@vkontakte/videoplayer 1.1.82-dev.a57718f4.0 → 1.1.82-dev.af06eecf.0

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.esm.js CHANGED
@@ -1,63 +1,63 @@
1
1
  /**
2
- * @vkontakte/videoplayer v1.1.82-dev.a57718f4.0
3
- * Tue, 03 Feb 2026 14:46:54 GMT
2
+ * @vkontakte/videoplayer v1.1.82-dev.af06eecf.0
3
+ * Mon, 09 Feb 2026 11:02:17 GMT
4
4
  * https://st.mycdn.me/static/vkontakte-videoplayer/1-1-82/doc/
5
5
  */
6
- var c$=Object.defineProperty,u$=Object.defineProperties;var p$=Object.getOwnPropertyDescriptors;var eg=Object.getOwnPropertySymbols;var f$=Object.prototype.hasOwnProperty,m$=Object.prototype.propertyIsEnumerable;var tg=t=>{throw TypeError(t)};var Ap=(t,e,i)=>e in t?c$(t,e,{enumerable:!0,configurable:!0,writable:!0,value:i}):t[e]=i,ke=(t,e)=>{for(var i in e||(e={}))f$.call(e,i)&&Ap(t,i,e[i]);if(eg)for(var i of eg(e))m$.call(e,i)&&Ap(t,i,e[i]);return t},Kt=(t,e)=>u$(t,p$(e));var ur=(t,e,i)=>Ap(t,typeof e!="symbol"?e+"":e,i),Lp=(t,e,i)=>e.has(t)||tg("Cannot "+i);var Oi=(t,e,i)=>(Lp(t,e,"read from private field"),i?i.call(t):e.get(t)),Js=(t,e,i)=>e.has(t)?tg("Cannot add the same private member more than once"):e instanceof WeakSet?e.add(t):e.set(t,i),ul=(t,e,i,o)=>(Lp(t,e,"write to private field"),o?o.call(t,i):e.set(t,i),i),ig=(t,e,i)=>(Lp(t,e,"access private method"),i);var gt=(t,e,i)=>new Promise((o,r)=>{var a=s=>{try{d(i.next(s))}catch(u){r(u)}},l=s=>{try{d(i.throw(s))}catch(u){r(u)}},d=s=>s.done?o(s.value):Promise.resolve(s.value).then(a,l);d((i=i.apply(t,e)).next())});var ea="[",ta="[!",Sa="]",us={};var to=Symbol(),qn=Symbol("filename"),og=Symbol("hmr"),ng="http://www.w3.org/1999/xhtml",Wc="http://www.w3.org/2000/svg";var Mp="@attach";var Kc=!0;var sg,ag,rg=(ag=(sg=globalThis.process)==null?void 0:sg.env)==null?void 0:ag.NODE_ENV,Ae=rg&&!rg.toLowerCase().startsWith("prod");var pr=Array.isArray,lg=Array.prototype.indexOf,od=Array.from,Vp=Object.keys,uo=Object.defineProperty,Wo=Object.getOwnPropertyDescriptor,qc=Object.getOwnPropertyDescriptors,Rp=Object.prototype,dg=Array.prototype,Ca=Object.getPrototypeOf,Np=Object.isExtensible;function ia(t){return typeof t=="function"}var ht=()=>{};function cg(t){return t()}function oa(t){for(var e=0;e<t.length;e++)t[e]()}var Ko=Symbol("$state"),pl=Symbol("legacy props"),ug=Symbol(""),Qc=Symbol("proxy path"),Gc=1,fl=3,fr=8;function Yc(t){return t===this.v}function ml(t,e){return t!=t?e==e:t!==e||t!==null&&typeof t=="object"||typeof t=="function"}function pg(t,e){return t!==e}function vl(t){return!ml(t,this.v)}function fg(){if(Ae){let t=new Error(`derived_references_self
6
+ var h$=Object.defineProperty,_$=Object.defineProperties;var b$=Object.getOwnPropertyDescriptors;var eg=Object.getOwnPropertySymbols;var $$=Object.prototype.hasOwnProperty,y$=Object.prototype.propertyIsEnumerable;var tg=i=>{throw TypeError(i)};var Pp=(i,e,t)=>e in i?h$(i,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):i[e]=t,Me=(i,e)=>{for(var t in e||(e={}))$$.call(e,t)&&Pp(i,t,e[t]);if(eg)for(var t of eg(e))y$.call(e,t)&&Pp(i,t,e[t]);return i},Qt=(i,e)=>_$(i,b$(e));var or=(i,e,t)=>Pp(i,typeof e!="symbol"?e+"":e,t),Ap=(i,e,t)=>e.has(i)||tg("Cannot "+t);var Ni=(i,e,t)=>(Ap(i,e,"read from private field"),t?t.call(i):e.get(i)),js=(i,e,t)=>e.has(i)?tg("Cannot add the same private member more than once"):e instanceof WeakSet?e.add(i):e.set(i,t),dl=(i,e,t,o)=>(Ap(i,e,"write to private field"),o?o.call(i,t):e.set(i,t),t),ig=(i,e,t)=>(Ap(i,e,"access private method"),t);var ht=(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 Xs="[",Zs="[!",wa="]",us={};var to=Symbol(),Hn=Symbol("filename"),og=Symbol("hmr"),ng="http://www.w3.org/1999/xhtml",Fc="http://www.w3.org/2000/svg";var kp="@attach";var Uc=!0;var sg,ag,rg=(ag=(sg=globalThis.process)==null?void 0:sg.env)==null?void 0:ag.NODE_ENV,Ve=rg&&!rg.toLowerCase().startsWith("prod");var nr=Array.isArray,lg=Array.prototype.indexOf,td=Array.from,Lp=Object.keys,mo=Object.defineProperty,zo=Object.getOwnPropertyDescriptor,zc=Object.getOwnPropertyDescriptors,Mp=Object.prototype,dg=Array.prototype,Sa=Object.getPrototypeOf,Vp=Object.isExtensible;function Js(i){return typeof i=="function"}var _t=()=>{};function cg(i){return i()}function ea(i){for(var e=0;e<i.length;e++)i[e]()}var Wo=Symbol("$state"),cl=Symbol("legacy props"),ug=Symbol(""),Wc=Symbol("proxy path"),Kc=1,ul=3,rr=8;function qc(i){return i===this.v}function pl(i,e){return i!=i?e==e:i!==e||i!==null&&typeof i=="object"||typeof i=="function"}function pg(i,e){return i!==e}function fl(i){return!pl(i,this.v)}function fg(){if(Ve){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 t.name="Svelte error",t}else throw new Error("https://svelte.dev/e/derived_references_self")}function mg(t){if(Ae){let e=new Error(`effect_in_teardown
9
- \`${t}\` 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 vg(){if(Ae){let t=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 t.name="Svelte error",t}else throw new Error("https://svelte.dev/e/effect_in_unowned_derived")}function gg(t){if(Ae){let e=new Error(`effect_orphan
11
- \`${t}\` 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 hg(){if(Ae){let t=new Error(`effect_update_depth_exceeded
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 mg(i){if(Ve){let e=new Error(`effect_in_teardown
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 vg(){if(Ve){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 gg(i){if(Ve){let e=new Error(`effect_orphan
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 hg(){if(Ve){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 t.name="Svelte error",t}else throw new Error("https://svelte.dev/e/effect_update_depth_exceeded")}function _g(){if(Ae){let t=new Error(`hydration_failed
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 _g(){if(Ve){let i=new Error(`hydration_failed
15
15
  Failed to hydrate the application
16
- https://svelte.dev/e/hydration_failed`);throw t.name="Svelte error",t}else throw new Error("https://svelte.dev/e/hydration_failed")}function bg(){if(Ae){let t=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 t.name="Svelte error",t}else throw new Error("https://svelte.dev/e/invalid_snippet")}function $g(t){if(Ae){let e=new Error(`props_invalid_value
17
- Cannot do \`bind:${t}={undefined}\` when \`${t}\` 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 yg(t){if(Ae){let e=new Error(`props_rest_readonly
19
- Rest element properties of \`$props()\` such as \`${t}\` 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 xg(t){if(Ae){let e=new Error(`rune_outside_svelte
21
- The \`${t}\` 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 wg(){if(Ae){let t=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 t.name="Svelte error",t}else throw new Error("https://svelte.dev/e/state_descriptors_fixed")}function Sg(){if(Ae){let t=new Error("state_prototype_fixed\nCannot set prototype of `$state` object\nhttps://svelte.dev/e/state_prototype_fixed");throw t.name="Svelte error",t}else throw new Error("https://svelte.dev/e/state_prototype_fixed")}function Cg(){if(Ae){let t=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 t.name="Svelte error",t}else throw new Error("https://svelte.dev/e/state_unsafe_mutation")}var ps=!1,fs=!1;function Tg(){ps=!0}var nd=null;function Ls(t){let e=Error(),i=e.stack;if(i){let o=i.split(`
16
+ https://svelte.dev/e/hydration_failed`);throw i.name="Svelte error",i}else throw new Error("https://svelte.dev/e/hydration_failed")}function bg(){if(Ve){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 $g(i){if(Ve){let e=new Error(`props_invalid_value
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 yg(i){if(Ve){let e=new Error(`props_rest_readonly
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 xg(i){if(Ve){let e=new Error(`rune_outside_svelte
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 wg(){if(Ve){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 Sg(){if(Ve){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 Cg(){if(Ve){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 ps=!1,fs=!1;function Tg(){ps=!0}var id=null;function Is(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;uo(e,"stack",{value:r.join(`
25
- `)}),uo(e,"name",{value:`${t}Error`})}return e}function jr(t,e){return t.label=e,jc(t.v,e),t}function jc(t,e){var i;return(i=t==null?void 0:t[Qc])==null||i.call(t,e),t}function gl(t){if(Ae){let e=new Error(`lifecycle_outside_component
26
- \`${t}(...)\` 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 Ft=null;function rd(t){Ft=t}var mr=null;function sd(t){mr=t}function hl(t){return Bp("getContext").get(t)}function _l(t,e){return Bp("setContext").set(t,e),e}function ad(){return Bp("getAllContexts")}function B(t,e=!1,i){var o=Ft={p:Ft,c:null,d:!1,e:null,m:!1,s:t,x:null,l:null};ps&&!e&&(Ft.l={s:null,u:null,r1:[],r2:Vr(!1)}),Lo(()=>{o.d=!0}),Ae&&(Ft.function=i,mr=i)}function H(t){var l,d;let e=Ft;if(e!==null){t!==void 0&&(e.x=t);let s=e.e;if(s!==null){var i=bt,o=Nt;e.e=null;try{for(var r=0;r<s.length;r++){var a=s[r];po(a.effect),qi(a.reaction),Mo(a.fn)}}finally{po(i),qi(o)}}Ft=e.p,Ae&&(mr=(d=(l=e.p)==null?void 0:l.function)!=null?d:null),e.m=!0}return t||{}}function ms(){return!ps||Ft!==null&&Ft.l===null}function Bp(t){var e;return Ft===null&&gl(t),(e=Ft.c)!=null?e:Ft.c=new Map(g$(Ft)||void 0)}function g$(t){let e=t.p;for(;e!==null;){let i=e.c;if(i!==null)return i;e=e.p}return null}var h$=/^[a-zA-Z_$][a-zA-Z_$0-9]*$/;function li(t){if(typeof t!="object"||t===null||Ko in t)return t;let e=Ca(t);if(e!==Rp&&e!==dg)return t;var i=new Map,o=pr(t),r=q(0),a=Ae&&fs?Ls("CreatedAt"):null,l=Nt,d=m=>{var p=Nt;qi(l);var v=m();return qi(p),v};o&&i.set("length",q(t.length,a));var s="";function u(m){s=m,jr(r,`${s} version`);for(let[p,v]of i)jr(v,Ta(s,p))}return new Proxy(t,{defineProperty(m,p,v){(!("value"in v)||v.configurable===!1||v.enumerable===!1||v.writable===!1)&&wg();var b=i.get(p);return b===void 0?b=d(()=>{var y=q(v.value,a);return i.set(p,y),Ae&&typeof p=="string"&&jr(y,Ta(s,p)),y}):N(b,v.value,!0),!0},deleteProperty(m,p){var v=i.get(p);if(v===void 0){if(p in m){let _=d(()=>q(to,a));i.set(p,_),Hp(r),Ae&&jr(_,Ta(s,p))}}else{if(o&&typeof p=="string"){var b=i.get("length"),y=Number(p);Number.isInteger(y)&&y<b.v&&N(b,y)}N(v,to),Hp(r)}return!0},get(m,p,v){var x;if(p===Ko)return t;if(Ae&&p===Qc)return u;var b=i.get(p),y=p in m;if(b===void 0&&(!y||(x=Wo(m,p))!=null&&x.writable)&&(b=d(()=>{var I=li(y?m[p]:to),T=q(I,a);return Ae&&jr(T,Ta(s,p)),T}),i.set(p,b)),b!==void 0){var _=n(b);return _===to?void 0:_}return Reflect.get(m,p,v)},getOwnPropertyDescriptor(m,p){var v=Reflect.getOwnPropertyDescriptor(m,p);if(v&&"value"in v){var b=i.get(p);b&&(v.value=n(b))}else if(v===void 0){var y=i.get(p),_=y==null?void 0:y.v;if(y!==void 0&&_!==to)return{enumerable:!0,configurable:!0,value:_,writable:!0}}return v},has(m,p){var _;if(p===Ko)return!0;var v=i.get(p),b=v!==void 0&&v.v!==to||Reflect.has(m,p);if(v!==void 0||bt!==null&&(!b||(_=Wo(m,p))!=null&&_.writable)){v===void 0&&(v=d(()=>{var x=b?li(m[p]):to,I=q(x,a);return Ae&&jr(I,Ta(s,p)),I}),i.set(p,v));var y=n(v);if(y===to)return!1}return b},set(m,p,v,b){var E;var y=i.get(p),_=p in m;if(o&&p==="length")for(var x=v;x<y.v;x+=1){var I=i.get(x+"");I!==void 0?N(I,to):x in m&&(I=d(()=>q(to,a)),i.set(x+"",I),Ae&&jr(I,Ta(s,x)))}if(y===void 0)(!_||(E=Wo(m,p))!=null&&E.writable)&&(y=d(()=>q(void 0,a)),N(y,li(v)),i.set(p,y),Ae&&jr(y,Ta(s,p)));else{_=y.v!==to;var T=d(()=>li(v));N(y,T)}var R=Reflect.getOwnPropertyDescriptor(m,p);if(R!=null&&R.set&&R.set.call(b,v),!_){if(o&&typeof p=="string"){var A=i.get("length"),P=Number(p);Number.isInteger(P)&&P>=A.v&&N(A,P+1)}Hp(r)}return!0},ownKeys(m){n(r);var p=Reflect.ownKeys(m).filter(y=>{var _=i.get(y);return _===void 0||_.v!==to});for(var[v,b]of i)b.v!==to&&!(v in m)&&p.push(v);return p},setPrototypeOf(){Sg()}})}function Ta(t,e){var i;return typeof e=="symbol"?`${t}[Symbol(${(i=e.description)!=null?i:""})]`:h$.test(e)?`${t}.${e}`:/^\d+$/.test(e)?`${t}[${e}]`:`${t}['${e}']`}function Hp(t,e=1){N(t,t.v+e)}function bl(t){try{if(t!==null&&typeof t=="object"&&Ko in t)return t[Ko]}catch(e){}return t}function Fp(t,e){return Object.is(bl(t),bl(e))}function Xr(t){var e=2050,i=Nt!==null&&(Nt.f&2)!==0?Nt:null;bt===null||i!==null&&(i.f&256)!==0?e|=256:bt.f|=1048576;let o={ctx:Ft,deps:null,effects:null,equals:Yc,f:e,fn:t,reactions:null,rv:0,v:null,wv:0,parent:i!=null?i:bt};return Ae&&fs&&(o.created=Ls("CreatedAt")),o}function f(t){let e=Xr(t);return Jc(e),e}function In(t){let e=Xr(t);return e.equals=vl,e}function Xc(t){var e=t.effects;if(e!==null){t.effects=null;for(var i=0;i<e.length;i+=1)Qi(e[i])}}var Up=[];function _$(t){for(var e=t.parent;e!==null;){if((e.f&2)===0)return e;e=e.parent}return null}function Kp(t){var e,i=bt;if(po(_$(t)),Ae){let o=Ia;zp(new Set);try{Up.includes(t)&&fg(),Up.push(t),Xc(t),e=Zc(t)}finally{po(i),zp(o),Up.pop()}}else try{Xc(t),e=Zc(t)}finally{po(i)}return e}function qp(t){var e=Kp(t);if(t.equals(e)||(t.v=e,t.wv=ld()),!Ms){var i=(Vs||(t.f&256)!==0)&&t.deps!==null?4096:1024;En(t,i)}}var Ia=new Set,$l=new Map;function zp(t){Ia=t}function Vr(t,e){var i={f:0,v:t,reactions:null,equals:Yc,rv:0,wv:0};return Ae&&fs&&(i.created=e!=null?e:Ls("CreatedAt"),i.updated=null,i.set_during_effect=!1,i.trace=null),i}function q(t,e){let i=Vr(t,e);return Jc(i),i}function vs(t,e=!1,i=!0){var r,a;let o=Vr(t);return e||(o.equals=vl),ps&&i&&Ft!==null&&Ft.l!==null&&((a=(r=Ft.l).s)!=null?a:r.s=[]).push(o),o}function N(t,e,i=!1){var r;Nt!==null&&(!hr||(Nt.f&262144)!==0)&&ms()&&(Nt.f&262162)!==0&&!((r=Qo)!=null&&r[1].includes(t)&&Qo[0]===Nt)&&Cg();let o=i?li(e):e;return Ae&&jc(o,t.label),yl(t,o)}function yl(t,e){if(!t.equals(e)){var i=t.v;if(Ms?$l.set(t,e):$l.set(t,i),t.v=e,Ae&&fs&&(t.updated=Ls("UpdatedAt"),bt!==null&&(t.set_during_effect=!0)),(t.f&2)!==0&&((t.f&2048)!==0&&Kp(t),En(t,(t.f&256)===0?1024:4096)),t.wv=ld(),Eg(t,2048),ms()&&bt!==null&&(bt.f&1024)!==0&&(bt.f&96)===0&&(gr===null?Pg([t]):gr.push(t)),Ae&&Ia.size>0){let o=Array.from(Ia);for(let r of o)(r.f&1024)!==0&&En(r,4096),Pa(r)&&xl(r);Ia.clear()}}return e}function Eg(t,e){var i=t.reactions;if(i!==null)for(var o=ms(),r=i.length,a=0;a<r;a++){var l=i[a],d=l.f;if((d&2048)===0&&!(!o&&l===bt)){if(Ae&&(d&262144)!==0){Ia.add(l);continue}En(l,e),(d&1280)!==0&&((d&2)!==0?Eg(l,4096):cd(l))}}}var wl="font-weight: bold",Sl="font-weight: normal";function kg(t,e,i){Ae?console.warn(`%c[svelte] hydration_attribute_changed
28
- %cThe \`${t}\` attribute on \`${e}\` changed its value between server and client renders. The client value, \`${i}\`, will be ignored in favour of the server value
29
- https://svelte.dev/e/hydration_attribute_changed`,wl,Sl):console.warn("https://svelte.dev/e/hydration_attribute_changed")}function Ag(t){Ae?console.warn(`%c[svelte] hydration_html_changed
30
- %c${t?`The value of an \`{@html ...}\` block ${t} 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`,wl,Sl):console.warn("https://svelte.dev/e/hydration_html_changed")}function na(t){Ae?console.warn(`%c[svelte] hydration_mismatch
32
- %c${t?`Hydration failed because the initial UI does not match what was rendered on the server. The error occurred near ${t}`:"Hydration failed because the initial UI does not match what was rendered on the server"}
33
- https://svelte.dev/e/hydration_mismatch`,wl,Sl):console.warn("https://svelte.dev/e/hydration_mismatch")}function Lg(){Ae?console.warn(`%c[svelte] lifecycle_double_unmount
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;mo(e,"stack",{value:r.join(`
25
+ `)}),mo(e,"name",{value:`${i}Error`})}return e}function Yr(i,e){return i.label=e,Qc(i.v,e),i}function Qc(i,e){var t;return(t=i==null?void 0:i[Wc])==null||t.call(i,e),i}function ml(i){if(Ve){let e=new Error(`lifecycle_outside_component
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 Ft=null;function od(i){Ft=i}var sr=null;function nd(i){sr=i}function vl(i){return Dp("getContext").get(i)}function gl(i,e){return Dp("setContext").set(i,e),e}function rd(){return Dp("getAllContexts")}function B(i,e=!1,t){var o=Ft={p:Ft,c:null,d:!1,e:null,m:!1,s:i,x:null,l:null};ps&&!e&&(Ft.l={s:null,u:null,r1:[],r2:Rr(!1)}),Ao(()=>{o.d=!0}),Ve&&(Ft.function=t,sr=t)}function H(i){var l,d;let e=Ft;if(e!==null){i!==void 0&&(e.x=i);let s=e.e;if(s!==null){var t=bt,o=Dt;e.e=null;try{for(var r=0;r<s.length;r++){var a=s[r];vo(a.effect),Gi(a.reaction),ko(a.fn)}}finally{vo(t),Gi(o)}}Ft=e.p,Ve&&(sr=(d=(l=e.p)==null?void 0:l.function)!=null?d:null),e.m=!0}return i||{}}function ms(){return!ps||Ft!==null&&Ft.l===null}function Dp(i){var e;return Ft===null&&ml(i),(e=Ft.c)!=null?e:Ft.c=new Map(w$(Ft)||void 0)}function w$(i){let e=i.p;for(;e!==null;){let t=e.c;if(t!==null)return t;e=e.p}return null}var S$=/^[a-zA-Z_$][a-zA-Z_$0-9]*$/;function ci(i){if(typeof i!="object"||i===null||Wo in i)return i;let e=Sa(i);if(e!==Mp&&e!==dg)return i;var t=new Map,o=nr(i),r=K(0),a=Ve&&fs?Is("CreatedAt"):null,l=Dt,d=m=>{var p=Dt;Gi(l);var v=m();return Gi(p),v};o&&t.set("length",K(i.length,a));var s="";function u(m){s=m,Yr(r,`${s} version`);for(let[p,v]of t)Yr(v,Ca(s,p))}return new Proxy(i,{defineProperty(m,p,v){(!("value"in v)||v.configurable===!1||v.enumerable===!1||v.writable===!1)&&wg();var b=t.get(p);return b===void 0?b=d(()=>{var y=K(v.value,a);return t.set(p,y),Ve&&typeof p=="string"&&Yr(y,Ca(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(to,a));t.set(p,_),Np(r),Ve&&Yr(_,Ca(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,to),Np(r)}return!0},get(m,p,v){var x;if(p===Wo)return i;if(Ve&&p===Wc)return u;var b=t.get(p),y=p in m;if(b===void 0&&(!y||(x=zo(m,p))!=null&&x.writable)&&(b=d(()=>{var I=ci(y?m[p]:to),C=K(I,a);return Ve&&Yr(C,Ca(s,p)),C}),t.set(p,b)),b!==void 0){var _=n(b);return _===to?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&&_!==to)return{enumerable:!0,configurable:!0,value:_,writable:!0}}return v},has(m,p){var _;if(p===Wo)return!0;var v=t.get(p),b=v!==void 0&&v.v!==to||Reflect.has(m,p);if(v!==void 0||bt!==null&&(!b||(_=zo(m,p))!=null&&_.writable)){v===void 0&&(v=d(()=>{var x=b?ci(m[p]):to,I=K(x,a);return Ve&&Yr(I,Ca(s,p)),I}),t.set(p,v));var y=n(v);if(y===to)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,to):x in m&&(I=d(()=>K(to,a)),t.set(x+"",I),Ve&&Yr(I,Ca(s,x)))}if(y===void 0)(!_||(E=zo(m,p))!=null&&E.writable)&&(y=d(()=>K(void 0,a)),O(y,ci(v)),t.set(p,y),Ve&&Yr(y,Ca(s,p)));else{_=y.v!==to;var C=d(()=>ci(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 k=t.get("length"),P=Number(p);Number.isInteger(P)&&P>=k.v&&O(k,P+1)}Np(r)}return!0},ownKeys(m){n(r);var p=Reflect.ownKeys(m).filter(y=>{var _=t.get(y);return _===void 0||_.v!==to});for(var[v,b]of t)b.v!==to&&!(v in m)&&p.push(v);return p},setPrototypeOf(){Sg()}})}function Ca(i,e){var t;return typeof e=="symbol"?`${i}[Symbol(${(t=e.description)!=null?t:""})]`:S$.test(e)?`${i}.${e}`:/^\d+$/.test(e)?`${i}[${e}]`:`${i}['${e}']`}function Np(i,e=1){O(i,i.v+e)}function hl(i){try{if(i!==null&&typeof i=="object"&&Wo in i)return i[Wo]}catch(e){}return i}function Bp(i,e){return Object.is(hl(i),hl(e))}function jr(i){var e=2050,t=Dt!==null&&(Dt.f&2)!==0?Dt:null;bt===null||t!==null&&(t.f&256)!==0?e|=256:bt.f|=1048576;let o={ctx:Ft,deps:null,effects:null,equals:qc,f:e,fn:i,reactions:null,rv:0,v:null,wv:0,parent:t!=null?t:bt};return Ve&&fs&&(o.created=Is("CreatedAt")),o}function f(i){let e=jr(i);return jc(e),e}function lr(i){let e=jr(i);return e.equals=fl,e}function Gc(i){var e=i.effects;if(e!==null){i.effects=null;for(var t=0;t<e.length;t+=1)Yi(e[t])}}var Hp=[];function C$(i){for(var e=i.parent;e!==null;){if((e.f&2)===0)return e;e=e.parent}return null}function zp(i){var e,t=bt;if(vo(C$(i)),Ve){let o=Ta;Fp(new Set);try{Hp.includes(i)&&fg(),Hp.push(i),Gc(i),e=Yc(i)}finally{vo(t),Fp(o),Hp.pop()}}else try{Gc(i),e=Yc(i)}finally{vo(t)}return e}function Wp(i){var e=zp(i);if(i.equals(e)||(i.v=e,i.wv=sd()),!Es){var t=(Ps||(i.f&256)!==0)&&i.deps!==null?4096:1024;$n(i,t)}}var Ta=new Set,_l=new Map;function Fp(i){Ta=i}function Rr(i,e){var t={f:0,v:i,reactions:null,equals:qc,rv:0,wv:0};return Ve&&fs&&(t.created=e!=null?e:Is("CreatedAt"),t.updated=null,t.set_during_effect=!1,t.trace=null),t}function K(i,e){let t=Rr(i,e);return jc(t),t}function vs(i,e=!1,t=!0){var r,a;let o=Rr(i);return e||(o.equals=fl),ps&&t&&Ft!==null&&Ft.l!==null&&((a=(r=Ft.l).s)!=null?a:r.s=[]).push(o),o}function O(i,e,t=!1){var r;Dt!==null&&(!cr||(Dt.f&262144)!==0)&&ms()&&(Dt.f&262162)!==0&&!((r=qo)!=null&&r[1].includes(i)&&qo[0]===Dt)&&Cg();let o=t?ci(e):e;return Ve&&Qc(o,i.label),bl(i,o)}function bl(i,e){if(!i.equals(e)){var t=i.v;if(Es?_l.set(i,e):_l.set(i,t),i.v=e,Ve&&fs&&(i.updated=Is("UpdatedAt"),bt!==null&&(i.set_during_effect=!0)),(i.f&2)!==0&&((i.f&2048)!==0&&zp(i),$n(i,(i.f&256)===0?1024:4096)),i.wv=sd(),Eg(i,2048),ms()&&bt!==null&&(bt.f&1024)!==0&&(bt.f&96)===0&&(dr===null?Pg([i]):dr.push(i)),Ve&&Ta.size>0){let o=Array.from(Ta);for(let r of o)(r.f&1024)!==0&&$n(r,4096),Ea(r)&&$l(r);Ta.clear()}}return e}function Eg(i,e){var t=i.reactions;if(t!==null)for(var o=ms(),r=t.length,a=0;a<r;a++){var l=t[a],d=l.f;if((d&2048)===0&&!(!o&&l===bt)){if(Ve&&(d&262144)!==0){Ta.add(l);continue}$n(l,e),(d&1280)!==0&&((d&2)!==0?Eg(l,4096):ld(l))}}}var yl="font-weight: bold",xl="font-weight: normal";function Ag(i,e,t){Ve?console.warn(`%c[svelte] hydration_attribute_changed
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`,yl,xl):console.warn("https://svelte.dev/e/hydration_attribute_changed")}function kg(i){Ve?console.warn(`%c[svelte] hydration_html_changed
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`,yl,xl):console.warn("https://svelte.dev/e/hydration_html_changed")}function ta(i){Ve?console.warn(`%c[svelte] hydration_mismatch
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`,yl,xl):console.warn("https://svelte.dev/e/hydration_mismatch")}function Lg(){Ve?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`,wl,Sl):console.warn("https://svelte.dev/e/lifecycle_double_unmount")}function Mg(){Ae?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",wl,Sl):console.warn("https://svelte.dev/e/select_multiple_invalid_value")}function eu(t){Ae?console.warn(`%c[svelte] state_proxy_equality_mismatch
36
- %cReactive \`$state(...)\` proxies and the values they proxy have different identities. Because of this, comparisons with \`${t}\` will produce unexpected results
37
- https://svelte.dev/e/state_proxy_equality_mismatch`,wl,Sl):console.warn("https://svelte.dev/e/state_proxy_equality_mismatch")}var tt=!1;function fo(t){tt=t}var $t;function xi(t){if(t===null)throw na(),us;return $t=t}function Gi(){return xi(Go($t))}function S(t){if(tt){if(Go($t)!==null)throw na(),us;$t=t}}function di(t=1){if(tt){for(var e=t,i=$t;e--;)i=Go(i);$t=i}}function ka(){for(var t=0,e=$t;;){if(e.nodeType===fr){var i=e.data;if(i===Sa){if(t===0)return e;t-=1}else(i===ea||i===ta)&&(t+=1)}var o=Go(e);e.remove(),e=o}}function tu(t){if(!t||t.nodeType!==fr)throw na(),us;return t.data}function Vg(){let t=Array.prototype,e=Array.__svelte_cleanup;e&&e();let{indexOf:i,lastIndexOf:o,includes:r}=t;t.indexOf=function(a,l){let d=i.call(this,a,l);if(d===-1){for(let s=l!=null?l:0;s<this.length;s+=1)if(bl(this[s])===a){eu("array.indexOf(...)");break}}return d},t.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(bl(this[s])===a){eu("array.lastIndexOf(...)");break}}return d},t.includes=function(a,l){let d=r.call(this,a,l);if(!d){for(let s=0;s<this.length;s+=1)if(bl(this[s])===a){eu("array.includes(...)");break}}return d},Array.__svelte_cleanup=()=>{t.indexOf=i,t.lastIndexOf=o,t.includes=r}}var Aa,Rg,ud,Ng,Og;function iu(){if(Aa===void 0){Aa=window,Rg=document,ud=/Firefox/.test(navigator.userAgent);var t=Element.prototype,e=Node.prototype,i=Text.prototype;Ng=Wo(e,"firstChild").get,Og=Wo(e,"nextSibling").get,Np(t)&&(t.__click=void 0,t.__className=void 0,t.__attributes=null,t.__style=void 0,t.__e=void 0),Np(i)&&(i.__t=void 0),Ae&&(t.__svelte_meta=null,Vg())}}function Pn(t=""){return document.createTextNode(t)}function Ci(t){return Ng.call(t)}function Go(t){return Og.call(t)}function C(t,e){if(!tt)return Ci(t);var i=Ci($t);if(i===null)i=$t.appendChild(Pn());else if(e&&i.nodeType!==fl){var o=Pn();return i==null||i.before(o),xi(o),o}return xi(i),i}function ue(t,e){var r,a;if(!tt){var i=Ci(t);return i.nodeType===8&&i.data===""?Go(i):i}if(e&&((r=$t)==null?void 0:r.nodeType)!==fl){var o=Pn();return(a=$t)==null||a.before(o),xi(o),o}return $t}function k(t,e=1,i=!1){let o=tt?$t:t;for(var r;e--;)r=o,o=Go(o);if(!tt)return o;if(i&&(o==null?void 0:o.nodeType)!==fl){var a=Pn();return o===null?r==null||r.after(a):o.before(a),xi(a),a}return xi(o),o}function pd(t){t.textContent=""}function Yp(t){bt===null&&Nt===null&&gg(t),Nt!==null&&(Nt.f&256)!==0&&bt===null&&vg(),Ms&&mg(t)}function b$(t,e){var i=e.last;i===null?e.last=e.first=t:(i.next=t,t.prev=i,e.last=t)}function La(t,e,i,o=!0){var s;var r=bt;if(Ae)for(;r!==null&&(r.f&262144)!==0;)r=r.parent;var a={ctx:Ft,deps:null,nodes_start:null,nodes_end:null,f:t|2048,first:null,fn:e,last:null,next:null,parent:r,prev:null,teardown:null,transitions:null,wv:0};if(Ae&&(a.component_function=mr),i)try{xl(a),a.f|=32768}catch(u){throw Qi(a),u}else e!==null&&cd(a);var l=i&&a.deps===null&&a.first===null&&a.nodes_start===null&&a.teardown===null&&(a.f&1048704)===0;if(!l&&o&&(r!==null&&b$(a,r),Nt!==null&&(Nt.f&2)!==0)){var d=Nt;((s=d.effects)!=null?s:d.effects=[]).push(a)}return a}function Lo(t){let e=La(8,null,!1);return En(e,1024),e.teardown=t,e}function De(t){var r;Yp("$effect");var e=bt!==null&&(bt.f&32)!==0&&Ft!==null&&!Ft.m;if(Ae&&uo(t,"name",{value:"$effect"}),e){var i=Ft;((r=i.e)!=null?r:i.e=[]).push({fn:t,effect:bt,reaction:Nt})}else{var o=Mo(t);return o}}function vd(t){return Yp("$effect.pre"),Ae&&uo(t,"name",{value:"$effect.pre"}),Yo(t)}function ru(t){let e=La(64,t,!0);return()=>{Qi(e)}}function Bg(t){let e=La(64,t,!0);return(i={})=>new Promise(o=>{i.outro?jn(e,()=>{Qi(e),o(void 0)}):(Qi(e),o(void 0))})}function Mo(t){return La(4,t,!1)}function Yo(t){return La(8,t,!0)}function D(t,e=[],i=Xr){if(Ae)return Yo(()=>{var r=bt,a=()=>t(...l.map(n));uo(r.fn,"name",{value:"{expression}"}),uo(a,"name",{value:"{expression}"});let l=e.map(i);Yi(a)});let o=e.map(i);return Yi(()=>t(...o.map(n)))}function Yi(t,e=0){return La(24|e,t,!0)}function Di(t,e=!0){return La(40,t,!0,e)}function jp(t){var e=t.teardown;if(e!==null){let i=Ms,o=Nt;Qp(!0),qi(null);try{e.call(null)}finally{Qp(i),qi(o)}}}function Xp(t,e=!1){var i=t.first;for(t.first=t.last=null;i!==null;){var o=i.next;(i.f&64)!==0?i.parent=null:Qi(i,e),i=o}}function Hg(t){for(var e=t.first;e!==null;){var i=e.next;(e.f&32)===0&&Qi(e),e=i}}function Qi(t,e=!0){var i=!1;(e||(t.f&524288)!==0)&&t.nodes_start!==null&&t.nodes_end!==null&&(Zp(t.nodes_start,t.nodes_end),i=!0),Xp(t,e&&!i),gd(t,0),En(t,16384);var o=t.transitions;if(o!==null)for(let a of o)a.stop();jp(t);var r=t.parent;r!==null&&r.first!==null&&Jp(t),Ae&&(t.component_function=null),t.next=t.prev=t.teardown=t.ctx=t.deps=t.fn=t.nodes_start=t.nodes_end=null}function Zp(t,e){for(;t!==null;){var i=t===e?null:Go(t);t.remove(),t=i}}function Jp(t){var e=t.parent,i=t.prev,o=t.next;i!==null&&(i.next=o),o!==null&&(o.prev=i),e!==null&&(e.first===t&&(e.first=o),e.last===t&&(e.last=i))}function jn(t,e){var i=[];su(t,i,!0),ef(i,()=>{Qi(t),e&&e()})}function ef(t,e){var i=t.length;if(i>0){var o=()=>--i||e();for(var r of t)r.out(o)}else e()}function su(t,e,i){if((t.f&8192)===0){if(t.f^=8192,t.transitions!==null)for(let l of t.transitions)(l.is_global||i)&&e.push(l);for(var o=t.first;o!==null;){var r=o.next,a=(o.f&65536)!==0||(o.f&32)!==0;su(o,e,a?i:!1),o=r}}}function Ns(t){Fg(t,!0)}function Fg(t,e){if((t.f&8192)!==0){t.f^=8192;for(var i=t.first;i!==null;){var o=i.next,r=(i.f&65536)!==0||(i.f&32)!==0;Fg(i,r?e:!1),i=o}if(t.transitions!==null)for(let a of t.transitions)(a.is_global||e)&&a.in()}}var hd=[],tf=[];function Ug(){var t=hd;hd=[],oa(t)}function $$(){var t=tf;tf=[],oa(t)}function kn(t){hd.length===0&&queueMicrotask(Ug),hd.push(t)}function zg(){hd.length>0&&Ug(),tf.length>0&&$$()}function Kg(t){var e=bt;if(Ae&&t instanceof Error&&y$(t,e),(e.f&32768)===0){if((e.f&128)===0)throw t;e.fn(t)}else _d(t,e)}function _d(t,e){for(;e!==null;){if((e.f&128)!==0)try{e.fn(t);return}catch(i){}e=e.parent}throw t}var Wg=new WeakSet;function y$(t,e){var l,d;if(Wg.has(t))return;Wg.add(t);let i=Wo(t,"message");if(!(i&&!i.configurable)){for(var o=ud?" ":" ",r=`
35
+ https://svelte.dev/e/lifecycle_double_unmount`,yl,xl):console.warn("https://svelte.dev/e/lifecycle_double_unmount")}function Mg(){Ve?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",yl,xl):console.warn("https://svelte.dev/e/select_multiple_invalid_value")}function Xc(i){Ve?console.warn(`%c[svelte] state_proxy_equality_mismatch
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`,yl,xl):console.warn("https://svelte.dev/e/state_proxy_equality_mismatch")}var ot=!1;function go(i){ot=i}var $t;function wi(i){if(i===null)throw ta(),us;return $t=i}function ji(){return wi(Qo($t))}function S(i){if(ot){if(Qo($t)!==null)throw ta(),us;$t=i}}function ti(i=1){if(ot){for(var e=i,t=$t;e--;)t=Qo(t);$t=t}}function Pa(){for(var i=0,e=$t;;){if(e.nodeType===rr){var t=e.data;if(t===wa){if(i===0)return e;i-=1}else(t===Xs||t===Zs)&&(i+=1)}var o=Qo(e);e.remove(),e=o}}function Zc(i){if(!i||i.nodeType!==rr)throw ta(),us;return i.data}function Vg(){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(hl(this[s])===a){Xc("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(hl(this[s])===a){Xc("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(hl(this[s])===a){Xc("array.includes(...)");break}}return d},Array.__svelte_cleanup=()=>{i.indexOf=t,i.lastIndexOf=o,i.includes=r}}var Aa,Rg,dd,Og,Dg;function Jc(){if(Aa===void 0){Aa=window,Rg=document,dd=/Firefox/.test(navigator.userAgent);var i=Element.prototype,e=Node.prototype,t=Text.prototype;Og=zo(e,"firstChild").get,Dg=zo(e,"nextSibling").get,Vp(i)&&(i.__click=void 0,i.__className=void 0,i.__attributes=null,i.__style=void 0,i.__e=void 0),Vp(t)&&(t.__t=void 0),Ve&&(i.__svelte_meta=null,Vg())}}function yn(i=""){return document.createTextNode(i)}function Ti(i){return Og.call(i)}function Qo(i){return Dg.call(i)}function T(i,e){if(!ot)return Ti(i);var t=Ti($t);if(t===null)t=$t.appendChild(yn());else if(e&&t.nodeType!==ul){var o=yn();return t==null||t.before(o),wi(o),o}return wi(t),t}function le(i,e){var r,a;if(!ot){var t=Ti(i);return t.nodeType===8&&t.data===""?Qo(t):t}if(e&&((r=$t)==null?void 0:r.nodeType)!==ul){var o=yn();return(a=$t)==null||a.before(o),wi(o),o}return $t}function A(i,e=1,t=!1){let o=ot?$t:i;for(var r;e--;)r=o,o=Qo(o);if(!ot)return o;if(t&&(o==null?void 0:o.nodeType)!==ul){var a=yn();return o===null?r==null||r.after(a):o.before(a),wi(a),a}return wi(o),o}function cd(i){i.textContent=""}function Qp(i){bt===null&&Dt===null&&gg(i),Dt!==null&&(Dt.f&256)!==0&&bt===null&&vg(),Es&&mg(i)}function T$(i,e){var t=e.last;t===null?e.last=e.first=i:(t.next=i,i.prev=t,e.last=i)}function ka(i,e,t,o=!0){var s;var r=bt;if(Ve)for(;r!==null&&(r.f&262144)!==0;)r=r.parent;var a={ctx:Ft,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(Ve&&(a.component_function=sr),t)try{$l(a),a.f|=32768}catch(u){throw Yi(a),u}else e!==null&&ld(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&&T$(a,r),Dt!==null&&(Dt.f&2)!==0)){var d=Dt;((s=d.effects)!=null?s:d.effects=[]).push(a)}return a}function Ao(i){let e=ka(8,null,!1);return $n(e,1024),e.teardown=i,e}function He(i){var r;Qp("$effect");var e=bt!==null&&(bt.f&32)!==0&&Ft!==null&&!Ft.m;if(Ve&&mo(i,"name",{value:"$effect"}),e){var t=Ft;((r=t.e)!=null?r:t.e=[]).push({fn:i,effect:bt,reaction:Dt})}else{var o=ko(i);return o}}function fd(i){return Qp("$effect.pre"),Ve&&mo(i,"name",{value:"$effect.pre"}),Go(i)}function iu(i){let e=ka(64,i,!0);return()=>{Yi(e)}}function Bg(i){let e=ka(64,i,!0);return(t={})=>new Promise(o=>{t.outro?Wn(e,()=>{Yi(e),o(void 0)}):(Yi(e),o(void 0))})}function ko(i){return ka(4,i,!1)}function Go(i){return ka(8,i,!0)}function D(i,e=[],t=jr){if(Ve)return Go(()=>{var r=bt,a=()=>i(...l.map(n));mo(r.fn,"name",{value:"{expression}"}),mo(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 ka(24|e,i,!0)}function Bi(i,e=!0){return ka(40,i,!0,e)}function Gp(i){var e=i.teardown;if(e!==null){let t=Es,o=Dt;Kp(!0),Gi(null);try{e.call(null)}finally{Kp(t),Gi(o)}}}function Yp(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 Hg(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&&(jp(i.nodes_start,i.nodes_end),t=!0),Yp(i,e&&!t),md(i,0),$n(i,16384);var o=i.transitions;if(o!==null)for(let a of o)a.stop();Gp(i);var r=i.parent;r!==null&&r.first!==null&&Xp(i),Ve&&(i.component_function=null),i.next=i.prev=i.teardown=i.ctx=i.deps=i.fn=i.nodes_start=i.nodes_end=null}function jp(i,e){for(;i!==null;){var t=i===e?null:Qo(i);i.remove(),i=t}}function Xp(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 Wn(i,e){var t=[];ou(i,t,!0),Zp(t,()=>{Yi(i),e&&e()})}function Zp(i,e){var t=i.length;if(t>0){var o=()=>--t||e();for(var r of i)r.out(o)}else e()}function ou(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;ou(o,e,a?t:!1),o=r}}}function ks(i){Fg(i,!0)}function Fg(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;Fg(t,r?e:!1),t=o}if(i.transitions!==null)for(let a of i.transitions)(a.is_global||e)&&a.in()}}var vd=[],Jp=[];function Ug(){var i=vd;vd=[],ea(i)}function I$(){var i=Jp;Jp=[],ea(i)}function xn(i){vd.length===0&&queueMicrotask(Ug),vd.push(i)}function zg(){vd.length>0&&Ug(),Jp.length>0&&I$()}function Kg(i){var e=bt;if(Ve&&i instanceof Error&&E$(i,e),(e.f&32768)===0){if((e.f&128)===0)throw i;e.fn(i)}else gd(i,e)}function gd(i,e){for(;e!==null;){if((e.f&128)!==0)try{e.fn(i);return}catch(t){}e=e.parent}throw i}var Wg=new WeakSet;function E$(i,e){var l,d;if(Wg.has(i))return;Wg.add(i);let t=zo(i,"message");if(!(t&&!t.configurable)){for(var o=dd?" ":" ",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[qn].split("/").pop()}`,a=a.p;uo(t,"message",{value:t.message+`
39
+ ${o}in ${(d=a.function)==null?void 0:d[Hn].split("/").pop()}`,a=a.p;mo(i,"message",{value:i.message+`
40
40
  ${r}
41
- `}),t.stack&&uo(t,"stack",{value:t.stack.split(`
41
+ `}),i.stack&&mo(i,"stack",{value:i.stack.split(`
42
42
  `).filter(s=>!s.includes("svelte/src/internal")).join(`
43
- `)})}}var Ma=!1,Cl=null,Va=!1,Ms=!1;function Qp(t){Ms=t}var bd=[],$d=[],Nt=null,hr=!1;function qi(t){Nt=t}var bt=null;function po(t){bt=t}var Qo=null;function Jc(t){Nt!==null&&Nt.f&2097152&&(Qo===null?Qo=[Nt,[t]]:Qo[1].push(t))}var An=null,_r=0,gr=null;function Pg(t){gr=t}var Gg=1,lu=0,Vs=!1,du=null;function ld(){return++Gg}function Pa(t){var p,v;var e=t.f;if((e&2048)!==0)return!0;if((e&4096)!==0){var i=t.deps,o=(e&256)!==0;if(i!==null){var r,a,l=(e&512)!==0,d=o&&bt!==null&&!Vs,s=i.length;if(l||d){var u=t,m=u.parent;for(r=0;r<s;r++)a=i[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=i[r],Pa(a)&&qp(a),a.wv>t.wv)return!0}(!o||bt!==null&&!Vs)&&En(t,1024)}return!1}function Yg(t,e,i=!0){var o=t.reactions;if(o!==null)for(var r=0;r<o.length;r++){var a=o[r];Qo!=null&&Qo[1].includes(t)&&Qo[0]===Nt||((a.f&2)!==0?Yg(a,e,!1):e===a&&(i?En(a,2048):(a.f&1024)!==0&&En(a,4096),cd(a)))}}function Zc(t){var b,y;var e=An,i=_r,o=gr,r=Nt,a=Vs,l=Qo,d=Ft,s=hr,u=t.f;An=null,_r=0,gr=null,Vs=(u&256)!==0&&(hr||!Va||Nt===null),Nt=(u&96)===0?t:null,Qo=null,rd(t.ctx),hr=!1,lu++,t.f|=2097152;try{var m=(0,t.fn)(),p=t.deps;if(An!==null){var v;if(gd(t,_r),p!==null&&_r>0)for(p.length=_r+An.length,v=0;v<An.length;v++)p[_r+v]=An[v];else t.deps=p=An;if(!Vs||(u&2)!==0&&t.reactions!==null)for(v=_r;v<p.length;v++)((y=(b=p[v]).reactions)!=null?y:b.reactions=[]).push(t)}else p!==null&&_r<p.length&&(gd(t,_r),p.length=_r);if(ms()&&gr!==null&&!hr&&p!==null&&(t.f&6146)===0)for(v=0;v<gr.length;v++)Yg(gr[v],t);return r!==null&&r!==t&&(lu++,gr!==null&&(o===null?o=gr:o.push(...gr))),m}catch(_){Kg(_)}finally{An=e,_r=i,gr=o,Nt=r,Vs=a,Qo=l,rd(d),hr=s,t.f^=2097152}}function x$(t,e){let i=e.reactions;if(i!==null){var o=lg.call(i,t);if(o!==-1){var r=i.length-1;r===0?i=e.reactions=null:(i[o]=i[r],i.pop())}}i===null&&(e.f&2)!==0&&(An===null||!An.includes(e))&&(En(e,4096),(e.f&768)===0&&(e.f^=512),Xc(e),gd(e,0))}function gd(t,e){var i=t.deps;if(i!==null)for(var o=e;o<i.length;o++)x$(t,i[o])}function xl(t){var e=t.f;if((e&16384)===0){En(t,1024);var i=bt,o=Va;if(bt=t,Va=!0,Ae){var r=mr;sd(t.component_function)}try{(e&16)!==0?Hg(t):Xp(t),jp(t);var a=Zc(t);if(t.teardown=typeof a=="function"?a:null,t.wv=Gg,Ae&&fs&&(t.f&2048)!==0&&t.deps!==null)for(var l of t.deps)l.set_during_effect&&(l.wv=ld(),l.set_during_effect=!1);Ae&&$d.push(t)}finally{Va=o,bt=i,Ae&&sd(r)}}}function qg(){console.error("Last ten effects were: ",$d.slice(-10).map(t=>t.fn)),$d=[]}function w$(){try{hg()}catch(t){if(Ae&&uo(t,"stack",{value:""}),Cl!==null)if(Ae)try{_d(t,Cl)}catch(e){throw qg(),e}else _d(t,Cl);else throw Ae&&qg(),t}}function nf(){var t=Va;try{var e=0;for(Va=!0;bd.length>0;){e++>1e3&&w$();var i=bd,o=i.length;bd=[];for(var r=0;r<o;r++){var a=C$(i[r]);S$(a)}$l.clear()}}finally{Ma=!1,Va=t,Cl=null,Ae&&($d=[])}}function S$(t){var e=t.length;if(e!==0)for(var i=0;i<e;i++){var o=t[i];(o.f&24576)===0&&Pa(o)&&(xl(o),o.deps===null&&o.first===null&&o.nodes_start===null&&(o.teardown===null?Jp(o):o.fn=null))}}function cd(t){Ma||(Ma=!0,queueMicrotask(nf));for(var e=Cl=t;e.parent!==null;){e=e.parent;var i=e.f;if((i&96)!==0){if((i&1024)===0)return;e.f^=1024}}bd.push(e)}function C$(t){for(var e=[],i=t;i!==null;){var o=i.f,r=(o&96)!==0,a=r&&(o&1024)!==0;if(!a&&(o&8192)===0){(o&4)!==0?e.push(i):r?i.f^=1024:Pa(i)&&xl(i);var l=i.first;if(l!==null){i=l;continue}}var d=i.parent;for(i=i.next;i===null&&d!==null;)i=d.next,d=d.parent}return e}function Tl(t){var e;for(t&&(Ma=!0,nf(),Ma=!0,e=t());;){if(zg(),bd.length===0)return Ma=!1,Cl=null,Ae&&($d=[]),e;Ma=!0,nf()}}function mo(){return gt(this,null,function*(){yield Promise.resolve(),Tl()})}function n(t){var e=t.f,i=(e&2)!==0;if(du!==null&&du.add(t),Nt!==null&&!hr){if(!(Qo!=null&&Qo[1].includes(t))||Qo[0]!==Nt){var o=Nt.deps;t.rv<lu&&(t.rv=lu,An===null&&o!==null&&o[_r]===t?_r++:An===null?An=[t]:(!Vs||!An.includes(t))&&An.push(t))}}else if(i&&t.deps===null&&t.effects===null){var r=t,a=r.parent;a!==null&&(a.f&256)===0&&(r.f^=256)}if(i&&(r=t,Pa(r)&&qp(r)),Ae&&fs&&!hr&&nd!==null&&Nt!==null&&nd.reaction===Nt)if(t.trace)t.trace();else{var l=Ls("TracedAt");if(l){var d=nd.entries.get(t);d===void 0&&(d={traces:[]},nd.entries.set(t,d));var s=d.traces[d.traces.length-1];l.stack!==(s==null?void 0:s.stack)&&d.traces.push(l)}}return Ms&&$l.has(t)?$l.get(t):t.v}function Tt(t){var e=hr;try{return hr=!0,t()}finally{hr=e}}var T$=-7169;function En(t,e){t.f=t.f&T$|e}function uu(t){if(!(typeof t!="object"||!t||t instanceof EventTarget)){if(Ko in t)cu(t);else if(!Array.isArray(t))for(let e in t){let i=t[e];typeof i=="object"&&i&&Ko in i&&cu(i)}}}function cu(t,e=new Set){if(typeof t=="object"&&t!==null&&!(t instanceof EventTarget)&&!e.has(t)){e.add(t),t instanceof Date&&t.getTime();for(let o in t)try{cu(t[o],e)}catch(r){}let i=Ca(t);if(i!==Object.prototype&&i!==Array.prototype&&i!==Map.prototype&&i!==Set.prototype&&i!==Date.prototype){let o=qc(i);for(let r in o){let a=o[r].get;if(a)try{a.call(t)}catch(l){}}}}}function rf(t,e){if(e){let i=document.body;t.autofocus=!0,kn(()=>{document.activeElement===i&&t.focus()})}}function yd(t){var e=Nt,i=bt;qi(null),po(null);try{return t()}finally{qi(e),po(i)}}var sf=new Set,pu=new Set;function Ra(t){if(!tt)return;t.removeAttribute("onload"),t.removeAttribute("onerror");let e=t.__e;e!==void 0&&(t.__e=void 0,queueMicrotask(()=>{t.isConnected&&t.dispatchEvent(e)}))}function af(t,e,i,o={}){function r(a){if(o.capture||Il.call(e,a),!a.cancelBubble)return yd(()=>i==null?void 0:i.call(this,a))}return t.startsWith("pointer")||t.startsWith("touch")||t==="wheel"?kn(()=>{e.addEventListener(t,r,o)}):e.addEventListener(t,r,o),r}function ut(t,e,i,o,r){var a={capture:o,passive:r},l=af(t,e,i,a);(e===document.body||e===window||e===document||e instanceof HTMLMediaElement)&&Lo(()=>{e.removeEventListener(t,l,a)})}function Ye(t){for(var e=0;e<t.length;e++)sf.add(t[e]);for(var i of pu)i(t)}function Il(t){var T;var e=this,i=e.ownerDocument,o=t.type,r=((T=t.composedPath)==null?void 0:T.call(t))||[],a=r[0]||t.target,l=0,d=t.__root;if(d){var s=r.indexOf(d);if(s!==-1&&(e===document||e===window)){t.__root=e;return}var u=r.indexOf(e);if(u===-1)return;s<=u&&(l=s)}if(a=r[l]||t.target,a!==e){uo(t,"currentTarget",{configurable:!0,get(){return a||i}});var m=Nt,p=bt;qi(null),po(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||t.target===a))if(pr(_)){var[x,...I]=_;x.apply(a,[t,...I])}else _.call(a,t)}catch(R){v?b.push(R):v=R}if(t.cancelBubble||y===e||y===null)break;a=y}if(v){for(let R of b)queueMicrotask(()=>{throw R});throw v}}finally{t.__root=e,delete t.currentTarget,qi(m),po(p)}}}var E$;function jg(){E$=void 0}function El(t){var e=document.createElement("template");return e.innerHTML=t.replaceAll("<!>","<!---->"),e.content}function Vo(t,e){var i=bt;i.nodes_start===null&&(i.nodes_start=t,i.nodes_end=e)}function L(t,e){var i=(e&1)!==0,o=(e&2)!==0,r,a=!t.startsWith("<!>");return()=>{if(tt)return Vo($t,null),$t;r===void 0&&(r=El(a?t:"<!>"+t),i||(r=Ci(r)));var l=o||ud?document.importNode(r,!0):r.cloneNode(!0);if(i){var d=Ci(l),s=l.lastChild;Vo(d,s)}else Vo(l,l);return l}}function A$(t,e,i="svg"){var o=!t.startsWith("<!>"),r=(e&1)!==0,a=`<${i}>${o?t:"<!>"+t}</${i}>`,l;return()=>{if(tt)return Vo($t,null),$t;if(!l){var d=El(a),s=Ci(d);if(r)for(l=document.createDocumentFragment();Ci(s);)l.appendChild(Ci(s));else l=Ci(s)}var u=l.cloneNode(!0);if(r){var m=Ci(u),p=u.lastChild;Vo(m,p)}else Vo(u,u);return u}}function Ie(t,e){return A$(t,e,"svg")}function gs(t=""){if(!tt){var e=Pn(t+"");return Vo(e,e),e}var i=$t;return i.nodeType!==fl&&(i.before(i=Pn()),xi(i)),Vo(i,i),i}function Ve(){if(tt)return Vo($t,null),$t;var t=document.createDocumentFragment(),e=document.createComment(""),i=Pn();return t.append(e,i),Vo(e,i),t}function $(t,e){if(tt){bt.nodes_end=$t,Gi();return}t!==null&&t.before(e)}var L$=/\r/g;function Zg(t){t=t.replace(L$,"");let e=5381,i=t.length;for(;i--;)e=(e<<5)-e^t.charCodeAt(i);return(e>>>0).toString(36)}function Jg(t){return t.endsWith("capture")&&t!=="gotpointercapture"&&t!=="lostpointercapture"}var M$=["beforeinput","click","change","dblclick","contextmenu","focusin","focusout","input","keydown","keyup","mousedown","mousemove","mouseout","mouseover","mouseup","pointerdown","pointermove","pointerout","pointerover","pointerup","touchend","touchmove","touchstart"];function eh(t){return M$.includes(t)}var V$=["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 R$={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 th(t){var e;return t=t.toLowerCase(),(e=R$[t])!=null?e:t}var DP=[...V$,"formNoValidate","isMap","noModule","playsInline","readOnly","value","volume","defaultValue","defaultChecked","srcObject","noValidate","allowFullscreen","disablePictureInPicture","disableRemotePlayback"];var N$=["touchstart","touchmove"];function ih(t){return N$.includes(t)}var O$=["$state","$state.raw","$derived","$derived.by"],BP=[...O$,"$state.snapshot","$props","$props.id","$bindable","$effect","$effect.pre","$effect.tracking","$effect.root","$inspect","$inspect().with","$inspect.trace","$host"];var D$=["textarea","script","style","title"];function oh(t){return D$.includes(t)}function fu(t){return t==null?void 0:t.replace(/\//g,"/​")}var xd=!0;function mu(t){xd=t}function ve(t,e){var o;var i=e==null?"":typeof e=="object"?e+"":e;i!==((o=t.__t)!=null?o:t.__t=t.nodeValue)&&(t.__t=i,t.nodeValue=i+"")}function es(t,e){return nh(t,e)}function df(t,e){var l;iu(),e.intro=(l=e.intro)!=null?l:!1;let i=e.target,o=tt,r=$t;try{for(var a=Ci(i);a&&(a.nodeType!==fr||a.data!==ea);)a=Go(a);if(!a)throw us;fo(!0),xi(a),Gi();let d=nh(t,Kt(ke({},e),{anchor:a}));if($t===null||$t.nodeType!==fr||$t.data!==Sa)throw na(),us;return fo(!1),d}catch(d){if(d===us)return e.recover===!1&&_g(),iu(),pd(i),fo(!1),es(t,e);throw d}finally{fo(o),xi(r),jg()}}var Pl=new Map;function nh(t,{target:e,anchor:i,props:o={},events:r,context:a,intro:l=!0}){iu();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=ih(b);e.addEventListener(b,Il,{passive:y});var _=Pl.get(b);_===void 0?(document.addEventListener(b,Il,{passive:y}),Pl.set(b,1)):Pl.set(b,_+1)}}};s(od(sf)),pu.add(s);var u=void 0,m=Bg(()=>{var p=i!=null?i:e.appendChild(Pn());return Di(()=>{if(a){B({});var v=Ft;v.c=a}r&&(o.$$events=r),tt&&Vo(p,null),xd=l,u=t(p,o)||{},xd=!0,tt&&(bt.nodes_end=$t),a&&H()}),()=>{var y;for(var v of d){e.removeEventListener(v,Il);var b=Pl.get(v);--b===0?(document.removeEventListener(v,Il),Pl.delete(v)):Pl.set(v,b)}pu.delete(s),p!==i&&((y=p.parentNode)==null||y.removeChild(p))}});return lf.set(u,m),u}var lf=new WeakMap;function Na(t,e){let i=lf.get(t);return i?(lf.delete(t),i(e)):(Ae&&Lg(),Promise.resolve())}function ii(t,e,...i){var o=t,r=ht,a;Yi(()=>{r!==(r=e())&&(a&&(Qi(a),a=null),Ae&&r==null&&bg(),a=Di(()=>r(o,...i)))},65536),tt&&(o=$t)}if(Ae){let t=function(e){if(!(e in globalThis)){let i;Object.defineProperty(globalThis,e,{configurable:!0,get:()=>{if(i!==void 0)return i;xg(e)},set:o=>{i=o}})}};U$=t,t("$state"),t("$effect"),t("$derived"),t("$inspect"),t("$props"),t("$bindable")}var U$;function Mt(t){Ft===null&&gl("onMount"),ps&&Ft.l!==null?F$(Ft).m.push(t):De(()=>{let e=Tt(t);if(typeof e=="function")return e})}function cn(t){Ft===null&&gl("onDestroy"),Mt(()=>()=>Tt(t))}function F$(t){var i;var e=t.l;return(i=e.u)!=null?i:e.u={a:[],b:[],m:[]}}var rh=new Map;function sh(t,e){var i=rh.get(t);i||(i=new Set,rh.set(t,i)),i.add(e)}function V(t,e,[i,o]=[0,0]){tt&&i===0&&Gi();var r=t,a=null,l=null,d=to,s=i>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(i===0){let x=tu(r);x===ea?o=0:x===ta?o=1/0:(o=parseInt(x.substring(1)),o!==o&&(o=d?1/0:-1))}let _=o>i;!!d===_&&(r=ka(),xi(r),fo(!1),y=!0,o=-1)}d?(a?Ns(a):b&&(a=Di(()=>b(r))),l&&jn(l,()=>{l=null})):(l?Ns(l):b&&(l=Di(()=>b(r,[i+1,o]))),a&&jn(a,()=>{a=null})),y&&fo(!0)};Yi(()=>{u=!1,e(m),u||p(null,null)},s),tt&&(r=$t)}function Os(t,e,i){tt&&Gi();var o=t,r=to,a,l=ms()?pg:ml;Yi(()=>{l(r,r=e())&&(a&&jn(a),a=Di(()=>i(o)))}),tt&&(o=$t)}var sa=null;function pf(t){sa=t}function wd(t,e){return e}function K$(t,e,i,o){for(var r=[],a=e.length,l=0;l<a;l++)su(e[l].e,r,!0);var d=a>0&&r.length===0&&i!==null;if(d){var s=i.parentNode;pd(s),s.append(i),o.clear(),ra(t,e[0].prev,e[a-1].next)}ef(r,()=>{for(var u=0;u<a;u++){var m=e[u];d||(o.delete(m.k),ra(t,m.prev,m.next)),Qi(m.e,!d)}})}function bi(t,e,i,o,r,a=null){var l=t,d={flags:e,items:new Map,first:null},s=(e&4)!==0;if(s){var u=t;l=tt?xi(Ci(u)):u.appendChild(Pn())}tt&&Gi();var m=null,p=!1,v=In(()=>{var b=i();return pr(b)?b:b==null?[]:od(b)});Yi(()=>{var b=n(v),y=b.length;if(p&&y===0)return;p=y===0;let _=!1;if(tt){var x=tu(l)===ta;x!==(y===0)&&(l=ka(),xi(l),fo(!1),_=!0)}if(tt){for(var I=null,T,R=0;R<y;R++){if($t.nodeType===fr&&$t.data===Sa){l=$t,_=!0,fo(!1);break}var A=b[R],P=o(A,R);T=dh($t,d,I,null,A,P,R,r,e,i),d.items.set(P,T),I=T}y>0&&xi(ka())}tt||q$(b,d,l,r,e,o,i),a!==null&&(y===0?m?Ns(m):m=Di(()=>a(l)):m!==null&&jn(m,()=>{m=null})),_&&fo(!0),n(v)}),tt&&(l=$t)}function q$(t,e,i,o,r,a,l){var J,we,me,ee;var d=(r&8)!==0,s=(r&3)!==0,u=t.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=t[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=t[P],R=a(T,P),A=m.get(R),A===void 0){var E=v?v.e.nodes_start:i;y=dh(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&&Q$(A,T,P,r),(A.e.f&8192)!==0&&(Ns(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)ah(x[F],z,i);for(F=0;F<I.length;F+=1)b.delete(I[F]);ra(e,U.prev,X.next),ra(e,y,U),ra(e,X,z),v=z,y=X,P-=1,x=[],I=[]}else b.delete(A),ah(A,v,i),ra(e,A.prev,A.next),ra(e,A,y===null?e.first:y.next),ra(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?[]:od(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?i: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()}K$(e,ae,re,m)}}d&&kn(()=>{var _e;if(_!==void 0)for(A of _)(_e=A.a)==null||_e.apply()}),bt.first=e.first&&e.first.e,bt.last=y&&y.e}function Q$(t,e,i,o){(o&1)!==0&&yl(t.v,e),(o&2)!==0?yl(t.i,i):t.i=i}function dh(t,e,i,o,r,a,l,d,s,u){var m=sa,p=(s&1)!==0,v=(s&16)===0,b=p?v?vs(r,!1,!1):Vr(r):r,y=(s&2)===0?l:Vr(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:i,next:o};sa=_;try{return _.e=Di(()=>d(t,b,y,u),tt),_.e.prev=i&&i.e,_.e.next=o&&o.e,i===null?e.first=_:(i.next=_,i.e.next=_.e),o!==null&&(o.prev=_,o.e.prev=_.e),_}finally{sa=m}}function ah(t,e,i){for(var o=t.next?t.next.e.nodes_start:i,r=e?e.e.nodes_start:i,a=t.e.nodes_start;a!==o;){var l=Go(a);r.before(a),a=l}}function ra(t,e,i){e===null?t.first=i:(e.next=i,e.e.next=i&&i.e),i!==null&&(i.prev=e,i.e.prev=e&&e.e)}function G$(t,e,i){var a,l;if(!e||e===Zg(String(i!=null?i:"")))return;let o,r=(a=t.__svelte_meta)==null?void 0:a.loc;r?o=`near ${r.file}:${r.line}:${r.column}`:(l=mr)!=null&&l[qn]&&(o=`in ${mr[qn]}`),Ag(fu(o))}function Sd(t,e,i=!1,o=!1,r=!1){var a=t,l="";D(()=>{var b;var d=bt;if(l===(l=(b=e())!=null?b:"")){tt&&Gi();return}if(d.nodes_start!==null&&(Zp(d.nodes_start,d.nodes_end),d.nodes_start=d.nodes_end=null),l!==""){if(tt){for(var s=$t.data,u=Gi(),m=u;u!==null&&(u.nodeType!==fr||u.data!=="");)m=u,u=Go(u);if(u===null)throw na(),us;Ae&&!r&&G$(u.parentNode,s,l),Vo($t,m),a=xi(u);return}var p=l+"";i?p=`<svg>${p}</svg>`:o&&(p=`<math>${p}</math>`);var v=El(p);if((i||o)&&(v=Ci(v)),Vo(Ci(v),v.lastChild),i||o)for(;Ci(v);)a.before(Ci(v));else a.before(v)}})}function Bi(t,e,i){tt&&Gi();var o=t,r,a;Yi(()=>{r!==(r=e())&&(a&&(jn(a),a=null),r&&(a=Di(()=>i(o,r))))},65536),tt&&(o=$t)}function Oa(t,e,i,o,r,a){var y;let l=tt;tt&&Gi();var d=Ae&&a&&((y=Ft)==null?void 0:y.function[qn]),s,u,m=null;tt&&$t.nodeType===Gc&&(m=$t,Gi());var p=tt?$t:t,v,b=sa;Yi(()=>{let _=e()||null;var x=r?r():i||_==="svg"?Wc:null;if(_!==s){var I=sa;pf(b),v&&(_===null?jn(v,()=>{v=null,u=null}):_===u?Ns(v):(Qi(v),mu(!1))),_&&_!==u&&(v=Di(()=>{if(m=tt?m:x?document.createElementNS(x,_):document.createElement(_),Ae&&a&&(m.__svelte_meta={loc:{file:d,line:a[0],column:a[1]}}),Vo(m,m),o){tt&&oh(_)&&m.append(document.createComment(""));var T=tt?Ci(m):m.appendChild(Pn());tt&&(T===null?fo(!1):xi(T)),o(m,T)}bt.nodes_end=m,p.before(m)})),s=_,s&&(u=s),mu(!0),pf(I)}},65536),l&&(fo(!0),xi(p))}var mf;function ch(t){return mf=t.target,new ff(t)}var Ds,Rr,ff=class{constructor(e){Js(this,Ds);Js(this,Rr);var a,l;var i=new Map,o=(d,s)=>{var u=vs(s,!1,!1);return i.set(d,u),u};let r=new Proxy(Kt(ke({},e.props||{}),{$$events:{}}),{get(d,s){var u;return n((u=i.get(s))!=null?u:o(s,Reflect.get(d,s)))},has(d,s){var u;return s===pl?!0:(n((u=i.get(s))!=null?u:o(s,Reflect.get(d,s))),Reflect.has(d,s))},set(d,s,u){var m;return N((m=i.get(s))!=null?m:o(s,u),u),Reflect.set(d,s,u)}});ul(this,Rr,(e.hydrate?df: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)&&Tl(),ul(this,Ds,r.$$events);for(let d of Object.keys(Oi(this,Rr)))d==="$set"||d==="$destroy"||d==="$on"||uo(this,d,{get(){return Oi(this,Rr)[d]},set(s){Oi(this,Rr)[d]=s},enumerable:!0});Oi(this,Rr).$set=d=>{Object.assign(r,d)},Oi(this,Rr).$destroy=()=>{Na(Oi(this,Rr))}}$set(e){Oi(this,Rr).$set(e)}$on(e,i){Oi(this,Ds)[e]=Oi(this,Ds)[e]||[];let o=(...r)=>i.call(this,...r);return Oi(this,Ds)[e].push(o),()=>{Oi(this,Ds)[e]=Oi(this,Ds)[e].filter(r=>r!==o)}}$destroy(){Oi(this,Rr).$destroy()}};Ds=new WeakMap,Rr=new WeakMap;function Q(t,e){kn(()=>{var r,a,l;var i=t.getRootNode(),o=i.host?i:(l=(r=i.head)!=null?r:i.ownerDocument.head)!=null?l:(a=mf)==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&&sh(e.hash,d)}})}function Bs(t,e){var i=void 0,o;Yi(()=>{i!==(i=e())&&(o&&(Qi(o),o=null),i&&(o=Di(()=>{Mo(()=>i(t))})))})}function uh(t){var e,i,o="";if(typeof t=="string"||typeof t=="number")o+=t;else if(typeof t=="object")if(Array.isArray(t)){var r=t.length;for(e=0;e<r;e++)t[e]&&(i=uh(t[e]))&&(o&&(o+=" "),o+=i)}else for(i in t)t[i]&&(o&&(o+=" "),o+=i);return o}function ph(){for(var t,e,i=0,o="",r=arguments.length;i<r;i++)(t=arguments[i])&&(e=uh(t))&&(o&&(o+=" "),o+=e);return o}function Cd(t){return typeof t=="object"?ph(t):t!=null?t:""}var fh=[...`
44
- \r\f \v\uFEFF`];function vh(t,e,i){var o=t==null?"":""+t;if(e&&(o=o?o+" "+e:e),i){for(var r in i)if(i[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||fh.includes(o[l-1]))&&(d===o.length||fh.includes(o[d]))?o=(l===0?"":o.substring(0,l))+o.substring(d+1):l=d}}return o===""?null:o}function mh(t,e=!1){var i=e?" !important;":";",o="";for(var r in t){var a=t[r];a!=null&&a!==""&&(o+=" "+r+": "+a+i)}return o}function vf(t){return t[0]!=="-"||t[1]!=="-"?t.toLowerCase():t}function gh(t,e){if(e){var i="",o,r;if(Array.isArray(e)?(o=e[0],r=e[1]):o=e,t){t=String(t).replaceAll(/\s*\/\*.*?\*\/\s*/g,"").trim();var a=!1,l=0,d=!1,s=[];o&&s.push(...Object.keys(o).map(vf)),r&&s.push(...Object.keys(r).map(vf));var u=0,m=-1;let _=t.length;for(var p=0;p<_;p++){var v=t[p];if(d?v==="/"&&t[p-1]==="*"&&(d=!1):a?a===v&&(a=!1):v==="/"&&t[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=vf(t.substring(u,m).trim());if(!s.includes(b)){v!==";"&&p++;var y=t.substring(u,p).trim();i+=" "+y+";"}}u=p+1,m=-1}}}}return o&&(i+=mh(o)),r&&(i+=mh(r,!0)),i=i.trim(),i===""?null:i}return t==null?null:String(t)}function oe(t,e,i,o,r,a){var l=t.__className;if(tt||l!==i||l===void 0){var d=vh(i,o,a);(!tt||d!==t.getAttribute("class"))&&(d==null?t.removeAttribute("class"):e?t.className=d:t.setAttribute("class",d)),t.__className=i}else if(a&&r!==a)for(var s in a){var u=!!a[s];(r==null||u!==!!r[s])&&t.classList.toggle(s,u)}return a}function gf(t,e={},i,o){for(var r in i){var a=i[r];e[r]!==a&&(i[r]==null?t.style.removeProperty(r):t.style.setProperty(r,a,o))}}function qe(t,e,i,o){var r=t.__style;if(tt||r!==e){var a=gh(e,o);(!tt||a!==t.getAttribute("style"))&&(a==null?t.removeAttribute("style"):t.style.cssText=a),t.__style=e}else o&&(Array.isArray(o)?(gf(t,i==null?void 0:i[0],o[0]),gf(t,i==null?void 0:i[1],o[1],"important")):gf(t,i,o));return o}function Td(t,e,i){if(t.multiple){if(e==null)return;if(!pr(e))return Mg();for(var o of t.options)o.selected=e.includes(hh(o));return}for(o of t.options){var r=hh(o);if(Fp(r,e)){o.selected=!0;return}}(!i||e!==void 0)&&(t.selectedIndex=-1)}function hf(t){var e=new MutationObserver(()=>{Td(t,t.__value)});e.observe(t,{childList:!0,subtree:!0,attributes:!0,attributeFilter:["value"]}),Lo(()=>{e.disconnect()})}function hh(t){return"__value"in t?t.__value:t.value}var kl=Symbol("class"),Al=Symbol("style"),$h=Symbol("is custom element"),yh=Symbol("is html");function xh(t,e){e?t.hasAttribute("selected")||t.setAttribute("selected",""):t.removeAttribute("selected")}function Re(t,e,i,o){var r=Sh(t);if(tt&&(r[e]=t.getAttribute(e),e==="src"||e==="srcset"||e==="href"&&t.nodeName==="LINK")){o||i1(t,e,i!=null?i:"");return}r[e]!==(r[e]=i)&&(e==="loading"&&(t[ug]=i),i==null?t.removeAttribute(e):typeof i!="string"&&Ch(t).includes(e)?t[e]=i:t.setAttribute(e,i))}function wh(t,e,i,o,r=!1){var A;var a=Sh(t),l=a[$h],d=!a[yh];let s=tt&&l;s&&fo(!1);var u=e||{},m=t.tagName==="OPTION";for(var p in e)p in i||(i[p]=null);i.class?i.class=Cd(i.class):(o||i[kl])&&(i.class=null),i[Al]&&((A=i.style)!=null||(i.style=null));var v=Ch(t);for(let P in i){let E=i[P];if(m&&P==="value"&&E==null){t.value=t.__value="",u[P]=E;continue}if(P==="class"){var b=t.namespaceURI==="http://www.w3.org/1999/xhtml";oe(t,b,E,o,e==null?void 0:e[kl],i[kl]),u[P]=E,u[kl]=i[kl];continue}if(P==="style"){qe(t,E,e==null?void 0:e[Al],i[Al]),u[P]=E,u[Al]=i[Al];continue}var y=u[P];if(!(E===y&&!(E===void 0&&t.hasAttribute(P)))){u[P]=E;var _=P[0]+P[1];if(_!=="$$")if(_==="on"){let z={},F="$$"+P,U=P.slice(2);var x=eh(U);if(Jg(U)&&(U=U.slice(0,-7),z.capture=!0),!x&&y){if(E!=null)continue;t.removeEventListener(U,u[F],z),u[F]=null}if(E!=null)if(x)t[`__${U}`]=E,Ye([U]);else{let X=function(ae){u[P].call(this,ae)};var R=X;u[F]=af(U,t,X,z)}else x&&(t[`__${U}`]=void 0)}else if(P==="style")Re(t,P,E);else if(P==="autofocus")rf(t,!!E);else if(!l&&(P==="__value"||P==="value"&&E!=null))t.value=t.__value=E;else if(P==="selected"&&m)xh(t,E);else{var I=P;d||(I=th(I));var T=I==="defaultValue"||I==="defaultChecked";if(E==null&&!l&&!T)if(a[P]=null,I==="value"||I==="checked"){let z=t,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 t.removeAttribute(P);else T||v.includes(I)&&(l||typeof E!="string")?t[I]=E:typeof E!="function"&&Re(t,I,E,r)}}}return s&&fo(!0),u}function io(t,e,i=[],o,r=!1,a=Xr){let l=i.map(a);var d=void 0,s={},u=t.nodeName==="SELECT",m=!1;if(Yi(()=>{var v=e(...l.map(n)),b=wh(t,d,v,o,r);m&&u&&"value"in v&&Td(t,v.value,!1);for(let _ of Object.getOwnPropertySymbols(s))v[_]||Qi(s[_]);for(let _ of Object.getOwnPropertySymbols(v)){var y=v[_];_.description===Mp&&(!d||y!==d[_])&&(s[_]&&Qi(s[_]),s[_]=Di(()=>Bs(t,()=>y))),b[_]=y}d=b}),u){var p=t;Mo(()=>{Td(p,d.value),hf(p)})}m=!0}function Sh(t){var e;return(e=t.__attributes)!=null?e:t.__attributes={[$h]:t.nodeName.includes("-"),[yh]:t.namespaceURI===ng}}var _h=new Map;function Ch(t){var e=_h.get(t.nodeName);if(e)return e;_h.set(t.nodeName,e=[]);for(var i,o=t,r=Element.prototype;r!==o;){i=qc(o);for(var a in i)i[a].set&&e.push(a);o=Ca(o)}return e}function i1(t,e,i){var o;Ae&&(e==="srcset"&&o1(t,i)||_f((o=t.getAttribute(e))!=null?o:"",i)||kg(e,t.outerHTML.replace(t.innerHTML,t.innerHTML&&"..."),String(i)))}function _f(t,e){return t===e?!0:new URL(t,document.baseURI).href===new URL(e,document.baseURI).href}function bh(t){return t.split(",").map(e=>e.trim().split(" ").filter(Boolean))}function o1(t,e){var i=bh(t.srcset),o=bh(e);return o.length===i.length&&o.every(([r,a],l)=>a===i[l][1]&&(_f(i[l][0],r)||_f(r,i[l][0])))}var n1=Kc?()=>performance.now():()=>Date.now(),ts={tick:t=>(Kc?requestAnimationFrame:ht)(t),now:()=>n1(),tasks:new Set};function Th(){let t=ts.now();ts.tasks.forEach(e=>{e.c(t)||(ts.tasks.delete(e),e.f())}),ts.tasks.size!==0&&ts.tick(Th)}function Ih(t){let e;return ts.tasks.size===0&&ts.tick(Th),{promise:new Promise(i=>{ts.tasks.add(e={c:t,f:i})}),abort(){ts.tasks.delete(e)}}}function vu(t,e){yd(()=>{t.dispatchEvent(new CustomEvent(e))})}function l1(t){if(t==="float")return"cssFloat";if(t==="offset")return"cssOffset";if(t.startsWith("--"))return t;let e=t.split("-");return e.length===1?e[0]:e[0]+e.slice(1).map(i=>i[0].toUpperCase()+i.slice(1)).join("")}function Eh(t){let e={},i=t.split(";");for(let o of i){let[r,a]=o.split(":");if(!r||a===void 0)break;let l=l1(r.trim());e[l]=a.trim()}return e}var d1=t=>t;function is(t,e,i,o){var R;var r=(t&1)!==0,a=(t&2)!==0,l=r&&a,d=(t&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=bt;qi(null),po(null);try{return u!=null?u:u=i()(e,(E=o==null?void 0:o())!=null?E:{},{direction:s})}finally{qi(A),po(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=bf(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=bf(e,y(),v,0,()=>{vu(e,"outroend"),A==null||A()})},stop:()=>{v==null||v.abort(),b==null||b.abort()}},x=bt;if(((R=x.transitions)!=null?R:x.transitions=[]).push(_),r&&xd){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&&Mo(()=>{Tt(()=>_.in())})}}function bf(t,e,i,o,r){var a=o===1;if(ia(e)){var l,d=!1;return kn(()=>{if(!d){var x=e({direction:a?"in":"out"});l=bf(t,x,i,o,r)}}),{abort:()=>{d=!0,l==null||l.abort()},deactivate:()=>l.deactivate(),reset:()=>l.reset(),t:()=>l.t()}}if(i==null||i.deactivate(),!(e!=null&&e.duration))return r(),{abort:ht,deactivate:ht,reset:ht,t:()=>o};let{delay:s=0,css:u,tick:m,easing:p=d1}=e;var v=[];if(a&&i===void 0&&(m&&m(0,1),u)){var b=Eh(u(0,1));v.push(b,b)}var y=()=>1-o,_=t.animate(v,{duration:s,fill:"forwards"});return _.onfinish=()=>{var U;_.cancel();var x=(U=i==null?void 0:i.t())!=null?U:1-o;i==null||i.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=Eh(u(z,1-z));R.push(F),A||(A=F.overflow==="hidden")}A&&(t.style.overflow="hidden"),y=()=>{var X=_.currentTime;return x+I*p(X/T)},m&&Ih(()=>{if(_.playState!=="running")return!1;var X=y();return m(X,1-X),!0})}_=t.animate(R,{duration:T,fill:"forwards"}),_.onfinish=()=>{y=()=>o,m==null||m(o,1-o),r()}},{abort:()=>{_&&(_.cancel(),_.effect=null,_.onfinish=ht)},deactivate:()=>{r=ht},reset:()=>{o===0&&(m==null||m(1,0))},t:()=>y()}}function $f(t,e,i){var o=Wo(t,e);o&&o.set&&(t[e]=i,Lo(()=>{t[e]=null}))}var aa,Ll,Id,hu,Ph,_u=class _u{constructor(e){Js(this,hu);Js(this,aa,new WeakMap);Js(this,Ll);Js(this,Id);ul(this,Id,e)}observe(e,i){var o=Oi(this,aa).get(e)||new Set;return o.add(i),Oi(this,aa).set(e,o),ig(this,hu,Ph).call(this).observe(e,Oi(this,Id)),()=>{var r=Oi(this,aa).get(e);r.delete(i),r.size===0&&(Oi(this,aa).delete(e),Oi(this,Ll).unobserve(e))}}};aa=new WeakMap,Ll=new WeakMap,Id=new WeakMap,hu=new WeakSet,Ph=function(){var e;return(e=Oi(this,Ll))!=null?e:ul(this,Ll,new ResizeObserver(i=>{for(var o of i){_u.entries.set(o.target,o);for(var r of Oi(this,aa).get(o.target)||[])r(o)}}))},ur(_u,"entries",new WeakMap);var yf=_u;var c1=new yf({box:"border-box"});function Ln(t,e,i){var o=c1.observe(t,()=>i(t[e]));Mo(()=>(Tt(()=>i(t[e])),o))}function kh(t,e){return t===e||(t==null?void 0:t[Ko])===e}function Ze(t={},e,i,o){return Mo(()=>{var r,a;return Yo(()=>{r=a,a=(o==null?void 0:o())||[],Tt(()=>{t!==i(...a)&&(e(t,...a),r&&kh(i(...r),t)&&e(null,...r))})}),()=>{kn(()=>{a&&kh(i(...a),t)&&e(null,...a)})}}),t}function ho(t=!1){let e=Ft,i=e.l.u;if(!i)return;let o=()=>uu(e.s);if(t){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)}i.b.length&&vd(()=>{Ah(e,o),oa(i.b)}),De(()=>{let r=Tt(()=>i.m.map(cg));return()=>{for(let a of r)typeof a=="function"&&a()}}),i.a.length&&De(()=>{Ah(e,o),oa(i.a)})}function Ah(t,e){if(t.l.s)for(let i of t.l.s)n(i);e()}function Ed(t,e,i){if(t==null)return e(void 0),i&&i(void 0),ht;let o=Tt(()=>t.subscribe(e,i));return o.unsubscribe?()=>o.unsubscribe():o}var Ml=[];function Nr(t,e){return{subscribe:de(t,e).subscribe}}function de(t,e=ht){let i=null,o=new Set;function r(d){if(ml(t,d)&&(t=d,i)){let s=!Ml.length;for(let u of o)u[1](),Ml.push(u,t);if(s){for(let u=0;u<Ml.length;u+=2)Ml[u][0](Ml[u+1]);Ml.length=0}}}function a(d){r(d(t))}function l(d,s=ht){let u=[d,s];return o.add(u),o.size===1&&(i=e(r,a)||ht),d(t),()=>{o.delete(u),o.size===0&&i&&(i(),i=null)}}return{set:r,update:a,subscribe:l}}function mi(t,e,i){let o=!Array.isArray(t),r=o?[t]:t;if(!r.every(Boolean))throw new Error("derived() expects stores as input, got a falsy value");let a=e.length<2;return Nr(i,(l,d)=>{let s=!1,u=[],m=0,p=ht,v=()=>{if(m)return;p();let y=e(o?u[0]:u,l,d);a?l(y):p=typeof y=="function"?y:ht},b=r.map((y,_)=>Ed(y,x=>{u[_]=x,m&=~(1<<_),s&&v()},()=>{m|=1<<_}));return s=!0,v(),function(){oa(b),p(),s=!1}})}function ye(t){let e;return Ed(t,i=>e=i)(),e}var bu=!1,xf=Symbol();function w(t,e,i){var a;let o=(a=i[e])!=null?a:i[e]={store:null,source:vs(void 0),unsubscribe:ht};if(o.store!==t&&!(xf in i))if(o.unsubscribe(),o.store=t!=null?t:null,t==null)o.source.v=void 0,o.unsubscribe=ht;else{var r=!0;o.unsubscribe=Ed(t,l=>{r?o.source.v=l:N(o.source,l)}),r=!1}return t&&xf in i?ye(t):n(o.source)}function Oe(){let t={};function e(){Lo(()=>{for(var i in t)t[i].unsubscribe();uo(t,xf,{enumerable:!1,value:!0})})}return[t,e]}function wf(t){var e=bu;try{return bu=!1,[t(),bu]}finally{bu=e}}var h1={get(t,e){if(!t.exclude.includes(e))return t.props[e]},set(t,e){return Ae&&yg(`${t.name}.${String(e)}`),!1},getOwnPropertyDescriptor(t,e){if(!t.exclude.includes(e)&&e in t.props)return{enumerable:!0,configurable:!0,value:t.props[e]}},has(t,e){return t.exclude.includes(e)?!1:e in t.props},ownKeys(t){return Reflect.ownKeys(t.props).filter(e=>!t.exclude.includes(e))}};function Mn(t,e,i){return new Proxy(Ae?{props:t,exclude:e,name:i,other:{},to_proxy:[]}:{props:t,exclude:e},h1)}var _1={get(t,e){let i=t.props.length;for(;i--;){let o=t.props[i];if(ia(o)&&(o=o()),typeof o=="object"&&o!==null&&e in o)return o[e]}},set(t,e,i){let o=t.props.length;for(;o--;){let r=t.props[o];ia(r)&&(r=r());let a=Wo(r,e);if(a&&a.set)return a.set(i),!0}return!1},getOwnPropertyDescriptor(t,e){let i=t.props.length;for(;i--;){let o=t.props[i];if(ia(o)&&(o=o()),typeof o=="object"&&o!==null&&e in o){let r=Wo(o,e);return r&&!r.configurable&&(r.configurable=!0),r}}},has(t,e){if(e===Ko||e===pl)return!1;for(let i of t.props)if(ia(i)&&(i=i()),i!=null&&e in i)return!0;return!1},ownKeys(t){let e=[];for(let i of t.props)if(ia(i)&&(i=i()),!!i){for(let o in i)e.includes(o)||e.push(o);for(let o of Object.getOwnPropertySymbols(i))e.includes(o)||e.push(o)}return e}};function os(...t){return new Proxy({props:t},_1)}function Lh(t){var e,i;return(i=(e=t.ctx)==null?void 0:e.d)!=null?i:!1}function h(t,e,i,o){var z,F;var r=(i&1)!==0,a=!ps||(i&2)!==0,l=(i&8)!==0,d=(i&16)!==0,s=!1,u;l?[u,s]=wf(()=>t[e]):u=t[e];var m=Ko in t||pl in t,p=l&&((F=(z=Wo(t,e))==null?void 0:z.set)!=null?F:m&&e in t&&(U=>t[e]=U))||void 0,v=o,b=!0,y=!1,_=()=>(y=!0,b&&(b=!1,d?v=Tt(o):v=o),v);u===void 0&&o!==void 0&&(p&&a&&$g(e),u=_(),p&&p(u));var x;if(a)x=()=>{var U=t[e];return U===void 0?_():(b=!0,y=!1,U)};else{var I=(r?Xr:In)(()=>t[e]);I.f|=131072,x=()=>{var U=n(I);return U!==void 0&&(v=void 0),U===void 0?v:U}}if((i&4)===0&&a)return x;if(p){var T=t.$$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=vs(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=vl),function(U,X){if(du!==null&&(R=A,x(),n(P)),arguments.length>0){let ae=X?n(E):a&&l?li(U):U;if(!E.equals(ae)){if(R=!0,N(P,ae),y&&v!==void 0&&(v=ae),Lh(E))return U;Tt(()=>n(E))}return U}return Lh(E)?E.v:n(E)}}var b1;typeof HTMLElement=="function"&&(b1=class extends HTMLElement{constructor(e,i,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=i,o&&this.attachShadow({mode:"open"})}addEventListener(e,i,o){if(this.$$l[e]=this.$$l[e]||[],this.$$l[e].push(i),this.$$c){let r=this.$$c.$on(e,i);this.$$l_u.set(i,r)}super.addEventListener(e,i,o)}removeEventListener(e,i,o){if(super.removeEventListener(e,i,o),this.$$c){let r=this.$$l_u.get(i);r&&(r(),this.$$l_u.delete(i))}}connectedCallback(){return gt(this,null,function*(){if(this.$$cn=!0,!this.$$c){let i=function(a){return l=>{let d=document.createElement("slot");a!=="default"&&(d.name=a),$(l,d)}};var e=i;if(yield Promise.resolve(),!this.$$cn||this.$$c)return;let o={},r=$1(this);for(let a of this.$$s)a in r&&(a==="default"&&!this.$$d.children?(this.$$d.children=i(a),o.default=!0):o[a]=i(a));for(let a of this.attributes){let l=this.$$g_p(a.name);l in this.$$d||(this.$$d[l]=Sf(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=ch({component:this.$$ctor,target:this.shadowRoot||this,props:Kt(ke({},this.$$d),{$$slots:o,$$host:this})}),this.$$me=ru(()=>{Yo(()=>{var a;this.$$r=!0;for(let l of Vp(this.$$c)){if(!((a=this.$$p_d[l])!=null&&a.reflect))continue;this.$$d[l]=this.$$c[l];let d=Sf(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,i,o){var r;this.$$r||(e=this.$$g_p(e),this.$$d[e]=Sf(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 Vp(this.$$p_d).find(i=>this.$$p_d[i].attribute===e||!this.$$p_d[i].attribute&&i.toLowerCase()===e)||e}});function Sf(t,e,i,o){var a;let r=(a=i[t])==null?void 0:a.type;if(e=r==="Boolean"&&typeof e!="boolean"?e!=null:e,!o||!i[t])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 $1(t){let e={};return t.childNodes.forEach(i=>{e[i.slot||"default"]=!0}),e}var Mh="5";var Vh,Rh,Nh;typeof window!="undefined"&&((Nh=(Rh=(Vh=window.__svelte)!=null?Vh:window.__svelte={}).v)!=null?Nh:Rh.v=new Set).add(Mh);import{areValidLiveRecordSources as KT,clientChecker as Rv}from"@vkontakte/videoplayer-core/es2015";import"@vkontakte/videoplayer-core/es2015";import{noop as qb,safeStorage as qT,throttleFn as QT}from"@vkontakte/videoplayer-shared/es2015";import{SeekAction as GT}from"@vkontakte/videoplayer-statistics/es2015";import{InterfaceLanguage as y1,fillWithDefault as x1,VideoQuality as Oh}from"@vkontakte/videoplayer-shared/es2015";var w1={isMobile:void 0,disableInvisibleComponentsTimeout:500,debugLog:!1,devNullLog:!1,defaultLanguage:y1.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:Oh.Q_480P,highQualityLimit:Oh.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:[]},Dh=t=>x1(t,w1),Bh=t=>_l("ui-config",t),Vt=()=>hl("ui-config");var Pd="vk_player_debug_panel_opened";var Hh="videoplayer",Fh="videoplayer";var hs={KeyF:"f",KeyK:"k",KeyC:"c",KeyM:"m"},Uh=new Set(["ArrowLeft","ArrowRight","KeyL","KeyJ"]),zh=new Set(["Tab","Space","ArrowLeft","ArrowRight","ArrowUp","ArrowDown"]),Wh=new Set(["ShiftRight","ShiftLeft"]);var Kh=["TIMELINE"],kd=[...Kh,"GRAPH_BUTTON"],Cf=[...Kh,"PLAY_BUTTON"],Ad=[...kd,"PLAY_BUTTON"];var _s=(a=>(a.XS="xs",a.S="s",a.M="m",a.L="l",a.XL="xl",a))(_s||{}),Ld={xs:0,s:1,m:2,l:3,xl:4};import{assertNonNullable as qh,VERSION as S1}from"@vkontakte/videoplayer-shared/es2015";import{VERSION as C1}from"@vkontakte/videoplayer-core/es2015";import{VERSION as T1}from"@vkontakte/videoplayer-statistics/es2015";var $u="prod",Vl="1.1.82-dev.a57718f4.0";var Ba=(t,e,i)=>{let o=document.createElement("a");o.href=t,o.download=`${e}.${i}`,o.style.display="none",o.click()};var Qh=Symbol("storeContext"),Gh=Symbol("microStoresContext"),Yh=(t,e)=>{_l(Qh,t),_l(Gh,e),$u==="dev"&&(window.app={store:t,microStores:e})},be=()=>{let t=hl(Qh);return qh(t,"Store context is empty!"),t},_o=()=>{let t=hl(Gh);return qh(t,"MicroStores context is empty!"),t},oi=(t,e)=>xu(t,t.getValue(),e),xu=(t,e,i)=>Nr(e,o=>{let r=t.subscribe(a=>{o(a),i==null||i(a)});return()=>r.unsubscribe()}),jh=(t,e,i,o,r=["meta config not provided"])=>{var F,U,X,ae,Z,re,J,we,me;let a=t.info,{width:l,height:d}=ye(i.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=`${Vl} (core: ${C1}, stat: ${T1}, shared: ${S1})`,v=ye(i.state.errorLog$),b=v.length?`
45
- `+v.map((ee,_e)=>{var Qe;let Ce=`${_e}) Type: ${ee.id}
46
- `,ge=`Message: ${ee.message} (${ee.thrown})
47
- `,pe=`Trace: ${(Qe=ee.thrown)==null?void 0:Qe.stack}
48
- `;return Ce+ge+pe}).join(`
49
- `):void 0,y=i.state.isAudioDisabled?"disabled":ye(i.state.isAudioAvailable$)?void 0:"unavailable",_=t.info.currentVideoStream$.getValue(),x=t.info.currentAudioStream$.getValue(),I=[];_&&I.push(`Video: ${(Z=_==null?void 0:_.codec)!=null?Z:""}`+(_!=null&&_.hdr?" (HDR)":"")),x&&I.push(`Audio: ${(re=x==null?void 0:x.codec)!=null?re:""}`+(x!=null&&x.language?` (${x.language})`:""));let T=a.currentQuality$.getValue(),R="";if(T){let ee=a.availableQualitiesFps$.getValue()[T];R=ee?`${ee}fps`:""}let A=a.httpConnectionType$.getValue(),P=(we=(J=a.currentBuffer$.getValue())==null?void 0:J.end)!=null?we:0,E=Math.max(P-ye(i.state.positionExact$),0),z={Version:p,Browser:navigator.userAgent,Config:r.join(", "),"United video id":String(i.videoId),TraceId:o,VSID:ye(i.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} ${T!=null?T:""} ${R}`,"Available qualities":a.availableQualities$.getValue().join(", "),Audio:y,Position:`${ye(i.state.positionExact$)}s`,Buffer:`${E}s`,State:`${ye(i.playerPhase)} ${(me=a.playbackState$.getValue())!=null?me:""}`,"Player size":`${l}x${d}`,URL:window.location.href,Errors:b};return Object.entries(z).filter(([ee,_e])=>_e!==void 0).map(([ee,_e])=>`${ee}: ${_e}`).join(`
50
- `)},Xh=(t,e,i)=>{var F,U,X,ae;let o=t.info,{width:r,height:a}=ye(i.ui.playerSize),l={version:Vl,viewport:`${r}x${a}`,volume:Math.round(ye(i.state.volume$)*100)};l.id=i.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(i.state.positionExact$),0),l.nativeBuffer=Math.max(p.end-ye(i.state.positionExact$),0))),l.position=ye(i.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(i.vsid);typeof R=="string"&&(l.vsid=R);let A=(F=t.info.currentVideoStream$.getValue())==null?void 0:F.codec;A&&(l.videoCodec=A);let P=(U=t.info.currentAudioStream$.getValue())==null?void 0:U.codec;P&&(l.audioCodec=P),((X=t.info.currentVideoStream$.getValue())==null?void 0:X.hdr)&&(l.hdr=!0);let z=(ae=t.info.currentAudioStream$.getValue())==null?void 0:ae.language;return z&&(l.audioLanguage=z),l},Zh=(t,e)=>Ba(t,e,"mp4"),Jh=t=>!t.type,e_=t=>!!t.type,t_=()=>{let e=[],i=0;return{add:(o,r)=>{e[i]=[o,r],i=(i+1)%10},find:o=>e.find(([r])=>r===o)}},yu=class{constructor(){this.destroyController=new AbortController;this.pendingDownloads=new Set}download(e){return gt(this,null,function*(){if(this.pendingDownloads.has(e))return null;this.pendingDownloads.add(e);try{let i=yield fetch(e,{signal:this.destroyController.signal});if(i.ok)return yield i.text();throw i}finally{this.pendingDownloads.delete(e)}})}destroy(){this.destroyController.abort(),this.pendingDownloads.clear()}isDestroyed(){return this.destroyController.signal.aborted}};import{isNullable as Pf,safeStorage as Ti}from"@vkontakte/videoplayer-shared/es2015";import"@vkontakte/videoplayer-core/es2015";var I1="vk_player_",i_="vk_player_prefer_traffic_saving_enabled",o_="vk_player_preferred_volume",n_="vk_player_prefer_volume_mute",kf="vk_player_preferred_quality",Tf="vk_player_preferred_default_quality_settings",If="vk_player_preferred_quality_settings_by_video",r_="vk_player_preferred_stream_language",s_="vk_player_preferred_rate",a_="vk_player_preferred_autoplay_next",Ef="vk_player_preferred_subtitles_language",l_="vk_player_user_video_prefs",d_=`${I1}preview_track_close_tooltip`,c_=t=>t>1?1:t<0?0:t,Af=t=>Ti.set(o_,c_(t).toString(10)),wu=()=>{let t=Ti.get(o_);return Pf(t)?void 0:c_(parseFloat(t))},Lf=(t,e)=>Ti.set(kf,JSON.stringify({videoId:t,value:e})),Su=()=>Ti.remove(kf),Mf=t=>{let e=Ti.get(kf);if(Pf(e))return;let{videoId:i,value:o}=JSON.parse(e);if(t!==i){Su();return}return o},u_=(t,e)=>{e?Ti.set(t,"true"):Ti.remove(t)},Vf=t=>Ti.get(t)==="true",Rf=t=>u_(n_,t),p_=()=>Vf(n_),Md=t=>u_(i_,t),Nf=()=>Vf(i_),f_=()=>Ti.get(r_),Of=t=>Ti.set(r_,t),Df=()=>Ti.get(Ef),Bf=t=>{t?Ti.set(Ef,t):Ti.remove(Ef)},m_=t=>Ti.set(s_,JSON.stringify({rate:t})),v_=()=>{let t=Ti.get(s_);if(Pf(t))return;let{rate:e}=JSON.parse(t);return e},g_=t=>{Ti.set(a_,String(t))},h_=()=>Vf(a_),E1=()=>{let t=m=>{Ti.set(Tf,JSON.stringify(m))},e=()=>{try{let m=Ti.get(Tf);return m?JSON.parse(m):null}catch(m){return null}},i=()=>{try{let m=Ti.get(If);return m?JSON.parse(m):null}catch(m){return null}},o=m=>{Ti.set(If,JSON.stringify(m))},r=m=>{u(m);let p=m?i():null;if(p&&(p==null?void 0:p.videoId)===m)return Kt(ke({},p),{appliesTo:"to-video"});p&&a();let v=e();return v?Kt(ke({},v),{appliesTo:"as-default"}):(t({type:"auto_quality"}),{type:"auto_quality",appliesTo:"as-default"})},a=()=>{Ti.remove(If)},l=()=>{Ti.remove(Tf)},d=(m,p="as-default")=>{m.type==="exact_quality"||p==="to-video"?o(m):t(m)},s=m=>{let p=r(m);if(p){switch(p.type){case"traffic_saving":Md(!0);break;case"exact_quality":Lf(m,p.quality)}a(),l()}},u=m=>{let p=Mf(m);if(p){o({type:"exact_quality",videoId:m,quality:p});return}Nf()&&t({type:"traffic_saving",videoId:m}),Md(!1),Su()};return{getPreferredQualitySettings:r,migrateSettingsToLegacyWay:s,savePreferredQualitySettings:d,savePreferredDefaultQualitySettings:t,removePreferredQualitySettingsByVideo:a,getPreferredDefaultQualitySettings:e,getPreferredSubtitlesLanguage:Df,savePreferredSubtitlesLanguage:Bf}},{getPreferredQualitySettings:__,migrateSettingsToLegacyWay:b_,savePreferredQualitySettings:Cu,savePreferredDefaultQualitySettings:uR,removePreferredQualitySettingsByVideo:pR,getPreferredDefaultQualitySettings:Tu}=E1(),P1=3,k1=3,$_=()=>{let t=Ti.get(l_);if(t)try{return JSON.parse(t)}catch(e){return null}return null},Iu=(t,e)=>{var r,a;let i=$_();return(a=(r=i==null?void 0:i[t])==null?void 0:r[e])!=null?a:null},Hf=(t,e,i)=>{var l,d,s;let o=(l=$_())!=null?l:{},r=(s=(d=o[t])==null?void 0:d[e])!=null?s:{};Object.assign(r,i,{updatedTs:Date.now()}),t in o||(o[t]={}),o[t][e]=r;let a=A1(o);Ti.set(l_,JSON.stringify(a))};function A1(t){let e=Object.entries(t).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(k1),e.reduce((o,[r])=>(o[r]=L1(t[r]),o),{})}function L1(t){let e=Object.entries(t);return e.sort(([,i],[,o])=>i.updatedTs>o.updatedTs?-1:1),e.splice(P1),Object.fromEntries(e)}function y_(){Ti.set(d_,JSON.stringify(!0))}function x_(){let t=Ti.get(d_);try{return t?JSON.parse(t):!1}catch(e){return!1}}import{PlaybackState as zb}from"@vkontakte/videoplayer-core/es2015";Tg();var la="var(--btn-color, #fff)";var M1=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),V1=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 Je(t,e){var m;B(e,!0);let i=h(e,"width",19,()=>"24"),o=h(e,"height",19,()=>"24"),r=h(e,"fill",3,la),a=(m=e.viewBox)!=null?m:`0 0 ${i()} ${o()}`;var l=V1(),d=C(l);{var s=p=>{var v=M1(),b=ue(v),y=C(b);ii(y,()=>e.children),S(b),di(),$(p,v)},u=p=>{var v=Ve(),b=ue(v);ii(b,()=>e.children),$(p,v)};V(d,p=>{e.shadow?p(s):p(u,!1)})}S(l),D(()=>{Re(l,"aria-label",e.ariaLabel),Re(l,"aria-hidden",!e.ariaLabel),Re(l,"width",i()),Re(l,"height",o()),Re(l,"viewBox",a),Re(l,"fill",r()),qe(l,e.style),Re(l,"data-testid",e.testId)}),$(t,l),H()}import{isNullable as C_,InterfaceLanguage as T_}from"@vkontakte/videoplayer-shared/es2015";var R1={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 La=!1,wl=null,Ma=!1,Es=!1;function Kp(i){Es=i}var hd=[],_d=[],Dt=null,cr=!1;function Gi(i){Dt=i}var bt=null;function vo(i){bt=i}var qo=null;function jc(i){Dt!==null&&Dt.f&2097152&&(qo===null?qo=[Dt,[i]]:qo[1].push(i))}var wn=null,ur=0,dr=null;function Pg(i){dr=i}var Gg=1,ru=0,Ps=!1,su=null;function sd(){return++Gg}function Ea(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&&bt!==null&&!Ps,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],Ea(a)&&Wp(a),a.wv>i.wv)return!0}(!o||bt!==null&&!Ps)&&$n(i,1024)}return!1}function Yg(i,e,t=!0){var o=i.reactions;if(o!==null)for(var r=0;r<o.length;r++){var a=o[r];qo!=null&&qo[1].includes(i)&&qo[0]===Dt||((a.f&2)!==0?Yg(a,e,!1):e===a&&(t?$n(a,2048):(a.f&1024)!==0&&$n(a,4096),ld(a)))}}function Yc(i){var b,y;var e=wn,t=ur,o=dr,r=Dt,a=Ps,l=qo,d=Ft,s=cr,u=i.f;wn=null,ur=0,dr=null,Ps=(u&256)!==0&&(cr||!Ma||Dt===null),Dt=(u&96)===0?i:null,qo=null,od(i.ctx),cr=!1,ru++,i.f|=2097152;try{var m=(0,i.fn)(),p=i.deps;if(wn!==null){var v;if(md(i,ur),p!==null&&ur>0)for(p.length=ur+wn.length,v=0;v<wn.length;v++)p[ur+v]=wn[v];else i.deps=p=wn;if(!Ps||(u&2)!==0&&i.reactions!==null)for(v=ur;v<p.length;v++)((y=(b=p[v]).reactions)!=null?y:b.reactions=[]).push(i)}else p!==null&&ur<p.length&&(md(i,ur),p.length=ur);if(ms()&&dr!==null&&!cr&&p!==null&&(i.f&6146)===0)for(v=0;v<dr.length;v++)Yg(dr[v],i);return r!==null&&r!==i&&(ru++,dr!==null&&(o===null?o=dr:o.push(...dr))),m}catch(_){Kg(_)}finally{wn=e,ur=t,dr=o,Dt=r,Ps=a,qo=l,od(d),cr=s,i.f^=2097152}}function P$(i,e){let t=e.reactions;if(t!==null){var o=lg.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&&(wn===null||!wn.includes(e))&&($n(e,4096),(e.f&768)===0&&(e.f^=512),Gc(e),md(e,0))}function md(i,e){var t=i.deps;if(t!==null)for(var o=e;o<t.length;o++)P$(i,t[o])}function $l(i){var e=i.f;if((e&16384)===0){$n(i,1024);var t=bt,o=Ma;if(bt=i,Ma=!0,Ve){var r=sr;nd(i.component_function)}try{(e&16)!==0?Hg(i):Yp(i),Gp(i);var a=Yc(i);if(i.teardown=typeof a=="function"?a:null,i.wv=Gg,Ve&&fs&&(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);Ve&&_d.push(i)}finally{Ma=o,bt=t,Ve&&nd(r)}}}function qg(){console.error("Last ten effects were: ",_d.slice(-10).map(i=>i.fn)),_d=[]}function A$(){try{hg()}catch(i){if(Ve&&mo(i,"stack",{value:""}),wl!==null)if(Ve)try{gd(i,wl)}catch(e){throw qg(),e}else gd(i,wl);else throw Ve&&qg(),i}}function tf(){var i=Ma;try{var e=0;for(Ma=!0;hd.length>0;){e++>1e3&&A$();var t=hd,o=t.length;hd=[];for(var r=0;r<o;r++){var a=L$(t[r]);k$(a)}_l.clear()}}finally{La=!1,Ma=i,wl=null,Ve&&(_d=[])}}function k$(i){var e=i.length;if(e!==0)for(var t=0;t<e;t++){var o=i[t];(o.f&24576)===0&&Ea(o)&&($l(o),o.deps===null&&o.first===null&&o.nodes_start===null&&(o.teardown===null?Xp(o):o.fn=null))}}function ld(i){La||(La=!0,queueMicrotask(tf));for(var e=wl=i;e.parent!==null;){e=e.parent;var t=e.f;if((t&96)!==0){if((t&1024)===0)return;e.f^=1024}}hd.push(e)}function L$(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:Ea(t)&&$l(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 Sl(i){var e;for(i&&(La=!0,tf(),La=!0,e=i());;){if(zg(),hd.length===0)return La=!1,wl=null,Ve&&(_d=[]),e;La=!0,tf()}}function ho(){return ht(this,null,function*(){yield Promise.resolve(),Sl()})}function n(i){var e=i.f,t=(e&2)!==0;if(su!==null&&su.add(i),Dt!==null&&!cr){if(!(qo!=null&&qo[1].includes(i))||qo[0]!==Dt){var o=Dt.deps;i.rv<ru&&(i.rv=ru,wn===null&&o!==null&&o[ur]===i?ur++:wn===null?wn=[i]:(!Ps||!wn.includes(i))&&wn.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,Ea(r)&&Wp(r)),Ve&&fs&&!cr&&id!==null&&Dt!==null&&id.reaction===Dt)if(i.trace)i.trace();else{var l=Is("TracedAt");if(l){var d=id.entries.get(i);d===void 0&&(d={traces:[]},id.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 Es&&_l.has(i)?_l.get(i):i.v}function Pt(i){var e=cr;try{return cr=!0,i()}finally{cr=e}}var M$=-7169;function $n(i,e){i.f=i.f&M$|e}function lu(i){if(!(typeof i!="object"||!i||i instanceof EventTarget)){if(Wo in i)au(i);else if(!Array.isArray(i))for(let e in i){let t=i[e];typeof t=="object"&&t&&Wo in t&&au(t)}}}function au(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{au(i[o],e)}catch(r){}let t=Sa(i);if(t!==Object.prototype&&t!==Array.prototype&&t!==Map.prototype&&t!==Set.prototype&&t!==Date.prototype){let o=zc(t);for(let r in o){let a=o[r].get;if(a)try{a.call(i)}catch(l){}}}}}function of(i,e){if(e){let t=document.body;i.autofocus=!0,xn(()=>{document.activeElement===t&&i.focus()})}}function bd(i){var e=Dt,t=bt;Gi(null),vo(null);try{return i()}finally{Gi(e),vo(t)}}var nf=new Set,du=new Set;function Va(i){if(!ot)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 rf(i,e,t,o={}){function r(a){if(o.capture||Cl.call(e,a),!a.cancelBubble)return bd(()=>t==null?void 0:t.call(this,a))}return i.startsWith("pointer")||i.startsWith("touch")||i==="wheel"?xn(()=>{e.addEventListener(i,r,o)}):e.addEventListener(i,r,o),r}function ft(i,e,t,o,r){var a={capture:o,passive:r},l=rf(i,e,t,a);(e===document.body||e===window||e===document||e instanceof HTMLMediaElement)&&Ao(()=>{e.removeEventListener(i,l,a)})}function Je(i){for(var e=0;e<i.length;e++)nf.add(i[e]);for(var t of du)t(i)}function Cl(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){mo(i,"currentTarget",{configurable:!0,get(){return a||t}});var m=Dt,p=bt;Gi(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(nr(_)){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),vo(p)}}}var R$;function jg(){R$=void 0}function Tl(i){var e=document.createElement("template");return e.innerHTML=i.replaceAll("<!>","<!---->"),e.content}function Lo(i,e){var t=bt;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(ot)return Lo($t,null),$t;r===void 0&&(r=Tl(a?i:"<!>"+i),t||(r=Ti(r)));var l=o||dd?document.importNode(r,!0):r.cloneNode(!0);if(t){var d=Ti(l),s=l.lastChild;Lo(d,s)}else Lo(l,l);return l}}function N$(i,e,t="svg"){var o=!i.startsWith("<!>"),r=(e&1)!==0,a=`<${t}>${o?i:"<!>"+i}</${t}>`,l;return()=>{if(ot)return Lo($t,null),$t;if(!l){var d=Tl(a),s=Ti(d);if(r)for(l=document.createDocumentFragment();Ti(s);)l.appendChild(Ti(s));else l=Ti(s)}var u=l.cloneNode(!0);if(r){var m=Ti(u),p=u.lastChild;Lo(m,p)}else Lo(u,u);return u}}function Pe(i,e){return N$(i,e,"svg")}function gs(i=""){if(!ot){var e=yn(i+"");return Lo(e,e),e}var t=$t;return t.nodeType!==ul&&(t.before(t=yn()),wi(t)),Lo(t,t),t}function Oe(){if(ot)return Lo($t,null),$t;var i=document.createDocumentFragment(),e=document.createComment(""),t=yn();return i.append(e,t),Lo(e,t),i}function $(i,e){if(ot){bt.nodes_end=$t,ji();return}i!==null&&i.before(e)}var B$=/\r/g;function Zg(i){i=i.replace(B$,"");let e=5381,t=i.length;for(;t--;)e=(e<<5)-e^i.charCodeAt(t);return(e>>>0).toString(36)}function Jg(i){return i.endsWith("capture")&&i!=="gotpointercapture"&&i!=="lostpointercapture"}var H$=["beforeinput","click","change","dblclick","contextmenu","focusin","focusout","input","keydown","keyup","mousedown","mousemove","mouseout","mouseover","mouseup","pointerdown","pointermove","pointerout","pointerover","pointerup","touchend","touchmove","touchstart"];function eh(i){return H$.includes(i)}var F$=["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 U$={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 th(i){var e;return i=i.toLowerCase(),(e=U$[i])!=null?e:i}var K3=[...F$,"formNoValidate","isMap","noModule","playsInline","readOnly","value","volume","defaultValue","defaultChecked","srcObject","noValidate","allowFullscreen","disablePictureInPicture","disableRemotePlayback"];var z$=["touchstart","touchmove"];function ih(i){return z$.includes(i)}var W$=["$state","$state.raw","$derived","$derived.by"],q3=[...W$,"$state.snapshot","$props","$props.id","$bindable","$effect","$effect.pre","$effect.tracking","$effect.root","$inspect","$inspect().with","$inspect.trace","$host"];var K$=["textarea","script","style","title"];function oh(i){return K$.includes(i)}function cu(i){return i==null?void 0:i.replace(/\//g,"/​")}var $d=!0;function uu(i){$d=i}function he(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 Jr(i,e){return nh(i,e)}function af(i,e){var l;Jc(),e.intro=(l=e.intro)!=null?l:!1;let t=e.target,o=ot,r=$t;try{for(var a=Ti(t);a&&(a.nodeType!==rr||a.data!==Xs);)a=Qo(a);if(!a)throw us;go(!0),wi(a),ji();let d=nh(i,Qt(Me({},e),{anchor:a}));if($t===null||$t.nodeType!==rr||$t.data!==wa)throw ta(),us;return go(!1),d}catch(d){if(d===us)return e.recover===!1&&_g(),Jc(),cd(t),go(!1),Jr(i,e);throw d}finally{go(o),wi(r),jg()}}var Il=new Map;function nh(i,{target:e,anchor:t,props:o={},events:r,context:a,intro:l=!0}){Jc();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=ih(b);e.addEventListener(b,Cl,{passive:y});var _=Il.get(b);_===void 0?(document.addEventListener(b,Cl,{passive:y}),Il.set(b,1)):Il.set(b,_+1)}}};s(td(nf)),du.add(s);var u=void 0,m=Bg(()=>{var p=t!=null?t:e.appendChild(yn());return Bi(()=>{if(a){B({});var v=Ft;v.c=a}r&&(o.$$events=r),ot&&Lo(p,null),$d=l,u=i(p,o)||{},$d=!0,ot&&(bt.nodes_end=$t),a&&H()}),()=>{var y;for(var v of d){e.removeEventListener(v,Cl);var b=Il.get(v);--b===0?(document.removeEventListener(v,Cl),Il.delete(v)):Il.set(v,b)}du.delete(s),p!==t&&((y=p.parentNode)==null||y.removeChild(p))}});return sf.set(u,m),u}var sf=new WeakMap;function Ra(i,e){let t=sf.get(i);return t?(sf.delete(i),t(e)):(Ve&&Lg(),Promise.resolve())}function oi(i,e,...t){var o=i,r=_t,a;Xi(()=>{r!==(r=e())&&(a&&(Yi(a),a=null),Ve&&r==null&&bg(),a=Bi(()=>r(o,...t)))},65536),ot&&(o=$t)}if(Ve){let i=function(e){if(!(e in globalThis)){let t;Object.defineProperty(globalThis,e,{configurable:!0,get:()=>{if(t!==void 0)return t;xg(e)},set:o=>{t=o}})}};Y$=i,i("$state"),i("$effect"),i("$derived"),i("$inspect"),i("$props"),i("$bindable")}var Y$;function Vt(i){Ft===null&&ml("onMount"),ps&&Ft.l!==null?G$(Ft).m.push(i):He(()=>{let e=Pt(i);if(typeof e=="function")return e})}function cn(i){Ft===null&&ml("onDestroy"),Vt(()=>()=>Pt(i))}function G$(i){var t;var e=i.l;return(t=e.u)!=null?t:e.u={a:[],b:[],m:[]}}var rh=new Map;function sh(i,e){var t=rh.get(i);t||(t=new Set,rh.set(i,t)),t.add(e)}function V(i,e,[t,o]=[0,0]){ot&&t===0&&ji();var r=i,a=null,l=null,d=to,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(ot&&o!==-1){if(t===0){let x=Zc(r);x===Xs?o=0:x===Zs?o=1/0:(o=parseInt(x.substring(1)),o!==o&&(o=d?1/0:-1))}let _=o>t;!!d===_&&(r=Pa(),wi(r),go(!1),y=!0,o=-1)}d?(a?ks(a):b&&(a=Bi(()=>b(r))),l&&Wn(l,()=>{l=null})):(l?ks(l):b&&(l=Bi(()=>b(r,[t+1,o]))),a&&Wn(a,()=>{a=null})),y&&go(!0)};Xi(()=>{u=!1,e(m),u||p(null,null)},s),ot&&(r=$t)}function Ls(i,e,t){ot&&ji();var o=i,r=to,a,l=ms()?pg:pl;Xi(()=>{l(r,r=e())&&(a&&Wn(a),a=Bi(()=>t(o)))}),ot&&(o=$t)}var oa=null;function cf(i){oa=i}function yd(i,e){return e}function Z$(i,e,t,o){for(var r=[],a=e.length,l=0;l<a;l++)ou(e[l].e,r,!0);var d=a>0&&r.length===0&&t!==null;if(d){var s=t.parentNode;cd(s),s.append(t),o.clear(),ia(i,e[0].prev,e[a-1].next)}Zp(r,()=>{for(var u=0;u<a;u++){var m=e[u];d||(o.delete(m.k),ia(i,m.prev,m.next)),Yi(m.e,!d)}})}function bi(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=ot?wi(Ti(u)):u.appendChild(yn())}ot&&ji();var m=null,p=!1,v=lr(()=>{var b=t();return nr(b)?b:b==null?[]:td(b)});Xi(()=>{var b=n(v),y=b.length;if(p&&y===0)return;p=y===0;let _=!1;if(ot){var x=Zc(l)===Zs;x!==(y===0)&&(l=Pa(),wi(l),go(!1),_=!0)}if(ot){for(var I=null,C,R=0;R<y;R++){if($t.nodeType===rr&&$t.data===wa){l=$t,_=!0,go(!1);break}var k=b[R],P=o(k,R);C=dh($t,d,I,null,k,P,R,r,e,t),d.items.set(P,C),I=C}y>0&&wi(Pa())}ot||J$(b,d,l,r,e,o,t),a!==null&&(y===0?m?ks(m):m=Bi(()=>a(l)):m!==null&&Wn(m,()=>{m=null})),_&&go(!0),n(v)}),ot&&(l=$t)}function J$(i,e,t,o,r,a,l){var X,Te,ue,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,k,P;if(d)for(P=0;P<u;P+=1)C=i[P],R=a(C,P),k=m.get(R),k!==void 0&&((X=k.a)==null||X.measure(),(_!=null?_:_=new Set).add(k));for(P=0;P<u;P+=1){if(C=i[P],R=a(C,P),k=m.get(R),k===void 0){var E=v?v.e.nodes_start:t;y=dh(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&&e1(k,C,P,r),(k.e.f&8192)!==0&&(ks(k.e),d&&((Te=k.a)==null||Te.unfix(),(_!=null?_:_=new Set).delete(k))),k!==v){if(b!==void 0&&b.has(k)){if(x.length<I.length){var W=I[0],F;y=W.prev;var U=x[0],j=x[x.length-1];for(F=0;F<x.length;F+=1)ah(x[F],W,t);for(F=0;F<I.length;F+=1)b.delete(I[F]);ia(e,U.prev,j.next),ia(e,y,U),ia(e,j,W),v=W,y=j,P-=1,x=[],I=[]}else b.delete(k),ah(k,v,t),ia(e,k.prev,k.next),ia(e,k,y===null?e.first:y.next),ia(e,y,k),y=k;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;k=v}x.push(k),y=k,v=k.next}if(v!==null||b!==void 0){for(var se=b===void 0?[]:td(b);v!==null;)(v.e.f&8192)===0&&se.push(v),v=v.next;var G=se.length;if(G>0){var re=(r&4)!==0&&u===0?t:null;if(d){for(P=0;P<G;P+=1)(ue=se[P].a)==null||ue.measure();for(P=0;P<G;P+=1)(te=se[P].a)==null||te.fix()}Z$(e,se,re,m)}}d&&xn(()=>{var be;if(_!==void 0)for(k of _)(be=k.a)==null||be.apply()}),bt.first=e.first&&e.first.e,bt.last=y&&y.e}function e1(i,e,t,o){(o&1)!==0&&bl(i.v,e),(o&2)!==0?bl(i.i,t):i.i=t}function dh(i,e,t,o,r,a,l,d,s,u){var m=oa,p=(s&1)!==0,v=(s&16)===0,b=p?v?vs(r,!1,!1):Rr(r):r,y=(s&2)===0?l:Rr(l);Ve&&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};oa=_;try{return _.e=Bi(()=>d(i,b,y,u),ot),_.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{oa=m}}function ah(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=Qo(a);r.before(a),a=l}}function ia(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 t1(i,e,t){var a,l;if(!e||e===Zg(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=sr)!=null&&l[Hn]&&(o=`in ${sr[Hn]}`),kg(cu(o))}function xd(i,e,t=!1,o=!1,r=!1){var a=i,l="";D(()=>{var b;var d=bt;if(l===(l=(b=e())!=null?b:"")){ot&&ji();return}if(d.nodes_start!==null&&(jp(d.nodes_start,d.nodes_end),d.nodes_start=d.nodes_end=null),l!==""){if(ot){for(var s=$t.data,u=ji(),m=u;u!==null&&(u.nodeType!==rr||u.data!=="");)m=u,u=Qo(u);if(u===null)throw ta(),us;Ve&&!r&&t1(u.parentNode,s,l),Lo($t,m),a=wi(u);return}var p=l+"";t?p=`<svg>${p}</svg>`:o&&(p=`<math>${p}</math>`);var v=Tl(p);if((t||o)&&(v=Ti(v)),Lo(Ti(v),v.lastChild),t||o)for(;Ti(v);)a.before(Ti(v));else a.before(v)}})}function Hi(i,e,t){ot&&ji();var o=i,r,a;Xi(()=>{r!==(r=e())&&(a&&(Wn(a),a=null),r&&(a=Bi(()=>t(o,r))))},65536),ot&&(o=$t)}function Oa(i,e,t,o,r,a){var y;let l=ot;ot&&ji();var d=Ve&&a&&((y=Ft)==null?void 0:y.function[Hn]),s,u,m=null;ot&&$t.nodeType===Kc&&(m=$t,ji());var p=ot?$t:i,v,b=oa;Xi(()=>{let _=e()||null;var x=r?r():t||_==="svg"?Fc:null;if(_!==s){var I=oa;cf(b),v&&(_===null?Wn(v,()=>{v=null,u=null}):_===u?ks(v):(Yi(v),uu(!1))),_&&_!==u&&(v=Bi(()=>{if(m=ot?m:x?document.createElementNS(x,_):document.createElement(_),Ve&&a&&(m.__svelte_meta={loc:{file:d,line:a[0],column:a[1]}}),Lo(m,m),o){ot&&oh(_)&&m.append(document.createComment(""));var C=ot?Ti(m):m.appendChild(yn());ot&&(C===null?go(!1):wi(C)),o(m,C)}bt.nodes_end=m,p.before(m)})),s=_,s&&(u=s),uu(!0),cf(I)}},65536),l&&(go(!0),wi(p))}var pf;function ch(i){return pf=i.target,new uf(i)}var Ms,Or,uf=class{constructor(e){js(this,Ms);js(this,Or);var a,l;var t=new Map,o=(d,s)=>{var u=vs(s,!1,!1);return t.set(d,u),u};let r=new Proxy(Qt(Me({},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===cl?!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)}});dl(this,Or,(e.hydrate?af:Jr)(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)&&Sl(),dl(this,Ms,r.$$events);for(let d of Object.keys(Ni(this,Or)))d==="$set"||d==="$destroy"||d==="$on"||mo(this,d,{get(){return Ni(this,Or)[d]},set(s){Ni(this,Or)[d]=s},enumerable:!0});Ni(this,Or).$set=d=>{Object.assign(r,d)},Ni(this,Or).$destroy=()=>{Ra(Ni(this,Or))}}$set(e){Ni(this,Or).$set(e)}$on(e,t){Ni(this,Ms)[e]=Ni(this,Ms)[e]||[];let o=(...r)=>t.call(this,...r);return Ni(this,Ms)[e].push(o),()=>{Ni(this,Ms)[e]=Ni(this,Ms)[e].filter(r=>r!==o)}}$destroy(){Ni(this,Or).$destroy()}};Ms=new WeakMap,Or=new WeakMap;function Q(i,e){xn(()=>{var r,a,l;var t=i.getRootNode(),o=t.host?t:(l=(r=t.head)!=null?r:t.ownerDocument.head)!=null?l:(a=pf)==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),Ve&&sh(e.hash,d)}})}function Vs(i,e){var t=void 0,o;Xi(()=>{t!==(t=e())&&(o&&(Yi(o),o=null),t&&(o=Bi(()=>{ko(()=>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 ph(){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 wd(i){return typeof i=="object"?ph(i):i!=null?i:""}var fh=[...`
44
+ \r\f \v\uFEFF`];function vh(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||fh.includes(o[l-1]))&&(d===o.length||fh.includes(o[d]))?o=(l===0?"":o.substring(0,l))+o.substring(d+1):l=d}}return o===""?null:o}function mh(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 ff(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(ff)),r&&s.push(...Object.keys(r).map(ff));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=ff(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+=mh(o)),r&&(t+=mh(r,!0)),t=t.trim(),t===""?null:t}return i==null?null:String(i)}function ne(i,e,t,o,r,a){var l=i.__className;if(ot||l!==t||l===void 0){var d=vh(t,o,a);(!ot||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 mf(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 je(i,e,t,o){var r=i.__style;if(ot||r!==e){var a=gh(e,o);(!ot||a!==i.getAttribute("style"))&&(a==null?i.removeAttribute("style"):i.style.cssText=a),i.__style=e}else o&&(Array.isArray(o)?(mf(i,t==null?void 0:t[0],o[0]),mf(i,t==null?void 0:t[1],o[1],"important")):mf(i,t,o));return o}function Sd(i,e,t){if(i.multiple){if(e==null)return;if(!nr(e))return Mg();for(var o of i.options)o.selected=e.includes(hh(o));return}for(o of i.options){var r=hh(o);if(Bp(r,e)){o.selected=!0;return}}(!t||e!==void 0)&&(i.selectedIndex=-1)}function vf(i){var e=new MutationObserver(()=>{Sd(i,i.__value)});e.observe(i,{childList:!0,subtree:!0,attributes:!0,attributeFilter:["value"]}),Ao(()=>{e.disconnect()})}function hh(i){return"__value"in i?i.__value:i.value}var El=Symbol("class"),Pl=Symbol("style"),$h=Symbol("is custom element"),yh=Symbol("is html");function xh(i,e){e?i.hasAttribute("selected")||i.setAttribute("selected",""):i.removeAttribute("selected")}function De(i,e,t,o){var r=Sh(i);if(ot&&(r[e]=i.getAttribute(e),e==="src"||e==="srcset"||e==="href"&&i.nodeName==="LINK")){o||d1(i,e,t!=null?t:"");return}r[e]!==(r[e]=t)&&(e==="loading"&&(i[ug]=t),t==null?i.removeAttribute(e):typeof t!="string"&&Ch(i).includes(e)?i[e]=t:i.setAttribute(e,t))}function wh(i,e,t,o,r=!1){var k;var a=Sh(i),l=a[$h],d=!a[yh];let s=ot&&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=wd(t.class):(o||t[El])&&(t.class=null),t[Pl]&&((k=t.style)!=null||(t.style=null));var v=Ch(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";ne(i,b,E,o,e==null?void 0:e[El],t[El]),u[P]=E,u[El]=t[El];continue}if(P==="style"){je(i,E,e==null?void 0:e[Pl],t[Pl]),u[P]=E,u[Pl]=t[Pl];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=eh(U);if(Jg(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,Je([U]);else{let j=function(se){u[P].call(this,se)};var R=j;u[F]=rf(U,i,j,W)}else x&&(i[`__${U}`]=void 0)}else if(P==="style")De(i,P,E);else if(P==="autofocus")of(i,!!E);else if(!l&&(P==="__value"||P==="value"&&E!=null))i.value=i.__value=E;else if(P==="selected"&&m)xh(i,E);else{var I=P;d||(I=th(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&&go(!0),u}function io(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(Xi(()=>{var v=e(...l.map(n)),b=wh(i,d,v,o,r);m&&u&&"value"in v&&Sd(i,v.value,!1);for(let _ of Object.getOwnPropertySymbols(s))v[_]||Yi(s[_]);for(let _ of Object.getOwnPropertySymbols(v)){var y=v[_];_.description===kp&&(!d||y!==d[_])&&(s[_]&&Yi(s[_]),s[_]=Bi(()=>Vs(i,()=>y))),b[_]=y}d=b}),u){var p=i;ko(()=>{Sd(p,d.value),vf(p)})}m=!0}function Sh(i){var e;return(e=i.__attributes)!=null?e:i.__attributes={[$h]:i.nodeName.includes("-"),[yh]:i.namespaceURI===ng}}var _h=new Map;function Ch(i){var e=_h.get(i.nodeName);if(e)return e;_h.set(i.nodeName,e=[]);for(var t,o=i,r=Element.prototype;r!==o;){t=zc(o);for(var a in t)t[a].set&&e.push(a);o=Sa(o)}return e}function d1(i,e,t){var o;Ve&&(e==="srcset"&&c1(i,t)||gf((o=i.getAttribute(e))!=null?o:"",t)||Ag(e,i.outerHTML.replace(i.innerHTML,i.innerHTML&&"..."),String(t)))}function gf(i,e){return i===e?!0:new URL(i,document.baseURI).href===new URL(e,document.baseURI).href}function bh(i){return i.split(",").map(e=>e.trim().split(" ").filter(Boolean))}function c1(i,e){var t=bh(i.srcset),o=bh(e);return o.length===t.length&&o.every(([r,a],l)=>a===t[l][1]&&(gf(t[l][0],r)||gf(r,t[l][0])))}var u1=Uc?()=>performance.now():()=>Date.now(),es={tick:i=>(Uc?requestAnimationFrame:_t)(i),now:()=>u1(),tasks:new Set};function Th(){let i=es.now();es.tasks.forEach(e=>{e.c(i)||(es.tasks.delete(e),e.f())}),es.tasks.size!==0&&es.tick(Th)}function Ih(i){let e;return es.tasks.size===0&&es.tick(Th),{promise:new Promise(t=>{es.tasks.add(e={c:i,f:t})}),abort(){es.tasks.delete(e)}}}function pu(i,e){bd(()=>{i.dispatchEvent(new CustomEvent(e))})}function v1(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 Eh(i){let e={},t=i.split(";");for(let o of t){let[r,a]=o.split(":");if(!r||a===void 0)break;let l=v1(r.trim());e[l]=a.trim()}return e}var g1=i=>i;function Rs(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 k=Dt,P=bt;Gi(null),vo(null);try{return u!=null?u:u=t()(e,(E=o==null?void 0:o())!=null?E:{},{direction:s})}finally{Gi(k),vo(P)}}var _={is_global:d,in(){var k;if(e.inert=m,!r){b==null||b.abort(),(k=b==null?void 0:b.reset)==null||k.call(b);return}a||v==null||v.abort(),pu(e,"introstart"),v=hf(e,y(),b,1,()=>{pu(e,"introend"),v==null||v.abort(),v=u=void 0,e.style.overflow=p})},out(k){if(!a){k==null||k(),u=void 0;return}e.inert=!0,pu(e,"outrostart"),b=hf(e,y(),v,0,()=>{pu(e,"outroend"),k==null||k()})},stop:()=>{v==null||v.abort(),b==null||b.abort()}},x=bt;if(((R=x.transitions)!=null?R:x.transitions=[]).push(_),r&&$d){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&&ko(()=>{Pt(()=>_.in())})}}function hf(i,e,t,o,r){var a=o===1;if(Js(e)){var l,d=!1;return xn(()=>{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=Eh(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 k=!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=Eh(u(W,1-W));R.push(F),k||(k=F.overflow==="hidden")}k&&(i.style.overflow="hidden"),y=()=>{var j=_.currentTime;return x+I*p(j/C)},m&&Ih(()=>{if(_.playState!=="running")return!1;var j=y();return m(j,1-j),!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 _f(i,e,t){var o=zo(i,e);o&&o.set&&(i[e]=t,Ao(()=>{i[e]=null}))}var na,Al,Cd,mu,Ph,vu=class vu{constructor(e){js(this,mu);js(this,na,new WeakMap);js(this,Al);js(this,Cd);dl(this,Cd,e)}observe(e,t){var o=Ni(this,na).get(e)||new Set;return o.add(t),Ni(this,na).set(e,o),ig(this,mu,Ph).call(this).observe(e,Ni(this,Cd)),()=>{var r=Ni(this,na).get(e);r.delete(t),r.size===0&&(Ni(this,na).delete(e),Ni(this,Al).unobserve(e))}}};na=new WeakMap,Al=new WeakMap,Cd=new WeakMap,mu=new WeakSet,Ph=function(){var e;return(e=Ni(this,Al))!=null?e:dl(this,Al,new ResizeObserver(t=>{for(var o of t){vu.entries.set(o.target,o);for(var r of Ni(this,na).get(o.target)||[])r(o)}}))},or(vu,"entries",new WeakMap);var bf=vu;var h1=new bf({box:"border-box"});function Sn(i,e,t){var o=h1.observe(i,()=>t(i[e]));ko(()=>(Pt(()=>t(i[e])),o))}function Ah(i,e){return i===e||(i==null?void 0:i[Wo])===e}function it(i={},e,t,o){return ko(()=>{var r,a;return Go(()=>{r=a,a=(o==null?void 0:o())||[],Pt(()=>{i!==t(...a)&&(e(i,...a),r&&Ah(t(...r),i)&&e(null,...r))})}),()=>{xn(()=>{a&&Ah(t(...a),i)&&e(null,...a)})}}),i}function Yo(i=!1){let e=Ft,t=e.l.u;if(!t)return;let o=()=>lu(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&&fd(()=>{kh(e,o),ea(t.b)}),He(()=>{let r=Pt(()=>t.m.map(cg));return()=>{for(let a of r)typeof a=="function"&&a()}}),t.a.length&&He(()=>{kh(e,o),ea(t.a)})}function kh(i,e){if(i.l.s)for(let t of i.l.s)n(t);e()}function Td(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 kl=[];function Dr(i,e){return{subscribe:ae(i,e).subscribe}}function ae(i,e=_t){let t=null,o=new Set;function r(d){if(pl(i,d)&&(i=d,t)){let s=!kl.length;for(let u of o)u[1](),kl.push(u,i);if(s){for(let u=0;u<kl.length;u+=2)kl[u][0](kl[u+1]);kl.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 Dr(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,_)=>Td(y,x=>{u[_]=x,m&=~(1<<_),s&&v()},()=>{m|=1<<_}));return s=!0,v(),function(){ea(b),p(),s=!1}})}function $e(i){let e;return Td(i,t=>e=t)(),e}var gu=!1,$f=Symbol();function w(i,e,t){var a;let o=(a=t[e])!=null?a:t[e]={store:null,source:vs(void 0),unsubscribe:_t};if(o.store!==i&&!($f 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=Td(i,l=>{r?o.source.v=l:O(o.source,l)}),r=!1}return i&&$f in t?$e(i):n(o.source)}function Be(){let i={};function e(){Ao(()=>{for(var t in i)i[t].unsubscribe();mo(i,$f,{enumerable:!1,value:!0})})}return[i,e]}function yf(i){var e=gu;try{return gu=!1,[i(),gu]}finally{gu=e}}var S1={get(i,e){if(!i.exclude.includes(e))return i.props[e]},set(i,e){return Ve&&yg(`${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 Cn(i,e,t){return new Proxy(Ve?{props:i,exclude:e,name:t,other:{},to_proxy:[]}:{props:i,exclude:e},S1)}var C1={get(i,e){let t=i.props.length;for(;t--;){let o=i.props[t];if(Js(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];Js(r)&&(r=r());let a=zo(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(Js(o)&&(o=o()),typeof o=="object"&&o!==null&&e in o){let r=zo(o,e);return r&&!r.configurable&&(r.configurable=!0),r}}},has(i,e){if(e===Wo||e===cl)return!1;for(let t of i.props)if(Js(t)&&(t=t()),t!=null&&e in t)return!0;return!1},ownKeys(i){let e=[];for(let t of i.props)if(Js(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 ts(...i){return new Proxy({props:i},C1)}function Lh(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=!ps||(t&2)!==0,l=(t&8)!==0,d=(t&16)!==0,s=!1,u;l?[u,s]=yf(()=>i[e]):u=i[e];var m=Wo in i||cl in i,p=l&&((F=(W=zo(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=Pt(o):v=o),v);u===void 0&&o!==void 0&&(p&&a&&$g(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:lr)(()=>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,j){return arguments.length>0?((!a||!j||C||s)&&p(j?x():U),U):x()}}var R=!1,k=!1,P=vs(u),E=jr(()=>{var U=x(),j=n(P);return R?(R=!1,k=!0,j):(k=!1,P.v=U)});return l&&n(E),r||(E.equals=fl),function(U,j){if(su!==null&&(R=k,x(),n(P)),arguments.length>0){let se=j?n(E):a&&l?ci(U):U;if(!E.equals(se)){if(R=!0,O(P,se),y&&v!==void 0&&(v=se),Lh(E))return U;Pt(()=>n(E))}return U}return Lh(E)?E.v:n(E)}}var T1;typeof HTMLElement=="function"&&(T1=class extends HTMLElement{constructor(e,t,o){super();or(this,"$$ctor");or(this,"$$s");or(this,"$$c");or(this,"$$cn",!1);or(this,"$$d",{});or(this,"$$r",!1);or(this,"$$p_d",{});or(this,"$$l",{});or(this,"$$l_u",new Map);or(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=I1(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]=xf(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=ch({component:this.$$ctor,target:this.shadowRoot||this,props:Qt(Me({},this.$$d),{$$slots:o,$$host:this})}),this.$$me=iu(()=>{Go(()=>{var a;this.$$r=!0;for(let l of Lp(this.$$c)){if(!((a=this.$$p_d[l])!=null&&a.reflect))continue;this.$$d[l]=this.$$c[l];let d=xf(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]=xf(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 Lp(this.$$p_d).find(t=>this.$$p_d[t].attribute===e||!this.$$p_d[t].attribute&&t.toLowerCase()===e)||e}});function xf(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 I1(i){let e={};return i.childNodes.forEach(t=>{e[t.slot||"default"]=!0}),e}var Mh="5";var Vh,Rh,Oh;typeof window!="undefined"&&((Oh=(Rh=(Vh=window.__svelte)!=null?Vh:window.__svelte={}).v)!=null?Oh:Rh.v=new Set).add(Mh);import{areValidLiveRecordSources as ZT,clientChecker as Vv}from"@vkontakte/videoplayer-core/es2015";import"@vkontakte/videoplayer-core/es2015";import{noop as jb,safeStorage as JT,throttleFn as eI}from"@vkontakte/videoplayer-shared/es2015";import{SeekAction as tI}from"@vkontakte/videoplayer-statistics/es2015";import{InterfaceLanguage as E1,fillWithDefault as P1,VideoQuality as Dh}from"@vkontakte/videoplayer-shared/es2015";var A1={isMobile:void 0,disableInvisibleComponentsTimeout:500,debugLog:!1,devNullLog:!1,defaultLanguage:E1.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:Dh.Q_480P,highQualityLimit:Dh.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:[]},Nh=i=>P1(i,A1),Bh=i=>gl("ui-config",i),Rt=()=>vl("ui-config");var Id="vk_player_debug_panel_opened";var Hh="videoplayer",Fh="videoplayer";var hs={KeyF:"f",KeyK:"k",KeyC:"c",KeyM:"m"},Uh=new Set(["ArrowLeft","ArrowRight","KeyL","KeyJ"]),zh=new Set(["Tab","Space","ArrowLeft","ArrowRight","ArrowUp","ArrowDown"]),Wh=new Set(["ShiftRight","ShiftLeft"]);var Kh=["TIMELINE"],Ed=[...Kh,"GRAPH_BUTTON"],wf=[...Kh,"PLAY_BUTTON"],Pd=[...Ed,"PLAY_BUTTON"];var _s=(a=>(a.XS="xs",a.S="s",a.M="m",a.L="l",a.XL="xl",a))(_s||{}),Ad={xs:0,s:1,m:2,l:3,xl:4};import{assertNonNullable as qh,VERSION as k1}from"@vkontakte/videoplayer-shared/es2015";import{VERSION as L1}from"@vkontakte/videoplayer-core/es2015";import{VERSION as M1}from"@vkontakte/videoplayer-statistics/es2015";var hu="prod",Ll="1.1.82-dev.af06eecf.0";var Na=(i,e,t)=>{let o=document.createElement("a");o.href=i,o.download=`${e}.${t}`,o.style.display="none",o.click()};var Qh=Symbol("storeContext"),Gh=Symbol("microStoresContext"),Yh=(i,e)=>{gl(Qh,i),gl(Gh,e),hu==="dev"&&(window.app={store:i,microStores:e})},xe=()=>{let i=vl(Qh);return qh(i,"Store context is empty!"),i},xo=()=>{let i=vl(Gh);return qh(i,"MicroStores context is empty!"),i},ni=(i,e)=>bu(i,i.getValue(),e),bu=(i,e,t)=>Dr(e,o=>{let r=i.subscribe(a=>{o(a),t==null||t(a)});return()=>r.unsubscribe()}),jh=(i,e,t,o,r=["meta config not provided"])=>{var F,U,j,se,G,re,X,Te,ue;let a=i.info,{width:l,height:d}=$e(t.ui.playerSize),s=(U=(F=a.throughputEstimation$.getValue())==null?void 0:F.toFixed(0))!=null?U:0,u=(se=(j=a.rttEstimation$.getValue())==null?void 0:j.toFixed(0))!=null?se:0,m=a.isAutoQualityEnabled$.getValue()?"auto":"manual",p=`${Ll} (core: ${L1}, stat: ${M1}, shared: ${k1})`,v=$e(t.state.errorLog$),b=v.length?`
45
+ `+v.map((te,be)=>{var ve;let Ce=`${be}) Type: ${te.id}
46
+ `,me=`Message: ${te.message} (${te.thrown})
47
+ `,qe=`Trace: ${(ve=te.thrown)==null?void 0:ve.stack}
48
+ `;return Ce+me+qe}).join(`
49
+ `):void 0,y=t.state.isAudioDisabled?"disabled":$e(t.state.isAudioAvailable$)?void 0:"unavailable",_=i.info.currentVideoStream$.getValue(),x=i.info.currentAudioStream$.getValue(),I=[];_&&I.push(`Video: ${(G=_==null?void 0:_.codec)!=null?G:""}`+(_!=null&&_.hdr?" (HDR)":"")),x&&I.push(`Audio: ${(re=x==null?void 0:x.codec)!=null?re:""}`+(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 k=a.httpConnectionType$.getValue(),P=(Te=(X=a.currentBuffer$.getValue())==null?void 0:X.end)!=null?Te:0,E=Math.max(P-$e(t.state.positionExact$),0),W={Version:p,Browser:navigator.userAgent,Config:r.join(", "),"United video id":String(t.videoId),TraceId:o,VSID:$e(t.vsid),"Content host":a.hostname$.getValue(),"Connection type":k?k+(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:`${$e(t.state.positionExact$)}s`,Buffer:`${E}s`,State:`${$e(t.playerPhase)} ${(ue=a.playbackState$.getValue())!=null?ue:""}`,"Player size":`${l}x${d}`,URL:window.location.href,Errors:b};return Object.entries(W).filter(([te,be])=>be!==void 0).map(([te,be])=>`${te}: ${be}`).join(`
50
+ `)},Xh=(i,e,t)=>{var F,U,j,se;let o=i.info,{width:r,height:a}=$e(t.ui.playerSize),l={version:Ll,viewport:`${r}x${a}`,volume:Math.round($e(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-$e(t.state.positionExact$),0),l.nativeBuffer=Math.max(p.end-$e(t.state.positionExact$),0))),l.position=$e(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=$e(t.vsid);typeof R=="string"&&(l.vsid=R);let k=(F=i.info.currentVideoStream$.getValue())==null?void 0:F.codec;k&&(l.videoCodec=k);let P=(U=i.info.currentAudioStream$.getValue())==null?void 0:U.codec;P&&(l.audioCodec=P),((j=i.info.currentVideoStream$.getValue())==null?void 0:j.hdr)&&(l.hdr=!0);let W=(se=i.info.currentAudioStream$.getValue())==null?void 0:se.language;return W&&(l.audioLanguage=W),l},Zh=(i,e)=>Na(i,e,"mp4"),Jh=i=>!i.type,e_=i=>!!i.type,t_=()=>{let e=[],t=0;return{add:(o,r)=>{e[t]=[o,r],t=(t+1)%10},find:o=>e.find(([r])=>r===o)}},_u=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}};import{isNullable as If,safeStorage as Ii}from"@vkontakte/videoplayer-shared/es2015";import"@vkontakte/videoplayer-core/es2015";var V1="vk_player_",i_="vk_player_prefer_traffic_saving_enabled",o_="vk_player_preferred_volume",n_="vk_player_prefer_volume_mute",Ef="vk_player_preferred_quality",Sf="vk_player_preferred_default_quality_settings",Cf="vk_player_preferred_quality_settings_by_video",r_="vk_player_preferred_stream_language",s_="vk_player_preferred_rate",a_="vk_player_preferred_autoplay_next",Tf="vk_player_preferred_subtitles_language",l_="vk_player_user_video_prefs",d_=`${V1}preview_track_close_tooltip`,c_=i=>i>1?1:i<0?0:i,Pf=i=>Ii.set(o_,c_(i).toString(10)),$u=()=>{let i=Ii.get(o_);return If(i)?void 0:c_(parseFloat(i))},Af=(i,e)=>Ii.set(Ef,JSON.stringify({videoId:i,value:e})),yu=()=>Ii.remove(Ef),kf=i=>{let e=Ii.get(Ef);if(If(e))return;let{videoId:t,value:o}=JSON.parse(e);if(i!==t){yu();return}return o},u_=(i,e)=>{e?Ii.set(i,"true"):Ii.remove(i)},Lf=i=>Ii.get(i)==="true",Mf=i=>u_(n_,i),p_=()=>Lf(n_),kd=i=>u_(i_,i),Vf=()=>Lf(i_),f_=()=>Ii.get(r_),Rf=i=>Ii.set(r_,i),Of=()=>Ii.get(Tf),Df=i=>{i?Ii.set(Tf,i):Ii.remove(Tf)},m_=i=>Ii.set(s_,JSON.stringify({rate:i})),v_=()=>{let i=Ii.get(s_);if(If(i))return;let{rate:e}=JSON.parse(i);return e},g_=i=>{Ii.set(a_,String(i))},h_=()=>Lf(a_),R1=()=>{let i=m=>{Ii.set(Sf,JSON.stringify(m))},e=()=>{try{let m=Ii.get(Sf);return m?JSON.parse(m):null}catch(m){return null}},t=()=>{try{let m=Ii.get(Cf);return m?JSON.parse(m):null}catch(m){return null}},o=m=>{Ii.set(Cf,JSON.stringify(m))},r=m=>{u(m);let p=m?t():null;if(p&&(p==null?void 0:p.videoId)===m)return Qt(Me({},p),{appliesTo:"to-video"});p&&a();let v=e();return v?Qt(Me({},v),{appliesTo:"as-default"}):(i({type:"auto_quality"}),{type:"auto_quality",appliesTo:"as-default"})},a=()=>{Ii.remove(Cf)},l=()=>{Ii.remove(Sf)},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":kd(!0);break;case"exact_quality":Af(m,p.quality)}a(),l()}},u=m=>{let p=kf(m);if(p){o({type:"exact_quality",videoId:m,quality:p});return}Vf()&&i({type:"traffic_saving",videoId:m}),kd(!1),yu()};return{getPreferredQualitySettings:r,migrateSettingsToLegacyWay:s,savePreferredQualitySettings:d,savePreferredDefaultQualitySettings:i,removePreferredQualitySettingsByVideo:a,getPreferredDefaultQualitySettings:e,getPreferredSubtitlesLanguage:Of,savePreferredSubtitlesLanguage:Df}},{getPreferredQualitySettings:__,migrateSettingsToLegacyWay:b_,savePreferredQualitySettings:xu,savePreferredDefaultQualitySettings:_R,removePreferredQualitySettingsByVideo:bR,getPreferredDefaultQualitySettings:wu}=R1(),O1=3,D1=3,$_=()=>{let i=Ii.get(l_);if(i)try{return JSON.parse(i)}catch(e){return null}return null},Su=(i,e)=>{var r,a;let t=$_();return(a=(r=t==null?void 0:t[i])==null?void 0:r[e])!=null?a:null},Nf=(i,e,t)=>{var l,d,s;let o=(l=$_())!=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=N1(o);Ii.set(l_,JSON.stringify(a))};function N1(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(D1),e.reduce((o,[r])=>(o[r]=B1(i[r]),o),{})}function B1(i){let e=Object.entries(i);return e.sort(([,t],[,o])=>t.updatedTs>o.updatedTs?-1:1),e.splice(O1),Object.fromEntries(e)}function y_(){Ii.set(d_,JSON.stringify(!0))}function x_(){let i=Ii.get(d_);try{return i?JSON.parse(i):!1}catch(e){return!1}}import{PlaybackState as Qb}from"@vkontakte/videoplayer-core/es2015";Tg();var ra="var(--btn-color, #fff)";var H1=Pe('<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),F1=Pe('<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,ra),a=(m=e.viewBox)!=null?m:`0 0 ${t()} ${o()}`;var l=F1(),d=T(l);{var s=p=>{var v=H1(),b=le(v),y=T(b);oi(y,()=>e.children),S(b),ti(),$(p,v)},u=p=>{var v=Oe(),b=le(v);oi(b,()=>e.children),$(p,v)};V(d,p=>{e.shadow?p(s):p(u,!1)})}S(l),D(()=>{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()),je(l,e.style),De(l,"data-testid",e.testId)}),$(i,l),H()}import{isNullable as C_,InterfaceLanguage as T_}from"@vkontakte/videoplayer-shared/es2015";var U1={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:"Выйти из режима точной перемотки"},w_=R1;var N1={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,
52
+ попробуйте изменить качество на «Авто»`,double_forward_label:"2x",preview_track_notification_text:"Потяните вверх для точной перемотки",preview_track_close_tooltip:"Выйти из режима точной перемотки"},w_=U1;var z1={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"},S_=N1;var Hs=new Map;Hs.set(T_.EN,S_);Hs.set(T_.RU,w_);var I_=new Map,Ff=({language:t,pack:e,fallback:i})=>{if(Hs.has(t)){let o=Hs.get(t);Hs.set(t,ke(ke({},o),e))}else Hs.set(t,e);I_.set(t,i)},Uf=t=>Hs.has(t),zf=(t,e,i,o)=>{var l;let r=Hs.get(t),a=r==null?void 0:r[e];if(C_(a)){let d=(l=I_.get(t))!=null?l:o,s=d?Hs.get(d):void 0;a=s==null?void 0:s[e]}return C_(a)?e+Object.values(i!=null?i:{}).join(" "):i?a.replaceAll(/{(\w+?)}/g,(d,s)=>{var u;return(u=i[s])!=null?u:""}):a},Y=(t,e)=>{let{interfaceLanguage$:i}=be(),o=ye(i),r=Vt();return zf(o,t,e,r.defaultLanguage)};var O1=Ie('<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 Vd(t,e){B(e,!1);let i=Y("video360");ho(),Je(t,{width:"76",height:"45",get ariaLabel(){return i},testId:"video-360-icon",shadow:!0,children:(o,r)=>{var a=O1();$(o,a)},$$slots:{default:!0}}),H()}import"@vkontakte/videoplayer-core/es2015";var Rl;(function(t){t.fatal="fatal",t.error="error",t.warning="warning",t.log="log",t.info="info",t.debug="debug",t.critical="critical"})(Rl||(Rl={}));var D1=/^\s*at (?:(.*?) ?\()?((?:file|https?|blob|chrome-extension|address|native|eval|webpack|<anonymous>|[-a-z]+:|.*bundle|\/).*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,B1=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:file|https?|blob|chrome|webpack|resource|moz-extension).*?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js))(?::(\d+))?(?::(\d+))?\s*$/i,H1=/^\s*at (?:((?:\[object object\])?.+) )?\(?((?:file|ms-appx|https?|webpack|blob):.*?):(\d+)(?::(\d+))?\)?\s*$/i,Eu="?",F1="X-Sentry-Auth",U1=/^(?:(\w+):)\/\/(?:([\w-]+)(?::(\w+))?@)([\w.-]+)(?::(\d+))?\/(.+)/;function z1(t){if(!t.stack)return null;let e=[],i=t.stack.split(`
55
- `),o,r;for(let a=0;a<i.length;++a){if(o=D1.exec(i[a]))r={filename:o[2]&&o[2].indexOf("address at ")===0?o[2].substr(11):o[2],function:o[1]||Eu,lineno:o[3]?+o[3]:null,colno:o[4]?+o[4]:null};else if(o=H1.exec(i[a]))r={filename:o[2],function:o[1]||Eu,lineno:+o[3],colno:o[4]?+o[4]:null};else if(o=B1.exec(i[a]))a===0&&!o[5]&&t.columnNumber!==void 0&&(e[0].column=t.columnNumber+1),r={filename:o[3],function:o[1]||Eu,lineno:o[4]?+o[4]:null,colno:o[5]?+o[5]:null};else continue;!r.function&&r.lineno&&(r.function=Eu),e.push(r)}return e.length?{value:E_(t),type:t.name,stacktrace:{frames:e.reverse()}}:null}function E_(t){return(t&&t.message||"No error message").split(`
56
- `).filter(i=>!!i)[0]}function W1(t){try{let e=z1(t);if(e)return e}catch(e){}return{value:E_(t),type:t&&t.name,stacktrace:{frames:[]}}}function K1(){return"xxxxxxxxxxxx4xxxyxxxxxxxxxxxxxxx".replace(/[xy]/g,t=>{let e=Math.random()*16|0;return(t==="x"?e:e&3|8).toString(16)})}var Pu=class{constructor(e){if(e&&e.dsn){let i=U1.exec(e.dsn),o=i?i.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 Kt(ke({},this.getRequestBlank()),{exception:{values:[W1(e)]}})}report(e){this.send(this.prepare(e))}send(e){!this.apiUrl||!e||this.createRequest(e)}createRequest(e){let i=new XMLHttpRequest;i.open("POST",this.apiUrl,!0),i.setRequestHeader("Content-type","application/json"),i.setRequestHeader(F1,this.authHeader||""),i.send(JSON.stringify(e))}getRequestBlank(){return{platform:"javascript",event_id:K1(),sdk:{name:"micro-sentry.javascript.core",version:"0.0.0"},timestamp:Date.now()/1e3,environment:this.environment}}};function P_(t,e){return Object.prototype.toString.call(e)==="[object RegExp]"?e.test(t):typeof e=="string"?t.indexOf(e)!==-1:!1}function q1(){return window}var ku=class t extends Pu{constructor(e,i=q1()){super(e),this.options=e,this.window=i,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,i){return this.extendState({tags:{[e]:i}}),this}setExtra(e,i){return this.extendState({extra:{[e]:i}}),this}setExtras(e){return this.setKeyState("extra",ke({},e)),this}setUser(e){return this.setKeyState("user",ke({},e)),this}clone(){let e=new t(Kt(ke({},this.options),{plugins:[]}));return e.extendState(this.state),e}withScope(e){let i=this.clone();e(i),i.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,i){this.send(Kt(ke({},this.getRequestBlank()),{message:e,level:i}))}destroy(){this.destroyed=!0,this.plugins.forEach(e=>{e.destroy&&e.destroy()})}isIgnoredError(e){return this.ignoreErrors.length?this.getPossibleEventMessages(e).some(i=>this.ignoreErrors.some(o=>P_(i,o))):!1}getRequestBlank(){return ke(Kt(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:i="",value:o=""}=e.exception.values&&e.exception.values[0]||{};return[`${o}`,`${i}: ${o}`]}catch(i){return[]}return[]}isDeniedUrl(e){if(!this.blacklistUrls.length)return!1;let i=this.getEventFilterUrl(e);return i?this.blacklistUrls.some(o=>P_(i,o)):!1}getEventFilterUrl(e){try{if(e.exception){let i=e.exception.values&&e.exception.values[0].stacktrace&&e.exception.values[0].stacktrace.frames;return i&&i[i.length-1].filename||null}return null}catch(i){return null}}extendState(e){this._state=Object.keys(e).reduce((i,o)=>{let r=this._state[o],a=Array.isArray(r)?r:null,l=e[o],d=Array.isArray(l)?l:null;return Kt(ke({},i),{[o]:a||d?[...a||[],...d||[]]:ke(ke({},typeof r!="string"?r:{}),typeof l!="string"?l:{})})},this._state)}setKeyState(e,i){this._state[e]=i}};import{isNonNullable as Au,Subscription as Q1}from"@vkontakte/videoplayer-shared/es2015";var Lu=null,Ha=class{constructor(e,i,o={}){!Lu&&e.dsn&&(this.sentryClient=new ku({dsn:e.dsn,environment:i.env}),this.version=i.version,this.sentrySubscription=new Q1,this.options=e,this.context=o,Lu=this)}destroy(){var e,i;(e=this.sentryClient)==null||e.destroy(),(i=this.sentrySubscription)==null||i.unsubscribe(),Lu=null}logIError(e,i=!1){e.thrown&&this.report(e.thrown,{fatal:i,errorType:e.id,category:e.category},{message:e.message,errorData:e.data})}report(e,i={},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}=i;if(Au(b)&&p.includes(b)||Au(v)&&m.includes(v))return;if(Math.random()<=d||Au(b)&&u.includes(b)||Au(v)&&s.includes(v)){Object.keys(i).length&&r.setTags(ke({version:this.version},i)),(Object.keys(a).length||Object.keys(o).length)&&r.setExtras(ke(ke({},a),o));try{v&&r.captureMessage(v,i.fatal?Rl.fatal:Rl.error),r.report(e)}catch(_){console.error(_)}}}static getInstance(){return Lu}};var bs=(d=>(d.Thumb="thumb",d.Video="video",d.Ads="ads",d.Crashed="crashed",d.LiveWaitingStart="LiveWaitingStart",d.LiveWaitingRecover="LiveWaitingRecover",d.LiveWaitingRecord="LiveWaitingRecord",d))(bs||{});var Mu=t=>{if(t.requestFullscreen)return t.requestFullscreen();if(t.msRequestFullscreen)return t.msRequestFullscreen();if(t.webkitRequestFullscreen)return t.webkitRequestFullscreen();if(t.mozRequestFullScreen)return t.mozRequestFullScreen();let e=t.querySelector("video");return e!=null&&e.webkitEnterFullscreen?(e.webkitEnterFullscreen(),Promise.resolve()):Promise.reject()},Vu=t=>t.exitFullscreen?t.exitFullscreen():t.msExitFullscreen?t.msExitFullscreen():t.webkitExitFullscreen?t.webkitExitFullscreen():t.mozCancelFullScreen?t.mozCancelFullScreen():Promise.reject(),k_=(t,e)=>e?!0:t.fullscreenEnabled||!!t.webkitFullscreenEnabled||!!t.mozFullscreenEnabled||!!t.msFullscreenEnabled,A_=t=>{let e=t;e!=null&&e.webkitExitFullscreen&&(e==null||e.webkitExitFullscreen())},Rd=()=>{let t=document;return t.fullscreenElement||t.mozFullScreenElement||t.webkitFullscreenElement||t.msFullscreenElement},da=()=>!!Rd(),Ru=t=>{document.addEventListener("fullscreenchange",t),document.addEventListener("webkitfullscreenchange",t),document.addEventListener("mozfullscreenchange",t),document.addEventListener("MSFullscreenChange",t)},Nu=t=>{document.removeEventListener("fullscreenchange",t),document.removeEventListener("webkitfullscreenchange",t),document.removeEventListener("mozfullscreenchange",t),document.removeEventListener("MSFullscreenChange",t)},L_=t=>{let e=window.screen;return(r=>gt(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")(t))};import{clientChecker as M_}from"@vkontakte/videoplayer-core/es2015";var V_=()=>({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:M_.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:M_.device.isApple?Y("hotkey_map_item_next_episode_mac_value"):Y("hotkey_map_item_next_episode_pc_value")}]}]});import{debounceFn as G1,getWindow as R_,ValueSubject as Wf}from"@vkontakte/videoplayer-shared/es2015";import{clientChecker as Y1}from"@vkontakte/videoplayer-core/es2015";var Fa=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:G1(this.onResize.bind(this),300)};this.info={isActive$:new Wf(!1),isEnabled$:new Wf(!1),type:0};this.info.isEnabled$=new Wf(e)}isSupported(){return document.pictureInPictureEnabled}isActive(){return this.info.isActive$.getValue()}setContext(e){this.svelteContext=e}revealPictureInPicture(){return gt(this,null,function*(){this.isRequested&&(this.removeEventHandlers(),yield this.request(),this.addEventHandlers())})}request(){return gt(this,null,function*(){var e;if(!(!this.isSupported()||this.isActive()))try{yield(e=this.videoElement)==null?void 0:e.requestPictureInPicture()}catch(i){this.isRequested=!1}})}exit(){return gt(this,null,function*(){!this.isSupported()||!this.isActive()||(yield document.exitPictureInPicture())})}assignPlayerContainer(e){this.isSupported()&&(this.playerContainer=e)}updateVideoElement(){this.isSupported()&&this.exit().finally(()=>{var i;this.removeEventHandlers();let e=this.videoElement;this.videoElement=(i=this.playerContainer)==null?void 0:i.querySelector("video"),this.waitForSafariLeavePictureInPicture(e,this.videoElement),this.addEventHandlers()})}addEventHandlers(){var e,i;(e=this.videoElement)==null||e.addEventListener("enterpictureinpicture",this.eventHandlers.enterpictureinpicture),(i=this.videoElement)==null||i.addEventListener("leavepictureinpicture",this.eventHandlers.leavepictureinpicture)}setExternalEventHandlers(e){this.externalEventHandlers=ke({},e)}removeEventHandlers(){var e,i;(e=this.videoElement)==null||e.removeEventListener("enterpictureinpicture",this.eventHandlers.enterpictureinpicture),(i=this.videoElement)==null||i.removeEventListener("leavepictureinpicture",this.eventHandlers.leavepictureinpicture)}dispose(){return gt(this,null,function*(){this.removeEventHandlers(),yield this.exit(),this.info.isActive$.next(!1),this.isRequested=!1})}onEnterPictureInPicture(e){var r,a;let o=e.pictureInPictureWindow;o&&(this.info.isActive$.next(!0),this.isRequested=!0,o.addEventListener("resize",this.eventHandlers.resize),(a=(r=this.externalEventHandlers).enterpictureinpicture)==null||a.call(r,e))}onLeavePictureInPicture(e){var r,a;let o=e.pictureInPictureWindow;this.info.isActive$.next(!1),this.isRequested=!1,this.eventHandlers.resize.cancel(),o==null||o.removeEventListener("resize",this.eventHandlers.resize),(a=(r=this.externalEventHandlers).leavepictureinpicture)==null||a.call(r,e)}onResize(e){var i,o;(o=(i=this.externalEventHandlers).resize)==null||o.call(i,e)}setEnabled(e){this.info.isEnabled$.next(e)}waitForSafariLeavePictureInPicture(e,i){if(Y1.browser.isSafari&&e&&e!==i){let r=this.eventHandlers.leavepictureinpicture,a=0,l=()=>{R_().clearTimeout(a),e.removeEventListener("leavepictureinpicture",d)},d=s=>(r(s),l());e.addEventListener("leavepictureinpicture",d),a=R_().setTimeout(l,1e3)}}};function Ua(t){return t instanceof Fa}import{devNull as N_,now as O_}from"@vkontakte/videoplayer-shared/es2015";function qf(t,e){B(e,!1);let i=be();Mt(()=>{i.getAdmanWrapper().startPostroll()}),ho(),H()}import{noop as Z1}from"@vkontakte/videoplayer-shared/es2015";var j1=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>'),X1=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 Or(t,e){B(e,!0);let i=h(e,"direction",3,"left"),o=h(e,"useBtnColor",3,!1),r=f(()=>["up","down"].includes(i())),a=f(()=>["right","down"].includes(i())),l=f(()=>`chevron-icon--${i()}`),d=f(()=>(()=>{let m="";return n(a)&&(m+="transform: rotate(180deg);"),m.length?m:void 0})()),s=f(()=>o()?la:"currentColor"),u=f(()=>n(r)?"7":"16");Je(t,{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=Ve(),b=ue(v);{var y=x=>{var I=j1();$(x,I)},_=x=>{var I=X1();$(x,I)};V(b,x=>{n(r)?x(y):x(_,!1)})}$(m,v)},$$slots:{default:!0}}),H()}var J1=(t,e,i)=>{t.stopPropagation(),n(e)&&i()()},ey=L('<div class="skip s-1g"> <!></div>'),ty=L("<div><!></div>"),iy={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 Qf(t,e){B(e,!0),Q(t,iy);let[i,o]=Oe(),r=()=>w(u,"$isMobile",i),a=h(e,"position",3,0),l=h(e,"secondsToWatchBeforeSkip",3,0),d=h(e,"skipAd",3,Z1),u=be().ui.isMobile,m=f(()=>a()>0&&a()>=l());var p=ty();let v;p.__click=[J1,m,d];var b=C(p);{var y=x=>{var I=ey(),T=C(I),R=k(T);Or(R,{direction:"right"}),S(I),D(A=>ve(T,`${A!=null?A:""} `),[()=>Y("skip_ads_now")]),$(x,I)},_=x=>{var I=gs();D(T=>ve(I,T),[()=>Y("skip_ads_after",{time:Math.ceil(l()-a()).toFixed(0)})]),$(x,I)};V(b,x=>{n(m)?x(y):x(_,!1)})}S(p),D(x=>v=oe(p,1,"container s-1g",null,v,x),[()=>({"container-mobile":r(),skippable:n(m)})]),$(t,p),H(),o()}Ye(["click"]);var oy=L('<button class="go-to-site s-1h"> </button>'),ny={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 Gf(t,e){B(e,!1),Q(t,ny),ho();var i=oy(),o=C(i,!0);S(i),D(r=>ve(o,r),[()=>Y("visit_advertiser")],In),$(t,i),H()}var ry=L('<div class="top-gradient-mobile s-k"></div>'),sy=L('<div class="container s-k"><!> <video style="width: 100%; height: 100%" playsinline=""></video> <!> <!> <!></div>',2),ay={hash:"s-k",code:".container.s-k{height:100%;width:100%}.top-gradient-mobile.s-k{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 Od(t,e){B(e,!0),Q(t,ay);let[i,o]=Oe(),r=()=>w(U,"$canSkipAd",i),a=()=>w(F,"$adPlaybackState",i),l=()=>w(R,"$isMobile",i),d=()=>w(X,"$adPosition",i),s=()=>w(ae,"$secondsToWatchBeforeSkipAd",i),u=()=>w(T,"$isVideoEnded",i),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=Vt(),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);Mt(()=>{let O=x.getAdmanWrapper();if(N_.push("ui",{key:"videoplayer_embed",strings:["new","adman_ads_mount"],numbers:[O_(),m()]}),!m()){O.onAdmanLoadingError();return}let Ge=()=>{var Le;let{width:He,height:ot}=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:ot,isFullscreen:ne,isAutoplay:ce,adsContainer:n(P),adsVideoElement:n(E),slotId:m(),params:p(),paramsOverride:Ne,duration:b(),externalApi:y(),json:_()}},K=He=>gt(null,null,function*(){He&&(yield mo());let ot=Ge();yield O.initAdman(ot),z=!0}),se=new AbortController,xe=()=>{se.abort()};return window.AdmanHTML?K(!0).catch(()=>{O.onAdmanLoadingError()}):O.loadAdman(se.signal).then(()=>K(!1)).catch(()=>{O.onAdmanLoadingError()}),()=>{N_.push("ui",{key:"videoplayer_embed",strings:["new","adman_ads_unmount"],numbers:[O_(),m()]}),!z&&xe()}});var J=sy(),we=C(J);{var me=O=>{var Ge=ry();$(O,Ge)};V(we,O=>{l()&&O(me)})}var ee=k(we,2);Ze(ee,O=>N(E,O),()=>n(E));var _e=k(ee,2);{var Ce=O=>{Qf(O,{get position(){return d()},get secondsToWatchBeforeSkip(){return s()},get skipAd(){return x.actions.internal.skipAd}})};V(_e,O=>{n(Z)&&O(Ce)})}var ge=k(_e,2);{var pe=O=>{qf(O,{})};V(ge,O=>{u()&&O(pe)})}var Qe=k(ge,2);{var G=O=>{Gf(O,{})};V(Qe,O=>{n(re)&&O(G)})}S(J),Ze(J,O=>N(P,O),()=>n(P)),$(t,J),H(),o()}var jo=t=>{if(!isFinite(t))return"00:00";let e=Math.round(t),i=Math.floor(e/(60*60));e-=i*3600;let o=Math.floor(e/60);e-=o*60;let r=[o,e].map(a=>String(a).padStart(2,"0")).join(":");return i>0&&(r=`${i}:${r}`),r};var ly=Ie('<path fill="#fff"></path>'),dy=Ie("<path></path><!>",1);function Dd(t,e){let i=h(e,"isActive",3,!1),o=f(()=>i()?"live-active-icon":"live-icon"),r=f(()=>i()?"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";Je(t,{width:"42",height:"20",get testId(){return n(o)},get fill(){return n(r)},children:(l,d)=>{var s=dy(),u=ue(s),m=k(u);{var p=v=>{var b=ly();Re(b,"d",a),$(v,b)};V(m,v=>{i()&&v(p)})}D(()=>Re(u,"d",`M5 0h32s5 0 5 5v10s0 5 -5 5h-32s-5 0 -5 -5v-10s0 -5 5 -5${i()?"":"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 cy=L('<div class="equalizer s-a"><div class="col s-a"></div> <div class="col s-a"></div> <div class="col s-a"></div></div>'),uy=L('<div class="live-icon s-a"><!></div>'),py=L('<span class="text s-a"> </span>'),fy=L("<div><!> <!></div>"),my={hash:"s-a",code:".wrapper.s-a{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-a{background:var(--red);border-radius:2px;font-size:0;height:20px;line-height:20px;padding:0 7px}.equalizer.s-a{display:inline-block;height:10px;margin-right:4px;margin-top:-4px;position:relative;vertical-align:middle;width:10px}.live.s-a .equalizer:where(.s-a){margin-top:-2px}.equalizer.s-a .col:where(.s-a){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-a .equalizer:where(.s-a) .col:where(.s-a){animation-play-state:running}.equalizer.s-a .col:where(.s-a):first-child{animation-name:s-a-thumb-timer-equalizer-col1;left:0}.equalizer.s-a .col:where(.s-a):nth-child(2){animation-name:s-a-thumb-timer-equalizer-col2;left:3px}.equalizer.s-a .col:where(.s-a):nth-child(3){animation-name:s-a-thumb-timer-equalizer-col3;left:6px}.live-icon.s-a{display:inline-block;height:20px;margin:0 -7px;vertical-align:middle;width:42px}@keyframes s-a-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-a-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-a-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-a{color:var(--controls-time);font-size:13px;font-weight:500;line-height:16px}"};function Bd(t,e){Q(t,my);let i=h(e,"withEqualizer",3,!1),o=h(e,"isLive",3,!1),r=h(e,"isPlaying",3,!1);var a=fy();let l;var d=C(a);{var s=v=>{var b=cy();$(v,b)};V(d,v=>{i()&&v(s)})}var u=k(d,2);{var m=v=>{var b=uy(),y=C(b);Dd(y,{isActive:!0}),S(b),$(v,b)},p=v=>{var b=py(),y=C(b,!0);S(b),D(()=>ve(y,e.time)),$(v,b)};V(u,v=>{o()?v(m):v(p,!1)})}S(a),D(v=>l=oe(a,1,"wrapper s-a",null,l,v),[()=>({live:o(),playing:r()})]),$(t,a)}var Nl=(t,e,i)=>{let o;return()=>(window.clearTimeout(o),t?o=window.setTimeout(()=>e.set(!0),i):e.set(!1),()=>window.clearTimeout(o))};var vy=L('<div role="timer" data-testid="thumb-timer"><!></div>'),gy={hash:"s-l",code:".thumb-timer.s-l{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 Hd(t,e){B(e,!0),Q(t,gy);let[i,o]=Oe(),r=()=>w(m,"$disabled",i),a=h(e,"isHidden",3,!1),l=h(e,"isLive",3,!1),d=h(e,"isPlaying",3,!1),s=Vt(),u=f(()=>jo(e.duration-e.position)),m=de(!1);var p=vy();let v;var b=C(p);Bd(b,{get time(){return n(u)},get isLive(){return l()},get isPlaying(){return d()},withEqualizer:!0}),S(p),Bs(p,()=>Nl(a()&&s.features.usePerformanceFix,m,s.disableInvisibleComponentsTimeout)),D(y=>v=oe(p,1,"thumb-timer s-l",null,v,y),[()=>({"out-of-flow":r(),hidden:a()})]),$(t,p),H(),o()}var Ol=t=>{if(!navigator.clipboard){D_(t);return}navigator.clipboard.writeText(t).catch(()=>D_(t))};function D_(t){if(document.queryCommandSupported&&document.queryCommandSupported("copy")){let e=document.createElement("textarea");e.textContent=t,e.style.position="absolute",e.style.top="-9999px",document.body.appendChild(e),e.select();try{document.execCommand("copy")}finally{document.body.removeChild(e)}}}import{ChromecastState as Iy,clientChecker as Ey}from"@vkontakte/videoplayer-core/es2015";import{clientChecker as B_}from"@vkontakte/videoplayer-core/es2015";var Yf="focus-hidden";var Dr=t=>{t.stopPropagation(),t.preventDefault()},jf=t=>{var e,i;(i=(e=t.parentNode)==null?void 0:e.firstElementChild)==null||i.classList.remove(Yf)},_y=t=>{var i;let e=t.previousElementSibling;e||(e=(i=t.parentNode)==null?void 0:i.lastElementChild),e==null||e.focus()},by=t=>{var i;let e=t.nextElementSibling;e||(e=(i=t.parentNode)==null?void 0:i.firstElementChild),e==null||e.focus()},$y=t=>{let e=t.code;return e==="Tab"&&!t.shiftKey||e==="ArrowDown"},yy=t=>{let e=t.code;return e==="Tab"||e==="ArrowUp"},H_=t=>t.code==="Escape",xy=t=>t.code==="ArrowLeft",Fd=(t,e=[])=>{let i=t.code;return["Enter","Space",...e].includes(i)},F_=t=>{$y(t)?(Dr(t),by(t.target)):yy(t)&&(Dr(t),_y(t.target))},pa=t=>!B_.device.isAndroid&&(t==null?void 0:t.detail)===0||B_.device.isAndroid&&(t==null?void 0:t.pointerType)==="",Dl=(t,e,i)=>gt(null,null,function*(){yield mo(),t&&!t.classList.contains("opened")&&!e&&ye(i)&&(yield mo(),i.set(!1),t.focus())}),U_=(t,e,i)=>gt(null,null,function*(){yield mo(),t&&!e&&ye(i)&&(i.set(!1),t.focus())}),Ud=(t,e,i,o=!1)=>gt(null,null,function*(){if(yield mo(),!!t&&e&&!o){let a=t.children[0];a==null||a.classList.toggle(Yf,!i),a==null||a.focus()}}),z_=(t,e)=>gt(null,null,function*(){setTimeout(()=>{let i=t[e];!!i&&i.focus()},100)}),Ou=(t,e)=>{F_(t),jf(t.target),H_(t)&&(Dr(t),e())},Du=(t,e)=>gt(null,null,function*(){Fd(t,["ArrowRight"])&&(Dr(t),e())}),W_=(t,e,i)=>gt(null,null,function*(){if(F_(t),xy(t)){Dr(t),e();return}H_(t)&&(Dr(t),i())}),Bl=(t,e)=>{Fd(t)&&(Dr(t),e())},K_=(t,e,i)=>{if(Fd(t))Dr(t),i(!e);else{let o=t.code;if(o==="ArrowLeft"&&e){i(!1),Dr(t);return}o==="ArrowRight"&&!e&&(i(!0),Dr(t))}},q_=t=>{let e=t.getBoundingClientRect(),i=-14,o=e.left+e.width,r=e.top+i;return{right:o,bottom:r}},Q_=t=>{if(!t)return{top:0,left:0};let e=t.getBoundingClientRect(),i=-58,o=8,r=e.left+o;return{bottom:e.bottom+i,left:r}};import{isNullable as Bu,isValidURL as Py}from"@vkontakte/videoplayer-shared/es2015";var ns={"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};import{noop as G_}from"@vkontakte/videoplayer-shared/es2015";var Sy=(t,e)=>{Bl(t,()=>e())},Cy=L('<li class="item s-1k" role="menuitem" tabindex="0"> </li>'),Ty={hash:"s-1k",code:".item.s-1k{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-1k:hover{background:rgba(66,66,66,.5);color:var(--white)}"};function Xf(t,e){B(e,!0),Q(t,Ty);let i=h(e,"onClick",3,G_),o=h(e,"closeContextMenu",3,G_),r=d=>{d==null||d.stopPropagation(),i()(),o()()};var a=Cy();a.__click=r,a.__keydown=[Sy,r];var l=C(a,!0);S(a),D(()=>{var d;Re(a,"aria-label",(d=e.ariaLabel)!=null?d:e.label),Re(a,"data-testid",e.id),ve(l,e.label)}),$(t,a),H()}Ye(["click","keydown"]);var Wa=(t,e)=>t.weight-e.weight;var zd=(o=>(o.OPEN_SUB_MENU="OPEN_SUB_MENU",o.CLICK="CLICK",o.SWITCH="SWITCH",o))(zd||{});var ky=(t,e)=>{Ou(t,e)},Ay=t=>{t.preventDefault()},Ly=L('<ul role="menu" data-testid="context-menu" class="s-r"></ul>'),My={hash:"s-r",code:"ul.s-r{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 Zf(t,e){B(e,!0),Q(t,My);let[i,o]=Oe(),r=()=>w(we,"$playerPhase",i),a=()=>w(ae,"$isLive$",i),l=()=>w(me,"$isPiPEnabled$",i),d=()=>w(X,"$chromecastState$",i),s=()=>w(ee,"$pictureInPictureApiIsActive$",i),u=()=>w(J,"$isLooped$",i),m=()=>w(Z,"$positionExact$",i),p=()=>w(z,"$additionalContextMenuItems$",i),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}=_o(),A=Vt(),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)}),O=f(()=>l()&&d()!==Iy.CONNECTED&&!re&&n(_e)&&!Ey.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)},ot=(fe,Ue)=>{if(!_()||!y())return;let ze=_().getBoundingClientRect(),Ct=y().getBoundingClientRect();N(x,fe-Ct.left),N(I,Ue-Ct.top),n(x)+ze.width>Ct.width&&N(x,Ct.width-ze.width),n(I)+ze.height>Ct.height&&N(I,Ct.height-ze.height),N(x,Math.max(n(x),0),!0),N(I,Math.max(n(I),0),!0)};De(()=>{gt(null,null,function*(){if(_()&&y()){yield mo();let{top:Ue,left:ze,bottom:Ct,right:si}=b(),xt=ze!=null?ze:0,Yt=Ue!=null?Ue:0,ci=_().getBoundingClientRect();Bu(ze)&&!Bu(si)&&(xt=si-ci.width),Bu(Ue)&&!Bu(Ct)&&(Yt=Ct-ci.height),xt=Math.max(xt,0),Yt=Math.max(Yt,0),ot(xt,Yt)}})});let ne=()=>{T.actions.internal.videoRotate()},ce=()=>{Py(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 Ue=new Blob([...fe],{type:"plain/text"}),ze=window.URL.createObjectURL(Ue);Ba(ze,"vk_player_debug_info","txt")}else Ol(T.actions.internal.getDebugTextData())},Le=()=>{let fe=T.actions.internal.getTraceTextData(),Ue=new Blob([...fe],{type:"application/json"}),ze=window.URL.createObjectURL(Ue);Ba(ze,"vk_player_trace_info","json")},et=()=>{E.set(!0)},Ee=()=>gt(null,null,function*(){var fe;try{U()}finally{(fe=e.returnFocus)==null||fe.call(e)}}),Te=()=>{T.actions.internal.setLooped(!u())},Fe=()=>{var fe,Ue;if(n(G)){let ze=(Ue=(fe=T.callbacks)==null?void 0:fe.onCopyEmbedCodeClicked)==null?void 0:Ue.call(fe);ze&&Ol(ze)}},It=(fe=!1)=>{var Ue,ze;if((Ue=T.callbacks)!=null&&Ue.onCopyVideoLink){let Ct=(ze=T.callbacks)==null?void 0:ze.onCopyVideoLink(fe,m());Ct&&Ol(Ct)}},wt=f(()=>A.features.saveDebugInfoToFile?F("menu_save_debug"):F("menu_copy_debug")),Dt=f(()=>n(pe)?{id:"copy-link",weight:ns["copy-link"],label:F("menu_copy_video_link"),onClick:()=>It()}:void 0),at=f(()=>n(Qe)?{id:"copy-link-timestamp",weight:ns["copy-link-timestamp"],label:F("menu_copy_video_link_with_timestamp"),onClick:()=>It(!0)}:void 0),Et=f(()=>n(G)?{id:"copy-embed-code",weight:ns["copy-embed-code"],label:F("menu_copy_embed_code"),onClick:Fe}:void 0),Zt=f(()=>n(O)?{id:"pip",weight:ns.pip,label:s()?F("menu_pip_close"):F("menu_pip"),onClick:Ee}:void 0),Pt=f(()=>n(Ge)?{id:"video-loop",weight:ns["video-loop"],label:u()?F("menu_video_loop_off"):F("menu_video_loop_on"),ariaLabel:F("aria_label_menu_loop"),onClick:Te}:void 0),Ot=f(()=>n(K)?{id:"rotate",weight:ns.rotate,label:F("menu_video_rotate"),ariaLabel:F("aria_label_menu_rotate"),onClick:ne}:void 0),zt=f(()=>n(se)?{id:"report",weight:ns.report,label:F("menu_report"),ariaLabel:`${F("menu_report")}. ${F("aria_label_new_tab_alert")}`,onClick:ce}:void 0),j=f(()=>({id:"save-debug",weight:ns["save-debug"],label:n(wt),onClick:Ne})),Pe=f(()=>n(xe)?{id:"save-trace",weight:ns["save-trace"],label:F("menu_save_debug"),onClick:Le}:void 0),le=f(()=>({id:"debug-info",weight:ns["debug-info"],label:F("menu_debug_overlay"),ariaLabel:F("aria_label_menu_debug_overlay"),onClick:et})),$e=f(()=>[n(Dt),n(at),n(Et),n(Zt),n(Pt),n(Ot),n(zt),n(j),n(Pe),n(le),...p()].filter(fe=>!!fe).sort(Wa));var Me=Ve(),dt=ue(Me);{var St=fe=>{var Ue=Ly();Ue.__contextmenu=[Ay],Ue.__keydown=[ky,He],bi(Ue,21,()=>n($e),ze=>ze.id,(ze,Ct)=>{Xf(ze,{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(Ue),Ze(Ue,ze=>_(ze),()=>_()),D(()=>{var ze,Ct;return qe(Ue,`top: ${(ze=n(I))!=null?ze:""}px; left: ${(Ct=n(x))!=null?Ct:""}px;`)}),$(fe,Ue)};V(dt,fe=>{v()&&fe(St)})}$(t,Me),H(),o()}Ye(["contextmenu","keydown"]);var Hu=class{constructor(e){this.value=e,this.next=null}};var Hl=class{constructor(e){this.top=null,this.bottom=null,this.size=0,this.maxSize=e}push(e){let i=new Hu(e);this.top?(this.top.next=i,this.top=i):(this.top=i,this.bottom=i),this.size++,this.size>this.maxSize&&this.bottom&&(this.bottom=this.bottom.next)}getValuesFromBottom(){let e=[],i=this.bottom;for(;i;)e.push(i.value),i=i.next;return e}};var Vy=L('<div class="container s-1i"><canvas class="s-1i"></canvas></div>'),Ry={hash:"s-1i",code:".container.s-1i{display:inline-block;height:16px;width:120px}canvas.s-1i{margin-top:2px;transform:scaleY(-1)}"};function Wd(t,e){B(e,!0),Q(t,Ry);let i=h(e,"values",19,()=>[]),o=q(void 0),r=q(null),a=16,l=120,d=60,s=l/d;Mt(()=>{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)}De(()=>{let v="";if(n(r)){let b=i()[0];for(let _=1;_<i().length;_++)i()[_]>b&&(b=i()[_]);n(r).clearRect(0,0,l,a);let y=d-1;for(let _=i().length-1;_>=0;_--){let x=y*s,I=b>0?a*(i()[_]/b):0;u(n(r),x,0,s,I),v=I+" "+v,y--}}});var m=Vy(),p=C(m);Ze(p,v=>N(o,v),()=>n(o)),S(m),$(t,m),H()}import{safeStorage as Y_}from"@vkontakte/videoplayer-shared/es2015";var Ny=(t,e)=>{t.stopPropagation(),Y_.remove(Pd),e.set(!1)},Oy=L('<div class="s-o"><div class="s-o">Video id</div> <span> </span></div>'),Dy=L('<div class="s-o"><div class="s-o">VSID</div> <span> </span></div>'),By=L('<div class="s-o"><div class="s-o">Provider</div> <span> </span></div>'),Hy=L('<div class="s-o"><div class="s-o">Streams</div> <span> </span></div>'),Fy=L('<div class="s-o"><div class="s-o">Viewport</div> <span> </span></div>'),Uy=L('<div class="s-o"><div class="s-o">Video size</div> <span> </span></div>'),zy=L('<div class="s-o"><div class="s-o">CDN host</div> <span> </span></div>'),Wy=L('<div class="s-o"><div class="s-o">Volume</div> <span> </span></div>'),Ky=L('<div class="s-o"><div class="s-o">Position</div> <span> </span></div>'),qy=L('<div class="s-o"><div class="s-o">Buffer</div> <span> </span></div>'),Qy=L('<div class="s-o"><div class="s-o">Nbuffer</div> <span> </span></div>'),Gy=L('<div class="s-o"><div class="s-o">Live latency</div> <span> </span></div>'),Yy=L('<div class="s-o"><div class="s-o">Segment</div> <span> </span></div>'),jy=L('<div class="s-o"><div class="s-o">Network</div> <!> <span> </span></div>'),Xy=L('<div class="s-o"><div class="s-o">V bitrate</div> <!> <span> </span></div>'),Zy=L('<div role="region"><button class="close s-o" title="закрыть">[x]</button> <div class="content s-o"><div class="s-o"><div class="s-o">Version</div> <span> </span></div> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <div class="s-o"><div class="s-o">Dropped</div> <span> </span></div> <!> <!> <div class="s-o"><div class="s-o">FPS</div> <!> <span> </span></div></div></div>'),Jy={hash:"s-o",code:".container.s-o{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-o{left:16px;top:16px}button.close.s-o{background-color:transparent;border:none;color:#fff;cursor:pointer;outline:0;padding:0;position:absolute;right:5px;top:3px}.content.s-o{padding:5px}.content.s-o>div:where(.s-o)>div:where(.s-o){display:inline-block;padding:0 5px;text-align:right;width:60px}"};function Kd(t,e){B(e,!0),Q(t,Jy);let[i,o]=Oe(),r=()=>w(d,"$isMobile",i),a=be(),l=a.ui.debugPanelVisible,d=a.ui.isMobile,s=q(li(a.actions.internal.getDebugPanelData())),u=a.actions.internal.getVideoElement(),m=q(0),p=q(0),v=q(0),b=new Hl(60),y=new Hl(60),_=new Hl(60),x=q(li([])),I=q(li([])),T=q(li([])),R=Y("aria_label_debug_panel");Mt(()=>{Y_.set(Pd,"true"),a.actions.internal.startLogging(),u&&(N(p,u.getVideoPlaybackQuality().droppedVideoFrames,!0),N(m,u.getVideoPlaybackQuality().totalVideoFrames,!0));let j=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(j),Pe&&clearInterval(Pe)}});var A=Zy();let P;var E=C(A);E.__click=[Ny,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=j=>{var Pe=Oy(),le=k(C(Pe),2),$e=C(le,!0);S(le),S(Pe),D(()=>ve($e,n(s).id)),$(j,Pe)};V(ae,j=>{n(s).id&&j(Z)})}var re=k(ae,2);{var J=j=>{var Pe=Dy(),le=k(C(Pe),2),$e=C(le,!0);S(le),S(Pe),D(()=>ve($e,n(s).vsid)),$(j,Pe)};V(re,j=>{n(s).vsid&&j(J)})}var we=k(re,2);{var me=j=>{var Pe=By(),le=k(C(Pe),2),$e=C(le,!0);S(le),S(Pe),D(()=>ve($e,n(s).provider)),$(j,Pe)};V(we,j=>{n(s).provider&&j(me)})}var ee=k(we,2);{var _e=j=>{var Pe=Hy(),le=k(C(Pe),2),$e=C(le);S(le),S(Pe),D(()=>{var Me,dt;return ve($e,`Video: ${(Me=n(s).videoCodec||"")!=null?Me:""} ${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"},S_=z1;var Os=new Map;Os.set(T_.EN,S_);Os.set(T_.RU,w_);var I_=new Map,Bf=({language:i,pack:e,fallback:t})=>{if(Os.has(i)){let o=Os.get(i);Os.set(i,Me(Me({},o),e))}else Os.set(i,e);I_.set(i,t)},Hf=i=>Os.has(i),Ff=(i,e,t,o)=>{var l;let r=Os.get(i),a=r==null?void 0:r[e];if(C_(a)){let d=(l=I_.get(i))!=null?l:o,s=d?Os.get(d):void 0;a=s==null?void 0:s[e]}return C_(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}=xe(),o=$e(t),r=Rt();return Ff(o,i,e,r.defaultLanguage)};var W1=Pe('<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 Ld(i,e){B(e,!1);let t=Y("video360");Yo(),Ze(i,{width:"76",height:"45",get ariaLabel(){return t},testId:"video-360-icon",shadow:!0,children:(o,r)=>{var a=W1();$(o,a)},$$slots:{default:!0}}),H()}import"@vkontakte/videoplayer-core/es2015";var Ml;(function(i){i.fatal="fatal",i.error="error",i.warning="warning",i.log="log",i.info="info",i.debug="debug",i.critical="critical"})(Ml||(Ml={}));var K1=/^\s*at (?:(.*?) ?\()?((?:file|https?|blob|chrome-extension|address|native|eval|webpack|<anonymous>|[-a-z]+:|.*bundle|\/).*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,q1=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:file|https?|blob|chrome|webpack|resource|moz-extension).*?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js))(?::(\d+))?(?::(\d+))?\s*$/i,Q1=/^\s*at (?:((?:\[object object\])?.+) )?\(?((?:file|ms-appx|https?|webpack|blob):.*?):(\d+)(?::(\d+))?\)?\s*$/i,Cu="?",G1="X-Sentry-Auth",Y1=/^(?:(\w+):)\/\/(?:([\w-]+)(?::(\w+))?@)([\w.-]+)(?::(\d+))?\/(.+)/;function j1(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=K1.exec(t[a]))r={filename:o[2]&&o[2].indexOf("address at ")===0?o[2].substr(11):o[2],function:o[1]||Cu,lineno:o[3]?+o[3]:null,colno:o[4]?+o[4]:null};else if(o=Q1.exec(t[a]))r={filename:o[2],function:o[1]||Cu,lineno:+o[3],colno:o[4]?+o[4]:null};else if(o=q1.exec(t[a]))a===0&&!o[5]&&i.columnNumber!==void 0&&(e[0].column=i.columnNumber+1),r={filename:o[3],function:o[1]||Cu,lineno:o[4]?+o[4]:null,colno:o[5]?+o[5]:null};else continue;!r.function&&r.lineno&&(r.function=Cu),e.push(r)}return e.length?{value:E_(i),type:i.name,stacktrace:{frames:e.reverse()}}:null}function E_(i){return(i&&i.message||"No error message").split(`
56
+ `).filter(t=>!!t)[0]}function X1(i){try{let e=j1(i);if(e)return e}catch(e){}return{value:E_(i),type:i&&i.name,stacktrace:{frames:[]}}}function Z1(){return"xxxxxxxxxxxx4xxxyxxxxxxxxxxxxxxx".replace(/[xy]/g,i=>{let e=Math.random()*16|0;return(i==="x"?e:e&3|8).toString(16)})}var Tu=class{constructor(e){if(e&&e.dsn){let t=Y1.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 Qt(Me({},this.getRequestBlank()),{exception:{values:[X1(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(G1,this.authHeader||""),t.send(JSON.stringify(e))}getRequestBlank(){return{platform:"javascript",event_id:Z1(),sdk:{name:"micro-sentry.javascript.core",version:"0.0.0"},timestamp:Date.now()/1e3,environment:this.environment}}};function P_(i,e){return Object.prototype.toString.call(e)==="[object RegExp]"?e.test(i):typeof e=="string"?i.indexOf(e)!==-1:!1}function J1(){return window}var Iu=class i extends Tu{constructor(e,t=J1()){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",Me({},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",Me({},e)),this}setUser(e){return this.setKeyState("user",Me({},e)),this}clone(){let e=new i(Qt(Me({},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:[Me({timestamp:Date.now()/1e3},this.beforeBreadcrumb(e))]})}setBreadcrumbs(e){this.setKeyState("breadcrumbs",e)}captureMessage(e,t){this.send(Qt(Me({},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=>P_(t,o))):!1}getRequestBlank(){return Me(Qt(Me({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(Me({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=>P_(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 Qt(Me({},t),{[o]:a||d?[...a||[],...d||[]]:Me(Me({},typeof r!="string"?r:{}),typeof l!="string"?l:{})})},this._state)}setKeyState(e,t){this._state[e]=t}};import{isNonNullable as Eu,Subscription as ey}from"@vkontakte/videoplayer-shared/es2015";var Pu=null,Ba=class{constructor(e,t,o={}){!Pu&&e.dsn&&(this.sentryClient=new Iu({dsn:e.dsn,environment:t.env}),this.version=t.version,this.sentrySubscription=new ey,this.options=e,this.context=o,Pu=this)}destroy(){var e,t;(e=this.sentryClient)==null||e.destroy(),(t=this.sentrySubscription)==null||t.unsubscribe(),Pu=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(Eu(b)&&p.includes(b)||Eu(v)&&m.includes(v))return;if(Math.random()<=d||Eu(b)&&u.includes(b)||Eu(v)&&s.includes(v)){Object.keys(t).length&&r.setTags(Me({version:this.version},t)),(Object.keys(a).length||Object.keys(o).length)&&r.setExtras(Me(Me({},a),o));try{v&&r.captureMessage(v,t.fatal?Ml.fatal:Ml.error),r.report(e)}catch(_){console.error(_)}}}static getInstance(){return Pu}};var bs=(d=>(d.Thumb="thumb",d.Video="video",d.Ads="ads",d.Crashed="crashed",d.LiveWaitingStart="LiveWaitingStart",d.LiveWaitingRecover="LiveWaitingRecover",d.LiveWaitingRecord="LiveWaitingRecord",d))(bs||{});var Au=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()},ku=i=>i.exitFullscreen?i.exitFullscreen():i.msExitFullscreen?i.msExitFullscreen():i.webkitExitFullscreen?i.webkitExitFullscreen():i.mozCancelFullScreen?i.mozCancelFullScreen():Promise.reject(),A_=(i,e)=>e?!0:i.fullscreenEnabled||!!i.webkitFullscreenEnabled||!!i.mozFullscreenEnabled||!!i.msFullscreenEnabled,k_=i=>{let e=i;e!=null&&e.webkitExitFullscreen&&(e==null||e.webkitExitFullscreen())},Md=()=>{let i=document;return i.fullscreenElement||i.mozFullScreenElement||i.webkitFullscreenElement||i.msFullscreenElement},sa=()=>!!Md(),Lu=i=>{document.addEventListener("fullscreenchange",i),document.addEventListener("webkitfullscreenchange",i),document.addEventListener("mozfullscreenchange",i),document.addEventListener("MSFullscreenChange",i)},Mu=i=>{document.removeEventListener("fullscreenchange",i),document.removeEventListener("webkitfullscreenchange",i),document.removeEventListener("mozfullscreenchange",i),document.removeEventListener("MSFullscreenChange",i)},L_=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))};import{clientChecker as M_}from"@vkontakte/videoplayer-core/es2015";var V_=()=>({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:M_.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:M_.device.isApple?Y("hotkey_map_item_next_episode_mac_value"):Y("hotkey_map_item_next_episode_pc_value")}]}]});import{devNull as R_,now as O_}from"@vkontakte/videoplayer-shared/es2015";function Uf(i,e){B(e,!1);let t=xe();Vt(()=>{t.getAdmanWrapper().startPostroll()}),Yo(),H()}import{noop as oy}from"@vkontakte/videoplayer-shared/es2015";var ty=Pe('<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=Pe('<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()?ra:"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=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 ny=(i,e,t)=>{i.stopPropagation(),n(e)&&t()()},ry=L('<div class="skip s-1d"> <!></div>'),sy=L("<div><!></div>"),ay={hash:"s-1d",code:".container.s-1d{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-1d{bottom:14px;font-size:15px;max-width:142px;top:unset}.skip.s-1d{align-items:flex-end;display:flex;gap:4px;white-space:nowrap}.skippable.s-1d{color:var(--white);cursor:pointer}.skippable.s-1d:hover{color:hsla(0,0%,100%,.75)}"};function zf(i,e){B(e,!0),Q(i,ay);let[t,o]=Be(),r=()=>w(u,"$isMobile",t),a=h(e,"position",3,0),l=h(e,"secondsToWatchBeforeSkip",3,0),d=h(e,"skipAd",3,oy),u=xe().ui.isMobile,m=f(()=>a()>0&&a()>=l());var p=sy();let v;p.__click=[ny,m,d];var b=T(p);{var y=x=>{var I=ry(),C=T(I),R=A(C);Nr(R,{direction:"right"}),S(I),D(k=>he(C,`${k!=null?k:""} `),[()=>Y("skip_ads_now")]),$(x,I)},_=x=>{var I=gs();D(C=>he(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),D(x=>v=ne(p,1,"container s-1d",null,v,x),[()=>({"container-mobile":r(),skippable:n(m)})]),$(i,p),H(),o()}Je(["click"]);var ly=L('<button class="go-to-site s-1c"> </button>'),dy={hash:"s-1c",code:"button.go-to-site.s-1c{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 Wf(i,e){B(e,!1),Q(i,dy),Yo();var t=ly(),o=T(t,!0);S(t),D(r=>he(o,r),[()=>Y("visit_advertiser")],lr),$(i,t),H()}var cy=L('<div class="top-gradient-mobile s-i"></div>'),uy=L('<div class="container s-i"><!> <video style="width: 100%; height: 100%" playsinline=""></video> <!> <!> <!></div>',2),py={hash:"s-i",code:".container.s-i{height:100%;width:100%}.top-gradient-mobile.s-i{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 Vd(i,e){B(e,!0),Q(i,py);let[t,o]=Be(),r=()=>w(U,"$canSkipAd",t),a=()=>w(F,"$adPlaybackState",t),l=()=>w(R,"$isMobile",t),d=()=>w(j,"$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=xe(),I=Rt(),C=x.state.isEnded$,R=x.ui.isMobile,k=I.ads.isMobileGoToSiteButton,P=K(void 0),E=K(void 0),W=!1,F=x.ads.playbackState,U=x.ads.canSkip,j=x.ads.position,se=x.ads.secondsToWatchBeforeSkip,G=f(()=>r()&&a()!=="inactive"),re=f(()=>l()&&a()!=="inactive"&&k);Vt(()=>{let Z=x.getAdmanWrapper();if(R_.push("ui",{key:"videoplayer_embed",strings:["new","adman_ads_mount"],numbers:[O_(),m()]}),!m()){Z.onAdmanLoadingError();return}let N=()=>{var ke;let{width:ge,height:ze}=$e(x.ui.playerSize),ie=$e(x.ui.isFullscreen),We=(ke=v())!=null?ke:$e(x.ui.isAutoplay),ee=I.ads.paramsOverride;return{width:ge,height:ze,isFullscreen:ie,isAutoplay:We,adsContainer:n(P),adsVideoElement:n(E),slotId:m(),params:p(),paramsOverride:ee,duration:b(),externalApi:y(),json:_()}},ce=ge=>ht(null,null,function*(){ge&&(yield ho());let ze=N();yield Z.initAdman(ze),W=!0}),de=new AbortController,_e=()=>{de.abort()};return window.AdmanHTML?ce(!0).catch(()=>{Z.onAdmanLoadingError()}):Z.loadAdman(de.signal).then(()=>ce(!1)).catch(()=>{Z.onAdmanLoadingError()}),()=>{R_.push("ui",{key:"videoplayer_embed",strings:["new","adman_ads_unmount"],numbers:[O_(),m()]}),!W&&_e()}});var X=uy(),Te=T(X);{var ue=Z=>{var N=cy();$(Z,N)};V(Te,Z=>{l()&&Z(ue)})}var te=A(Te,2);it(te,Z=>O(E,Z),()=>n(E));var be=A(te,2);{var Ce=Z=>{zf(Z,{get position(){return d()},get secondsToWatchBeforeSkip(){return s()},get skipAd(){return x.actions.internal.skipAd}})};V(be,Z=>{n(G)&&Z(Ce)})}var me=A(be,2);{var qe=Z=>{Uf(Z,{})};V(me,Z=>{u()&&Z(qe)})}var ve=A(me,2);{var pe=Z=>{Wf(Z,{})};V(ve,Z=>{n(re)&&Z(pe)})}S(X),it(X,Z=>O(P,Z),()=>n(P)),$(i,X),H(),o()}var jo=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 fy=Pe('<path fill="#fff"></path>'),my=Pe("<path></path><!>",1);function Rd(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=my(),u=le(s),m=A(u);{var p=v=>{var b=fy();De(b,"d",a),$(v,b)};V(m,v=>{t()&&v(p)})}D(()=>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 vy=L('<div class="equalizer s-c"><div class="col s-c"></div> <div class="col s-c"></div> <div class="col s-c"></div></div>'),gy=L('<div class="live-icon s-c"><!></div>'),hy=L('<span class="text s-c"> </span>'),_y=L("<div><!> <!></div>"),by={hash:"s-c",code:".wrapper.s-c{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-c{background:var(--red);border-radius:2px;font-size:0;height:20px;line-height:20px;padding:0 7px}.equalizer.s-c{display:inline-block;height:10px;margin-right:4px;margin-top:-4px;position:relative;vertical-align:middle;width:10px}.live.s-c .equalizer:where(.s-c){margin-top:-2px}.equalizer.s-c .col:where(.s-c){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-c .equalizer:where(.s-c) .col:where(.s-c){animation-play-state:running}.equalizer.s-c .col:where(.s-c):first-child{animation-name:s-c-thumb-timer-equalizer-col1;left:0}.equalizer.s-c .col:where(.s-c):nth-child(2){animation-name:s-c-thumb-timer-equalizer-col2;left:3px}.equalizer.s-c .col:where(.s-c):nth-child(3){animation-name:s-c-thumb-timer-equalizer-col3;left:6px}.live-icon.s-c{display:inline-block;height:20px;margin:0 -7px;vertical-align:middle;width:42px}@keyframes s-c-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-c-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-c-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-c{color:var(--controls-time);font-size:13px;font-weight:500;line-height:16px}"};function Od(i,e){Q(i,by);let t=h(e,"withEqualizer",3,!1),o=h(e,"isLive",3,!1),r=h(e,"isPlaying",3,!1);var a=_y();let l;var d=T(a);{var s=v=>{var b=vy();$(v,b)};V(d,v=>{t()&&v(s)})}var u=A(d,2);{var m=v=>{var b=gy(),y=T(b);Rd(y,{isActive:!0}),S(b),$(v,b)},p=v=>{var b=hy(),y=T(b,!0);S(b),D(()=>he(y,e.time)),$(v,b)};V(u,v=>{o()?v(m):v(p,!1)})}S(a),D(v=>l=ne(a,1,"wrapper s-c",null,l,v),[()=>({live:o(),playing:r()})]),$(i,a)}var Vl=(i,e,t)=>{let o;return()=>(window.clearTimeout(o),i?o=window.setTimeout(()=>e.set(!0),t):e.set(!1),()=>window.clearTimeout(o))};var $y=L('<div role="timer" data-testid="thumb-timer"><!></div>'),yy={hash:"s-k",code:".thumb-timer.s-k{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 Dd(i,e){B(e,!0),Q(i,yy);let[t,o]=Be(),r=()=>w(m,"$disabled",t),a=h(e,"isHidden",3,!1),l=h(e,"isLive",3,!1),d=h(e,"isPlaying",3,!1),s=Rt(),u=f(()=>jo(e.duration-e.position)),m=ae(!1);var p=$y();let v;var b=T(p);Od(b,{get time(){return n(u)},get isLive(){return l()},get isPlaying(){return d()},withEqualizer:!0}),S(p),Vs(p,()=>Vl(a()&&s.features.usePerformanceFix,m,s.disableInvisibleComponentsTimeout)),D(y=>v=ne(p,1,"thumb-timer s-k",null,v,y),[()=>({"out-of-flow":r(),hidden:a()})]),$(i,p),H(),o()}var Rl=i=>{if(!navigator.clipboard){D_(i);return}navigator.clipboard.writeText(i).catch(()=>D_(i))};function D_(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)}}}import{ChromecastState as Ly,clientChecker as My}from"@vkontakte/videoplayer-core/es2015";import{clientChecker as N_}from"@vkontakte/videoplayer-core/es2015";var Kf="focus-hidden";var Br=i=>{i.stopPropagation(),i.preventDefault()},qf=i=>{var e,t;(t=(e=i.parentNode)==null?void 0:e.firstElementChild)==null||t.classList.remove(Kf)},wy=i=>{var t;let e=i.previousElementSibling;e||(e=(t=i.parentNode)==null?void 0:t.lastElementChild),e==null||e.focus()},Sy=i=>{var t;let e=i.nextElementSibling;e||(e=(t=i.parentNode)==null?void 0:t.firstElementChild),e==null||e.focus()},Cy=i=>{let e=i.code;return e==="Tab"&&!i.shiftKey||e==="ArrowDown"},Ty=i=>{let e=i.code;return e==="Tab"||e==="ArrowUp"},B_=i=>i.code==="Escape",Iy=i=>i.code==="ArrowLeft",Nd=(i,e=[])=>{let t=i.code;return["Enter","Space",...e].includes(t)},H_=i=>{Cy(i)?(Br(i),Sy(i.target)):Ty(i)&&(Br(i),wy(i.target))},da=i=>!N_.device.isAndroid&&(i==null?void 0:i.detail)===0||N_.device.isAndroid&&(i==null?void 0:i.pointerType)==="",Ol=(i,e,t)=>ht(null,null,function*(){yield ho(),i&&!i.classList.contains("opened")&&!e&&$e(t)&&(yield ho(),t.set(!1),i.focus())}),F_=(i,e,t)=>ht(null,null,function*(){yield ho(),i&&!e&&$e(t)&&(t.set(!1),i.focus())}),Bd=(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(Kf,!t),a==null||a.focus()}}),U_=(i,e)=>ht(null,null,function*(){setTimeout(()=>{let t=i[e];!!t&&t.focus()},100)}),Vu=(i,e)=>{H_(i),qf(i.target),B_(i)&&(Br(i),e())},Ru=(i,e)=>ht(null,null,function*(){Nd(i,["ArrowRight"])&&(Br(i),e())}),z_=(i,e,t)=>ht(null,null,function*(){if(H_(i),Iy(i)){Br(i),e();return}B_(i)&&(Br(i),t())}),Dl=(i,e)=>{Nd(i)&&(Br(i),e())},W_=(i,e,t)=>{if(Nd(i))Br(i),t(!e);else{let o=i.code;if(o==="ArrowLeft"&&e){t(!1),Br(i);return}o==="ArrowRight"&&!e&&(t(!0),Br(i))}},K_=i=>{let e=i.getBoundingClientRect(),t=-14,o=e.left+e.width,r=e.top+t;return{right:o,bottom:r}},q_=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}};import{isNullable as Ou,isValidURL as Vy}from"@vkontakte/videoplayer-shared/es2015";var is={"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};import{noop as Q_}from"@vkontakte/videoplayer-shared/es2015";var Py=(i,e)=>{Dl(i,()=>e())},Ay=L('<li class="item s-1l" role="menuitem" tabindex="0"> </li>'),ky={hash:"s-1l",code:".item.s-1l{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-1l:hover{background:rgba(66,66,66,.5);color:var(--white)}"};function Qf(i,e){B(e,!0),Q(i,ky);let t=h(e,"onClick",3,Q_),o=h(e,"closeContextMenu",3,Q_),r=d=>{d==null||d.stopPropagation(),t()(),o()()};var a=Ay();a.__click=r,a.__keydown=[Py,r];var l=T(a,!0);S(a),D(()=>{var d;De(a,"aria-label",(d=e.ariaLabel)!=null?d:e.label),De(a,"data-testid",e.id),he(l,e.label)}),$(i,a),H()}Je(["click","keydown"]);var Fa=(i,e)=>i.weight-e.weight;var Hd=(o=>(o.OPEN_SUB_MENU="OPEN_SUB_MENU",o.CLICK="CLICK",o.SWITCH="SWITCH",o))(Hd||{});var Ry=(i,e)=>{Vu(i,e)},Oy=i=>{i.preventDefault()},Dy=L('<ul role="menu" data-testid="context-menu" class="s-u"></ul>'),Ny={hash:"s-u",code:"ul.s-u{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 Gf(i,e){B(e,!0),Q(i,Ny);let[t,o]=Be(),r=()=>w(Te,"$playerPhase",t),a=()=>w(se,"$isLive$",t),l=()=>w(ue,"$isPiPEnabled$",t),d=()=>w(j,"$chromecastState$",t),s=()=>w(te,"$pictureInPictureApiIsActive$",t),u=()=>w(X,"$isLooped$",t),m=()=>w(G,"$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=xe(),{pictureInPicture$:R}=xo(),k=Rt(),P=C.ui.contextMenu.visible$,E=C.ui.debugPanelVisible,W=C.ui.additionalContextMenuItems$,F=C.ui.t,U=C.actions.internal.togglePictureInPicture,j=C.state.chromecastState$,se=C.state.isLive$,G=C.state.positionExact$,re=C.state.isInteractive,X=C.state.looped$,Te=C.playerPhase,{isEnabled$:ue,isActive$:te}=R,be=f(()=>r()==="video"),Ce=f(()=>!!a()&&n(be)),me=f(()=>["thumb","LiveWaitingStart","LiveWaitingRecover","LiveWaitingRecord"].includes(r())),qe=f(()=>{var ye;return k.features.copyVideoLink&&((ye=C.callbacks)==null?void 0:ye.onCopyVideoLink)}),ve=f(()=>n(qe)&&!n(me)&&!re&&!n(Ce)),pe=f(()=>{var ye;return!!((ye=C.callbacks)!=null&&ye.onCopyEmbedCodeClicked)}),Z=f(()=>l()&&d()!==Ly.CONNECTED&&!re&&n(be)&&!My.browser.isFirefox),N=f(()=>!re&&!n(me)&&!n(Ce)),ce=f(()=>k.features.videoRotate&&!re&&!n(me)),de=f(()=>k.showSupport&&!s()),_e=f(()=>k.features.saveTraceInfoToFile),ge=()=>{var ye;P.set(!1),(ye=e.returnFocus)==null||ye.call(e)},ze=(ye,Fe)=>{if(!_()||!y())return;let Qe=_().getBoundingClientRect(),rt=y().getBoundingClientRect();O(x,ye-rt.left),O(I,Fe-rt.top),n(x)+Qe.width>rt.width&&O(x,rt.width-Qe.width),n(I)+Qe.height>rt.height&&O(I,rt.height-Qe.height),O(x,Math.max(n(x),0),!0),O(I,Math.max(n(I),0),!0)};He(()=>{ht(null,null,function*(){if(_()&&y()){yield ho();let{top:Fe,left:Qe,bottom:rt,right:Kt}=b(),Nt=Qe!=null?Qe:0,ai=Fe!=null?Fe:0,$i=_().getBoundingClientRect();Ou(Qe)&&!Ou(Kt)&&(Nt=Kt-$i.width),Ou(Fe)&&!Ou(rt)&&(ai=rt-$i.height),Nt=Math.max(Nt,0),ai=Math.max(ai,0),ze(Nt,ai)}})});let ie=()=>{C.actions.internal.videoRotate()},We=()=>{Vy(e.supportLink)&&window.open(e.supportLink,"_blank"),C.actions.internal.reportProblem(),C.actions.internal.pause()},ee=()=>{let ye=C.actions.internal.getDebugTextData();if(k.features.saveDebugInfoToFile){let Fe=new Blob([...ye],{type:"plain/text"}),Qe=window.URL.createObjectURL(Fe);Na(Qe,"vk_player_debug_info","txt")}else Rl(C.actions.internal.getDebugTextData())},ke=()=>{let ye=C.actions.internal.getTraceTextData(),Fe=new Blob([...ye],{type:"application/json"}),Qe=window.URL.createObjectURL(Fe);Na(Qe,"vk_player_trace_info","json")},Ue=()=>{E.set(!0)},Ie=()=>ht(null,null,function*(){var ye;try{U()}finally{(ye=e.returnFocus)==null||ye.call(e)}}),Ae=()=>{C.actions.internal.setLooped(!u())},Ne=()=>{var ye,Fe;if(n(pe)){let Qe=(Fe=(ye=C.callbacks)==null?void 0:ye.onCopyEmbedCodeClicked)==null?void 0:Fe.call(ye);Qe&&Rl(Qe)}},gt=(ye=!1)=>{var Fe,Qe;if((Fe=C.callbacks)!=null&&Fe.onCopyVideoLink){let rt=(Qe=C.callbacks)==null?void 0:Qe.onCopyVideoLink(ye,m());rt&&Rl(rt)}},It=f(()=>k.features.saveDebugInfoToFile?F("menu_save_debug"):F("menu_copy_debug")),Lt=f(()=>n(qe)?{id:"copy-link",weight:is["copy-link"],label:F("menu_copy_video_link"),onClick:()=>gt()}:void 0),lt=f(()=>n(ve)?{id:"copy-link-timestamp",weight:is["copy-link-timestamp"],label:F("menu_copy_video_link_with_timestamp"),onClick:()=>gt(!0)}:void 0),Et=f(()=>n(pe)?{id:"copy-embed-code",weight:is["copy-embed-code"],label:F("menu_copy_embed_code"),onClick:Ne}:void 0),jt=f(()=>n(Z)?{id:"pip",weight:is.pip,label:s()?F("menu_pip_close"):F("menu_pip"),onClick:Ie}:void 0),zt=f(()=>n(N)?{id:"video-loop",weight:is["video-loop"],label:u()?F("menu_video_loop_off"):F("menu_video_loop_on"),ariaLabel:F("aria_label_menu_loop"),onClick:Ae}:void 0),Ot=f(()=>n(ce)?{id:"rotate",weight:is.rotate,label:F("menu_video_rotate"),ariaLabel:F("aria_label_menu_rotate"),onClick:ie}:void 0),Wt=f(()=>n(de)?{id:"report",weight:is.report,label:F("menu_report"),ariaLabel:`${F("menu_report")}. ${F("aria_label_new_tab_alert")}`,onClick:We}:void 0),q=f(()=>({id:"save-debug",weight:is["save-debug"],label:n(It),onClick:ee})),Le=f(()=>n(_e)?{id:"save-trace",weight:is["save-trace"],label:F("menu_save_debug"),onClick:ke}:void 0),Re=f(()=>({id:"debug-info",weight:is["debug-info"],label:F("menu_debug_overlay"),ariaLabel:F("aria_label_menu_debug_overlay"),onClick:Ue})),we=f(()=>[n(Lt),n(lt),n(Et),n(jt),n(zt),n(Ot),n(Wt),n(q),n(Le),n(Re),...p()].filter(ye=>!!ye).sort(Fa));var Ke=Oe(),Se=le(Ke);{var yt=ye=>{var Fe=Dy();Fe.__contextmenu=[Oy],Fe.__keydown=[Ry,ge],bi(Fe,21,()=>n(we),Qe=>Qe.id,(Qe,rt)=>{Qf(Qe,{get id(){return n(rt).id},get label(){return n(rt).label},get ariaLabel(){return n(rt).ariaLabel},get onClick(){return n(rt).onClick},closeContextMenu:ge})}),S(Fe),it(Fe,Qe=>_(Qe),()=>_()),D(()=>{var Qe,rt;return je(Fe,`top: ${(Qe=n(I))!=null?Qe:""}px; left: ${(rt=n(x))!=null?rt:""}px;`)}),$(ye,Fe)};V(Se,ye=>{v()&&ye(yt)})}$(i,Ke),H(),o()}Je(["contextmenu","keydown"]);var Du=class{constructor(e){this.value=e,this.next=null}};var Nl=class{constructor(e){this.top=null,this.bottom=null,this.size=0,this.maxSize=e}push(e){let t=new Du(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 By=L('<div class="container s-1a"><canvas class="s-1a"></canvas></div>'),Hy={hash:"s-1a",code:".container.s-1a{display:inline-block;height:16px;width:120px}canvas.s-1a{margin-top:2px;transform:scaleY(-1)}"};function Fd(i,e){B(e,!0),Q(i,Hy);let t=h(e,"values",19,()=>[]),o=K(void 0),r=K(null),a=16,l=120,d=60,s=l/d;Vt(()=>{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)}He(()=>{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=By(),p=T(m);it(p,v=>O(o,v),()=>n(o)),S(m),$(i,m),H()}import{safeStorage as G_}from"@vkontakte/videoplayer-shared/es2015";var Fy=(i,e)=>{i.stopPropagation(),G_.remove(Id),e.set(!1)},Uy=L('<div class="s-h"><div class="s-h">Video id</div> <span> </span></div>'),zy=L('<div class="s-h"><div class="s-h">VSID</div> <span> </span></div>'),Wy=L('<div class="s-h"><div class="s-h">Provider</div> <span> </span></div>'),Ky=L('<div class="s-h"><div class="s-h">Streams</div> <span> </span></div>'),qy=L('<div class="s-h"><div class="s-h">Viewport</div> <span> </span></div>'),Qy=L('<div class="s-h"><div class="s-h">Video size</div> <span> </span></div>'),Gy=L('<div class="s-h"><div class="s-h">CDN host</div> <span> </span></div>'),Yy=L('<div class="s-h"><div class="s-h">Volume</div> <span> </span></div>'),jy=L('<div class="s-h"><div class="s-h">Position</div> <span> </span></div>'),Xy=L('<div class="s-h"><div class="s-h">Buffer</div> <span> </span></div>'),Zy=L('<div class="s-h"><div class="s-h">Nbuffer</div> <span> </span></div>'),Jy=L('<div class="s-h"><div class="s-h">Live latency</div> <span> </span></div>'),e0=L('<div class="s-h"><div class="s-h">Segment</div> <span> </span></div>'),t0=L('<div class="s-h"><div class="s-h">Network</div> <!> <span> </span></div>'),i0=L('<div class="s-h"><div class="s-h">V bitrate</div> <!> <span> </span></div>'),o0=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>'),n0={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 Ud(i,e){B(e,!0),Q(i,n0);let[t,o]=Be(),r=()=>w(d,"$isMobile",t),a=xe(),l=a.ui.debugPanelVisible,d=a.ui.isMobile,s=K(ci(a.actions.internal.getDebugPanelData())),u=a.actions.internal.getVideoElement(),m=K(0),p=K(0),v=K(0),b=new Nl(60),y=new Nl(60),_=new Nl(60),x=K(ci([])),I=K(ci([])),C=K(ci([])),R=Y("aria_label_debug_panel");Vt(()=>{G_.set(Id,"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 Re=u.getVideoPlaybackQuality().totalVideoFrames;O(v,Re-n(m)),O(m,Re,!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 k=o0();let P;var E=T(k);E.__click=[Fy,l];var W=A(E,2),F=T(W),U=A(T(F),2),j=T(U,!0);S(U),S(F);var se=A(F,2);{var G=q=>{var Le=Uy(),Re=A(T(Le),2),we=T(Re,!0);S(Re),S(Le),D(()=>he(we,n(s).id)),$(q,Le)};V(se,q=>{n(s).id&&q(G)})}var re=A(se,2);{var X=q=>{var Le=zy(),Re=A(T(Le),2),we=T(Re,!0);S(Re),S(Le),D(()=>he(we,n(s).vsid)),$(q,Le)};V(re,q=>{n(s).vsid&&q(X)})}var Te=A(re,2);{var ue=q=>{var Le=Wy(),Re=A(T(Le),2),we=T(Re,!0);S(Re),S(Le),D(()=>he(we,n(s).provider)),$(q,Le)};V(Te,q=>{n(s).provider&&q(ue)})}var te=A(Te,2);{var be=q=>{var Le=Ky(),Re=A(T(Le),2),we=T(Re);S(Re),S(Le),D(()=>{var Ke,Se;return he(we,`Video: ${(Ke=n(s).videoCodec||"")!=null?Ke:""} ${n(s).hdr?"(HDR)":""}
57
57
  &
58
- Audio: ${(dt=n(s).audioCodec||"")!=null?dt:""} ${n(s).audioLanguage?`(${n(s).audioLanguage})`:""}`)}),$(j,Pe)};V(ee,j=>{(n(s).videoCodec||n(s).audioCodec)&&j(_e)})}var Ce=k(ee,2);{var ge=j=>{var Pe=Fy(),le=k(C(Pe),2),$e=C(le,!0);S(le),S(Pe),D(()=>ve($e,n(s).viewport)),$(j,Pe)};V(Ce,j=>{n(s).viewport&&j(ge)})}var pe=k(Ce,2);{var Qe=j=>{var Pe=Uy(),le=k(C(Pe),2),$e=C(le,!0);S(le),S(Pe),D(()=>ve($e,n(s).videoSize)),$(j,Pe)};V(pe,j=>{n(s).videoSize&&j(Qe)})}var G=k(pe,2);{var O=j=>{var Pe=zy(),le=k(C(Pe),2),$e=C(le,!0);S(le),S(Pe),D(()=>ve($e,n(s).cdn)),$(j,Pe)};V(G,j=>{n(s).cdn&&j(O)})}var Ge=k(G,2);{var K=j=>{var Pe=Wy(),le=k(C(Pe),2),$e=C(le);S(le),S(Pe),D(()=>{var Me;return ve($e,`${(Me=n(s).volume)!=null?Me:""} %`)}),$(j,Pe)};V(Ge,j=>{n(s).volume&&j(K)})}var se=k(Ge,2);{var xe=j=>{var Pe=Ky(),le=k(C(Pe),2),$e=C(le);S(le),S(Pe),D(Me=>ve($e,`${Me!=null?Me:""} s`),[()=>n(s).position.toFixed(2)]),$(j,Pe)};V(se,j=>{n(s).position&&j(xe)})}var He=k(se,2);{var ot=j=>{var Pe=qy(),le=k(C(Pe),2),$e=C(le);S(le),S(Pe),D(Me=>ve($e,`${Me!=null?Me:""} s`),[()=>n(s).buffer.toFixed(2)]),$(j,Pe)};V(He,j=>{n(s).buffer&&j(ot)})}var ne=k(He,2);{var ce=j=>{var Pe=Qy(),le=k(C(Pe),2),$e=C(le);S(le),S(Pe),D(Me=>ve($e,`${Me!=null?Me:""} s`),[()=>n(s).nativeBuffer.toFixed(2)]),$(j,Pe)};V(ne,j=>{n(s).nativeBuffer&&j(ce)})}var Ne=k(ne,2);{var Le=j=>{var Pe=Gy(),le=k(C(Pe),2),$e=C(le);S(le),S(Pe),D(Me=>ve($e,`${Me!=null?Me:""} s`),[()=>n(s).liveLatency.toFixed(2)]),$(j,Pe)};V(Ne,j=>{n(s).liveLatency&&j(Le)})}var et=k(Ne,2);{var Ee=j=>{var Pe=Yy(),le=k(C(Pe),2),$e=C(le,!0);S(le),S(Pe),D(Me=>ve($e,Me),[()=>[{value:n(s).currentVideoSegmentLength,title:"Video:"},{value:n(s).currentAudioSegmentLength,title:"Audio:"}].filter(({value:Me})=>Me).map(({value:Me,title:dt})=>`${dt} ${((Me!=null?Me:0)/1e3).toFixed(2)} s`).join(" & ")]),$(j,Pe)};V(et,j=>{(n(s).currentVideoSegmentLength||n(s).currentAudioSegmentLength)&&j(Ee)})}var Te=k(et,2),Fe=k(C(Te),2),It=C(Fe);S(Fe),S(Te);var wt=k(Te,2);{var Dt=j=>{var Pe=jy(),le=k(C(Pe),2);Wd(le,{get values(){return n(I)}});var $e=k(le,2),Me=C($e);S($e),S(Pe),D(dt=>ve(Me,`${dt!=null?dt:""} Kbps`),[()=>n(s).speed.toFixed(2)]),$(j,Pe)};V(wt,j=>{n(s).speed&&j(Dt)})}var at=k(wt,2);{var Et=j=>{var Pe=Xy(),le=k(C(Pe),2);Wd(le,{get values(){return n(T)}});var $e=k(le,2),Me=C($e);S($e),S(Pe),D(dt=>ve(Me,`${dt!=null?dt:""} Kbps`),[()=>n(s).bitrate.toFixed(2)]),$(j,Pe)};V(at,j=>{n(s).bitrate&&j(Et)})}var Zt=k(at,2),Pt=k(C(Zt),2);Wd(Pt,{get values(){return n(x)}});var Ot=k(Pt,2),zt=C(Ot,!0);S(Ot),S(Zt),S(z),S(A),D(j=>{var Pe,le;P=oe(A,1,"container s-o",null,P,j),Re(A,"aria-label",R),ve(X,n(s).version),ve(It,`${(Pe=n(p))!=null?Pe:""} / ${(le=n(m))!=null?le:""} frames`),ve(zt,n(v))},[()=>({"container-mobile":r()})]),$(t,A),H(),o()}Ye(["click"]);import{noop as e0}from"@vkontakte/videoplayer-shared/es2015";var t0=(t,e)=>{t.stopPropagation(),e()()},i0=L('<div class="close s-19"></div>'),o0={hash:"s-19",code:'.close.s-19{cursor:pointer;height:16px;opacity:.8;position:relative;transition:opacity .2s;width:16px}.close.s-19:hover{opacity:1}.close.s-19:after,.close.s-19:before{background-color:var(--white);content:" ";height:16px;left:8px;position:absolute;width:2px}.close.s-19:before{transform:rotate(45deg)}.close.s-19:after{transform:rotate(-45deg)}'};function Fs(t,e){B(e,!0),Q(t,o0);let i=h(e,"onClick",3,e0);var o=i0();o.__click=[t0,i],$(t,o),H()}Ye(["click"]);import{noop as r0}from"@vkontakte/videoplayer-shared/es2015";var un=t=>`width:${t}px;height:${t}px;`;var n0=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 Vn(t,e){B(e,!0);let i=f(()=>un(e.size));Je(t,{get width(){return"48"},get height(){return"48"},get fill(){return e.fill},get style(){return n(i)},testId:"play-icon",get shadow(){return e.shadow},children:(o,r)=>{var a=n0();$(o,a)},$$slots:{default:!0}}),H()}var s0=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 qd(t,e){B(e,!0),Q(t,a0);let i=h(e,"isRunning",3,!0),o=h(e,"onTimerEnded",3,r0),r=5e3,a=q(void 0),l,d,s=0,u;De(()=>{i()&&Tt(()=>{d=Date.now(),s=requestAnimationFrame(p)})});let m=()=>{s&&(cancelAnimationFrame(s),s=0)},p=()=>{m(),i()&&(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()())};Mt(()=>{l=n(a).getContext("2d"),l&&(l.lineWidth=6,l.lineCap="round",l.strokeStyle="#fff")}),cn(()=>{m()});var v=s0(),b=C(v);Ze(b,_=>N(a,_),()=>n(a));var y=k(b,2);Vn(y,{get size(){return"24"}}),S(v),$(t,v),H()}var l0=(t,e,i)=>{e(!1),i()},d0=L('<div class="overlay s-m"></div> <div class="next-video s-m"><div class="top s-m"><div class="caption s-m"> </div> <!></div> <div class="row s-m"><div class="column s-m"><div class="thumb s-m"><div></div> <!></div></div> <div class="column s-m"><div class="title s-m"> </div></div></div></div>',1),c0={hash:"s-m",code:".overlay.s-m{background:rgba(0,0,0,.72);height:100%;position:absolute;width:100%}.next-video.s-m{display:flex;flex-direction:column;left:50%;position:absolute;top:50%;transform:translate(-50%,-50%);width:362px}.top.s-m{display:flex;justify-content:space-between}.caption.s-m{color:var(--white);font-size:11px;font-weight:700;opacity:.8;text-transform:uppercase}.row.s-m{background:rgba(48,48,48,.8);cursor:pointer;display:flex;flex-direction:row;height:102px;margin-top:6px;width:100%}.column.s-m{display:flex;flex-basis:50%;flex-direction:column}.thumb.s-m{align-items:center;background:no-repeat 50%;background-size:cover;display:flex;justify-content:space-around;position:relative}.thumb.s-m,.thumb-overlay.s-m{height:100%;width:100%}.thumb-overlay.s-m{position:absolute}.thumb-overlay.withOpacity.s-m{background:var(--black);opacity:.3}.title.s-m{color:var(--white);font-size:12px;font-weight:700;line-height:1.6;max-height:52px;overflow:hidden;padding:10px 16px}"};function Jf(t,e){B(e,!0),Q(t,c0);let[i,o]=Oe(),r=()=>w(d,"$autoplayNextEnabled$",i),a=()=>w(s,"$timerNextVideoRunning$",i),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()};Mt(()=>{e.isHide||m(),e.isHide&&r()&&(u(!1),v())});var x=Ve(),I=ue(x);{var T=R=>{var A=d0(),P=k(ue(A),2),E=C(P),z=C(E),F=C(z,!0);S(z);var U=k(z,2);Fs(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());qd(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),D((ge,pe)=>{ve(F,ge),qe(Z,`background-image: url('${e.thumb}')`),J=oe(re,1,"thumb-overlay s-m",null,J,pe),ve(Ce,e.title)},[()=>Y("end_screen_next_video"),()=>({withOpacity:r()})]),$(R,A)};V(I,R=>{e.isHide||R(T)})}$(t,x),H(),o()}Ye(["click"]);import{PlaybackState as Ka}from"@vkontakte/videoplayer-core/es2015";import{checkNever as p0}from"@vkontakte/videoplayer-shared/es2015";import{SeekAction as Xn}from"@vkontakte/videoplayer-statistics/es2015";var em=(t,e)=>Math.min(+(t+e).toFixed(2),1),tm=(t,e)=>Math.max(+(t-e).toFixed(2),0),Fu=(t,e,i)=>{let o=em(e,i);e<1&&t.actions.internal.setVolume(o)},Uu=(t,e,i)=>{let o=tm(e,i);e>0&&t.actions.internal.setVolume(o)};var fa=({isAudioDisabled:t,isAudioAvailable:e,isAds:i,audioDisabledHintCallback:o,audioIsNotExistHintCallback:r})=>t?i?!0:(o==null||o(),!1):e?!0:(r==null||r(),!1);function zu(){var t,e,i;return(i=(e=(t=document.activeElement)==null?void 0:t.shadowRoot)==null?void 0:e.activeElement)!=null?i:null}var f0=(t,e)=>{e(t)},m0=L('<div class="keyboard-controls s-n" tabindex="-1" role="region"><!></div>'),v0={hash:"s-n",code:".keyboard-controls.s-n{bottom:0;left:0;position:absolute;right:0;top:0}"};function im(t,e){var j,Pe;B(e,!0),Q(t,v0);let[i,o]=Oe(),r=()=>w(we,"$disabledControls$",i),a=()=>w(ot,"$isInteractiveTime$",i),l=()=>w(ne,"$showInteractiveTimeIndicatorTooltip$",i),d=()=>w(U,"$playbackState$",i),s=()=>w(O,"$isEnded$",i),u=()=>w(Qe,"$doubleForwardAvailable$",i),m=()=>w(pe,"$doubleForwardOn$",i),p=()=>w(Ge,"$overlayContainer$",i),v=()=>w(ae,"$adPlaybackState",i),b=()=>w(Z,"$positionExact$",i),y=()=>w(re,"$duration$",i),_=()=>w(xe,"$isAudioAvailable$",i),x=()=>w(J,"$volume$",i),I=()=>w(X,"$canChangePlaybackSpeed$",i),T=()=>w(me,"$muted$",i),R=()=>w(ee,"$currentSubtitle$",i),A=h(e,"nextButtonActive",3,!1),P=h(e,"prevButtonActive",3,!1),E=be(),z=Vt(),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$,O=E.state.isEnded$,Ge=E.ui.overlayContainer$,K=(j=E.callbacks)==null?void 0:j.onAudioDoesNotExistHint,se=(Pe=E.callbacks)==null?void 0:Pe.onAudioDisabledHint,xe=E.state.isAudioAvailable$,He=E.state.isAudioDisabled,ot=E.state.isInteractiveTime$,{showInteractiveTimeIndicatorTooltip$:ne}=_o(),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:Me})=>{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()===Ka.PAUSED?fe="PAUSE":s()&&(fe="REPLAY"),e.showHotKeyHelpers({type:fe})}},St=le==="down";if(!u()||Me){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=Q_(p());G.set($e),Ce.set(le.target),_e.set(!0),ge.set(!0)},It=(le,$e=!1)=>{var vo,fi;let Me=le.target,dt=(vo=Me==null?void 0:Me.getAttribute("role"))==null?void 0:vo.includes("menuitem"),St=Me.classList.contains("btn"),fe=le.code;if(St&&fe==="Space")return!1;let Ue=zh.has(fe);if(dt&&Ue)return!1;let ze=!Uh.has(fe);if(le.ctrlKey&&ze||le.altKey&&ze||le.metaKey)return!1;let Ct=dt&&fe==="Escape";Wh.has(fe)||Ct||e.hideContextMenu();let si=d()===Ka.PLAYING||d()===Ka.PAUSED,xt=e.isAds&&(v()==="paused"||v()==="playing"),Yt=!xt&&!r().has("TIMELINE"),ci=le.shiftKey&&["Digit1","Numpad1"].includes(fe);if(!ci&&!(si||xt))return!1;F({message:`key down, code: ${fe}, isExternal = ${$e}`});let Hi=!1,Rt=()=>{Hi=!0,$e||le.preventDefault()};if(ci)return Fe(le),Rt(),!0;switch(fe){case"KeyJ":case"ArrowLeft":{if(!Yt)break;if(le.ctrlKey||le.altKey){let nt=E.actions.internal.getPrevEpisode();E.actions.internal.seekToPrevEpisode(nt),nt&&e.showHotKeyHelpers({type:"EPISODE_PREV",text:nt.text}),Rt()}else{let nt=le.shiftKey?et(!1):z.controls.seekStepKeyboard/1e3,jt=Math.max(b()-nt,0);b()>0&&(E.actions.internal.seekTime(jt,Xn.DOUBLE_TAP),e.showHotKeyHelpers({type:"BACKWARD_SEEK",text:nt.toString()}),Rt())}break}case"KeyL":case"ArrowRight":{if(!Yt)break;if(le.ctrlKey||le.altKey){let nt=E.actions.internal.getNextEpisode();E.actions.internal.seekToNextEpisode(nt),nt&&e.showHotKeyHelpers({type:"EPISODE_NEXT",text:nt.text}),Rt()}else{let nt=le.shiftKey?et(!0):z.controls.seekStepKeyboard/1e3,jt=Math.min(b()+nt,y());Math.round(b())<Math.round(y())&&(E.actions.internal.seekTime(jt,Xn.DOUBLE_TAP),e.showHotKeyHelpers({type:"FORWARD_SEEK",text:nt.toString()}),Rt())}break}case"ArrowUp":{if(fa({isAudioDisabled:He,audioDisabledHintCallback:se,isAudioAvailable:_(),audioIsNotExistHintCallback:K,isAds:e.isAds})){let nt=x(),jt=z.controls.volumeStepKeyboard,Fi=nt<=1;if(Fu(E,nt,jt),Fi){let $i=Math.round(em(nt,jt)*100).toString();e.showHotKeyHelpers({type:"VOLUME",t:{key:"hotkey_helper_current_volume",value:$i}})}}Rt();break}case"ArrowDown":{if(fa({isAudioDisabled:He,audioDisabledHintCallback:se,isAudioAvailable:_(),audioIsNotExistHintCallback:K,isAds:e.isAds})){let nt=x(),jt=z.controls.volumeStepKeyboard,Fi=nt>=0;if(Uu(E,nt,jt),Fi){let $i=Math.round(tm(nt,jt)*100).toString();e.showHotKeyHelpers({type:"VOLUME",t:{key:"hotkey_helper_current_volume",value:$i}})}}Rt();break}case"Comma":{if(le.shiftKey){if(!m()&&I()){let nt=E.actions.internal.decrementPlaybackRate();e.showHotKeyHelpers({type:"RATE_DOWN",text:nt==null?void 0:nt.displayValue}),Rt()}}else{if(xt||d()!==Ka.PAUSED)break;let nt=Math.max(b()-z.controls.seekStepFrame/1e3,0);b()>0&&(e.showHotKeyHelpers({type:"BACKWARD_SEEK"}),E.actions.internal.clearDelayedBufferingCheckTimeout(),E.actions.internal.seekTime(nt,Xn.DOUBLE_TAP),Rt())}break}case"Period":{if(le.shiftKey){if(!m()&&I()){let nt=E.actions.internal.incrementPlaybackRate();e.showHotKeyHelpers({type:"RATE_UP",text:nt==null?void 0:nt.displayValue}),Rt()}}else{if(xt||d()!==Ka.PAUSED)break;let nt=Math.min(b()+z.controls.seekStepFrame/1e3,y());b()<y()&&(e.showHotKeyHelpers({type:"FORWARD_SEEK"}),E.actions.internal.clearDelayedBufferingCheckTimeout(),E.actions.internal.seekTime(nt,Xn.DOUBLE_TAP),Rt())}break}case"KeyK":case"Space":Te({type:"down",repeat:le.repeat,disableDoubleForward:"KeyK"===fe}),Rt();break;case"KeyM":{fa({isAudioDisabled:He,audioDisabledHintCallback:se,isAudioAvailable:_(),audioIsNotExistHintCallback:K,isAds:e.isAds})&&(e.showHotKeyHelpers({type:T()?"VOLUME":"MUTE"}),E.actions.internal.toggleMuted()),Rt();break}case"KeyF":e.toggleFullscreen(),Rt();break;case"KeyC":E.actions.internal.toggleSubtitle(),R().value!=="off"?e.showHotKeyHelpers({type:"SUBTITLES_ON",text:(fi=R())==null?void 0:fi.displayValue}):e.showHotKeyHelpers({type:"SUBTITLES_OFF"}),Rt();break;case"KeyI":E.actions.internal.togglePictureInPicture(),Rt();break;case"Digit1":case"Numpad1":e.showHotKeyHelpers(),E.actions.internal.seekToPercent(.1,Xn.DOUBLE_TAP),Rt();break;case"Digit2":case"Numpad2":e.showHotKeyHelpers(),E.actions.internal.seekToPercent(.2,Xn.DOUBLE_TAP),Rt();break;case"Digit3":case"Numpad3":e.showHotKeyHelpers(),E.actions.internal.seekToPercent(.3,Xn.DOUBLE_TAP),Rt();break;case"Digit4":case"Numpad4":e.showHotKeyHelpers(),E.actions.internal.seekToPercent(.4,Xn.DOUBLE_TAP),Rt();break;case"Digit5":case"Numpad5":e.showHotKeyHelpers(),E.actions.internal.seekToPercent(.5,Xn.DOUBLE_TAP),Rt();break;case"Digit6":case"Numpad6":e.showHotKeyHelpers(),E.actions.internal.seekToPercent(.6,Xn.DOUBLE_TAP),Rt();break;case"Digit7":case"Numpad7":e.showHotKeyHelpers(),E.actions.internal.seekToPercent(.7,Xn.DOUBLE_TAP),Rt();break;case"Digit8":case"Numpad8":e.showHotKeyHelpers(),E.actions.internal.seekToPercent(.8,Xn.DOUBLE_TAP),Rt();break;case"Digit9":case"Numpad9":e.showHotKeyHelpers(),E.actions.internal.seekToPercent(.9,Xn.DOUBLE_TAP),Rt();break;case"Digit0":case"Numpad0":e.showHotKeyHelpers(),E.actions.internal.seekToPercent(0,Xn.DOUBLE_TAP),Rt();break;case"Slash":{le.shiftKey&&z.features.hotKeyMapModal&&(e.showKeyMap(),Rt());break}case"KeyN":le.shiftKey&&A()&&(E.actions.internal.nextVideoClick(),Rt());break;case"KeyP":le.shiftKey&&P()&&(E.actions.internal.prevVideoClick(),Rt());break;case"ShiftLeft":case"ShiftRight":Rt();break;case"Tab":case"Escape":case"Enter":break;default:p0(fe);break}return Hi},wt=le=>{let $e=le.code;if(le.ctrlKey||le.altKey||le.metaKey)return;let Me=d()===Ka.PLAYING||d()===Ka.PAUSED,dt=e.isAds&&(v()==="paused"||v()==="playing");if(Me||dt)switch($e){case"ShiftLeft":case"ShiftRight":ce=0;break;case"Space":Te({type:"up"});break}},Dt=Y("aria_label_video_player"),at=()=>{var le;return(le=n(Le))==null?void 0:le.focus()},Et=()=>n(Le)===zu(),Zt=le=>le.type==="keydown"?It(le,!0):(le.type==="keyup"&&wt(le),!1);var Pt=m0();Pt.__keyup=wt,Pt.__keydown=[f0,It];var Ot=C(Pt);ii(Ot,()=>{var le;return(le=e.children)!=null?le:ht}),S(Pt),Ze(Pt,le=>N(Le,le),()=>n(Le)),D(()=>Re(Pt,"aria-label",Dt)),$(t,Pt);var zt=H({focus:at,isFocused:Et,handleExternalKeyboardEvent:Zt});return o(),zt}Ye(["keyup","keydown"]);var g0=L('<div class="container s-u"><div class="dot s-u"></div> <div class="dot s-u"></div> <div class="dot s-u"></div></div>'),h0={hash:"s-u",code:".container.s-u{display:flex;left:50%;pointer-events:none;position:absolute;top:50%;transform:translate(-50%,-50%)}.dot.s-u:first-child{animation-delay:0s}.dot.s-u:nth-child(2){animation-delay:.18s}.dot.s-u:nth-child(3){animation-delay:.36s}@keyframes s-u-dot_animation{0%{opacity:.2}30%{opacity:1}to{opacity:.2}}.dot.s-u{animation-duration:.75s;animation-iteration-count:infinite;animation-name:s-u-dot_animation;background:var(--btn-color);border-radius:4px;height:8px;width:8px}.dot.s-u+.dot:where(.s-u){margin-left:4px}"};function qa(t,e){Q(t,h0);let i=h(e,"style",3,"");var o=g0();D(()=>qe(o,i())),$(t,o)}var _0=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 om(t,e){Je(t,{get fill(){return e.fill},children:(i,o)=>{var r=_0();$(i,r)},$$slots:{default:!0}})}import{noop as Fl}from"@vkontakte/videoplayer-shared/es2015";var b0=t=>{t.stopPropagation()},$0=L("<button><!></button>"),y0={hash:"s-1l",code:"button.btn.s-1l{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-1l{width:100%}button.btn--live.s-1l{padding:10px 4px}button.btn-jc-l.s-1l{justify-content:left}button.btn-m.s-1l{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-1l,button.btn-m--play.s-1l{align-items:center;display:flex;justify-content:center}button.btn-m--play.s-1l{height:var(--big-play-size);padding:16px;position:relative;width:var(--big-play-size)}button.btn-m--next.s-1l,button.btn-m--prev.s-1l{height:50px;position:absolute;width:50px}button.btn-m--prev.s-1l{right:calc(100% + 35px)}button.btn-m--next.s-1l{left:calc(100% + 35px)}button.btn.s-1l:disabled{cursor:default;pointer-events:none}button.btn.s-1l:not(.btn-full-opacity):disabled{opacity:.4}button.btn.s-1l:not(:disabled):hover{opacity:.8}button.pr-0.s-1l{padding-right:0}button.pl-0.s-1l{padding-left:0}"};function Ut(t,e){B(e,!0),Q(t,y0);let i=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,Fl),b=h(e,"focus",3,Fl),y=h(e,"blur",3,Fl),_=f(()=>v()===Fl?null:A=>{A.stopPropagation(),v()(A)}),x=f(()=>b()===Fl?null:A=>{A.preventDefault(),b()()}),I=f(()=>y()===Fl?null:A=>{A.preventDefault(),y()()});var T=$0();T.__pointerdown=[b0],T.__click=function(...A){var P;(P=n(_))==null||P.apply(this,A)};var R=C(T);ii(R,()=>{var A;return(A=e.children)!=null?A:ht}),S(T),Ze(T,A=>s(A),()=>s()),D(()=>{var A,P,E,z,F,U,X,ae;oe(T,1,`btn ${(A=i())!=null?A:""}`,"s-1l"),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)}),$(t,T),H()}Ye(["pointerdown","click"]);var x0=(t,e)=>{t.key==="Escape"&&e.onClose(),(t.key==="ArrowUp"||t.key==="ArrowDown")&&t.stopPropagation()},w0=L('<div class="modal-header s-1a"><h3 class="modal-title s-1a"> </h3> <!></div>'),S0=L('<div class="modal-overlay s-1a"><div class="modal-container s-1a" role="dialog" aria-modal="true"><!> <div class="modal-scroll s-1a" tabindex="0" role="scrollbar"><div class="modal-main s-1a"><!></div></div></div></div>'),C0={hash:"s-1a",code:'.modal-overlay.s-1a{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-1a{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-1a{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-1a{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-1a{height:100%;margin:8px 4px 8px 0;overflow-x:hidden;overflow-y:auto}.modal-scroll.s-1a::-webkit-scrollbar{width:8px}.modal-scroll.s-1a::-webkit-scrollbar-track{background-color:transparent;border-radius:4px;box-shadow:none;margin-right:2px}.modal-scroll.s-1a::-webkit-scrollbar-thumb{background-clip:padding-box;background-color:#666;border:1px solid transparent;border-radius:5px;min-height:40px}.modal-scroll.s-1a::-webkit-scrollbar-thumb:hover{background-color:#777}.modal-main.s-1a{margin:-8px -4px 0 0}'};function nm(t,e){B(e,!0),Q(t,C0);let i=h(e,"showHeader",3,!0),o=h(e,"showCloseCross",3,!0),r=q(void 0),a=q(void 0),{webApi:{focusManager:l}}=be(),d=Y("hotkey_map_modal_close_btn_text");Mt(()=>{var _;return(_=n(r))==null||_.focus(),n(a)&&l&&(l.setContainerForFocusLock(n(a)),l.activateLock()),()=>l==null?void 0:l.deactivateLock()});var s=S0();s.__keydown=[x0,e];var u=C(s),m=C(u);{var p=_=>{var x=w0(),I=C(x),T=C(I,!0);S(I);var R=k(I,2);{var A=P=>{Ut(P,{get click(){return e.onClose},testId:"close-modal",style:"padding: 0; height: 24px; width: 24px",get ariaLabel(){return d},children:(E,z)=>{om(E,{fill:"currentColor"})},$$slots:{default:!0}})};V(R,P=>{o()&&P(A)})}S(x),D(()=>ve(T,e.title)),$(_,x)};V(m,_=>{i()&&_(p)})}var v=k(m,2),b=C(v),y=C(b);ii(y,()=>{var _;return(_=e.children)!=null?_:ht}),S(b),S(v),Ze(v,_=>N(r,_),()=>n(r)),S(u),Ze(u,_=>N(a,_),()=>n(a)),S(s),$(t,s),H()}Ye(["keydown"]);var T0=new Set(["BR"]),j_=t=>{var r;let e=document.createElement("DIV");e.innerHTML=t;let i=e.querySelectorAll("*"),o=i.length;for(;o--;){let a=i[o],l=a.tagName;T0.has(l)||(r=a.parentElement)==null||r.removeChild(a)}return e.innerHTML};var I0=L('<li class="hot-key-map-item s-p"><span class="hot-key-map-item-description s-p"><!></span> &nbsp; <span class="hot-key-map-item-value s-p"> </span></li>'),E0=L('<div class="hot-key-map-group s-p"><h5 class="hot-key-map-group-title s-p"> </h5> <ul class="hot-key-map-group-items s-p"></ul></div>'),P0=L('<div class="hot-key-map s-p"></div>'),k0={hash:"s-p",code:'.hot-key-map.s-p{box-sizing:border-box;color:var(--black);overflow-x:hidden}.hot-key-map-group.s-p{border-bottom:1px solid var(--white-alpha-24);margin:0 20px 0 16px}.hot-key-map-group.s-p:last-child{border-bottom:none}.hot-key-map-group-title.s-p{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-p,.hot-key-map-item.s-p{margin:0;padding:12px 0;width:100%}.hot-key-map-group-items.s-p{box-sizing:border-box;list-style:none;margin:0;padding:0}.hot-key-map-item.s-p{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-p{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-p{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-p,.hot-key-map-item-value.s-p{font-feature-settings:"clig" off,"liga" off;font-size:13px;font-style:normal;font-weight:400;line-height:16px}'};function rm(t,e){B(e,!1),Q(t,k0);let[i,o]=Oe(),r=()=>w(l,"$data",i),a=be(),{data:l,show:d}=a.ui.modals.hotKeyMap,s=()=>{d.set(!1)};ho(),nm(t,{get title(){return r().title},onClose:s,children:(u,m)=>{var p=P0();bi(p,5,()=>r().groups,({title:v,items:b})=>v,(v,b)=>{let y=()=>n(b).title,_=()=>n(b).items;var x=E0(),I=C(x),T=C(I,!0);S(I);var R=k(I,2);bi(R,5,_,({description:A,value:P})=>P,(A,P)=>{let E=()=>n(P).description,z=()=>n(P).value;var F=I0(),U=C(F),X=C(U);Sd(X,()=>j_(E())),S(U);var ae=k(U,2),Z=C(ae,!0);S(ae),S(F),D(()=>ve(Z,z())),$(A,F)}),S(R),S(x),D(()=>ve(T,y())),$(v,x)}),S(p),$(u,p)},$$slots:{default:!0}}),H(),o()}import{noop as Sb}from"@vkontakte/videoplayer-shared/es2015";import{ChromecastState as _b,PlaybackState as Qm}from"@vkontakte/videoplayer-core/es2015";import{getVideoQualityLabel as H0}from"@vkontakte/videoplayer-shared/es2015";var A0=L('<div class="pillow s-27"><!></div>'),L0={hash:"s-27",code:".pillow.s-27{background-color:#679ff8;color:var(--white);font-size:6px;font-weight:600;-webkit-font-smoothing:antialiased;border-radius:12px;padding:2px 4px}"};function sm(t,e){Q(t,L0);var i=A0(),o=C(i);ii(o,()=>{var r;return(r=e.children)!=null?r:ht}),S(i),D(()=>Re(i,"data-testid",e.testId)),$(t,i)}import{VideoQuality as Qd}from"@vkontakte/videoplayer-shared/es2015";var M0=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(t,e){let i=Mn(e,["$$slots","$$events","$$legacy","children"]);var o=M0();io(o,()=>ke({xmlns:"http://www.w3.org/2000/svg",width:"9",height:"5",fill:"currentColor","fill-rule":"evenodd",role:"img"},i));var r=C(o);ii(r,()=>{var a;return(a=e.children)!=null?a:ht}),di(),S(o),$(t,o)}var V0=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(t,e){let i=Mn(e,["$$slots","$$events","$$legacy","children"]);var o=V0();io(o,()=>ke({xmlns:"http://www.w3.org/2000/svg",width:"9",height:"5",fill:"currentColor","fill-rule":"evenodd",role:"img"},i));var r=C(o);ii(r,()=>{var a;return(a=e.children)!=null?a:ht}),di(),S(o),$(t,o)}var R0=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 dm(t,e){let i=Mn(e,["$$slots","$$events","$$legacy","children"]);var o=R0();io(o,()=>ke({xmlns:"http://www.w3.org/2000/svg",width:"9",height:"5",fill:"currentColor",role:"img"},i));var r=C(o);ii(r,()=>{var a;return(a=e.children)!=null?a:ht}),di(),S(o),$(t,o)}var N0=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 cm(t,e){let i=Mn(e,["$$slots","$$events","$$legacy","children"]);var o=N0();io(o,()=>ke({xmlns:"http://www.w3.org/2000/svg",width:"13",height:"5",fill:"currentColor",role:"img"},i));var r=C(o);ii(r,()=>{var a;return(a=e.children)!=null?a:ht}),di(),S(o),$(t,o)}var O0=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 um(t,e){let i=Mn(e,["$$slots","$$events","$$legacy","children"]);var o=O0();io(o,()=>ke({xmlns:"http://www.w3.org/2000/svg",width:"15",height:"7",fill:"currentColor",role:"img"},i));var r=C(o);ii(r,()=>{var a;return(a=e.children)!=null?a:ht}),di(),S(o),$(t,o)}var Wu=t=>{switch(t){case Qd.Q_720P:return dm;case Qd.Q_1080P:return cm;case Qd.Q_1440P:return um;case Qd.Q_2160P:return am;case Qd.Q_4320P:return lm}};var D0=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 pm(t,e){Je(t,{get testId(){return e.testId},children:(i,o)=>{var r=D0();$(i,r)},$$slots:{default:!0}})}var B0=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 fm(t,e){Je(t,{get testId(){return e.testId},children:(i,o)=>{var r=B0();$(i,r)},$$slots:{default:!0}})}var F0=L('<div aria-hidden="true"><!> <!></div>'),U0={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 Gd(t,e){B(e,!0),Q(t,U0);let i=h(e,"isMobile",3,!1),o=h(e,"currentQuality",3,void 0),r=f(()=>o()?H0(o()):""),a=f(()=>Wu(o())),l=f(()=>n(r).length>2);var d=Ve(),s=ue(d);{var u=p=>{pm(p,{testId:"settings-mobile-icon"})},m=p=>{var v=F0();let b;var y=C(v);{var _=T=>{let R=f(()=>`${n(r)}-pill-icon`);sm(T,{get testId(){return n(R)},children:(A,P)=>{var E=Ve(),z=ue(E);Bi(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");fm(x,{get testId(){return n(I)}}),S(v),D(T=>b=oe(v,1,"icon s-1v",null,b,T),[()=>({triple:n(l)})]),$(p,v)};V(s,p=>{i()?p(u):p(m,!1)})}$(t,d),H()}var z0=L('<span class="settings-icon-wrapper s-1y"><!></span>'),W0={hash:"s-1y",code:".settings-icon-wrapper.s-1y{position:relative;width:24px}"};function Ul(t,e){B(e,!0),Q(t,W0);let[i,o]=Oe(),r=()=>w(u,"$settingsMenuVisible",i),a=()=>w(v,"$isMobile",i),l=()=>w(s,"$currentQuality",i),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);De(()=>{n(y)&&Tt(()=>{e.ref$.set(n(y))})});let _=b("aria_label_settings");function x(T){return gt(this,null,function*(){let R=pa(T);r()?p():m(R,mo)})}let I=f(()=>r()?"opened":"");Ut(t,{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=z0(),P=C(A);Gd(P,{get isMobile(){return a()},get currentQuality(){return l()}}),S(A),$(T,A)},$$slots:{default:!0}}),H(),o()}var K0=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),q0=Ie("<path></path>");function ma(t,e){B(e,!0);let i=f(()=>`subtitles-icon${e.type==="off"?"-off":e.type==="outline"?"-outline":""}`),o=f(()=>un(e.size));Je(t,{get width(){return"48"},get height(){return"48"},get style(){return n(o)},get testId(){return n(i)},get shadow(){return e.shadow},children:(r,a)=>{var l=Ve(),d=ue(l);{var s=m=>{var p=K0();di(),$(m,p)},u=m=>{var p=q0();D(()=>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(be)})}var Ce=A(te,2);{var me=q=>{var Le=qy(),Re=A(T(Le),2),we=T(Re,!0);S(Re),S(Le),D(()=>he(we,n(s).viewport)),$(q,Le)};V(Ce,q=>{n(s).viewport&&q(me)})}var qe=A(Ce,2);{var ve=q=>{var Le=Qy(),Re=A(T(Le),2),we=T(Re,!0);S(Re),S(Le),D(()=>he(we,n(s).videoSize)),$(q,Le)};V(qe,q=>{n(s).videoSize&&q(ve)})}var pe=A(qe,2);{var Z=q=>{var Le=Gy(),Re=A(T(Le),2),we=T(Re,!0);S(Re),S(Le),D(()=>he(we,n(s).cdn)),$(q,Le)};V(pe,q=>{n(s).cdn&&q(Z)})}var N=A(pe,2);{var ce=q=>{var Le=Yy(),Re=A(T(Le),2),we=T(Re);S(Re),S(Le),D(()=>{var Ke;return he(we,`${(Ke=n(s).volume)!=null?Ke:""} %`)}),$(q,Le)};V(N,q=>{n(s).volume&&q(ce)})}var de=A(N,2);{var _e=q=>{var Le=jy(),Re=A(T(Le),2),we=T(Re);S(Re),S(Le),D(Ke=>he(we,`${Ke!=null?Ke:""} s`),[()=>n(s).position.toFixed(2)]),$(q,Le)};V(de,q=>{n(s).position&&q(_e)})}var ge=A(de,2);{var ze=q=>{var Le=Xy(),Re=A(T(Le),2),we=T(Re);S(Re),S(Le),D(Ke=>he(we,`${Ke!=null?Ke:""} s`),[()=>n(s).buffer.toFixed(2)]),$(q,Le)};V(ge,q=>{n(s).buffer&&q(ze)})}var ie=A(ge,2);{var We=q=>{var Le=Zy(),Re=A(T(Le),2),we=T(Re);S(Re),S(Le),D(Ke=>he(we,`${Ke!=null?Ke:""} s`),[()=>n(s).nativeBuffer.toFixed(2)]),$(q,Le)};V(ie,q=>{n(s).nativeBuffer&&q(We)})}var ee=A(ie,2);{var ke=q=>{var Le=Jy(),Re=A(T(Le),2),we=T(Re);S(Re),S(Le),D(Ke=>he(we,`${Ke!=null?Ke:""} s`),[()=>n(s).liveLatency.toFixed(2)]),$(q,Le)};V(ee,q=>{n(s).liveLatency&&q(ke)})}var Ue=A(ee,2);{var Ie=q=>{var Le=e0(),Re=A(T(Le),2),we=T(Re,!0);S(Re),S(Le),D(Ke=>he(we,Ke),[()=>[{value:n(s).currentVideoSegmentLength,title:"Video:"},{value:n(s).currentAudioSegmentLength,title:"Audio:"}].filter(({value:Ke})=>Ke).map(({value:Ke,title:Se})=>`${Se} ${((Ke!=null?Ke:0)/1e3).toFixed(2)} s`).join(" & ")]),$(q,Le)};V(Ue,q=>{(n(s).currentVideoSegmentLength||n(s).currentAudioSegmentLength)&&q(Ie)})}var Ae=A(Ue,2),Ne=A(T(Ae),2),gt=T(Ne);S(Ne),S(Ae);var It=A(Ae,2);{var Lt=q=>{var Le=t0(),Re=A(T(Le),2);Fd(Re,{get values(){return n(I)}});var we=A(Re,2),Ke=T(we);S(we),S(Le),D(Se=>he(Ke,`${Se!=null?Se:""} Kbps`),[()=>n(s).speed.toFixed(2)]),$(q,Le)};V(It,q=>{n(s).speed&&q(Lt)})}var lt=A(It,2);{var Et=q=>{var Le=i0(),Re=A(T(Le),2);Fd(Re,{get values(){return n(C)}});var we=A(Re,2),Ke=T(we);S(we),S(Le),D(Se=>he(Ke,`${Se!=null?Se:""} Kbps`),[()=>n(s).bitrate.toFixed(2)]),$(q,Le)};V(lt,q=>{n(s).bitrate&&q(Et)})}var jt=A(lt,2),zt=A(T(jt),2);Fd(zt,{get values(){return n(x)}});var Ot=A(zt,2),Wt=T(Ot,!0);S(Ot),S(jt),S(W),S(k),D(q=>{var Le,Re;P=ne(k,1,"container s-h",null,P,q),De(k,"aria-label",R),he(j,n(s).version),he(gt,`${(Le=n(p))!=null?Le:""} / ${(Re=n(m))!=null?Re:""} frames`),he(Wt,n(v))},[()=>({"container-mobile":r()})]),$(i,k),H(),o()}Je(["click"]);import{noop as r0}from"@vkontakte/videoplayer-shared/es2015";var s0=(i,e)=>{i.stopPropagation(),e()()},a0=L('<div class="close s-1b"></div>'),l0={hash:"s-1b",code:'.close.s-1b{cursor:pointer;height:16px;opacity:.8;position:relative;transition:opacity .2s;width:16px}.close.s-1b:hover{opacity:1}.close.s-1b:after,.close.s-1b:before{background-color:var(--white);content:" ";height:16px;left:8px;position:absolute;width:2px}.close.s-1b:before{transform:rotate(45deg)}.close.s-1b:after{transform:rotate(-45deg)}'};function Ds(i,e){B(e,!0),Q(i,l0);let t=h(e,"onClick",3,r0);var o=a0();o.__click=[s0,t],$(i,o),H()}Je(["click"]);import{noop as c0}from"@vkontakte/videoplayer-shared/es2015";var un=i=>`width:${i}px;height:${i}px;`;var d0=Pe('<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 Tn(i,e){B(e,!0);let t=f(()=>un(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=d0();$(o,a)},$$slots:{default:!0}}),H()}var u0=L('<div class="timer s-19"><canvas class="timer-canvas s-19" width="100" height="100"></canvas> <!></div>'),p0={hash:"s-19",code:".timer.s-19{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-19:hover{background:rgba(31,31,31,.85)}.timer-canvas.s-19{height:50px;position:absolute;width:50px}"};function zd(i,e){B(e,!0),Q(i,p0);let t=h(e,"isRunning",3,!0),o=h(e,"onTimerEnded",3,c0),r=5e3,a=K(void 0),l,d,s=0,u;He(()=>{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()())};Vt(()=>{l=n(a).getContext("2d"),l&&(l.lineWidth=6,l.lineCap="round",l.strokeStyle="#fff")}),cn(()=>{m()});var v=u0(),b=T(v);it(b,_=>O(a,_),()=>n(a));var y=A(b,2);Tn(y,{get size(){return"24"}}),S(v),$(i,v),H()}var f0=(i,e,t)=>{e(!1),t()},m0=L('<div class="overlay s-11"></div> <div class="next-video s-11"><div class="top s-11"><div class="caption s-11"> </div> <!></div> <div class="row s-11"><div class="column s-11"><div class="thumb s-11"><div></div> <!></div></div> <div class="column s-11"><div class="title s-11"> </div></div></div></div>',1),v0={hash:"s-11",code:".overlay.s-11{background:rgba(0,0,0,.72);height:100%;position:absolute;width:100%}.next-video.s-11{display:flex;flex-direction:column;left:50%;position:absolute;top:50%;transform:translate(-50%,-50%);width:362px}.top.s-11{display:flex;justify-content:space-between}.caption.s-11{color:var(--white);font-size:11px;font-weight:700;opacity:.8;text-transform:uppercase}.row.s-11{background:rgba(48,48,48,.8);cursor:pointer;display:flex;flex-direction:row;height:102px;margin-top:6px;width:100%}.column.s-11{display:flex;flex-basis:50%;flex-direction:column}.thumb.s-11{align-items:center;background:no-repeat 50%;background-size:cover;display:flex;justify-content:space-around;position:relative}.thumb.s-11,.thumb-overlay.s-11{height:100%;width:100%}.thumb-overlay.s-11{position:absolute}.thumb-overlay.withOpacity.s-11{background:var(--black);opacity:.3}.title.s-11{color:var(--white);font-size:12px;font-weight:700;line-height:1.6;max-height:52px;overflow:hidden;padding:10px 16px}"};function Yf(i,e){B(e,!0),Q(i,v0);let[t,o]=Be(),r=()=>w(d,"$autoplayNextEnabled$",t),a=()=>w(s,"$timerNextVideoRunning$",t),l=xe(),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()};Vt(()=>{e.isHide||m(),e.isHide&&r()&&(u(!1),v())});var x=Oe(),I=le(x);{var C=R=>{var k=m0(),P=A(le(k),2),E=T(P),W=T(E),F=T(W,!0);S(W);var U=A(W,2);Ds(U,{onClick:_}),S(E);var j=A(E,2);j.__click=[f0,u,p];var se=T(j),G=T(se),re=T(G);let X;var Te=A(re,2);{var ue=me=>{let qe=f(()=>a()&&r());zd(me,{get isRunning(){return n(qe)},onTimerEnded:y})};V(Te,me=>{r()&&me(ue)})}S(G),S(se);var te=A(se,2),be=T(te),Ce=T(be,!0);S(be),S(te),S(j),S(P),D((me,qe)=>{he(F,me),je(G,`background-image: url('${e.thumb}')`),X=ne(re,1,"thumb-overlay s-11",null,X,qe),he(Ce,e.title)},[()=>Y("end_screen_next_video"),()=>({withOpacity:r()})]),$(R,k)};V(I,R=>{e.isHide||R(C)})}$(i,x),H(),o()}Je(["click"]);import{PlaybackState as Ua}from"@vkontakte/videoplayer-core/es2015";import{checkNever as h0}from"@vkontakte/videoplayer-shared/es2015";import{SeekAction as Kn}from"@vkontakte/videoplayer-statistics/es2015";var jf=(i,e)=>Math.min(+(i+e).toFixed(2),1),Xf=(i,e)=>Math.max(+(i-e).toFixed(2),0),Nu=(i,e,t)=>{let o=jf(e,t);e<1&&i.actions.internal.setVolume(o)},Bu=(i,e,t)=>{let o=Xf(e,t);e>0&&i.actions.internal.setVolume(o)};var ca=({isAudioDisabled:i,isAudioAvailable:e,isAds:t,audioDisabledHintCallback:o,audioIsNotExistHintCallback:r})=>i?t?!0:(o==null||o(),!1):e?!0:(r==null||r(),!1);function Hu(){var i,e,t;return(t=(e=(i=document.activeElement)==null?void 0:i.shadowRoot)==null?void 0:e.activeElement)!=null?t:null}var _0=(i,e)=>{e(i)},b0=L('<div class="keyboard-controls s-x" tabindex="-1" role="region"><!></div>'),$0={hash:"s-x",code:".keyboard-controls.s-x{bottom:0;left:0;position:absolute;right:0;top:0}"};function Zf(i,e){var we,Ke;B(e,!0),Q(i,$0);let[t,o]=Be(),r=()=>w(Te,"$disabledControls$",t),a=()=>w(ze,"$isInteractiveTime$",t),l=()=>w(ie,"$showInteractiveTimeIndicatorTooltip$",t),d=()=>w(U,"$playbackState$",t),s=()=>w(Z,"$isEnded$",t),u=()=>w(ve,"$doubleForwardAvailable$",t),m=()=>w(qe,"$doubleForwardOn$",t),p=()=>w(N,"$overlayContainer$",t),v=()=>w(se,"$adPlaybackState",t),b=()=>w(G,"$positionExact$",t),y=()=>w(re,"$duration$",t),_=()=>w(_e,"$isAudioAvailable$",t),x=()=>w(X,"$volume$",t),I=()=>w(j,"$canChangePlaybackSpeed$",t),C=()=>w(ue,"$muted$",t),R=()=>w(te,"$currentSubtitle$",t),k=h(e,"nextButtonActive",3,!1),P=h(e,"prevButtonActive",3,!1),E=xe(),W=Rt(),F=E.getLogger().createComponentLog("KeyboardControls component"),U=E.state.playbackState$,j=E.state.canChangePlaybackSpeed$,se=E.ads.playbackState,G=E.state.positionExact$,re=E.state.duration$,X=E.state.volume$,Te=E.ui.controls.disabledControls$,ue=E.state.muted$,te=E.state.currentSubtitle$,be=E.ui.contextMenu.openedByHotKey$,Ce=E.ui.contextMenu.lastActiveElem$,me=E.ui.contextMenu.visible$,qe=E.ui.doubleForwardOn$,ve=E.ui.doubleForwardAvailable$,pe=E.ui.contextMenu.position$,Z=E.state.isEnded$,N=E.ui.overlayContainer$,ce=(we=E.callbacks)==null?void 0:we.onAudioDoesNotExistHint,de=(Ke=E.callbacks)==null?void 0:Ke.onAudioDisabledHint,_e=E.state.isAudioAvailable$,ge=E.state.isAudioDisabled,ze=E.state.isInteractiveTime$,{showInteractiveTimeIndicatorTooltip$:ie}=xo(),We=0,ee=!0,ke=K(void 0),Ue=Se=>(Se!==ee&&(ee=Se,We=0),We+=1,(W.controls.seekStepKeyboard+W.controls.seekStepKeyboard*We)/1e3),Ie=!0,Ae=()=>{if(!r().has("PLAY_BUTTON"))if(a()&&l()&&ie.set(!1),e.fakePlayButtonHandler)e.fakePlayButtonHandler();else{E.actions.internal.togglePlay();let Se="PLAY";d()===Ua.PAUSED?Se="PAUSE":s()&&(Se="REPLAY"),e.showHotKeyHelpers({type:Se})}},Ne=Se=>{if(!u()||!Se&&m()){Ae(),e.stopDoubleForward(),Ie=!0;return}Ie=!1,!Se&&e.startDoubleForwardActivationTimer()},gt=()=>{Ie||(m()||Ae(),e.stopDoubleForward(),Ie=!0)},It=Se=>{Se!=="Space"&&e.stopDoubleForward()},Lt=Se=>{let yt=q_(p());pe.set(yt),Ce.set(Se.target),be.set(!0),me.set(!0)},lt=(Se,yt=!1)=>{var ui,ao;let ye=Se.target,Fe=(ui=ye==null?void 0:ye.getAttribute("role"))==null?void 0:ui.includes("menuitem"),Qe=ye.classList.contains("btn"),rt=Se.code;if(Qe&&rt==="Space")return!1;let Kt=zh.has(rt);if(Fe&&Kt)return!1;let Nt=!Uh.has(rt);if(Se.ctrlKey&&Nt||Se.altKey&&Nt||Se.metaKey)return!1;let ai=Fe&&rt==="Escape";Wh.has(rt)||ai||e.hideContextMenu();let $i=d()===Ua.PLAYING||d()===Ua.PAUSED,gi=e.isAds&&(v()==="paused"||v()==="playing"),ro=!gi&&!r().has("TIMELINE"),so=Se.shiftKey&&["Digit1","Numpad1"].includes(rt);if(!so&&!($i||gi))return!1;F({message:`key down, code: ${rt}, isExternal = ${yt}`});let pi=!1,at=()=>{pi=!0,yt||Se.preventDefault()};if(It(rt),so)return Lt(Se),at(),!0;switch(rt){case"KeyJ":case"ArrowLeft":{if(!ro)break;if(Se.ctrlKey||Se.altKey){let St=E.actions.internal.getPrevEpisode();E.actions.internal.seekToPrevEpisode(St),St&&e.showHotKeyHelpers({type:"EPISODE_PREV",text:St.text}),at()}else{let St=Se.shiftKey?Ue(!1):W.controls.seekStepKeyboard/1e3,Ct=Math.max(b()-St,0);b()>0&&(E.actions.internal.seekTime(Ct,Kn.DOUBLE_TAP),e.showHotKeyHelpers({type:"BACKWARD_SEEK",text:St.toString()}),at())}break}case"KeyL":case"ArrowRight":{if(!ro)break;if(Se.ctrlKey||Se.altKey){let St=E.actions.internal.getNextEpisode();E.actions.internal.seekToNextEpisode(St),St&&e.showHotKeyHelpers({type:"EPISODE_NEXT",text:St.text}),at()}else{let St=Se.shiftKey?Ue(!0):W.controls.seekStepKeyboard/1e3,Ct=Math.min(b()+St,y());Math.round(b())<Math.round(y())&&(E.actions.internal.seekTime(Ct,Kn.DOUBLE_TAP),e.showHotKeyHelpers({type:"FORWARD_SEEK",text:St.toString()}),at())}break}case"ArrowUp":{if(ca({isAudioDisabled:ge,audioDisabledHintCallback:de,isAudioAvailable:_(),audioIsNotExistHintCallback:ce,isAds:e.isAds})){let St=x(),Ct=W.controls.volumeStepKeyboard,Si=St<=1;if(Nu(E,St,Ct),Si){let nt=Math.round(jf(St,Ct)*100).toString();e.showHotKeyHelpers({type:"VOLUME",t:{key:"hotkey_helper_current_volume",value:nt}})}}at();break}case"ArrowDown":{if(ca({isAudioDisabled:ge,audioDisabledHintCallback:de,isAudioAvailable:_(),audioIsNotExistHintCallback:ce,isAds:e.isAds})){let St=x(),Ct=W.controls.volumeStepKeyboard,Si=St>=0;if(Bu(E,St,Ct),Si){let nt=Math.round(Xf(St,Ct)*100).toString();e.showHotKeyHelpers({type:"VOLUME",t:{key:"hotkey_helper_current_volume",value:nt}})}}at();break}case"Comma":{if(Se.shiftKey){if(!m()&&I()){let St=E.actions.internal.decrementPlaybackRate();e.showHotKeyHelpers({type:"RATE_DOWN",text:St==null?void 0:St.displayValue}),at()}}else{if(gi||d()!==Ua.PAUSED)break;let St=Math.max(b()-W.controls.seekStepFrame/1e3,0);b()>0&&(e.showHotKeyHelpers({type:"BACKWARD_SEEK"}),E.actions.internal.clearDelayedBufferingCheckTimeout(),E.actions.internal.seekTime(St,Kn.DOUBLE_TAP),at())}break}case"Period":{if(Se.shiftKey){if(!m()&&I()){let St=E.actions.internal.incrementPlaybackRate();e.showHotKeyHelpers({type:"RATE_UP",text:St==null?void 0:St.displayValue}),at()}}else{if(gi||d()!==Ua.PAUSED)break;let St=Math.min(b()+W.controls.seekStepFrame/1e3,y());b()<y()&&(e.showHotKeyHelpers({type:"FORWARD_SEEK"}),E.actions.internal.clearDelayedBufferingCheckTimeout(),E.actions.internal.seekTime(St,Kn.DOUBLE_TAP),at())}break}case"KeyK":Ae(),at();break;case"Space":Ne(Se.repeat),at();break;case"KeyM":{ca({isAudioDisabled:ge,audioDisabledHintCallback:de,isAudioAvailable:_(),audioIsNotExistHintCallback:ce,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:(ao=R())==null?void 0:ao.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,Kn.DOUBLE_TAP),at();break;case"Digit2":case"Numpad2":e.showHotKeyHelpers(),E.actions.internal.seekToPercent(.2,Kn.DOUBLE_TAP),at();break;case"Digit3":case"Numpad3":e.showHotKeyHelpers(),E.actions.internal.seekToPercent(.3,Kn.DOUBLE_TAP),at();break;case"Digit4":case"Numpad4":e.showHotKeyHelpers(),E.actions.internal.seekToPercent(.4,Kn.DOUBLE_TAP),at();break;case"Digit5":case"Numpad5":e.showHotKeyHelpers(),E.actions.internal.seekToPercent(.5,Kn.DOUBLE_TAP),at();break;case"Digit6":case"Numpad6":e.showHotKeyHelpers(),E.actions.internal.seekToPercent(.6,Kn.DOUBLE_TAP),at();break;case"Digit7":case"Numpad7":e.showHotKeyHelpers(),E.actions.internal.seekToPercent(.7,Kn.DOUBLE_TAP),at();break;case"Digit8":case"Numpad8":e.showHotKeyHelpers(),E.actions.internal.seekToPercent(.8,Kn.DOUBLE_TAP),at();break;case"Digit9":case"Numpad9":e.showHotKeyHelpers(),E.actions.internal.seekToPercent(.9,Kn.DOUBLE_TAP),at();break;case"Digit0":case"Numpad0":e.showHotKeyHelpers(),E.actions.internal.seekToPercent(0,Kn.DOUBLE_TAP),at();break;case"Slash":{Se.shiftKey&&W.features.hotKeyMapModal&&(e.showKeyMap(),at());break}case"KeyN":Se.shiftKey&&k()&&(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:h0(rt);break}return pi},Et=Se=>{let yt=Se.code;if(Se.ctrlKey||Se.altKey||Se.metaKey)return;let ye=d()===Ua.PLAYING||d()===Ua.PAUSED,Fe=e.isAds&&(v()==="paused"||v()==="playing");if(ye||Fe)switch(yt){case"ShiftLeft":case"ShiftRight":We=0;break;case"Space":gt();break}},jt=Y("aria_label_video_player"),zt=()=>{var Se;return(Se=n(ke))==null?void 0:Se.focus()},Ot=()=>n(ke)===Hu(),Wt=Se=>Se.type==="keydown"?lt(Se,!0):(Se.type==="keyup"&&Et(Se),!1);var q=b0();q.__keyup=Et,q.__keydown=[_0,lt];var Le=T(q);oi(Le,()=>{var Se;return(Se=e.children)!=null?Se:_t}),S(q),it(q,Se=>O(ke,Se),()=>n(ke)),D(()=>De(q,"aria-label",jt)),$(i,q);var Re=H({focus:zt,isFocused:Ot,handleExternalKeyboardEvent:Wt});return o(),Re}Je(["keyup","keydown"]);var y0=L('<div class="container s-o"><div class="dot s-o"></div> <div class="dot s-o"></div> <div class="dot s-o"></div></div>'),x0={hash:"s-o",code:".container.s-o{display:flex;left:50%;pointer-events:none;position:absolute;top:50%;transform:translate(-50%,-50%)}.dot.s-o:first-child{animation-delay:0s}.dot.s-o:nth-child(2){animation-delay:.18s}.dot.s-o:nth-child(3){animation-delay:.36s}@keyframes s-o-dot_animation{0%{opacity:.2}30%{opacity:1}to{opacity:.2}}.dot.s-o{animation-duration:.75s;animation-iteration-count:infinite;animation-name:s-o-dot_animation;background:var(--btn-color);border-radius:4px;height:8px;width:8px}.dot.s-o+.dot:where(.s-o){margin-left:4px}"};function za(i,e){Q(i,x0);let t=h(e,"style",3,"");var o=y0();D(()=>je(o,t())),$(i,o)}var w0=Pe('<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 Jf(i,e){Ze(i,{get fill(){return e.fill},children:(t,o)=>{var r=w0();$(t,r)},$$slots:{default:!0}})}import{noop as Bl}from"@vkontakte/videoplayer-shared/es2015";var S0=i=>{i.stopPropagation()},C0=L("<button><!></button>"),T0={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 Ut(i,e){B(e,!0),Q(i,T0);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,Bl),b=h(e,"focus",3,Bl),y=h(e,"blur",3,Bl),_=f(()=>v()===Bl?null:k=>{k.stopPropagation(),v()(k)}),x=f(()=>b()===Bl?null:k=>{k.preventDefault(),b()()}),I=f(()=>y()===Bl?null:k=>{k.preventDefault(),y()()});var C=C0();C.__pointerdown=[S0],C.__click=function(...k){var P;(P=n(_))==null||P.apply(this,k)};var R=T(C);oi(R,()=>{var k;return(k=e.children)!=null?k:_t}),S(C),it(C,k=>s(k),()=>s()),D(()=>{var k,P,E,W,F,U,j,se;ne(C,1,`btn ${(k=t())!=null?k:""}`,"s-1n"),je(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",(j=a())!=null?j:null),De(C,"tabindex",p()),De(C,"role",e.role),De(C,"aria-checked",(se=e.areaChecked)!=null?se:null)}),ft("focus",C,function(...k){var P;(P=n(x))==null||P.apply(this,k)}),ft("blur",C,function(...k){var P;(P=n(I))==null||P.apply(this,k)}),$(i,C),H()}Je(["pointerdown","click"]);var I0=(i,e)=>{i.key==="Escape"&&e.onClose(),(i.key==="ArrowUp"||i.key==="ArrowDown")&&i.stopPropagation()},E0=L('<div class="modal-header s-1f"><h3 class="modal-title s-1f"> </h3> <!></div>'),P0=L('<div class="modal-overlay s-1f"><div class="modal-container s-1f" role="dialog" aria-modal="true"><!> <div class="modal-scroll s-1f" tabindex="0" role="scrollbar"><div class="modal-main s-1f"><!></div></div></div></div>'),A0={hash:"s-1f",code:'.modal-overlay.s-1f{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-1f{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-1f{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-1f{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-1f{height:100%;margin:8px 4px 8px 0;overflow-x:hidden;overflow-y:auto}.modal-scroll.s-1f::-webkit-scrollbar{width:8px}.modal-scroll.s-1f::-webkit-scrollbar-track{background-color:transparent;border-radius:4px;box-shadow:none;margin-right:2px}.modal-scroll.s-1f::-webkit-scrollbar-thumb{background-clip:padding-box;background-color:#666;border:1px solid transparent;border-radius:5px;min-height:40px}.modal-scroll.s-1f::-webkit-scrollbar-thumb:hover{background-color:#777}.modal-main.s-1f{margin:-8px -4px 0 0}'};function em(i,e){B(e,!0),Q(i,A0);let t=h(e,"showHeader",3,!0),o=h(e,"showCloseCross",3,!0),r=K(void 0),a=K(void 0),{webApi:{focusManager:l}}=xe(),d=Y("hotkey_map_modal_close_btn_text");Vt(()=>{var _;return(_=n(r))==null||_.focus(),n(a)&&l&&(l.setContainerForFocusLock(n(a)),l.activateLock()),()=>l==null?void 0:l.deactivateLock()});var s=P0();s.__keydown=[I0,e];var u=T(s),m=T(u);{var p=_=>{var x=E0(),I=T(x),C=T(I,!0);S(I);var R=A(I,2);{var k=P=>{Ut(P,{get click(){return e.onClose},testId:"close-modal",style:"padding: 0; height: 24px; width: 24px",get ariaLabel(){return d},children:(E,W)=>{Jf(E,{fill:"currentColor"})},$$slots:{default:!0}})};V(R,P=>{o()&&P(k)})}S(x),D(()=>he(C,e.title)),$(_,x)};V(m,_=>{t()&&_(p)})}var v=A(m,2),b=T(v),y=T(b);oi(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()}Je(["keydown"]);var k0=new Set(["BR"]),Y_=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;k0.has(l)||(r=a.parentElement)==null||r.removeChild(a)}return e.innerHTML};var L0=L('<li class="hot-key-map-item s-w"><span class="hot-key-map-item-description s-w"><!></span> &nbsp; <span class="hot-key-map-item-value s-w"> </span></li>'),M0=L('<div class="hot-key-map-group s-w"><h5 class="hot-key-map-group-title s-w"> </h5> <ul class="hot-key-map-group-items s-w"></ul></div>'),V0=L('<div class="hot-key-map s-w"></div>'),R0={hash:"s-w",code:'.hot-key-map.s-w{box-sizing:border-box;color:var(--black);overflow-x:hidden}.hot-key-map-group.s-w{border-bottom:1px solid var(--white-alpha-24);margin:0 20px 0 16px}.hot-key-map-group.s-w:last-child{border-bottom:none}.hot-key-map-group-title.s-w{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-w,.hot-key-map-item.s-w{margin:0;padding:12px 0;width:100%}.hot-key-map-group-items.s-w{box-sizing:border-box;list-style:none;margin:0;padding:0}.hot-key-map-item.s-w{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-w{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-w{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-w,.hot-key-map-item-value.s-w{font-feature-settings:"clig" off,"liga" off;font-size:13px;font-style:normal;font-weight:400;line-height:16px}'};function tm(i,e){B(e,!1),Q(i,R0);let[t,o]=Be(),r=()=>w(l,"$data",t),a=xe(),{data:l,show:d}=a.ui.modals.hotKeyMap,s=()=>{d.set(!1)};Yo(),em(i,{get title(){return r().title},onClose:s,children:(u,m)=>{var p=V0();bi(p,5,()=>r().groups,({title:v,items:b})=>v,(v,b)=>{let y=()=>n(b).title,_=()=>n(b).items;var x=M0(),I=T(x),C=T(I,!0);S(I);var R=A(I,2);bi(R,5,_,({description:k,value:P})=>P,(k,P)=>{let E=()=>n(P).description,W=()=>n(P).value;var F=L0(),U=T(F),j=T(U);xd(j,()=>Y_(E())),S(U);var se=A(U,2),G=T(se,!0);S(se),S(F),D(()=>he(G,W())),$(k,F)}),S(R),S(x),D(()=>he(C,y())),$(v,x)}),S(p),$(u,p)},$$slots:{default:!0}}),H(),o()}import{noop as Eb}from"@vkontakte/videoplayer-shared/es2015";import{ChromecastState as xb,PlaybackState as Qm}from"@vkontakte/videoplayer-core/es2015";import{getVideoQualityLabel as K0}from"@vkontakte/videoplayer-shared/es2015";var O0=L('<div class="pillow s-1x"><!></div>'),D0={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 im(i,e){Q(i,D0);var t=O0(),o=T(t);oi(o,()=>{var r;return(r=e.children)!=null?r:_t}),S(t),D(()=>De(t,"data-testid",e.testId)),$(i,t)}import{VideoQuality as Wd}from"@vkontakte/videoplayer-shared/es2015";var N0=Pe('<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 om(i,e){let t=Cn(e,["$$slots","$$events","$$legacy","children"]);var o=N0();io(o,()=>Me({xmlns:"http://www.w3.org/2000/svg",width:"9",height:"5",fill:"currentColor","fill-rule":"evenodd",role:"img"},t));var r=T(o);oi(r,()=>{var a;return(a=e.children)!=null?a:_t}),ti(),S(o),$(i,o)}var B0=Pe('<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 nm(i,e){let t=Cn(e,["$$slots","$$events","$$legacy","children"]);var o=B0();io(o,()=>Me({xmlns:"http://www.w3.org/2000/svg",width:"9",height:"5",fill:"currentColor","fill-rule":"evenodd",role:"img"},t));var r=T(o);oi(r,()=>{var a;return(a=e.children)!=null?a:_t}),ti(),S(o),$(i,o)}var H0=Pe('<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 rm(i,e){let t=Cn(e,["$$slots","$$events","$$legacy","children"]);var o=H0();io(o,()=>Me({xmlns:"http://www.w3.org/2000/svg",width:"9",height:"5",fill:"currentColor",role:"img"},t));var r=T(o);oi(r,()=>{var a;return(a=e.children)!=null?a:_t}),ti(),S(o),$(i,o)}var F0=Pe('<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 sm(i,e){let t=Cn(e,["$$slots","$$events","$$legacy","children"]);var o=F0();io(o,()=>Me({xmlns:"http://www.w3.org/2000/svg",width:"13",height:"5",fill:"currentColor",role:"img"},t));var r=T(o);oi(r,()=>{var a;return(a=e.children)!=null?a:_t}),ti(),S(o),$(i,o)}var U0=Pe('<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 am(i,e){let t=Cn(e,["$$slots","$$events","$$legacy","children"]);var o=U0();io(o,()=>Me({xmlns:"http://www.w3.org/2000/svg",width:"15",height:"7",fill:"currentColor",role:"img"},t));var r=T(o);oi(r,()=>{var a;return(a=e.children)!=null?a:_t}),ti(),S(o),$(i,o)}var Fu=i=>{switch(i){case Wd.Q_720P:return rm;case Wd.Q_1080P:return sm;case Wd.Q_1440P:return am;case Wd.Q_2160P:return om;case Wd.Q_4320P:return nm}};var z0=Pe('<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 lm(i,e){Ze(i,{get testId(){return e.testId},children:(t,o)=>{var r=z0();$(t,r)},$$slots:{default:!0}})}var W0=Pe('<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=W0();$(t,r)},$$slots:{default:!0}})}var q0=L('<div aria-hidden="true"><!> <!></div>'),Q0={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 Kd(i,e){B(e,!0),Q(i,Q0);let t=h(e,"isMobile",3,!1),o=h(e,"currentQuality",3,void 0),r=f(()=>o()?K0(o()):""),a=f(()=>Fu(o())),l=f(()=>n(r).length>2);var d=Oe(),s=le(d);{var u=p=>{lm(p,{testId:"settings-mobile-icon"})},m=p=>{var v=q0();let b;var y=T(v);{var _=C=>{let R=f(()=>`${n(r)}-pill-icon`);im(C,{get testId(){return n(R)},children:(k,P)=>{var E=Oe(),W=le(E);Hi(W,()=>n(a),(F,U)=>{U(F,{})}),$(k,E)},$$slots:{default:!0}})};V(y,C=>{n(a)&&C(_)})}var x=A(y,2);let I=f(()=>n(a)?"settings-icon--labeled":"settings-icon");dm(x,{get testId(){return n(I)}}),S(v),D(C=>b=ne(v,1,"icon s-1v",null,b,C),[()=>({triple:n(l)})]),$(p,v)};V(s,p=>{t()?p(u):p(m,!1)})}$(i,d),H()}var G0=L('<span class="settings-icon-wrapper s-23"><!></span>'),Y0={hash:"s-23",code:".settings-icon-wrapper.s-23{position:relative;width:24px}"};function Hl(i,e){B(e,!0),Q(i,Y0);let[t,o]=Be(),r=()=>w(u,"$settingsMenuVisible",t),a=()=>w(v,"$isMobile",t),l=()=>w(s,"$currentQuality",t),d=xe(),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);He(()=>{n(y)&&Pt(()=>{e.ref$.set(n(y))})});let _=b("aria_label_settings");function x(C){return ht(this,null,function*(){let R=da(C);r()?p():m(R,ho)})}let I=f(()=>r()?"opened":"");Ut(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 k=G0(),P=T(k);Kd(P,{get isMobile(){return a()},get currentQuality(){return l()}}),S(k),$(C,k)},$$slots:{default:!0}}),H(),o()}var j0=Pe('<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),X0=Pe("<path></path>");function ua(i,e){B(e,!0);let t=f(()=>`subtitles-icon${e.type==="off"?"-off":e.type==="outline"?"-outline":""}`),o=f(()=>un(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=j0();ti(),$(m,p)},u=m=>{var p=X0();D(()=>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 mm(t,e){B(e,!0);let i=h(e,"isSubtitlesEnabled",3,!1),r=be().ui.t,a=f(()=>i()?r("tooltip_subtitles_on"):r("tooltip_subtitles_off"));Ut(t,{testId:"subtitles-btn",get ariaLabel(){return n(a)},get click(){return e.click},get ariaKeyShortCut(){return hs.KeyC},role:"button",children:(l,d)=>{let s=f(()=>i()?void 0:"outline");ma(l,{get size(){return"24"},get type(){return n(s)}})},$$slots:{default:!0}}),H()}var Q0=L('<span class="duration s-21" data-testid="video_duration"> </span>'),G0=L('<div data-testid="time"><span class="current s-21" data-testid="current_time"> </span> <!></div>'),Y0={hash:"s-21",code:'.time.s-21{align-items:center;color:var(--controls-time);display:flex;font-variant-numeric:tabular-nums;font-weight:500;padding:12px 6px}.time.mobile.s-21{padding:0 0 0 8px}.current.s-21{position:relative}.duration.s-21{opacity:.7}.duration.s-21:before{content:" / ";white-space:pre}'};function Yd(t,e){B(e,!0),Q(t,Y0);let i=h(e,"isMobile",3,!1),o=h(e,"isHidden",3,!1),r=h(e,"showDuration",3,!0),a=h(e,"ref",15),l=Vt(),d=de(!1),s=f(()=>jo(e.duration)),u=f(()=>jo(e.position));var m=G0();let p;var v=C(m),b=C(v,!0);S(v);var y=k(v,2);{var _=x=>{var I=Q0(),T=C(I,!0);S(I),D(()=>ve(T,n(s))),$(x,I)};V(y,x=>{r()&&x(_)})}S(m),Bs(m,()=>Nl(o()&&l.features.usePerformanceFix,d,l.disableInvisibleComponentsTimeout)),Ze(m,x=>a(x),()=>a()),D(x=>{p=oe(m,1,"time s-21",null,p,x),ve(b,n(u))},[()=>({mobile:i()})]),$(t,m),H()}import{noop as Ku}from"@vkontakte/videoplayer-shared/es2015";var j0=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),X0=Ie("<path></path>"),Z0=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 va(t,e){B(e,!0);let i=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(i(),o())),l=f(()=>un(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";Je(t,{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=Z0(),v=k(ue(p));{var b=_=>{var x=j0();di(),$(_,x)},y=_=>{var x=X0();D(()=>Re(x,"d",`${d}${n(a)==="max"?s:""}`)),$(_,x)};V(v,_=>{n(a)==="off"?_(b):_(y,!1)})}$(u,p)},$$slots:{default:!0}}),H()}import{isNonNullable as Z_,noop as Zn}from"@vkontakte/videoplayer-shared/es2015";import{noop as gm}from"@vkontakte/videoplayer-shared/es2015";import{noop as ex}from"@vkontakte/videoplayer-shared/es2015";var J0=L('<div class="overlay"><!></div>');function vm(t,e){B(e,!0);let[i,o]=Oe(),r=()=>w(l,"$overlayContainer$",i),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))};De(()=>{u(r())}),Mt(()=>(u(r()),()=>s(r())));var m=J0(),p=C(m);ii(p,()=>{var v;return(v=e.children)!=null?v:ht}),S(m),Ze(m,v=>N(d,v),()=>n(d)),$(t,m),H(),o()}var tx=L('<div class="tooltip s-1p"><div class="content s-1p"> </div> <div class="tooltip-pointer s-1p"></div></div>'),ix=L("<div><!></div> <!>",1),ox={hash:"s-1p",code:'.tooltip-wrapper.s-1p{display:flex;flex-direction:column;min-width:0}.full-width.s-1p{width:100%}.tooltip.s-1p{bottom:100%;left:0;opacity:0;position:absolute;transition:opacity .2s,visibility .2s;visibility:hidden}.content.s-1p{background-color:rgba(41,41,41,.8);border-radius:3px;color:var(--white);display:inline-block;padding:6px 10px}.tooltip-pointer.s-1p{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 Qa(t,e){B(e,!0),Q(t,ox);let[i,o]=Oe(),r=()=>w(X,"$overlayContainer$",i),a=()=>w(U,"$containerSize",i),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,ex),_=5,x=q(void 0),I=q(void 0),T,R=q(0),A=q(0),P=q(0),E=q(0),z=Vt(),F=be(),U=F.ui.playerSize,X=F.ui.overlayContainer$;De(()=>{Tt(()=>{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,It=ce.top+m()-ne.top,wt=Le/2-_,Dt=Fe<8,at=Fe+Le>et-8;Dt&&(Fe=8,wt=Te+ce.width/2-2.5*_),at&&(Fe=et-8-Le,wt=ce.left-ne.left+ce.width/2-Fe-_),N(P,Fe,!0),N(E,It),N(R,wt,!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 wt=ce.top+m()-ne.top+et,Dt=Te-et/2,at=Te-_;N(P,Fe,!0),N(E,wt),N(A,Dt),N(R,at)},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())),O=f(()=>Qe(n(R),n(A)));Mt(me),cn(()=>window.clearTimeout(T));var Ge=ix(),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);ii(xe,()=>{var ne;return(ne=e.children)!=null?ne:ht}),S(K),Ze(K,ne=>N(x,ne),()=>n(x));var He=k(K,2);{var ot=ne=>{vm(ne,{children:(ce,Ne)=>{var Le=tx(),et=C(Le),Ee=C(et,!0);S(et);var Te=k(et,2);S(Le),Ze(Le,Fe=>N(I,Fe),()=>n(I)),D(()=>{qe(Le,n(G)),ve(Ee,d()),qe(Te,n(O))}),$(ce,Le)},$$slots:{default:!0}})};V(He,ne=>{d()&&!l()&&ne(ot)})}D(ne=>se=oe(K,1,"tooltip-wrapper s-1p",null,se,ne),[()=>({"full-width":p()})]),ut("pointerenter",K,Ce),ut("pointerleave",K,ge),$(t,Ge),H(),o()}Ye(["pointermove","pointerdown","pointerup"]);var X_=t=>{t.stopPropagation()},nx=L("<div><!></div>"),rx={hash:"s-1j",code:".btn-container.s-1j{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-1j{min-width:0;width:100%}"};function Ro(t,e){B(e,!0),Q(t,rx);let[i,o]=Oe(),r=()=>w(u,"$isGraphOpened$",i),a=()=>w(s,"$isMobile",i),l=be(),d=_o(),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,gm),z=h(e,"initialTranslateXPx",3,0),F=h(e,"initialTranslateYPx",19,()=>-18),U=h(e,"mouseEnter",3,gm),X=h(e,"mouseLeave",3,gm),ae=f(()=>v()?r()?m("tooltip_disabled_when_graph_on"):A():I()),Z=q(!1);De(()=>{T()||N(Z,!1)});var re=nx();re.__pointerdown=[X_],re.__click=[X_];var J=C(re);{var we=ee=>{Qa(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=Ve(),pe=ue(ge);ii(pe,()=>{var Qe;return(Qe=e.children)!=null?Qe:ht}),$(_e,ge)},$$slots:{default:!0}})},me=ee=>{var _e=Ve(),Ce=ue(_e);ii(Ce,()=>{var ge;return(ge=e.children)!=null?ge:ht}),$(ee,_e)};V(J,ee=>{b()&&n(ae)&&!a()?ee(we):ee(me,!1)})}S(re),Ze(re,ee=>y(ee),()=>y()),D(()=>{var ee;oe(re,1,`btn-container ${(ee=p())!=null?ee:""}`,"s-1j"),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)}),Ln(re,"clientWidth",_),$(t,re),H(),o()}Ye(["pointerdown","click"]);var sx=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 jd(t,e){let i=f(()=>(e.completed,"interactive-episode-completed-icon"));Je(t,{width:"20",height:"20",fill:"none",get testId(){return n(i)},children:(o,r)=>{var a=sx(),l=ue(a),d=k(l);D(()=>{Re(l,"fill",la),Re(l,"fill-opacity",e.completed?1:.24),Re(d,"fill",e.completed?"var(--interactive-episode-complete)":"white")}),$(o,a)},$$slots:{default:!0}})}var ax=L("<div><!></div>"),lx={hash:"s-18",code:".interactive-episode-icon.s-18{cursor:default;height:20px;position:absolute;transform:translateX(-50%);width:20px}.interactive-episode-icon.disabled.s-18{opacity:.4;pointer-events:none}"};function hm(t,e){B(e,!0),Q(t,lx);let o=be().ui.t,r=q(0),a=f(()=>o(e.videoEpisode.completed?"tooltip_episode_finished":"tooltip_episode_unfinished"));Ro(t,{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=ax();let u;var m=C(s);let p=f(()=>!!e.videoEpisode.completed);jd(m,{get completed(){return n(p)}}),S(s),D(v=>{u=oe(s,1,"interactive-episode-icon s-18",null,u,v),qe(s,`left: ${e.videoEpisode.from+e.videoEpisode.width/2}%`)},[()=>({disabled:e.disabled})]),Ln(s,"clientWidth",v=>N(r,v)),$(l,s)},$$slots:{default:!0}}),H()}var dx=L('<div><div class="video-episode-inner s-16"><div class="video-episode-loaded s-16"></div> <div></div></div></div>'),cx=L('<div class="video-episodes-wrap s-16"></div>'),ux={hash:"s-16",code:".video-episodes-wrap.s-16{height:100%;position:absolute;width:100%}.video-episode.s-16{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-16:first-child{padding-left:0}.video-episode.s-16:last-child{padding-right:0}.video-episode.s-16:not(.disabled):where(:hover,:active){transform:scaleY(1.5)}.video-episode-filled.s-16,.video-episode-inner.s-16,.video-episode-loaded.s-16{border-radius:var(--slider-radius);height:var(--slider-height);position:absolute}.video-episode-inner.s-16{background:var(--slider-bg);overflow:hidden;position:absolute;width:calc(100% - var(--slider-video-episode-gap)*2)}.video-episode.s-16:first-child .video-episode-inner:where(.s-16),.video-episode.s-16:last-child .video-episode-inner:where(.s-16){width:calc(100% - var(--slider-video-episode-gap))}.video-episode-loaded.s-16{background:var(--slider-loaded-bg);transition:transform .2s}.video-episode-filled.s-16,.video-episode-loaded.s-16{border-radius:var(--slider-radius);height:100%;left:-100%;position:absolute;width:100%}.video-episode-filled.s-16{background-color:var(--slider-filled-bg)}"};function _m(t,e){Q(t,ux);let i=h(e,"videoEpisodes",19,()=>[]);var o=cx();bi(o,21,i,r=>r.from,(r,a)=>{var l=dx();let d;var s=C(l),u=C(s),m=k(u,2);let p;S(s),S(l),D((v,b)=>{d=oe(l,1,"video-episode s-16",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-16",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),$(t,o)}function px(t,e,i,o,r,a,l){if(t.preventDefault(),e()&&N(i,e().getBoundingClientRect(),!0),o()||n(r)||!e())return;N(r,!0);let d=a(t.clientX,t.clientY);l()(d,t),e().setPointerCapture(t.pointerId)}function fx(t,e,i,o,r,a,l,d){if(t.preventDefault(),e())return;let s=i(t.clientX,t.clientY),u=o(t.clientX);r()(s,u,n(a).width,t),n(l)&&d()(s)}function mx(t,e,i,o,r){if(t.preventDefault(),e()||!n(i))return;N(i,!1);let a=o(t.clientX,t.clientY);r()(a,t)}function vx(t,e,i,o){t.stopPropagation(),t.preventDefault(),e()&&i()(o(t.clientX,t.clientY))}function gx(t,e,i,o,r,a){let l=e(t.clientX,t.clientY);i()&&o()(l),N(r,!1),a()(l)}var hx=L("<div></div>"),_x=L('<div class="bars s-h"><div class="loaded s-h"></div> <div></div></div>'),bx=L('<!> <div role="slider" tabindex="0"><!> <div><div></div></div></div>',1),$x={hash:"s-h",code:'.interactive-icons.s-h{position:absolute;top:-28px;width:calc(100% - 20px)}.interactive-icons.mobile.s-h{top:-10px}.slider.s-h{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-h{cursor:default}.slider.s-h: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-h{background:var(--slider-bg);overflow:hidden}.bars.s-h,.loaded.s-h{border-radius:var(--slider-radius);height:100%;position:absolute;width:100%}.loaded.s-h{background:var(--slider-loaded-bg);left:-100%;transition:transform .2s;will-change:transform}.filled.s-h{background-color:var(--slider-filled-bg);border-radius:var(--slider-radius);height:100%;left:-100%;position:absolute;width:100%}.slider.square.s-h,.slider.square.s-h .filled:where(.s-h),.slider.square.s-h .loaded:where(.s-h),.slider.square.s-h>.bars:where(.s-h){border-radius:unset}.filled.active-live.s-h{background-color:var(--timeline-slider-filled-active-live-bg)}.filled.ads.s-h{background-color:var(--slider-filled-ads)}.handleWrap.s-h{left:-100%;position:absolute;width:100%}.handle.s-h{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-h{background-color:var(--timeline-slider-handle-active-live-bg)}.handle-always-visible.s-h .handle:where(.s-h),.slider-dragging.s-h .handle:where(.s-h),.slider.s-h:hover .handle:where(.s-h){opacity:1;transform:scale(1);visibility:visible}.slider-dragging.s-h .handle:where(.s-h){transform:scale(1.3)}.slider-vertical.s-h{left:-8px;position:absolute;top:-18px;transform:rotate(-90deg);transform-origin:0 0}.slider.disabled.s-h{cursor:default;opacity:.4}'};function Ga(t,e){B(e,!0),Q(t,$x);let i=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,Zn),x=h(e,"onHandleMove",3,Zn),I=h(e,"onPointerUp",3,Zn),T=h(e,"onPointerEnter",3,Zn),R=h(e,"onPointerMove",3,Zn),A=h(e,"onPointerLeave",3,Zn),P=h(e,"onMouseEnter",3,Zn),E=h(e,"onMouseLeave",3,Zn),z=h(e,"onWheelUp",3,Zn),F=h(e,"onWheelDown",3,Zn),U=h(e,"onWheelLeft",3,Zn),X=h(e,"onWheelRight",3,Zn),ae=h(e,"onDisabledClick",3,Zn),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,Zn),pe=h(e,"handleAlwaysVisible",3,!1),Qe=Vt(),G=q(void 0),O=q(!1),Ge=f(()=>{var $e;return($e=ee())!=null?$e:0}),K=f(()=>{var $e;return Z_(m())&&(($e=m()[m().length-1])==null?void 0:$e.time)<n(Ge)}),se=f(()=>Z_(m())&&m().length&&n(K)&&n(Ge)?et(Z()*100,re()*100):[]);function xe($e){if($e.preventDefault(),i()&&N(G,i().getBoundingClientRect(),!0),b())return;let Me=Ne($e.clientX,$e.clientY),dt=Le($e.clientX);T()(Me,dt,n(G).width)}function He($e){$e.preventDefault(),!b()&&A()()}function ot(){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,Me){return l()?Math.max(0,Math.min(1,(n(G).height-(Me-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,Me){let dt=Qe.features.episodesClustering&&!v()?Qe.episodeMinWidthPc:0,St=[],fe=m()[0].time/n(Ge)*100,Ue=0,ze=0;for(let xt=1;xt<m().length;xt++)Ue=m()[xt].time/n(Ge)*100,Ue-fe>dt&&(St.push({from:fe,width:Math.max(0,Ue-fe),loadedWidth:Math.max(0,Math.min(Ue,$e)-fe),filledWidth:Math.max(0,Math.min(Ue,Me)-fe),interactive:m()[xt-1].interactive,completed:m()[xt-1].completed}),fe=m()[xt].time/n(Ge)*100,ze++);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(Me,100)-fe),interactive:m()[ze].interactive,completed:m()[ze].completed};100-fe<dt?(ze-=1,St[ze].width+=100-fe,St[ze].loadedWidth+=Math.max(0,Math.min($e,100)-fe),St[ze].filledWidth+=Math.max(0,Math.min(Me,100)-fe)):St[ze]=Ct;let si=m()[0].time;if(si!==0){let xt=si/n(Ge)*100;St.unshift({from:0,width:xt,loadedWidth:Math.min(xt,$e),filledWidth:Math.min(xt,Me)})}return St}function Ee($e){return Math.max(0,Math.min(100,$e*100))}let Te=f(()=>Ee(Z())),Fe=f(()=>Ee(re()));var It=bx(),wt=ue(It);{var Dt=$e=>{var Me=hx();let dt;bi(Me,21,()=>n(se),St=>St.from,(St,fe)=>{var Ue=Ve(),ze=ue(Ue);{var Ct=si=>{hm(si,{get videoEpisode(){return n(fe)},get disabled(){return b()}})};V(ze,si=>{n(fe).interactive&&si(Ct)})}$(St,Ue)}),S(Me),D(St=>dt=oe(Me,1,"interactive-icons s-h",null,dt,St),[()=>({mobile:s(),hidden:s()&&!n(O)})]),$($e,Me)};V(wt,$e=>{v()&&$e(Dt)})}var at=k(wt,2);let Et;at.__pointerdown=[px,i,G,b,O,Ne,_],at.__pointermove=[fx,b,Ne,Le,R,G,O,x],at.__pointerup=[mx,b,O,Ne,I],at.__click=[vx,b,ae,Ne],at.__contextmenu=[gx,Ne,b,ae,O,ge];var Zt=C(at);{var Pt=$e=>{_m($e,{get videoEpisodes(){return n(se)},get disabled(){return b()},get isMobile(){return s()}})},Ot=$e=>{var Me=_x(),dt=C(Me),St=k(dt,2);let fe;S(Me),D(Ue=>{Re(dt,"data-value",n(Te)),qe(dt,`transform: translateX(${n(Te)}%);`),fe=oe(St,1,"filled s-h",null,fe,Ue),Re(St,"data-value",n(Fe)),qe(St,`transform: translateX(${n(Fe)}%);`)},[()=>({"active-live":d()})]),$($e,Me)};V(Zt,$e=>{n(se).length?$e(Pt):$e(Ot,!1)})}var zt=k(Zt,2);let j;var Pe=C(zt);let le;S(zt),S(at),Ze(at,$e=>i($e),()=>i()),D(($e,Me,dt,St)=>{var fe,Ue;Et=oe(at,1,`slider ${(fe=o())!=null?fe:""}`,"s-h",Et,$e),Re(at,"aria-label",we()),Re(at,"aria-valuemin",me()),Re(at,"aria-valuemax",ee()),Re(at,"aria-valuenow",_e()),Re(at,"aria-valuetext",Ce()),Re(at,"data-testid",(Ue=r())!=null?Ue:null),j=oe(zt,1,"handleWrap s-h",null,j,Me),qe(zt,dt),le=oe(Pe,1,"handle s-h",null,le,St)},[()=>({disabled:b(),"slider-dragging":n(O),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",at,xe),ut("pointerleave",at,He),ut("mouseenter",at,ot),ut("mouseleave",at,ne),ut("wheel",at,ce),$(t,It),H()}Ye(["pointerdown","pointermove","pointerup","click","contextmenu"]);var oo=(t,e)=>Ld[t]>=Ld[e];var Us=(t,e)=>Ld[t]<=Ld[e],J_=t=>t>699?"xl":t>599?"l":t>509?"m":t>320?"s":"xs";var xx=L("<div><!></div>"),wx=L("<div><!> <!></div>"),Sx={hash:"s-29",code:".volumeBar-container.s-29{align-items:center;display:flex}.vertical.s-29 .btn,.vertical.s-29 .tooltip-wrapper,.volumeBar-container.vertical.s-29{width:40px}.volumeBar.s-29{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-29{padding:0 8px 0 0;width:0}"};function bm(t,e){var Le,et;B(e,!0),Q(t,Sx);let[i,o]=Oe(),r=()=>w(R,"$isAudioAvailable$",i),a=()=>w(v,"$muted$",i),l=()=>w(p,"$volume$",i),d=()=>w(x,"$currentGridType$",i),s=()=>w(xe,"$controlsVisible",i),u=be(),m=Vt(),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(()=>Us(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(){Fu(u,l(),m.controls.volumeStepWheel)}function _e(){Uu(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 O(){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;De(()=>{s()||N(se,!1)});var He=wx();let ot;var ne=C(He);Qa(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");Ut(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 hs.KeyM},role:"button",children:(It,wt)=>{va(It,{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=xx();let Fe;var It=C(Te);let wt=f(()=>n(X)?"volumeBar-slider-vertical":""),Dt=f(()=>n(X)&&!n(E)),at=f(()=>n(X)?pe:Ku),Et=f(()=>n(X)?Qe:Ku),Zt=f(()=>Math.round(n(re)*100)),Pt=f(()=>`${Math.round(n(re)*100)}%`),Ot=f(()=>n(X)?"volume-slider-vertical":"volume-slider");Ga(It,{get className(){return n(wt)},get isHidden(){return n(Dt)},get isVertical(){return n(X)},withWheelHandler:!0,onWheelUp:ee,onWheelDown:_e,onPointerDown:me,onHandleMove:Ce,onPointerUp:ge,get onPointerEnter(){return n(at)},get onPointerLeave(){return n(Et)},ariaLabel:"Ползунок громкости",ariaValueMin:0,ariaValueMax:100,get ariaValueNow(){return n(Zt)},get ariaValueText(){return n(Pt)},get filledProgress(){return n(re)},get handleProgress(){return n(re)},get testId(){return n(Ot)}}),S(Te),D(zt=>Fe=oe(Te,1,"volumeBar s-29",null,Fe,zt),[()=>({"volumeBar-vertical":n(X)})]),$(Ee,Te)};V(ce,Ee=>{n(F)&&Ee(Ne)})}S(He),D(Ee=>ot=oe(He,1,"volumeBar-container s-29",null,ot,Ee),[()=>({vertical:n(X)})]),ut("mouseenter",He,function(...Ee){var Te;(Te=n(X)?G:Ku)==null||Te.apply(this,Ee)}),ut("mouseleave",He,function(...Ee){var Te;(Te=n(X)?O:Ku)==null||Te.apply(this,Ee)}),ut("wheel",He,K),$(t,He),H(),o()}import{noop as Ix}from"@vkontakte/videoplayer-shared/es2015";var Cx=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>'),Tx=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 $m(t,e){let i=h(e,"isFullscreen",8,!1),o=In(()=>i()?"close-fullscreen-icon":"open-fullscreen-icon");Je(t,{get testId(){return n(o)},children:(r,a)=>{var l=Ve(),d=ue(l);{var s=m=>{var p=Cx();$(m,p)},u=m=>{var p=Tx();$(m,p)};V(d,m=>{i()?m(s):m(u,!1)})}$(r,l)},$$slots:{default:!0}})}function Xd(t,e){B(e,!0);let i=h(e,"isFullscreen",3,!1),o=h(e,"click",3,Ix),r=be(),a=r.ui.isFullscreenOpenedByKeyboard,l=r.ui.t,d=f(()=>i()?l("tooltip_fullscreen_on"):l("tooltip_fullscreen_off"));Ut(t,{testId:"fullscreen-btn",get ariaLabel(){return n(d)},click:u=>{let m=pa(u);a.set(m),o()()},get ariaKeyShortCut(){return hs.KeyF},role:"button",children:(u,m)=>{$m(u,{get isFullscreen(){return i()}})},$$slots:{default:!0}}),H()}var Ex=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 ym(t,e){let i=Mn(e,["$$slots","$$events","$$legacy","children"]);var o=Ex();io(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"},i));var r=C(o);ii(r,()=>{var a;return(a=e.children)!=null?a:ht}),di(),S(o),$(t,o)}var Px=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 xm(t,e){let i=Mn(e,["$$slots","$$events","$$legacy","children"]);var o=Px();io(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"},i));var r=C(o);ii(r,()=>{var a;return(a=e.children)!=null?a:ht}),di(6),S(o),$(t,o)}var kx={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 wm(t,e){B(e,!0),Q(t,kx);let i=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()&&!i()?91:i()?l:95),s=f(()=>!o()&&!i()?"vk-video-logo-icon--en":i()?a:"vk-video-logo-icon"),u=f(()=>`0 0 ${n(d)} 24`);xm(t,{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 Zd(t,e){B(e,!0);let[i,o]=Oe(),r=()=>w(b,"$isMobile",i),a=()=>w(v,"$currentGridType$",i),l=()=>w(_,"$isCyrillicRelatedInterface$",i),d=h(e,"ref",15,void 0),s=h(e,"logoClickable",3,!1),u=h(e,"targetUrl",3,""),m=Vt(),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()&&Us(a(),"m")||Us(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");Ut(t,{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=Ve(),U=ue(F);{var X=Z=>{wm(Z,{get logo(){return m.logoType},get short(){return n(T)},get isCyrillic(){return l()}})},ae=Z=>{ym(Z,{})};V(U,Z=>{n(x)?Z(X):Z(ae,!1)})}$(E,F)},$$slots:{default:!0}}),H(),o()}import{ChromecastState as Vx}from"@vkontakte/videoplayer-core/es2015";import{ChromecastState as tb}from"@vkontakte/videoplayer-core/es2015";var Ax=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-1d"></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-1d"></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-1d"></path>',1),Lx=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),Mx={hash:"s-1d",code:".animated.s-1d{animation-duration:1s;animation-iteration-count:infinite}.wave1.animated.s-1d{animation-name:s-1d-wave1}.wave2.animated.s-1d{animation-name:s-1d-wave2}.wave3.animated.s-1d{animation-name:s-1d-wave3}@keyframes s-1d-wave1{0%{opacity:.3}33%{opacity:1}66%{opacity:1}to{opacity:1}}@keyframes s-1d-wave2{0%{opacity:.3}33%{opacity:.3}66%{opacity:1}to{opacity:1}}@keyframes s-1d-wave3{0%{opacity:.3}33%{opacity:.3}66%{opacity:.3}to{opacity:1}}"};function Jd(t,e){B(e,!0),Q(t,Mx);let i=h(e,"isMobile",3,!1),o=f(()=>e.iconState===tb.CONNECTED),r=f(()=>e.iconState===tb.CONNECTING),a=f(()=>n(o)?"#2688EB":la),l=f(()=>e.size?un(e.size):void 0);var d=Ve(),s=ue(d);{var u=p=>{Je(p,{get fill(){return n(a)},get style(){return n(l)},testId:"chromecast-mobile-icon",children:(v,b)=>{var y=Ax();di(2),$(v,y)},$$slots:{default:!0}})},m=p=>{Je(p,{get style(){return n(l)},testId:"chromecast-icon",children:(v,b)=>{var y=Lx(),_=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;D((U,X,ae,Z,re)=>{x=oe(_,0,"wave2 s-1d",null,x,U),T=oe(I,0,"wave3 s-1d",null,T,X),A=oe(R,0,"wave1 s-1d",null,A,ae),E=oe(P,0,"s-1d",null,E,Z),F=oe(z,0,"s-1d",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=>{i()?p(u):p(m,!1)})}$(t,d),H()}import{noop as Rx}from"@vkontakte/videoplayer-shared/es2015";function ec(t,e){B(e,!0);let i=h(e,"ref",15,void 0),o=h(e,"isMobile",3,!1),r=h(e,"click",3,Rx),l=be().ui.t,d=f(()=>e.state===Vx.CONNECTED?l("tooltip_chromecast_on"):l("tooltip_chromecast_off"));Ut(t,{get ariaLabel(){return n(d)},get click(){return r()},testId:"btn-chromecast",get ref(){return i()},set ref(s){i(s)},children:(s,u)=>{Jd(s,{get isMobile(){return o()},get iconState(){return e.state}})},$$slots:{default:!0}}),H()}import{noop as Ox}from"@vkontakte/videoplayer-shared/es2015";var Nx=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 Sm(t){Je(t,{testId:"episodes-icon",children:(e,i)=>{var o=Nx();di(2),$(e,o)},$$slots:{default:!0}})}var qu=(t,e,i)=>i.filter(o=>o.time<=t*e).pop();var Dx=L('<span class="text mobile s-25"> </span> <div class="chevron-episodes s-25" data-testid="btn-episodes_icon"><!></div>',1),Bx=L('<span class="text s-25"> </span>'),Hx=L('<span class="text count s-25"> </span>'),Fx=L('<span class="icon s-25"><!></span> <!>',1),Ux={hash:"s-25",code:".icon.s-25{flex-shrink:0}.text.s-25{overflow:hidden;padding:0 8px;text-overflow:ellipsis;white-space:nowrap}.text.count.s-25{overflow:visible}.text.mobile.s-25{padding:0 3px 0 4px}.chevron-episodes.s-25{margin-bottom:-6px;opacity:.7;transform:scale(.8)}"};function tc(t,e){var J,we,me;B(e,!0),Q(t,Ux);let[i,o]=Oe(),r=()=>w(y,"$currentGridType$",i),a=()=>w(_,"$openedByKeyboard$",i),l=()=>w(x,"$panelOpened$",i),d=()=>w(I,"$isMobile",i),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:Ox,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=pa(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());De(()=>{var _e;let ee=qu(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(()=>oo(r(),"xl")?"FULL":oo(r(),"m")?"COUNT":"SHORT"),U=f(()=>`${T("tooltip_episodes")}: ${n(z)}`),X=(ee,_e,Ce)=>gt(null,null,function*(){yield mo(),(ee==null?void 0:ee.getAttribute("aria-expanded"))==="false"&&_e&&!Ce&&Tt(()=>{_.set(!1),ee.focus()})});De(()=>{X(n(R),a(),l())});var ae=Ve(),Z=ue(ae);{var re=ee=>{let _e=f(()=>d()?"px-0":""),Ce=f(()=>!b);Ut(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=Ve(),G=ue(Qe);{var O=K=>{var se=Dx(),xe=ue(se),He=C(xe,!0);S(xe);var ot=k(xe,2),ne=C(ot);Or(ne,{direction:"right"}),S(ot),D(()=>ve(He,n(z))),$(K,se)},Ge=K=>{var se=Fx(),xe=ue(se),He=C(xe);Sm(He,{}),S(xe);var ot=k(xe,2);{var ne=Ne=>{var Le=Bx(),et=C(Le,!0);S(Le),D(()=>ve(et,n(z))),$(Ne,Le)},ce=(Ne,Le)=>{{var et=Ee=>{var Te=Hx(),Fe=C(Te,!0);S(Te),D(()=>ve(Fe,m().length)),$(Ee,Te)};V(Ne,Ee=>{n(F)==="COUNT"&&Ee(et)},Le)}};V(ot,Ne=>{n(F)==="FULL"?Ne(ne):Ne(ce,!1)})}$(K,se)};V(G,K=>{d()?K(O):K(Ge,!1)})}$(ge,Qe)},$$slots:{default:!0}})};V(Z,ee=>{n(P)&&ee(re)})}$(t,ae),H(),o()}import{debounceFn as bb}from"@vkontakte/videoplayer-shared/es2015";import{ChromecastState as jx,PlaybackState as Kl,Player as Xx,PredefinedQualityLimits as ys,VideoFormat as oc,clientChecker as lb}from"@vkontakte/videoplayer-core/es2015";import{assertNonNullable as br,getHighestQuality as Zx,InterfaceLanguage as Jx,isInvariantQuality as e2,isNonNullable as t2,loadVKLangPack as i2,Logger as o2,map as db,merge as n2,Observable as Ju,Subject as ql,Subscription as km,TracerFactory as r2,ValueSubject as s2,VideoQuality as a2,devNull as l2,now as d2,filter as c2,once as u2}from"@vkontakte/videoplayer-shared/es2015";import{SeekAction as Ws}from"@vkontakte/videoplayer-statistics/es2015";import{detectEmbed as zx,devNull as ni,now as ri,withoutNullable as ib}from"@vkontakte/videoplayer-shared/es2015";import{addScript as Wx,Subject as pn,clearVideoElement as Kx}from"@vkontakte/videoplayer-shared/es2015";var qx="//ad.mail.ru/static/admanhtml/rbadman-html5.min.js",Qu=class{constructor(e,i){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 pn,loadStarted$:new pn,loadEnded$:new pn,loadError$:new pn,ready$:new pn,slotRequested$:new pn,started$:new pn,timeRemained$:new pn,paused$:new pn,resumed$:new pn,ended$:new pn,empty$:new pn,skipped$:new pn,clicked$:new pn,closed$:new pn,error$:new pn};this.loadAdman=e=>(ni.push("ui",{key:"videoplayer_embed",strings:["new","adman_load_start",this.useAdmanFromNPM?"npm":"http"],numbers:[ri()]}),this.useAdmanFromNPM?this.loadAdmanNPM(e):this.loadAdmanMailRu(e));this.loadAdmanMailRu=e=>new Promise((i,o)=>{let r;this.events.loadStarted$.next();let a=()=>{clearTimeout(r),delete window.admanAsyncInit,window.AdmanHTML?(ni.push("ui",{key:"videoplayer_embed",strings:["new","adman_async_init_done","http"],numbers:[ri()]}),i(),this.events.loadEnded$.next()):(ni.push("ui",{key:"videoplayer_embed",strings:["new","adman_init_timed_out","http"],numbers:[ri()]}),o())};Wx(qx,e,this.loadTimeout).then(()=>{ni.push("ui",{key:"videoplayer_embed",strings:["new","adman_script_loaded","http"],numbers:[ri()]}),window.AdmanHTML?(ni.push("ui",{key:"videoplayer_embed",strings:["new","adman_already_inited","http"],numbers:[ri()]}),i(),this.events.loadEnded$.next()):(ni.push("ui",{key:"videoplayer_embed",strings:["new","adman_wait_async_init","http"],numbers:[ri()]}),window.admanAsyncInit=a,r=window.setTimeout(a,this.initTimeout))}).catch(l=>{ni.push("ui",{key:"videoplayer_embed",strings:["new","adman_script_load_error","http",String(l)],numbers:[ri()]}),o(),clearTimeout(r)})});this.loadAdmanNPM=e=>new Promise((i,o)=>{let r;this.events.loadStarted$.next();let a=()=>{clearTimeout(r),delete window.admanAsyncInit,window.AdmanHTML?(ni.push("ui",{key:"videoplayer_embed",strings:["new","adman_init_done","npm"],numbers:[ri()]}),i(),this.events.loadEnded$.next()):(ni.push("ui",{key:"videoplayer_embed",strings:["new","adman_init_timed_out","npm"],numbers:[ri()]}),o())},l=()=>{d=!0,o()},d=!1,s=window.setTimeout(()=>{ni.push("ui",{key:"videoplayer_embed",strings:["new","adman_load_timed_out","npm"],numbers:[ri()]}),l()},this.loadTimeout);e.addEventListener("abort",l),e.aborted&&(ni.push("ui",{key:"videoplayer_embed",strings:["new","adman_load_aborted","npm"],numbers:[ri()]}),l()),window.AdmanHTML=window.AdmanHTML||null,import("@adtech/rbadman/out/rbadman-html5.min.js").then(()=>{ni.push("ui",{key:"videoplayer_embed",strings:["new","adman_chunk_imorted","npm","failed: "+String(d)],numbers:[ri()]}),!d&&(window.AdmanHTML?(ni.push("ui",{key:"videoplayer_embed",strings:["new","adman_already_inited","npm"],numbers:[ri()]}),i(),this.events.loadEnded$.next()):(ni.push("ui",{key:"videoplayer_embed",strings:["new","adman_wait_async_init","npm"],numbers:[ri()]}),window.admanAsyncInit=a,r=window.setTimeout(a,this.initTimeout)))},l).finally(()=>{clearTimeout(r),clearTimeout(s),e.removeEventListener("abort",l)})});this.onAdsReady=()=>{ni.push("ui",{key:"videoplayer_embed",strings:["new","adman_ads_ready"],numbers:[ri()]}),this.log({message:"ads ready"}),this.events.ready$.next(),this.startPreroll()};this.onAdStarted=(e,i)=>{var o;ni.push("ui",{key:"videoplayer_embed",strings:["new","adman_ad_started",e,"muted: "+i.muted],numbers:[ri(),i.bannerID]}),this.adsState&&this.playerState&&this.actions?(this.log({message:`ad started, section: ${e}, banner: ${JSON.stringify(i)}`}),this.events.started$.next(e),i.muted&&(this.setVolume(0),this.actions.setMuted(!0),this.log({message:"ad muted start"})),this.adsState.duration.set(i.duration),this.adsState.playbackState.set("playing"),this.adsState.canSkip.set(i.allowClose),this.adsState.secondsToWatchBeforeSkip.set(i.allowCloseDelay),this.startWatchDog(),(o=this.externalApi)!=null&&o.videoTrackAdEvent&&this.safeExternalCall(this.externalApi.videoTrackAdEvent,e,String(i.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;ni.push("ui",{key:"videoplayer_embed",strings:["new","adman_ad_pased",(e=this.currentAdSection)!=null?e:""],numbers:[ri()]}),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;ni.push("ui",{key:"videoplayer_embed",strings:["new","adman_ad_played",(e=this.currentAdSection)!=null?e:""],numbers:[ri()]}),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(ni.push("ui",{key:"videoplayer_embed",strings:["new","adman_ad_midroll_pioint"],numbers:[ri()]}),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;ni.push("ui",{key:"videoplayer_embed",strings:["new","adman_ad_skipped",(e=this.currentAdSection)!=null?e:""],numbers:[ri()]}),this.log({message:"ad skipped"}),this.stopWatchDog()};this.onAdClosed=()=>{var e;ni.push("ui",{key:"videoplayer_embed",strings:["new","adman_ad_closed",(e=this.currentAdSection)!=null?e:""],numbers:[ri()]}),this.log({message:"ad closed"}),this.currentAdSection&&this.events.closed$.next(this.currentAdSection),this.stopWatchDog(),this.switchToVideo()};this.onAdCompleted=()=>{var e;ni.push("ui",{key:"videoplayer_embed",strings:["new","adman_ad_completed",(e=this.currentAdSection)!=null?e:""],numbers:[ri()]}),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,i;ni.push("ui",{key:"videoplayer_embed",strings:["new","adman_ad_clicked",(e=this.currentAdSection)!=null?e:""],numbers:[ri()]}),this.log({message:"ad clicked"}),(i=this.videoElement)==null||i.pause(),this.currentAdSection&&this.events.clicked$.next(this.currentAdSection),this.stopWatchDog()};this.onAdError=(e="ad error")=>{ni.push("ui",{key:"videoplayer_embed",strings:["new","adman_ad_error",e],numbers:[ri()]}),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"),ni.push("ui",{key:"videoplayer_embed",strings:["new","adman_created"],numbers:[ri()]}),this.loadTimeout=i.loadTimeout,this.initTimeout=i.initTimeout,this.runtimeTimeout=i.runtimeTimeout,this.useAdmanFromNPM=i.useAdmanFromNPM,this.volumeMultiplier=Math.max(0,Math.min(i.volumeMultiplier,1)),this.isVsidOriginal=i.isVsidOriginal}init(e,i,o){this.actions=e,this.adsState=i,this.playerState=o}onAdmanLoadingError(){this.onAdError("adman loading error")}initAdman(e){return gt(this,null,function*(){var A,P;if(ni.push("ui",{key:"videoplayer_embed",strings:["new","adman_init","already inited: "+!!this.adman],numbers:[ri(),e.slotId]}),this.adman)return;this.events.init$.next(e.slotId),this.startWatchDog();let{width:i,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}=zx(),I=(A=_?x:window.location.href)!=null?A:window.location.href,T=ib(ke(Kt(ke(Kt(ke({},s),{dl:encodeURIComponent(I),autoplay:r?1:0,player_width:i,player_height:o}),b?{request_id:b}:{}),{duration:m}),u)),R=ib({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){ni.push("ui",{key:"videoplayer_embed",strings:["new","adman_init_threw",String(E)],numbers:[ri()]}),this.onAdError("could not init adman")}})}switchToVideo(e=!1){var o,r,a;if(ni.push("ui",{key:"videoplayer_embed",strings:["new","adman_switch_to_video",(o=this.currentAdSection)!=null?o:"","force: "+e],numbers:[ri()]}),this.currentAdSection===null&&!e){this.log({message:"switch to video, no currentAdSection. can't switch"});return}let i=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: ${i}`});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,!i)}}setPostrollPassed(e){var i;(i=this.adsState)==null||i.postrollPassed.set(e),this.log({message:"postroll passed"})}togglePlay(){var e;if(ni.push("ui",{key:"videoplayer_embed",strings:["new","adman_toggle_play",(e=this.currentAdSection)!=null?e:""],numbers:[ri()]}),this.adsState){this.log({message:"toggle play"});let i=ye(this.adsState.playbackState);i==="playing"?this.pause():i==="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 i=e*this.volumeMultiplier;if(this.log({message:`set volume ${i}`}),this.adman)try{this.adman.setVolume(i)}catch(o){this.onAdError("could not set ad volume")}this.videoElement&&(this.videoElement.volume=i)}setFullscreen(e){if(this.log({message:`set fullscreen ${e}`}),this.adman)try{this.adman.setFullscreen(e)}catch(i){this.onAdError("could not set ad fullscreen")}}startPreroll(){if(ni.push("ui",{key:"videoplayer_embed",strings:["new","adman_start_preroll"],numbers:[ri()]}),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(ni.push("ui",{key:"videoplayer_embed",strings:["new","adman_start_postroll",(e=this.currentAdSection)!=null?e:""],numbers:[ri()]}),this.adman&&this.actions){this.log({message:"start postroll"}),this.actions.switchFromVideoToAds(),this.currentAdSection="postroll",this.startWatchDog();try{this.adman.start("postroll")}catch(i){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(ni.push("ui",{key:"videoplayer_embed",strings:["new","adman_pplay",(e=this.currentAdSection)!=null?e:""],numbers:[ri()]}),this.adman){this.log({message:"ad play"}),this.startWatchDog();try{this.adman.resume(),this.events.resumed$.next()}catch(i){this.onAdError("could not resume ad")}}else this.onAdError("Can not play: Adman is not initialized")}pause(){var e;if(ni.push("ui",{key:"videoplayer_embed",strings:["new","adman_pause",(e=this.currentAdSection)!=null?e:""],numbers:[ri()]}),this.adman){this.stopWatchDog(),this.log({message:"ad pause"});try{this.adman.pause(),this.events.paused$.next()}catch(i){this.onAdError("could not pause ad")}}else this.onAdError("Can not pause: Adman is not initialized")}skip(){var e;if(ni.push("ui",{key:"videoplayer_embed",strings:["new","adman_skip",(e=this.currentAdSection)!=null?e:""],numbers:[ri()]}),this.adman){this.stopWatchDog(),this.log({message:"ad skip"});try{this.adman.skip(),this.events.skipped$.next()}catch(i){this.onAdError("could not skip ad")}}else this.onAdError("Can not skip: Adman is not initialized")}setPosition(e,i){var o;(o=this.adman)==null||o.setPosition(Math.floor(e),Math.floor(i))}destroy(){var e,i,o,r,a,l,d,s,u,m,p,v;ni.push("ui",{key:"videoplayer_embed",strings:["new","adman_destroy"],numbers:[ri()]}),this.log({message:"destroy"}),this.stopWatchDog(),(e=this.adman)==null||e.onReady(void 0),(i=this.adman)==null||i.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&&Kx(this.videoElement),this.isDestroyed=!0}safeExternalCall(e,...i){return gt(this,null,function*(){var o;try{return yield e(...i)}catch(r){return this.onAdError((o=r==null?void 0:r.message)!=null?o:"External call failed"),null}})}};var ob=t=>{let e=Math.round(t);return isNaN(e)||e<40?"":e>=40&&e<55?50:e>=55&&e<90?60:e>=90&&e<180?120:e>=180?240:""};var Cm=class{constructor(){this.oneLineRegExp=/\r\n|\n|\r/;this.twoLinesRegExp=/\r\n\r\n|\n\n|\r\r/}parse(e,i){let o=[],r=e.split(this.twoLinesRegExp);for(let a of r){let l={startTime:0,endTime:0,texts:[],lang:i},d=a.split(this.oneLineRegExp);for(let s of d)if(!l.startTime&&!l.endTime){let u=new Gu,{startTime:m,endTime:p}=u.parse(s);l.startTime=m,l.endTime=p}else if(s.trim()!==""){let u=new Tm,{texts:m}=u.parse(s);l.texts=[...l.texts,...m]}(l.startTime||l.endTime)&&l.texts.length>0&&o.push(l)}return o}},Gu=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 i={startTime:0,endTime:0},o=this.timingRegExp.exec(e);return o&&(i.startTime=this.calcTime(o[1],o[2],o[3],o[4]),i.endTime=this.calcTime(o[6],o[7],o[8],o[9])),i}parseTime(e){let i=this.timeRegExp.exec(e);return i?this.calcTime(i[1],i[2],i[3],i[4]):0}isTime(e){return this.timeRegExp.test(e)}calcTime(e="0",i="0",o="0",r="0"){let a=Number(e)*60*60,l=Number(i)*60,d=Number(o),s=+`0.${r}`;return a+l+d+s}},Tm=class{constructor(){this.letterTagRegExp=/<[a-z]*>|<\/[a-z]*>/}parse(e){let i={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 Gu;for(let l of r)a.isTime(l)?i.texts.push({type:"timestamp",value:a.parseTime(l)}):i.texts.push({type:"text",value:l});return i}},nb=Cm;import{isNonNullable as Im}from"@vkontakte/videoplayer-shared/es2015";var Ya,Li,Em=0,Pm=!1,rb="",sb=(t,e=0,i=0)=>t<e&&t<i,Yu=(t,e=0,i=0)=>t>=e&&t<=i,Qx=(t,e=0,i=0)=>t>e&&t>i,ab=(t,e,i,o=!1)=>{var d;let r=(d=i.find(({id:s})=>s===e.value))==null?void 0:d.subtitles;if(o)return r==null?void 0:r.find(({startTime:u,endTime:m})=>Yu(t,u,m));let a=t>=Em,l=t<Em;if(Em=t,l&&(Pm=!1),Im(Ya)&&Yu(t,Ya.startTime,Ya.endTime)&&rb===e.value)return Ya;if(!Im(Li)&&(r!=null&&r.length)&&!Pm){Li=r.find(({startTime:u,endTime:m})=>Yu(t,u,m)||a&&sb(t,u,m)),Ya=void 0,!Im(Li)&&r[r.length-1].endTime<t&&(Pm=!0);return}else{if(Yu(t,Li==null?void 0:Li.startTime,Li==null?void 0:Li.endTime))return Ya=Li,Li=void 0,rb=e.value,Ya;(a&&Qx(t,Li==null?void 0:Li.startTime,Li==null?void 0:Li.endTime)||l&&sb(t,Li==null?void 0:Li.startTime,Li==null?void 0:Li.endTime))&&(Li=void 0)}};var ju={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"},Gx={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"},ic=t=>{var e,i;return(i=(e=ju[t])!=null?e:ju[Gx[t]])!=null?i:void 0};import{Subscription as Yx}from"@vkontakte/videoplayer-shared/es2015";import"@vkontakte/videoplayer-statistics/es2015";var Xu=class{constructor(e,i,o,r=new Yx){this.oneStat=e;this.thinOneStat=i;this.mediascopePixel=o;this.statSubscription=r}destroy(){var e,i,o;(e=this.oneStat)==null||e.destroy(),(i=this.thinOneStat)==null||i.destroy(),(o=this.mediascopePixel)==null||o.destroy(),this.statSubscription.unsubscribe()}};var Zu=(i=>(i.DESKTOP_CONTROL_PANEL_LEFT="desktop-control-panel-left",i.DESKTOP_CONTROL_PANEL_RIGHT="desktop-control-panel-right",i))(Zu||{});var $s=t=>t!=null?t:0,zs=(t,e)=>{var r,a;let i=(r=t==null?void 0:t.getBoundingClientRect)==null?void 0:r.call(t),o=(a=e==null?void 0:e.getBoundingClientRect)==null?void 0:a.call(e);return{top:Math.round($s(i==null?void 0:i.top)-$s(o==null?void 0:o.top)),left:Math.round($s(i==null?void 0:i.left)-$s(o==null?void 0:o.left)),bottom:Math.round($s(i==null?void 0:i.bottom)-$s(o==null?void 0:o.top)),right:Math.round($s(i==null?void 0:i.right)-$s(o==null?void 0:o.left))}},zl=t=>{var i;let e=(i=t==null?void 0:t.getBoundingClientRect)==null?void 0:i.call(t);return{width:$s(e==null?void 0:e.width),height:$s(e==null?void 0:e.height)}};var Rn="off";var Wl=t=>!!(Math.round(Math.abs(t)/90)%2);var cb=({interfaceLanguage:t,isCyrillicRelatedInterface:e,videoId:i,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 Zv,Jv;let ge=Kt(ke({},b),{isAudioDisabled:l,live:Kt(ke({},(Zv=b.live)!=null?Zv:{}),{isLiveCatchUpMode:!!r})}),pe=v,Qe=r2.createRootTracer(pe.features.tracer),G=Qe.createComponentTracer("Store"),O=y||new Xx(ge,Qe,{playerId:_e,onDevNullLog:s==null?void 0:s.onDevNullLog});me==null||me.expose({corePlayer:O});let Ge=new o2,K=new Qu(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=Ha.getInstance(),xe=u==null?void 0:u.pictureInPictureApi,He=u==null?void 0:u.annotationsApi,ot=u==null?void 0:u.slotsApi,ne=u==null?void 0:u.focusManager,ce=Ge.createComponentLog("Store"),Ne,Le,et={},Ee=new yu,Te=new km,Fe="",It=de(!1),wt=J&&J.oneStat?oi(J.oneStat.vsid$):Nr(void 0),Dt=de(da()),at=de(!1),Et=()=>k_(document,lb.device.isIOS),Zt=(Jv=xe==null?void 0:xe.info.isActive$)!=null?Jv:new s2(!1),Pt=de(0),Ot=de(!1),zt=de(!1),j=de([]),Pe=n2(O.events.fatalError$,O.events.managedError$).subscribe(c=>j.update(g=>[...g,c])),le=Nr(!1,c=>{let g=O.events.fatalError$.subscribe(()=>c(!0));return()=>g.unsubscribe()}),$e=c=>gt(null,null,function*(){var ie;let g=Object.values(Jx).includes(c);if(pe.downloadVKLanguages&&(g&&pe.updateBuiltinLanguages||!Uf(c))){let Se;try{Se=yield i2(c,Hh,Fh)}catch(Xe){(ie=J==null?void 0:J.oneStat)==null||ie.logError({errorType:"VKLangPack",fatal:!1}),se==null||se.report(Xe,{errorType:"VKLangPack",fatal:!1})}Se&&(Ff({language:c,pack:Se,fallback:pe.defaultLanguage}),Me.set(c),dt.update(Xe=>Xe+1))}Uf(c)&&Me.set(c)}),Me=de(t),dt=de(0),St=de(e);$e(t);let fe=(c,g)=>{let M=ye(Me);return zf(M,c,g,pe.defaultLanguage)},Ue=de("thumb");Ue.subscribe(c=>{c==="ads"&&O.info.playbackState$.getValue()&&si()});let ze=(()=>{let c=mi([le,Ue],([g,M])=>g?"crashed":M);return Kt(ke({},c),{is:g=>ye(c)===g})})(),Ct=de(),si=()=>{Ct.set({muted:O.info.muted$.getValue()})},xt=(()=>{let c=de(new Set(_));return Kt(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)}})})(),Yt=de({width:0,height:0}),ci=null,Hi=O.info.isBuffering$,Rt=Nr(Hi.getValue(),c=>{let g=Hi.subscribe(M=>{M&&ci===null?ci=window.setTimeout(()=>{c(Hi.getValue()),ci=null},pe.loaderDelay):c(M)});return()=>{g.unsubscribe(),ci&&clearTimeout(ci)}});G.log("create store"),ce({message:"create store"});let vo=c=>{let g=c.container,M=()=>{wi=new MutationObserver(Se=>{let{removedNodes:Xe}=Se[0];Xe.length&&g.append(O.experimental.element$.getValue())}),wi.observe(g,{childList:!0})},ie=O.experimental.element$.getValue();if(ie)g.append(ie),M();else{let Se=O.experimental.element$.pipe(c2(Xe=>!!Xe),u2()).subscribe(Xe=>{g.append(Xe),M()});Te.add(Se)}},fi=c=>{ce({message:`init video, config: ${JSON.stringify(c)}`}),x?vo(c):(l2.push("ui",{key:"videoplayer_embed",strings:["new","core_init_video"],numbers:[d2()]}),O.initVideo(c)),G.log("init video",{isInteractive:x}),c.subtitles&&O.setExternalTextTracks(c.subtitles),Ne=c,Fe=c.subtitlesForcedLanguage||""},nt=new ql,jt=c=>nt.next(c),Fi=new ql,$i=new ql,Jt=new ql,wi=null,st={actionRewind$:Fi,actionSeek$:$i,inPiP$:Zt,inFullscreen$:new Ju(c=>Dt.subscribe(g=>c.next(g))),actionSetSubtitle$:Jt,nextMovie$:nt},lt=new ql,_i=new ql,Xo={actionSeek$:$i,actionSubtitlesSwitched$:lt,actionQuality$:_i,playerSize$:new Ju(c=>Yt.subscribe(g=>c.next(g))),inPiP$:Zt,inFullscreen$:new Ju(c=>Dt.subscribe(g=>c.next(g))),isLoaderVisible$:new Ju(c=>Rt.subscribe(g=>c.next(g)))};if(J){let{oneStat:c,thinOneStat:g,mediascopePixel:M,statSubscription:ie}=J;c&&(x||ie.add(c.attachTo(O)),ie.add(c.attachToUi(st)),ie.add(c.attachToAds(K.events)),c.authorize(a).catch(Se=>{ce({message:`onestat auth error ${String(Se)}`})}),M&&M.attachTo(O)),g&&(ie.add(g.attachTo(O,K.events)),ie.add(g.attachToUi(Xo)),ie.add(g.attachToAds(K.events)),g.updateContext({isMobile:ye(It)}),g.authorize(a))}if(se){let c=new km,g=(M,ie)=>c.add(M.subscribe(ie));if(g(O.events.managedError$,M=>{se.logIError(M)}),g(O.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 No=()=>{if(lb.device.isIOS&&Le)try{A_(Le)}catch(c){ce({message:`exitIosSafariFullscreen failed: ${c}`})}};Te.add(O.experimental.element$.subscribe(c=>{c&&(Le=c,c.classList.add("player-media"),Ua(xe)&&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(O.events.ended$.subscribe(()=>{var c;No(),(c=s==null?void 0:s.onEnded)==null||c.call(s)})).add(O.events.looped$.subscribe(()=>{var c;(c=s==null?void 0:s.onLooped)==null||c.call(s)})).add(O.events.started$.subscribe(()=>gt(null,null,function*(){var g,M;Ua(xe)&&(yield xe==null?void 0:xe.revealPictureInPicture());let c=O.info.muted$.getValue();(g=s==null?void 0:s.onStarted)==null||g.call(s),(M=et.onStarted)==null||M.call(et,c)}))).add(O.events.willSeek$.subscribe(({from:c,to:g})=>{var M;(M=s==null?void 0:s.onSeek)==null||M.call(s,c,g)})).add(O.events.autoplaySoundProhibited$.subscribe(()=>{var c;(c=s==null?void 0:s.onAutoplaySoundProhibited)==null||c.call(s)})).add(O.info.position$.subscribe(c=>{var M;let g=O.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(O.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(O.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(O.events.loadedMetadata$.subscribe(()=>{Ot.set(!0)})).add(O.info.is3DVideo$.subscribe(c=>{zt.set(c)})).add(O.info.isEnded$.subscribe(c=>{x&&(c?(T!=null&&T.getValue()&&xt.add(Ad),xt.add("PLAY_BUTTON")):xt.remove("PLAY_BUTTON"))})).add(O.info.liveTime$.subscribe(c=>{var g;(g=s==null?void 0:s.onLiveTime)==null||g.call(s,c)})).add(O.info.isStalled$.subscribe(c=>{var g;(g=s==null?void 0:s.onStalledChanged)==null||g.call(s,c)})).add(O.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 _t=new km,Bt=()=>{var Xe,At,Ht;let{debugLog:c}=pe,g,M="#9df7b7",ie="#efd169";if(c&&c!==!0){let{colors:Qt}=c;g=c.tag,M=(Xe=Qt==null?void 0:Qt[0])!=null?Xe:M,ie=(Ht=(At=Qt==null?void 0:Qt[1])!=null?At:Qt==null?void 0:Qt[0])!=null?Ht:ie}let Se=g?`: ${g}`:"";_t.add(O.events.log$.subscribe(Qt=>{console.debug(`%c sdk${Se} `,`background:${M};`,`sdk component: ${Qt.component}`,Qt.message)})).add(Ge.log$.subscribe(Qt=>{console.debug(`%c ui${Se} `,`background:${ie};`,`ui component: ${Qt.component}.`,Qt.message)}))},W=()=>{_t.unsubscribe()},Lt=(c,g)=>{G.log("start camera manual rotation",{mx:c,my:g}),O.startCameraManualRotation(c,g)},ai=(c=!1)=>{G.log("stop camera manual rotation",{immediate:c}),O.stopCameraManualRotation(c)},vt=(c,g,M)=>{G.log("move camera focus px",{xpx:c,ypx:g,dt:M}),O.moveCameraFocusPX(c,g,M)},ti=()=>{O.holdCamera()},qt=()=>{O.releaseCamera()},Ke=Nr(O.info.position$.getValue(),c=>{let g,M,ie=()=>{let Se=O.info.playbackState$.getValue(),Xe=O.info.isLive$.getValue(),At=O.info.duration$.getValue(),Ht=O.info.position$.getValue();if(Se&&[Kl.PLAYING,Kl.PAUSED].includes(Se)){let Qt=Xe?Ht-At:O.getExactTime();Qt!==M&&c(Qt),M=Qt}g=requestAnimationFrame(ie)};return ie(),()=>cancelAnimationFrame(g)}),Ui=oi(O.info.playbackState$),Xi=oi(O.info.isBuffering$),Zo=mi([Ui,Xi],([c,g])=>g?"buffering":c),tr=oi(O.info.currentBuffer$),ro=oi(O.info.isEnded$),Ei=oi(O.info.isLive$),bo=pe.features.playbackRate?oi(O.info.canChangePlaybackSpeed$):Nr(!1),Oo=oi(O.info.liveBufferTime$),$o=oi(O.info.volume$),Pi=oi(O.info.muted$),yo=xu(O.info.predefinedQualityLimitType$.pipe(db(c=>c===ys.TRAFFIC_SAVING)),O.info.predefinedQualityLimitType$.getValue()===ys.TRAFFIC_SAVING),xo=xu(O.info.predefinedQualityLimitType$.pipe(db(c=>c===ys.HIGH_QUALITY)),O.info.predefinedQualityLimitType$.getValue()===ys.HIGH_QUALITY),Jo=oi(O.info.autoQualityLimitingAvailable$),Br=oi(O.info.availableQualities$),Hr=oi(O.info.availableQualitiesFps$),ss=oi(O.info.chromecastState$),ws=oi(O.info.chromecastDeviceName$),$r=oi(O.info.currentFormat$),ir=oi(O.info.throughputEstimation$),Fr=oi(O.info.videoBitrate$),mn=oi(O.info.intrinsicVideoSize$),vn=oi(O.info.duration$),yr=oi(O.info.isAudioAvailable$),xr=()=>{ci&&clearTimeout(ci),ci=null},en=mi([vn,Ei],([c,g])=>g?-c:c),wr=mi([Ui],([c])=>c===Kl.PLAYING),Sr=oi(O.info.atLiveEdge$),Cr=oi(O.info.atLiveDurationEdge$),Nn=oi(O.info.position$),Ur=mi([Nn,vn],([c,g])=>isFinite(c)&&isFinite(g)&&!!g),Ss=mi([ss],([c])=>c===jx.CONNECTED),zr=oi(O.info.availableVideoStreams$),Si=pe.features.audioLanguages?oi(O.info.availableAudioStreams$):Nr([]),as=oi(O.info.currentVideoStream$),tn=oi(O.info.currentAudioStream$),pt=c=>{c.language&&Of(c.language),O.setVideoStream(c)},ei=(c,g)=>{O.setAudioStream(c),Ho(g)&&(c.language&&Of(c.language),pe.features.userVideoPrefs&&i&&Hf(pe.userSalt,String(i),{audioTrackId:c.id}))},On=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&&i){let ie=Iu(pe.userSalt,String(i));if(ie!=null&&ie.audioTrackId){let Se=c.find(Xe=>Xe.id===ie.audioTrackId);g=Se!=null?Se:g}}let M=f_();return M&&(g!=null||(g=c.find(({language:ie})=>M===ie))),g!=null||(g=c.at(0)),g},or=c=>{G.log("change audio stream",{id:c});let g=O.info.availableAudioStreams$.getValue().find(M=>M.id===c);g&&ei(g,!0)},Wr=!1;Te.add(O.info.availableAudioStreams$.subscribe(c=>{if(!Wr&&c.length){let g=On(c);g&&(O.setAudioStream(g),Wr=!0)}})),Si.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})))}),tn.subscribe(c=>{var g;return c&&((g=s==null?void 0:s.onAudioStreamChanged)==null?void 0:g.call(s,c.id))});let nr=!1;Te.add(O.info.availableVideoStreams$.subscribe(c=>{if(!nr&&c.length){let g=On(c);g&&(O.setVideoStream(g),nr=!0)}}));let rr=de(void 0),Do=oi(O.info.isAutoQualityEnabled$,c=>c&&rr.set(void 0)),Tr=oi(O.info.currentQuality$,()=>rr.set(void 0)),Dn=mi([rr,Tr],([c,g])=>c!=null?c:g),sr=mi($r,c=>c!==oc.MPEG),ar=mi([Br,Hr,Do,Dn,sr],([c,g,M,ie,Se])=>{let Xe=[];Se&&Xe.push({value:"auto",displayValue:fe("auto_quality_option"),selected:M});let At=c.filter(Ht=>!e2(Ht));for(let Ht of At){let Qt=g[Ht];Xe.push({value:Ht,displayValue:`${Ht}${Qt?ob(Qt):""}`,selected:M?!1:Ht===ie})}return Xe}),on=oi(O.info.currentPlaybackRate$),gn=mi([on,Sr,Cr],([c,g,M])=>{let ie=M||x?1:pe.controls.playbackRateMin,Se=g?1:pe.controls.playbackRateMax,Xe=pe.controls.playbackRateStep,At=[];for(let Ht=ie;Ht<=Se;Ht+=Xe)At.push({value:Ht,displayValue:Ht===1?fe("playback_rate_1"):fe("playback_rate",{multiplier:Ht.toString(10)}),selected:c===Ht});return At}),Bn=()=>({displayValue:fe("subtitles_off"),value:Rn,language:""}),Mi=de(Bn()),Vi=mi([Mi,dt],([c],g)=>{c.value===Rn?g(Bn()):g(c)}),Bo=pe.features.subtitles?oi(O.info.availableTextTracks$):Nr([]),Hn=t_(),lr=mi([Bo,Vi],([c,g],M)=>{var Xe;let ie=[],Se=c.find(({id:At})=>At===g.value);if(Se!=null&&Se.url){let[,At]=(Xe=Hn.find(Se.url))!=null?Xe:[];if(At){M(At);return}Ee.download(Se.url).then(Ht=>{if(!Ht||Ee.isDestroyed())return;let Qt=new nb,Zs=Se.language;if(Zs){let l$=!!Se.isAuto,d$=Qt.parse(Ht,Zs);ie.push({lang:Zs,subtitles:d$,isAuto:l$,id:Se.id})}Hn.add(Se.url,ie),ye(Vi).value===g.value&&M(ie)}).catch(Ht=>{var Qt;(Qt=J==null?void 0:J.oneStat)==null||Qt.logError({errorType:"Subtitles download",fatal:!1}),se==null||se.report(Ht,{errorType:"Subtitles download",fatal:!1})})}M(ie)}),Fn=mi([on,wr,Vi],([c,g,M],ie)=>{let At;if(O.info.isLive$.getValue()&&g&&M.value!==Rn){let Qt=()=>{let Zs=1e3/(3*c);At=setTimeout(Qt,Zs),ie(Date.now())};return Qt(),()=>clearTimeout(At)}}),Ir=mi([Bo,Vi],([c,g])=>{if(!c.length)return[];let M=[];for(let{language:ie,isAuto:Se,id:Xe}of c){let At=ie&&ic(ie);ie&&At&&M.push({displayValue:Se?fe("subtitles_auto",{language:At}):At,value:Xe,selected:(g==null?void 0:g.value)===Xe,isAuto:Se,language:ie})}return M.length?(M.unshift(Kt(ke({},Bn()),{selected:(g==null?void 0:g.value)===Rn})),M):[]}),ct={available:[],prev:[]},kt=()=>{var g,M;let c=O.experimental.getCurrentTime$.getValue();return(M=(g=c==null?void 0:c())!=null?g:Le==null?void 0:Le.currentTime)!=null?M:0},so=mi([Ke,Vi,lr,Fn],([c,g,M,ie])=>{var Xe;let Se=O.info.isLive$.getValue();if(Se&&ct.prev!==M){let At=M.find(({id:Qt})=>Qt===g.value),Ht=ct.prev.find(({id:Qt})=>Qt===g.value);if(At){let Qt=Kt(ke({},At),{subtitles:[...(Xe=Ht==null?void 0:Ht.subtitles)!=null?Xe:[],...At.subtitles]});ct.available=[Qt],ct.prev=M}}if(g&&g.value!==Rn){let At=Se?kt():c,Ht=Se?ct.available:M;return ab(At,g,Ht,Se)}}),wo=mi([so],([c])=>c!=null&&c.texts?c.texts:[]);Te.add(Vi.subscribe(c=>{var g,M;if(c.value===Rn)(g=s==null?void 0:s.onSubtitleOff)==null||g.call(s);else{let ie=Object.entries(ju).find(([Se,Xe])=>Xe===c.displayValue);(M=s==null?void 0:s.onSubtitleOn)==null||M.call(s,ie?ie[0]:"",c.value)}}));let So=de(!0),hn=mi([tr,en,Nn,Oo],([c,g,M,ie])=>{var Ht;let Se=(Ht=c==null?void 0:c.end)!=null?Ht:0;if(!ie)return Se/g;let At=-M+ie-g;return(Se-At)/g}),ao=oi(O.info.availableSources$),_n=mi([ao],([c])=>Object.keys((c==null?void 0:c[oc.MPEG])||{}).length>0),Zi=()=>{var M,ie,Se;let c=Object.keys(((ie=(M=O.info.availableSources$)==null?void 0:M.getValue())==null?void 0:ie[oc.MPEG])||{}),g=Zx(c)||a2.Q_144P;return(Se=Ne.sources[oc.MPEG])==null?void 0:Se[g]},bn=()=>{var g;let c=Zi();if(c)G.log("download video",{url:c}),Zh(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})}},Co=()=>{ce({message:"toggle muted"});let c=O.info.muted$.getValue();O.info.volume$.getValue()===0&&!c?Er(qr(),!1):$n(!c,!1)},Cs=()=>{var c;if(Wt.ui.settingsMenu.visible$.set(!1),!ye(Wt.ui.settingsSubMenu.visible$)){let g=ye(Wt.ui.settingsMenu.ref$);if((c=s==null?void 0:s.uiInfo)!=null&&c.onSettingsMenu&&g){let ie=zl(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")},Kr=(c,g=()=>Promise.resolve())=>gt(null,null,function*(){var Se;Wt.ui.settingsMenu.openedByBtnKeyboard$.set(!!c),Wt.ui.settingsMenu.visible$.set(!0),yield g();let M=ye(Wt.ui.settingsMenu.ref$),ie=xa();if((Se=s==null?void 0:s.uiInfo)!=null&&Se.onSettingsMenu&&M&&ie){let At=zl(M),Ht=zs(M,ie);s.uiInfo.onSettingsMenu({visible:!0,size:At,position:Ht,name:"settings"})}G.log("open settings menu",{wasOpenedByKeyboard:c})}),Ts=(c,g=!1)=>{var Xe;Wt.ui.settingsSubMenu.visible$.set(!1);let M=ye(Wt.ui.settingsMenu.ref$),ie=xa(),Se=ye(Wt.ui.settingsMenu.visible$);if((Xe=s==null?void 0:s.uiInfo)!=null&&Xe.onSettingsMenu&&M&&ie)if(Se&&!g){let Ht=zl(M),Qt=zs(M,ie);s.uiInfo.onSettingsMenu({visible:!0,size:Ht,position:Qt,name:"settings"})}else{let Ht=zl(c),Qt={top:0,left:0,bottom:0,right:0},Zs=ye(Wt.ui.settingsSubMenu.name$);s.uiInfo.onSettingsMenu({visible:!1,size:Ht,position:Qt,name:Zs})}G.log("close settings sub menu")},zi=(c,g)=>{var ie;Wt.ui.settingsSubMenu.visible$.set(!0),Wt.ui.settingsSubMenu.ref$.set(g),Wt.ui.settingsSubMenu.name$.set(c);let M=xa();if((ie=s==null?void 0:s.uiInfo)!=null&&ie.onSettingsMenu&&g&&M){let Xe=zl(g),At=zs(g,M);s.uiInfo.onSettingsMenu({visible:!0,name:c,size:Xe,position:At})}G.log("open settings sub menu",{name:c})},qr=()=>{var g;let c=Math.max(pe.volumeMinRestore,(g=wu())!=null?g:0);return c===0?pe.volumeDefault:c},Ho=c=>{let g=pe.features.savePreferredStatesOnUserActionOnly;return!g||g&&!c},Er=(c,g)=>{let M=c===0?qr():c,ie=O.info.muted$.getValue();ce({message:`set volume, volume: ${c}, preferredVolume: ${M}`});let Se=!l||ze.is("ads");ie&&c>0&&Se&&(ie=!1,Ho(g)&&Rf(!1)),O.setVolume(c,ie),K.setVolume(c),Ho(g)&&Af(M)},$n=(c,g)=>{let M=O.info.volume$.getValue();ce({message:`set muted, currentVolume: ${M}, mute: ${c}`});let ie=ze.is("ads");if(O.setMuted(c,ie),K.setVolume(c?0:M),Ho(g)&&(!ie||!c)&&Rf(c),!c&&M===0){let Se=qr();O.setVolume(Se),Ho(g)&&Af(Se),K.setVolume(Se)}},Qr=de(!1),We=c=>{var g,M;G.log("set looped",{isLooped:c}),Qr.set(c),O.setLooped(c),(M=(g=s==null?void 0:s.uiInfo)==null?void 0:g.onLoopedChanged)==null||M.call(g,c)};We(re);let yt=()=>{var c,g;(g=(c=s==null?void 0:s.uiInfo)==null?void 0:c.onReportProblem)==null||g.call(c)},ui=(c,g=!1)=>{var M;ce({message:`set autoplayNextEnabled, value: ${c}`}),G.log("set autoplay next enabled",{autoplayNextEnabled:c}),Wt.ui.autoplayNextEnabled$.set(c),g_(c),g&&((M=s==null?void 0:s.onSetAutoplayNextEnabled)==null||M.call(s,c))},go=c=>{ce({message:`set timerNextVideoRunning, value: ${c}`}),G.log("set timer next video running",{timerNextVideoRunning:c}),Wt.ui.timerNextVideoRunning$.set(c)},ki=(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()},Fo=(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()},lo=()=>{var c;(c=s==null?void 0:s.onNextVideoAnnouncementShow)==null||c.call(s)},Uo=()=>{var c;(c=s==null?void 0:s.onNextVideoAnnouncementClick)==null||c.call(s)},nn=()=>{var c;(c=s==null?void 0:s.onNextVideoAnnouncementAuto)==null||c.call(s)},dr=()=>{var c;(c=s==null?void 0:s.onNextVideoAnnouncementCancel)==null||c.call(s)},To=()=>{O.prepare()},rn=()=>{br(Wt);let c=ye(Wt.ui.controls.disabledControls$),g=ye(Wt.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 Xe;ce({message:"toggle play, call player.play"}),M.action="play",O.play(),(Xe=s==null?void 0:s.onPlay)==null||Xe.call(s)},Se=()=>{var Xe;ce({message:"toggle play, call player.pause"}),M.action="pause",O.pause(),(Xe=s==null?void 0:s.onPause)==null||Xe.call(s)};if(O.info.isEnded$.getValue()){if(ce({message:"toggle play, video ended, seek to 0"}),Fi.next(),$i.next(Ws.REWIND),x){R==null||R();return}O.seekTime(0),ie()}else O.info.playbackState$.getValue()!==Kl.PLAYING?ie():Se();G.log("toggle play",M)},Un=(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&&_i.next(c),O.setAutoQuality(c==="auto");let{qualityDetailsSubMenuEnabled:Xe}=pe.features;Su(),c!=="auto"?(Xe?(Cu({type:"exact_quality",quality:c,videoId:i},M),O.setPredefinedQualityLimits(ys.UNKNOWN)):Lf(i,c),rr.set(c),O.setQuality(c)):Xe&&g==="default"&&(ls("auto_quality",M,Se),ye(yo)&&Io(!1,void 0,Se),ye(xo)&&yn(!1,void 0,Se))},Io=(c,g="as-default",M)=>{ce({message:`set trafficSavingEnabled, value: ${c}`}),G.log("set traffic saving enabled",{trafficSavingEnabled:c});let ie=c?ys.TRAFFIC_SAVING:ys.UNKNOWN;pe.features.qualityDetailsSubMenuEnabled?(zn(ie,g,M),Md(!1)):(O.setPredefinedQualityLimits(ie),Ho(M)&&Md(c))},yn=(c,g="as-default",M)=>{ce({message:`set highQualityEnabled, value: ${c}`}),G.log("set high quality enabled",{highQualityEnabled:c}),zn(c?ys.HIGH_QUALITY:ys.UNKNOWN,g,M)},zn=(c,g,M)=>{c!==ys.UNKNOWN&&(ye(Jo)&&!ye(Do)&&Un("auto",{appliesTo:g,changeReason:"limit-changed"},M),ls(c,g,M)),O.setPredefinedQualityLimits(c)},ls=(c,g,M)=>{Ho(M)&&(Cu({type:c,videoId:i},g),g==="as-default"&&Cu({type:c,videoId:i},"to-video"))},cr=(c,g=!0)=>{G.log("set playback rate",{playbackRate:c}),O.setPlaybackRate(c),pe.features.saveRate&&we&&!O.info.isLive$.getValue()&&g&&m_(c)},je=()=>{let c=ye(bo),g=ye(gn),M=g.findIndex(({selected:Se})=>Se);if(M===g.length-1||!c)return g[M];let ie=g[M+1];return cr(ie.value),ie},Xt=()=>{let c=ye(bo),g=ye(gn),M=g.findIndex(({selected:Se})=>Se);if(M===0||!c)return g[M];let ie=g[M-1];return cr(ie.value),ie},yi=(c=Kt(ke({},Bn()),{selected:!1}),g)=>{G.log("set subtitles",ke({},c)),c.value!==Rn&&Jt.next(c.isAuto?c.value+"_auto":c.value),lt.next({enabled:c.value!==Rn,lang:c.language,auto:!!c.isAuto}),Mi.set(c),Ho(g)&&(Bf(c.value===Rn?void 0:c.language),pe.features.userVideoPrefs&&i&&Hf(pe.userSalt,String(i),{subtitleTrackId:c.value===Rn?void 0:c.value}))},zo=c=>{G.log("toggle subtitles");let g=ye(Vi);(g==null?void 0:g.value)===Rn?Pr(c):sn(c)},xn=(c,g)=>{G.log("change subtitle",{enabled:c}),c?Pr(!0,g):sn(!0)},Pr=(c,g)=>{G.log("subtitle on");let M=ye(Ir),ie=ye(Me),Se=Fe!=null?Fe:ie,Xe;g&&(Xe=M.find(At=>At.value===g)),Xe!=null||(Xe=M.filter(At=>At.value!==Rn).find(At=>At.language===Se)),yi(Xe!=null?Xe:M[1],c)},sn=c=>{G.log("subtitle off"),yi(void 0,c)};Te.add(O.info.availableTextTracks$.subscribe(c=>{var M;function g(){let ie=[];for(let{language:Se,isAuto:Xe,id:At}of c){let Ht=Se&&ic(Se);Se&&Ht&&ie.push({id:At,language:Se,title:Xe?fe("subtitles_auto",{language:Ht}):Ht})}return ie}(M=s==null?void 0:s.onAvailableSubtitlesChanged)==null||M.call(s,g())}));let an=de(!0),Is=c=>{an.set(c)},kr=(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}),$i.next(g),O.info.isLive$.getValue()){let Se=O.info.duration$.getValue(),Xe=Math.min(0,Se+c);O.seekTime(Xe,M)}else{if(T!=null&&T.getValue())return;O.info.isEnded$.getValue()&&(ce({message:"seek after ended, call callbacks.onPlay"}),(ie=s==null?void 0:s.onPlay)==null||ie.call(s)),O.seekTime(Ao(c),M)}},Es=c=>{ce({message:`seek to episode start time: ${c}`}),G.log("seek to episode start time",{time:c}),kr(c,Ws.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(en)*c;kr(ie,g,M)},Ps=c=>{ce({message:`seek external, time: ${c}`}),G.log("seek external",{time:c}),$i.next(Ws.UNKNOWN),O.seekTime(O.info.isLive$.getValue()?-c:c)},ft=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}),O.setAutoQualityLimits(c)},pi=c=>{ce({message:`seek external to episode start time: ${c}`}),G.log("seek external to episode start time",{time:c}),kr(c,Ws.EPISODE,!0)},Eo=c=>{ce({message:`set playback rate to: ${c}`}),G.log("set playback rate external",{playbackRate:c}),O.setPlaybackRate(c)},co=de(!1),wn=de(!1),Ri=mi([en],([c])=>!!p&&c>=pe.suitableDurationForUsingRichSeek&&pe.features.useRichSeek&&!x),ds=((p==null?void 0:p.frameWidth)||0)>=((p==null?void 0:p.frameHeight)||0),ks=mi([Pt],([c])=>{let g=Wl(c);return ds?!g:g});Te.add(ze.subscribe(c=>{c!=="video"&&co.set(!1)})),co.subscribe(c=>{var g;(g=s==null?void 0:s.onRichSeekActiveChanged)==null||g.call(s,c)});let Wi=de(void 0),Ii=de(!1),Wn=c=>{ce({message:`start scrubbing, progress: ${c}`}),G.log("start scrubbing",{progress:c}),Ii.set(!0),Ar(c)},Ar=c=>{Wi.set(c)},he,it,vi=()=>{Wi.set(void 0),Ii.set(!1)},Ai=()=>{clearTimeout(it),clearTimeout(he),he=window.setTimeout(()=>{vi()},500),Le==null||Le.removeEventListener("seeked",Ai)},Sn=(c,g=!1)=>{ce({message:`complete scrubbing, progress: ${c}`}),G.log("complete scrubbing",{progress:c}),Ys(c,Ws.SLIDER,g),ye(Wt.ui.isMobile)&&ye(Wt.state.currentFormat$)===oc.HLS?(Le==null||Le.addEventListener("seeked",Ai),it=window.setTimeout(()=>{Ai()},300)):vi()},Po=mi([Ke,en,Wi],([c,g,M],ie)=>{ie(t2(M)?M*g:c)}),Ni=de(!1),Kn=()=>{Ni.set(!0)},As=()=>{Ni.set(!1)},Gr=mi([Yt],([{width:c}],g)=>{let M=J_(c);g(M)}),ha=z.filter(c=>Jh(c)),cs=mi([Gr,It],([c,g])=>g?ha.filter(M=>!M.hideOnMobile):ha.filter(M=>{var ie;return!((ie=M.hideOnDesktopGridTypes)!=null&&ie.includes(c))})),Cn=de(z.filter(c=>e_(c))),_a=mi([Cn,Gr],([c,g])=>c.filter(M=>{var ie;return!((ie=M.hideOnDesktopGridTypes)!=null&&ie.includes(g))})),ba=mi([_a,cs],([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))),Yr=de(F),al=mi([Yr],([c])=>pe.features.additionalSettingsMenuItems?c.map(g=>g.type==="SWITCH"?Kt(ke({},g),{onClick:g.onChangeEnabled}):g):[]),ed=(c,g)=>{let M=ye(Cn).map(ie=>ie.id!==c?ie:ke(ke({},ie),g));Cn.set(M)},$a=c=>{let g=ye(Cn);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),Cn.set(g)},td=c=>{let g=ye(Cn);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),Cn.set(g)},ll=c=>{$i.next(Ws.LIVE),ce({message:"live switch to low latency "+c}),G.log("live switch to low latency "+c),O.setLiveLowLatency(c)},dl=(c,g)=>{let M=ye(Yr).map(ie=>ie.id!==c?ie:ke(ke({},ie),g));Yr.set(M)},ya=c=>{let g=ye(Yr);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),Yr.set(g)},mt=c=>{let g=ye(Yr);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),Yr.set(g)},rt=de(U),Ji=mi([rt],([c])=>pe.features.additionalContextMenuItems?c:[]),ko=(c,g)=>{let M=ye(rt).map(ie=>ie.id!==c?ie:ke(ke({},ie),g));rt.set(M)},eo=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)},gi=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)},Ki=mi([It,le],([c,g],M)=>{M(c&&g)}),js=()=>{$i.next(Ws.LIVE),ce({message:"switch to active live"}),G.log("switch to active live"),O.seekTime(0),O.info.playbackState$.getValue()!==Kl.PLAYING&&Wt.actions.internal.togglePlay()},id=()=>{G.log("skip adman"),K.skip()},Mc=(c=!0)=>{var ie;br(Wt),ce({message:`switch from ads to video, callPlay: ${c}`}),G.log("switch from ads to video",{callPlay:c}),Ue.set("video"),c&&O.play(),l&&$n(!0,!0);let g=(ie=ye(Ct))==null?void 0:ie.muted,M=!O.info.muted$.getValue();g!==void 0&&!M&&$n(g,!0),Ct.set(void 0)},yp=()=>{br(Wt),ce({message:"switch from video to ads"}),G.log("switch from video to ads"),Wt.actions.internal.pause(),No(),Ue.set("ads")},Vc=c=>{br(Wt);let g=c?"LiveWaitingStart":"thumb";G.log("set live waiting start",{state:c,playerPhase:g}),Ue.set(g)},xp=c=>{br(Wt);let g=c?"LiveWaitingRecover":"thumb";G.log("set live waiting recover",{state:c,playerPhase:g}),Ue.set(g)},Rc=c=>{br(Wt);let g=c?"LiveWaitingRecord":"thumb";G.log("set live waiting record",{state:c,playerPhase:g}),Ue.set(g)},wp=()=>(br(Wt),G.log("get debug text data"),jh(O,Ne,Wt,Qe.getTraceId(),Ce)),Nc=()=>(br(Wt),JSON.stringify(Qe.getFinishedSpans())),Sp=()=>(br(Wt),Xh(O,Ne,Wt)),xa=()=>Le,Cp=()=>{ce({message:"toggle chromecast"}),G.log("toggle chromecast"),O.toggleChromecast()},Xs=c=>{var M;if(br(Wt),O.info.isEnded$.getValue())return;let g=!c;if(ye(Wt.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)),O.pause()},wa=c=>{var M;br(Wt);let g=!c;if(ye(Wt.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)),O.play()},Oc=c=>{br(Wt);let g=!c;if(ye(Wt.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()},Dc=(c,g)=>{br(Wt),ce({message:`first start, show ads: ${c}, internalCall: ${!g}`}),G.log("first start",{showAds:c,external:g}),c?Ue.set("ads"):(Ue.set("video"),g?O.play():Wt.actions.internal.togglePlay())},cl=()=>(ce({message:"getting time codes"}),m),Bc=()=>{let c=cl();if(!c||[0,1].includes(c.length))return;let g=O.info.position$.getValue();return c.find(M=>M.time>g)},Hc=c=>{let g=c;g||(g=Bc());let M=O.info.position$.getValue();G.log("seek to next episode",ke({currentTime:M},g)),g&&(ce({message:"seek to next episode"}),kr(g.time,Ws.EPISODE,!0))},Fc=()=>{let c=cl();if(!c||[0,1].includes(c.length))return;let g=O.info.position$.getValue(),M=c.findIndex(Se=>Se.time>g),ie=M===-1?c.length-2:M-2;if(!(ie<0))return c[ie]},Uc=c=>{let g=c;g||(g=Fc());let M=O.info.position$.getValue();G.log("seek to prev episode",ke({currentTime:M},g)),g&&(ce({message:"seek to prev episode"}),kr(g.time,Ws.EPISODE,!0))},Tp=()=>(ce({message:"getting preview thumbs data"}),G.log("get preview thumbs data",ke({},p)),p),Ip=()=>gt(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})}),Ep=(c=-90)=>{G.log("rotate video",{alphaDiff:c}),Pt.update(g=>g+c)},Be=de([]);I==null||I.subscribe(c=>{let g=[];for(let M=0;M<c.length;M++){let{range:[ie,Se],subjects:Xe}=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?!Xe.length||Xe.every(At=>At.isRemoved):!Xe.length}),Se!==1/0&&g.push({time:Se/1e3,text:"",interactive:!1,completed:!0})}Be.set(g)});let hi=de(!1);T==null||T.subscribe(c=>{c&&ye(Ii)&&vi()});let Ao=c=>{if(!x)return c;let g=ye(Be),M=ye(en),Se=ye(Nn)/M,Xe=g.find(At=>At.interactive&&!At.completed&&At.time>Se);return typeof(Xe==null?void 0:Xe.time)=="number"?Math.min(c,Xe.time-.05):c},Lr=()=>{Wt.ui.episodes.panelOpened$.set(!1)},Tn=()=>{G.log("destroy store"),clearTimeout(it),clearTimeout(he),Te.unsubscribe(),_t.unsubscribe(),O.destroy(),K.destroy(),J==null||J.destroy(),se==null||se.destroy(),Pe.unsubscribe(),wi==null||wi.disconnect(),wi=null,Ee.destroy()},o$=mi([Sr,ze,bo],([c,g,M])=>v.features.doubleForwardAvailable&&!c&&g==="video"&&M),Pp=de(!1),jv=2,zc=null,Xv=c=>{if(!ye(wr)&&c)return;let g=O.info.currentPlaybackRate$.getValue();c?g!==jv&&(zc=g,cr(jv,!1),Pp.set(!0)):(zc&&cr(zc,!1),Pp.set(!1),zc=null)};ze.subscribe(c=>{c!=="video"&&Xv(!1)});let n$=()=>{Xs(!1),co.set(!0)},r$=()=>{wa(!1),co.set(!1)},kp=!1,s$=()=>{wn.set(!0),kp=O.info.playbackState$.getValue()===Kl.PLAYING,Xs(!1)},a$=()=>{wn.set(!1),!ye(co)&&kp&&wa(!1),kp=!1};O.events.playing$.subscribe(()=>{ye(co)&&Xs(!1)});let Wt={interfaceLanguage$:Me,isCyrillicRelatedInterface$:St,initVideo:fi,videoId:i,isClip:o,playerPhase:ze,vsid:wt,state:{positionExact$:Ke,positionWithScrubbing$:Po,duration$:en,playbackState$:Ui,playbackStateRealistic$:Zo,isPlaying$:wr,isLoaderVisible:Rt,bufferedProgress$:hn,isLive$:Ei,canChangePlaybackSpeed$:bo,isActiveLive$:Sr,isOldestAvailableLive$:Cr,isRewindableLive$:Ur,isEnded$:ro,muted$:Pi,volume$:$o,trafficSavingEnabled$:yo,highQualityEnabled$:xo,autoQualityLimitingAvailable$:Jo,availableVideoStreams$:zr,availableAudioStreams$:Si,videoStream$:as,audioStream$:tn,currentQuality$:Dn,isAutoQualityEnabled$:Do,availableQualities$:ar,currentPlaybackRate$:on,availablePlaybackRates$:gn,currentSubtitle$:Vi,availableTextTracks$:Bo,availableSubtitlesList$:Ir,currentSubtitleCaptions$:wo,isAutoSubtitleCaptionVisible$:So,chromecastState$:ss,chromecastDeviceName$:ws,chromecastConnected$:Ss,currentFormat$:$r,throughputEstimation$:ir,videoBitrate$:Fr,videoSize$:mn,errorLog$:j,crashed$:le,isAudioAvailable$:yr,isAudioDisabled:!!l,canDownload:pe.features.download&&!!d,availableSources$:ao,hasMpegSources$:_n,isInteractive:x,showInteractiveGraph:pe.features.interactiveGraph,showSeekToInteractive:pe.features.seekToInteractive,showPlayPrevChapter:pe.features.interactivePlayPrevChapter,showInteractiveTimeIndicator:pe.features.interactiveTimeIndicator&&!!ye(Be).length,interactiveEpisodes$:Be,isInteractiveTime$:T?oi(T):de(!1),isInteractiveExpectation$:hi,hasInteractiveBranches:P,playPrevChapterDisabledTooltip:E,looped$:Qr,loadedMetadata$:Ot,isAutoQualityAvailable$:sr,previewTrackActive:co,previewTrackDragInProgress:wn},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$:xt},modals:{hotKeyMap:{show:de(!1),data:de({title:"",closeBtnText:"",groups:[]})}},isFullscreen:Dt,isFullscreenOpenedByKeyboard:at,rotateAlpha:Pt,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:Yt,isMobile:It,mobileNotReportControlHidden$:Ki,icon3DVideoVisible:de(!1),scrubbingInProgress:Ii,volumeChangingInProgress:Ni,is3DVideo:zt,currentGridType$:Gr,additionalButtonsDeprecated$:cs,additionalDesktopControlPanelRightButtons$:ba,additionalSettingsMenuItems$:al,additionalContextMenuItems$:Ji,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:an,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$:Pp,doubleForwardAvailable$:o$,previewTrackNotificationVisible:de(!1),previewTrackActive:co,previewTrackDragInProgress:wn,previewTrackAvailable:Ri,isPreviewTrackHorizontallyAligned:ks},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:ot,focusManager:ne},actions:{internal:{preload:To,firstStart:c=>Dc(c,!1),play:()=>wa(!1),pause:()=>Xs(!1),togglePlay:rn,toggleMuted:Co,openSettingsMenu:Kr,closeSettingsMenu:Cs,openSettingsSubMenu:zi,closeSettingsSubMenu:Ts,setVolume:c=>Er(c,!1),setMuted:c=>$n(c,!1),startVolumeChanging:Kn,stopVolumeChanging:As,setVideoStream:pt,setAudioStream:c=>ei(c,!1),setQuality:(c,g)=>Un(c,g,!1),setTrafficSavingEnabled:(c,g)=>Io(c,g,!1),setHighQualityEnabled:(c,g)=>yn(c,g,!1),setPlaybackRate:cr,incrementPlaybackRate:je,decrementPlaybackRate:Xt,setSubtitle:c=>yi(c,!1),toggleSubtitle:()=>zo(!1),togglePictureInPicture:Ip,startScrubbing:Wn,progressScrubbing:Ar,completeScrubbing:Sn,toggleChromecast:Cp,switchToActiveLive:js,switchFromAdsToVideo:Mc,switchFromVideoToAds:yp,skipAd:id,setLiveWaitingStart:Vc,setLiveWaitingRecover:xp,setLiveWaitingRecord:Rc,getDebugTextData:wp,getTraceTextData:Nc,getDebugPanelData:Sp,getVideoElement:xa,seekTime:(c,g,M)=>kr(c,g,M),clearDelayedBufferingCheckTimeout:xr,seekEpisodeStartTime:Es,seekToPercent:Ys,getNextEpisode:Bc,seekToNextEpisode:Hc,getPrevEpisode:Fc,seekToPrevEpisode:Uc,startLogging:Bt,stopLogging:W,startCameraManualRotation:Lt,stopCameraManualRotation:ai,moveCameraFocusPX:vt,holdCamera:ti,releaseCamera:qt,getVideoEpisodes:cl,getPreviewThumbsData:Tp,downloadVideo:bn,addLanguage:Ff,setLanguage:$e,nextMovie:jt,videoRotate:Ep,correctSeekTimeToInteractive:Ao,replayInteractive:R,setLooped:We,reportProblem:yt,setAutoplayNextEnabled:ui,setTimerNextVideoRunning:go,prevVideoClick:ki,nextVideoClick:Fo,nextVideoAnnouncementShow:lo,nextVideoAnnouncementClick:Uo,nextVideoAnnouncementAuto:nn,nextVideoAnnouncementCancel:dr,checkFullscreenSupport:Et,changeDoubleForwardOn:Xv,closePreviewTrack:r$,previewTrackOpened:n$,previewTrackDragStarted:s$,previewTrackDragFinished:a$},external:{firstStart:c=>Dc(c,!0),play:()=>wa(!0),pause:()=>Xs(!0),stop:()=>Oc(!0),seekTime:c=>Ps(c),seekEpisodeStartTime:c=>pi(c),setPlaybackRate:c=>Eo(c),setAutoQualityLimits:c=>ft(c),setMuted:c=>$n(c,!0),toggleSubtitle:()=>zo(!0),changeSubtitle:xn,setVolume:c=>Er(c,!0),returnFocusToEpisodes:Lr,updateAdditionalSettingsItem:dl,addAdditionalSettingsItem:ya,removeAdditionalSettingsItem:mt,updateAdditionalContextItem:ko,addAdditionalContextItem:eo,removeAdditionalContextItem:gi,updateAdditionalButton:ed,addAdditionalButton:$a,removeAdditionalButton:td,setLiveLowLatency:ll,hideControls:()=>Is(!1),showControls:()=>Is(!0),setQuality:c=>Un(c,{appliesTo:"to-video"},!0),setTrafficSavingEnabled:c=>Io(c,"to-video",!0),setHighQualityEnabled:c=>yn(c,"to-video",!0),changeAudioStream:or}},callbacks:s,setUiCallbacks:c=>{et=ke({},c)},getAdmanWrapper:()=>K,getLogger:()=>Ge,getPlayer:()=>O,destroy:Tn};return Wt};function Jn(t,e,i,o){var m;let r=(m=e[i])==null?void 0:m.getBoundingClientRect(),a=o&&!!r&&!!(r.right-r.left),{top:l,left:d,bottom:s,right:u}=zs(e[i],t||void 0);return{left:a?d:0,right:a?u:0,top:a?l:0,bottom:a?s:0,isDisplayed:a}}var p2=["disabledControls$","additionalButtons"],f2=["interactiveTimeIndicator"],Gl=(t,e,i,o)=>{if(t){for(let[r,a]of Object.entries(e))if(!p2.includes(r)){let l=o||f2.includes(r);a.set(Jn(t,i,r,l))}}};var ep=(t,e,i)=>gt(null,null,function*(){yield mo(),e&&i&&(i.focus(),t.set(!1))});var m2=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 Am(t){Je(t,{children:(e,i)=>{var o=m2();$(e,o)},$$slots:{default:!0}})}function Lm(t,e){B(e,!0);let[i,o]=Oe(),r=()=>w(s,"$contextMenuVisible$",i),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);De(()=>{n(b)&&Tt(()=>{v.set(n(b))})});let y=T=>{let R=pa(T),A=q_(n(b));p.set(A),u.set(R),s.set(!r())},_=()=>{m.set(!0)},x=()=>{m.set(!1)},I=f(()=>r()?"opened":"");Ut(t,{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)=>{Am(T,{})},$$slots:{default:!0}}),H(),o()}var v2=t=>{t.stopPropagation()},g2=L("<div><!> <div></div> <div></div></div>"),h2={hash:"s-24",code:'.interactive-episode-icon-animated.s-24{height:32px;opacity:1;position:absolute;right:16px;top:16px;transition:.3s;width:32px}.interactive-episode-icon-animated.icon-small.s-24{height:28px;width:28px}.invisible.s-24{opacity:0;visibility:hidden}.fullscreen.s-24:not(.mobile){height:40px;right:23px;top:19px;width:40px}.mobile.s-24{height:28px;right:14px;top:12px;width:28px}.fullscreen.mobile.s-24{height:32px;width:32px}@media screen and (orientation:portrait){.interactive-episode-icon-animated.mobile.fullscreen.s-24{right:16px;top:40px}}@keyframes s-24-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-24{animation:s-24-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-24{animation-play-state:paused}.interactive-episode-icon-animated svg{height:100%;width:100%}.ref-block.s-24{height:100%;position:absolute;top:0;visibility:hidden;width:100%}.hidden.s-24{display:none}'};function nc(t,e){var K;B(e,!0),Q(t,h2);let[i,o]=Oe(),r=()=>w(x,"$isMobile",i),a=()=>w(A,"$areControlsVisible",i),l=()=>w(E,"$currentGridType$",i),d=()=>w(T,"$isInteractiveTime$",i),s=()=>w(_,"$interactiveControlsOpacity$",i),u=()=>w(R,"$showInteractiveTimeIndicatorTooltip$",i),m=()=>w(I,"$isFullscreen",i),p=h(e,"ref",15,void 0),v=q(void 0),b=be(),y=_o(),{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(()=>Us(l(),"s")),U=f(()=>!d()||!!s()||n(z)),X=q(!1);De(()=>{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));De(()=>{u()?Z():re()});let me=()=>{n(U)||(R.set(!0),P==null||P())};cn(()=>{R.clearTimeout(),re()});let ee=()=>{R.set(!1)},_e=Y("tooltip_interactive_interaction_time_indicator");var Ce=g2();let ge;Ce.__mousemove=[v2],Ce.__click=me;var pe=C(Ce);Ro(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)=>{jd(se,{completed:!0})},$$slots:{default:!0}});var Qe=k(pe,2);let G;Ze(Qe,se=>p(se),()=>p());var O=k(Qe,2);let Ge;Ze(O,se=>N(v,se),()=>n(v)),S(Ce),D((se,xe,He)=>{ge=oe(Ce,1,"interactive-episode-icon-animated s-24",null,ge,se),G=oe(Qe,1,"ref-block s-24",null,G,xe),Ge=oe(O,1,"pulse s-24",null,Ge,He)},[()=>({mobile:r(),fullscreen:m(),invisible:n(U),"icon-small":n(F)}),()=>({hidden:n(U)}),()=>({paused:n(X)})]),ut("mouseleave",Ce,ee),$(t,Ce),H(),o()}Ye(["mousemove","click"]);function tp(t,e){B(e,!0);let i=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);Ro(t,{get disabled(){return o()},get tooltipContent(){return e.tooltipText},get disabledTooltipContent(){return e.disabledTooltipContent},get hasTooltip(){return i()},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=Ve();let m=f(()=>e.buttonComponent);var p=ue(u);Bi(p,()=>n(m),(v,b)=>{b(v,os(()=>{var y;return(y=e.buttonComponentProps)!=null?y:{}}))}),$(d,u)},$$slots:{default:!0}}),H()}var Ks={prevButton:100,replayButton:200,playButton:300,nextButton:400,playPrevChapterButton:500,seekToInteractiveButton:600,interactiveGraphButton:700,liveButton:800};var b2=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 ga(t,e){B(e,!0);let i=h(e,"reversed",3,!1),o=f(()=>i()?"transform: scaleX(-1);transform-origin: 50%;":void 0),r=f(()=>`${un(e.size)}${n(o)}`),a=f(()=>i()?"prev-icon":"next-icon");Je(t,{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=b2();$(l,s)},$$slots:{default:!0}}),H()}var $2=L('<div class="icon-background-mobile s-22"><!></div>'),y2={hash:"s-22",code:".icon-background-mobile.s-22{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 ja(t,e){B(e,!0),Q(t,y2);let i=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}`);Ut(t,{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 i()},set ref(m){i(m)},children:(m,p)=>{var v=Ve(),b=ue(v);{var y=x=>{var I=$2(),T=C(I);let R=f(()=>e.type==="prev");ga(T,{get size(){return"32"},get reversed(){return n(R)}}),S(I),$(x,I)},_=x=>{let I=f(()=>e.type==="prev");ga(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 x2=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 rc(t,e){B(e,!0);let i=f(()=>un(e.size));Je(t,{get width(){return"48"},get height(){return"48"},get style(){return n(i)},testId:"replay-icon",get shadow(){return e.shadow},children:(o,r)=>{var a=x2();$(o,a)},$$slots:{default:!0}}),H()}import{noop as w2}from"@vkontakte/videoplayer-shared/es2015";var S2=L('<div class="icon-background-mobile s-23"></div>'),C2=L("<!> <div><!></div>",1),T2={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 Yl(t,e){B(e,!0),Q(t,T2);let i=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,w2),d=Y("tooltip_restart"),s=f(()=>`${o()?"btn-m--play":""} ${a()}`);Ut(t,{get className(){return n(s)},testId:"replay-btn",get ariaLabel(){return d},get disabled(){return r()},get click(){return l()},get ariaKeyShortCut(){return hs.KeyK},get ref(){return i()},set ref(u){i(u)},children:(u,m)=>{var p=C2(),v=ue(p);{var b=T=>{var R=S2();$(T,R)};V(v,T=>{o()&&T(b)})}var y=k(v,2);let _;var x=C(y);let I=f(()=>o()?"48":"24");rc(x,{get size(){return n(I)}}),S(y),D(T=>_=oe(y,1,"s-23",null,_,T),[()=>({mobile:o()})]),$(u,p)},$$slots:{default:!0}}),H()}var I2=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 qs(t,e){B(e,!0);let i=f(()=>un(e.size));Je(t,{get width(){return"48"},get height(){return"48"},get fill(){return e.fill},get style(){return n(i)},testId:"pause-icon",get shadow(){return e.shadow},children:(o,r)=>{var a=I2();$(o,a)},$$slots:{default:!0}}),H()}import{noop as E2}from"@vkontakte/videoplayer-shared/es2015";var P2=L('<div class="icon-background-mobile s-1z"><!></div>'),k2={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:calc(100% - 32px);justify-content:space-around;left:16px;position:absolute;top:16px;width:calc(100% - 32px)}"};function jl(t,e){B(e,!0),Q(t,k2);let[i,o]=Oe(),r=()=>w(a,"$fakeIsPlaying$",i),{fakeIsPlaying$:a}=_o(),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,E2),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)?qs:Vn),A=f(()=>`${d()?"btn-m--play":""} ${m()}`),P=f(()=>n(x)?n(_):p());Ut(t,{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 hs.KeyK},get ref(){return l()},set ref(E){l(E)},children:(E,z)=>{var F=Ve();let U=f(()=>n(R));var X=ue(F);{var ae=re=>{var J=P2(),we=C(J);Bi(we,()=>n(U),(me,ee)=>{ee(me,{get size(){return"48"}})}),S(J),$(re,J)},Z=re=>{var J=Ve(),we=ue(J);Bi(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 A2=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 Mm(t){Je(t,{testId:"play-prev-chapter-icon",children:(e,i)=>{var o=A2();$(e,o)},$$slots:{default:!0}})}function sc(t,e){B(e,!0);let i=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":"");Ut(t,{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 i()},set ref(d){i(d)},children:(d,s)=>{Mm(d,{})},$$slots:{default:!0}}),H()}var L2=L('<span class="gutter s-26"><span><!></span></span>'),M2={hash:"s-26",code:".gutter.s-26{--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-26{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-26{background-color:var(--toggle-color-autoplay-on);transform:translateX(calc(var(--gutterWidth) - var(--togglerWidth) + var(--togglerGap)))}"};function ac(t,e){B(e,!0),Q(t,M2);let[i,o]=Oe(),r=()=>w(s,"$autoplayNextEnabled$",i),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");Ut(t,{click:m,get ariaLabel(){return p},role:"switch",get areaChecked(){return n(y)},get ref(){return a()},set ref(_){a(_)},children:(_,x)=>{var I=L2(),T=C(I);let R;var A=C(T);{var P=z=>{Vn(z,{get size(){return v},fill:b})},E=z=>{qs(z,{get size(){return v},fill:b})};V(A,z=>{r()?z(P):z(E,!1)})}S(T),S(I),D(z=>R=oe(T,1,"toggler s-26",null,R,z),[()=>({enabled:r()})]),$(_,I)},$$slots:{default:!0}}),H(),o()}var V2=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 Vm(t){Je(t,{testId:"seek-to-interactive-icon",children:(e,i)=>{var o=V2();di(),$(e,o)},$$slots:{default:!0}})}function lc(t,e){B(e,!0);let i=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":"");Ut(t,{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 i()},set ref(d){i(d)},children:(d,s)=>{Vm(d,{})},$$slots:{default:!0}}),H()}var R2=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>'),N2=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 Rm(t,e){let i=h(e,"isOpened",3,!1),o=f(()=>i()?"graph-close-icon":"graph-open-icon");Je(t,{get testId(){return n(o)},children:(r,a)=>{var l=N2(),d=k(ue(l));{var s=u=>{var m=R2();$(u,m)};V(d,u=>{i()&&u(s)})}$(r,l)},$$slots:{default:!0}})}function dc(t,e){B(e,!0);let i=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":"");Ut(t,{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 i()},set ref(m){i(m)},children:(m,p)=>{let v=f(()=>!!a());Rm(m,{get isOpened(){return n(v)}})},$$slots:{default:!0}}),H()}import{PlaybackState as ub}from"@vkontakte/videoplayer-core/es2015";function cc(t,e){B(e,!0);let[i,o]=Oe(),r=()=>w(u,"$playbackState$",i),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()===ub.PAUSED&&p()}),b=f(()=>a()?"":"btn--live btn-full-opacity"),y=f(()=>l()?"btn-live":"btn-live-offset"),_=f(()=>l()&&r()===ub.PLAYING);Ut(t,{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)=>{Dd(x,{get isActive(){return l()}})},$$slots:{default:!0}}),H(),o()}import{noop as pb}from"@vkontakte/videoplayer-shared/es2015";var O2=L('<div class="icon icon-error-stub"><div class="inner"></div></div>'),D2=L('<img class="icon" aria-hidden="true"/>');function Xa(t,e){"use strict";let i=q(!1),o=()=>{N(i,!0)};var r=Ve(),a=ue(r);{var l=s=>{var u=O2();$(s,u)},d=s=>{var u=D2();D(()=>Re(u,"src",e.icon)),ut("error",u,o),Ra(u),$(s,u)};V(a,s=>{n(i)?s(l):s(d,!1)})}$(t,r)}function Nm(t,e){B(e,!0);let i=h(e,"disabled",3,!1),o=h(e,"onClick",3,pb),r=h(e,"ref",15),a=f(()=>o()===pb),l=f(()=>n(a)||i()),d=f(()=>n(a)?"btn-full-opacity":"");Ro(t,{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});Ut(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)=>{Xa(p,{get icon(){return e.icon}})},$$slots:{default:!0}})},$$slots:{default:!0}}),H()}var fb=t=>!!t.buttonComponent;var Qs={vkLogo:100,autoplayNext:200,volume:300,subtitles:400,settings:500,context:600,fullscreen:700,chromecast:800};var ip=(t,e,i,o)=>{if(t)for(let[r,a]of Object.entries(e))a.set(Jn(t,i,r,o))};import{interpolate as Om}from"@vkontakte/videoplayer-shared/es2015";var mb=10,vb=40,Dm=.2,H2=.5,F2=65,U2=114,z2=4,gb=({onPreviewTrackOpened:t,getTimelineRef:e,isHorizontal:i})=>{let o=f(()=>i?F2:U2),r=q(!1),a=q(0),l=q(0),d=f(()=>n(o)+mb-vb-z2),s=f(()=>Om(n(a),[Dm,1],[0,-n(d)])),u=f(()=>Om(n(a),[Dm,1],[0,vb])),m=f(()=>Om(n(a),[Dm,1],[0,n(o)+mb]));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)>=H2?1:0,!0),n(a)===1&&t()},closePreviewTrack:()=>{N(a,0)}}};var W2=t=>t;function xs(t,{delay:e=0,duration:i=400,easing:o=W2}={}){let r=+getComputedStyle(t).opacity;return{delay:e,duration:i,easing:o,css:a=>`opacity: ${a*r}`}}var K2=L('<span class="root s-2b"> </span>'),q2={hash:"s-2b",code:".root.s-2b{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 Bm(t,e){Q(t,q2);var i=K2(),o=C(i,!0);S(i),D(()=>ve(o,e.time)),$(t,i)}var Q2=L('<div class="tooltip-wrapper s-i"><div><!></div></div>'),G2={hash:"s-i",code:'.tooltip-wrapper.s-i{display:block;position:relative}.tooltip.s-i{bottom:100%;opacity:0;position:absolute;transform:translateX(-50%);transition:opacity .2s;visibility:hidden}.pointer.s-i: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-i{opacity:1;visibility:visible}'};function Hm(t,e){Q(t,G2);let i=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=Q2(),b=C(v);let y;var _=C(b);ii(_,()=>{var x;return(x=e.children)!=null?x:ht}),S(b),Ze(b,x=>N(u,x),()=>n(u)),S(v),Ze(v,x=>N(s,x),()=>n(s)),D(x=>{qe(v,`transform: translate(${n(p)}px, ${a()}px);`),y=oe(b,1,"tooltip s-i",null,y,x),qe(b,`opacity: ${i()?1:0}; visibility: ${i()?"visible":"hidden"}`)},[()=>({active:i(),pointer:o()})]),$(t,v)}var hb=t=>Math.abs(t)/90%4===1;var Y2=L('<div class="preview s-j"></div>'),j2=L('<div class="time s-j"> </div>'),X2=L('<div><!> <div class="episode s-j"><!></div> <!></div>'),Z2={hash:"s-j",code:".timeline-preview.s-j{border-radius:2px;bottom:18px;pointer-events:none}.timeline-preview.mobile.s-j{bottom:72px}.preview.s-j{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-j{margin-bottom:4px;margin-top:10px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.episode.s-j,.time.s-j{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-j{color:var(--white)}"};function Fm(t,e){B(e,!0),Q(t,Z2);let[i,o]=Oe(),r=()=>w(y,"$rotateAlpha",i),a=()=>w(_,"$playerSize",i),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(()=>qu(m(),p(),u())),F=f(()=>Wl(r())),U=f(()=>hb(r())),X=f(re),ae=f(()=>(n(U)?1:-1)*(n(x)/2-n(I)/2)),Z=f(()=>n(ae)*-1);De(()=>{(K=>{N(x,K.width,!0),N(I,K.height,!0)})(we())}),De(()=>{(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),ot=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=-ot*n(x),Ee=-He*n(I);return{imgSrc:e.previewThumbsData.links[xe],imgWidth:Ne,imgHeight:Le,imgOffsetX:et,imgOffsetY:Ee}}var ee=X2();let _e;var Ce=C(ee);{var ge=K=>{var se=Y2();D(()=>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(F)?`translate(${n(ae)}px, ${n(Z)}px)`:""};
62
- `)),$(K,se)};V(Ce,K=>{n(T)&&K(ge)})}var pe=k(Ce,2),Qe=C(pe);{var G=K=>{var se=Ve(),xe=ue(se);{var He=ne=>{var ce=gs();D(Ne=>ve(ce,Ne),[()=>Y("tooltip_episode_unfinished")]),$(ne,ce)},ot=ne=>{var ce=gs();D(()=>ve(ce,n(z).text||"")),$(ne,ce)};V(xe,ne=>{v()&&n(z).completed===!1?ne(He):ne(ot,!1)})}$(K,se)};V(Qe,K=>{n(z)&&K(G)})}S(pe);var O=k(pe,2);{var Ge=K=>{var se=j2(),xe=C(se,!0);S(se),D(()=>ve(xe,d())),$(K,se)};V(O,K=>{v()||K(Ge)})}S(ee),D(K=>{_e=oe(ee,1,"timeline-preview s-j",null,_e,K),qe(ee,`width: ${n(F)?n(I):n(x)}px;`)},[()=>({mobile:s()})]),$(t,ee),H(),o()}var J2=L('<span class="time s-f"> </span>'),ew=L("<!> <!>",1),tw={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 Um(t,e){var le,$e,Me,dt,St;B(e,!0),Q(t,tw);let[i,o]=Oe(),r=()=>w(Z,"$interactiveEpisodes$",i),a=()=>w(E,"$duration$",i),l=()=>w(P,"$position$",i),d=()=>w(we,"$isInteractiveExpectation$",i),s=()=>w(J,"$isInteractiveTime$",i),u=()=>w(Ce,"$previewTrackActive",i),m=()=>w(z,"$isLive$",i),p=()=>w(_e,"$disabledControls$",i),v=()=>w(U,"$isMobile",i),b=()=>w(F,"$isActiveLive$",i),y=()=>w(A,"$bufferedProgress$",i),_=h(e,"showTimeline",3,!1),x=h(e,"withEpisodes",3,!0),I=h(e,"ref",15,void 0),T=be(),R=Vt(),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=(Me=($e=T.callbacks)==null?void 0:$e.uiInfo)==null?void 0:Me.onTimelineMouseEnter,pe=(St=(dt=T.callbacks)==null?void 0:dt.uiInfo)==null?void 0:St.onTimelineMouseLeave,Qe=T.ui.t,G=R.features.interactiveResponsiveUi,O=f(()=>re?r():X),Ge=f(()=>jo(a())),K=f(()=>jo(l())),se=f(()=>l()/a()),xe=f(()=>d()||s()),He=q(!1),ot=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,Ue){var ze;(ze=e.onSliderPointerDown)==null||ze.call(e,Ue),T.actions.internal.startScrubbing(Te(fe))}function It(fe){s()||T.actions.internal.progressScrubbing(Te(fe))}function wt(fe){var Ue;T.actions.internal.completeScrubbing(Te(fe)),N(He,!1),(Ue=e.onSliderPointerUp)==null||Ue.call(e)}function Dt(fe,Ue,ze){var Ct;(Ct=e.onSliderPointerEnter)==null||Ct.call(e,fe),Zt(fe,Ue,ze),N(He,!0)}function at(fe,Ue,ze,Ct){var si;(si=e.onSliderMove)==null||si.call(e,Ct,fe),Zt(fe,Ue,ze),N(He,!0)}function Et(){var fe;N(He,!1),(fe=e.onSliderLeave)==null||fe.call(e)}function Zt(fe,Ue,ze){N(Ne,Te(fe),!0),N(ne,Ue,!0),ze&&N(ce,ze,!0),N(ot,Pt(fe),!0)}function Pt(fe){let Ue=jo((m()?1-fe:fe)*a());return m()?`-${Ue}`:Ue}let Ot=f(()=>p().has("TIMELINE"));var zt=ew(),j=ue(zt);Hm(j,os(()=>n(Le),{get leftOffset(){return e.tooltipLeftOffset},get rightOffset(){return e.tooltipRightOffset},children:(fe,Ue)=>{var ze=Ve(),Ct=ue(ze);{var si=Yt=>{Fm(Yt,{get time(){return n(ot)},get isMobile(){return v()},get videoEpisodes(){return n(O)},get previewThumbsData(){return ae},get progress(){return n(Ne)},get duration(){return a()},get isInteractive(){return re}})},xt=Yt=>{var ci=J2(),Hi=C(ci,!0);S(ci),D(()=>ve(Hi,n(ot))),$(Yt,ci)};V(Ct,Yt=>{R.features.timelinePreview&&ae&&!m()?Yt(si):Yt(xt,!1)})}$(fe,ze)},$$slots:{default:!0}}));var Pe=k(j,2);Ga(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(O)},onPointerDown:Fe,onHandleMove:It,onPointerMove:at,onPointerUp:wt,onPointerEnter:Dt,onPointerLeave:Et,get onMouseEnter(){return ge},get onMouseLeave(){return pe},get onDisabledClick(){return ee},get isInteractive(){return re},get disabled(){return n(Ot)},get handleAlwaysVisible(){return u()},get hideHandel(){return s()},testId:"progress_bar",onContextMenu:wt,get ref(){return I()},set ref(fe){I(fe)}}),$(t,zt),H(),o()}var iw={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 uc(t,e){B(e,!0),Q(t,iw);let[i,o]=Oe(),r=()=>w(s,"$isMobile",i),a=h(e,"position",3,0),l=h(e,"duration",3,0),d=be(),s=d.ui.isMobile,u=d.ui.t,m=f(()=>jo(l())),p=f(()=>jo(a())),v=f(()=>a()/l()),b=f(()=>u("aria_timeline_value",{position:n(p),duration:n(m)})),y=f(()=>Math.round(n(v)*100));Ga(t,{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 ow=L("<div><!></div>"),nw=L("<div></div>"),rw={hash:"s-c",code:".timeline.s-c{align-items:center;bottom:0;box-sizing:border-box;display:flex;min-width:86px;pointer-events:all;position:relative;width:100%}.timeline.mobile.s-c{height:16px;margin-top:6px;padding:6px 12px 7px}.withoutPadding.s-c{padding:0}.timeline-stub.s-c{min-width:20px;width:100%}.timeline-stub.mobile.s-c{height:8px}"};function Za(t,e){B(e,!0),Q(t,rw);let[i,o]=Oe(),r=()=>w(x,"$isLive$",i),a=()=>w(R,"$isMobile",i),l=()=>w(A,"$disabled",i),d=()=>w(T,"$adPosition",i),s=()=>w(I,"$adDuration",i),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(),_=Vt(),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=Ve(),z=ue(E);{var F=X=>{var ae=ow();let Z;var re=C(ae);{var J=me=>{uc(me,{get position(){return d()},get duration(){return s()}})},we=me=>{Um(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),Bs(ae,()=>Nl(m()&&_.features.usePerformanceFix,A,_.disableInvisibleComponentsTimeout)),D(me=>Z=oe(ae,1,"timeline s-c",null,Z,me),[()=>({withoutPadding:!v(),mobile:a(),"out-of-flow":l()})]),$(X,ae)},U=X=>{var ae=nw();let Z;D(re=>Z=oe(ae,1,"timeline-stub s-c",null,Z,re),[()=>({mobile:a()})]),$(X,ae)};V(z,X=>{n(P)?X(F):X(U,!1)})}$(t,E),H(),o()}import{getRangeAroundIndex as sw}from"@vkontakte/videoplayer-shared/es2015";var aw=(t,e,i,o,r,a,l)=>{N(e,!0),N(i,t.clientX,!0),N(o,n(r),!0),a(l())},lw=L("<div></div>"),dw=L('<div><div class="track s-2c"></div></div>'),cw={hash:"s-2c",code:'.root.s-2c{display:flex;height:var(--preview-track-frame-height-horizontal);overflow:hidden;position:relative;width:100%}.root.is-vertical-video.s-2c,.root.vertically-rotated.s-2c{height:var(--preview-track-frame-height-vertical)}.root.s-2c: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-2c{bottom:0;display:flex;left:0;padding:0 50%;top:0}.frame.s-2c,.track.s-2c{position:absolute}.frame.s-2c{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-2c .frame:where(.s-2c){transform-origin:0 0}.rotate-1.s-2c{transform:rotate(-90deg) translateX(-100%)}.rotate-2.s-2c{transform:rotate(-180deg)}.rotate-3.s-2c{transform:rotate(-270deg) translateY(-100%)}'};function Wm(t,e){B(e,!0),Q(t,cw);let[i,o]=Oe(),r=()=>w(R,"$rotateAlpha",i),a=()=>w(_,"$position$",i),l=()=>w(y,"$duration$",i),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(()=>Wl(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);De(()=>{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,O=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,It=Te*u;for(let wt=1;wt<=u;wt++)Ee*s+Fe+It<m&&Fe++;return Fe},He=f(()=>Math.floor(n(U)/s)),ot=f(()=>sw(3,n(He),p.length-1)),ne=(Ee,Te,Fe)=>{let It=s*n(me);return Ee*It+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=dw();let Le;var et=C(Ne);et.__pointerdown=[aw,P,E,z,F,x,Qe],et.__pointermove=O,et.__pointerup=Ge,bi(et,20,()=>n(ot),Ee=>Ee,(Ee,Te)=>{var Fe=Ve(),It=ue(Fe);bi(It,16,()=>Array.from({length:n(se)},(wt,Dt)=>Dt),wt=>wt,(wt,Dt)=>{var at=Ve(),Et=ue(at);bi(Et,16,()=>Array.from({length:xe(Te,Dt)},(Zt,Pt)=>Pt),Zt=>Zt,(Zt,Pt)=>{var Ot=lw();D((zt,j)=>{qe(Ot,zt),oe(Ot,1,j,"s-2c")},[()=>`--row-index: ${Dt}; --column-index: ${Pt}; left: ${ne(Te,Dt,Pt)}px; background-image: url(${p[Te]});`,()=>`frame rotate-${Math.abs(r())/90%4}`]),$(Zt,Ot)}),$(wt,at)}),$(Ee,Fe)}),S(et),S(Ne),Ze(Ne,Ee=>N(A,Ee),()=>n(A)),D(Ee=>{Le=oe(Ne,1,"root s-2c",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),Ln(Ne,"clientWidth",Ee=>N(ge,Ee)),$(t,Ne),H(),o()}Ye(["pointerdown","pointermove","pointerup"]);var uw=L('<div class="notification s-2d"><span class="description s-2d"> </span></div>'),pw={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 Km(t,e){B(e,!1),Q(t,pw);let i=340,{ui:{t:o}}=be();ho();var r=uw(),a=C(r),l=C(a,!0);S(a),S(r),D(d=>ve(l,d),[()=>o("preview_track_close_tooltip")],In),is(3,r,()=>xs,()=>({duration:i})),$(t,r),H()}import{getRangeAroundIndex as fw}from"@vkontakte/videoplayer-shared/es2015";var mw=L('<div class="preview-track-close tooltip s-28"><!></div>'),vw=L('<div class="preview-track-control s-28"><!> <div class="preview-track-close s-28"><!></div> <!></div>'),gw=L('<div class="wrapper-preview-track s-28"><!></div>'),hw=L('<div class="enriched-timeline s-28"><!> <!> <!></div>'),_w={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 qm(t,e){B(e,!0),Q(t,_w);let[i,o]=Oe(),r=()=>w(_,"$playerSize",i),a=()=>w(y,"$duration$",i),l=()=>w(x,"$previewTrackActive",i),d=()=>w(v,"$position$",i),s=()=>w(b,"$isRewindableLive$",i),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(!x_()),E=()=>{n(P)&&(y_(),N(P,!1))},z=me=>{let ee=Math.floor(a()*me/R),_e=Math.floor(ee/I),Ce=fw(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=hw(),X=C(U);{var ae=me=>{var ee=vw(),_e=C(ee);let Ce=f(()=>jo(d()));Bm(_e,{get time(){return n(Ce)}});var ge=k(_e,2),pe=C(ge);Fs(pe,{onClick:()=>m.actions.internal.closePreviewTrack()}),S(ge);var Qe=k(ge,2);{var G=O=>{var Ge=mw(),K=C(Ge);Km(K,{}),S(Ge),$(O,Ge)};V(Qe,O=>{n(P)&&O(G)})}S(ee),ut("mouseleave",ge,E),is(3,ee,()=>xs,()=>({duration:p})),$(me,ee)};V(X,me=>{l()&&me(ae)})}var Z=k(X,2);let re=f(()=>!n(A));Za(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=gw(),_e=C(ee);Wm(_e,{}),S(ee),D(()=>qe(ee,`height: ${e.animatedPreviewTrackHeight}px;`)),$(me,ee)};V(J,me=>{e.previewTrackAvailable&&me(we)})}S(U),D(()=>qe(U,`transform: translateY(${e.animatedOffsetY}px);`)),$(t,U),H(),o()}var $w=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),yw={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 Gm(t,e){var dl,ya;B(e,!0),Q(t,yw);let[i,o]=Oe(),r=()=>w(Xo,"$disabledControls$",i),a=()=>w(Ke,"$adPlaybackState",i),l=()=>w(xt,"$playbackState$",i),d=()=>w(_i,"$currentSubtitle$",i),s=()=>w(Hi,"$isEnded$",i),u=()=>w(Zo,"$currentGridType$",i),m=()=>w(Rt,"$isLive$",i),p=()=>w(st,"$chromecastState$",i),v=()=>w(nt,"$isPictureInPictureActive",i),b=()=>w(jt,"$pictureInPictureType$",i),y=()=>w(lt,"$availableSubtitlesList$",i),_=()=>w(Bt,"$contextMenuOpenedByKeyboard$",i),x=()=>w(_t,"$showContextMenuBtn$",i),I=()=>w(fi,"$isRewindableLive$",i),T=()=>w(vo,"$isActiveLive$",i),R=()=>w($r,"$graphIsOpened$",i),A=()=>w(No,"$contextMenuVisible$",i),P=()=>w(Ui,"$isFullscreen",i),E=()=>w(ro,"$autoplayNextEnabled",i),z=()=>w(n(wo),"$prevButton",i),F=()=>w(n(So),"$replayButton",i),U=()=>w(n(hn),"$playButton",i),X=()=>w(n(ao),"$nextButton",i),ae=()=>w(n(_n),"$playPrevChapterButton",i),Z=()=>w(n(Zi),"$seekToInteractiveButton",i),re=()=>w(n(bn),"$interactiveGraphButton",i),J=()=>w(n(Co),"$liveButton",i),we=()=>w(n(Cs),"$time",i),me=()=>w(n(Kr),"$episodes",i),ee=()=>w(n(Ts),"$vkLogo",i),_e=()=>w(n(zi),"$volume",i),Ce=()=>w(n(qr),"$subtitles",i),ge=()=>w(n(Ho),"$settings",i),pe=()=>w(n(Er),"$context",i),Qe=()=>w(n($n),"$fullscreen",i),G=()=>w(n(Qr),"$chromecast",i),O=()=>w(tr,"$additionalDesktopControlPanelRightButtons$",i),Ge=()=>w(Xi,"$playerSize",i),K=()=>w(yo,"$isInteractiveTime$",i),se=()=>w(pi,"$previewTrackActive",i),xe=()=>w(Fi,"$settingsMenuVisible",i),He=()=>w(lo,"$settingButtonRef$",i),ot=()=>w(W,"$startedByKeyboard$",i),ne=()=>w(Yt,"$isAudioAvailable$",i),ce=()=>w(zt,"$fakeIsPlaying$",i),Ne=()=>w(ws,"$seekToInteractiveDisabledTooltip$",i),Le=()=>w(wn,"$isPreviewTrackHorizontallyAligned$",i),et=()=>w(co,"$previewTrackAvailable",i),Ee=()=>w(Eo,"$previewTrackDragInProgress",i),Te=()=>w(qt,"$adPosition",i),Fe=()=>w(si,"$position$",i),It=()=>w(ti,"$adDuration",i),wt=()=>w(Ct,"$duration$",i),Dt=h(e,"playerControlsWrapperRef",15,void 0),at=h(e,"playerControlsRef",15,void 0),Et=h(e,"isAds",3,!1),Zt=h(e,"logoTargetUrl",3,""),Pt=h(e,"isOneVideoPlaylist",3,!1),Ot=h(e,"customFullscreenSupported",3,!0),{fakeIsPlaying$:zt}=_o(),j=be(),Pe=_o(),le=Vt(),$e=j.actions.internal.toggleMuted,Me=j.actions.internal.togglePlay,dt=j.actions.internal.pause,St=j.actions.internal.toggleSubtitle,fe=j.actions.internal.checkFullscreenSupport,Ue=(dl=j.callbacks)==null?void 0:dl.onAudioDoesNotExistHint,ze=(ya=j.callbacks)==null?void 0:ya.onAudioDisabledHint,Ct=j.state.duration$,si=j.state.positionWithScrubbing$,xt=j.state.playbackState$,Yt=j.state.isAudioAvailable$,ci=j.state.isAudioDisabled,Hi=j.state.isEnded$,Rt=j.state.isLive$,vo=j.state.isActiveLive$,fi=j.state.isRewindableLive$,{isActive$:nt,type$:jt}=Pe.pictureInPicture$,Fi=j.ui.settingsMenu.visible$,$i=j.ui.settingsMenu.openedByBtnKeyboard$,Jt=j.ui.controls,wi=j.actions.internal.getVideoEpisodes(),st=j.state.chromecastState$,lt=j.state.availableSubtitlesList$,_i=j.state.currentSubtitle$,Xo=Jt.disabledControls$,No=j.ui.contextMenu.visible$,_t=j.ui.contextMenu.showContextMenuBtn$,Bt=j.ui.contextMenu.openedByBtnKeyboard$,W=j.ui.startedByKeyboard$,Lt=j.ui.controlBlocks,ai=j.ui.previewTrackNotificationVisible,vt=j.ui.t,ti=j.ads.duration,qt=j.ads.position,Ke=j.ads.playbackState,Ui=j.ui.isFullscreen,Xi=j.ui.playerSize,Zo=j.ui.currentGridType$,tr=j.ui.additionalDesktopControlPanelRightButtons$,ro=j.ui.autoplayNextEnabled$,Ei=j.actions.internal.getVideoElement,bo=j.actions.internal.replayInteractive,Oo=j.actions.internal.prevVideoClick,$o=j.actions.internal.nextVideoClick,Pi=j.state.isInteractive,yo=j.state.isInteractiveTime$,xo=j.state.showInteractiveGraph,Jo=j.state.showSeekToInteractive,Br=j.state.showPlayPrevChapter,Hr=j.state.showInteractiveTimeIndicator,ss=j.state.playPrevChapterDisabledTooltip,ws=Pe.seekToInteractiveDisabledTooltip$,$r=Pe.graphIsOpened$,ir=le.features.interactiveResponsiveUi,Fr=f(()=>r().has("EPISODE_BUTTON")),mn=f(()=>r().has("GRAPH_BUTTON")),vn=f(()=>r().has("SEEK_TO_INTERACTIVE_BUTTON")),yr=f(()=>r().has("PLAY_BUTTON")),xr=f(()=>r().has("REPLAY_BUTTON")),en=f(()=>r().has("PLAY_PREV_CHAPTER_BUTTON")),wr=()=>j.actions.internal.toggleChromecast(),Sr=f(()=>Et()?a()==="playing":l()===Qm.PLAYING),Cr=f(()=>d().value!=="off"),Nn=f(()=>s()&&!Et()||Pi),Ur=f(()=>ir?n(Nn)&&oo(u(),"m"):n(Nn)),Ss=f(()=>!s()||Pi||Et()),zr=f(()=>oo(u(),"m")),Si=f(()=>e.showNextPrevButtons&&oo(u(),"m")&&!Et()&&e.nextButtonActive),as=f(()=>e.showNextPrevButtons&&oo(u(),"m")&&!Et()&&e.prevButtonActive),tn=f(()=>!Et()&&!!m()),pt=f(()=>p()!==_b.NOT_AVAILABLE&&!(v()&&b()===1)&&oo(u(),"m")&&!Pi),ei=f(()=>e.showAutoplayNext&&!Pt()&&oo(u(),"s")),On=f(()=>y().length>0&&oo(u(),"m")),or=f(()=>_()||x()),Wr=f(()=>oo(u(),"s")&&!Et()),nr=f(()=>!e.logoHidden&&!Et()),rr=f(()=>le.features.fullscreen&&fe()&&(e.logoHidden||oo(u(),ir?"xs":"s"))&&!(v()&&b()===1)&&(Pi?Ot():!0)),Do=f(()=>(!m()||Et())&&!(le.features.interactiveHideTime&&Pi)),Tr=f(()=>xo&&oo(u(),"m")),Dn=f(()=>ir?Jo&&oo(u(),"s"):Jo),sr=f(()=>ir?Br&&oo(u(),"s"):Br),ar=f(()=>!Et()&&!m()&&!!(wi!=null&&wi.length)&&n(zr)&&!n(Fr)),on=f(()=>!I()||!!T()),gn=f(()=>R()?vt("tooltip_interactive_graph_on"):vt("tooltip_interactive_graph_off")),Bn=f(()=>A()?vt("tooltip_context_menu_close"):vt("tooltip_context_menu_open")),Mi=(mt,rt)=>mt?rt&&rt===Qm.PAUSED?vt("tooltip_play"):"":vt("tooltip_live"),Vi=f(()=>Mi(n(on),l())),Bo=f(()=>le.logoType==="vk_video"?vt("tooltip_vk_video_logo"):vt("tooltip_vk_logo")),Hn=f(()=>n(Cr)?vt("tooltip_subtitles_on"):vt("tooltip_subtitles_off")),lr=f(()=>P()?vt("tooltip_fullscreen_on"):vt("tooltip_fullscreen_off")),Fn=f(()=>p()===_b.CONNECTED?vt("tooltip_chromecast_on"):vt("tooltip_chromecast_off")),Ir=f(()=>E()?vt("tooltip_autoplay_on"):vt("tooltip_autoplay_off")),ct=q(0),kt=li({}),so=li({}),wo=f(()=>Jt.prevButton),So=f(()=>Jt.replayButton),hn=f(()=>Jt.playButton),ao=f(()=>Jt.nextButton),_n=f(()=>Jt.playPrevChapterButton),Zi=f(()=>Jt.seekToInteractiveButton),bn=f(()=>Jt.interactiveGraphButton),Co=f(()=>Jt.liveButton),Cs=f(()=>Jt.time),Kr=f(()=>Jt.episodes),Ts=f(()=>Jt.vkLogo),zi=f(()=>Jt.volume),qr=f(()=>Jt.subtitles),Ho=f(()=>Jt.settings),Er=f(()=>Jt.context),$n=f(()=>Jt.fullscreen),Qr=f(()=>Jt.chromecast),We=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:O().length?O().reduce(mt=>[...mt,40],[]):[]})),yt=q(0);De(()=>{(!n(yt)||n(yt)<n(We).time)&&Tt(()=>N(yt,n(We).time,!0))});let ui=q(!1);De(()=>{let mt=0;n(ar)&&(oo(u(),"xl")?mt=n(We).time:mt=60);let rt=n(We).prevButton+n(We).playButton+n(We).nextButton+n(We).seekToInteractiveButton+n(We).interactiveGraphButton+n(We).liveButton+n(yt)+mt;N(ui,n(Do)&&n(ct)>=rt,!0)});let go=f(()=>n(ui)&&oo(u(),"m")),ki=bb(Gl,260),Fo=bb(ip,260);De(()=>{Ge(),K(),se(),ki(Ei(),Jt,kt,e.showControls),Fo(Ei(),Lt,so,e.showControls)}),De(()=>{so.bottom=Dt()});let lo=de();De(()=>{xe(),He()&&Tt(()=>Dl(He(),xe(),$i))});let Uo;De(()=>{ot(),Tt(()=>ep(W,ot(),Uo))});function nn(){fa({isAudioDisabled:ci,isAudioAvailable:ne(),isAds:Et(),audioIsNotExistHintCallback:Ue,audioDisabledHintCallback:ze})&&$e()}let dr=Pi?bo:Me,To=f(()=>ce()!==null),rn=f(()=>n(To)?ce():n(Sr)),Un=f(()=>n(rn)?vt("tooltip_pause"):vt("tooltip_play")),Io=vt("tooltip_episodes"),yn=f(()=>{var mt,rt,Ji,ko;return n(as)?{id:"prevButton",type:"desktop-control-panel-left",weight:Ks.prevButton,buttonComponent:ja,buttonComponentProps:{disabled:!e.prevButtonActive,type:"prev",click:Oo.bind(null,!0)},tooltipEnabled:!((rt=(mt=j.callbacks)==null?void 0:mt.uiInfo)!=null&&rt.onPrevButtonMouseEnter)&&!((ko=(Ji=j.callbacks)==null?void 0:Ji.uiInfo)!=null&&ko.onPrevButtonMouseLeave),mouseEnter:()=>{var eo,gi,Ki;(Ki=(gi=(eo=j.callbacks)==null?void 0:eo.uiInfo)==null?void 0:gi.onPrevButtonMouseEnter)==null||Ki.call(gi,Jn(Ei(),kt,"prevButton",e.showControls))},mouseLeave:()=>{var eo,gi,Ki;(Ki=(gi=(eo=j.callbacks)==null?void 0:eo.uiInfo)==null?void 0:gi.onPrevButtonMouseLeave)==null||Ki.call(gi,Jn(Ei(),kt,"prevButton",e.showControls))},tooltipText:vt("tooltip_previous"),disabled:!e.prevButtonActive}:void 0}),zn=f(()=>n(Ur)?{id:"replayButton",type:"desktop-control-panel-left",weight:Ks.replayButton,buttonComponent:Yl,buttonComponentProps:{disabled:n(xr),click:dr},tooltipText:vt("tooltip_restart"),disabled:n(xr)}:void 0),ls=f(()=>n(Ss)?{id:"playButton",type:"desktop-control-panel-left",weight:Ks.playButton,buttonComponent:jl,buttonComponentProps:{disabled:n(yr),isPlaying:n(Sr),click:Me},tooltipText:n(Un),disabled:n(yr)}:void 0),cr=f(()=>{var mt,rt,Ji,ko;return n(Si)?{id:"nextButton",type:"desktop-control-panel-left",weight:Ks.nextButton,buttonComponent:ja,buttonComponentProps:{disabled:!e.nextButtonActive,type:"next",click:$o.bind(null,!0)},tooltipEnabled:!((rt=(mt=j.callbacks)==null?void 0:mt.uiInfo)!=null&&rt.onNextButtonMouseEnter)&&!((ko=(Ji=j.callbacks)==null?void 0:Ji.uiInfo)!=null&&ko.onNextButtonMouseLeave),mouseEnter:()=>{var eo,gi,Ki;(Ki=(gi=(eo=j.callbacks)==null?void 0:eo.uiInfo)==null?void 0:gi.onNextButtonMouseEnter)==null||Ki.call(gi,Jn(Ei(),kt,"nextButton",e.showControls))},mouseLeave:()=>{var eo,gi,Ki;(Ki=(gi=(eo=j.callbacks)==null?void 0:eo.uiInfo)==null?void 0:gi.onNextButtonMouseLeave)==null||Ki.call(gi,Jn(Ei(),kt,"nextButton",e.showControls))},tooltipText:vt("tooltip_next"),disabled:!e.nextButtonActive}:void 0}),je=f(()=>Pi&&n(sr)?{id:"playPrevChapterButton",type:"desktop-control-panel-left",weight:Ks.playPrevChapterButton,buttonComponent:sc,buttonComponentProps:{disabled:n(en),click:e.playPrevChapter},tooltipText:vt("tooltip_interactive_go_back"),disabledTooltipContent:vt(ss),disabled:n(en)}:void 0),Xt=f(()=>Pi&&n(Dn)?{id:"seekToInteractiveButton",type:"desktop-control-panel-left",weight:Ks.seekToInteractiveButton,buttonComponent:lc,buttonComponentProps:{disabled:n(vn),click:e.seekToInteractive},tooltipText:vt("tooltip_interactive_seek"),disabled:n(vn),disabledTooltipContent:vt(Ne())}:void 0),yi=f(()=>Pi&&n(Tr)?{id:"interactiveGraphButton",type:"desktop-control-panel-left",weight:Ks.interactiveGraphButton,buttonComponent:dc,buttonComponentProps:{disabled:n(mn),click:$r.toggle,graphIsOpened:R()},tooltipText:n(gn)}:void 0),zo=f(()=>n(tn)?{id:"liveButton",type:"desktop-control-panel-left",weight:Ks.liveButton,buttonComponent:cc,buttonComponentProps:{isLiveActive:n(on),ariaLabel:n(Vi)},tooltipText:n(Vi),disabled:n(on)&&l()===Qm.PLAYING}:void 0),xn=f(()=>[n(yn),n(zn),n(ls),n(cr),n(je),n(Xt),n(yi),n(zo)].filter(mt=>!!mt).sort(Wa)),Pr=f(()=>n(nr)?{id:"vkLogo",type:"desktop-control-panel-right",weight:Qs.vkLogo,buttonComponent:Zd,buttonComponentProps:{targetUrl:Zt(),logoClickable:e.logoClickable,click:dt},tooltipText:n(Bo),disabledTooltipContent:"",disabled:!e.logoClickable}:void 0),sn=f(()=>n(ei)?{id:"autoplayNext",type:"desktop-control-panel-right",weight:Qs.autoplayNext,buttonComponent:ac,tooltipText:n(Ir)}:void 0),an=f(()=>({id:"volume",type:"desktop-control-panel-right",weight:Qs.volume,buttonComponent:bm,buttonComponentProps:{click:nn,isAds:Et()}})),Is=f(()=>n(On)?{id:"subtitles",type:"desktop-control-panel-right",weight:Qs.subtitles,buttonComponent:mm,buttonComponentProps:{isSubtitlesEnabled:n(Cr),click:St},tooltipText:n(Hn)}:void 0),kr=f(()=>n(Wr)?{id:"settings",type:"desktop-control-panel-right",weight:Qs.settings,buttonComponent:Ul,buttonComponentProps:{ref$:lo},tooltipText:xe()?void 0:vt("tooltip_settings_off")}:void 0),Es=f(()=>le.features.contextMenuButton?{id:"context",type:"desktop-control-panel-right",weight:Qs.context,buttonComponent:Lm,buttonComponentProps:{ariaLabel:vt("aria_label_context_menu")},className:n(or)?"":"out-of-view",tooltipText:n(Bn)}:void 0),Ys=f(()=>n(rr)?{id:"fullscreen",type:"desktop-control-panel-right",weight:Qs.fullscreen,buttonComponent:Xd,buttonComponentProps:{isFullscreen:P(),click:e.toggleFullscreen},tooltipText:n(lr)}:void 0),Ps=f(()=>n(pt)?{id:"chromecast",type:"desktop-control-panel-right",weight:Qs.chromecast,buttonComponent:ec,buttonComponentProps:{state:p(),click:wr},tooltipText:n(Fn)}:void 0),ft=f(()=>[n(Pr),n(sn),n(an),n(Is),n(kr),n(Es),n(Ys),n(Ps),...O()].filter(mt=>!!mt).sort(Wa)),pi=j.ui.previewTrackActive,Eo=j.ui.previewTrackDragInProgress,co=j.ui.previewTrackAvailable,wn=j.ui.isPreviewTrackHorizontallyAligned,Ri=f(()=>gb({onPreviewTrackOpened:j.actions.internal.previewTrackOpened,getTimelineRef:()=>kt.timeline,isHorizontal:Le()})),ds=f(()=>n(Ri).progressBarY),ks=f(()=>n(Ri).controlsY),Wi=f(()=>n(Ri).onPointerDown),Ii=f(()=>n(Ri).onPointerMove),Wn=f(()=>n(Ri).onPointerUp),Ar=f(()=>n(Ri).calculatedHeight),he=f(()=>n(Ri).closePreviewTrack);De(()=>{se()?ai.set(!1):n(he)()});let it;Mt(()=>()=>it&&clearTimeout(it));let vi=mt=>{se()||!et()||(n(Wi)(mt),it=setTimeout(()=>{j.actions.internal.previewTrackDragStarted()},200))},Ai=()=>{se()||n(Wn)(),it&&clearTimeout(it),Ee()&&j.actions.internal.previewTrackDragFinished()},Sn=mt=>{n(Ii)(mt),!se()&&et()&&!se()&&ai.set(!0)},Po=()=>{ai.set(!1)};var Ni=$w(),Kn=ue(Ni);let As;var Gr=C(Kn);{var ha=mt=>{let rt=f(()=>n(ds)()),Ji=f(()=>n(Ar)());qm(mt,{get animatedOffsetY(){return n(rt)},get animatedPreviewTrackHeight(){return n(Ji)},get canRewindLive(){return e.canRewindLive},get isAds(){return Et()},onTimelineMove:Sn,onTimelinePointerDown:vi,onTimelinePointerUp:Ai,onTimelinePointerLeave:Po,get previewTrackAvailable(){return et()},get timelineRef(){return kt.timeline},set timelineRef(ko){kt.timeline=ko}})};V(Gr,mt=>{e.showControls&&mt(ha)})}var cs=k(Gr,2),Cn=C(cs),_a=C(Cn);bi(_a,17,()=>n(xn),mt=>mt.id,(mt,rt)=>{tp(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 kt[n(rt).id]},set ref(Ji){kt[n(rt).id]=Ji}})});var ba=k(_a,2);{var Yr=mt=>{let rt=f(()=>!e.showControls),Ji=f(()=>Et()?Te():Fe()),ko=f(()=>Et()?It():wt());Yd(mt,{get isHidden(){return n(rt)},isMobile:!1,get showDuration(){return n(go)},get position(){return n(Ji)},get duration(){return n(ko)},get ref(){return kt.time},set ref(eo){kt.time=eo}})};V(ba,mt=>{n(Do)&&mt(Yr)})}var al=k(ba,2);let ed=f(()=>!n(ar));Ro(al,{className:"w-max",get disabled(){return n(ed)},get tooltipContent(){return Io},get tooltipVisible(){return e.showControls},get ref(){return kt.episodes},set ref(mt){kt.episodes=mt},children:(mt,rt)=>{var Ji=Ve(),ko=ue(Ji);{var eo=gi=>{tc(gi,{get position(){return Fe()},get duration(){return wt()},get timeCodes(){return wi}})};V(ko,gi=>{n(ar)&&gi(eo)})}$(mt,Ji)},$$slots:{default:!0}}),S(Cn);var $a=k(Cn,2);bi($a,21,()=>n(ft),mt=>mt.id,(mt,rt)=>{var Ji=Ve(),ko=ue(Ji);{var eo=Ki=>{tp(Ki,{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 kt[n(rt).id]},set ref(js){kt[n(rt).id]=js}})},gi=Ki=>{let js=f(()=>!!n(rt).disabled);Nm(Ki,{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(js)},get onClick(){return n(rt).onClick},get disableMouseupTooltipShow(){return n(rt).disableMouseupTooltipShow},get tooltipVisible(){return e.showControls},get ref(){return kt[n(rt).id]},set ref(id){kt[n(rt).id]=id}})};V(ko,Ki=>{fb(n(rt))?Ki(eo):Ki(gi,!1)})}$(mt,Ji)}),S($a),S(cs),Ze(cs,mt=>at(mt),()=>at()),S(Kn),Ze(Kn,mt=>Dt(mt),()=>Dt());var td=k(Kn,2);{var ll=mt=>{nc(mt,{get ref(){return kt.interactiveTimeIndicator},set ref(rt){kt.interactiveTimeIndicator=rt}})};V(td,mt=>{Hr&&mt(ll)})}D((mt,rt)=>{As=oe(Kn,1,"wrapper-bottom s-1b",null,As,mt),qe(Kn,`transform: ${e.showControls?"translateY(0)":"translateY(100%)"}`),qe(cs,rt),cs.inert=se()},[()=>({hidden:e.bottomHidden,"controls-hidden":!e.showControls,"no-smooth":e.bottomNoSmooth||Ee()}),()=>`transform: translateY(${n(ks)()}px);`]),Ln(Cn,"clientWidth",mt=>N(ct,mt)),$(t,Ni),H(),o()}import{ChromecastState as yb,PlaybackState as xb}from"@vkontakte/videoplayer-core/es2015";import{noop as $b}from"@vkontakte/videoplayer-shared/es2015";var xw=L('<div class="icon icon-error-stub s-20"><div class="inner s-20"></div></div>'),ww=L('<img class="icon s-20" aria-hidden="true"/>'),Sw={hash:"s-20",code:".icon.s-20{height:24px!important;width:24px!important}.inner.s-20{background-color:var(--white);height:16px;width:16px}"};function Ym(t,e){Q(t,Sw);let i=h(e,"disabled",3,!1),o=h(e,"onClick",3,$b),r=f(()=>o()===$b),a=f(()=>n(r)||i()),l=q(!1),d=()=>{N(l,!0)},s=f(()=>n(r)?"btn-full-opacity":"");Ut(t,{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=Ve(),v=ue(p);{var b=_=>{var x=xw();$(_,x)},y=_=>{var x=ww();D(()=>Re(x,"src",e.iconUrl)),ut("error",x,d),Ra(x),$(_,x)};V(v,_=>{n(l)?_(b):_(y,!1)})}$(u,p)},$$slots:{default:!0}})}var Cw=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 jm(t){Je(t,{testId:"muted-icon",children:(e,i)=>{var o=Cw();$(e,o)},$$slots:{default:!0}})}import{noop as Tw}from"@vkontakte/videoplayer-shared/es2015";function op(t,e){B(e,!0);let i=h(e,"muted",3,!1),o=h(e,"click",3,Tw),r=h(e,"ref",15,void 0),l=be().ui.t,d=f(()=>i()?l("tooltip_volume"):l("tooltip_volume_muted")),s=f(()=>i()?"btn-mobile-muted":"btn-mobile-unmuted");Ut(t,{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=Ve(),v=ue(p);{var b=_=>{jm(_,{})},y=_=>{va(_,{get size(){return"24"}})};V(v,_=>{i()?_(b):_(y,!1)})}$(u,p)},$$slots:{default:!0}}),H()}var Iw=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>'),Ew=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>'),Pw=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 Xm(t,e){let i=h(e,"isActive",3,!1),o=f(()=>i()?"pip-icon--active":"pip-icon");Je(t,{get testId(){return n(o)},children:(r,a)=>{var l=Pw(),d=k(ue(l));{var s=m=>{var p=Iw();$(m,p)},u=m=>{var p=Ew();$(m,p)};V(d,m=>{i()?m(s):m(u,!1)})}$(r,l)},$$slots:{default:!0}})}import{noop as kw}from"@vkontakte/videoplayer-shared/es2015";function Zm(t,e){B(e,!0);let i=h(e,"ref",15,void 0),o=h(e,"isPictureInPictureActive",3,!1),r=h(e,"click",3,kw),a=Y("menu_pip");Ut(t,{testId:"btn-pip",get ariaLabel(){return a},get click(){return r()},get ref(){return i()},set ref(l){i(l)},children:(l,d)=>{Xm(l,{get isActive(){return o()}})},$$slots:{default:!0}}),H()}import{debounceFn as wb}from"@vkontakte/videoplayer-shared/es2015";var Aw=(t,e,i,o)=>{n(e)&&i.onDisabledPlayPrevChapterClick(n(o))},Lw=(t,e,i,o)=>{n(e)&&i.onDisabledSeekToInteractiveClick(n(o))},Mw=L("<div><!></div>"),Vw=L("<div><!></div>"),Rw=L("<div><!></div>"),Nw=L("<!> <!> <!>",1),Ow=L("<div></div> <div></div> <div><!> <!> <!> <!> <!> <!></div> <div><!> <!> <!> <!></div> <!>",1),Dw=L('<div class="wrapper-middle s-1c"><!></div>'),Bw=L("<div><!></div> <!> <div><!></div>",1),Hw=L('<div aria-hidden="true">·</div> <!>',1),Fw=L('<!> <!> <div><div><div class="controls mobile s-1c" data-testid="bottom-controls"><div class="controls-group contain s-1c"><!> <!> <!> <!></div> <div class="controls-group s-1c"><!> <!> <!></div></div> <!></div></div> <!>',1),Uw={hash:"s-1c",code:".wrapper-bottom.s-1c{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-1c>:where(.s-1c){pointer-events:auto}.wrapper-bottom.ads-timeline-mobile.s-1c{height:9px;padding:0 4px 4px}.wrapper-middle.s-1c{align-items:center;left:50%;top:50%;transform:translate(-50%,-50%)}.wrapper-middle.s-1c,.wrapper-top-right.s-1c{display:flex;position:absolute;transition:opacity var(--controls-transition-duration);z-index:var(--controls-container-z-index)}.wrapper-top-right.s-1c{right:8px;top:4px}.wrapper-top-left.s-1c{left:8px;position:absolute;top:4px;z-index:var(--controls-container-z-index)}.wrapper-middle-left.s-1c,.wrapper-middle-left-second.s-1c,.wrapper-middle-right.s-1c{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-1c{left:12px}.wrapper-middle-left-second.s-1c{left:64px}.wrapper-middle-right.s-1c{right:12px}.controls.s-1c{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-1c,.controls-group.s-1c{display:flex}.controls-group.contain.s-1c{min-width:0}.controls-group.s-1c >:not(:first-child){margin-left:8px}.hidden.s-1c{opacity:0;visibility:hidden}.controls-hidden.s-1c{transform:translateY(100%);visibility:visible}.wrapper-bottom.no-smooth.s-1c{transition:none}.overlay-mobile.s-1c{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-1c,.wrapper-top-right.fullscreen.s-1c{top:16px}.controls-wrapper.fullscreen.s-1c{bottom:30px;position:absolute;width:calc(100% - 8px)}}@media screen and (orientation:landscape){.wrapper-top-left.fullscreen.s-1c{left:44px;top:12px}.wrapper-top-right.fullscreen.s-1c{right:44px;top:12px}.wrapper-middle-left.fullscreen.s-1c{left:44px}.wrapper-middle-left-second.fullscreen.s-1c{left:96px}.wrapper-middle-right.fullscreen.s-1c{right:44px}.controls-wrapper.fullscreen.s-1c{bottom:32px;left:36px;position:absolute;right:36px;width:calc(100% - 72px)}}"};function Jm(t,e){var $n,Qr;B(e,!0),Q(t,Uw);let[i,o]=Oe(),r=()=>w(Xi,"$seekToInteractiveDisabledTooltip$",i),a=()=>w(Jt,"$disabledControls$",i),l=()=>w(Pt,"$playbackState$",i),d=()=>w(Xo,"$adPlaybackState",i),s=()=>w(j,"$isEnded$",i),u=()=>w(_t,"$playerSize",i),m=()=>w(St,"$scrubbingInProgress",i),p=()=>w(Fi,"$chromecastState$",i),v=()=>w(Ue,"$isPictureInPictureActive",i),b=()=>w(ze,"$pictureInPictureType$",i),y=()=>w(fe,"$mobileNotReportControlHidden$",i),_=()=>w(fi,"$chromecastHidden",i),x=()=>w(at,"$playerPhase",i),I=()=>w(Rt,"$pipHidden",i),T=()=>w(st,"$currentGridType$",i),R=()=>w(ci,"$vkLogoHidden",i),A=()=>w(Yt,"$volumeHidden",i),P=()=>w(Pe,"$isLive$",i),E=()=>w(Ct,"$settingsMenuVisible",i),z=()=>w(dt,"$isRewindableLive$",i),F=()=>w(Me,"$isActiveLive$",i),U=()=>w(Ot,"$isAudioAvailable$",i),X=()=>w($e,"$muted$",i),ae=()=>w(le,"$volume$",i),Z=()=>w(vt,"$isInteractiveTime$",i),re=()=>w(Dn,"$settingButtonRef$",i),J=()=>w(wi,"$startedByKeyboard$",i),we=()=>w(No,"$isFullscreen",i),me=()=>w(Bt,"$additionalButtons$",i),ee=()=>w(Hi,"$autoplayNextToggleHidden",i),_e=()=>w($i,"$crashed$",i),Ce=()=>w(vo,"$settingsHidden",i),ge=()=>w(Zo,"$graphIsOpened$",i),pe=()=>w(_i,"$adPosition",i),Qe=()=>w(lt,"$adDuration",i),G=()=>w(Zt,"$position$",i),O=()=>w(Et,"$duration$",i),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),ot=h(e,"customFullscreenSupported",3,!0),ne=be(),ce=_o(),Ne=Vt(),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,It=ne.actions.internal.checkFullscreenSupport,wt=($n=ne.callbacks)==null?void 0:$n.onAudioDoesNotExistHint,Dt=(Qr=ne.callbacks)==null?void 0:Qr.onAudioDisabledHint,at=ne.playerPhase,Et=ne.state.duration$,Zt=ne.state.positionWithScrubbing$,Pt=ne.state.playbackState$,Ot=ne.state.isAudioAvailable$,zt=ne.state.isAudioDisabled,j=ne.state.isEnded$,Pe=ne.state.isLive$,le=ne.state.volume$,$e=ne.state.muted$,Me=ne.state.isActiveLive$,dt=ne.state.isRewindableLive$,St=ne.ui.scrubbingInProgress,fe=ne.ui.mobileNotReportControlHidden$,{isActive$:Ue,type$:ze}=ce.pictureInPicture$,Ct=ne.ui.settingsMenu.visible$,si=ne.ui.settingsMenu.openedByBtnKeyboard$,xt=ne.ui.controls,{volume:Yt,vkLogo:ci,autoplayNextToggle:Hi,pip:Rt,settings:vo,chromecast:fi}=ne.ui.hiddenControls,nt=ne.actions.internal.getVideoEpisodes(),jt=ne.webApi.pictureInPictureApi,Fi=ne.state.chromecastState$,$i=ne.state.crashed$,Jt=xt.disabledControls$,wi=ne.ui.startedByKeyboard$,st=ne.ui.currentGridType$,lt=ne.ads.duration,_i=ne.ads.position,Xo=ne.ads.playbackState,No=ne.ui.isFullscreen,_t=ne.ui.playerSize,Bt=ne.ui.additionalButtonsDeprecated$,W=ne.actions.internal.getVideoElement,Lt=ne.actions.internal.replayInteractive,ai=ne.state.isInteractive,vt=ne.state.isInteractiveTime$,ti=ne.state.showInteractiveGraph,qt=ne.state.showSeekToInteractive,Ke=ne.state.showPlayPrevChapter,Ui=ne.state.showInteractiveTimeIndicator,Xi=ce.seekToInteractiveDisabledTooltip$,Zo=ce.graphIsOpened$,tr=ne.ui.controlBlocks,ro=f(()=>Y(ne.state.playPrevChapterDisabledTooltip)),Ei=f(()=>Y(r())),bo=f(()=>a().has("EPISODE_BUTTON")),Oo=f(()=>a().has("GRAPH_BUTTON")),$o=f(()=>a().has("SEEK_TO_INTERACTIVE_BUTTON")),Pi=f(()=>a().has("PLAY_BUTTON")),yo=f(()=>a().has("REPLAY_BUTTON")),xo=f(()=>a().has("PLAY_PREV_CHAPTER_BUTTON")),Jo=f(()=>l()===xb.PLAYING),Br=f(()=>d()==="paused"),Hr=f(()=>s()&&!se()&&!ai),ss=f(()=>!s()||se()),ws=f(()=>e.showNextPrevButtons&&!se()&&e.prevButtonActive),$r=f(()=>e.showNextPrevButtons&&!se()&&e.nextButtonActive),ir=f(()=>u().width>300),Fr=f(()=>u().width>400),mn=f(m),vn=f(()=>p()!==yb.NOT_AVAILABLE&&!(v()&&b()===1)&&!y()&&!ai&&!_()),yr=f(()=>x()==="LiveWaitingStart"),xr=f(()=>!!jt&&p()!==yb.CONNECTED&&!y()&&(b()===1&&n(yr)||!n(yr))&&!n(mn)&&!ai&&!I()),en=q(!1);Mt(()=>{let We=jt==null?void 0:jt.info.isActive$.subscribe(yt=>N(en,yt,!0));return()=>We==null?void 0:We.unsubscribe()});let wr=f(()=>!n(mn)&&oo(T(),"s")),Sr=f(()=>!e.logoHidden&&u().width>350&&!R()),Cr=f(()=>Ne.features.fullscreen&&It()&&!(v()&&b()===1)&&(ai?ot():!0)&&!n(mn)&&!n(en)),Nn=f(()=>!A()&&!n(mn)),Ur=f(()=>(!P()||se())&&u().width>260&&!n(mn)&&!(Ne.features.interactiveHideTime&&ai)),Ss=f(()=>E()||e.showControls),zr=f(()=>!se()&&!P()&&!!(nt!=null&&nt.length)&&n(ir)&&!n(bo)&&!n(mn)),Si=f(()=>!z()||!!F()),as=f(()=>ti&&oo(T(),"m")),tn=f(()=>!U()||X()||ae()===0),pt=li({}),ei=li({}),On=wb(Gl,260),or=wb(ip,260);De(()=>{u(),Z(),On(W(),xt,pt,e.showControls),or(W(),tr,ei,e.showControls)});let Wr=()=>ne.actions.internal.toggleChromecast();function nr(){return gt(this,null,function*(){jt!=null&&jt.isActive()?yield jt==null?void 0:jt.exit():yield jt==null?void 0:jt.request()})}function rr(){fa({isAudioDisabled:zt,audioDisabledHintCallback:Dt,isAudioAvailable:U(),audioIsNotExistHintCallback:wt,isAds:se()})&&Le()}let Do=q(""),Tr=(We,yt)=>{if(!We){N(Do,Y("tooltip_live"),!0);return}yt&&yt===xb.PAUSED&&N(Do,Y("tooltip_play"),!0)};De(()=>{Tr(n(Si),l())});let Dn=de();De(()=>{re()&&Dl(re(),E(),si)}),De(()=>{ep(wi,J(),pt.playButton)});var sr=Fw(),ar=ue(sr);{var on=We=>{var yt=Ow(),ui=ue(yt);let go;var ki=k(ui,2);let Fo;Ze(ki,ft=>ei.topLeft=ft,()=>ei==null?void 0:ei.topLeft);var lo=k(ki,2);let Uo;var nn=C(lo);bi(nn,1,me,({iconUrl:ft,ariaLabel:pi,testId:Eo,onClick:co,tooltip:wn})=>ft,(ft,pi)=>{let Eo=()=>n(pi).iconUrl,co=()=>n(pi).ariaLabel,wn=()=>n(pi).testId,Ri=()=>n(pi).onClick,ds=()=>n(pi).tooltip,ks=f(()=>{var Wi;return(Wi=co())!=null?Wi:ds()});Ym(ft,{get iconUrl(){return Eo()},get ariaLabel(){return n(ks)},get testId(){return wn()},get onClick(){return Ri()}})});var dr=k(nn,2);{var To=ft=>{ac(ft,{get ref(){return pt.autoplayNextToggle},set ref(pi){pt.autoplayNextToggle=pi}})};V(dr,ft=>{e.showAutoplayNext&&!He()&&!ee()&&ft(To)})}var rn=k(dr,2);{var Un=ft=>{ec(ft,{isMobile:!0,click:Wr,get state(){return p()},get ref(){return pt.chromecast},set ref(pi){pt.chromecast=pi}})};V(rn,ft=>{n(vn)&&ft(Un)})}var Io=k(rn,2);{var yn=ft=>{Zm(ft,{click:nr,get isPictureInPictureActive(){return v()},get ref(){return pt.pip},set ref(pi){pt.pip=pi}})};V(Io,ft=>{n(xr)&&ft(yn)})}var zn=k(Io,2);{var ls=ft=>{Ul(ft,{get ref$(){return Dn}})};V(zn,ft=>{_e()&&!Ce()&&ft(ls)})}var cr=k(zn,2);{var je=ft=>{Zd(ft,{get click(){return Ee},get targetUrl(){return xe()},get logoClickable(){return e.logoClickable},get ref(){return pt.vkLogo},set ref(pi){pt.vkLogo=pi}})};V(cr,ft=>{n(Sr)&&ft(je)})}S(lo),Ze(lo,ft=>ei.topRight=ft,()=>ei==null?void 0:ei.topRight);var Xt=k(lo,2);let yi;var zo=C(Xt);{var xn=ft=>{let pi=f(()=>Te.bind(null,!0));ja(ft,{get click(){return n(pi)},type:"prev",isMobile:!0,get ref(){return pt.prevButton},set ref(Eo){pt.prevButton=Eo}})};V(zo,ft=>{n(ws)&&ft(xn)})}var Pr=k(zo,2);{var sn=ft=>{jl(ft,{get disabled(){return n(Pi)},get click(){return et},isMobile:!0,get isPlaying(){return n(Jo)},get ref(){return pt.playButton},set ref(pi){pt.playButton=pi}})};V(Pr,ft=>{n(ss)&&ft(sn)})}var an=k(Pr,2);{var Is=ft=>{Yl(ft,{get disabled(){return n(yo)},get click(){return et},isMobile:!0,get ref(){return pt.replayButton},set ref(pi){pt.replayButton=pi}})};V(an,ft=>{n(Hr)&&ft(Is)})}var kr=k(an,2);{var Es=ft=>{let pi=f(()=>Fe.bind(null,!0));ja(ft,{get click(){return n(pi)},type:"next",isMobile:!0,get ref(){return pt.nextButton},set ref(Eo){pt.nextButton=Eo}})};V(kr,ft=>{n($r)&&ft(Es)})}S(Xt),Ze(Xt,ft=>ei.middle=ft,()=>ei==null?void 0:ei.middle);var Ys=k(Xt,2);{var Ps=ft=>{var pi=Nw(),Eo=ue(pi);{var co=Wi=>{var Ii=Mw();let Wn;Ii.__click=[Aw,xo,e,ro];var Ar=C(Ii);let he=f(()=>!e.showControls);sc(Ar,{get hidden(){return n(he)},get disabled(){return n(xo)},get click(){return e.playPrevChapter},get ref(){return pt.playPrevChapterButton},set ref(it){pt.playPrevChapterButton=it}}),S(Ii),D(it=>Wn=oe(Ii,1,"wrapper-middle-left s-1c",null,Wn,it),[()=>({fullscreen:we(),hidden:!e.showControls})]),$(Wi,Ii)};V(Eo,Wi=>{Ke&&Wi(co)})}var wn=k(Eo,2);{var Ri=Wi=>{var Ii=Vw();let Wn;var Ar=C(Ii);let he=f(()=>!e.showControls&&!ge());dc(Ar,{get hidden(){return n(he)},get disabled(){return n(Oo)},get click(){return Zo.toggle},get graphIsOpened(){return ge()},get ref(){return pt.interactiveGraphButton},set ref(it){pt.interactiveGraphButton=it}}),S(Ii),D(it=>Wn=oe(Ii,1,Cd(Ke?"wrapper-middle-left-second":"wrapper-middle-left"),"s-1c",Wn,it),[()=>({fullscreen:we(),hidden:!e.showControls&&!ge()})]),$(Wi,Ii)};V(wn,Wi=>{n(as)&&Wi(Ri)})}var ds=k(wn,2);{var ks=Wi=>{var Ii=Rw();let Wn;Ii.__click=[Lw,$o,e,Ei];var Ar=C(Ii);let he=f(()=>!e.showControls);lc(Ar,{get hidden(){return n(he)},get disabled(){return n($o)},get click(){return e.seekToInteractive},get ref(){return pt.seekToInteractiveButton},set ref(it){pt.seekToInteractiveButton=it}}),S(Ii),D(it=>Wn=oe(Ii,1,"wrapper-middle-right s-1c",null,Wn,it),[()=>({fullscreen:we(),hidden:!e.showControls})]),$(Wi,Ii)};V(ds,Wi=>{qt&&Wi(ks)})}$(ft,pi)};V(Ys,ft=>{ai&&!m()&&ft(Ps)})}D((ft,pi,Eo,co)=>{go=oe(ui,1,"overlay-mobile s-1c",null,go,ft),Fo=oe(ki,1,"wrapper-top-left s-1c",null,Fo,pi),Uo=oe(lo,1,"wrapper-top-right s-1c",null,Uo,Eo),yi=oe(Xt,1,"wrapper-middle s-1c",null,yi,co)},[()=>({hidden:!n(Ss)}),()=>({hidden:!e.showControls,fullscreen:we()}),()=>({hidden:!e.showControls&&!y(),fullscreen:we()}),()=>({hidden:!e.showControls||m()||e.endScreenShown&&e.showNextPrevButtons})]),$(We,yt)};V(ar,We=>{se()||We(on)})}var gn=k(ar,2);{var Bn=We=>{var yt=Bw(),ui=ue(yt);let go;var ki=C(ui);op(ki,{get muted(){return X()},click:rr,get ref(){return pt.volume},set ref(To){pt.volume=To}}),S(ui);var Fo=k(ui,2);{var lo=To=>{var rn=Dw(),Un=C(rn);let Io=f(()=>!n(Br));jl(Un,{get disabled(){return n(Pi)},get click(){return et},isMobile:!0,get isPlaying(){return n(Io)},get ref(){return pt.playButton},set ref(yn){pt.playButton=yn}}),S(rn),$(To,rn)};V(Fo,To=>{n(Br)&&To(lo)})}var Uo=k(Fo,2);let nn;var dr=C(Uo);uc(dr,{get position(){return pe()},get duration(){return Qe()}}),S(Uo),D((To,rn)=>{go=oe(ui,1,"wrapper-top-right s-1c",null,go,To),nn=oe(Uo,1,"wrapper-bottom ads-timeline-mobile s-1c",null,nn,rn)},[()=>({fullscreen:we()}),()=>({fullscreen:we()})]),$(We,yt)};V(gn,We=>{se()&&d()!=="inactive"&&We(Bn)})}var Mi=k(gn,2);let Vi;var Bo=C(Mi);let Hn;var lr=C(Bo),Fn=C(lr),Ir=C(Fn);{var ct=We=>{Ro(We,{get disabled(){return n(yo)},get ref(){return pt.replayButton},set ref(yt){pt.replayButton=yt},children:(yt,ui)=>{Yl(yt,{get disabled(){return n(yo)},get click(){return Lt}})},$$slots:{default:!0}})};V(Ir,We=>{ai&&We(ct)})}var kt=k(Ir,2);{var so=We=>{Ro(We,{get ref(){return pt.liveButton},set ref(yt){pt.liveButton=yt},children:(yt,ui)=>{cc(yt,{get isLiveActive(){return n(Si)},isMobile:!0,get ariaLabel(){return n(Do)}})},$$slots:{default:!0}})};V(kt,We=>{!se()&&P()&&We(so)})}var wo=k(kt,2);{var So=We=>{let yt=f(()=>se()?pe():G()),ui=f(()=>se()?Qe():O()),go=f(()=>!e.showControls);Yd(We,{get showDuration(){return n(Fr)},get position(){return n(yt)},get duration(){return n(ui)},isMobile:!0,get isHidden(){return n(go)},get ref(){return pt.time},set ref(ki){pt.time=ki}})};V(wo,We=>{n(Ur)&&We(So)})}var hn=k(wo,2);let ao=f(()=>!n(zr));Ro(hn,{className:"w-max",get disabled(){return n(ao)},get ref(){return pt.episodes},set ref(We){pt.episodes=We},children:(We,yt)=>{var ui=Ve(),go=ue(ui);{var ki=Fo=>{var lo=Hw(),Uo=k(ue(lo),2);tc(Uo,{get position(){return G()},get duration(){return O()},get timeCodes(){return nt}}),$(Fo,lo)};V(go,Fo=>{n(zr)&&Fo(ki)})}$(We,ui)},$$slots:{default:!0}}),S(Fn),Ze(Fn,We=>ei.bottomLeft=We,()=>ei==null?void 0:ei.bottomLeft);var _n=k(Fn,2),Zi=C(_n);{var bn=We=>{Ro(We,{get ref(){return pt.volume},set ref(yt){pt.volume=yt},children:(yt,ui)=>{op(yt,{get muted(){return n(tn)},click:rr})},$$slots:{default:!0}})};V(Zi,We=>{n(Nn)&&We(bn)})}var Co=k(Zi,2);{var Cs=We=>{Ro(We,{get ref(){return pt.settings},set ref(yt){pt.settings=yt},children:(yt,ui)=>{Ul(yt,{get ref$(){return Dn}})},$$slots:{default:!0}})};V(Co,We=>{n(wr)&&We(Cs)})}var Kr=k(Co,2);{var Ts=We=>{Ro(We,{get ref(){return pt.fullscreen},set ref(yt){pt.fullscreen=yt},children:(yt,ui)=>{Xd(yt,{get click(){return e.toggleFullscreen},get isFullscreen(){return we()}})},$$slots:{default:!0}})};V(Kr,We=>{n(Cr)&&We(Ts)})}S(_n),Ze(_n,We=>ei.bottomRight=We,()=>ei==null?void 0:ei.bottomRight),S(lr),Ze(lr,We=>K(We),()=>K());var zi=k(lr,2);let qr=f(()=>!e.showControls);Za(zi,{get isHidden(){return n(qr)},get isAds(){return se()},get canRewindLive(){return e.canRewindLive},get isRewindableLive(){return z()},get ref(){return pt.timeline},set ref(We){pt.timeline=We}}),S(Bo),Ze(Bo,We=>ei.bottom=We,()=>ei==null?void 0:ei.bottom),S(Mi),Ze(Mi,We=>Ge(We),()=>Ge());var Ho=k(Mi,2);{var Er=We=>{nc(We,{get ref(){return pt.interactiveTimeIndicator},set ref(yt){pt.interactiveTimeIndicator=yt}})};V(Ho,We=>{Ui&&We(Er)})}D((We,yt)=>{Vi=oe(Mi,1,"wrapper-bottom mobile s-1c",null,Vi,We),Hn=oe(Bo,1,"controls-wrapper s-1c",null,Hn,yt)},[()=>({hidden:e.bottomHidden,"controls-hidden":!e.showControls,"no-smooth":e.bottomNoSmooth}),()=>({fullscreen:we()})]),$(t,sr),H(),o()}Ye(["click"]);function pc(t,e){B(e,!0);let[i,o]=Oe(),r=()=>w(I,"$isMobile",i),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,Sb),_=h(e,"onDisabledSeekToInteractiveClick",3,Sb),I=be().ui.isMobile,T=q(!1);Mt(()=>{let E=setTimeout(()=>N(T,!0),0);return()=>clearTimeout(E)});var R=Ve(),A=ue(R);{var P=E=>{var z=Ve(),F=ue(z);{var U=ae=>{Jm(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=>{Gm(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)})}$(t,R),H(),o()}var zw=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 fc(t,e){B(e,!0);let i=f(()=>e.reversed?"transform:scaleX(-1);transform-origin:50% 0;":""),o=f(()=>`${un(e.size)}${n(i)}`);Je(t,{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=zw();$(r,l)},$$slots:{default:!0}}),H()}var Ww=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(t,e){B(e,!0);let i=h(e,"reversed",3,!1),o=f(()=>i()?"transform:scaleX(-1);transform-origin: 50% 0;":void 0),r=f(()=>`seek-icon-${i()?"backward":"forward"}`);Je(t,{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=Ww();$(a,d)},$$slots:{default:!0}}),H()}var Kw=L('<span class="hot-key-helpers-text s-t"> </span>'),qw=L('<div data-testid="hotkey-helper-icon" class="s-t"><!> <!> <!> <!> <!> <!> <!> <!> <!> <!></div> <!>',1),Qw=L("<div><!></div>"),Gw={hash:"s-t",code:'.hot-key-helpers-container.s-t{align-items:center;animation:s-t-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-t{left:calc(25% - 100px)}.hot-key-helpers-container--right.s-t{left:calc(75% - 100px)}.hot-key-helpers-text.s-t{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-t{animation:s-t-fadeOut ease var(--controls-transition-duration);height:0;visibility:hidden;width:0}@keyframes s-t-fadeIn{0%{opacity:0}to{opacity:1}}@keyframes s-t-fadeOut{0%{opacity:1}to{opacity:0}}'};function tv(t,e){B(e,!0),Q(t,Gw);let[i,o]=Oe(),r=()=>w(e.data,"$data",i),a=be(),{features:l}=Vt(),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=Qw();let y;var _=C(b);{var x=I=>{var T=qw(),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=>{qs(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=>{Vn(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=>{rc(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=>{ma(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=>{ma(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");fc(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");ga(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=>{va(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=>{va(K,{get size(){return"48"},volume:1,shadow:!0})};V(Qe,K=>{n(p)==="VOLUME"&&K(G)})}S(R);var O=k(R,2);{var Ge=K=>{var se=Kw(),xe=C(se,!0);S(se),D(()=>ve(xe,n(v))),$(K,se)};V(O,K=>{n(v)&&K(Ge)})}D(()=>Re(R,"data-type",n(p))),$(I,T)};V(_,I=>{!n(s)&&n(p)&&I(x)})}S(b),D(I=>y=oe(b,1,"hot-key-helpers-container s-t",null,y,I),[()=>({hidden:n(s),"hot-key-helpers-container--left":n(u),"hot-key-helpers-container--right":n(m)})]),$(t,b),H(),o()}var Yw=(t,e,i,o,r,a)=>{if(e.has(t.code))switch(t.preventDefault(),t.stopPropagation(),t.code){case"ArrowUp":i();break;case"ArrowDown":o();break;case"ArrowLeft":r();break;case"ArrowRight":a();break}},jw=(t,e,i)=>{e.has(t.code)&&(t.preventDefault(),t.stopPropagation(),i())},Xw=L('<div tabindex="0" role="button"><div class="button-block s-q" aria-hidden="true"><div class="button-row s-q"><div class="button button-up s-q"><!></div> <div class="button button-right s-q"><!></div></div> <div class="button-row s-q"><div class="button button-left s-q"><!></div> <div class="button button-down s-q"><!></div></div></div></div>'),Zw={hash:"s-q",code:".immersive-controls.s-q{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-q{left:20px;top:50px}.button-block.s-q{height:40px;margin:auto;transform:rotate(45deg);width:40px}.button-row.s-q{display:flex;flex-direction:row;position:relative}.button.s-q{cursor:pointer;height:20px;text-align:center;width:20px}.button.s-q svg{opacity:.7;transition:opacity .2s linear}.button.button-up.s-q svg{transform:rotate(-45deg) translate(-1px,-1px)}.button.button-right.s-q svg{transform:rotate(45deg) translate(1px,-1px)}.button.button-down.s-q svg{transform:rotate(135deg) translate(1px,-3px)}.button.button-left.s-q svg{transform:rotate(-135deg) translate(-1px,-3px)}.button.s-q:hover svg{opacity:1}"};function mc(t,e){B(e,!0),Q(t,Zw);let i=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=Y("aria_label_spherical_control");var p=Xw();let v;p.__keydown=[Yw,r,a,l,s,d],p.__keyup=[jw,r,u];var b=C(p),y=C(b),_=C(y);_.__mousedown=a,_.__mouseup=u;var x=C(_);Or(x,{direction:"up",useBtnColor:!0}),S(_);var I=k(_,2);I.__mousedown=d,I.__mouseup=u;var T=C(I);Or(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);Or(P,{direction:"up",useBtnColor:!0}),S(A);var E=k(A,2);E.__mousedown=l,E.__mouseup=u;var z=C(E);Or(z,{direction:"up",useBtnColor:!0}),S(E),S(R),S(b),S(p),D(F=>{v=oe(p,1,"immersive-controls s-q",null,v,F),Re(p,"aria-label",m)},[()=>({"m-shifted":i()})]),ut("mouseleave",_,u),ut("mouseleave",I,u),ut("mouseleave",A,u),ut("mouseleave",E,u),$(t,p),H()}Ye(["keydown","keyup","mousedown","mouseup"]);import{ValueSubject as Tb,Subscription as Jw,filterChanged as eS,filter as tS}from"@vkontakte/videoplayer-shared/es2015";var Cb=(t=1e3)=>{let e=null,i=()=>{e&&(clearTimeout(e),e=null)};return{add:o=>{i(),e=setTimeout(o,t)},clear:i}};var np=class{constructor(){this.flickeringTimeout=Cb(1e3);this.subscriptions=new Jw;this.isAuto=!1;this.isLive=!1;this.captions$=new Tb([]);this.captionsPrepared$=new Tb([])}subscribe(){return this.subscriptions.add(this.captions$.pipe(tS(()=>this.isEnabled()),eS()).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 i=[],o=e.length>1&&e[0].type!=="timestamp"&&e[1].type!=="timestamp";o&&i.push([{value:String(e[0].value),timeAppeared:null}]),i.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(i)}};var iS=L('<span class="caption-line s-d"><span class="caption-segment s-d"> </span></span>'),oS=L('<span class="caption-line s-d"><span class="caption-segment s-d"></span></span>'),nS=L('<span class="caption-line s-d"><span class="caption-segment s-d"> </span></span>'),rS=L('<div><span class="caption s-d"><!></span></div>'),sS=L("<div><!></div>"),aS={hash:"s-d",code:".subtitles-container.s-d{height:100%;left:0;pointer-events:none;position:absolute;top:0;transition:transform var(--controls-transition-duration);width:100%}.subtitles-container.shifted.s-d{transform:translateY(calc(var(--controls-height)*-1))}.subtitles-container.preview-track-active.s-d{transform:translateY(calc(var(--preview-track-height)*-1))}.preview-track-active.s-d .subtitles-caption:where(.s-d){bottom:var(--preview-track-controls-top-offset)}.subtitles-caption.s-d{bottom:4%;display:flex;justify-content:center;left:4%;position:absolute;right:4%}.subtitles-caption.mobile.s-d{bottom:8%}.subtitles-container.auto.s-d .subtitles-caption:where(.s-d){left:var(--subtitles-caption-margin);right:var(--subtitles-caption-margin)}.caption.s-d{background:rgba(0,0,0,.4);border-radius:4px;display:block;overflow-wrap:normal;padding:4px 8px}.subtitles-container.auto.s-d .caption:where(.s-d){width:100%}.caption-line.s-d{display:block;text-align:center}.subtitles-container.auto.s-d .caption-line:where(.s-d){text-align:left}.caption-segment.s-d{color:var(--white);display:inline-block;font-size:13px;line-height:1.2;white-space:pre-wrap}"};function el(t,e){B(e,!0),Q(t,aS);let[i,o]=Oe(),r=()=>w(v,"$currentSubtitle$",i),a=()=>w(y,"$isLive$",i),l=()=>w(_,"$isFullscreen",i),d=()=>w(x,"$previewTrackActive",i),s=()=>w(b,"$isAutoSubtitleCaptionVisible$",i),u=h(e,"isMobile",3,!1),m=be(),p=Vt(),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);De(()=>{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(li([[]]));Mt(()=>{N(P,new np().subscribe(),!0);let Z=n(P).captionsPrepared$.subscribe(re=>{N(E,re,!0)});return()=>{var re;(re=n(P))==null||re.destroy(),Z.unsubscribe()}}),Mt(()=>{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=sS();let U;var X=C(F);{var ae=Z=>{var re=rS();let J;var we=C(re),me=C(we);{var ee=Ce=>{var ge=iS(),pe=C(ge),Qe=C(pe,!0);S(pe),S(ge),D(G=>{var O;qe(pe,`font-size: ${(O=n(A))!=null?O:""}px`),ve(Qe,G)},[()=>Y("subtitles_auto_caption")]),$(Ce,ge)},_e=(Ce,ge)=>{{var pe=G=>{var O=Ve(),Ge=ue(O);bi(Ge,17,()=>n(E),wd,(K,se)=>{var xe=oS(),He=C(xe);bi(He,21,()=>n(se),({value:ot,timeAppeared:ne})=>ne,(ot,ne)=>{let ce=()=>n(ne).value,Ne=()=>n(ne).timeAppeared;var Le=Ve(),et=ue(Le);{var Ee=Te=>{var Fe=gs();D(()=>ve(Fe,ce())),$(Te,Fe)};V(et,Te=>{(!Ne()||Ne()<=e.position)&&Te(Ee)})}$(ot,Le)}),S(He),S(xe),D(()=>{var ot;return qe(He,`font-size: ${(ot=n(A))!=null?ot:""}px`)}),$(K,xe)}),$(G,O)},Qe=G=>{var O=Ve(),Ge=ue(O);bi(Ge,17,()=>e.captions,({value:K})=>K,(K,se)=>{let xe=()=>n(se).value;var He=nS(),ot=C(He),ne=C(ot,!0);S(ot),S(He),D(()=>{var ce;qe(ot,`font-size: ${(ce=n(A))!=null?ce:""}px`),ve(ne,xe())}),$(K,He)}),$(G,O)};V(Ce,G=>{var O;n(I)&&((O=n(E))!=null&&O.length)?G(pe):G(Qe,!1)},ge)}};V(me,Ce=>{n(I)&&s()?Ce(ee):Ce(_e,!1)})}S(we),S(re),D(Ce=>{var ge;J=oe(re,1,"subtitles-caption s-d",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),D(Z=>U=oe(F,1,"subtitles-container s-d",null,U,Z),[()=>({shifted:e.shifted,"preview-track-active":d(),auto:n(I)&&!n(T)&&!s()})]),$(t,F),H(),o()}import{ChromecastState as lS}from"@vkontakte/videoplayer-core/es2015";var dS=L('<div class="text s-v"> </div>'),cS=L('<div><div class="icon_wrapper s-v"><!></div> <!></div>'),uS={hash:"s-v",code:".wrapper.s-v{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-v{background-size:cover}.icon_wrapper.s-v{align-items:center;display:flex;flex-direction:column;width:400px}.text.s-v{margin-top:20px}"};function vc(t,e){B(e,!0),Q(t,uS);let i=h(e,"chromecastDeviceName",3,"chromecastDeviceName"),o=Vt();var r=cS();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);Jd(d,{get size(){return"48"},get iconState(){return lS.CONNECTED}}),S(l);var s=k(l,2);{var u=m=>{var p=dS(),v=C(p);S(p),D(()=>{var b;return ve(v,`Видео воспроизводится на ${(b=i())!=null?b:""}`)}),$(m,p)};V(s,m=>{i()&&m(u)})}S(r),D(m=>{a=oe(r,1,"wrapper s-v",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})]),$(t,r),H()}Ye(["contextmenu","click","dblclick"]);var pS=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 iv(t){Je(t,{width:"200",height:"200",viewBox:"460 190 130 90",testId:"error-icon",children:(e,i)=>{var o=pS();$(e,o)},$$slots:{default:!0}})}var fS=L('<div class="container s-5"><!></div>'),mS={hash:"s-5",code:".container.s-5{align-items:center;background:#000;bottom:0;display:flex;justify-content:center;left:0;position:absolute;right:0;top:0}"};function tl(t){Q(t,mS);var e=fS(),i=C(e);iv(i,{}),S(e),$(t,e)}var vS=L('<div class="playButton s-b" tabindex="0" role="button"><div class="playButtonBackground s-b"></div> <!></div>'),gS=L('<div data-testid="unstarted-thumb"><!></div>'),hS={hash:"s-b",code:".container.s-b{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-b{opacity:0;visibility:hidden}.container.bgCover.s-b{background-size:cover}.playButton.s-b{align-items:center;display:flex;height:var(--big-play-size);justify-content:center;margin:auto;width:var(--big-play-size)}.playButton.s-b,.playButtonBackground.s-b{bottom:0;left:0;position:absolute;right:0;top:0}.playButtonBackground.s-b{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-b:hover .playButtonBackground:where(.s-b){background-color:var(--big-play-hover-bg-color);transform:scale(1.15)}.playButton.s-b svg{position:relative}"};function il(t,e){B(e,!0),Q(t,hS);let i=h(e,"iconVisible",3,!0),o=be(),r=Vt(),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=gS();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=vS();y.__keydown=d;var _=k(C(y),2);Vn(_,{get size(){return"48"}}),S(y),D(()=>Re(y,"aria-label",l)),$(b,y)};V(p,b=>{i()&&b(v)})}return S(u),D(b=>{m=oe(u,1,"container s-b",null,m,b),qe(u,`background-color: #222; background-image: url('${e.thumbUrl||""}')`)},[()=>({hidden:e.hidden,bgCover:r.features.previewNoEmptySpace})]),$(t,u),H({handlePressKey:d,handleClick:s})}Ye(["click","contextmenu","keydown"]);var _S=L('<span class="text s-y"> </span>'),bS=(t,e)=>{var i;return(i=e.onTitleClicked)==null?void 0:i.call(e)},$S=L('<a target="_blank" class="link s-y"><!></a>'),yS=(t,e)=>e.onTitleClicked(),xS=L("<button><!></button>"),wS=L('<div data-testid="video_title"><!></div>'),SS={hash:"s-y",code:".title.s-y{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-y,.title.s-y{color:var(--white)}.link.s-y{pointer-events:auto;text-decoration:none}.link.s-y:hover{text-decoration:underline}.text.s-y{pointer-events:auto}.size-sm.s-y{font-size:14px;font-weight:500;line-height:18px}.hidden.s-y{opacity:0;transform:translateY(calc(var(--controls-gradient-height)*-1));visibility:hidden}"};function ov(t,e){B(e,!0),Q(t,SS);let i=b=>{var y=_S(),_=C(y,!0);S(y),Ze(y,x=>l(x),()=>l()),D(()=>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);Mt(()=>{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=wS();let u;var m=C(s);{var p=b=>{var y=$S();y.__click=[bS,e];var _=C(y);i(_),S(y),D(()=>Re(y,"href",e.titleLinkHref)),$(b,y)},v=(b,y)=>{{var _=I=>{var T=xS();T.__click=[yS,e];var R=C(T);i(R),S(T),$(I,T)},x=I=>{i(I)};V(b,I=>{e.onTitleClicked?I(_):I(x,!1)},y)}};V(m,b=>{e.titleLinkHref?b(p):b(v,!1)})}S(s),Ze(s,b=>N(d,b),()=>n(d)),D(b=>u=oe(s,1,`title size-${a()}`,"s-y",u,b),[()=>({hidden:r()})]),$(t,s),H()}Ye(["click"]);import{throttleFn as AS}from"@vkontakte/videoplayer-shared/es2015";var CS=L('<div class="timer__cell cell s-1f"><span class="cell__value s-1f"> </span> <span class="cell__unit s-1f"> </span></div> <span class="timer__points s-1f"> </span>',1),TS=L('<div class="timer__cell cell s-1f"><span class="cell__value s-1f"> </span> <span class="cell__unit s-1f"> </span></div> <span class="timer__points s-1f"> </span>',1),IS=L('<div class="timer__cell cell s-1f"><span class="cell__value s-1f"> </span> <span class="cell__unit s-1f"> </span></div> <span class="timer__points s-1f"> </span>',1),ES=L('<div class="timer__cell cell s-1f"><span class="cell__value s-1f"> </span> <span class="cell__unit s-1f"> </span></div>'),PS=L("<div><!> <!> <!> <!></div>"),kS={hash:"s-1f",code:".timer__container.s-1f{align-items:flex-start;display:flex;justify-content:center}.cell.s-1f{align-items:center;display:flex;flex-direction:column}.cell__value.s-1f{font-size:48px;font-weight:600;line-height:1.2}.small.s-1f .cell__value:where(.s-1f){font-size:24px}.cell__unit.s-1f{font-size:14px;font-weight:400;line-height:1.2}.small.s-1f .cell__unit:where(.s-1f){font-size:12px}.timer__points.s-1f{display:inline-block;font-size:42px;font-weight:600;line-height:1.2;margin:0 8px}.small.s-1f .timer__points:where(.s-1f){font-size:20px}"};function nv(t,e){B(e,!0),Q(t,kS);let i=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(i,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()};Mt(()=>{l=requestAnimationFrame(b)}),cn(()=>{cancelAnimationFrame(l)});var y=PS();let _;var x=C(y);{var I=F=>{var U=CS(),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),D((_e,Ce,ge)=>{ae=qe(X,"",ae,{width:_e}),ve(re,n(i)),ve(we,Ce),ve(ee,ge)},[()=>p(n(i)),()=>Y("waiting_live_day_value"),()=>Y("waiting_live_colon")]),$(F,U)};V(x,F=>{n(i)&&F(I)})}var T=k(x,2);{var R=F=>{var U=TS(),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),D((_e,Ce,ge)=>{ae=qe(X,"",ae,{width:_e}),ve(re,n(o)),ve(we,Ce),ve(ee,ge)},[()=>p(n(o)),()=>Y("waiting_live_hour_value"),()=>Y("waiting_live_colon")]),$(F,U)};V(T,F=>{n(o)&&F(R)})}var A=k(T,2);{var P=F=>{var U=IS(),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),D((_e,Ce,ge)=>{ae=qe(X,"",ae,{width:_e}),ve(re,n(r)),ve(we,Ce),ve(ee,ge)},[()=>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 z=F=>{var U=ES();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),D((we,me)=>{X=qe(U,"",X,{width:we}),ve(Z,n(a)),ve(J,me)},[()=>p(n(a)),()=>Y("waiting_live_second_value")]),$(F,U)};V(E,F=>{n(a)&&F(z)})}S(y),D(F=>_=oe(y,1,"timer__container s-1f",null,_,F),[()=>({small:e.isSmallSize})]),$(t,y),H()}var LS=L('<div class="waiting s-s"><span> </span></div>'),MS=L('<div class="upcoming-timer timer s-s"><span> </span> <!></div>'),VS=L('<div class="waiting-container s-s"><!></div>'),RS={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 gc(t,e){B(e,!0),Q(t,RS);let i=h(e,"startTime",3,0),o=f(()=>i()<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?AS(()=>{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;De(()=>{n(s),n(d),n(o),p==null||p()}),cn(()=>{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=VS();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=LS(),T=C(I);let R;var A=C(T,!0);S(T),S(I),Ze(I,P=>N(r,P),()=>n(r)),D((P,E)=>{R=oe(T,1,"waiting__title s-s",null,R,P),ve(A,E)},[()=>({medium:n(m),small:n(u)}),()=>Y("waiting_live_upcoming_title")]),$(x,I)},_=x=>{var I=MS(),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(()=>i()||0);nv(P,{get isSmallSize(){return n(E)},get startTime(){return n(z)},onTimerOver:()=>N(o,!0)}),S(I),Ze(I,F=>N(a,F),()=>n(a)),D((F,U)=>{R=oe(T,1,"timer__title s-s",null,R,F),ve(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),D(()=>qe(v,`background-image: url(${e.thumbUrl})`)),Ln(v,"clientWidth",x=>N(d,x)),Ln(v,"clientHeight",x=>N(s,x)),$(t,v),H()}Ye(["contextmenu","click"]);var NS=L('<div class="waiting-container s-x"><div class="waiting-caption s-x"><!> <p class="waiting-title s-x"> </p></div></div>'),OS={hash:"s-x",code:'.waiting-container.s-x{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-x,.waiting-container.s-x:before{height:100%;left:0;position:absolute;top:0;width:100%}.waiting-container.s-x:before{backdrop-filter:blur(10px);background-color:rgba(0,0,0,.4);content:""}.waiting-caption.s-x{align-items:center;display:flex;flex-direction:column;position:relative}.waiting-title.s-x{font-size:20px;font-weight:400;line-height:1.2;margin:0;padding:20px;text-align:center}'};function ol(t,e){B(e,!0),Q(t,OS);let i=h(e,"thumbUrl",3,""),o={recover:Y("waiting_live_recover_title"),record:Y("waiting_record_title")},r=f(()=>o[e.kind]||"");var a=NS();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);qa(d,{style:"position: static; transform: translate(0, 0)"});var s=k(d,2),u=C(s,!0);S(s),S(l),S(a),D(()=>{qe(a,`background-image: url('${i()}')`),ve(u,n(r))}),$(t,a),H()}Ye(["contextmenu","click"]);var DS=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 rv(t){Je(t,{width:"16",height:"16",testId:"check-mark-icon",children:(e,i)=>{var o=DS();$(e,o)},$$slots:{default:!0}})}var BS=L('<div class="select-icon s-1x"><!></div>'),HS={hash:"s-1x",code:".select-icon.s-1x{margin-right:auto;opacity:.9;padding-right:12px;position:relative;top:3px}"};function hc(t){Q(t,HS);var e=BS(),i=C(e);rv(i,{}),S(e),$(t,e)}var FS=(t,e)=>{t.stopPropagation(),e.item.selectItem(e.item.value)},US=(t,e)=>{Bl(t,()=>e.item.selectItem(e.item.value))},zS=L("<p> </p>"),WS=L('<p class="sublabel s-1u"> </p>'),KS=L('<li role="menuitem" tabindex="0"><!> <div><!> <!></div></li>'),qS={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 sv(t,e){B(e,!0),Q(t,qS);let i=h(e,"isMobile",3,!1);var o=KS();let r;o.__click=[FS,e],o.__keydown=[US,e];var a=C(o);{var l=y=>{hc(y,{})};V(a,y=>{e.item.selected&&y(l)})}var d=k(a,2);let s;var u=C(d);{var m=y=>{var _=Ve(),x=ue(_);Bi(x,()=>e.item.valueComponent,(I,T)=>{T(I,os(()=>{var R;return(R=e.item.valueComponentParams)!=null?R:{}}))}),$(y,_)},p=y=>{var _=zS();let x;var I=C(_,!0);S(_),D(T=>{var R;x=oe(_,1,"label s-1u",null,x,T),ve(I,(R=e.item.label)!=null?R:e.item.value)},[()=>({mobile:i()})]),$(y,_)};V(u,y=>{e.item.valueComponent?y(m):y(p,!1)})}var v=k(u,2);{var b=y=>{var _=WS(),x=C(_,!0);S(_),D(()=>ve(x,e.item.sublabel)),$(y,_)};V(v,y=>{e.item.sublabel&&y(b)})}S(d),S(o),D((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:i()}),()=>{var y,_;return(_=(y=e.item.ariaLabel)!=null?y:e.item.label)!=null?_:e.item.value.toString()},()=>({"submenu-value-mobile":i()})]),$(t,o),H()}Ye(["click","keydown"]);var QS=L('<li role="menuitem" tabindex="0" aria-haspopup="true"><!> <div><!></div></li>');function av(t,e){B(e,!0);let i=h(e,"isMobile",3,!1),o=h(e,"refMenuItems",15),r=f(()=>()=>e.openSubMenuList(e.item.children)),a=f(()=>_=>Du(_,n(r)));var l=QS();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=_=>{hc(_,{})};V(s,_=>{e.item.selected&&_(u)})}var m=k(s,2);let p;var v=C(m);{var b=_=>{var x=Ve();let I=f(()=>e.item.valueComponent);var T=ue(x);Bi(T,()=>n(I),(R,A)=>{A(R,os(()=>{var P;return(P=e.item.valueComponentParams)!=null?P:{}}))}),$(_,x)},y=_=>{var x=gs();D(()=>ve(x,e.item.label)),$(_,x)};V(v,_=>{e.item.valueComponent?_(b):_(y,!1)})}S(m),S(l),Ze(l,_=>o(o()[e.item.id]=_,!0),()=>{var _;return(_=o())==null?void 0:_[e.item.id]}),D((_,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:i(),bottomBordered:e.item.bottomBordered}),()=>({"submenu-value-mobile":i()})]),$(t,l),H()}Ye(["click","keydown"]);var rs={"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 YS=(t,e)=>{W_(t,e.returnFromSubMenu,e.closeSettingsMenu)},jS=(t,e)=>{t.stopPropagation(),e.returnFromSubMenu()},XS=(t,e)=>{Fd(t)&&(Dr(t),e.returnFromSubMenu())},ZS=L('<div><ul role="menu"><li role="menuitem" tabindex="0" data-testid="return-to-settings-menu"><!> <p class="title s-1m"> </p></li> <!></ul></div>'),JS={hash:"s-1m",code:".sub-menu.s-1m{--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-1m .item.mobile{font-size:14px;line-height:var(--item-label-line-height);padding:var(--item-padding-vertical-mobile) 17px}.sub-menu.s-1m{padding-top:calc(var(--edge-item-padding-vertical) + var(--item-padding-vertical) + var(--item-label-line-height))}.sub-menu.mobile.s-1m{padding-top:calc(var(--edge-item-padding-vertical-mobile) + var(--item-padding-vertical-mobile) + var(--item-label-line-height) + 1px)}.sub-menu.s-1m .items:where(.s-1m) .item.header:where(.s-1m){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-1m .title:where(.s-1m){margin-left:8px}.sub-menu.s-1m .item{padding:var(--item-padding-vertical) 12px;padding-right:22px}.items.s-1m .item:first-child:not(.mobile){padding-top:var(--edge-item-padding-vertical)}.items.s-1m .item:last-child:not(.mobile){padding-bottom:var(--edge-item-padding-vertical)}.items.s-1m .item.mobile:first-child{padding-top:var(--edge-item-padding-vertical-mobile)}.items.s-1m .item.mobile:last-child{padding-bottom:var(--edge-item-padding-vertical-mobile)}.sub-menu.s-1m .item.bottomBordered{border-bottom:var(--divider-border)}.sub-menu.s-1m .item .sublabel{font-size:12px;line-height:14px}.item.s-1m:not(.mobile) p:where(.s-1m),.sub-menu.s-1m .item:not(.mobile) .label{font-size:13px;line-height:var(--item-label-line-height)}"};function dv(t,e){B(e,!0),Q(t,JS);let[i,o]=Oe(),r=()=>w(p,"$isFullscreen",i),a=()=>w(v,"$playerSize",i),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);Mt(()=>{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=ZS();let R;var A=C(T);let P;A.__keydown=[YS,e];var E=C(A);let z;E.__click=[jS,e],E.__keydown=[XS,e];var F=C(E);Or(F,{direction:"left"});var U=k(F,2),X=C(U,!0);S(U),S(E),Ze(E,Z=>N(b,Z),()=>n(b));var ae=k(E,2);bi(ae,17,()=>e.items,wd,(Z,re)=>{var J=Ve(),we=ue(J);{var me=_e=>{sv(_e,{get item(){return n(re)},get isMobile(){return l()}})},ee=(_e,Ce)=>{{var ge=pe=>{av(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),Ze(A,Z=>u(Z),()=>u()),S(T),D((Z,re,J)=>{R=oe(T,1,"sub-menu menu s-1m",null,R,Z),Re(T,"data-testid",`${e.id}-sub-menu`),qe(T,`min-width: ${n(I)}px`),P=oe(A,1,"items s-1m",null,P,re),qe(A,n(x)),z=oe(E,1,"item header back s-1m",null,z,J),Re(E,"aria-label",s()),ve(X,e.title)},[()=>({desktop:!l(),mobile:l()}),()=>({mobile:l()}),()=>({mobile:l()})]),Ln(E,"clientWidth",Z=>N(y,Z)),Ln(E,"clientHeight",Z=>N(_,Z)),$(t,T),H(),o()}Ye(["keydown","click"]);import{noop as eC}from"@vkontakte/videoplayer-shared/es2015";var tC=(t,e)=>Du(t,e()),iC=(t,e)=>{t.stopPropagation(),e()()},oC=L('<div class="value s-1n"> </div>'),nC=L('<li role="menuitem" tabindex="0" aria-haspopup="true"><div class="icon-wrapper"><!></div> <div class="label"> </div> <!></li>'),rC={hash:"s-1n",code:".value.s-1n{opacity:.7;overflow:hidden;position:relative;text-overflow:ellipsis}"};function cv(t,e){B(e,!0),Q(t,rC);let i=h(e,"isMobile",3,!1),o=h(e,"onClick",3,eC),r=h(e,"valueComponent",3,void 0),a=h(e,"iconProps",19,()=>({})),l=h(e,"ref",15);var d=nC();let s;d.__click=[iC,o],d.__keydown=[tC,o];var u=C(d),m=C(u);{var p=T=>{Xa(T,{get icon(){return e.icon}})},v=T=>{var R=Ve();let A=f(()=>e.icon);var P=ue(R);Bi(P,()=>n(A),(E,z)=>{z(E,os(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=Ve();let A=f(r);var P=ue(R);Bi(P,()=>n(A),(E,z)=>{z(E,{})}),$(T,R)},I=T=>{var R=oC(),A=C(R,!0);S(R),D(()=>ve(A,e.value)),$(T,R)};V(_,T=>{r()?T(x):T(I,!1)})}S(d),Ze(d,T=>l(T),()=>l()),D(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:i()})]),$(t,d),H()}Ye(["click","keydown"]);import{noop as Eb}from"@vkontakte/videoplayer-shared/es2015";var sC=(t,e)=>{Bl(t,()=>e())},aC=L('<div class="icon icon-error-stub"><div class="inner"></div></div>'),lC=L('<img class="icon" aria-hidden="true"/>'),dC=L('<li role="menuitem" tabindex="0"><div class="icon-wrapper"><!></div> <div class="label s-1o"> </div></li>'),cC={hash:"s-1o",code:".label.s-1o{overflow:hidden;text-overflow:ellipsis}"};function uv(t,e){B(e,!0),Q(t,cC);let i=h(e,"isMobile",3,!1),o=h(e,"onClick",3,Eb),r=h(e,"closeSettings",3,Eb),a=q(!1),l=()=>{N(a,!0)},d=x=>{x==null||x.stopPropagation(),o()(),r()()};var s=dC();let u;s.__click=d,s.__keydown=[sC,d];var m=C(s),p=C(m);{var v=x=>{var I=Ve(),T=ue(I);{var R=P=>{var E=aC();$(P,E)},A=P=>{var E=lC();D(()=>Re(E,"src",e.icon)),ut("error",E,l),Ra(E),$(P,E)};V(T,P=>{n(a)?P(R):P(A,!1)})}$(x,I)},b=x=>{var I=Ve();let T=f(()=>e.icon);var R=ue(I);Bi(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),D(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:i()})]),$(t,s),H()}Ye(["click","keydown"]);import{noop as fC}from"@vkontakte/videoplayer-shared/es2015";var uC=L('<div class="toggle_wrap s-1r"><div></div> <div class="toggle-label s-1r"></div></div>'),pC={hash:"s-1r",code:'.toggle_wrap.s-1r{cursor:pointer;font-size:12px;line-height:15px;min-height:15px;padding:0;user-select:none}.toggle.s-1r{background-color:var(--toggle-color-separator);border-radius:45px;cursor:pointer;float:right;height:9px;margin-top:3px;width:28px}.toggle.s-1r: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-1r:after{background-color:var(--toggle-color-on);left:13px}.toggle-label.s-1r{overflow:hidden}'};function pv(t,e){Q(t,pC);let i=h(e,"enabled",3,!1);var o=uC(),r=C(o);let a;di(2),S(o),D(l=>a=oe(r,1,"toggle s-1r",null,a,l),[()=>({on:i()})]),$(t,o)}var mC=(t,e,i)=>{K_(t,e(),o=>i()(o))},vC=(t,e,i)=>{t.stopPropagation(),e()(!i())},gC=L('<div><div class="icon-wrapper"><!></div> <div class="label"> </div> <!></div>'),hC=L('<li role="menuitem" tabindex="0"><!></li>');function fv(t,e){B(e,!0);let i=h(e,"isMobile",3,!1),o=h(e,"onClick",3,fC),r=h(e,"enabled",3,!1),a=h(e,"tooltipText",3,void 0),l=h(e,"maxTooltipWidth",3,void 0);var d=hC();let s;d.__click=[vC,o,r],d.__keydown=[mC,r,o];var u=C(d);Qa(u,{get content(){return a()},get isMobile(){return i()},placement:"left",translateX:10,isFullWidthWrapper:!0,get maxTooltipWidth(){return l()},children:(m,p)=>{var v=gC();let b;var y=C(v),_=C(y);{var x=P=>{Xa(P,{get icon(){return e.icon}})},I=P=>{var E=Ve();let z=f(()=>e.icon);var F=ue(E);Bi(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);pv(A,{get enabled(){return r()}}),S(v),D(P=>{b=oe(v,1,"switch-wrapper",null,b,P),ve(R,e.label)},[()=>({mobile:i()})]),$(m,v)},$$slots:{default:!0}}),S(d),D(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:i()})]),$(t,d),H()}Ye(["click","keydown"]);import{isValidURL as UC,VideoQuality as Bb}from"@vkontakte/videoplayer-shared/es2015";var Pb=()=>{let t=q(li([])),e=f(()=>(n(t).length?n(t).at(-1):null)||null);return{get current(){return n(e)},pushSubMenu:i=>{n(t).push(i)},popSubMenu:()=>{N(t,n(t).slice(0,-1),!0)},popAllSubMenus:()=>{N(t,[],!0)}}};import{getVideoQualityLabel as _C}from"@vkontakte/videoplayer-shared/es2015";var bC=L('<div class="quality-icon s-1q"><!></div>'),$C=L('<div class="quality-label s-1q"><span> </span> <!></div>'),yC={hash:"s-1q",code:".quality-label.s-1q{position:relative}.quality.s-1q{font-size:13px;line-height:18px}.quality.sub.s-1q{opacity:.7}.quality-icon.s-1q{display:flex;padding-left:2px;position:absolute;right:0;top:0;transform:translateX(100%)}.quality-icon.s-1q svg{color:var(--blue-light)}"};function nl(t,e){B(e,!0),Q(t,yC);let i=h(e,"isSubCase",3,!1),o=f(()=>e.quality?_C(e.quality):""),r=f(()=>Wu(e.quality));var a=$C(),l=C(a);let d;var s=C(l,!0);S(l);var u=k(l,2);{var m=p=>{var v=bC();let b=f(()=>n(r));var y=C(v);Bi(y,()=>n(b),(_,x)=>{x(_,{})}),S(v),D(()=>Re(v,"data-testid",`${n(o)}-icon`)),$(p,v)};V(u,p=>{n(r)&&!e.isMobile&&p(m)})}S(a),D(p=>{d=oe(l,1,"s-1q",null,d,p),ve(s,e.label)},[()=>({sub:!i(),quality:!e.isMobile})]),$(t,a),H()}import{VideoQuality as xC}from"@vkontakte/videoplayer-shared/es2015";import{VideoQuality as kb}from"@vkontakte/videoplayer-core/es2015";var Ab=({quality:t,availableQualities:e})=>{let i=e.find(o=>o.value===t);return i?i.displayValue:t},Lb=({quality:t,availableQualities:e,isAutoQualityEnabled:i})=>{if(!t)return"...";let o=Ab({quality:t,availableQualities:e});return i?t===kb.INVARIANT?Y("auto_quality_invariant"):Y("auto_quality",{actual:o}):o},Mb=({quality:t,availableQualities:e,prefix:i,onlyPrefix:o})=>t?o||t===kb.INVARIANT?i:`${i}${Ab({quality:t,availableQualities:e})}`:"...";var wC=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 Xl(t,e){B(e,!0),Q(t,SC);let[i,o]=Oe(),r=()=>w(s,"$currentQuality$",i),a=()=>w(u,"$availableQualities$",i),l=()=>w(m,"$isMobile$",i),d=be(),s=d.state.currentQuality$,u=d.state.availableQualities$,m=d.ui.isMobile,p=" · ",v=f(()=>e.prefix+(e.selected&&r()!==xC.INVARIANT?p:"")),b=f(()=>Mb({prefix:n(v),quality:r(),availableQualities:a(),onlyPrefix:!e.selected}));var y=wC(),_=C(y);let x=f(()=>e.selected?r():void 0);nl(_,{get quality(){return n(x)},get label(){return n(b)},get isMobile(){return l()},isSubCase:!0}),S(y),$(t,y),H(),o()}var CC=t=>{let e=t.join("|"),i="<(?<keyhtml>.*?)(?<propshtml> .*?)?>(?<childrenhtml>.*?)</\\k<keyhtml>>",o=`{(?<keyi18n>${e})}(?<childreni18n>.*?){/\\k<keyi18n>}`,r="<(?<keyhtmlself>.*?)(?<propshtmlself> .*?)?/?>",a=`{(?<keyi18nself>${e})}`;return new RegExp(`${i}|${o}|${r}|${a}`,"g")},TC={br:!0,span:!0},mv=(t,e={})=>{var d,s,u,m,p,v,b;if(!t)return t;let i=ke(ke({},TC),e),o=Object.keys(i);if(!o.length)return t;let r=CC(o),a=[],l=0;for(let y of t.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(!i[x]){a.push(t.slice(l,I)),l=I+_.length;continue}let T=(p=y.groups)!=null&&p.childrenhtml?mv(y.groups.childrenhtml,i):"",R=(v=y.groups)!=null&&v.childrenhtml?_.replace(new RegExp((b=y.groups)==null?void 0:b.childrenhtml),()=>T||""):_;a.push(t.slice(l,I),R),l=I+_.length}return l===0?t:(a.push(t.slice(l)),a.join(""))};function _c(t,e){B(e,!1);let i=h(e,"message",8),o=mv(i());ho();var r=Ve(),a=ue(r);{var l=d=>{var s=Ve(),u=ue(s);Sd(u,()=>o),$(d,s)};V(a,d=>{o&&d(l)})}$(t,r),H()}var IC=L('<p class="quality-applies sublabel s-1s"><!></p>'),EC={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 vv(t,e){B(e,!1),Q(t,EC),ho();var i=IC(),o=C(i);let r=In(()=>Y("quality_applience",{action:`<span>${Y("quality_applience_action")}</span>`}));_c(o,{get message(){return n(r)}}),S(i),$(t,i),H()}var Rb=({isAutoQualityEnabled:t,trafficSavingEnabled:e,highQualityEnabled:i})=>{let o=!t&&!e&&!i;return{id:"quality-other-settings",type:"OPEN_SUB_MENU",label:Y("other_quality"),selected:o,valueComponent:Xl,valueComponentParams:{prefix:Y("other_quality"),selected:o},children:"quality-other-settings"}},gv=({appliesTo:t,labelWithQuality:e,selected:i},{selectQuality:o})=>({id:"quality-auto",type:"SELECT_VALUE",value:"auto",label:Y("auto_quality_limit"),valueComponent:e?Xl:void 0,valueComponentParams:{prefix:Y("auto_quality_limit"),selected:i},selectItem:()=>o("auto",t),selected:i}),Nb=()=>({id:"quality-appliance-settings",type:"OPEN_SUB_MENU",valueComponent:vv,bottomBordered:!0,children:"quality-appliance"}),hv=({labelWithQuality:t,appliesTo:e,selected:i},{toggleHighQuality:o})=>({id:"quality-high",type:"SELECT_VALUE",value:"high_quality",selectItem:()=>o(!0,e),selected:i,label:Y("high_quality"),valueComponent:t?Xl:void 0,valueComponentParams:{prefix:Y("high_quality"),selected:i},sublabel:Y("high_quality_description")}),_v=({labelWithQuality:t,appliesTo:e,selected:i},{toggleTrafficSaving:o})=>({id:"quality-traffic-saving",type:"SELECT_VALUE",value:"save_traffic",selectItem:()=>o(!0,e),selected:i,label:Y("traffic_saving_quality"),valueComponent:t?Xl:void 0,valueComponentParams:{prefix:Y("traffic_saving_quality"),selected:i},sublabel:Y("traffic_saving_quality_description")});var rp=(t,e)=>String(e.findIndex(i=>i.id===t.id)+1),sp=(t,e)=>{var l;if(!t)return"";let{language:i,label:o}=t,r;if(i==="und"?r=void 0:i&&(r=(l=ic(i))!=null?l:i),o&&i&&r){let d=e.filter(s=>s.label===o&&s.language===i);if(d.length===1)return Y("audio_stream_display_language_label",{language:r,label:o});{let s=rp(t,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=rp(t,d);return Y("audio_stream_display_label_index",{label:o,index:s})}}if(i&&r){let d=e.filter(s=>s.language===i);if(d.length===1)return r;{let s=rp(t,d);return Y("audio_stream_display_language_index",{language:r,index:s})}}let a=rp(t,e);return Y("audio_stream_display_unknown",{index:a})};var PC={"quality-settings":t=>{let{isAutoQualityEnabled:e,isAutoQualityAvailable:i,trafficSavingEnabled:o,highQualityEnabled:r}=t,a=[];return i&&a.push({handler:gv,selected:e&&!o&&!r||!1}),a.push({handler:_v,selected:o},{handler:hv,selected:r}),{title:Y("submenu_quality"),id:"quality-settings",items:[Nb(t),...a.map(({handler:l,selected:d})=>l({labelWithQuality:!0,appliesTo:"to-video",selected:d},t)),Rb(t)]}},"quality-other-settings":({closeSettingsMenu:t,selectQuality:e,availableQualities:i,isMobile:o})=>({id:"quality-other-settings",title:Y("submenu_quality"),closeSettingsMenu:t,items:i.map(r=>({type:"SELECT_VALUE",value:r.value,valueComponent:nl,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":t=>{var i,o,r;let{closeSettingsMenu:e}=t;return{id:"quality-appliance",title:Y("default_quality_for_any_video"),closeSettingsMenu:e,items:[{handler:gv,selected:((i=Tu())==null?void 0:i.type)==="auto_quality"},{handler:_v,selected:((o=Tu())==null?void 0:o.type)==="traffic_saving"},{handler:hv,selected:((r=Tu())==null?void 0:r.type)==="high_quality"}].map(({handler:a,selected:l})=>a({labelWithQuality:!1,appliesTo:"as-default",selected:l},t))}},"audio-tracks":({closeSettingsMenu:t,availableAudioStreams:e,currentAudioStream:i,selectAudioLanguage:o})=>({id:"audio-tracks",title:Y("submenu_audio_languages"),closeSettingsMenu:t,items:e.map(r=>({type:"SELECT_VALUE",value:r,dataValue:r.id,selectItem:o,selected:r.id===(i==null?void 0:i.id),label:sp(r,e)}))}),"playback-rate":({closeSettingsMenu:t,availablePlaybackRates:e,selectPlaybackRate:i})=>({id:"playback-rate",title:Y("submenu_playback_rate"),closeSettingsMenu:t,items:e.map(o=>({type:"SELECT_VALUE",value:o.value,selectItem:i,selected:o.selected,label:o.displayValue}))}),subtitles:({availableSubtitlesList:t,selectSubtitle:e})=>({id:"subtitles",minWidth:164,title:Y("subtitles_caption"),items:t.map(i=>({type:"SELECT_VALUE",value:i.value,selectItem:()=>e(i),selected:i.selected,label:i.displayValue,dataTestid:i.value===Rn?"sub_off":void 0}))})},Ob=({subMenuId:t,context:e})=>t?[PC[t](e)]:[];var kC=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 bv(t){Je(t,{testId:"traffic-saving-icon",children:(e,i)=>{var o=kC();$(e,o)},$$slots:{default:!0}})}var AC=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 $v(t){Je(t,{width:"18",height:"15",children:(e,i)=>{var o=AC();$(e,o)},$$slots:{default:!0}})}var LC=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 yv(t){Je(t,{testId:"play-speed-icon",children:(e,i)=>{var o=LC();$(e,o)},$$slots:{default:!0}})}var MC=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 xv(t){Je(t,{testId:"download-icon",children:(e,i)=>{var o=MC();$(e,o)},$$slots:{default:!0}})}var VC=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 wv(t){Je(t,{testId:"report-icon",children:(e,i)=>{var o=VC();$(e,o)},$$slots:{default:!0}})}var RC=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 ap(t){Je(t,{children:(e,i)=>{var o=RC();$(e,o)},$$slots:{default:!0}})}var NC=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 Sv(t){Je(t,{testId:"info-icon",children:(e,i)=>{var o=NC();$(e,o)},$$slots:{default:!0}})}var OC=L('<div class="menu-item-value-wrapper s-1w"><!></div>'),DC={hash:"s-1w",code:".menu-item-value-wrapper.s-1w{line-height:normal}"};function Cv(t,e){B(e,!0),Q(t,DC);let[i,o]=Oe(),r=()=>w(u,"$currentQuality$",i),a=()=>w(m,"$availableQualities$",i),l=()=>w(p,"$isAutoQualityEnabled$",i),d=()=>w(v,"$isMobile$",i),s=be(),u=s.state.currentQuality$,m=s.state.availableQualities$,p=s.state.isAutoQualityEnabled$,v=s.ui.isMobile,b=f(()=>Lb({quality:r(),availableQualities:a(),isAutoQualityEnabled:l()}));var y=OC(),_=C(y);nl(_,{get quality(){return r()},get label(){return n(b)},get isMobile(){return d()}}),S(y),$(t,y),H(),o()}var HC={"quality-settings":({isAutoQualityEnabled:t,currentQuality:e,qualityDetailsSubMenuEnabled:i})=>{let o=(t?Y("auto_quality_option"):e)||"";return{id:"quality-settings",type:"OPEN_SUB_MENU",ariaLabel:Y("aria_label_menu_quality",{actual:o}),icon:Gd,label:Y("menu_quality"),value:e,valueComponent:Cv,weight:rs["quality-settings"],children:i?"quality-settings":"quality-other-settings"}},"traffic-saving-switch":({trafficSavingEnabled:t,toggleTrafficSaving:e})=>({id:"traffic-saving-switch",weight:rs["traffic-saving-settings"],type:"SWITCH",onClick:i=>e(i,"to-video"),ariaLabel:Y("aria_label_submenu_traffic_saving"),icon:bv,label:Y("menu_traffic_saving"),enabled:t,tooltipText:Y("traffic_saving_helper_text"),maxTooltipWidth:175}),"audio-tracks-settings":({currentAudioStream:t,availableAudioStreams:e})=>{let i=sp(t,e);return{id:"audio-tracks-settings",weight:rs["audio-language-settings"],type:"OPEN_SUB_MENU",ariaLabel:Y("aria_label_menu_audio_languages",{actual:i}),icon:$v,label:Y("menu_audio_languages"),value:i,children:"audio-tracks"}},"playback-rate-settings":({availablePlaybackRates:t,currentPlaybackRate:e})=>{var o;let i=((o=t.find(r=>r.value===e))==null?void 0:o.displayValue)||"";return{id:"playback-rate-settings",weight:rs["playback-rate-settings"],type:"OPEN_SUB_MENU",ariaLabel:Y("aria_label_menu_rate",{actual:i}),icon:yv,label:Y("menu_playback_rate"),value:`${e}x`,children:"playback-rate"}},"subtitles-settings":({currentSubtitle:t})=>({id:"subtitles-settings",weight:rs["subtitles-settings"],type:"OPEN_SUB_MENU",ariaLabel:Y("aria_label_menu_subtitle",{actual:t.displayValue}),icon:ma,iconProps:{type:"outline"},label:Y("subtitles_caption"),value:t.displayValue,children:"subtitles"}),download:({onDownloadClick:t})=>({id:"download",weight:rs.download,type:"CLICK",onClick:t,label:Y("download_video_caption"),ariaLabel:Y("aria_label_menu_download"),icon:xv}),"show-support":({onReportProblemClick:t})=>({id:"show-support",weight:rs.report,type:"CLICK",onClick:t,label:Y("menu_report"),ariaLabel:`${Y("menu_report")}. ${Y("aria_label_new_tab_alert")}`,icon:wv,isHiddenFor:["desktop"]}),"copy-data":({onCopyDataClick:t})=>({id:"copy-data",weight:rs["copy-data"],type:"CLICK",onClick:t,label:Y("menu_copy_debug"),ariaLabel:Y("menu_copy_debug"),icon:ap,isHiddenFor:["desktop"]}),"save-trace-info":({onSaveTraceDataClick:t})=>({id:"save-trace-info",weight:rs["save-trace-info"],type:"CLICK",onClick:t,label:Y("menu_save_debug"),ariaLabel:Y("menu_save_debug"),icon:ap,isHiddenFor:["desktop"]}),"debug-info":({toggleShowDebugInfo:t})=>({id:"debug-info",weight:rs["debug-info"],type:"CLICK",onClick:t,ariaLabel:Y("aria_label_menu_debug_overlay"),label:Y("menu_debug_overlay"),icon:Sv,isHiddenFor:["desktop"]})},Db=({items:t,context:e,additionalSettingsMenuItems:i})=>{let{isMobile:o}=e;return[...t.map(r=>HC[r](e)),...i.map(r=>Kt(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(Wa)};var zC=(t,e)=>{Ou(t,e)},WC=L('<div><div> </div> <div class="close s-13" data-testid="close-settings-menu"></div></div>'),KC=L('<div data-testid="settings-menu" role="presentation"><!> <ul role="menu"></ul></div>'),qC=L("<div><!> <!></div>"),QC={hash:"s-13",code:'.settings-menu-container.mobile.s-13{width:100%;-webkit-touch-callout:none;-webkit-user-select:none;user-select:none}.settings-menu-container.s-13 ul{list-style-type:none;margin:0;padding:0}.settings-menu-container.s-13 .menu{background-color:var(--settings-bg);border-radius:var(--settings-radius);overflow:hidden;transition:opacity .2s,visibility .2s}.settings-menu-container.s-13 .menu .item:first-child:not(.mobile){border-top-left-radius:var(--settings-radius);border-top-right-radius:var(--settings-radius)}.settings-menu-container.s-13 .menu .item:last-child{border-bottom-left-radius:var(--settings-radius);border-bottom-right-radius:var(--settings-radius)}.settings-menu-container.s-13 .settings-menu .item:first-child:not(.mobile){padding-top:6px}.settings-menu-container.s-13 .settings-menu .item:last-child:not(.mobile){padding-bottom:6px}.settings-menu-container.s-13 .menu.desktop{bottom:0;max-width:100%;position:absolute;right:0}.settings-menu.s-13{line-height:40px}.settings-menu.desktop.s-13{min-width:300px}.settings-menu-container.s-13 .menu.mobile{background:var(--mobile-settings-bg);font-size:15px;line-height:50px;width:100%}.settings-menu-container.s-13 .menu.mobile.hidden{display:none}.settings-menu-container.s-13 .menu .item:not(.switch-item),.settings-menu-container.s-13 .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-13 .menu .item:hover{background-color:var(--settings-item-bg-hover)}.settings-menu-container.s-13 .menu .item.mobile:hover{background:var(--mobile-settings-bg)}.settings-menu.s-13 .item:not(.switch-item),.settings-menu.s-13 .switch-wrapper{padding:0 32px 0 18px}.settings-menu.s-13 .item.mobile:not(.switch-item),.settings-menu.s-13 .switch-wrapper.mobile{padding:0 14px}.settings-menu.s-13 .icon-wrapper{align-items:center;display:flex;height:24px;justify-content:center;margin-right:16px;min-width:24px;width:24px}.settings-menu.s-13 .label{flex-grow:1;margin-right:24px;overflow:hidden;text-overflow:ellipsis}.settings-menu.s-13 .item.header.mobile:where(.s-13){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-13 .items::-webkit-scrollbar{width:8px}.settings-menu-container.s-13 .items::-webkit-scrollbar-track{background-color:#3a3a3a;border-radius:4px;box-shadow:none}.settings-menu-container.s-13 .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-13 .items::-webkit-scrollbar-thumb:hover{background-color:#777}.settings-menu-container.s-13 .items.mobile{max-height:160px;overflow-x:hidden;overflow-y:auto;text-align:left}.close.s-13{height:12px;margin-right:-12px;padding:12px;position:relative;width:12px}.close.s-13:after,.close.s-13:before{background-color:var(--white);content:" ";height:12px;left:18px;position:absolute;width:2px}.close.s-13:before{transform:rotate(45deg)}.close.s-13:after{transform:rotate(-45deg)}'};function bc(t,e){B(e,!0),Q(t,QC);let[i,o]=Oe(),r=()=>w(He,"$settingsMenuVisible",i),a=()=>w(ot,"$settingsMenuOpenedByKeyboard",i),l=()=>w(Fe,"$debugPanelVisible",i),d=()=>w(ce,"$isMobile",i),s=()=>w(Te,"$playerSize",i),u=()=>w(xe,"$hasMpegSources$",i),m=()=>w(Ne,"$mobileNotReportControlHidden$",i),p=()=>w(ge,"$autoQualityLimitingAvailable$",i),v=()=>w(K,"$availableSubtitlesList$",i),b=()=>w(Le,"$isLiveWithPlaybackSpeed",i),y=()=>w(ee,"$availableAudioStreams$",i),_=()=>w(O,"$availablePlaybackRates$",i),x=()=>w(me,"$currentAudioStream$",i),I=()=>w(G,"$currentPlaybackRate$",i),T=()=>w(et,"$trafficSavingEnabled",i),R=()=>w(_e,"$currentQuality$",i),A=()=>w(pe,"$isAutoQualityEnabled$",i),P=()=>w(Ge,"$currentSubtitle$",i),E=()=>w(wt,"$additionalSettingsMenuItems$",i),z=()=>w(Qe,"$isAutoQualityAvailable$",i),F=()=>w(Ce,"$availableQualities$",i),U=()=>w(Ee,"$highQualityEnabled",i),X=h(e,"ref",15,void 0),ae=h(e,"playerControlsHeight",3,0),Z=li({}),re=li({}),J=be(),we=Vt(),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$,O=J.state.availablePlaybackRates$,Ge=J.state.currentSubtitle$,K=J.state.availableSubtitlesList$,se=J.state.canDownload,xe=J.state.hasMpegSources$,He=J.ui.settingsMenu.visible$,ot=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,It=J.state.isInteractiveTime$,wt=J.ui.additionalSettingsMenuItems$,Dt=J.ui.t,at=J.actions.internal.downloadVideo,Et=J.actions.internal.closeSettingsMenu,Zt=J.actions.internal.openSettingsSubMenu,Pt=J.actions.internal.closeSettingsSubMenu,Ot=q(!1),zt=q(void 0),j=Pb();De(()=>{!r()&&j.current&&(Pt(re[j.current]),j.popAllSubMenus())}),De(()=>{r()||N(zt,void 0)}),De(()=>{!j.current&&n(zt)&&z_(Z,n(zt))}),De(()=>{X()&&ne.set(X())});function Pe(_t){return gt(this,null,function*(){var W;j.pushSubMenu(_t),yield mo(),Zt(_t,re[_t]);let Bt=(W=X())==null?void 0:W.firstElementChild;Bt&&jf(Bt)})}function le(_t){var Bt;_t==null||_t.stopPropagation(),a()||(Bt=e.returnFocus)==null||Bt.call(e),Et(),N(Ot,!1)}function $e(_t,Bt){J.actions.internal.setQuality(_t,{appliesTo:Bt,byUser:!0}),le()}function Me(_t){J.actions.internal.setAudioStream(_t),le()}function dt(_t,Bt){J.actions.internal.setTrafficSavingEnabled(_t,Bt),we.features.qualityDetailsSubMenuEnabled&&le()}function St(_t,Bt){J.actions.internal.setHighQualityEnabled(_t,Bt),le()}function fe(_t){J.actions.internal.setPlaybackRate(_t),le()}function Ue(_t){J.actions.internal.setSubtitle(_t),le()}function ze(){at()}function Ct(){UC(e.supportLink)&&window.open(e.supportLink,"_blank"),J.actions.internal.reportProblem(),J.actions.internal.pause()}function si(){Ol(J.actions.internal.getDebugTextData())}let xt=()=>{let _t=J.actions.internal.getTraceTextData(),Bt=new Blob([..._t],{type:"application/json"}),W=window.URL.createObjectURL(Bt);Ba(W,"vk_player_trace_info","json")};function Yt(){Fe.set(!l())}function ci(){N(Ot,!0)}function Hi(){N(Ot,!1)}function Rt(){return d()?`max-height: ${Math.round(s().height*.6)}px`:`max-height: ${s().height-32-ae()}px; overflow: auto;`}let vo=f(()=>se&&u()&&!m()),fi=f(()=>we.features.trafficSaving&&!m()&&p()&&!we.features.qualityDetailsSubMenuEnabled),nt=f(()=>v().length>0&&!m()),jt=f(()=>!!b()&&!m()),Fi=f(()=>we.features.audioLanguages&&y().length>=2&&!m()),$i=f(()=>!m());Mt(()=>It.subscribe(_t=>{_t&&!d()&&!n(Ot)&&!a()&&le()}));let Jt=f(()=>{let _t=[n($i)&&"quality-settings",n(Fi)&&"audio-tracks-settings",n(jt)&&"playback-rate-settings",n(nt)&&"subtitles-settings",n(fi)&&"traffic-saving-switch",n(vo)&&"download",we.showSupport&&"show-support","copy-data",we.features.saveTraceInfoToFile&&"save-trace-info","debug-info"].filter(Bt=>!!Bt);return Db({items:_t,context:{qualityDetailsSubMenuEnabled:we.features.qualityDetailsSubMenuEnabled,availablePlaybackRates:_(),currentAudioStream:x(),availableAudioStreams:y(),currentPlaybackRate:I(),selectPlaybackRate:fe,trafficSavingEnabled:T(),toggleTrafficSaving:dt,currentQuality:R()||Bb.INVARIANT,isAutoQualityEnabled:A()||!1,currentSubtitle:P(),isMobile:d(),onDownloadClick:ze,onCopyDataClick:si,onReportProblemClick:Ct,onSaveTraceDataClick:xt,toggleShowDebugInfo:Yt},additionalSettingsMenuItems:E()})}),wi=f(()=>Ob({subMenuId:j.current,context:{availablePlaybackRates:_(),selectPlaybackRate:fe,trafficSavingEnabled:T(),toggleTrafficSaving:dt,currentQuality:R()||Bb.INVARIANT,isAutoQualityEnabled:A()||!1,isAutoQualityAvailable:z()||!1,availableQualities:F(),highQualityEnabled:U(),toggleHighQuality:St,availableAudioStreams:y(),availableSubtitlesList:v(),closeSettingsMenu:Et,currentAudioStream:x(),isMobile:d(),selectAudioLanguage:Me,selectQuality:$e,selectSubtitle:Ue}}));var st=qC();let lt;var _i=C(st);{var Xo=_t=>{var Bt=KC();let W;Bt.__keydown=[zC,Et];var Lt=C(Bt);{var ai=qt=>{var Ke=WC();let Ui;var Xi=C(Ke),Zo=C(Xi,!0);S(Xi);var tr=k(Xi,2);tr.__click=le,S(Ke),D((ro,Ei)=>{Ui=oe(Ke,1,"item header s-13",null,Ui,ro),ve(Zo,Ei)},[()=>({mobile:d()}),()=>Dt("submenu_settings")]),$(qt,Ke)};V(Lt,qt=>{d()&&qt(ai)})}var vt=k(Lt,2);let ti;bi(vt,21,()=>n(Jt),qt=>qt.id,(qt,Ke)=>{var Ui=Ve(),Xi=ue(Ui);{var Zo=ro=>{cv(ro,{get isMobile(){return d()},get id(){return n(Ke).id},get icon(){return n(Ke).icon},get iconProps(){return n(Ke).iconProps},get label(){return n(Ke).label},get ariaLabel(){return n(Ke).ariaLabel},get value(){return n(Ke).value},get valueComponent(){return n(Ke).valueComponent},onClick:()=>{Pe(n(Ke).children),N(zt,n(Ke).id,!0)},get ref(){return Z[n(Ke).id]},set ref(Ei){Z[n(Ke).id]=Ei}})},tr=(ro,Ei)=>{{var bo=$o=>{let Pi=f(()=>`${n(Ke).id}-menu-item`);uv($o,{get isMobile(){return d()},get id(){return n(Pi)},get onClick(){return n(Ke).onClick},get icon(){return n(Ke).icon},get label(){return n(Ke).label},get ariaLabel(){return n(Ke).ariaLabel},closeSettings:le})},Oo=($o,Pi)=>{{var yo=xo=>{let Jo=f(()=>`${n(Ke).id}-menu-item`);fv(xo,{get isMobile(){return d()},get id(){return n(Jo)},get onClick(){return n(Ke).onClick},get icon(){return n(Ke).icon},get label(){return n(Ke).label},get ariaLabel(){return n(Ke).ariaLabel},get enabled(){return n(Ke).enabled},get tooltipText(){return n(Ke).tooltipText},get maxTooltipWidth(){return n(Ke).maxTooltipWidth}})};V($o,xo=>{n(Ke).type==="SWITCH"&&xo(yo)},Pi)}};V(ro,$o=>{n(Ke).type==="CLICK"?$o(bo):$o(Oo,!1)},Ei)}};V(Xi,ro=>{n(Ke).type==="OPEN_SUB_MENU"?ro(Zo):ro(tr,!1)})}$(qt,Ui)}),S(vt),Ze(vt,qt=>X(qt),()=>X()),S(Bt),D((qt,Ke,Ui)=>{W=oe(Bt,1,"settings-menu menu s-13",null,W,qt),ti=oe(vt,1,"items",null,ti,Ke),qe(vt,Ui)},[()=>({desktop:!d(),mobile:d(),hidden:!!j.current}),()=>({mobile:d()}),Rt]),ut("mouseenter",Bt,ci),ut("mouseleave",Bt,Hi),$(_t,Bt)};V(_i,_t=>{r()&&_t(Xo)})}var No=k(_i,2);bi(No,17,()=>n(wi),_t=>_t.id,(_t,Bt)=>{let W=f(()=>{var Lt;return(Lt=n(Bt).minWidth)!=null?Lt:137});dv(_t,{get isMobile(){return d()},get playerControlsHeight(){return ae()},get returnFromSubMenu(){return j.popSubMenu},get id(){return n(Bt).id},get title(){return n(Bt).title},get closeSettingsMenu(){return Et},openSubMenuList:Pe,get items(){return n(Bt).items},get minWidth(){return n(W)},get refMenuItems(){return Z},get listRef(){return re[n(Bt).id]},set listRef(Lt){re[n(Bt).id]=Lt}})}),S(st),D(_t=>lt=oe(st,1,"settings-menu-container s-13",null,lt,_t),[()=>({mobile:d(),hidden:!r()})]),$(t,st),H(),o()}Ye(["keydown","click"]);var GC=L('<button class="btn s-1e"> </button>'),YC={hash:"s-1e",code:"button.btn.s-1e{background:hsla(0,0%,100%,.1);border-radius:8px;font-size:14px;line-height:18px;margin-top:12px;padding:6px 12px 7px}"};function Tv(t,e){Q(t,YC);var i=GC();i.__click=function(...r){var a;(a=e.onClick)==null||a.apply(this,r)};var o=C(i,!0);S(i),D(()=>ve(o,e.label)),$(t,i)}Ye(["click"]);var jC=L('<div class="container s-10"><div class="notification s-10"><div><p class="description s-10"><!></p> <!></div> <!></div></div>'),XC={hash:"s-10",code:".container.s-10{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-10{background:var(--notification-bg);border-radius:var(--notification-radius);display:inline-flex;gap:10px;padding:9px 14px 10px 12px;pointer-events:auto}.description.s-10{font-size:13px;line-height:16px;margin:0;white-space:pre}"};function $c(t,e){B(e,!0),Q(t,XC);let i=340,{features:{forceAutoQualityWhenSevereStallHappens:o}}=Vt(),{ui:{t:r}}=be(),a=r(o?"slow_video_notification_force_description":"slow_video_notification_suggest_description");var l=jC(),d=C(l),s=C(d),u=C(s),m=C(u);_c(m,{get message(){return a}}),S(u);var p=k(u,2);{var v=y=>{let _=f(()=>r("slow_video_notification_button"));Tv(y,{get label(){return n(_)},get onClick(){return e.onSelectAutoQuality}})};V(p,y=>{o||y(v)})}S(s);var b=k(s,2);Fs(b,{get onClick(){return e.onClose}}),S(d),S(l),is(3,d,()=>xs,()=>({duration:i})),$(t,l),H()}import{isIntersecting as Hb,Subscription as ZC}from"@vkontakte/videoplayer-shared/es2015";var rl="annotation",lp=class{constructor(e){this.slots=new Map;this.disabledIds=new Set(e)}init(e,i){this.shadowRootContainer=e,this.store=i}add(e,i){var s;let{overlay:o,id:r,controlsBehaviour:a,hideAllControls:l}=i;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",rl),this.setupSlotStyles(d,o),this.shadowRootContainer.append(d),this.slots.set(r,{rootElement:d,options:i}),a&&this.runHidingControlsWhenIntersected(r,a),l&&((s=this.store)==null||s.ui.isControlsAvailable.set(!1)),{success:!0}}setupSlotStyles(e,i){switch(e.style.position="absolute",i){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 gt(this,arguments,function*(e,{observedSlotElementId:i,controlsToObserve:o}){var v;let l=this.slots.get(e);if(!l)return;let d=yield this.findSlotElement(l.rootElement,i,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(Hb(I,y)))})}));m.observe(d,{childList:!0,subtree:!0}),l.observer=m;let p=new ZC;o.forEach(b=>{s&&p.add(s[b].subscribe(y=>{let _=u==null?void 0:u[b];y&&y.isDisplayed?_==null||_.set(Hb(y,zs(d,this.shadowRootContainer))):_==null||_.set(!1)}))}),l.subs=p})}findSlotElement(e,i,o){return gt(this,null,function*(){return new Promise(r=>{let a=null,l=new MutationObserver(()=>{if(a=e.querySelector(`#${i}`),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 i=this.slots.get(e);if(!i)return;let{rootElement:o,observer:r,observerForFindingSlotElement:a,subs:l,options:{controlsBehaviour:d,hideAllControls:s}}=i;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 JC=L('<div class="container s-4"><!></div>'),eT={hash:"s-4",code:".container.s-4{align-items:center;animation-fill-mode:forwards;animation-name:s-4-videoPlayerStatusIconPopup;background-color:#00000073;border-radius:100%;display:flex;height:64px;justify-content:center;width:64px;will-change:opacity,scale}@keyframes s-4-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 yc(t,e){B(e,!0),Q(t,eT);let i=h(e,"reversed",3,!1);var o=Ve(),r=ue(o);Os(r,()=>e.Icon,a=>{var l=JC(),d=C(l);Bi(d,()=>e.Icon,(s,u)=>{u(s,{get size(){return"48"},get reversed(){return i()}})}),S(l),D(()=>qe(l,`animation-duration: ${e.duration}ms`)),$(a,l)}),$(t,o),H()}import{PlaybackState as Fb}from"@vkontakte/videoplayer-core/es2015";var tT=L('<div class="container s-z"><!></div>'),iT={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 Iv(t,e){B(e,!0),Q(t,iT);let[i,o]=Oe(),r=()=>w(s,"$playbackState$",i),a=()=>w(m,"$previewTrackActive",i),l=()=>w(p,"$previewTrackDragInProgress",i),d=()=>w(u,"$isPlaying$",i),{state:{playbackState$:s,isPlaying$:u},ui:{previewTrackActive:m,previewTrackDragInProgress:p}}=be(),{features:{playbackStatusShow:v},playbackStatusAnimationDuration:b}=Vt(),y=0,_=q(null),x=q(!1);De(()=>{r()===Fb.PLAYING?N(_,Vn,!0):r()===Fb.PAUSED?N(_,qs,!0):N(_,null)}),De(()=>{if(!(!v||a()||l()))return y=window.setTimeout(()=>{y=0,N(_,null)},b),()=>{y&&(window.clearTimeout(y),y=0)}}),De(()=>{d()&&!n(x)&&(N(x,!0),N(_,null))});var I=Ve(),T=ue(I);{var R=A=>{var P=tT(),E=C(P);yc(E,{get duration(){return b},get Icon(){return n(_)}}),S(P),$(A,P)};V(T,A=>{n(_)&&v&&A(R)})}$(t,I),H(),o()}var oT=L('<div><div data-testid="video-container"></div></div>'),nT={hash:"s-e",code:".video-container.s-e,.video-wrapper.s-e{height:100%;left:0;position:absolute;top:0;width:100%}.video-wrapper.s-e{background:var(--black)}.video-container.s-e,.video-wrapper.s-e{z-index:var(--video-container-z-index)}.video-container.s-e{transition:var(--rotate-transition-duration) ease all}.video-container.fast-rotate.s-e{transition:none}.nocursor.s-e{cursor:none}"};function sl(t,e){B(e,!0),Q(t,nT);let[i,o]=Oe(),r=()=>w(p,"$rotateAlpha",i),a=()=>w(v,"$playerSize",i),l=()=>w(m,"$playerPhase",i),d=()=>w(y,"$chromecastConnected$",i),s=()=>w(b,"$isPlaying$",i),u=h(e,"videoContainer",15),{playerPhase:m,ui:{rotateAlpha:p,playerSize:v},state:{isPlaying$:b,chromecastConnected$:y}}=be(),{isSmoothVideoRotate:_}=Vt(),x=f(()=>u()&&r()%180?a().height/a().width:1);var I=oT();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;Ze(R,P=>u(P),()=>u()),S(I),D((P,E)=>{T=oe(I,1,"video-wrapper s-e",null,T,P),A=oe(R,1,"video-container s-e",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":!_})]),$(t,I),H(),o()}Ye(["contextmenu","mousedown","mouseup","click","dblclick"]);var rT=L('<div><span class="text s-12"> </span> <!></div>'),sT={hash:"s-12",code:".root.s-12{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-12,.root.visible.s-12{transform:translateX(-50%)}.root.visible.s-12{opacity:1;visibility:visible}.text.s-12{font-size:13px;font-weight:600;line-height:16px}"};function Ev(t,e){B(e,!0),Q(t,sT);let{ui:{t:i}}=be();var o=rT();let r;var a=C(o),l=C(a,!0);S(a);var d=k(a,2);fc(d,{get size(){return"16"},fill:"currentColor"}),S(o),D((s,u)=>{r=oe(o,1,"root s-12",null,r,s),ve(l,u)},[()=>({visible:e.isVisible}),()=>i("double_forward_label")]),$(t,o),H()}var aT=L('<div class="container s-11" role="button" data-testid="preview-track-overlay"><div class="icon s-11"><!></div></div>'),lT={hash:"s-11",code:".container.s-11{background-color:rgba(0,0,0,.48);cursor:pointer;height:100%;position:absolute;width:100%}.container.s-11,.icon.s-11{align-items:center;display:flex;justify-content:center}.icon.s-11{background-color:#00000073;border-radius:100%;height:64px;transition:transform .2s;transition-timing-function:ease-out;width:64px;will-change:transform}.container.s-11:hover .icon:where(.s-11){transform:scale(1.15)}"};function Pv(t,e){B(e,!1),Q(t,lT);let o=be().actions.internal.closePreviewTrack,r=200,a=u=>{u.stopPropagation(),o()};ho();var l=aT();l.__click=a;var d=C(l),s=C(d);return Vn(s,{get size(){return"32"}}),S(d),S(l),is(3,l,()=>xs,()=>({duration:r})),$(t,l),$f(e,"handleClick",a),H({handleClick:a})}Ye(["click"]);var dT=L('<div class="container s-w"><div class="notification s-w"><span class="text s-w"> </span></div></div>'),cT={hash:"s-w",code:".container.s-w{display:flex;justify-content:center;left:0;pointer-events:none;position:absolute;right:0;top:20px}.notification.s-w{background-color:var(--black-alpha-40);border-radius:var(--notification-radius);padding:10px 16px}.text.s-w{font-size:14px;font-weight:500;line-height:18px}"};function kv(t,e){B(e,!1),Q(t,cT);let{ui:{t:i}}=be();ho();var o=dT(),r=C(o),a=C(r),l=C(a,!0);S(a),S(r),S(o),D(d=>ve(l,d),[()=>i("preview_track_notification_text")],In),is(3,r,()=>xs,()=>({duration:340})),$(t,o),H()}var uT=(t,e,i,o,r,a)=>{if(t.stopPropagation(),e()||o()){a();return}},pT=L("<div><!></div>"),fT=L('<div class="spherical-video-icon s-8"><!></div>'),mT=L("<div><!></div>"),vT=L('<div class="settings-menu s-8"><!></div>'),gT=L("<!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!>",1),hT=L("<!> <!> <!>",1),_T=L('<div class="blocked s-8"></div>'),bT=L('<div class="player-wrapper s-8"><!> <div class="overlay-container"></div></div> <!>',1),$T={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 Av(t,e){B(e,!0),Q(t,$T);let[i,o]=Oe(),r=()=>w(nr,"$notificationsToShow$",i),a=()=>w(nt,"$playerPhase",i),l=()=>w(No,"$isLoaderVisible",i),d=()=>w(Rt,"$adPlaybackState",i),s=()=>w(ti,"$crashed",i),u=()=>w(Oo,"$isInteractiveTime$",i),m=()=>w(Jt,"$settingsMenuVisible",i),p=()=>w($o,"$isInteractiveExpectation$",i),v=()=>w($i,"$controlsVisible",i),b=()=>w(yo,"$touched",i),y=()=>w(zr,"$graphIsOpened$",i),_=()=>w(jt,"$isFullscreen",i),x=()=>w(mn,"$autoplayNextEnabled$",i),I=()=>w(Lt,"$postrollPassed",i),T=()=>w(_t,"$isEnded$",i),R=()=>w(Bn,"$cursorInside",i),A=()=>w(yr,"$isControlsAvailable",i),P=()=>w(en,"$doubleForwardOn$",i),E=()=>w(Ur,"$fakeIsPlaying$",i),z=()=>w(sr,"$bottomNoSmooth",i),F=()=>w(ss,"$interactiveTimeIndicator",i),U=()=>w(Zo,"$playerSize",i),X=()=>w(ro,"$is3DVideo",i),ae=()=>w(wr,"$doubleForwardAvailable$",i),Z=()=>w(_i,"$contextMenuVisible$",i),re=()=>w(Hi,"$playbackState$",i),J=()=>w(xo,"$hotKeyMapData",i),we=()=>w(st,"$scrubbingInProgress",i),me=()=>w(lt,"$volumeChangingInProgress",i),ee=()=>w(Bt,"$chromecastConnected$",i),_e=()=>w(on,"$controlsTimeoutActive",i),Ce=()=>w(tr,"$adsPlaybackState",i),ge=()=>w(wi,"$settingsMenuOpenedByKeyboard",i),pe=()=>w(Pr,"$contextMenuOpenedByKeyboard$",i),Qe=()=>w(Is,"$contextMenuOpenedByHotKey$",i),G=()=>w(sn,"$contextMenuButtonRef$",i),O=()=>w(kr,"$contextMenuLastActiveElem$",i),Ge=()=>w(Fi,"$isFullscreenOpenedByKeyboard",i),K=()=>w(Br,"$positionExact$",i),se=()=>w(ci,"$language$",i),xe=()=>w(Ys,"$previewTrackActive$",i),He=()=>w(Ei,"$icon3DVideoVisible",i),ot=()=>w(W,"$chromecastDeviceName$",i),ne=()=>w(Ui,"$currentSubtitle$",i),ce=()=>w(Xi,"$currentSubtitleCaptions$",i),Ne=()=>w(vo,"$position$",i),Le=()=>w(fi,"$duration$",i),et=()=>w(ai,"$isLive$",i),Ee=()=>w(vt,"$isPlaying$",i),Te=()=>w($r,"$contextMenuPosition$",i),Fe=()=>w(Sr,"$previewTrackNotificationVisible$",i),It=()=>w(Jo,"$showHotKeyMap",i),wt=()=>w(Xo,"$debugPanelVisible",i),Dt=()=>w(vn,"$userActionsDisabled$",i),at=h(e,"videoContainer",15),Et=h(e,"adsSlotId",3,void 0),Zt=h(e,"adsParams",3,void 0),Pt=h(e,"adsAutoplayParam",3,void 0),Ot=h(e,"duration",3,void 0),zt=h(e,"logoTargetUrl",3,""),j=h(e,"showNextPrevButtons",3,!1),Pe=h(e,"nextButtonActive",3,!1),le=h(e,"prevButtonActive",3,!1),$e=h(e,"endScreenVideoTitle",3,void 0),Me=h(e,"endScreenVideoThumb",3,void 0),dt=h(e,"isOneVideoPlaylist",3,!1),St=h(e,"shadowRootContainer",3,void 0),fe=h(e,"outerContainerRef",3,void 0),Ue=h(e,"playerStarted",3,!1),ze=h(e,"fullScreenTarget",3,void 0),Ct=h(e,"showMiniTimer",3,!1),si=h(e,"showEndScreen",3,!0),xt=h(e,"keyboardControls",15),Yt=e.store.getLogger().createComponentLog("Root component"),ci=e.store.interfaceLanguage$,Hi=e.store.state.playbackState$,Rt=e.store.ads.playbackState,vo=e.store.state.positionWithScrubbing$,fi=e.store.state.duration$,nt=e.store.playerPhase,jt=e.store.ui.isFullscreen,Fi=e.store.ui.isFullscreenOpenedByKeyboard,$i=e.store.ui.controlsVisible,Jt=e.store.ui.settingsMenu.visible$,wi=e.store.ui.settingsMenu.openedByBtnKeyboard$,st=e.store.ui.scrubbingInProgress,lt=e.store.ui.volumeChangingInProgress,_i=e.store.ui.contextMenu.visible$,Xo=e.store.ui.debugPanelVisible,No=e.store.state.isLoaderVisible,_t=e.store.state.isEnded$,Bt=e.store.state.chromecastConnected$,W=e.store.state.chromecastDeviceName$,Lt=e.store.ads.postrollPassed,ai=e.store.state.isLive$,vt=e.store.state.isPlaying$,ti=e.store.state.crashed$,qt=e.store.webApi.annotationsApi,Ke=e.store.webApi.pictureInPictureApi,Ui=e.store.state.currentSubtitle$,Xi=e.store.state.currentSubtitleCaptions$,Zo=e.store.ui.playerSize,tr=e.store.ads.playbackState,ro=e.store.ui.is3DVideo,Ei=e.store.ui.icon3DVideoVisible,bo=e.store.state.isInteractive,Oo=e.store.state.isInteractiveTime$,$o=e.store.state.isInteractiveExpectation$,Pi=e.store.state.hasInteractiveBranches,yo=e.store.ui.touched,xo=e.store.ui.modals.hotKeyMap.data,Jo=e.store.ui.modals.hotKeyMap.show,Br=e.store.state.positionExact$,Hr=e.store.ui.overlayContainer$,ss=e.store.ui.controls.interactiveTimeIndicator,ws=e.store.state.showInteractiveTimeIndicator,$r=e.store.ui.contextMenu.position$,ir=e.store.actions.internal.setQuality,Fr=e.store.actions.internal.closeSettingsMenu,mn=e.store.ui.autoplayNextEnabled$,vn=e.store.ui.userActionsDisabled,yr=e.store.ui.isControlsAvailable,xr=e.store.ui.videoTitleInfo,en=e.store.ui.doubleForwardOn$,wr=e.store.ui.doubleForwardAvailable$,Sr=e.store.ui.previewTrackNotificationVisible,Cr=e.store.actions.internal.getVideoElement,Nn=e.store.actions.internal.checkFullscreenSupport,{fakeIsPlaying$:Ur,notifications$:Ss,graphIsOpened$:zr}=_o(),Si=q(void 0),as=q(void 0),tn=q(void 0),pt=q(void 0),ei,On,or;xo.set(V_());let{closeNotification:Wr,notificationsToShow$:nr}=Ss,rr=f(()=>!!r().slow_video),Do=()=>Wr("slow_video"),Tr=f(()=>(a()==="video"&&l()||a()==="ads"&&d()==="inactive")&&!s()),Dn=q(void 0),sr=de(!1),ar,on=de(!1),gn=de(),Bn=de(!1),Mi=q(!1),Vi=q(!1),Bo=q(!1),Hn=q(!(e.autoplay&&!e.uiConfig.controls.showOnStartupAtAutoplay)),lr=f(()=>u()&&!m()&&!(n(Mi)||n(Vi))&&!(n(Bo)&&!p())),Fn=!0,Ir=f(()=>e.uiConfig.features.thumbTimer&&Ct()&&a()==="video"&&!v()&&!s()&&!bo&&(e.uiConfig.hideThumbTimerAfterTouch&&!b()||!e.uiConfig.hideThumbTimerAfterTouch)),ct=e.uiConfig.titleShowBehaviour,kt=f(()=>!["video","thumb"].includes(a())||ct==="never"||y()?!1:ct==="fullscreen"?_():!0),so=f(()=>ct==="always"||a()==="thumb"?!1:!v()),wo=q(!1),So=f(()=>(si()||e.showAutoplayNext&&x())&&!!$e()&&!!Me()&&(e.showAds&&I()||!e.showAds)&&T()&&!s()&&!n(wo)&&!Pi),hn=f(()=>R()&&!(v()||n(So))&&!u()&&A()&&!P()),ao=q(!1),_n=f(()=>E()!==null),{toggle:Zi}=Ur,bn=!1,Co=null;Ke==null||Ke.setContext(ad());let Cs=()=>{e.autoplay&&!bo&&e.uiConfig.controls.showOnStartupAtAutoplay&&zi(e.uiConfig.controls.hideTimeout)};e.store.setUiCallbacks({onStarted:Cs});let Kr=()=>{window.clearTimeout(ei),on.set(!1)},Ts=()=>{window.clearTimeout(On),gn.set(null)},zi=he=>{Kr(),on.set(!0),ei=window.setTimeout(()=>on.set(!1),he);let it=he-100;ar=window.setTimeout(()=>{z()&&sr.set(!1)},it>0?it:he)},qr=(he,it)=>{Ts(),gn.set(it),On=window.setTimeout(()=>gn.set(null),he)},Ho=ro.subscribe(he=>{Ei.set(he),he&&(window.clearTimeout(or),or=window.setTimeout(()=>Ei.set(!1),e.uiConfig.controls.hide360IconTimeout))}),Er=()=>gt(null,null,function*(){var it,vi,Ai,Sn;let he=da();if(he){let Po=Rd(),Ni=We();he=Po===Ni||Po===St()}if(he){zi(e.uiConfig.controls.hideTimeoutFullscreen);try{yield Ke==null?void 0:Ke.exit()}catch(Po){Yt({message:String(Po)})}}jt.set(he),e.store.getAdmanWrapper().setFullscreen(he),_()?(vi=(it=e.store.callbacks)==null?void 0:it.onFullscreenEnter)==null||vi.call(it):(Sn=(Ai=e.store.callbacks)==null?void 0:Ai.onFullscreenExit)==null||Sn.call(Ai)}),$n=he=>{let{width:it,height:vi}=he.target;Zo.set({width:it,height:vi})},Qr=()=>{let{width:he,height:it}=n(Si).getBoundingClientRect();Zo.set({width:he,height:it})};Mt(()=>{var it;return Ru(Er),e.uiConfig.features.annotationsInside&&(qt==null||qt.init(n(Si))),Ua(Ke)&&(Ke==null||Ke.assignPlayerContainer(n(Si)),Ke==null||Ke.setExternalEventHandlers({resize:$n,leavepictureinpicture:Qr})),e.interactiveContainer&&((it=at().parentElement)==null||it.insertBefore(e.interactiveContainer,at().nextSibling)),()=>{window.clearTimeout(ei),window.clearTimeout(ar),window.clearTimeout(On),window.clearTimeout(or),Ho(),Ke==null||Ke.dispose().catch(vi=>{Yt({message:String(vi)})}),Nu(Er)}});let We=()=>{let he=e.uiConfig.features.fullscreenInternalTargetPlayerContainer||!fe()?n(Si):fe(),it=he.getRootNode(),vi=it instanceof ShadowRoot?it.host:it,Ai=ze()instanceof HTMLElement&&ze().contains(vi);return e.uiConfig.allowChangingFullscreenTarget&&ze()&&Ai?ze():he},yt=()=>{_i.set(!1)},ui=()=>{Fr(),yt()},go=()=>gt(null,null,function*(){if(!Nn()){Yt({message:"fullscreen disabled"});return}yt(),da()?(yield Vu(document),Yt({message:"exit fullscreen"})):(Yt({message:"request fullscreen"}),yield Mu(We()))}),ki=he=>{y()||(he.preventDefault(),_i.set(!0),$r.set({left:he.clientX,top:he.clientY}))};function Fo(){Bn.set(!0),bo||zi(e.uiConfig.controls.hideTimeoutCursor)}function lo(he){var Po,Ni;let{relatedTarget:it}=he,Ai=!!(it&&((Po=n(tn))!=null&&Po.contains(it)))&&((Ni=xt())==null?void 0:Ni.isFocused()),Sn=e.uiConfig.controls.showOnStartupAtAutoplay||!!it;!bo&&!Ai&&Sn&&(sr.set(!0),zi(e.uiConfig.controls.hideTimeoutCursor))}function Uo(){Bn.set(!1),N(Vi,!1),N(Mi,!1),bn=!1,e.store.actions.internal.releaseCamera(),zi(e.uiConfig.controls.hideTimeout),P()&&zn()}function nn(he){return he?he.offsetTop+nn(he.offsetParent):0}function dr(he){return he?he.offsetLeft+dr(he.offsetParent):0}function To(he){if(F()&&ws){let it=he.currentTarget,vi=nn(it),Ai=dr(it),Sn=he.pageX-Ai,Po=he.pageY-vi,{left:Ni,bottom:Kn,right:As}=F(),Gr=As-Ni;return Sn>=Ni-Gr&&Po<=Kn+Gr}}function rn(he){if(n(Si)){let it=nn(he.currentTarget),vi=U().height,Ai=he.pageY-it;if(To(he)){N(Vi,!1);return}Ai<40?N(Vi,!0):Ai>vi-40?N(Mi,!0):(N(Vi,!1),m()||N(Mi,!1))}}function Un(he){rn(he),!n(lr)&&!P()&&zi(e.uiConfig.controls.hideTimeoutCursor),X()&&bn&&Co&&e.store.actions.internal.moveCameraFocusPX(Co.clientX-he.clientX,Co.clientY-he.clientY,he.timeStamp-Co.timeStamp),Co=he}let Io=null,yn=()=>{Io=window.setTimeout(()=>{e.store.actions.internal.changeDoubleForwardOn(!0),Kr()},e.uiConfig.doubleForwardActivationTime)},zn=()=>{e.store.actions.internal.changeDoubleForwardOn(!1),Io&&clearTimeout(Io),Io=null},ls=he=>{he.preventDefault(),he.button===0&&(bn=!0,e.store.actions.internal.holdCamera(),ae()&&yn()),!bn&&zi(e.uiConfig.controls.hideTimeoutCursor)},cr=he=>{he.preventDefault(),he.button===0&&(Co=he,bn=!1,e.store.actions.internal.releaseCamera()),!P()&&zi(e.uiConfig.controls.hideTimeoutCursor)},je=he=>{he.preventDefault(),Fn&&(Yt({message:"double click on video"}),go(),zi(e.uiConfig.controls.hideTimeoutCursor))},Xt=he=>{var it;if(he.preventDefault(),P()){zn();return}if(Io&&zn(),Z()||m()){ui();return}if(!(T()&&!Pi)){if(n(_n))return Zi();if((it=xt())==null||it.focus(),!Ue()){e.firstStart(),zi(e.uiConfig.controls.hideTimeoutCursor);return}(!e.uiConfig.preventPauseOnVideoClick||re()!==zb.PLAYING)&&e.store.actions.internal.togglePlay(),zi(e.uiConfig.controls.hideTimeoutCursor)}},yi=he=>{ui(),yo.set(!0),zi(e.uiConfig.controls.hideTimeout),he&&qr(e.uiConfig.controls.hideHotKeyHelpers,he)},zo=()=>{var he,it;ui(),(he=e.store.callbacks)!=null&&he.onOpenHotKeyMap?(it=e.store.callbacks)==null||it.onOpenHotKeyMap(J()):Jo.update(vi=>!vi)},xn=()=>{yo.set(!0)},Pr=e.store.ui.contextMenu.openedByBtnKeyboard$,sn=e.store.ui.contextMenu.btnRef$,an=q(void 0),Is=e.store.ui.contextMenu.openedByHotKey$,kr=e.store.ui.contextMenu.lastActiveElem$,Es=q(!1),Ys=e.store.ui.previewTrackActive;De(()=>{Hr.set(n(Dn))}),De(()=>{N(Bo,n(Hn)&&re()!==zb.PLAYING,!0),n(Hn)||Tt(()=>N(Hn,!0))}),De(()=>{var it,vi;let he=(n(Bo)||T()||m()||we()||me()||ee()||_e()||n(Es))&&!n(lr)&&(a()==="video"||a()==="ads"&&(e.uiConfig.controls.showOnStartupAtAutoplay||Ce()!=="inactive"))&&!s()&&A();$i.set(he),!he&&!_e()&&((it=n(tn))!=null&&it.contains(zu()))&&((vi=xt())==null||vi.focus())}),De(()=>{!we()&&n(ao)&&!u()&&zi(e.uiConfig.controls.hideTimeoutCursor),Tt(()=>N(ao,we(),!0))}),De(()=>{n(pt),m(),ge(),Tt(()=>Ud(n(pt),m(),ge()))}),De(()=>{n(an),Z(),pe(),Qe(),Tt(()=>{let he=pe()||Qe();Ud(n(an),Z(),he)})}),De(()=>{let he=G();he&&(Z(),Tt(()=>Dl(he,Z(),Pr)))}),De(()=>{let he=O();he&&(Z(),Tt(()=>U_(he,Z(),Is)))}),De(()=>{var he;!Ge()&&_()&&(Tt(()=>Fi.set(!1)),(he=xt())==null||he.focus())}),De(()=>{y()&&ui()});let Ps=q(void 0),ft=he=>{xr.set(Jn(Cr(),{title:n(Ps)},"title",he))},pi=(he,it)=>{var Po,Ni;let vi=(Ni=(Po=e.store.callbacks)==null?void 0:Po.uiInfo)==null?void 0:Ni.onUpcomingLiveViewStateChanged;if(!vi)return;let Ai=!!it,Sn=ke(ke({},Jn(n(Si),{upcomingLiveScreen:it},"upcomingLiveScreen",Ai)),he);vi(Sn)},Eo="",co=f(()=>{var he;return n(so)?Eo:(he=e.getVideoDeeplink)==null?void 0:he.call(e,K())});De(()=>{Eo=n(co)});var wn=bT();ut("blur",Aa,ui);var Ri=ue(wn);Ri.__mousemove=Un;var ds=C(Ri);let ks=f(()=>a()==="ads"),Wi=f(()=>n(_n)?Zi:void 0);Ze(im(ds,{startDoubleForwardActivationTimer:yn,stopDoubleForward:zn,toggleFullscreen:go,hideContextMenu:ui,showHotKeyHelpers:yi,showKeyMap:zo,get isAds(){return n(ks)},get fakePlayButtonHandler(){return n(Wi)},get nextButtonActive(){return Pe()},get prevButtonActive(){return le()},children:(he,it)=>{var vi=hT(),Ai=ue(vi);sl(Ai,{get hideCursor(){return n(hn)},onClick:Xt,onContextMenu:ki,onMouseDown:ls,onMouseUp:cr,onDblClick:je,get videoContainer(){return at()},set videoContainer(Ni){at(Ni)}});var Sn=k(Ai,2);Oa(Sn,()=>"slot",!1,(Ni,Kn)=>{io(Ni,()=>({name:rl}))});var Po=k(Sn,2);Os(Po,se,Ni=>{var Kn=gT(),As=ue(Kn);let Gr=f(()=>a()!=="thumb"||s()||bo&&e.autoplay);il(As,{get hidden(){return n(Gr)},get thumbUrl(){return e.thumbUrl},get startVideo(){return e.firstStart},onContextMenu:ki,onClick:yt});var ha=k(As,2);{var cs=Be=>{Pv(Be,{})};V(ha,Be=>{xe()&&Be(cs)})}var Cn=k(ha,2);Iv(Cn,{});var _a=k(Cn,2);Ev(_a,{get isVisible(){return P()}});var ba=k(_a,2);{var Yr=Be=>{let hi=f(()=>{var Ao;return(Ao=e.live)==null?void 0:Ao.startTime});gc(Be,{get thumbUrl(){return e.thumbUrl},get startTime(){return n(hi)},onUpcomingLiveViewStateChanged:pi,onContextMenu:ki,onClick:yt})};V(ba,Be=>{a()==="LiveWaitingStart"&&Be(Yr)})}var al=k(ba,2);{var ed=Be=>{ol(Be,{kind:"recover",get thumbUrl(){return e.thumbUrl},onContextMenu:ki,onClick:yt})};V(al,Be=>{a()==="LiveWaitingRecover"&&Be(ed)})}var $a=k(al,2);{var td=Be=>{ol(Be,{kind:"record",get thumbUrl(){return e.thumbUrl},onContextMenu:ki,onClick:yt})};V($a,Be=>{a()==="LiveWaitingRecord"&&Be(td)})}var ll=k($a,2);{var dl=Be=>{var hi=pT();let Ao;var Lr=C(hi);Od(Lr,{get adsSlotId(){return Et()},get adsParams(){return Zt()},get adsAutoplayParam(){return Pt()},get duration(){return Ot()},get adsExternalApi(){return e.adsExternalApi},get adsJson(){return e.adsJson}}),S(hi),D(Tn=>Ao=oe(hi,1,"ads-container s-8",null,Ao,Tn),[()=>({hidden:a()!=="ads"})]),$(Be,hi)};V(ll,Be=>{e.showAds&&Ue()&&Be(dl)})}var ya=k(ll,2);{var mt=Be=>{let hi=f(()=>!si()&&e.showAutoplayNext&&x());Jf(Be,{get title(){return $e()},get thumb(){return Me()},get isHide(){return n(hi)},clickCloseIcon:()=>N(wo,!0)})};V(ya,Be=>{n(So)&&$e()&&Me()&&Be(mt)})}var rt=k(ya,2);{var Ji=Be=>{let hi=f(()=>_()?"md":"sm"),Ao=f(()=>{var Lr;return(Lr=e.store.callbacks)==null?void 0:Lr.onTitleClicked});ov(Be,{get title(){return e.title},get isHidden(){return n(so)},onVisibilityChanged:ft,get titleLinkHref(){return n(co)},onMouseEnter:()=>{N(Es,!0)},onMouseLeave:()=>{N(Es,!1)},get size(){return n(hi)},get onTitleClicked(){return n(Ao)},get ref(){return n(Ps)},set ref(Lr){N(Ps,Lr,!0)}})};V(rt,Be=>{n(kt)&&Be(Ji)})}var ko=k(rt,2);{var eo=Be=>{let hi=f(()=>a()==="video"&&v());mc(Be,{get isShifted(){return n(hi)}})};V(ko,Be=>{X()&&Be(eo)})}var gi=k(ko,2);{var Ki=Be=>{var hi=fT(),Ao=C(hi);Vd(Ao,{}),S(hi),$(Be,hi)};V(gi,Be=>{He()&&Be(Ki)})}var js=k(gi,2);{var id=Be=>{vc(Be,{get thumbUrl(){return e.thumbUrl},get chromecastDeviceName(){return ot()},onClick:Xt,onContextMenu:ki,onDblClick:je})};V(js,Be=>{ee()&&Be(id)})}var Mc=k(js,2);{var yp=Be=>{el(Be,{get shifted(){return v()},get captions(){return ce()},get position(){return Ne()},get playerSize(){return U()}})};V(Mc,Be=>{ne().value!=="off"&&Be(yp)})}var Vc=k(Mc,2);{var xp=Be=>{var hi=mT();hi.__contextmenu=ki,hi.__click=[uT,Z,_i,m,Jt,ui];var Ao=C(hi);tl(Ao,{}),S(hi),$(Be,hi)};V(Vc,Be=>{s()&&Be(xp)})}var Rc=k(Vc,2);{var wp=Be=>{let hi=f(()=>a()==="thumb"||a()==="LiveWaitingStart"||a()==="LiveWaitingRecover"||a()==="LiveWaitingRecord"),Ao=f(()=>a()==="ads"),Lr=f(()=>e.canRewindLive&&Le()!==0);pc(Be,{get bottomHidden(){return n(hi)},get bottomNoSmooth(){return z()},get showControls(){return v()},get isAds(){return n(Ao)},get canRewindLive(){return n(Lr)},get logoClickable(){return e.logoClickable},get logoHidden(){return e.logoHidden},get logoTargetUrl(){return zt()},get showAutoplayNext(){return e.showAutoplayNext},get showNextPrevButtons(){return j()},get nextButtonActive(){return Pe()},get prevButtonActive(){return le()},get isOneVideoPlaylist(){return dt()},customFullscreenSupported:Fn,toggleFullscreen:go,get seekToInteractive(){return e.seekToInteractive},get playPrevChapter(){return e.playPrevChapter},get playerControlsWrapperRef(){return n(as)},set playerControlsWrapperRef(Tn){N(as,Tn,!0)},get playerControlsRef(){return n(tn)},set playerControlsRef(Tn){N(tn,Tn,!0)}})};V(Rc,Be=>{Ue()&&Be(wp)})}var Nc=k(Rc,2);{var Sp=Be=>{var hi=vT(),Ao=C(hi);let Lr=f(()=>{var Tn;return(Tn=n(tn))==null?void 0:Tn.clientHeight});bc(Ao,{get supportLink(){return e.supportLink},get playerControlsHeight(){return n(Lr)},returnFocus:()=>{var Tn;return(Tn=xt())==null?void 0:Tn.focus()},get ref(){return n(pt)},set ref(Tn){N(pt,Tn,!0)}}),S(hi),$(Be,hi)};V(Nc,Be=>{!ee()&&a()!=="ads"&&Be(Sp)})}var xa=k(Nc,2);let Cp=f(()=>!n(Ir));Hd(xa,{get isLive(){return et()},get isHidden(){return n(Cp)},get isPlaying(){return Ee()},get position(){return Ne()},get duration(){return Le()}});var Xs=k(xa,2);tv(Xs,{get data(){return gn}});var wa=k(Xs,2);Zf(wa,{get supportLink(){return e.supportLink},returnFocus:()=>{var Be;return(Be=xt())==null?void 0:Be.focus()},get visible(){return Z()},get playerContainerRef(){return n(Si)},get position(){return Te()},get menuElementRef(){return n(an)},set menuElementRef(Be){N(an,Be,!0)}});var Oc=k(wa,2);{var Dc=Be=>{$c(Be,{onClose:Do,onSelectAutoQuality:()=>{ir("auto"),Do()}})};V(Oc,Be=>{n(rr)&&Be(Dc)})}var cl=k(Oc,2);{var Bc=Be=>{kv(Be,{})};V(cl,Be=>{Fe()&&Be(Bc)})}var Hc=k(cl,2);{var Fc=Be=>{qa(Be,{})};V(Hc,Be=>{n(Tr)&&Be(Fc)})}var Uc=k(Hc,2);{var Tp=Be=>{rm(Be,{})};V(Uc,Be=>{It()&&Be(Tp)})}var Ip=k(Uc,2);{var Ep=Be=>{Kd(Be,{})};V(Ip,Be=>{wt()&&Be(Ep)})}$(Ni,Kn)}),$(he,vi)},$$slots:{default:!0}}),he=>xt(he),()=>xt());var Ii=k(ds,2);Ze(Ii,he=>N(Dn,he),()=>n(Dn)),S(Ri),Ze(Ri,he=>N(Si,he),()=>n(Si));var Wn=k(Ri,2);{var Ar=he=>{var it=_T();$(he,it)};V(Wn,he=>{Dt()&&he(Ar)})}ut("mouseenter",Ri,Fo),ut("mouseleave",Ri,Uo),ut("click",Ri,xn,!0),ut("focusin",Ri,lo,!0),$(t,wn),H(),o()}Ye(["mousemove","contextmenu","click"]);import{clientChecker as xc,PlaybackState as kT}from"@vkontakte/videoplayer-core/es2015";import{noop as AT}from"@vkontakte/videoplayer-shared/es2015";var yT=L('<div></div> <div class="info s-14"><div class="triangles-wrapper s-14"><div></div> <div></div> <div></div></div> <p class="step-caption s-14"> </p></div>',1),xT=L("<div><!></div>"),wT={hash:"s-14",code:".double-click-area.s-14{height:100%;overflow:hidden;position:absolute;top:0;width:25%}.double-click-area.left.s-14{left:0}.double-click-area.right.s-14{right:0}.semicircle.s-14{background-color:rgba(0,0,0,.5);height:100%;position:absolute;top:0;width:100%}.semicircle.left.s-14{border-bottom-right-radius:50%;border-top-right-radius:50%;left:0}.semicircle.right.s-14{border-bottom-left-radius:50%;border-top-left-radius:50%;right:0}.info.s-14{align-items:center;flex-direction:column;left:50%;position:absolute;top:50%;transform:translate(-50%,-50%)}.info.s-14,.triangles-wrapper.s-14{display:flex;justify-content:center}.triangles-wrapper.s-14{margin-bottom:10px;position:relative}.triangle.s-14{animation:s-14-blink .5s infinite;border-bottom:6px solid transparent;border-top:6px solid transparent;height:0;opacity:0;width:0}.triangle.left.s-14:nth-child(3),.triangle.right.s-14:first-child{animation-delay:0s}.triangle.left.s-14:nth-child(2),.triangle.right.s-14:nth-child(2){animation-delay:.1s}.triangle.left.s-14:first-child,.triangle.right.s-14:nth-child(3){animation-delay:.2s}@keyframes s-14-blink{0%{opacity:0}50%{opacity:1}to{opacity:0}}.triangle.left.s-14{border-right:8px solid var(--white)}.triangle.right.s-14{border-left:8px solid var(--white)}.triangle.s-14:not(:last-child){margin-right:5px}.step-caption.s-14{color:var(--white);font-size:12px;line-height:1;margin:0;text-align:center}"};function dp(t,e){B(e,!0),Q(t,wT);let i=h(e,"seekStep",3,0),o=q(!1),r=0,a=0,l=q(li(i())),d=p=>{p.stopPropagation(),a+=1,N(l,i()*(a-1)),a===1?e.handleSingleFirstClick(p):(N(o,!0),e.handleSecondClick()),window.clearTimeout(r),r=window.setTimeout(()=>{a=0,N(o,!1)},300)};cn(()=>{window.clearTimeout(r)});var s=xT();s.__click=d;var u=C(s);{var m=p=>{var v=yT(),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),D(P=>{var E,z,F,U;oe(b,1,`semicircle ${(E=e.side)!=null?E:""}`,"s-14"),oe(x,1,`triangle ${(z=e.side)!=null?z:""}`,"s-14"),oe(I,1,`triangle ${(F=e.side)!=null?F:""}`,"s-14"),oe(T,1,`triangle ${(U=e.side)!=null?U:""}`,"s-14"),ve(A,P)},[()=>Y("doubletap_seek_step",{seconds:n(l).toFixed(0)})]),$(p,v)};V(u,p=>{n(o)&&p(m)})}S(s),D(()=>{var p;return oe(s,1,`double-click-area ${(p=e.side)!=null?p:""}`,"s-14")}),$(t,s),H()}Ye(["click"]);var ST=(t,e,i)=>{e(!1),i()},CT=L('<div class="overlay s-15"></div> <div class="next-video s-15"><div class="top s-15"><div class="caption s-15"> </div> <!></div> <div class="row s-15"><div class="column s-15"><div class="thumb s-15"><div></div> <!></div></div> <div class="column s-15"><div class="title s-15"> </div></div></div></div>',1),TT={hash:"s-15",code:".overlay.s-15{background:rgba(0,0,0,.72);height:100%;position:absolute;width:100%}.next-video.s-15{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-15{display:flex;justify-content:space-between}.caption.s-15{color:var(--white);font-size:11px;font-weight:700;opacity:.8;text-transform:uppercase}.row.s-15{background:rgba(48,48,48,.8);cursor:pointer;display:flex;flex-direction:row;height:102px;margin-top:6px;width:100%}.column.s-15{display:flex;flex-basis:50%;flex-direction:column}.thumb.s-15{align-items:center;background:no-repeat 50%;background-size:cover;display:flex;justify-content:space-around;position:relative}.thumb.s-15,.thumb-overlay.s-15{height:100%;width:100%}.thumb-overlay.s-15{position:absolute}.thumb-overlay.withOpacity.s-15{background:var(--black);opacity:.3}.title.s-15{color:var(--white);font-size:12px;font-weight:700;line-height:1.6;max-height:52px;overflow:hidden;padding:10px 16px}"};function Lv(t,e){B(e,!0),Q(t,TT);let[i,o]=Oe(),r=()=>w(d,"$autoplayNextEnabled$",i),a=()=>w(s,"$timerNextVideoRunning$",i),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()};Mt(()=>{e.isHide||m(),e.isHide&&r()&&(u(!1),v())});var x=Ve(),I=ue(x);{var T=R=>{var A=CT(),P=k(ue(A),2),E=C(P),z=C(E),F=C(z,!0);S(z);var U=k(z,2);Fs(U,{onClick:_}),S(E);var X=k(E,2);X.__click=[ST,u,p];var ae=C(X),Z=C(ae),re=C(Z);let J;var we=k(re,2);{var me=ge=>{qd(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),D((ge,pe)=>{ve(F,ge),qe(Z,`background-image: url('${e.thumb}')`),J=oe(re,1,"thumb-overlay s-15",null,J,pe),ve(Ce,e.title)},[()=>r()?Y("end_screen_next_video"):Y("end_screen_recommended_video"),()=>({withOpacity:r()})]),$(R,A)};V(I,R=>{e.isHide||R(T)})}$(t,x),H(),o()}Ye(["click"]);import{clientChecker as IT}from"@vkontakte/videoplayer-core/es2015";var Wb=({getFullscreenTarget:t,fullScreenChangeHandler:e})=>{let i=null,o;Mt(()=>{IT.device.isIOS&&(o=setTimeout(()=>{let a=t().querySelector("video");if(!a)return;let l=()=>e(!0),d=()=>e(!1);a.addEventListener("webkitbeginfullscreen",l),a.addEventListener("webkitendfullscreen",d),i=()=>{a.removeEventListener("webkitbeginfullscreen",l),a.removeEventListener("webkitendfullscreen",d)}},0))}),cn(()=>{i==null||i(),clearTimeout(o)})};import{VideoFormat as ET}from"@vkontakte/videoplayer-core/es2015";var cp=class{constructor(e){this.video=e}getTracksArray(){return Array.from(this.video.getElementsByTagName("track"))}attach(e,i=!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),i&&(o.track.mode="showing"),this.video.appendChild(o)}detachAll(){for(let e of this.getTracksArray())this.video.removeChild(e)}updateSrc(e){let i=this.getTracksArray().find(o=>o.id===e.id);i&&(i.src=e.url)}getCurrentShowingId(){var e,i;return(i=(e=this.getTracksArray().find(o=>o.track.mode==="showing"))==null?void 0:e.id)!=null?i:null}};import{clientChecker as PT}from"@vkontakte/videoplayer-core/es2015";var Kb=({store:t,getFullscreenTarget:e})=>{let{isFullscreen:i}=t.ui,{setSubtitle:o}=t.actions.internal,{currentSubtitle$:r,availableSubtitlesList$:a,currentFormat$:l,availableTextTracks$:d}=t.state,s=null,u=()=>e().querySelector("video"),m=()=>PT.device.isIOS&&ye(l)===ET.DASH_LIVE_CMAF,p=()=>{s==null||s(),s=null},v=b=>{if(p(),!m()||!b)return;let y=u();if(!y)return;let _=new cp(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)}};Mt(()=>i.subscribe(v)),cn(p)};var LT=(t,e,i,o)=>{if(t.stopPropagation(),e()){o();return}},MT=L("<!> <!>",1),VT=L("<div><!></div>"),RT=L('<div class="spherical-video-icon s-9"><!></div>'),NT=L("<div><!></div>"),OT=L('<div class="settings-mobile s-9"><!></div>'),DT=L("<!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!>",1),BT=L('<div class="player-wrapper s-9" role="region" tabindex="-1"><!> <!> <!> <div class="overlay-container"></div></div>'),HT={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 Mv(t,e){var Fn,Ir;B(e,!0),Q(t,HT);let[i,o]=Oe(),r=()=>w(Me,"$playerPhase",i),a=()=>w(ci,"$isLoaderVisible",i),l=()=>w(Pe,"$adPlaybackState",i),d=()=>w(Jt,"$crashed",i),s=()=>w(ws,"$notificationsToShow$",i),u=()=>w(j,"$playbackState$",i),m=()=>w(Pt,"$graphIsOpened$",i),p=()=>w(Ue,"$interactiveHideMobileControls",i),v=()=>w(Hi,"$isEnded$",i),b=()=>w(vt,"$isInteractiveExpectation$",i),y=()=>w(St,"$controlsVisible",i),_=()=>w(Ke,"$touched",i),x=()=>w(Xi,"$autoplayNextEnabled$",i),I=()=>w(fi,"$postrollPassed",i),T=()=>w(Fr,"$bottomNoSmooth",i),R=()=>w(lt,"$videoSize",i),A=()=>w(_t,"$playerSize",i),P=()=>w(dt,"$isFullscreen",i),E=()=>w(le,"$position$",i),z=()=>w($e,"$duration$",i),F=()=>w(Zo,"$loadedMetadata",i),U=()=>w(ze,"$settingsMenuVisible",i),X=()=>w(si,"$scrubbingInProgress",i),ae=()=>w(xt,"$volumeChangingInProgress",i),Z=()=>w(Rt,"$chromecastConnected$",i),re=()=>w(fe,"$isControlsAvailable",i),J=()=>w(ai,"$isInteractiveTime$",i),we=()=>w(Fi,"$isActiveLive",i),me=()=>w(Ct,"$settingsMenuOpenedByKeyboard",i),ee=()=>w(zt,"$language$",i),_e=()=>w(qt,"$disabledControls$",i),Ce=()=>w(Bt,"$is3DVideo",i),ge=()=>w(W,"$icon3DVideoVisible",i),pe=()=>w(vo,"$chromecastDeviceName$",i),Qe=()=>w(_i,"$currentSubtitle$",i),G=()=>w(Xo,"$currentSubtitleCaptions$",i),O=()=>w(No,"$realDuration$",i),Ge=()=>w(nt,"$isLive$",i),K=()=>w(jt,"$isPlaying$",i),se=()=>w(Yt,"$debugPanelVisible",i),xe=h(e,"videoContainer",15),He=h(e,"adsSlotId",3,void 0),ot=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),It=h(e,"isOneVideoPlaylist",3,!1),wt=h(e,"showMiniTimer",3,!1),Dt=h(e,"fullScreenTarget",3,void 0),at=h(e,"playerStarted",3,!1),Et=h(e,"showEndScreen",3,!0),{notifications$:Zt,graphIsOpened$:Pt}=_o(),Ot=e.store.getLogger().createComponentLog("Root component"),zt=e.store.interfaceLanguage$,j=e.store.state.playbackState$,Pe=e.store.ads.playbackState,le=e.store.state.positionWithScrubbing$,$e=e.store.state.duration$,Me=e.store.playerPhase,dt=e.store.ui.isFullscreen,St=e.store.ui.controlsVisible,fe=e.store.ui.isControlsAvailable,Ue=e.store.ui.interactiveHideMobileControls,ze=e.store.ui.settingsMenu.visible$,Ct=e.store.ui.settingsMenu.openedByBtnKeyboard$,si=e.store.ui.scrubbingInProgress,xt=e.store.ui.volumeChangingInProgress,Yt=e.store.ui.debugPanelVisible,ci=e.store.state.isLoaderVisible,Hi=e.store.state.isEnded$,Rt=e.store.state.chromecastConnected$,vo=e.store.state.chromecastDeviceName$,fi=e.store.ads.postrollPassed,nt=e.store.state.isLive$,jt=e.store.state.isPlaying$,Fi=e.store.state.isActiveLive$,$i=e.store.state.isRewindableLive$,Jt=e.store.state.crashed$,wi=e.store.webApi.annotationsApi,st=e.store.webApi.pictureInPictureApi,lt=e.store.state.videoSize$,_i=e.store.state.currentSubtitle$,Xo=e.store.state.currentSubtitleCaptions$,No=e.store.state.duration$,_t=e.store.ui.playerSize,Bt=e.store.ui.is3DVideo,W=e.store.ui.icon3DVideoVisible,Lt=e.store.state.isInteractive,ai=e.store.state.isInteractiveTime$,vt=e.store.state.isInteractiveExpectation$,ti=e.store.state.hasInteractiveBranches,qt=e.store.ui.controls.disabledControls$,Ke=e.store.ui.touched,Ui=e.store.ui.overlayContainer$,Xi=e.store.ui.autoplayNextEnabled$,Zo=e.store.state.loadedMetadata$,tr=e.store.actions.internal.closeSettingsMenu,ro=(Fn=e.store.callbacks)==null?void 0:Fn.onDisabledPlayPrevChapterClick,Ei=(Ir=e.store.callbacks)==null?void 0:Ir.onDisabledSeekToInteractiveClick,bo=e.store.actions.internal.setQuality,Oo=q(void 0),$o=q(void 0),Pi=q(void 0),yo=q(void 0),xo,Jo,Br=f(()=>(r()==="video"&&a()||r()==="ads"&&l()==="inactive")&&!d()),Hr=q(void 0),{closeNotification:ss,notificationsToShow$:ws}=Zt,$r=f(()=>!!s().slow_video),ir=()=>ss("slow_video"),Fr=de(!1),mn,vn=q(!1),yr=f(()=>u()!==kT.PLAYING),xr=q(!1),en=f(()=>m()||p()||!n(vn)&&(v()&&!!ti||n(yr)&&b())),wr=q(!0),Sr=f(()=>e.uiConfig.features.thumbTimer&&wt()&&r()==="video"&&!y()&&!d()&&!Lt&&(e.uiConfig.hideThumbTimerAfterTouch&&!_()||!e.uiConfig.hideThumbTimerAfterTouch)),Cr=q(!1),Nn=f(()=>(Et()||e.showAutoplayNext&&x())&&!!Te()&&!!Fe()&&(e.showAds&&I()||!e.showAds)&&v()&&!d()&&!n(Cr)),Ur=q(!1);st==null||st.setContext(ad());let Ss=ct=>{ct&&!Lt&&Si(e.uiConfig.controls.hideTimeoutMobile)};e.store.setUiCallbacks({onStarted:Ss});let zr=()=>{clearTimeout(xo),N(vn,!1),p()&&Ue.set(!1)},Si=ct=>{zr(),N(vn,!0),xo=setTimeout(()=>N(vn,!1),ct);let kt=ct-100;mn=setTimeout(()=>{T()&&Fr.set(!1)},kt>0?kt:ct)},as=Bt.subscribe(ct=>{W.set(ct),ct&&(clearTimeout(Jo),Jo=setTimeout(()=>W.set(!1),e.uiConfig.controls.hide360IconTimeout))}),tn=(...kt)=>gt(null,[...kt],function*(ct=da()){var so,wo,So,hn,ao,_n;if(ct&&!xc.device.isIOS){let Zi=Rd(),bn=nr(),Co=xc.browser.isSamsungBrowser&&Zi===e.shadowRootContainer;ct=Zi===bn||Co}if(ct){Si(e.uiConfig.controls.hideTimeoutFullscreen);try{yield st==null?void 0:st.exit()}catch(Zi){Ot({message:String(Zi)})}try{let Zi=(so=R())!=null&&so.width&&((wo=R())!=null&&wo.height)?R():A();yield L_(Zi)}catch(Zi){Ot({message:String(Zi)})}}dt.set(ct),e.store.getAdmanWrapper().setFullscreen(ct),P()?(hn=(So=e.store.callbacks)==null?void 0:So.onFullscreenEnter)==null||hn.call(So):(_n=(ao=e.store.callbacks)==null?void 0:ao.onFullscreenExit)==null||_n.call(ao)}),pt=ct=>{let kt=ct,{width:so,height:wo}=kt.target;_t.set({width:so,height:wo})},ei=()=>{let{width:ct,height:kt}=n(Oo).getBoundingClientRect();_t.set({width:ct,height:kt})};Mt(()=>{var ct;return Ru(tn),e.uiConfig.features.annotationsInside&&(wi==null||wi.init(n(Oo))),Ua(st)&&(st==null||st.assignPlayerContainer(n(Oo)),st==null||st.setExternalEventHandlers({resize:pt,leavepictureinpicture:ei})),N(wr,!xc.device.isIphoneOrOldIpad),e.interactiveContainer&&((ct=xe().parentElement)==null||ct.insertBefore(e.interactiveContainer,xe().nextSibling)),()=>{clearTimeout(xo),clearTimeout(mn),clearTimeout(Jo),as(),st==null||st.dispose().catch(kt=>{Ot({message:String(kt)})}),Nu(tn)}});let On=q(!0),or=q(!0),Wr=ct=>{let kt=E()+(ct==="forward"?1:-1)*e.uiConfig.controls.seekStepMobile/1e3;kt<0?(N(On,!1),kt=0):kt>=z()&&(N(or,!1),kt=z()),N(xr,!0),e.seekTime(kt)},nr=()=>xc.device.isIOS?n(Oo):!e.uiConfig.allowChangingFullscreenTarget||!Dt()?e.outerContainerRef:Dt().contains(e.outerContainerRef)?Dt():e.outerContainerRef,rr=()=>gt(null,null,function*(){try{if(da())yield Vu(document),Ot({message:"exit fullscreen"});else{if(Ot({message:"request fullscreen"}),xc.device.isIOS&&!F())return;yield Mu(nr())}}catch(ct){Ot({message:String(ct)})}}),Do=()=>{tr()},Tr=ct=>{if(ct.preventDefault(),U()){Do();return}if(!at()){e.firstStart(),Si(e.uiConfig.controls.hideTimeoutCursor);return}N(xr,!1),y()?zr():Si(e.uiConfig.controls.hideTimeoutMobile)},Dn=()=>{Ke.set(!0)},sr=()=>{Lt||(Fr.set(!0),Si(e.uiConfig.controls.hideTimeoutCursor))},ar=ct=>{ro&&(ro(ct),Si(e.uiConfig.controls.hideTimeoutMobile))},on=ct=>{Ei&&(Ei(ct),Si(e.uiConfig.controls.hideTimeoutMobile))};De(()=>{Ui.set(n(Hr))}),De(()=>{St.set((n(yr)||U()||X()||ae()||Z()||!n(Nn)&&(v()||n(vn)&&!n(xr)))&&!n(en)&&r()==="video"&&!d()&&re())}),De(()=>{!X()&&n(Ur)&&!J()&&Si(e.uiConfig.controls.hideTimeoutMobile),N(Ur,X(),!0)}),De(()=>{N(On,E()>0),N(or,!we()&&E()<z(),!0)}),De(()=>{Ud(n(yo),U(),me(),!0)});let gn=Y("aria_label_video_player");Wb({fullScreenChangeHandler:tn,getFullscreenTarget:nr}),Kb({store:e.store,getFullscreenTarget:nr});let Bn=(ct,kt)=>{var hn,ao;let so=(ao=(hn=e.store.callbacks)==null?void 0:hn.uiInfo)==null?void 0:ao.onUpcomingLiveViewStateChanged;if(!so)return;let wo=!!kt,So=ke(ke({},Jn(n(Oo),{upcomingLiveScreen:kt},"upcomingLiveScreen",wo)),ct);so(So)};var Mi=BT();ut("blur",Aa,Do);var Vi=C(Mi);sl(Vi,{onClick:Tr,get videoContainer(){return xe()},set videoContainer(ct){xe(ct)}});var Bo=k(Vi,2);Oa(Bo,()=>"slot",!1,(ct,kt)=>{io(ct,()=>({name:rl}))});var Hn=k(Bo,2);Os(Hn,ee,ct=>{var kt=DT(),so=ue(kt);let wo=f(()=>r()!=="thumb"||d()||Lt&&e.autoplay||e.uiConfig.features.disableThumbUnstartedOnAutoplay&&e.autoplay);il(so,{get hidden(){return n(wo)},get thumbUrl(){return e.thumbUrl},get startVideo(){return e.firstStart}});var So=k(so,2);{var hn=je=>{var Xt=MT(),yi=ue(Xt);{var zo=sn=>{let an=f(()=>e.uiConfig.controls.seekStepMobile/1e3);dp(sn,{side:"left",get seekStep(){return n(an)},handleSingleFirstClick:Tr,handleSecondClick:()=>Wr("backward")})};V(yi,sn=>{n(On)&&sn(zo)})}var xn=k(yi,2);{var Pr=sn=>{let an=f(()=>e.uiConfig.controls.seekStepMobile/1e3);dp(sn,{side:"right",get seekStep(){return n(an)},handleSingleFirstClick:Tr,handleSecondClick:()=>Wr("forward")})};V(xn,sn=>{n(or)&&sn(Pr)})}$(je,Xt)};V(So,je=>{e.canRewindLive&&$i&&!_e().has("TIMELINE")&&je(hn)})}var ao=k(So,2);{var _n=je=>{let Xt=f(()=>{var yi;return(yi=e.live)==null?void 0:yi.startTime});gc(je,{get thumbUrl(){return e.thumbUrl},get startTime(){return n(Xt)},onUpcomingLiveViewStateChanged:Bn})};V(ao,je=>{r()==="LiveWaitingStart"&&je(_n)})}var Zi=k(ao,2);{var bn=je=>{ol(je,{kind:"recover",get thumbUrl(){return e.thumbUrl}})};V(Zi,je=>{r()==="LiveWaitingRecover"&&je(bn)})}var Co=k(Zi,2);{var Cs=je=>{ol(je,{kind:"record",get thumbUrl(){return e.thumbUrl}})};V(Co,je=>{r()==="LiveWaitingRecord"&&je(Cs)})}var Kr=k(Co,2);{var Ts=je=>{var Xt=VT();let yi;var zo=C(Xt);Od(zo,{get adsSlotId(){return He()},get adsParams(){return ot()},get adsAutoplayParam(){return ne()},get duration(){return ce()},get adsExternalApi(){return e.adsExternalApi},get adsJson(){return e.adsJson}}),S(Xt),D(xn=>yi=oe(Xt,1,"ads-container s-9",null,yi,xn),[()=>({hidden:r()!=="ads"})]),$(je,Xt)};V(Kr,je=>{e.showAds&&at()&&je(Ts)})}var zi=k(Kr,2);{var qr=je=>{let Xt=f(()=>!Et()&&e.showAutoplayNext&&x());Lv(je,{get title(){return Te()},get thumb(){return Fe()},get isHide(){return n(Xt)},clickCloseIcon:()=>N(Cr,!0)})};V(zi,je=>{n(Nn)&&Te()&&Fe()&&je(qr)})}var Ho=k(zi,2);{var Er=je=>{mc(je,{})};V(Ho,je=>{Ce()&&je(Er)})}var $n=k(Ho,2);{var Qr=je=>{var Xt=RT(),yi=C(Xt);Vd(yi,{}),S(Xt),$(je,Xt)};V($n,je=>{ge()&&je(Qr)})}var We=k($n,2);{var yt=je=>{vc(je,{get thumbUrl(){return e.thumbUrl},get chromecastDeviceName(){return pe()},onClick:Tr})};V(We,je=>{Z()&&je(yt)})}var ui=k(We,2);{var go=je=>{el(je,{get shifted(){return y()},get captions(){return G()},get position(){return E()},get playerSize(){return A()},isMobile:!0})};V(ui,je=>{Qe().value!=="off"&&je(go)})}var ki=k(ui,2);{var Fo=je=>{var Xt=NT();Xt.__click=[LT,U,ze,Do];var yi=C(Xt);tl(yi,{}),S(Xt),$(je,Xt)};V(ki,je=>{d()&&je(Fo)})}var lo=k(ki,2);{var Uo=je=>{let Xt=f(()=>r()==="thumb"||r()==="LiveWaitingStart"||r()==="LiveWaitingRecover"||r()==="LiveWaitingRecord"||r()==="ads"),yi=f(()=>r()==="ads"),zo=f(()=>e.canRewindLive&&O()!==0);pc(je,{get bottomHidden(){return n(Xt)},get showControls(){return y()},get bottomNoSmooth(){return T()},get isAds(){return n(yi)},get canRewindLive(){return n(zo)},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 It()},get customFullscreenSupported(){return n(wr)},get endScreenShown(){return n(Nn)},toggleFullscreen:rr,get seekToInteractive(){return e.seekToInteractive},get playPrevChapter(){return e.playPrevChapter},onDisabledPlayPrevChapterClick:ar,onDisabledSeekToInteractiveClick:on,get playerControlsWrapperRef(){return n($o)},set playerControlsWrapperRef(xn){N($o,xn,!0)},get playerControlsRef(){return n(Pi)},set playerControlsRef(xn){N(Pi,xn,!0)}})};V(lo,je=>{at()&&je(Uo)})}var nn=k(lo,2);{var dr=je=>{var Xt=OT(),yi=C(Xt);bc(yi,{get supportLink(){return e.supportLink},get returnFocus(){return AT},get ref(){return n(yo)},set ref(zo){N(yo,zo,!0)}}),S(Xt),$(je,Xt)};V(nn,je=>{U()&&je(dr)})}var To=k(nn,2);let rn=f(()=>!n(Sr));Hd(To,{get isLive(){return Ge()},get isHidden(){return n(rn)},get isPlaying(){return K()},get position(){return E()},get duration(){return z()}});var Un=k(To,2);{var Io=je=>{qa(je,{})};V(Un,je=>{n(Br)&&je(Io)})}var yn=k(Un,2);{var zn=je=>{Kd(je,{})};V(yn,je=>{se()&&je(zn)})}var ls=k(yn,2);{var cr=je=>{$c(je,{onClose:ir,onSelectAutoQuality:()=>{bo("auto"),ir()}})};V(ls,je=>{n($r)&&je(cr)})}$(ct,kt)});var lr=k(Hn,2);Ze(lr,ct=>N(Hr,ct),()=>n(Hr)),S(Mi),Ze(Mi,ct=>N(Oo,ct),()=>n(Oo)),D(()=>Re(Mi,"aria-label",gn)),ut("click",Mi,Dn,!0),ut("focusin",Mi,sr,!0),$(t,Mi),H(),o()}Ye(["click"]);function up(t){let e="";return no(t.timelineSliderFilledColor)&&(e+=`--timeline-slider-filled-bg:${t.timelineSliderFilledColor};`),no(t.timelineSliderHandleColor)&&(e+=`--timeline-slider-handle-bg:${t.timelineSliderHandleColor};`),no(t.timelineSliderLoadedColor)&&(e+=`--timeline-slider-loaded-bg:${t.timelineSliderLoadedColor};`),no(t.timelineSliderColor)&&(e+=`--timeline-slider-bg:${t.timelineSliderColor};`),no(t.volumeSliderColor)&&(e+=`--volume-slider-bg:${t.volumeSliderColor};`),no(t.volumeSliderHandleColor)&&(e+=`--volume-slider-handle-bg:${t.volumeSliderHandleColor};`),no(t.volumeSliderFilledColor)&&(e+=`--volume-slider-filled-bg:${t.volumeSliderFilledColor};`),no(t.controlsTimeColor)&&(e+=`--controls-time:${t.controlsTimeColor};`),no(t.timelineSliderFilledActiveLiveColor)&&(e+=`--timeline-slider-filled-active-live-bg:${t.timelineSliderFilledActiveLiveColor};`),no(t.timelineSliderHandleActiveLiveColor)&&(e+=`--timeline-slider-handle-active-live-bg:${t.timelineSliderHandleActiveLiveColor};`),no(t.buttonColor)&&(e+=`--btn-color:${t.buttonColor};`),no(t.buttonToggleOnColor)&&(e+=`--toggle-color-on:${t.buttonToggleOnColor};`,e+=`--toggle-color-autoplay-on:${t.buttonToggleOnColor};`),no(t.focusedColor)&&(e+=`--focused:${t.focusedColor};`),no(t.focusedOutlineWidth)&&(e+=`--focused-outline-width:${t.focusedOutlineWidth};`),no(t.focusedOutlineRadius)&&(e+=`--focused-outline-radius:${t.focusedOutlineRadius};`),no(t.controlsDesktopPaddingHorizontal)&&(e+=`--controls-desktop-padding-horizontal:${t.controlsDesktopPaddingHorizontal};`),no(t.timelinePaddingHorizontal)&&(e+=`--timeline-padding-horizontal:${t.timelinePaddingHorizontal};`),no(t.settingsBackgroundColor)&&(e+=`--settings-bg:${t.settingsBackgroundColor};`),no(t.font)&&(e+=`--font:${t.font};`),no(t.controlsGradientHeight)&&(e+=`--controls-gradient-height:${t.controlsGradientHeight};`),no(t.controlsGradient)&&(e+=`--controls-gradient:${t.controlsGradient};`),e.length&&e||void 0}function no(t){return typeof t=="string"&&!t.includes(";")}import{debounceFn as FT}from"@vkontakte/videoplayer-shared/es2015";var UT=L('<div class="time-container s-7"><!></div>'),zT=L('<div class="player-wrapper s-7" role="region"><!> <!> <!> <!> <!> <div><!></div></div>'),WT={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 Vv(t,e){B(e,!0),Q(t,WT);let[i,o]=Oe(),r=()=>w(J,"$scrubbingInProgress",i),a=()=>w(Z,"$playerSize",i),l=()=>w(E,"$isPlaying$",i),d=()=>w(A,"$duration$",i),s=()=>w(U,"$positionWithScrubbing$",i),u=()=>w(T,"$playerPhase",i),m=()=>w(R,"$crashed$",i),p=()=>w(z,"$currentSubtitle$",i),v=()=>w(F,"$currentSubtitleCaptions$",i),b=()=>w(P,"$positionExact$",i),y=()=>w(X,"$isLive$",i),_=()=>w(ae,"$isRewindableLive$",i),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=li({}),Ce=q(!1),ge=f(()=>!r()&&!n(Ce)),pe=()=>{N(ee,!0)},Qe=()=>{N(ee,!1)},G=FT(Gl,260);De(()=>{a(),G(we(),re,_e,n(ee))});let O=f(()=>l()?jo(d()-s()):jo(isFinite(d())?d():x()));var Ge=zT(),K=C(Ge);sl(K,{hideCursor:!1,get videoContainer(){return I()},set videoContainer(Te){I(Te)}});var se=k(K,2);Oa(se,()=>"slot",!1,(Te,Fe)=>{io(Te,()=>({name:rl}))});var xe=k(se,2);let He=f(()=>u()!=="thumb"||m());il(xe,{get hidden(){return n(He)},get thumbUrl(){return e.thumbUrl},iconVisible:!1});var ot=k(xe,2);{var ne=Te=>{el(Te,{shifted:!1,get captions(){return v()},get position(){return b()},get playerSize(){return a()}})};V(ot,Te=>{p().value!=="off"&&n(ge)&&Te(ne)})}var ce=k(ot,2);{var Ne=Te=>{var Fe=UT(),It=C(Fe);Bd(It,{get isLive(){return y()},get isPlaying(){return l()},get time(){return n(O)}}),S(Fe),$(Te,Fe)};V(ce,Te=>{n(ge)&&Te(Ne)})}var Le=k(ce,2);let et;var Ee=C(Le);Za(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),D(Te=>et=oe(Le,1,"timeline s-7",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)),$(t,Ge),H(),o()}var YT=L("<div><!></div>"),jT={hash:"s-2",code:'.vk-vp-root.s-2{--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-2{overflow:visible}.vk-vp-root.s-2 *{-webkit-tap-highlight-color:transparent}.vk-vp-root.s-2 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-2 p{margin:0}.vk-vp-root.s-2 svg:not(.interactive-root svg){pointer-events:none}.vk-vp-root.s-2 .interactive-root{font-family:var(--vk-vp-int-custom-font,inherit)}.vk-vp-root.s-2 :focus,.vk-vp-root.s-2 :focus-visible{outline:none}.vk-vp-root.s-2 :focus-visible{border-radius:var(--focused-outline-radius);box-shadow:var(--focused-element-shadow)}.vk-vp-root.s-2 .focus-hidden:focus-visible{box-shadow:none}.vk-vp-root.s-2 .hidden{opacity:0;visibility:hidden}.vk-vp-root.s-2 .out-of-flow{content-visibility:hidden!important}.vk-vp-root.s-2 .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-2 .out-of-view{left:-1000vh!important;position:absolute!important}.vk-vp-root.s-2 .icon.icon-error-stub{align-items:center;display:flex;justify-content:center}'};function Nv(t,e){B(e,!0),Q(t,jT);let[i,o]=Oe(),r=()=>w(at,"$isLive$",i),a=()=>w(wi,"$availableSubtitlesList$",i),l=()=>w(st,"$isPreviewTrackHorizontallyAligned$",i),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),O=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),ot=h(e,"seekToInteractive",7,qb),ne=h(e,"playPrevChapter",7,qb),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();Bh(p());let Fe=Vt(),It=p().logoLink,wt=s().ui.debugPanelVisible,Dt=s().ui.playerSize,at=s().state.isLive$,Zt=s().state.isInteractive&&Rv.device.isAndroid,Pt=q(void 0),Ot=null,zt=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}),Yh(s(),Te),De(()=>{var W,Lt;s().ui.isMobile.set(me()),(Lt=(W=m().callbacks)==null?void 0:W.onDomReady)==null||Lt.call(W)});let j=(W=!1)=>{N(zt,!0),W?s().actions.external.firstStart(U()):s().actions.internal.firstStart(U())},Pe=()=>{if(Fe.features.qualityDetailsSubMenuEnabled){let W=__(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{b_(s().videoId),Nf()&&s().actions.internal.setTrafficSavingEnabled(!0);let Lt=Mf(s().videoId);Lt&&s().actions.internal.setQuality(Lt)}};function le(W){var qt,Ke,Ui;let Lt=d()||W;Lt&&s().initVideo({container:n(Pt),sources:Lt,failoverHosts:se(),subtitles:x(),subtitlesForcedLanguage:I(),volumeMultiplier:ce()});let ai=qT.get(Pd)==="true";wt.set(ai),z()>0&&s().actions.external.seekTime(z());let vt=me()?Fe.volumeDefault:(Ke=(qt=P())!=null?qt:wu())!=null?Ke:Fe.volumeDefault,ti=(Ui=E())!=null?Ui:p_();if(s().actions.external.setVolume(vt),s().actions.external.setMuted(ti),s().getAdmanWrapper().setInitialVolume(ti?0:vt),Pe(),Fe.features.saveRate&&He()){let Xi=v_();Xi&&!r()&&s().actions.internal.setPlaybackRate(Xi)}if(Ne()){let Xi=h_();Xi&&s().actions.internal.setAutoplayNextEnabled(Xi)}s().ui.isAutoplay.set(A()),A()&&j(),R()&&Fe.features.preload&&s().actions.internal.preload()}let $e=W=>{if(window.ResizeObserver){let Lt,ai;Ot=new ResizeObserver(QT(vt=>{let ti=vt[0];if(ti.contentBoxSize){let qt=Array.isArray(ti.contentBoxSize)?ti.contentBoxSize[0]:ti.contentBoxSize;Lt=qt.inlineSize,ai=qt.blockSize}else ti.contentRect&&(Lt=ti.contentRect.width,ai=ti.contentRect.height);Dt.set({width:Lt,height:ai})},300)),Ot.observe(W)}W.clientWidth&&W.clientHeight&&Dt.set({width:W.clientWidth,height:W.clientHeight})},Me=()=>{document.hidden&&s().actions.external.stop()};Mt(()=>{var ai,vt,ti,qt;Zt&&document.addEventListener("visibilitychange",Me),Fe.debugLog&&s().actions.internal.startLogging(),$e(n(Pt));let W=Ee.map(Ke=>Ke.init({store:s(),microStores:Te,config:m(),interactiveController:_(),uiConfig:p()})),Lt=()=>{Zt&&document.removeEventListener("visibilitychange",Me),Ot==null||Ot.disconnect(),W.forEach(Ke=>Ke.unsubscribe()),s().destroy()};return((ai=T())==null?void 0:ai.status)==="upcoming"?(s().actions.internal.setLiveWaitingStart(!0),Lt):((vt=T())==null?void 0:vt.status)==="waiting"?(s().actions.internal.setLiveWaitingRecover(!0),Lt):(((ti=T())==null?void 0:ti.status)==="finished"||((qt=T())==null?void 0:qt.status)==="postlive")&&!(d()&&KT(d()))?(s().actions.internal.setLiveWaitingRecord(!0),Lt):(le(),Lt)});function dt(){n(zt)?s().actions.external.play():j(!0)}function St(){s().actions.external.pause()}function fe(W){s().actions.external.setMuted(W)}function Ue(){s().actions.external.toggleSubtitle()}function ze(W,Lt){s().actions.external.changeSubtitle(W,Lt)}function Ct(W){s().actions.external.changeAudioStream(W)}function si(){var W;(W=s().webApi.slotsApi)!=null&&W.haveSlots()&&s().actions.external.hideControls()}function xt(){var W;(W=s().webApi.slotsApi)!=null&&W.haveSlots()&&s().actions.external.showControls()}function Yt(W){me()||W>=0&&W<=1&&s().actions.external.setVolume(W)}function ci(W){s().actions.internal.seekTime(W,GT.UNKNOWN)}function Hi(W){s().actions.external.seekEpisodeStartTime(W)}function Rt(){s().actions.external.returnFocusToEpisodes()}function vo(W){s().actions.external.setPlaybackRate(W)}function fi(W){s().actions.external.setAutoQualityLimits(W)}function nt(){s().actions.external.setQuality("auto")}function jt(W){s().actions.external.setTrafficSavingEnabled(W)}function Fi(W){s().actions.external.setHighQualityEnabled(W)}let $i=up(Fe.view),Jt=m().playerView==="preview",wi=s().state.availableSubtitlesList$;if(Fe.features.initSubtitles){let W=!1;De(()=>{var Lt;if(!W&&a().length){W=!0;let ai;if(Fe.features.userVideoPrefs&&s().videoId){let ti=Iu(Fe.userSalt,String(s().videoId));ti!=null&&ti.subtitleTrackId&&(ai=a().find(qt=>qt.value===ti.subtitleTrackId))}let vt=(Lt=I())!=null?Lt:Df();vt&&(ai=a().find(ti=>ti.language===vt)),s().actions.internal.setSubtitle(ai)}})}let st=s().ui.isPreviewTrackHorizontallyAligned;var lt=YT();let _i;var Xo=C(lt);{var No=W=>{Mv(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 It},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 O()},get outerContainerRef(){return Ge()},get fullScreenTarget(){return K()},get showMiniTimer(){return xe()},get playerStarted(){return n(zt)},get seekToInteractive(){return ot()},get playPrevChapter(){return ne()},firstStart:j,seekTime:ci,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(Pt)},set videoContainer(Lt){N(Pt,Lt,!0)}})},_t=W=>{var Lt=Ve(),ai=ue(Lt);{var vt=qt=>{Vv(qt,{get thumbUrl(){return b()},get outsideDuration(){return re()},get canRewindLive(){return F()},get videoContainer(){return n(Pt)},set videoContainer(Ke){N(Pt,Ke,!0)}})},ti=qt=>{Av(qt,{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 It},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 O()},get outerContainerRef(){return Ge()},get fullScreenTarget(){return K()},get showMiniTimer(){return xe()},get playerStarted(){return n(zt)},get seekToInteractive(){return ot()},get playPrevChapter(){return ne()},firstStart:j,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(Pt)},set videoContainer(Ke){N(Pt,Ke,!0)},get keyboardControls(){return et()},set keyboardControls(Ke){et(Ke)}})};V(ai,qt=>{Jt?qt(vt):qt(ti,!1)})}$(W,Lt)};V(Xo,W=>{me()?W(No):W(_t,!1)})}S(lt),D(W=>{_i=oe(lt,1,"vk-vp-root s-2",null,_i,W),qe(lt,$i)},[()=>({"root--miui-browser":Rv.device.isMobile&&Rv.browser.isMiuiBrowser,"visible-outside":Jt,"preview-track-horizontally-alinged":l()})]),$(t,lt);var Bt=H({initVideo:le,play:dt,pause:St,setMuted:fe,toggleSubtitle:Ue,changeSubtitle:ze,changeAudioStream:Ct,hideControls:si,showControls:xt,setVolume:Yt,seekTime:ci,seekEpisodeStartTime:Hi,returnFocusToEpisodes:Rt,setPlaybackRate:vo,setAutoQualityLimits:fi,setAutoQuality:nt,toggleTrafficSaving:jt,toggleHighQuality:Fi,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 O()},set shadowRootContainer(W){O(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 ot()},set seekToInteractive(W){ot(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(),Bt}var XT=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 Ov(t,e){let i=h(e,"isWhite",3,!1),o=f(()=>i()?"#fff":"#909499");Je(t,{width:"57",height:"60",get fill(){return n(o)},testId:"stub-icon",children:(r,a)=>{var l=XT();di(9),$(r,l)},$$slots:{default:!0}})}var ZT=L('<div class="title s-1"> </div>'),JT=L('<div class="playerStub s-1"><!> <!></div>'),eI={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 Dv(t,e){Q(t,eI);var i=JT(),o=C(i);{var r=d=>{var s=ZT(),u=C(s,!0);S(s),D(()=>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);Ov(d,{get isWhite(){return n(s)}})};V(a,d=>{(!e.title||!e.thumbUrl)&&d(l)})}S(i),D(()=>qe(i,e.thumbUrl?`background-image: url('${e.thumbUrl}')`:"")),$(t,i)}var tI=L('<div class="playerError s-0"><!></div>'),iI={hash:"s-0",code:".playerError.s-0{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 Bv(t){Q(t,iI);var e=tI(),i=C(e);tl(i,{}),S(e),$(t,e)}import{now as RI,ValueSubject as NI}from"@vkontakte/videoplayer-shared/es2015";import{cloneDeepWith as OI,InterfaceLanguage as DI,isNonNullable as Qv,Logger as BI,Observable as HI,Subscription as t$,once as FI,InternalsExposure as UI,skip as zI,getPlayerId as WI}from"@vkontakte/videoplayer-shared/es2015";import{clientChecker as i$,isMobile as KI}from"@vkontakte/videoplayer-core/es2015";import{OneStat as qI,ThinOneStat as QI,MediascopePixel as GI}from"@vkontakte/videoplayer-statistics/es2015";import{Logger as oI,Subscription as nI}from"@vkontakte/videoplayer-shared/es2015";var pp=class{constructor(){this.subscription=new nI,this.logger=new oI,this.log=this.logger.createComponentLog("MediaSessionApi")}isSupported(){return"mediaSession"in navigator}setMetaData({title:e,artist:i="",thumbUrl:o=""}){this.isSupported()&&(navigator.mediaSession.metadata=new MediaMetadata({title:e,artist:i,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 i,o;if(this.isSupported())for(let[r,a]of e)try{(o=(i=navigator.mediaSession).setActionHandler)==null||o.call(i,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(i=>{var a,l;let o=ye(e.state.currentPlaybackRate$),r=ye(e.state.duration$);if(!(!isFinite(i)||!isFinite(r)))try{(l=(a=navigator.mediaSession).setPositionState)==null||l.call(a,{position:i,playbackRate:o,duration:r})}catch(d){this.log({message:`MediaSession setPositionState can't call with position: ${i} and duration: ${r}`})}})))}clearSubscriptions(){this.subscription.unsubscribe()}destroy(){this.resetActionHandlers(),this.clearSubscriptions()}};import{ValueSubject as Uv,detectEmbed as cI}from"@vkontakte/videoplayer-shared/es2015";var rI=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),sI=L('<div><div><!></div> <span class="title s-6"> </span></div>'),aI={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 Hv(t,e){B(e,!0),Q(t,aI);let[i,o]=Oe(),r=()=>w(u,"$interfaceLanguage$",i),a=()=>w(m,"$isMobile$",i),l=be(),d=Vt(),s=!!l.webApi.pictureInPictureApi,u=l.interfaceLanguage$,m=l.ui.isMobile,p=l.ui.t,v=f(()=>r()&&p("pip_dummy_title")),b=up(d.view);var y=sI();let _;var x=C(y);let I;var T=C(x);Je(T,{width:"57",height:"56",testId:"pip-dummy-icon",children:(P,E)=>{var z=rI();di(),$(P,z)},$$slots:{default:!0}}),S(x);var R=k(x,2),A=C(R,!0);S(R),S(y),D((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),ve(A,n(v))},[()=>({"is-pip-api":s}),()=>({desktop:!a()})]),$(t,y),H(),o()}var lI=Object.defineProperty,dI=(t,e,i)=>e in t?lI(t,e,{enumerable:!0,configurable:!0,writable:!0,value:i}):t[e]=i,Zl=(t,e,i)=>dI(t,typeof e!="symbol"?e+"":e,i),Fv=(t,e,i)=>new Promise((o,r)=>{var a=s=>{try{d(i.next(s))}catch(u){r(u)}},l=s=>{try{d(i.throw(s))}catch(u){r(u)}},d=s=>s.done?o(s.value):Promise.resolve(s.value).then(a,l);d((i=i.apply(t,e)).next())}),uI=460,pI=280,wc=class{constructor({enabled:e=!0}={enabled:!0}){Zl(this,"playerDomElement"),Zl(this,"playerParentShadowRoot"),Zl(this,"playerDummyElement"),Zl(this,"svelteContext"),Zl(this,"pipWindow"),Zl(this,"info",{isActive$:new Uv(!1),isEnabled$:new Uv(!1),type:1}),this.info.isEnabled$=new Uv(e)}isSupported(){let{isEmbed:e}=cI();return"documentPictureInPicture"in window&&!e}isActive(){return this.info.isActive$.getValue()}setPlayerDomElement(e,i){this.playerDomElement=e,this.playerParentShadowRoot=i}setContext(e){this.svelteContext=e}request(){return Fv(this,null,function*(){var e,i;if(!this.isSupported()||!this.playerDomElement||!this.playerParentShadowRoot)return;this.pipWindow=yield documentPictureInPicture.requestWindow({width:uI,height:pI,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(Hv,d),(e=this.pipWindow)==null||e.document.body.append(a),this.info.isActive$.next(!0),(i=this.pipWindow)==null||i.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 Fv(this,null,function*(){return new Promise(e=>{var i;this.pipWindow&&((i=documentPictureInPicture.window)==null||i.close()),e()})})}dispose(){return Fv(this,null,function*(){yield this.exit()})}setEnabled(e){this.info.isEnabled$.next(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 Qb(t){return t instanceof wc}var fp=class{static getLatestSupportedVersion(e){let i=new Fa(e),o=new wc(e);if(o.isSupported())return o;if(i.isSupported())return i}};function Sc(t,e){var r,a;let i=new Set([...Object.keys(t),...Object.keys(e)]),o={};for(let l of i)o[l]=(a=(r=e[l])!=null?r:t[l])!=null?a:void 0;return o}var Gb="Inner error. Unexpectedly root annotation container null reference exception",Yb="Annotation with such name already exists",jb="Annotation with such name does not exist";var Jl=class extends Error{constructor(e){super(e),this.name="AnnotationError"}};import{observeElementSize as fI,Subscription as mI,throttleFn as vI}from"@vkontakte/videoplayer-shared/es2015";var gI="1",hI=100,mp=class{constructor(e){this.annotationsInside=e;this.annotations=new Map;this.subscriptions=new mI}init(e){if(this.rootAnnotationsContainer=e,this.annotationsInside)return;let i=vI(()=>{for(let o of this.annotations.values())this.isElementExceedsBoundaries(o,this.playerSize.width,this.playerSize.height)?o.style.visibility="hidden":o.style.visibility="visible"},hI);this.subscriptions.add(fI(this.rootAnnotationsContainer).subscribe(({width:o,height:r})=>{this.playerSize={width:o,height:r},i()})),this.mutationObserver=new MutationObserver(i),this.mutationObserver.observe(this.rootAnnotationsContainer,{attributes:!0,childList:!0,subtree:!0,characterData:!0})}add(e,i){var o;if(!this.rootAnnotationsContainer)throw new Jl(Gb);if(this.annotations.has(e))throw new Jl(Yb);i.style.zIndex=(o=i.style.zIndex)!=null?o:gI,i.style.position="absolute",this.rootAnnotationsContainer.append(i),this.annotations.set(e,i)}get(e){let i=this.annotations.get(e);if(!i)throw new Jl(jb);return i}remove(e){let i=this.get(e);this.annotations.delete(e)&&i.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,i,o){let r=e.offsetTop,a=e.offsetLeft,l=e.offsetWidth,d=e.offsetHeight;return r<0||a<0||a+l>i||r+d>o}registryRootContainer(e){}addLayer(e){return document.createElement("div")}getLayer(e){}removeLayer(e){}clearLayer(e){}detach(){}reattach(){}};import{assertNonNullable as vp,Subscription as _I}from"@vkontakte/videoplayer-shared/es2015";var fn=class{init({store:e,microStores:i,interactiveController:o,config:r}){return vp(e),vp(i),vp(r),r.interactiveData&&vp(o),this.subscription=new _I,this.subscription}};var Cc=class extends fn{constructor(){super(...arguments);this.stateName="fakeIsPlaying$";this.state$=Kt(ke({},de(null)),{toggle:()=>this.state$.update(i=>!i)})}init(i){let o=super.init(i),{isInteractiveExpectation$:r}=i.store.state;return o.add(r.subscribe(a=>{this.state$.set(a?!0:null)})),o}};var Tc=class extends fn{constructor(){super(...arguments);this.stateName="interactiveControlsOpacity$";this.state$=Kt(ke({},de(null)),{toggle:()=>this.state$.update(i=>!i)})}init(i){let o=super.init(i),{microStores:r,store:a}=i,{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 Ic=class extends fn{constructor(){super(...arguments);this.stateName="seekToInteractiveDisabledTooltip$";this.state$=de("tooltip_chapter_without_interactive")}init(i){let o=super.init(i),{store:r}=i;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}};import{combine as bI}from"@vkontakte/videoplayer-shared/es2015";var zv=de(!1),gp=null,Ec=class extends fn{constructor(){super(...arguments);this.stateName="showInteractiveTimeIndicatorTooltip$";this.state$=Kt(ke({},zv),{set:(i,o=!1)=>{i!==ye(zv)&&(this.clearTimeout(),zv.set(i),!i&&gp&&(gp=!1),i&&o&&(this.timeout=setTimeout(()=>{this.state$.set(!1)},3e3)))},clearTimeout:()=>this.clearTimeout()})}init(i){let o=super.init(i),{store:r,config:a}=i,{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(bI({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&&gp===null&&(gp=!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)}};import{combine as $I,noop as yI}from"@vkontakte/videoplayer-shared/es2015";var Pc=class extends fn{constructor(){super(...arguments);this.stateName="graphIsOpened$";this.graphMadePause=!1;this.state$=Kt(ke({},de(null)),{toggle:yI});this.checkIfShouldHide=i=>Us(i,"s")}init(i){let o=super.init(i),{store:r,interactiveController:a}=i,l=r.ui.currentGridType$,d=r.getLogger().createComponentLog("GraphIsOpened microStore");return this.state$.toggle=()=>gt(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(Cf),!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(Cf),!v&&this.graphMadePause&&r.actions.internal.pause()}catch(y){d({message:"Cant show graph"})}}}),o.add($I({graphIsOpened:this.state$,currentGridType:l}).subscribe(m=>gt(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}};import{ValueSubject as Xb}from"@vkontakte/videoplayer-shared/es2015";var kc=class extends fn{constructor(){super(...arguments);this.stateName="pictureInPicture$";this.state$={isActive$:de(!1),isEnabled$:de(!1),type$:de(void 0)}}init(i){let o=super.init(i),{store:r}=i,{info:{isActive$:a,isEnabled$:l,type:d}}=r.webApi.pictureInPictureApi||{info:{isActive$:new Xb(!1),isEnabled$:new Xb(!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}};import{filter as SI,filterChanged as CI}from"@vkontakte/videoplayer-shared/es2015";import{safeStorage as Wv}from"@vkontakte/videoplayer-shared/es2015";var Zb=({maxShowCount:t,timeout:e})=>{let i=[t!==0?xI({maxCount:t}):void 0,e!==0?wI({timeout:e}):void 0].filter(o=>!!o);return{notificationShowed:o=>i.forEach(r=>r.notificationShowed(o)),canShowNotification:o=>i.every(r=>r.canShowNotification(o))}},xI=({maxCount:t})=>{let e={};return{notificationShowed:i=>{var o,r;e[i]=((o=e[i])!=null?o:0)+1,Wv.set("videoplayer_notifications_manager_count",JSON.stringify((r=e[i])!=null?r:0))},canShowNotification:i=>{var o;return((o=e[i])!=null?o:0)<t}}},wI=({timeout:t})=>{let e="videoplayer_notifications_manager",i=()=>{try{return JSON.parse(Wv.get(e)||"{}")}catch(a){return{}}},o=a=>Wv.set(e,JSON.stringify(a)),r=a=>{let l=i();delete l[a],o(l)};return{notificationShowed:a=>{o(Kt(ke({},i()),{[a]:{timeout:t,launchTime:Date.now()}}))},canShowNotification:a=>{let l=i()[a];if(l){let d=Date.now()-l.launchTime>t;return d&&r(a),d}else return!0}}};var Ac=class extends fn{constructor(){super(...arguments);this.stateName="notifications$";this.state$={notificationsToShow$:de({}),showNotification:i=>{this.state$.notificationsToShow$.update(o=>(o[i]=!0,o)),this.notificationManager.notificationShowed(i)},closeNotification:i=>{this.state$.notificationsToShow$.update(o=>(delete o[i],o))}}}init(i){let o=super.init(i),{store:r,uiConfig:{features:{maxCountShowSlowVideoNotification:a,timeoutShowSlowVideoNotification:l,showSlowVideoNotification:d,forceAutoQualityWhenSevereStallHappens:s}}}=i;this.notificationManager=Zb({maxShowCount:a,timeout:l});let u=r.getPlayer();return o.add(u.events.severeStallOccured$.pipe(CI(),SI(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 Jb=()=>[Cc,Tc,Ic,Ec,Pc,kc,Ac].reduce(({subscribers:t,stores:e},i)=>{let o=new i;return{subscribers:[...t,o],stores:Kt(ke({},e),{[o.stateName]:o.state$})}},{subscribers:[],stores:{}});import{devNull as Lc}from"@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 i=this.focusableElements[0],o=this.focusableElements[this.focusableElements.length-1],r=this.getActiveElement();e.shiftKey&&r===i?(e.preventDefault(),o.focus()):!e.shiftKey&&r===o&&(e.preventDefault(),i.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(i=>!i.disabled&&i.offsetParent!==null)}destroy(){this.deactivate()}setContainer(e){this.container=e}};var _p=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 TI=L('<div class="root s-3"><!></div>'),II={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 Kv(t,e){B(e,!0),Q(t,II);let i=null,o=q(null);De(()=>(n(o)&&(i=window.setTimeout(()=>{N(o,null)},e.animationDuration)),()=>{i&&clearTimeout(i)}));function r(s){e.playbackStatusShow&&N(o,s?"prev":"next",!0)}var a=Ve(),l=ue(a);{var d=s=>{var u=Ve(),m=ue(u);Os(m,()=>n(o),p=>{var v=TI(),b=C(v);let y=f(()=>n(o)==="prev");yc(b,{get duration(){return e.animationDuration},get Icon(){return ga},get reversed(){return n(y)}}),S(v),$(p,v)}),$(s,u)};V(l,s=>{e.playbackStatusShow&&n(o)&&s(d)})}return $(t,a),H({startVideoChangedAnimation:r})}import{getWindow as EI}from"@vkontakte/videoplayer-shared/es2015";var qv=EI().HTMLElement||class{constructor(){this.isConnected=!1}};var PI=Object.defineProperty,kI=Object.defineProperties,AI=Object.getOwnPropertyDescriptors,e$=Object.getOwnPropertySymbols,LI=Object.prototype.hasOwnProperty,MI=Object.prototype.propertyIsEnumerable,Yv=(t,e,i)=>e in t?PI(t,e,{enumerable:!0,configurable:!0,writable:!0,value:i}):t[e]=i,Gs=(t,e)=>{for(var i in e||(e={}))LI.call(e,i)&&Yv(t,i,e[i]);if(e$)for(var i of e$(e))MI.call(e,i)&&Yv(t,i,e[i]);return t},VI=(t,e)=>kI(t,AI(e)),Gt=(t,e,i)=>Yv(t,typeof e!="symbol"?e+"":e,i),bp=(t,e,i)=>new Promise((o,r)=>{var a=s=>{try{d(i.next(s))}catch(u){r(u)}},l=s=>{try{d(i.throw(s))}catch(u){r(u)}},d=s=>s.done?o(s.value):Promise.resolve(s.value).then(a,l);d((i=i.apply(t,e)).next())}),YI={preload:!0,autoplay:!1,repeat:!1,loop:!1,fromTime:0,canRewindLive:!0,showAds:!1,interfaceLanguage:DI.RU,isCyrillicRelatedInterface:!0,logoClickable:!1,logoHidden:!1,isTouch:KI(),isMediaSessionEnabled:!0,isPictureInPictureEnabled:!0,isAudioDisabled:!1,callbacks:{uiInfo:{}},tuningConfig:{},saveRate:!0,volumeMultiplier:1,showEndScreen:!0,showAutoplayNext:!0,showNextPrevButtons:!0},er=q(void 0),Gv=li({animationDuration:0,playbackStatusShow:!1}),$p=class extends qv{constructor(){super(),Gt(this,"svelteStubComponent"),Gt(this,"svelteRootComponent"),Gt(this,"sveltePersistentLayerComponent"),Gt(this,"svelteErrorComponent"),Gt(this,"store"),Gt(this,"microStoresRoot"),Gt(this,"statistics"),Gt(this,"sentry"),Gt(this,"_shadowRoot"),Gt(this,"playerContainer"),Gt(this,"rootContainer"),Gt(this,"stateContainer"),Gt(this,"shadowRootContainer"),Gt(this,"playerId"),Gt(this,"uiConfig"),Gt(this,"coreConfig"),Gt(this,"statisticsConfig"),Gt(this,"metaConfig"),Gt(this,"interactiveController"),Gt(this,"interactiveContainer"),Gt(this,"graphMadePause"),Gt(this,"currentPlayingVideoIndex",0),Gt(this,"needToRepeatPlaylist",!1),Gt(this,"videoConfig"),Gt(this,"pictureInPictureApi"),Gt(this,"mediaSessionApi"),Gt(this,"unsubscribePlayerPhaseSubscription"),Gt(this,"logger"),Gt(this,"log"),Gt(this,"subscription"),Gt(this,"interactiveSubscription"),Gt(this,"annotationsApi"),Gt(this,"slotsApi"),Gt(this,"focusManager"),Gt(this,"prevIsid"),Gt(this,"isInited",!1),Gt(this,"postponedInitParams",null),Gt(this,"internalsExposure",null),Gt(this,"shadowDOMCallbacksDisabled",!1),Gt(this,"fatalError$",new NI(null)),Gt(this,"createOneStat",(e,i={})=>{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}=Sc(this.videoConfig,i),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 qI(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})}}),Lc.create("ui"),this.logger=new BI,this.log=this.logger.createComponentLog("VKVideoPlayer"),this.subscription=new t$,this.interactiveSubscription=new t$,this.graphMadePause=!1,this.fatalError$.subscribe(e=>{this.unmountComponent(this.svelteErrorComponent),e&&(this.unmountComponent(this.svelteStubComponent),this.unmountComponent(this.svelteRootComponent),this.svelteErrorComponent=es(Bv,{target:this.playerContainer}))})}connectedCallback(){var e,i;if(this.rootContainer)return;this.initPlayerRootContainers();let o=(e=this.getAttribute("stub-title"))!=null?e:void 0,r=(i=this.getAttribute("stub-thumb-url"))!=null?i:void 0,a=li({title:o,thumbUrl:r}),l={target:this.playerContainer,props:a};this.svelteStubComponent=es(Dv,l),this.sveltePersistentLayerComponent=es(Kv,{target:this.playerContainer,props:Gv}),this.postponedInitParams&&(this.initPlayer(...this.postponedInitParams),this.postponedInitParams=null)}updatePersistentLayerProps(){if(!this.uiConfig)return;let{playbackStatusNextVideoAnimationDuration:e,features:{playbackStatusShow:i,playbackStatusNextVideoShow:o}}=this.uiConfig;Gv.animationDuration=e,Gv.playbackStatusShow=i&&o}disconnectedCallback(){var e,i,o,r,a,l,d;this.shadowDOMCallbacksDisabled||((e=this.annotationsApi)==null||e.destroy(),(i=this.slotsApi)==null||i.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(),Lc.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 i;let o=(i=this.store)==null?void 0:i.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,i={}){if(!this.videoConfig)return;let{deviceId:o,preload:r,refreshStatAuthToken:a}=Sc(this.videoConfig,i),{unitedVideoId:l}=e;if(this.uiConfig.features.thinStatistics&&l)return new QI.ThinOneStat({deviceId:o,movieId:l,preload:r,isPreviewPlayerView:this.videoConfig.playerView==="preview"},{config:this.statisticsConfig,refreshAuthToken:a})}createPlayer(e,i={},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:O,showThumbTimer:Ge,additionalButtons:K=[],additionalSettingsMenuItems:se=[],additionalContextMenuItems:xe=[],repeat:He,loop:ot,saveRate:ne,volumeMultiplier:ce,showEndScreen:Ne,showAutoplayNext:Le,mediascopePixels:et}=Sc(this.videoConfig,i),{sources:Ee,title:Te,thumbUrl:Fe,unitedVideoId:It,isClip:wt=!1,duration:Dt,adsParams:at={},videoEpisodes:Et,previewThumbsData:Zt,subtitles:Pt,subtitlesForcedLanguage:Ot,live:zt,adsExternalApi:j,adsJson:Pe}=e;if(!Ee&&!zt){let fi=new Error("empty sources and live");this.fatalError$.next(fi),(r=G.onCrashed)==null||r.call(G,fi.message);return}let le=Gs(Gs({},X),at),$e=this.getNextVideoInfo(),Me={sources:Ee,title:Te,thumbUrl:Fe,subtitles:Pt,subtitlesForcedLanguage:Ot,unitedVideoId:It,isClip:wt,live:zt,albumId:y,statPlace:_,autoplay:T,muted:A,volume:R,fromTime:P,canRewindLive:E,showAds:F,adsSlotId:U,adsParams:le,adsAutoplayParam:ae,duration:Dt,logoClickable:J,logoHidden:we,isTouch:ee!=null?ee:me,repeat:He,loop:ot,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(Me)}`});let St=(a=this.interactiveController)==null?void 0:a.state.statistics$.getValue(),fe=(St==null?void 0:St.oneStat)||this.createOneStat(e,i),Ue=this.createThinOneStat(e,i),ze;et&&(ze=new GI({pixels:et})),(fe||Ue)&&(this.statistics=new Xu(fe,Ue,ze,St==null?void 0:St.statSubscription)),this.uiConfig.features.sentry&&this.uiConfig.sentry.dsn&&new Ha(this.uiConfig.sentry,{version:Vl,env:$u},{movieId:It,albumId:y,place:_,autoplay:(l=T&&!this.interactiveController)!=null?l:!1,mobile:ee!=null?ee:me,clip:wt}),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),Ha.getInstance());let si=!!O,xt=[],Yt="tooltip_interactive_go_back_disabled_first";if(si&&this.interactiveController){let fi=this.interactiveController.state.isInitialChapter$.getValue(),nt=this.interactiveController.getHistoryState();fi&&xt.push("REPLAY_BUTTON"),this.interactiveController.getIsSeekable().getValue()||xt.push("SEEK_TO_INTERACTIVE_BUTTON"),nt.hasPrevChapter$.getValue()||(xt.push("PLAY_PREV_CHAPTER_BUTTON"),fi||(nt.isGoBackLimited$.getValue()?Yt="tooltip_interactive_go_back_disabled_limit":Yt="tooltip_interactive_go_back_disabled"))}let ci=()=>{var fi;this.isInited=!1,this.prevIsid=void 0;let nt=(o==null?void 0:o.info.isEnded$.getValue())&&((fi=this.interactiveController)==null?void 0:fi.state.isEndChapter$.getValue());G.onReplayInteractiveVideo&&!nt?G.onReplayInteractiveVideo():this.replayInteractiveVideo()},Hi=He&&this.videoConfig.videos.length===1;this.store=cb({player:o,interfaceLanguage:Z,isCyrillicRelatedInterface:re,videoId:It,isClip:wt,isLiveCatchUpMode:Ce,isAudioDisabled:_e,statAuthToken:x,callbacks:G,webApi:dt,videoEpisodes:Et,previewThumbsData:Zt,canDownload:Qe,uiConfig:this.uiConfig,coreConfig:this.coreConfig,metaConfig:this.metaConfig,disabledControls:xt,isInteractive:si,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:ci,playPrevChapterDisabledTooltip:Yt,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:fi=>{var nt;return(nt=this.sveltePersistentLayerComponent)==null?void 0:nt.startVideoChangedAnimation(fi)},looped:this.uiConfig.features.useLoopSetting?ot:Hi,statistics:this.statistics,internalsExposure:this.internalsExposure,playerView:this.videoConfig.playerView,playerId:this.playerId});let{stores:Rt}=this.microStoresRoot=Jb(),vo=()=>{var fi,nt,jt,Fi,$i,Jt;if(!this.store||!this.microStoresRoot||!this.videoConfig)return;this.subscription.add(this.store.state.currentFormat$.subscribe(st=>{var lt;return(lt=G==null?void 0:G.onCurrentFormatChanged)==null?void 0:lt.call(G,st)})),this.subscription.add(Rt.interactiveControlsOpacity$.subscribe(st=>{var lt;st!==null&&((lt=this==null?void 0:this.interactiveController)==null||lt.setDisabledControls(st))})),this.subscription.add(this.store.state.throughputEstimation$.subscribe(st=>{var lt;return(lt=G==null?void 0:G.onThroughputEstimationChanged)==null?void 0:lt.call(G,st)})),this.subscription.add(this.store.state.trafficSavingEnabled$.subscribe(st=>{var lt;return(lt=G==null?void 0:G.onTrafficSavingEnabledChanged)==null?void 0:lt.call(G,st)})),this.subscription.add(this.store.state.highQualityEnabled$.subscribe(st=>{var lt;return(lt=G==null?void 0:G.onHighQualityEnabledChanged)==null?void 0:lt.call(G,st)})),this.subscription.add(this.store.state.isAutoQualityEnabled$.subscribe(st=>{var lt;return(lt=G==null?void 0:G.onAutoQualityEnabledChanged)==null?void 0:lt.call(G,!!st)})),this.subscription.add(new HI(st=>{this.store&&this.subscription.add(this.store.state.currentPlaybackRate$.subscribe(lt=>st.next(lt)))}).pipe(zI(1)).subscribe(st=>{var lt;return(lt=G==null?void 0:G.onCurrentPlaybackRateChanged)==null?void 0:lt.call(G,st)})),this.subscription.add(this.store.state.volume$.subscribe(st=>{var lt;return(lt=G==null?void 0:G.onVolumeChange)==null?void 0:lt.call(G,st)})),this.subscription.add(this.store.state.muted$.subscribe(st=>{var lt,_i,Xo,No;if(st)(lt=G==null?void 0:G.onMute)==null||lt.call(G);else{let _t=(Xo=((_i=this.store)==null?void 0:_i.state.volume$)&&ye(this.store.state.volume$))!=null?Xo:0;(No=G==null?void 0:G.onUnmute)==null||No.call(G,_t)}})),this.subscription.add(this.store.state.videoBitrate$.subscribe(st=>{var lt;return(lt=G==null?void 0:G.onVideoBitrateChanged)==null?void 0:lt.call(G,st)})),this.subscription.add(this.store.state.isInteractiveTime$.subscribe(st=>{var lt;let _i=(lt=this.store)==null?void 0:lt.ui.controls.disabledControls$;_i&&(st&&!_i.includes(kd)&&_i.add(kd),st||_i.remove(kd))})),this.subscription.add(this.store.ui.isFullscreen.subscribe(st=>bp(this,null,function*(){var lt;if(!i$.browser.isSamsungBrowser||!st||!this.interactiveController)return;document.fullscreenElement===this.shadowRootContainer&&(yield this.replayInteractiveChapter((lt=this.videoConfig)==null?void 0:lt.callbacks.onExternalFullscreenExit))}))),this.statistics&&this.statistics.oneStat&&this.subscription.add(this.statistics.oneStat.vsid$.subscribe(st=>{var lt;return(lt=G==null?void 0:G.onVSIDChanged)==null?void 0:lt.call(G,st)})),this.initMediaSession(),N(er,{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:Pt,subtitlesForcedLanguage:Ot,live:zt,preload:I,autoplay:T,muted:A,volume:R,fromTime:P,canRewindLive:E,supportLink:z,showAds:F,adsSlotId:U,adsParams:le,adsAutoplayParam:ae,duration:Dt,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:j,adsJson:Pe,getVideoDeeplink:this.videoConfig.getVideoDeeplink},!0);let wi={target:this.playerContainer,props:n(er)};this.svelteRootComponent=es(Nv,wi),this.addPlayerInfoSubscriptions(),this.isInited||(this.isInited=!0,(jt=(nt=(fi=this.videoConfig)==null?void 0:fi.callbacks)==null?void 0:nt.onInited)==null||jt.call(nt)),(Fi=this.internalsExposure)==null||Fi.expose({player:this,videoConfig:this.videoConfig,coreConfig:this.coreConfig,uiConfig:this.uiConfig,statisticsConfig:this.statisticsConfig,logger:this.logger,log:this.log}),this.uiConfig.devNullLog&&((Jt=($i=this.videoConfig)==null?void 0:$i.callbacks)!=null&&Jt.onDevNullLog)?Lc.subscribe("ui",this.videoConfig.callbacks.onDevNullLog):Lc.destroy("ui")};this.coreConfig.asyncResolveClientChecker?i$.isInited$.subscribe(fi=>{fi&&(console.log("UI SDK async start"),vo())}):vo()}addPlayerInfoSubscriptions(){var e,i;let o=this.store,r=(e=this.microStoresRoot)==null?void 0:e.stores;if(!o||!r)return;let a=(i=this.videoConfig)==null?void 0:i.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,i=!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&&Qv(r.unitedVideoId)&&((o=this.store)==null||o.actions.internal.nextMovie(r.unitedVideoId)),this.unmountComponent(this.svelteRootComponent),this.createPlayer(r,{autoplay:i,fromTime:0},e)}playPrevChapter(){var e;(e=this.interactiveController)==null||e.playPrevChapter()}seekToInteractive(){var e;let i=(e=this.interactiveController)==null?void 0:e.getNextInteractiveStartTime();typeof i=="number"&&this.seekTime(i/1e3)}initInteractives(){return bp(this,null,function*(){var e,i,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=(i=this.store)==null?void 0:i.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]=VI(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(Ad)),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(Ad)})),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,i={}){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,i];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=Sc(YI,OI(e,Z=>Z instanceof qv?Z:void 0)),this.playerId=WI(e.playerId),this.uiConfig=Dh((a=i.ui)!=null?a:{}),this.updatePersistentLayerProps(),this.coreConfig=(l=i.core)!=null?l:{},this.statisticsConfig=(d=i.statistics)!=null?d:{},this.metaConfig=i.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 UI("ui",this.playerId))),Lc.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:[RI()]}),Qv(this.videoConfig.isMediaSessionEnabled)&&(this.uiConfig.features.mediaSession=(v=(p=this.uiConfig.features.mediaSession)!=null?p:this.videoConfig.isMediaSessionEnabled)!=null?v:!0),Qv(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=fp.getLatestSupportedVersion(Z):this.pictureInPictureApi=new Fa(Z)}this.mediaSessionApi=this.uiConfig.features.mediaSession?new pp:void 0,this.slotsApi=this.uiConfig.features.slots?new lp(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 _p(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]),Qb(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,i){if(!this.videoConfig)return;this.log({message:`update ${i} videos, videos: ${JSON.stringify(e)}`}),i==="prev"?(this.videoConfig.videos.splice(0,this.currentPlayingVideoIndex),this.videoConfig.videos.unshift(...e),this.currentPlayingVideoIndex=e.length):i==="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,i;this.mediaSessionApi&&((e=this.unsubscribePlayerPhaseSubscription)==null||e.call(this),this.mediaSessionApi.clearSubscriptions(),this.unsubscribePlayerPhaseSubscription=(i=this.store)==null?void 0:i.playerPhase.subscribe(o=>{o==="video"?this.setupMediaSessionForVideo():o==="ads"&&this.setupMediaSessionForAds()}))}setupMediaSessionForVideo(){if(!(!this.videoConfig||!this.mediaSessionApi))try{let{title:e,thumbUrl:i}=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:i}),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="Реклама",i=[["play",()=>this.play()],["pause",()=>this.pause()]];this.mediaSessionApi.setMetaData({title:e}),this.mediaSessionApi.updateActionHandlers(i),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,i,o,r;this.isControlDisabled("PLAY_BUTTON")||(e=this.store)!=null&&e.playerPhase.is("LiveWaitingStart")||(i=this.store)!=null&&i.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 i=!!this.interactiveController;i&&(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),i?(this.videoConfig.autoplay=!1,this.initInteractives()):this.createPlayer(o))}setMuted(e){var i;this.log({message:`set muted, muted: ${e}`}),(i=this.svelteRootComponent)==null||i.setMuted(e)}toggleSubtitle(){var e;this.log({message:"toggle subtitle"}),(e=this.svelteRootComponent)==null||e.toggleSubtitle()}changeSubtitle(e,i){var o;this.log({message:"change subtitle"}),(o=this.svelteRootComponent)==null||o.changeSubtitle(e,i)}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 i,o;(o=(i=this.store)==null?void 0:i.webApi.pictureInPictureApi)==null||o.setEnabled(e)}setVolume(e){var i;this.log({message:`set volume, volume: ${e}`}),(i=this.svelteRootComponent)==null||i.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 i;this.isControlDisabled("TIMELINE")||(this.log({message:`seek time, time: ${e}`}),(i=this.svelteRootComponent)==null||i.seekTime(e))}seekEpisodeStartTime(e){var i;this.log({message:`seek episode start time, time: ${e}`}),(i=this.svelteRootComponent)==null||i.seekEpisodeStartTime(e)}returnFocusToEpisodes(){var e;this.log({message:"return focus to episodes button"}),(e=this.svelteRootComponent)==null||e.returnFocusToEpisodes()}setPlaybackRate(e){var i;this.log({message:`set playback rate to: ${e}`}),(i=this.svelteRootComponent)==null||i.setPlaybackRate(e)}setAutoQualityLimits(e){var i,o,r;this.log({message:`set auto quality limitation. Max: ${(i=e.max)!=null?i:"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 i;(i=this.svelteRootComponent)==null||i.toggleTrafficSaving(e)}toggleHighQuality(e){var i;(i=this.svelteRootComponent)==null||i.toggleHighQuality(e)}changeAudioStream(e){var i;(i=this.svelteRootComponent)==null||i.changeAudioStream(e)}addLanguage(e){var i;(i=this.store)==null||i.actions.internal.addLanguage(e)}setLanguage(e){return bp(this,null,function*(){var i;yield(i=this.store)==null?void 0:i.actions.internal.setLanguage(e)})}setLiveStart(e){var i,o;let r=this.isLiveTailPlaying();this.log({message:`live started: liveTailPlaying = ${r}`}),r||((i=this.store)==null||i.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 i=(e=this.store)==null?void 0:e.getPlayer();if(!i)return!1;let{info:o}=i;return o.canPlayLiveTailBuffer$.getValue()&&!o.isStalled$.getValue()&&!o.atLiveEdge$.getValue()}setLiveWaitingRecover(e=!1){var i;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(),(i=this.store)!=null&&i.callbacks&&(this.store.callbacks.onLiveEnded=()=>{var l;r||a(),(l=this.store)==null||l.destroy()})}setLiveWaitingRecord(){var e;let i=this.isLiveTailPlaying(),o=!i;this.log({message:`live waiting record: liveTailPlaying = ${i}`});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 i;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}(i=this.store)!=null&&i.callbacks&&(this.store.callbacks.onLiveEnded=a)}setLiveLowLatency(e){var i;this.log({message:"live switch to low latency "+e}),(i=this.store)==null||i.actions.external.setLiveLowLatency(e)}setLooped(e){var i;(i=this.store)==null||i.actions.internal.setLooped(e)}getDebugData(){var e,i;return(i=(e=this.store)==null?void 0:e.actions.internal.getDebugTextData())!=null?i:""}getDeviceId(){var e,i,o;return(o=(i=(e=this.statistics)==null?void 0:e.oneStat)==null?void 0:i.getDeviceId())!=null?o:void 0}replayInteractiveVideo(){this.interactiveController&&this.interactiveController.setChapter()}replayInteractiveChapter(e){return bp(this,null,function*(){var i,o;if(this.interactiveController&&((i=this.store)!=null&&i.state.positionExact$)){let r=ye(this.store.state.positionExact$),l=ye(this.store.state.interactiveEpisodes$).find(s=>!s.completed);this.interactiveController.events.playerChanged$.pipe(FI()).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,i=!1){var o;(o=this.microStoresRoot)==null||o.stores.showInteractiveTimeIndicatorTooltip$.set(e,i)}switchToActiveLive(){var e;(e=this.store)==null||e.actions.internal.switchToActiveLive()}updateAdditionalSettingsItem(e,i){var o;(o=this.store)==null||o.actions.external.updateAdditionalSettingsItem(e,i)}addAdditionalSettingsItem(e){var i;(i=this.store)==null||i.actions.external.addAdditionalSettingsItem(e)}removeAdditionalSettingsItem(e){var i;(i=this.store)==null||i.actions.external.removeAdditionalSettingsItem(e)}updateAdditionalContextItem(e,i){var o;(o=this.store)==null||o.actions.external.updateAdditionalContextItem(e,i)}addAdditionalContextItem(e){var i;(i=this.store)==null||i.actions.external.addAdditionalContextItem(e)}removeAdditionalContextItem(e){var i;(i=this.store)==null||i.actions.external.removeAdditionalContextItem(e)}updateAdditionalButton(e,i){var o;(o=this.store)==null||o.actions.external.updateAdditionalButton(e,i)}addAdditionalButton(e){var i;(i=this.store)==null||i.actions.external.addAdditionalButton(e)}removeAdditionalButton(e){var i;(i=this.store)==null||i.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 i;(i=this.store)==null||i.actions.internal.setTimerNextVideoRunning(e)}togglePictureInPicture(){var e;(e=this.store)==null||e.actions.internal.togglePictureInPicture()}focus(){var e,i,o;(o=(i=(e=this.svelteRootComponent)==null?void 0:e.keyboardControls)==null?void 0:i.focus)==null||o.call(i)}restoreFocus(){var e;(e=this.focusManager)==null||e.restoreFocus()}handleExternalKeyboardEvent(e){var i,o;return!!((o=(i=this.svelteRootComponent)==null?void 0:i.keyboardControls)!=null&&o.handleExternalKeyboardEvent(e))}setAutoplayNext(e){var i;(i=this.store)==null||i.actions.internal.setAutoplayNextEnabled(e)}getTotalViewTime(){var e,i;return(i=(e=this.statistics)==null?void 0:e.thinOneStat)==null?void 0:i.getTotalViewTime()}unmountComponent(e){e&&Na(e)}};import{InterfaceLanguage as One,VKNumericLanguage as Dne,loadVKLangPack as Bne}from"@vkontakte/videoplayer-shared/es2015";import{VideoQuality as Fne,VideoFormat as Une}from"@vkontakte/videoplayer-core/es2015";var Pne=()=>{window.customElements.define("vk-video-player",$p)};export{Zu as ControlButtonType,_s as GridTypes,One as InterfaceLanguage,zd as MenuItemType,bs as PlayerPhase,Vl as VERSION,Dne as VKNumericLanguage,Une as VideoFormat,Fne as VideoQuality,Bne as loadVKLangPack,Pne as registerPlayerWebComponent};
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 cm(i,e){B(e,!0);let t=h(e,"isSubtitlesEnabled",3,!1),r=xe().ui.t,a=f(()=>t()?r("tooltip_subtitles_on"):r("tooltip_subtitles_off"));Ut(i,{testId:"subtitles-btn",get ariaLabel(){return n(a)},get click(){return e.click},get ariaKeyShortCut(){return hs.KeyC},role:"button",children:(l,d)=>{let s=f(()=>t()?void 0:"outline");ua(l,{get size(){return"24"},get type(){return n(s)}})},$$slots:{default:!0}}),H()}var Z0=L('<span class="duration s-1z" data-testid="video_duration"> </span>'),J0=L('<div data-testid="time"><span class="current s-1z" data-testid="current_time"> </span> <!></div>'),ex={hash:"s-1z",code:'.time.s-1z{align-items:center;color:var(--controls-time);display:flex;font-variant-numeric:tabular-nums;font-weight:500;padding:12px 6px}.time.mobile.s-1z{padding:0 0 0 8px}.current.s-1z{position:relative}.duration.s-1z{opacity:.7}.duration.s-1z:before{content:" / ";white-space:pre}'};function qd(i,e){B(e,!0),Q(i,ex);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=Rt(),d=ae(!1),s=f(()=>jo(e.duration)),u=f(()=>jo(e.position));var m=J0();let p;var v=T(m),b=T(v,!0);S(v);var y=A(v,2);{var _=x=>{var I=Z0(),C=T(I,!0);S(I),D(()=>he(C,n(s))),$(x,I)};V(y,x=>{r()&&x(_)})}S(m),Vs(m,()=>Vl(o()&&l.features.usePerformanceFix,d,l.disableInvisibleComponentsTimeout)),it(m,x=>a(x),()=>a()),D(x=>{p=ne(m,1,"time s-1z",null,p,x),he(b,n(u))},[()=>({mobile:t()})]),$(i,m),H()}import{noop as Uu}from"@vkontakte/videoplayer-shared/es2015";var tx=Pe('<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),ix=Pe("<path></path>"),ox=Pe('<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 pa(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(()=>un(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=ox(),v=A(le(p));{var b=_=>{var x=tx();ti(),$(_,x)},y=_=>{var x=ix();D(()=>De(x,"d",`${d}${n(a)==="max"?s:""}`)),$(_,x)};V(v,_=>{n(a)==="off"?_(b):_(y,!1)})}$(u,p)},$$slots:{default:!0}}),H()}import{isNonNullable as X_,noop as qn}from"@vkontakte/videoplayer-shared/es2015";import{noop as pm}from"@vkontakte/videoplayer-shared/es2015";import{noop as rx}from"@vkontakte/videoplayer-shared/es2015";var nx=L('<div class="overlay"><!></div>');function um(i,e){B(e,!0);let[t,o]=Be(),r=()=>w(l,"$overlayContainer$",t),l=xe().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))};He(()=>{u(r())}),Vt(()=>(u(r()),()=>s(r())));var m=nx(),p=T(m);oi(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 sx=L('<div class="tooltip s-1p"><div class="content s-1p"> </div> <div class="tooltip-pointer s-1p"></div></div>'),ax=L("<div><!></div> <!>",1),lx={hash:"s-1p",code:'.tooltip-wrapper.s-1p{display:flex;flex-direction:column;min-width:0}.full-width.s-1p{width:100%}.tooltip.s-1p{bottom:100%;left:0;opacity:0;position:absolute;transition:opacity .2s,visibility .2s;visibility:hidden}.content.s-1p{background-color:rgba(41,41,41,.8);border-radius:3px;color:var(--white);display:inline-block;padding:6px 10px}.tooltip-pointer.s-1p{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 Wa(i,e){B(e,!0),Q(i,lx);let[t,o]=Be(),r=()=>w(j,"$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,rx),_=5,x=K(void 0),I=K(void 0),C,R=K(0),k=K(0),P=K(0),E=K(0),W=Rt(),F=xe(),U=F.ui.playerSize,j=F.ui.overlayContainer$;He(()=>{Pt(()=>{y()(s())})});let se=F.getLogger().createComponentLog("Tooltip component"),G=ie=>{if(!r()||!n(I)||!n(x))return;O(k,_);let We=r().getBoundingClientRect(),ee=n(x).getBoundingClientRect(),ke=ee.width,Ue=n(I).clientWidth,Ie=a().width,Ae=(ke-Ue)/2,Ne=ee.left+u()-We.left,gt=Ne+Ae,It=ee.top+m()-We.top,Lt=Ue/2-_,lt=gt<8,Et=gt+Ue>Ie-8;ie==="top-left"&&(gt=Ne),lt&&(gt=8,Lt=Ne+ee.width/2-2.5*_),Et&&(gt=Ie-8-Ue,Lt=ee.left-We.left+ee.width/2-gt-_),O(P,gt,!0),O(E,It),O(R,Lt,!0)},re=()=>{!r()||!n(I)||!n(x)||O(k,-_)},X=()=>{if(!r()||!n(I)||!n(x))return;O(R,_);let ie=r().getBoundingClientRect(),We=n(x).getBoundingClientRect(),ee=We.height,ke=n(I).clientHeight,Ue=(ee-ke)/2+ke,Ie=We.left+u()-ie.left-n(I).clientWidth,Ae=2,Ne=Ie-_;Ne<8&&(Ne=8);let It=We.top+m()-ie.top+Ue,Lt=Ae-Ue/2,lt=Ae-_;O(P,Ne,!0),O(E,It),O(k,Lt),O(R,lt)},Te=()=>{!r()||!n(I)||!n(x)||O(R,-_)},ue=()=>{switch(b()){case"top":G();break;case"bottom":re();break;case"left":X();break;case"top-left":G("top-left");break;default:Te();break}},te=()=>{try{if(!r()||!n(x))return;ue(),s(!0)}catch(ie){se({message:String(ie)})}},be=()=>{s(!1)},Ce=()=>{n(I)&&(C||(C=window.setTimeout(te,W.controls.hideTimeoutTooltips)),s()&&te())},me=()=>{be(),window.clearTimeout(C),C=void 0},qe=(ie,We,ee)=>{let ke="";switch(b()){case"top":ke=`transform: translate(${ie}px, ${We}px);`;break;case"bottom":ke=`transform: translate(${ie}px, ${We}px); top: auto; bottom: 100%;`;break;case"left":ke=`transform: translate(${ie}px, ${We}px); left: 0; right: auto;`;break;default:ke=`transform: translate(${ie}px, ${We}px);`}return ke+=` max-width: ${v()===void 0?"auto":`${v()}px`};`,ke+=` opacity: ${ee?1:0}; visibility: ${ee?"visible":"hidden"}`,ke},ve=(ie,We)=>{let ee="";switch(b()){case"top-left":case"top":ee=`transform: translate(${ie}px, ${We}px) rotate(0); top: auto; bottom: 0;`;break;case"bottom":ee=`transform: translate(${ie}px, ${We}px) rotate(180deg); top: 0; bottom: auto;`;break;case"left":ee=`transform: translate(${ie}px, ${We}px) rotate(-90deg); left: 100%; top: auto; bottom: 0;`;break;default:ee=`transform: translate(${ie}px, ${We}px) rotate(90deg); right: 100%; top: auto; bottom: 0;`}return ee},pe=f(()=>qe(n(P),n(E),s())),Z=f(()=>ve(n(R),n(k)));Vt(ue),cn(()=>window.clearTimeout(C));var N=ax(),ce=le(N);let de;ce.__pointermove=Ce,ce.__pointerdown=me,ce.__pointerup=function(...ie){var We;(We=e.disableMouseupTooltipShow?void 0:Ce)==null||We.apply(this,ie)};var _e=T(ce);oi(_e,()=>{var ie;return(ie=e.children)!=null?ie:_t}),S(ce),it(ce,ie=>O(x,ie),()=>n(x));var ge=A(ce,2);{var ze=ie=>{um(ie,{children:(We,ee)=>{var ke=sx(),Ue=T(ke),Ie=T(Ue,!0);S(Ue);var Ae=A(Ue,2);S(ke),it(ke,Ne=>O(I,Ne),()=>n(I)),D(()=>{je(ke,n(pe)),he(Ie,d()),je(Ae,n(Z))}),$(We,ke)},$$slots:{default:!0}})};V(ge,ie=>{d()&&!l()&&ie(ze)})}D(ie=>de=ne(ce,1,"tooltip-wrapper s-1p",null,de,ie),[()=>({"full-width":p()})]),ft("pointerenter",ce,Ce),ft("pointerleave",ce,me),$(i,N),H(),o()}Je(["pointermove","pointerdown","pointerup"]);var j_=i=>{i.stopPropagation()},dx=L("<div><!></div>"),cx={hash:"s-1m",code:".btn-container.s-1m{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-1m{min-width:0;width:100%}"};function Mo(i,e){B(e,!0),Q(i,cx);let[t,o]=Be(),r=()=>w(u,"$isGraphOpened$",t),a=()=>w(s,"$isMobile",t),l=xe(),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"),k=h(e,"disabledTooltipContent",19,()=>m("tooltip_button_disabled")),P=h(e,"isAriaHidden",3,!1),E=h(e,"onTooltipVisibilityChange",3,pm),W=h(e,"initialTranslateXPx",3,0),F=h(e,"initialTranslateYPx",19,()=>-18),U=h(e,"mouseEnter",3,pm),j=h(e,"mouseLeave",3,pm),se=f(()=>v()?r()?m("tooltip_disabled_when_graph_on"):k():I()),G=K(!1);He(()=>{C()||O(G,!1)});var re=dx();re.__pointerdown=[j_],re.__click=[j_];var X=T(re);{var Te=te=>{Wa(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(G)},set active(be){O(G,be,!0)},children:(be,Ce)=>{var me=Oe(),qe=le(me);oi(qe,()=>{var ve;return(ve=e.children)!=null?ve:_t}),$(be,me)},$$slots:{default:!0}})},ue=te=>{var be=Oe(),Ce=le(be);oi(Ce,()=>{var me;return(me=e.children)!=null?me:_t}),$(te,be)};V(X,te=>{b()&&n(se)&&!a()?te(Te):te(ue,!1)})}S(re),it(re,te=>y(te),()=>y()),D(()=>{var te;ne(re,1,`btn-container ${(te=p())!=null?te:""}`,"s-1m"),De(re,"aria-hidden",P()||null)}),ft("mouseenter",re,function(...te){var be;(be=U())==null||be.apply(this,te)}),ft("mouseleave",re,function(...te){var be;(be=j())==null||be.apply(this,te)}),Sn(re,"clientWidth",_),$(i,re),H(),o()}Je(["pointerdown","click"]);var ux=Pe('<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 Qd(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=ux(),l=le(a),d=A(l);D(()=>{De(l,"fill",ra),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>"),fx={hash:"s-1h",code:".interactive-episode-icon.s-1h{cursor:default;height:20px;position:absolute;transform:translateX(-50%);width:20px}.interactive-episode-icon.disabled.s-1h{opacity:.4;pointer-events:none}"};function fm(i,e){B(e,!0),Q(i,fx);let o=xe().ui.t,r=K(0),a=f(()=>o(e.videoEpisode.completed?"tooltip_episode_finished":"tooltip_episode_unfinished"));Mo(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);Qd(m,{get completed(){return n(p)}}),S(s),D(v=>{u=ne(s,1,"interactive-episode-icon s-1h",null,u,v),je(s,`left: ${e.videoEpisode.from+e.videoEpisode.width/2}%`)},[()=>({disabled:e.disabled})]),Sn(s,"clientWidth",v=>O(r,v)),$(l,s)},$$slots:{default:!0}}),H()}var mx=L('<div><div class="video-episode-inner s-1g"><div class="video-episode-loaded s-1g"></div> <div></div></div></div>'),vx=L('<div class="video-episodes-wrap s-1g"></div>'),gx={hash:"s-1g",code:".video-episodes-wrap.s-1g{height:100%;position:absolute;width:100%}.video-episode.s-1g{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-1g:first-child{padding-left:0}.video-episode.s-1g:last-child{padding-right:0}.video-episode.s-1g:not(.disabled):where(:hover,:active){transform:scaleY(1.5)}.video-episode-filled.s-1g,.video-episode-inner.s-1g,.video-episode-loaded.s-1g{border-radius:var(--slider-radius);height:var(--slider-height);position:absolute}.video-episode-inner.s-1g{background:var(--slider-bg);overflow:hidden;position:absolute;width:calc(100% - var(--slider-video-episode-gap)*2)}.video-episode.s-1g:first-child .video-episode-inner:where(.s-1g),.video-episode.s-1g:last-child .video-episode-inner:where(.s-1g){width:calc(100% - var(--slider-video-episode-gap))}.video-episode-loaded.s-1g{background:var(--slider-loaded-bg);transition:transform .2s}.video-episode-filled.s-1g,.video-episode-loaded.s-1g{border-radius:var(--slider-radius);height:100%;left:-100%;position:absolute;width:100%}.video-episode-filled.s-1g{background-color:var(--slider-filled-bg)}"};function mm(i,e){Q(i,gx);let t=h(e,"videoEpisodes",19,()=>[]);var o=vx();bi(o,21,t,r=>r.from,(r,a)=>{var l=mx();let d;var s=T(l),u=T(s),m=A(u,2);let p;S(s),S(l),D((v,b)=>{d=ne(l,1,"video-episode s-1g",null,d,v),je(l,`left: ${n(a).from}%; width: ${n(a).width}%`),je(u,`transform: translateX(${n(a).loadedWidth/n(a).width*100}%)`),p=ne(m,1,"video-episode-filled s-1g",null,p,b),je(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 hx(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 _x(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 bx(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 $x(i,e,t,o){i.stopPropagation(),i.preventDefault(),e()&&t()(o(i.clientX,i.clientY))}function yx(i,e,t,o,r,a){let l=e(i.clientX,i.clientY);t()&&o()(l),O(r,!1),a()(l)}var xx=L("<div></div>"),wx=L('<div class="bars s-t"><div class="loaded s-t"></div> <div></div></div>'),Sx=L('<!> <div role="slider" tabindex="0"><!> <div><div></div></div></div>',1),Cx={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 Ka(i,e){B(e,!0),Q(i,Cx);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,qn),x=h(e,"onHandleMove",3,qn),I=h(e,"onPointerUp",3,qn),C=h(e,"onPointerEnter",3,qn),R=h(e,"onPointerMove",3,qn),k=h(e,"onPointerLeave",3,qn),P=h(e,"onMouseEnter",3,qn),E=h(e,"onMouseLeave",3,qn),W=h(e,"onWheelUp",3,qn),F=h(e,"onWheelDown",3,qn),U=h(e,"onWheelLeft",3,qn),j=h(e,"onWheelRight",3,qn),se=h(e,"onDisabledClick",3,qn),G=h(e,"loadedProgress",3,0),re=h(e,"filledProgress",3,0),X=h(e,"handleProgress",3,0),Te=h(e,"ariaLabel",3,""),ue=h(e,"ariaValueMin",3,void 0),te=h(e,"ariaValueMax",3,void 0),be=h(e,"ariaValueNow",3,void 0),Ce=h(e,"ariaValueText",3,""),me=h(e,"onContextMenu",3,qn),qe=h(e,"handleAlwaysVisible",3,!1),ve=Rt(),pe=K(void 0),Z=K(!1),N=f(()=>{var we;return(we=te())!=null?we:0}),ce=f(()=>{var we;return X_(m())&&((we=m()[m().length-1])==null?void 0:we.time)<n(N)}),de=f(()=>X_(m())&&m().length&&n(ce)&&n(N)?Ue(G()*100,re()*100):[]);function _e(we){if(we.preventDefault(),t()&&O(pe,t().getBoundingClientRect(),!0),b())return;let Ke=ee(we.clientX,we.clientY),Se=ke(we.clientX);C()(Ke,Se,n(pe).width)}function ge(we){we.preventDefault(),!b()&&k()()}function ze(){P()()}function ie(){E()()}function We(we){b()||p()&&(we.preventDefault(),we.deltaY<0?W()():we.deltaY>0?F()():we.deltaX>0?j()():U()())}function ee(we,Ke){return l()?Math.max(0,Math.min(1,(n(pe).height-(Ke-n(pe).top))/n(pe).height)):Math.min(Math.max(we-n(pe).x,0),n(pe).width)/n(pe).width}function ke(we){return Math.min(Math.max(we-n(pe).x,0),n(pe).width)}function Ue(we,Ke){let Se=ve.features.episodesClustering&&!v()?ve.episodeMinWidthPc:0,yt=[],ye=m()[0].time/n(N)*100,Fe=0,Qe=0;for(let Nt=1;Nt<m().length;Nt++)Fe=m()[Nt].time/n(N)*100,Fe-ye>Se&&(yt.push({from:ye,width:Math.max(0,Fe-ye),loadedWidth:Math.max(0,Math.min(Fe,we)-ye),filledWidth:Math.max(0,Math.min(Fe,Ke)-ye),interactive:m()[Nt-1].interactive,completed:m()[Nt-1].completed}),ye=m()[Nt].time/n(N)*100,Qe++);let rt={from:ye,width:Math.max(0,100-ye),loadedWidth:Math.max(0,Math.min(we,100)-ye),filledWidth:Math.max(0,Math.min(Ke,100)-ye),interactive:m()[Qe].interactive,completed:m()[Qe].completed};100-ye<Se?(Qe-=1,yt[Qe].width+=100-ye,yt[Qe].loadedWidth+=Math.max(0,Math.min(we,100)-ye),yt[Qe].filledWidth+=Math.max(0,Math.min(Ke,100)-ye)):yt[Qe]=rt;let Kt=m()[0].time;if(Kt!==0){let Nt=Kt/n(N)*100;yt.unshift({from:0,width:Nt,loadedWidth:Math.min(Nt,we),filledWidth:Math.min(Nt,Ke)})}return yt}function Ie(we){return Math.max(0,Math.min(100,we*100))}let Ae=f(()=>Ie(G())),Ne=f(()=>Ie(re()));var gt=Sx(),It=le(gt);{var Lt=we=>{var Ke=xx();let Se;bi(Ke,21,()=>n(de),yt=>yt.from,(yt,ye)=>{var Fe=Oe(),Qe=le(Fe);{var rt=Kt=>{fm(Kt,{get videoEpisode(){return n(ye)},get disabled(){return b()}})};V(Qe,Kt=>{n(ye).interactive&&Kt(rt)})}$(yt,Fe)}),S(Ke),D(yt=>Se=ne(Ke,1,"interactive-icons s-t",null,Se,yt),[()=>({mobile:s(),hidden:s()&&!n(Z)})]),$(we,Ke)};V(It,we=>{v()&&we(Lt)})}var lt=A(It,2);let Et;lt.__pointerdown=[hx,t,pe,b,Z,ee,_],lt.__pointermove=[_x,b,ee,ke,R,pe,Z,x],lt.__pointerup=[bx,b,Z,ee,I],lt.__click=[$x,b,se,ee],lt.__contextmenu=[yx,ee,b,se,Z,me];var jt=T(lt);{var zt=we=>{mm(we,{get videoEpisodes(){return n(de)},get disabled(){return b()},get isMobile(){return s()}})},Ot=we=>{var Ke=wx(),Se=T(Ke),yt=A(Se,2);let ye;S(Ke),D(Fe=>{De(Se,"data-value",n(Ae)),je(Se,`transform: translateX(${n(Ae)}%);`),ye=ne(yt,1,"filled s-t",null,ye,Fe),De(yt,"data-value",n(Ne)),je(yt,`transform: translateX(${n(Ne)}%);`)},[()=>({"active-live":d()})]),$(we,Ke)};V(jt,we=>{n(de).length?we(zt):we(Ot,!1)})}var Wt=A(jt,2);let q;var Le=T(Wt);let Re;S(Wt),S(lt),it(lt,we=>t(we),()=>t()),D((we,Ke,Se,yt)=>{var ye,Fe;Et=ne(lt,1,`slider ${(ye=o())!=null?ye:""}`,"s-t",Et,we),De(lt,"aria-label",Te()),De(lt,"aria-valuemin",ue()),De(lt,"aria-valuemax",te()),De(lt,"aria-valuenow",be()),De(lt,"aria-valuetext",Ce()),De(lt,"data-testid",(Fe=r())!=null?Fe:null),q=ne(Wt,1,"handleWrap s-t",null,q,Ke),je(Wt,Se),Re=ne(Le,1,"handle s-t",null,Re,yt)},[()=>({disabled:b(),"slider-dragging":n(Z),hidden:a(),"handle-always-visible":qe(),"slider-vertical":l(),"no-handle":y(),square:u()}),()=>({hidden:y()}),()=>`transform: translateX(${Ie(X())}%);`,()=>({"active-live":d()})]),ft("pointerenter",lt,_e),ft("pointerleave",lt,ge),ft("mouseenter",lt,ze),ft("mouseleave",lt,ie),ft("wheel",lt,We),$(i,gt),H()}Je(["pointerdown","pointermove","pointerup","click","contextmenu"]);var oo=(i,e)=>Ad[i]>=Ad[e];var Ns=(i,e)=>Ad[i]<=Ad[e],Z_=i=>i>699?"xl":i>599?"l":i>509?"m":i>320?"s":"xs";var Ix=L("<div><!></div>"),Ex=L("<div><!> <!></div>"),Px={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 vm(i,e){var ke,Ue;B(e,!0),Q(i,Px);let[t,o]=Be(),r=()=>w(R,"$isAudioAvailable$",t),a=()=>w(v,"$muted$",t),l=()=>w(p,"$volume$",t),d=()=>w(x,"$currentGridType$",t),s=()=>w(_e,"$controlsVisible",t),u=xe(),m=Rt(),p=u.state.volume$,v=u.state.muted$,{setVolume:b,startVolumeChanging:y,stopVolumeChanging:_}=u.actions.internal,x=u.ui.currentGridType$,I=(ke=u.callbacks)==null?void 0:ke.onAudioDoesNotExistHint,C=(Ue=u.callbacks)==null?void 0:Ue.onAudioDisabledHint,R=u.state.isAudioAvailable$,k=u.state.isAudioDisabled,P=u.ui.t,E=K(!1),W,F=f(()=>e.isAds||r()),U=f(()=>!n(F)||a()||l()===0),j=f(()=>Ns(d(),"l")),se=f(()=>n(j)?"":n(U)?!r()||k?P("tooltip_sound_unavailable"):P("tooltip_volume"):P("tooltip_volume_muted")),G=f(()=>n(U)?P("tooltip_volume"):P("tooltip_volume_muted")),re=f(()=>n(U)?0:l()),X=!1,Te=f(()=>e.isAds?!1:k?!C:r()?!1:!I);function ue(Ie){y(),b(Ie)}function te(){Nu(u,l(),m.controls.volumeStepWheel)}function be(){Bu(u,l(),m.controls.volumeStepWheel)}function Ce(Ie){b(Ie)}function me(Ie){b(Ie),_()}function qe(){X=!0}function ve(){X=!1,N()}function pe(){clearTimeout(W),O(E,!0)}function Z(){N()}function N(){W=window.setTimeout(()=>{X||O(E,!1)},m.controls.volumeBarTimeout)}function ce(Ie){Ie.preventDefault(),Ie.deltaY<0?te():Ie.deltaY>0&&be()}let de=K(!1),_e=u.ui.controlsVisible;He(()=>{s()||O(de,!1)});var ge=Ex();let ze;var ie=T(ge);Wa(ie,{get content(){return n(se)},translateY:-18,get active(){return n(de)},set active(Ie){O(de,Ie,!0)},children:(Ie,Ae)=>{let Ne=f(()=>n(j)?"btn-volume-vertical":"btn-volume-horizontal");Ut(Ie,{className:"btn-full-opacity",get disabled(){return n(Te)},get testId(){return n(Ne)},get ariaLabel(){return n(G)},get click(){return e.click},get ariaKeyShortCut(){return hs.KeyM},role:"button",children:(gt,It)=>{pa(gt,{get size(){return"24"},get volume(){return l()},get muted(){return n(U)}})},$$slots:{default:!0}})},$$slots:{default:!0}});var We=A(ie,2);{var ee=Ie=>{var Ae=Ix();let Ne;var gt=T(Ae);let It=f(()=>n(j)?"volumeBar-slider-vertical":""),Lt=f(()=>n(j)&&!n(E)),lt=f(()=>n(j)?qe:Uu),Et=f(()=>n(j)?ve:Uu),jt=f(()=>Math.round(n(re)*100)),zt=f(()=>`${Math.round(n(re)*100)}%`),Ot=f(()=>n(j)?"volume-slider-vertical":"volume-slider");Ka(gt,{get className(){return n(It)},get isHidden(){return n(Lt)},get isVertical(){return n(j)},withWheelHandler:!0,onWheelUp:te,onWheelDown:be,onPointerDown:ue,onHandleMove:Ce,onPointerUp:me,get onPointerEnter(){return n(lt)},get onPointerLeave(){return n(Et)},ariaLabel:"Ползунок громкости",ariaValueMin:0,ariaValueMax:100,get ariaValueNow(){return n(jt)},get ariaValueText(){return n(zt)},get filledProgress(){return n(re)},get handleProgress(){return n(re)},get testId(){return n(Ot)}}),S(Ae),D(Wt=>Ne=ne(Ae,1,"volumeBar s-27",null,Ne,Wt),[()=>({"volumeBar-vertical":n(j)})]),$(Ie,Ae)};V(We,Ie=>{n(F)&&Ie(ee)})}S(ge),D(Ie=>ze=ne(ge,1,"volumeBar-container s-27",null,ze,Ie),[()=>({vertical:n(j)})]),ft("mouseenter",ge,function(...Ie){var Ae;(Ae=n(j)?pe:Uu)==null||Ae.apply(this,Ie)}),ft("mouseleave",ge,function(...Ie){var Ae;(Ae=n(j)?Z:Uu)==null||Ae.apply(this,Ie)}),ft("wheel",ge,ce),$(i,ge),H(),o()}import{noop as Lx}from"@vkontakte/videoplayer-shared/es2015";var Ax=Pe('<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>'),kx=Pe('<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 gm(i,e){let t=h(e,"isFullscreen",8,!1),o=lr(()=>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=Ax();$(m,p)},u=m=>{var p=kx();$(m,p)};V(d,m=>{t()?m(s):m(u,!1)})}$(r,l)},$$slots:{default:!0}})}function Gd(i,e){B(e,!0);let t=h(e,"isFullscreen",3,!1),o=h(e,"click",3,Lx),r=xe(),a=r.ui.isFullscreenOpenedByKeyboard,l=r.ui.t,d=f(()=>t()?l("tooltip_fullscreen_on"):l("tooltip_fullscreen_off"));Ut(i,{testId:"fullscreen-btn",get ariaLabel(){return n(d)},click:u=>{let m=da(u);a.set(m),o()()},get ariaKeyShortCut(){return hs.KeyF},role:"button",children:(u,m)=>{gm(u,{get isFullscreen(){return t()}})},$$slots:{default:!0}}),H()}var Mx=Pe('<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 hm(i,e){let t=Cn(e,["$$slots","$$events","$$legacy","children"]);var o=Mx();io(o,()=>Me({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);oi(r,()=>{var a;return(a=e.children)!=null?a:_t}),ti(),S(o),$(i,o)}var Vx=Pe('<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 _m(i,e){let t=Cn(e,["$$slots","$$events","$$legacy","children"]);var o=Vx();io(o,()=>Me({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);oi(r,()=>{var a;return(a=e.children)!=null?a:_t}),ti(6),S(o),$(i,o)}var Rx={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 bm(i,e){B(e,!0),Q(i,Rx);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`);_m(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 Yd(i,e){B(e,!0);let[t,o]=Be(),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=Rt(),p=xe(),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()&&Ns(a(),"m")||Ns(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")},k=f(()=>!s()),P=f(()=>n(x)?"btn-vk-video-logo":"btn-vk-logo");Ut(i,{className:"btn-full-opacity",get disabled(){return n(k)},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 j=G=>{bm(G,{get logo(){return m.logoType},get short(){return n(C)},get isCyrillic(){return l()}})},se=G=>{hm(G,{})};V(U,G=>{n(x)?G(j):G(se,!1)})}$(E,F)},$$slots:{default:!0}}),H(),o()}import{ChromecastState as Bx}from"@vkontakte/videoplayer-core/es2015";import{ChromecastState as eb}from"@vkontakte/videoplayer-core/es2015";var Ox=Pe('<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),Dx=Pe('<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),Nx={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 jd(i,e){B(e,!0),Q(i,Nx);let t=h(e,"isMobile",3,!1),o=f(()=>e.iconState===eb.CONNECTED),r=f(()=>e.iconState===eb.CONNECTING),a=f(()=>n(o)?"#2688EB":ra),l=f(()=>e.size?un(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=Ox();ti(2),$(v,y)},$$slots:{default:!0}})},m=p=>{Ze(p,{get style(){return n(l)},testId:"chromecast-icon",children:(v,b)=>{var y=Dx(),_=le(y);let x;var I=A(_);let C;var R=A(I);let k;var P=A(R);let E;var W=A(P);let F;D((U,j,se,G,re)=>{x=ne(_,0,"wave2 s-18",null,x,U),C=ne(I,0,"wave3 s-18",null,C,j),k=ne(R,0,"wave1 s-18",null,k,se),E=ne(P,0,"s-18",null,E,G),F=ne(W,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()}import{noop as Hx}from"@vkontakte/videoplayer-shared/es2015";function Xd(i,e){B(e,!0);let t=h(e,"ref",15,void 0),o=h(e,"isMobile",3,!1),r=h(e,"click",3,Hx),l=xe().ui.t,d=f(()=>e.state===Bx.CONNECTED?l("tooltip_chromecast_on"):l("tooltip_chromecast_off"));Ut(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)=>{jd(s,{get isMobile(){return o()},get iconState(){return e.state}})},$$slots:{default:!0}}),H()}import{noop as Ux}from"@vkontakte/videoplayer-shared/es2015";var Fx=Pe('<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 $m(i){Ze(i,{testId:"episodes-icon",children:(e,t)=>{var o=Fx();ti(2),$(e,o)},$$slots:{default:!0}})}var zu=(i,e,t)=>t.filter(o=>o.time<=i*e).pop();var zx=L('<span class="text mobile s-21"> </span> <div class="chevron-episodes s-21" data-testid="btn-episodes_icon"><!></div>',1),Wx=L('<span class="text s-21"> </span>'),Kx=L('<span class="text count s-21"> </span>'),qx=L('<span class="icon s-21"><!></span> <!>',1),Qx={hash:"s-21",code:".icon.s-21{flex-shrink:0}.text.s-21{overflow:hidden;padding:0 8px;text-overflow:ellipsis;white-space:nowrap}.text.count.s-21{overflow:visible}.text.mobile.s-21{padding:0 3px 0 4px}.chevron-episodes.s-21{margin-bottom:-6px;opacity:.7;transform:scale(.8)}"};function Zd(i,e){var X,Te,ue;B(e,!0),Q(i,Qx);let[t,o]=Be(),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=xe(),v=(Te=(X=p.callbacks)==null?void 0:X.onEpisodeChanged)!=null?Te:Ux,b=!!((ue=p.callbacks)!=null&&ue.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),k=te=>{var Ce,me,qe;if(!!((Ce=p.callbacks)!=null&&Ce.onEpisodeClicked)){let ve=da(te);_.set(ve),x.set(!0),(qe=(me=p.callbacks)==null?void 0:me.onEpisodeClicked)==null||qe.call(me,ve)}},P=K(null),E=f(()=>s()/u());He(()=>{var be;let te=zu(n(E),u(),m());te?((be=n(P))==null?void 0:be.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(()=>oo(r(),"xl")?"FULL":oo(r(),"m")?"COUNT":"SHORT"),U=f(()=>`${C("tooltip_episodes")}: ${n(W)}`),j=(te,be,Ce)=>ht(null,null,function*(){yield ho(),(te==null?void 0:te.getAttribute("aria-expanded"))==="false"&&be&&!Ce&&Pt(()=>{_.set(!1),te.focus()})});He(()=>{j(n(R),a(),l())});var se=Oe(),G=le(se);{var re=te=>{let be=f(()=>d()?"px-0":""),Ce=f(()=>!b);Ut(te,{get className(){var me;return`w-max btn-full-opacity btn-jc-l ${(me=n(be))!=null?me:""}`},testId:"btn-episodes",click:k,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,qe)=>{var ve=Oe(),pe=le(ve);{var Z=ce=>{var de=zx(),_e=le(de),ge=T(_e,!0);S(_e);var ze=A(_e,2),ie=T(ze);Nr(ie,{direction:"right"}),S(ze),D(()=>he(ge,n(W))),$(ce,de)},N=ce=>{var de=qx(),_e=le(de),ge=T(_e);$m(ge,{}),S(_e);var ze=A(_e,2);{var ie=ee=>{var ke=Wx(),Ue=T(ke,!0);S(ke),D(()=>he(Ue,n(W))),$(ee,ke)},We=(ee,ke)=>{{var Ue=Ie=>{var Ae=Kx(),Ne=T(Ae,!0);S(Ae),D(()=>he(Ne,m().length)),$(Ie,Ae)};V(ee,Ie=>{n(F)==="COUNT"&&Ie(Ue)},ke)}};V(ze,ee=>{n(F)==="FULL"?ee(ie):ee(We,!1)})}$(ce,de)};V(pe,ce=>{d()?ce(Z):ce(N,!1)})}$(me,ve)},$$slots:{default:!0}})};V(G,te=>{n(P)&&te(re)})}$(i,se),H(),o()}import{debounceFn as wb}from"@vkontakte/videoplayer-shared/es2015";import{ChromecastState as o2,PlaybackState as zl,Player as n2,PredefinedQualityLimits as ys,VideoFormat as tc,clientChecker as cb}from"@vkontakte/videoplayer-core/es2015";import{assertNonNullable as pr,getHighestQuality as r2,InterfaceLanguage as s2,isInvariantQuality as a2,isNonNullable as l2,loadVKLangPack as d2,Logger as c2,map as ub,merge as u2,Observable as Zu,Subject as ic,Subscription as Pm,TracerFactory as p2,ValueSubject as pb,VideoQuality as f2,devNull as m2,now as v2,filter as fb,once as g2}from"@vkontakte/videoplayer-shared/es2015";import{SeekAction as Fs,ThinOneStat as h2}from"@vkontakte/videoplayer-statistics/es2015";import{detectEmbed as Gx,devNull as ri,now as si,withoutNullable as tb}from"@vkontakte/videoplayer-shared/es2015";import{addScript as Yx,Subject as pn,clearVideoElement as jx}from"@vkontakte/videoplayer-shared/es2015";var Xx="//ad.mail.ru/static/admanhtml/rbadman-html5.min.js",Wu=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 pn,loadStarted$:new pn,loadEnded$:new pn,loadError$:new pn,ready$:new pn,slotRequested$:new pn,started$:new pn,timeRemained$:new pn,paused$:new pn,resumed$:new pn,ended$:new pn,empty$:new pn,skipped$:new pn,clicked$:new pn,closed$:new pn,error$:new pn};this.loadAdman=e=>(ri.push("ui",{key:"videoplayer_embed",strings:["new","adman_load_start",this.useAdmanFromNPM?"npm":"http"],numbers:[si()]}),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?(ri.push("ui",{key:"videoplayer_embed",strings:["new","adman_async_init_done","http"],numbers:[si()]}),t(),this.events.loadEnded$.next()):(ri.push("ui",{key:"videoplayer_embed",strings:["new","adman_init_timed_out","http"],numbers:[si()]}),o())};Yx(Xx,e,this.loadTimeout).then(()=>{ri.push("ui",{key:"videoplayer_embed",strings:["new","adman_script_loaded","http"],numbers:[si()]}),window.AdmanHTML?(ri.push("ui",{key:"videoplayer_embed",strings:["new","adman_already_inited","http"],numbers:[si()]}),t(),this.events.loadEnded$.next()):(ri.push("ui",{key:"videoplayer_embed",strings:["new","adman_wait_async_init","http"],numbers:[si()]}),window.admanAsyncInit=a,r=window.setTimeout(a,this.initTimeout))}).catch(l=>{ri.push("ui",{key:"videoplayer_embed",strings:["new","adman_script_load_error","http",String(l)],numbers:[si()]}),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?(ri.push("ui",{key:"videoplayer_embed",strings:["new","adman_init_done","npm"],numbers:[si()]}),t(),this.events.loadEnded$.next()):(ri.push("ui",{key:"videoplayer_embed",strings:["new","adman_init_timed_out","npm"],numbers:[si()]}),o())},l=()=>{d=!0,o()},d=!1,s=window.setTimeout(()=>{ri.push("ui",{key:"videoplayer_embed",strings:["new","adman_load_timed_out","npm"],numbers:[si()]}),l()},this.loadTimeout);e.addEventListener("abort",l),e.aborted&&(ri.push("ui",{key:"videoplayer_embed",strings:["new","adman_load_aborted","npm"],numbers:[si()]}),l()),window.AdmanHTML=window.AdmanHTML||null,import("@adtech/rbadman/out/rbadman-html5.min.js").then(()=>{ri.push("ui",{key:"videoplayer_embed",strings:["new","adman_chunk_imorted","npm","failed: "+String(d)],numbers:[si()]}),!d&&(window.AdmanHTML?(ri.push("ui",{key:"videoplayer_embed",strings:["new","adman_already_inited","npm"],numbers:[si()]}),t(),this.events.loadEnded$.next()):(ri.push("ui",{key:"videoplayer_embed",strings:["new","adman_wait_async_init","npm"],numbers:[si()]}),window.admanAsyncInit=a,r=window.setTimeout(a,this.initTimeout)))},l).finally(()=>{clearTimeout(r),clearTimeout(s),e.removeEventListener("abort",l)})});this.onAdsReady=()=>{ri.push("ui",{key:"videoplayer_embed",strings:["new","adman_ads_ready"],numbers:[si()]}),this.log({message:"ads ready"}),this.events.ready$.next(),this.startPreroll()};this.onAdStarted=(e,t)=>{var o;ri.push("ui",{key:"videoplayer_embed",strings:["new","adman_ad_started",e,"muted: "+t.muted],numbers:[si(),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?$e(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;ri.push("ui",{key:"videoplayer_embed",strings:["new","adman_ad_pased",(e=this.currentAdSection)!=null?e:""],numbers:[si()]}),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;ri.push("ui",{key:"videoplayer_embed",strings:["new","adman_ad_played",(e=this.currentAdSection)!=null?e:""],numbers:[si()]}),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(ri.push("ui",{key:"videoplayer_embed",strings:["new","adman_ad_midroll_pioint"],numbers:[si()]}),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;ri.push("ui",{key:"videoplayer_embed",strings:["new","adman_ad_skipped",(e=this.currentAdSection)!=null?e:""],numbers:[si()]}),this.log({message:"ad skipped"}),this.stopWatchDog()};this.onAdClosed=()=>{var e;ri.push("ui",{key:"videoplayer_embed",strings:["new","adman_ad_closed",(e=this.currentAdSection)!=null?e:""],numbers:[si()]}),this.log({message:"ad closed"}),this.currentAdSection&&this.events.closed$.next(this.currentAdSection),this.stopWatchDog(),this.switchToVideo()};this.onAdCompleted=()=>{var e;ri.push("ui",{key:"videoplayer_embed",strings:["new","adman_ad_completed",(e=this.currentAdSection)!=null?e:""],numbers:[si()]}),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;ri.push("ui",{key:"videoplayer_embed",strings:["new","adman_ad_clicked",(e=this.currentAdSection)!=null?e:""],numbers:[si()]}),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")=>{ri.push("ui",{key:"videoplayer_embed",strings:["new","adman_ad_error",e],numbers:[si()]}),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"),ri.push("ui",{key:"videoplayer_embed",strings:["new","adman_created"],numbers:[si()]}),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 k,P;if(ri.push("ui",{key:"videoplayer_embed",strings:["new","adman_init","already inited: "+!!this.adman],numbers:[si(),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&&$e(this.playerState.vsid);y&&(this.isVsidOriginal?b=y:b=parseInt(y,36));let{isEmbed:_,immediateOrigin:x}=Gx(),I=(k=_?x:window.location.href)!=null?k:window.location.href,C=tb(Me(Qt(Me(Qt(Me({},s),{dl:encodeURIComponent(I),autoplay:r?1:0,player_width:t,player_height:o}),b?{request_id:b}:{}),{duration:m}),u)),R=tb({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){ri.push("ui",{key:"videoplayer_embed",strings:["new","adman_init_threw",String(E)],numbers:[si()]}),this.onAdError("could not init adman")}})}switchToVideo(e=!1){var o,r,a;if(ri.push("ui",{key:"videoplayer_embed",strings:["new","adman_switch_to_video",(o=this.currentAdSection)!=null?o:"","force: "+e],numbers:[si()]}),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(ri.push("ui",{key:"videoplayer_embed",strings:["new","adman_toggle_play",(e=this.currentAdSection)!=null?e:""],numbers:[si()]}),this.adsState){this.log({message:"toggle play"});let t=$e(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(ri.push("ui",{key:"videoplayer_embed",strings:["new","adman_start_preroll"],numbers:[si()]}),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(ri.push("ui",{key:"videoplayer_embed",strings:["new","adman_start_postroll",(e=this.currentAdSection)!=null?e:""],numbers:[si()]}),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(ri.push("ui",{key:"videoplayer_embed",strings:["new","adman_pplay",(e=this.currentAdSection)!=null?e:""],numbers:[si()]}),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(ri.push("ui",{key:"videoplayer_embed",strings:["new","adman_pause",(e=this.currentAdSection)!=null?e:""],numbers:[si()]}),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(ri.push("ui",{key:"videoplayer_embed",strings:["new","adman_skip",(e=this.currentAdSection)!=null?e:""],numbers:[si()]}),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;ri.push("ui",{key:"videoplayer_embed",strings:["new","adman_destroy"],numbers:[si()]}),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&&jx(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 ib=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 Ku,{startTime:m,endTime:p}=u.parse(s);l.startTime=m,l.endTime=p}else if(s.trim()!==""){let u=new xm,{texts:m}=u.parse(s);l.texts=[...l.texts,...m]}(l.startTime||l.endTime)&&l.texts.length>0&&o.push(l)}return o}},Ku=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}},xm=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 Ku;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}},ob=ym;import{isNonNullable as wm}from"@vkontakte/videoplayer-shared/es2015";var qa,Ri,Sm=0,Cm=!1,nb="",rb=(i,e=0,t=0)=>i<e&&i<t,qu=(i,e=0,t=0)=>i>=e&&i<=t,Zx=(i,e=0,t=0)=>i>e&&i>t,sb=(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})=>qu(i,u,m));let a=i>=Sm,l=i<Sm;if(Sm=i,l&&(Cm=!1),wm(qa)&&qu(i,qa.startTime,qa.endTime)&&nb===e.value)return qa;if(!wm(Ri)&&(r!=null&&r.length)&&!Cm){Ri=r.find(({startTime:u,endTime:m})=>qu(i,u,m)||a&&rb(i,u,m)),qa=void 0,!wm(Ri)&&r[r.length-1].endTime<i&&(Cm=!0);return}else{if(qu(i,Ri==null?void 0:Ri.startTime,Ri==null?void 0:Ri.endTime))return qa=Ri,Ri=void 0,nb=e.value,qa;(a&&Zx(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 Qu={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"},Jx={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"},Jd=i=>{var e,t;return(t=(e=Qu[i])!=null?e:Qu[Jx[i]])!=null?t:void 0};import{clientChecker as lb}from"@vkontakte/videoplayer-core/es2015";import{debounceFn as t2,getWindow as Tm,ValueSubject as Im}from"@vkontakte/videoplayer-shared/es2015";import{getWindow as e2}from"@vkontakte/videoplayer-shared/es2015";var Gu=()=>{var i;return(i=e2().document)==null?void 0:i.pictureInPictureEnabled},Yu=i=>!!i.pictureInPictureWindow,ab=i=>!!i.target&&"height"in i.target&&"width"in i.target;var Bs=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:t2(this.onResize.bind(this),300)};this.info={isActive$:new Im(!1),isEnabled$:new Im(!1),type:0};this.info.isEnabled$=new Im(e)}isSupported(){return Gu()}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}=Tm();!this.isSupported()||!this.isActive()||!this.videoElement||!e.pictureInPictureElement||(yield e.exitPictureInPicture(),lb.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=Me({},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=Yu(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=Yu(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=ab(e)?e.target:Yu(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(lb.browser.isSafari&&e&&e!==t){let r=this.eventHandlers.leavepictureinpicture,a=0,l=()=>{Tm().clearTimeout(a),e.removeEventListener("leavepictureinpicture",d)},d=s=>(r(s),l());e.addEventListener("leavepictureinpicture",d),a=Tm().setTimeout(l,1e3)}}};function db(i){return i instanceof Bs}import{Subscription as i2}from"@vkontakte/videoplayer-shared/es2015";import"@vkontakte/videoplayer-statistics/es2015";var ju=class{constructor(e,t,o,r=new i2){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 Xu=(t=>(t.DESKTOP_CONTROL_PANEL_LEFT="desktop-control-panel-left",t.DESKTOP_CONTROL_PANEL_RIGHT="desktop-control-panel-right",t))(Xu||{});var $s=i=>i!=null?i:0,Hs=(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($s(t==null?void 0:t.top)-$s(o==null?void 0:o.top)),left:Math.round($s(t==null?void 0:t.left)-$s(o==null?void 0:o.left)),bottom:Math.round($s(t==null?void 0:t.bottom)-$s(o==null?void 0:o.top)),right:Math.round($s(t==null?void 0:t.right)-$s(o==null?void 0:o.left))}},Fl=i=>{var t;let e=(t=i==null?void 0:i.getBoundingClientRect)==null?void 0:t.call(i);return{width:$s(e==null?void 0:e.width),height:$s(e==null?void 0:e.height)}};var In="off";var Ul=i=>!!(Math.round(Math.abs(i)/90)%2);var mb=({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:k,hasInteractiveBranches:P,playPrevChapterDisabledTooltip:E,additionalButtons:W,additionalSettingsMenuItems:F,additionalContextMenuItems:U,playPrevVideo:j,playNextVideo:se,onVideoChanged:G,looped:re=!1,statistics:X,saveRate:Te,internalsExposure:ue,playerView:te,playerId:be,metaConfig:Ce,videoElement:me})=>{var Zv,Jv;let qe=Qt(Me({},b),{isAudioDisabled:l,live:Qt(Me({},(Zv=b.live)!=null?Zv:{}),{isLiveCatchUpMode:!!r})}),ve=v,pe=p2.createRootTracer(ve.features.tracer),Z=pe.createComponentTracer("Store"),N=y||new n2(qe,pe,{playerId:be,onDevNullLog:s==null?void 0:s.onDevNullLog,externalVideoElement:me});ue==null||ue.expose({corePlayer:N});let ce=new c2,de=new Wu(ce,{loadTimeout:ve.ads.loadTimeout,initTimeout:ve.ads.initTimeout,runtimeTimeout:ve.ads.runtimeTimeout,useAdmanFromNPM:ve.ads.useAdmanFromNPM,volumeMultiplier:ve.ads.volumeMultiplier,isVsidOriginal:ve.ads.isVsidOriginal}),_e=Ba.getInstance(),ge=u==null?void 0:u.pictureInPictureApi,ze=u==null?void 0:u.annotationsApi,ie=u==null?void 0:u.slotsApi,We=u==null?void 0:u.focusManager,ee=ce.createComponentLog("Store"),ke,Ue,Ie={},Ae=new _u,Ne=new Pm,gt="",It=ae(!1),Lt=X&&X.oneStat?ni(X.oneStat.vsid$):Dr(void 0),lt=ae(sa()),Et=ae(!1),jt=()=>A_(document,cb.device.isIOS),zt=(Jv=ge==null?void 0:ge.info.isActive$)!=null?Jv:new pb(!1),Ot=ae(0),Wt=ae(!1),q=ae(!1),Le=ae([]),Re=u2(N.events.fatalError$,N.events.managedError$).subscribe(c=>Le.update(g=>[...g,c])),we=Dr(!1,c=>{let g=N.events.fatalError$.subscribe(()=>c(!0));return()=>g.unsubscribe()}),Ke=c=>ht(null,null,function*(){var oe;let g=Object.values(s2).includes(c);if(ve.downloadVKLanguages&&(g&&ve.updateBuiltinLanguages||!Hf(c))){let Ee;try{Ee=yield d2(c,Hh,Fh)}catch(tt){(oe=X==null?void 0:X.oneStat)==null||oe.logError({errorType:"VKLangPack",fatal:!1}),_e==null||_e.report(tt,{errorType:"VKLangPack",fatal:!1})}Ee&&(Bf({language:c,pack:Ee,fallback:ve.defaultLanguage}),Se.set(c),yt.update(tt=>tt+1))}Hf(c)&&Se.set(c)}),Se=ae(i),yt=ae(0),ye=ae(e);Ke(i);let Fe=(c,g)=>{let M=$e(Se);return Ff(M,c,g,ve.defaultLanguage)},Qe=ae("thumb");Qe.subscribe(c=>{c==="ads"&&N.info.playbackState$.getValue()&&Nt()});let rt=(()=>{let c=mi([we,Qe],([g,M])=>g?"crashed":M);return Qt(Me({},c),{is:g=>$e(c)===g})})(),Kt=ae(),Nt=()=>{Kt.set({muted:N.info.muted$.getValue()})},ai=(()=>{let c=ae(new Set(_));return Qt(Me({},c),{add:g=>{c.update(M=>new Set([...M].concat(g)))},remove:g=>{c.update(M=>{let oe=[...M];return new Set(Array.isArray(g)?oe.filter(Ee=>!g.includes(Ee)):oe.filter(Ee=>Ee!==g))})},includes:g=>{let M=$e(c);return Array.isArray(g)?g.every(oe=>M.has(oe)):M.has(g)}})})(),$i=ae({width:0,height:0}),gi=null,ro=N.info.isBuffering$,so=Dr(ro.getValue(),c=>{let g=ro.subscribe(M=>{M&&gi===null?gi=window.setTimeout(()=>{c(ro.getValue()),gi=null},ve.loaderDelay):c(M)});return()=>{g.unsubscribe(),gi&&clearTimeout(gi)}});Z.log("create store"),ee({message:"create store"});let pi=c=>{let g=c.container,M=()=>{nt=new MutationObserver(Ee=>{let{removedNodes:tt}=Ee[0];tt.length&&g.append(N.experimental.element$.getValue())}),nt.observe(g,{childList:!0})},oe=N.experimental.element$.getValue();if(oe)g.append(oe),M();else{let Ee=N.experimental.element$.pipe(fb(tt=>!!tt),g2()).subscribe(tt=>{g.append(tt),M()});Ne.add(Ee)}},at=c=>{ee({message:`init video, config: ${JSON.stringify(c)}`}),x?pi(c):(m2.push("ui",{key:"videoplayer_embed",strings:["new","core_init_video"],numbers:[v2()]}),N.initVideo(c)),Z.log("init video",{isInteractive:x}),c.subtitles&&N.setExternalTextTracks(c.subtitles),ke=c,gt=c.subtitlesForcedLanguage||""},ui=new ic,ao=c=>ui.next(c),St=new ic,Ct=new pb(Fs.UNKNOWN),Si=new ic,nt=null,st={actionRewind$:St,actionSeek$:Ct,inPiP$:zt,inFullscreen$:new Zu(c=>lt.subscribe(g=>c.next(g))),actionSetSubtitle$:Si,nextMovie$:ui},Ei=new ic,Vo=new ic,Xo={actionSeek$:Ct,actionSubtitlesSwitched$:Ei,actionQuality$:Vo,playerSize$:new Zu(c=>$i.subscribe(g=>c.next(g))),inPiP$:zt,inFullscreen$:new Zu(c=>lt.subscribe(g=>c.next(g))),isLoaderVisible$:new Zu(c=>so.subscribe(g=>c.next(g)))};if(X){let{oneStat:c,thinOneStat:g,mediascopePixel:M,statSubscription:oe}=X;c&&(x||oe.add(c.attachTo(N)),oe.add(c.attachToUi(st)),oe.add(c.attachToAds(de.events)),c.authorize(a).catch(Ee=>{ee({message:`onestat auth error ${String(Ee)}`})}),M&&M.attachTo(N)),g&&(oe.add(g.attachTo(N,de.events)),oe.add(g.attachToUi(Xo)),oe.add(g.attachToAds(de.events)),g.updateContext({isMobile:$e(It)}),g.authorize(a))}if(_e){let c=new Pm,g=(M,oe)=>c.add(M.subscribe(oe));if(g(N.events.managedError$,M=>{_e.logIError(M)}),g(N.events.fatalError$,M=>{_e.logIError(M,!0)}),X){let{oneStat:M}=X;M&&g(M.experimental.error$,oe=>{_e.logIError(oe)})}_e.sentrySubscription.add(c)}let xt=()=>{if(cb.device.isIOS&&Ue)try{k_(Ue)}catch(c){ee({message:`exitIosSafariFullscreen failed: ${c}`})}};Ne.add(N.experimental.element$.subscribe(c=>{c&&(Ue=c,c.classList.add("player-media"),ge==null||ge.updateVideoElement(),x&&c.setAttribute("pip","false"),(te==="preview"||!ve.features.pip&&!ve.features.dpip)&&(c.setAttribute("disablePictureInPicture","true"),c.setAttribute("x-yandex-pip","false")))})).add(N.events.ended$.subscribe(()=>{var c;xt(),(c=s==null?void 0:s.onEnded)==null||c.call(s)})).add(N.events.looped$.subscribe(()=>{var c;(c=s==null?void 0:s.onLooped)==null||c.call(s)})).add(N.events.started$.subscribe(()=>ht(null,null,function*(){var g,M;db(ge)&&(yield ge==null?void 0:ge.revealPictureInPicture());let c=N.info.muted$.getValue();(g=s==null?void 0:s.onStarted)==null||g.call(s),(M=Ie.onStarted)==null||M.call(Ie,c)}))).add(N.events.willSeek$.subscribe(({from:c,to:g})=>{var M;(M=s==null?void 0:s.onSeek)==null||M.call(s,c,g,Ct.getValue())})).add(N.events.autoplaySoundProhibited$.subscribe(()=>{var c;(c=s==null?void 0:s.onAutoplaySoundProhibited)==null||c.call(s)})).add(N.info.position$.subscribe(c=>{var M;let g=N.info.duration$.getValue();isFinite(g)&&g>0&&((M=s==null?void 0:s.onTimeupdate)==null||M.call(s,g,c),de.setPosition(c,g))})).add(N.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(N.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(N.events.loadedMetadata$.subscribe(()=>{Wt.set(!0)})).add(N.info.is3DVideo$.subscribe(c=>{q.set(c)})).add(N.info.isEnded$.subscribe(c=>{x&&(c?(C!=null&&C.getValue()&&ai.add(Pd),ai.add("PLAY_BUTTON")):ai.remove("PLAY_BUTTON"))})).add(N.info.liveTime$.subscribe(c=>{var g;(g=s==null?void 0:s.onLiveTime)==null||g.call(s,c)})).add(N.info.isStalled$.subscribe(c=>{var g;(g=s==null?void 0:s.onStalledChanged)==null||g.call(s,c)})).add(N.info.isLiveEnded$.subscribe(c=>{var g;return c&&((g=s==null?void 0:s.onLiveEnded)==null?void 0:g.call(s))})).add(N.experimental.element$.pipe(fb(c=>!!c)).subscribe(c=>{var g;return(g=s==null?void 0:s.onVideoElementCreated)==null?void 0:g.call(s,c)})).add(de.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(de.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(de.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(de.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(de.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(de.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(de.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(de.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(de.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(de.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(de.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(de.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(de.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(de.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 Pm,z=()=>{var tt,kt,Ht;let{debugLog:c}=ve,g,M="#9df7b7",oe="#efd169";if(c&&c!==!0){let{colors:Gt}=c;g=c.tag,M=(tt=Gt==null?void 0:Gt[0])!=null?tt:M,oe=(Ht=(kt=Gt==null?void 0:Gt[1])!=null?kt:Gt==null?void 0:Gt[0])!=null?Ht:oe}let Ee=g?`: ${g}`:"";Bt.add(N.events.log$.subscribe(Gt=>{console.debug(`%c sdk${Ee} `,`background:${M};`,`sdk component: ${Gt.component}`,Gt.message)})).add(ce.log$.subscribe(Gt=>{console.debug(`%c ui${Ee} `,`background:${oe};`,`ui component: ${Gt.component}.`,Gt.message)}))},Mt=()=>{Bt.unsubscribe()},ct=(c,g)=>{Z.log("start camera manual rotation",{mx:c,my:g}),N.startCameraManualRotation(c,g)},_i=(c=!1)=>{Z.log("stop camera manual rotation",{immediate:c}),N.stopCameraManualRotation(c)},Zt=(c,g,M)=>{Z.log("move camera focus px",{xpx:c,ypx:g,dt:M}),N.moveCameraFocusPX(c,g,M)},wt=()=>{N.holdCamera()},dt=()=>{N.releaseCamera()},Ui=Dr(N.info.position$.getValue(),c=>{let g,M,oe=()=>{let Ee=N.info.playbackState$.getValue(),tt=N.info.isLive$.getValue(),kt=N.info.duration$.getValue(),Ht=N.info.position$.getValue();if(Ee&&[zl.PLAYING,zl.PAUSED].includes(Ee)){let Gt=tt?Ht-kt:N.getExactTime();Gt!==M&&c(Gt),M=Gt}g=requestAnimationFrame(oe)};return oe(),()=>cancelAnimationFrame(g)}),Pi=ni(N.info.playbackState$),En=ni(N.info.isBuffering$),Pn=mi([Pi,En],([c,g])=>g?"buffering":c),Ci=ni(N.info.currentBuffer$),lo=ni(N.info.isEnded$),fr=ni(N.info.isLive$),Zi=ve.features.playbackRate?ni(N.info.canChangePlaybackSpeed$):Dr(!1),yi=ni(N.info.liveBufferTime$),Ro=ni(N.info.volume$),Zo=ni(N.info.muted$),_o=bu(N.info.predefinedQualityLimitType$.pipe(ub(c=>c===ys.TRAFFIC_SAVING)),N.info.predefinedQualityLimitType$.getValue()===ys.TRAFFIC_SAVING),mn=bu(N.info.predefinedQualityLimitType$.pipe(ub(c=>c===ys.HIGH_QUALITY)),N.info.predefinedQualityLimitType$.getValue()===ys.HIGH_QUALITY),Hr=ni(N.info.autoQualityLimitingAvailable$),Fr=ni(N.info.availableQualities$),xs=ni(N.info.availableQualitiesFps$),mr=ni(N.info.chromecastState$),vr=ni(N.info.chromecastDeviceName$),Ur=ni(N.info.currentFormat$),zr=ni(N.info.throughputEstimation$),Jo=ni(N.info.videoBitrate$),An=ni(N.info.intrinsicVideoSize$),Yn=ni(N.info.duration$),gr=ni(N.info.isAudioAvailable$),ns=()=>{gi&&clearTimeout(gi),gi=null},en=mi([Yn,fr],([c,g])=>g?-c:c),hr=mi([Pi],([c])=>c===zl.PLAYING),kn=ni(N.info.atLiveEdge$),_r=ni(N.info.atLiveDurationEdge$),br=ni(N.info.position$),wo=mi([br,Yn],([c,g])=>isFinite(c)&&isFinite(g)&&!!g),$r=mi([mr],([c])=>c===o2.CONNECTED),Ji=ni(N.info.availableVideoStreams$),jn=ve.features.audioLanguages?ni(N.info.availableAudioStreams$):Dr([]),Xn=ni(N.info.currentVideoStream$),mt=ni(N.info.currentAudioStream$),ii=c=>{c.language&&Rf(c.language),N.setVideoStream(c)},yr=(c,g)=>{N.setAudioStream(c),sn(g)&&(c.language&&Rf(c.language),ve.features.userVideoPrefs&&t&&Nf(ve.userSalt,String(t),{audioTrackId:c.id}))},xr=c=>{let g;if(c.length===1&&(g=c.at(0)),g!=null||(g=c.find(oe=>"isDefault"in oe&&oe.isDefault)),ve.features.userVideoPrefs&&t){let oe=Su(ve.userSalt,String(t));if(oe!=null&&oe.audioTrackId){let Ee=c.find(tt=>tt.id===oe.audioTrackId);g=Ee!=null?Ee:g}}let M=f_();return M&&(g!=null||(g=c.find(({language:oe})=>M===oe))),g!=null||(g=c.at(0)),g},rs=c=>{Z.log("change audio stream",{id:c});let g=N.info.availableAudioStreams$.getValue().find(M=>M.id===c);g&&yr(g,!0)},Ln=!1;Ne.add(N.info.availableAudioStreams$.subscribe(c=>{if(!Ln&&c.length){let g=xr(c);g&&(N.setAudioStream(g),Ln=!0)}})),jn.subscribe(c=>{var g;(g=s==null?void 0:s.onAvailableAudioStreamsChanged)==null||g.call(s,c.map(({label:M="",id:oe="",language:Ee=""})=>({label:M,language:Ee,id:oe})))}),mt.subscribe(c=>{var g;return c&&((g=s==null?void 0:s.onAudioStreamChanged)==null?void 0:g.call(s,c.id))});let wr=!1;Ne.add(N.info.availableVideoStreams$.subscribe(c=>{if(!wr&&c.length){let g=xr(c);g&&(N.setVideoStream(g),wr=!0)}}));let So=ae(void 0),tn=ni(N.info.isAutoQualityEnabled$,c=>c&&So.set(void 0)),Sr=ni(N.info.currentQuality$,()=>So.set(void 0)),on=mi([So,Sr],([c,g])=>c!=null?c:g),nn=mi(Ur,c=>c!==tc.MPEG),Wr=mi([Fr,xs,tn,on,nn],([c,g,M,oe,Ee])=>{let tt=[];Ee&&tt.push({value:"auto",displayValue:Fe("auto_quality_option"),selected:M});let kt=c.filter(Ht=>!a2(Ht));for(let Ht of kt){let Gt=g[Ht];tt.push({value:Ht,displayValue:`${Ht}${Gt?ib(Gt):""}`,selected:M?!1:Ht===oe})}return tt}),vn=ni(N.info.currentPlaybackRate$),gn=mi([vn,kn,_r],([c,g,M])=>{let oe=M||x?1:ve.controls.playbackRateMin,Ee=g?1:ve.controls.playbackRateMax,tt=ve.controls.playbackRateStep,kt=[];for(let Ht=oe;Ht<=Ee;Ht+=tt)kt.push({value:Ht,displayValue:Ht===1?Fe("playback_rate_1"):Fe("playback_rate",{multiplier:Ht.toString(10)}),selected:c===Ht});return kt}),Ai=()=>({displayValue:Fe("subtitles_off"),value:In,language:""}),Mn=ae(Ai()),eo=mi([Mn,yt],([c],g)=>{c.value===In?g(Ai()):g(c)}),Vn=ve.features.subtitles?ni(N.info.availableTextTracks$):Dr([]),Zn=t_(),hn=mi([Vn,eo],([c,g],M)=>{var tt;let oe=[],Ee=c.find(({id:kt})=>kt===g.value);if(Ee!=null&&Ee.url){let[,kt]=(tt=Zn.find(Ee.url))!=null?tt:[];if(kt){M(kt);return}Ae.download(Ee.url).then(Ht=>{if(!Ht||Ae.isDestroyed())return;let Gt=new ob,Ys=Ee.language;if(Ys){let v$=!!Ee.isAuto,g$=Gt.parse(Ht,Ys);oe.push({lang:Ys,subtitles:g$,isAuto:v$,id:Ee.id})}Zn.add(Ee.url,oe),$e(eo).value===g.value&&M(oe)}).catch(Ht=>{var Gt;(Gt=X==null?void 0:X.oneStat)==null||Gt.logError({errorType:"Subtitles download",fatal:!1}),_e==null||_e.report(Ht,{errorType:"Subtitles download",fatal:!1})})}M(oe)}),Cr=mi([vn,hr,eo],([c,g,M],oe)=>{let kt;if(N.info.isLive$.getValue()&&g&&M.value!==In){let Gt=()=>{let Ys=1e3/(3*c);kt=setTimeout(Gt,Ys),oe(Date.now())};return Gt(),()=>clearTimeout(kt)}}),et=mi([Vn,eo],([c,g])=>{if(!c.length)return[];let M=[];for(let{language:oe,isAuto:Ee,id:tt}of c){let kt=oe&&Jd(oe);oe&&kt&&M.push({displayValue:Ee?Fe("subtitles_auto",{language:kt}):kt,value:tt,selected:(g==null?void 0:g.value)===tt,isAuto:Ee,language:oe})}return M.length?(M.unshift(Qt(Me({},Ai()),{selected:(g==null?void 0:g.value)===In})),M):[]}),li={available:[],prev:[]},Oo=()=>{var g,M;let c=N.experimental.getCurrentTime$.getValue();return(M=(g=c==null?void 0:c())!=null?g:Ue==null?void 0:Ue.currentTime)!=null?M:0},_n=mi([Ui,eo,hn,Cr],([c,g,M,oe])=>{var tt;let Ee=N.info.isLive$.getValue();if(Ee&&li.prev!==M){let kt=M.find(({id:Gt})=>Gt===g.value),Ht=li.prev.find(({id:Gt})=>Gt===g.value);if(kt){let Gt=Qt(Me({},kt),{subtitles:[...(tt=Ht==null?void 0:Ht.subtitles)!=null?tt:[],...kt.subtitles]});li.available=[Gt],li.prev=M}}if(g&&g.value!==In){let kt=Ee?Oo():c,Ht=Ee?li.available:M;return sb(kt,g,Ht,Ee)}}),Co=mi([_n],([c])=>c!=null&&c.texts?c.texts:[]);Ne.add(eo.subscribe(c=>{var g,M;if(c.value===In)(g=s==null?void 0:s.onSubtitleOff)==null||g.call(s);else{let oe=Object.entries(Qu).find(([Ee,tt])=>tt===c.displayValue);(M=s==null?void 0:s.onSubtitleOn)==null||M.call(s,oe?oe[0]:"",c.value)}}));let rn=ae(!0),bo=mi([Ci,en,br,yi],([c,g,M,oe])=>{var Ht;let Ee=(Ht=c==null?void 0:c.end)!=null?Ht:0;if(!oe)return Ee/g;let kt=-M+oe-g;return(Ee-kt)/g}),$o=ni(N.info.availableSources$),ki=mi([$o],([c])=>Object.keys((c==null?void 0:c[tc.MPEG])||{}).length>0),Kr=()=>{var M,oe,Ee;let c=Object.keys(((oe=(M=N.info.availableSources$)==null?void 0:M.getValue())==null?void 0:oe[tc.MPEG])||{}),g=r2(c)||f2.Q_144P;return(Ee=ke.sources[tc.MPEG])==null?void 0:Ee[g]},Rn=()=>{var g;let c=Kr();if(c)Z.log("download video",{url:c}),Zh(c,((g=ke==null?void 0:ke.meta)==null?void 0:g.title)||"video");else{let M="There is no URL for download video";Z.log("download video",{message:M}),ee({message:M})}},ws=()=>{ee({message:"toggle muted"});let c=N.info.muted$.getValue();N.info.volume$.getValue()===0&&!c?On(Tr(),!1):xi(!c,!1)},zi=()=>{var c;if(qt.ui.settingsMenu.visible$.set(!1),!$e(qt.ui.settingsSubMenu.visible$)){let g=$e(qt.ui.settingsMenu.ref$);if((c=s==null?void 0:s.uiInfo)!=null&&c.onSettingsMenu&&g){let oe=Fl(g),Ee={top:0,left:0,bottom:0,right:0};s.uiInfo.onSettingsMenu({visible:!1,size:oe,position:Ee,name:"settings"})}}Z.log("close settings menu")},Ss=(c,g=()=>Promise.resolve())=>ht(null,null,function*(){var Ee;qt.ui.settingsMenu.openedByBtnKeyboard$.set(!!c),qt.ui.settingsMenu.visible$.set(!0),yield g();let M=$e(qt.ui.settingsMenu.ref$),oe=$a();if((Ee=s==null?void 0:s.uiInfo)!=null&&Ee.onSettingsMenu&&M&&oe){let kt=Fl(M),Ht=Hs(M,oe);s.uiInfo.onSettingsMenu({visible:!0,size:kt,position:Ht,name:"settings"})}Z.log("open settings menu",{wasOpenedByKeyboard:c})}),ss=(c,g=!1)=>{var tt;qt.ui.settingsSubMenu.visible$.set(!1);let M=$e(qt.ui.settingsMenu.ref$),oe=$a(),Ee=$e(qt.ui.settingsMenu.visible$);if((tt=s==null?void 0:s.uiInfo)!=null&&tt.onSettingsMenu&&M&&oe)if(Ee&&!g){let Ht=Fl(M),Gt=Hs(M,oe);s.uiInfo.onSettingsMenu({visible:!0,size:Ht,position:Gt,name:"settings"})}else{let Ht=Fl(c),Gt={top:0,left:0,bottom:0,right:0},Ys=$e(qt.ui.settingsSubMenu.name$);s.uiInfo.onSettingsMenu({visible:!1,size:Ht,position:Gt,name:Ys})}Z.log("close settings sub menu")},as=(c,g)=>{var oe;qt.ui.settingsSubMenu.visible$.set(!0),qt.ui.settingsSubMenu.ref$.set(g),qt.ui.settingsSubMenu.name$.set(c);let M=$a();if((oe=s==null?void 0:s.uiInfo)!=null&&oe.onSettingsMenu&&g&&M){let tt=Fl(g),kt=Hs(g,M);s.uiInfo.onSettingsMenu({visible:!0,name:c,size:tt,position:kt})}Z.log("open settings sub menu",{name:c})},Tr=()=>{var g;let c=Math.max(ve.volumeMinRestore,(g=$u())!=null?g:0);return c===0?ve.volumeDefault:c},sn=c=>{let g=ve.features.savePreferredStatesOnUserActionOnly;return!g||g&&!c},On=(c,g)=>{let M=c===0?Tr():c,oe=N.info.muted$.getValue();ee({message:`set volume, volume: ${c}, preferredVolume: ${M}`});let Ee=!l||rt.is("ads");oe&&c>0&&Ee&&(oe=!1,sn(g)&&Mf(!1)),N.setVolume(c,oe),de.setVolume(c),sn(g)&&Pf(M)},xi=(c,g)=>{let M=N.info.volume$.getValue();ee({message:`set muted, currentVolume: ${M}, mute: ${c}`});let oe=rt.is("ads");if(N.setMuted(c,oe),de.setVolume(c?0:M),sn(g)&&(!oe||!c)&&Mf(c),!c&&M===0){let Ee=Tr();N.setVolume(Ee),sn(g)&&Pf(Ee),de.setVolume(Ee)}},Ye=ae(!1),At=c=>{var g,M;Z.log("set looped",{isLooped:c}),Ye.set(c),N.setLooped(c),(M=(g=s==null?void 0:s.uiInfo)==null?void 0:g.onLoopedChanged)==null||M.call(g,c)};At(re);let fi=()=>{var c,g;(g=(c=s==null?void 0:s.uiInfo)==null?void 0:c.onReportProblem)==null||g.call(c)},Do=(c,g=!1)=>{var M;ee({message:`set autoplayNextEnabled, value: ${c}`}),Z.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))},To=c=>{ee({message:`set timerNextVideoRunning, value: ${c}`}),Z.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(oe){ee({message:"onPrevVideoClick callback failed to execute"})}G(!0),g&&j()},Wi=(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(oe){ee({message:"onNextVideoClick callback failed to execute"})}G(!1),g&&se()},No=()=>{var c;(c=s==null?void 0:s.onNextVideoAnnouncementShow)==null||c.call(s)},Dn=()=>{var c;(c=s==null?void 0:s.onNextVideoAnnouncementClick)==null||c.call(s)},Ir=()=>{var c;(c=s==null?void 0:s.onNextVideoAnnouncementAuto)==null||c.call(s)},Eo=()=>{var c;(c=s==null?void 0:s.onNextVideoAnnouncementCancel)==null||c.call(s)},co=()=>{N.prepare()},Jn=()=>{pr(qt);let c=$e(qt.ui.controls.disabledControls$),g=$e(qt.playerPhase),M={playerPhase:g,isInteractive:x,isVideoEnded:!1,action:"none"};if(c.has("PLAY_BUTTON"))return;if(ee({message:"toggle play"}),g==="ads"){M.action="play",Z.log("toggle adman play",M),de.togglePlay();return}let oe=()=>{var tt;ee({message:"toggle play, call player.play"}),M.action="play",N.play(),(tt=s==null?void 0:s.onPlay)==null||tt.call(s)},Ee=()=>{var tt;ee({message:"toggle play, call player.pause"}),M.action="pause",N.pause(),(tt=s==null?void 0:s.onPause)==null||tt.call(s)};if(N.info.isEnded$.getValue()){if(ee({message:"toggle play, video ended, seek to 0"}),St.next(),Ct.next(Fs.REWIND),x){R==null||R();return}N.seekTime(0),oe()}else N.info.playbackState$.getValue()!==zl.PLAYING?oe():Ee();Z.log("toggle play",M)},Bo=(c,{changeReason:g="default",appliesTo:M="to-video",byUser:oe=!1}={},Ee)=>{ee({message:`set quality, quality: ${c}`}),Z.log("set quality",{quality:c}),oe&&Vo.next(c),N.setAutoQuality(c==="auto");let{qualityDetailsSubMenuEnabled:tt}=ve.features;yu(),c!=="auto"?(tt?(xu({type:"exact_quality",quality:c,videoId:t},M),N.setPredefinedQualityLimits(ys.UNKNOWN)):Af(t,c),So.set(c),N.setQuality(c)):tt&&g==="default"&&(Qr("auto_quality",M,Ee),$e(_o)&&Nn(!1,void 0,Ee),$e(mn)&&Er(!1,void 0,Ee))},Nn=(c,g="as-default",M)=>{ee({message:`set trafficSavingEnabled, value: ${c}`}),Z.log("set traffic saving enabled",{trafficSavingEnabled:c});let oe=c?ys.TRAFFIC_SAVING:ys.UNKNOWN;ve.features.qualityDetailsSubMenuEnabled?(qr(oe,g,M),kd(!1)):(N.setPredefinedQualityLimits(oe),sn(M)&&kd(c))},Er=(c,g="as-default",M)=>{ee({message:`set highQualityEnabled, value: ${c}`}),Z.log("set high quality enabled",{highQualityEnabled:c}),qr(c?ys.HIGH_QUALITY:ys.UNKNOWN,g,M)},qr=(c,g,M)=>{c!==ys.UNKNOWN&&($e(Hr)&&!$e(tn)&&Bo("auto",{appliesTo:g,changeReason:"limit-changed"},M),Qr(c,g,M)),N.setPredefinedQualityLimits(c)},Qr=(c,g,M)=>{sn(M)&&(xu({type:c,videoId:t},g),g==="as-default"&&xu({type:c,videoId:t},"to-video"))},Xe=(c,g=!0)=>{Z.log("set playback rate",{playbackRate:c}),N.setPlaybackRate(c),ve.features.saveRate&&Te&&!N.info.isLive$.getValue()&&g&&m_(c)},Xt=()=>{let c=$e(Zi),g=$e(gn),M=g.findIndex(({selected:Ee})=>Ee);if(M===g.length-1||!c)return g[M];let oe=g[M+1];return Xe(oe.value),oe},Li=()=>{let c=$e(Zi),g=$e(gn),M=g.findIndex(({selected:Ee})=>Ee);if(M===0||!c)return g[M];let oe=g[M-1];return Xe(oe.value),oe},yo=(c=Qt(Me({},Ai()),{selected:!1}),g)=>{Z.log("set subtitles",Me({},c)),c.value!==In&&Si.next(c.isAuto?c.value+"_auto":c.value),Ei.next({enabled:c.value!==In,lang:c.language,auto:!!c.isAuto}),Mn.set(c),sn(g)&&(Df(c.value===In?void 0:c.language),ve.features.userVideoPrefs&&t&&Nf(ve.userSalt,String(t),{subtitleTrackId:c.value===In?void 0:c.value}))},an=c=>{Z.log("toggle subtitles");let g=$e(eo);(g==null?void 0:g.value)===In?Ho(c):tr(c)},er=(c,g)=>{Z.log("change subtitle",{enabled:c}),c?Ho(!0,g):tr(!0)},Ho=(c,g)=>{Z.log("subtitle on");let M=$e(et),oe=$e(Se),Ee=gt!=null?gt:oe,tt;g&&(tt=M.find(kt=>kt.value===g)),tt!=null||(tt=M.filter(kt=>kt.value!==In).find(kt=>kt.language===Ee)),yo(tt!=null?tt:M[1],c)},tr=c=>{Z.log("subtitle off"),yo(void 0,c)};Ne.add(N.info.availableTextTracks$.subscribe(c=>{var M;function g(){let oe=[];for(let{language:Ee,isAuto:tt,id:kt}of c){let Ht=Ee&&Jd(Ee);Ee&&Ht&&oe.push({id:kt,language:Ee,title:tt?Fe("subtitles_auto",{language:Ht}):Ht})}return oe}(M=s==null?void 0:s.onAvailableSubtitlesChanged)==null||M.call(s,g())}));let ls=ae(!0),qs=c=>{ls.set(c)},Bn=(c,g,M=!0)=>{var oe;if(ee({message:`seek to time, time: ${c}`}),Z.log("seek to time",{time:c,action:g,forcePrecise:M}),Ct.next(g),N.info.isLive$.getValue()){let Ee=N.info.duration$.getValue(),tt=Math.min(0,Ee+c);N.seekTime(tt,M)}else{if(C!=null&&C.getValue())return;N.info.isEnded$.getValue()&&(ee({message:"seek after ended, call callbacks.onPlay"}),(oe=s==null?void 0:s.onPlay)==null||oe.call(s)),N.seekTime(Yv(c),M)}},ga=c=>{ee({message:`seek to episode start time: ${c}`}),Z.log("seek to episode start time",{time:c}),Bn(c,Fs.EPISODE,!0)},Qs=(c,g,M=!1)=>{ee({message:`seek to percent, percent: ${c}`}),Z.log("seek to percent",{percent:c,action:g});let oe=$e(en)*c;Bn(oe,g,M)},ut=c=>{ee({message:`seek external, time: ${c}`}),Z.log("seek external",{time:c}),Ct.next(Fs.UNKNOWN),N.seekTime(N.info.isLive$.getValue()?-c:c)},di=c=>{var oe,Ee;let g=(oe=c.max)!=null?oe:"none",M=(Ee=c.min)!=null?Ee:"none";ee({message:`set auto quality limitation. Max: ${g}. Min: ${M}`}),Z.log("set auto quality limits",{max:g,min:M}),N.setAutoQualityLimits(c)},Po=c=>{ee({message:`seek external to episode start time: ${c}`}),Z.log("seek external to episode start time",{time:c}),Bn(c,Fs.EPISODE,!0)},uo=c=>{ee({message:`set playback rate to: ${c}`}),Z.log("set playback rate external",{playbackRate:c}),N.setPlaybackRate(c)},Mi=ae(!1),Pr=ae(!1),Cs=mi([en],([c])=>!!p&&c>=ve.suitableDurationForUsingRichSeek&&ve.features.useRichSeek&&!x),Ts=((p==null?void 0:p.frameWidth)||0)>=((p==null?void 0:p.frameHeight)||0),po=mi([Ot],([c])=>{let g=Ul(c);return Ts?!g:g});Ne.add(rt.subscribe(c=>{c!=="video"&&Mi.set(!1)})),Mi.subscribe(c=>{var g;(g=s==null?void 0:s.onRichSeekActiveChanged)==null||g.call(s,c)});let Vi=ae(void 0),fe=ae(!1),Tt=c=>{ee({message:`start scrubbing, progress: ${c}`}),Z.log("start scrubbing",{progress:c}),fe.set(!0),Jt(c)},Jt=c=>{Vi.set(c)},ei,Fo,fo=()=>{Vi.set(void 0),fe.set(!1)},Ki=()=>{clearTimeout(Fo),clearTimeout(ei),ei=window.setTimeout(()=>{fo()},500),Ue==null||Ue.removeEventListener("seeked",Ki)},ds=(c,g=!1,M=h2.ActionSeekType.SLIDER)=>{ee({message:`complete scrubbing, progress: ${c}`}),Z.log("complete scrubbing",{progress:c}),Qs(c,M,g),$e(qt.ui.isMobile)&&$e(qt.state.currentFormat$)===tc.HLS?(Ue==null||Ue.addEventListener("seeked",Ki),Fo=window.setTimeout(()=>{Ki()},300)):fo()},ir=mi([Ui,en,Vi],([c,g,M],oe)=>{oe(l2(M)?M*g:c)}),Gr=ae(!1),ha=()=>{Gr.set(!0)},jl=()=>{Gr.set(!1)},Ar=mi([$i],([{width:c}],g)=>{let M=Z_(c);g(M)}),cs=W.filter(c=>Jh(c)),Gs=mi([Ar,It],([c,g])=>g?cs.filter(M=>!M.hideOnMobile):cs.filter(M=>{var oe;return!((oe=M.hideOnDesktopGridTypes)!=null&&oe.includes(c))})),kr=ae(W.filter(c=>e_(c))),nl=mi([kr,Ar],([c,g])=>c.filter(M=>{var oe;return!((oe=M.hideOnDesktopGridTypes)!=null&&oe.includes(g))})),Xl=mi([nl,Gs],([c,g])=>[...ve.features.additionalButtonsDesktopControlPanelRight?c.filter(M=>M.type==="desktop-control-panel-right"):[],...ve.features.additionalButtons?g.map((M,oe)=>{var Ee;return{id:oe,weight:oe,type:"desktop-control-panel-right",testId:M.testId,icon:M.iconUrl,onClick:M.onClick,ariaLabel:(Ee=M.ariaLabel)!=null?Ee:M.tooltip,tooltipText:M.tooltip}}):[]].filter(M=>!v.disabledAdditionalButtonIds.includes(M.id))),Lr=ae(F),rl=mi([Lr],([c])=>ve.features.additionalSettingsMenuItems?c.map(g=>g.type==="SWITCH"?Qt(Me({},g),{onClick:g.onChangeEnabled}):g):[]),sl=(c,g)=>{let M=$e(kr).map(oe=>oe.id!==c?oe:Me(Me({},oe),g));kr.set(M)},Zl=c=>{let g=$e(kr);if(g.some(M=>M.id===c.id)){ee({message:`Additional button with id: "${c.id}" was exist! Can't add more with the same id`});return}g.push(c),kr.set(g)},_a=c=>{let g=$e(kr);if(!g.some(M=>M.id===c)){ee({message:`Can't find additional button with id: "${c}"! Can't remove item with this id`});return}g=g.filter(M=>M.id!==c),kr.set(g)},al=c=>{Ct.next(Fs.LIVE),ee({message:"live switch to low latency "+c}),Z.log("live switch to low latency "+c),N.setLiveLowLatency(c)},pt=(c,g)=>{let M=$e(Lr).map(oe=>oe.id!==c?oe:Me(Me({},oe),g));Lr.set(M)},vt=c=>{let g=$e(Lr);if(g.some(M=>M.id===c.id)){ee({message:`Settings menu item with id: "${c.id}" was exist! Can't add more with the same id`});return}g.push(c),Lr.set(g)},qi=c=>{let g=$e(Lr);if(!g.some(M=>M.id===c)){ee({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),Lr.set(g)},Oi=ae(U),Qi=mi([Oi],([c])=>ve.features.additionalContextMenuItems?c:[]),hi=(c,g)=>{let M=$e(Oi).map(oe=>oe.id!==c?oe:Me(Me({},oe),g));Oi.set(M)},Di=c=>{let g=$e(Oi);if(g.some(M=>M.id===c.id)){ee({message:`Context menu item with id: "${c.id}" was exist! Can't add more with the same id`});return}g.push(c),Oi.set(g)},ba=c=>{let g=$e(Oi);if(!g.some(M=>M.id===c)){ee({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),Oi.set(g)},ll=mi([It,we],([c,g],M)=>{M(c&&g)}),$p=()=>{Ct.next(Fs.LIVE),ee({message:"switch to active live"}),Z.log("switch to active live"),N.seekTime(0),N.info.playbackState$.getValue()!==zl.PLAYING&&qt.actions.internal.togglePlay()},Lc=()=>{Z.log("skip adman"),de.skip()},yp=(c=!0)=>{var oe;pr(qt),ee({message:`switch from ads to video, callPlay: ${c}`}),Z.log("switch from ads to video",{callPlay:c}),Qe.set("video"),c&&N.play(),l&&xi(!0,!0);let g=(oe=$e(Kt))==null?void 0:oe.muted,M=!N.info.muted$.getValue();g!==void 0&&!M&&xi(g,!0),Kt.set(void 0)},Mc=()=>{pr(qt),ee({message:"switch from video to ads"}),Z.log("switch from video to ads"),qt.actions.internal.pause(),xt(),Qe.set("ads")},xp=c=>{pr(qt);let g=c?"LiveWaitingStart":"thumb";Z.log("set live waiting start",{state:c,playerPhase:g}),Qe.set(g)},Vc=c=>{pr(qt);let g=c?"LiveWaitingRecover":"thumb";Z.log("set live waiting recover",{state:c,playerPhase:g}),Qe.set(g)},wp=c=>{pr(qt);let g=c?"LiveWaitingRecord":"thumb";Z.log("set live waiting record",{state:c,playerPhase:g}),Qe.set(g)},Rc=()=>(pr(qt),Z.log("get debug text data"),jh(N,ke,qt,pe.getTraceId(),Ce)),Sp=()=>(pr(qt),JSON.stringify(pe.getFinishedSpans())),Oc=()=>(pr(qt),Xh(N,ke,qt)),$a=()=>Ue,Dc=()=>{ee({message:"toggle chromecast"}),Z.log("toggle chromecast"),N.toggleChromecast()},ya=c=>{var M;if(pr(qt),N.info.isEnded$.getValue())return;let g=!c;if($e(qt.playerPhase)==="ads"){ee({message:`pause ads, internalCall: ${g}`}),Z.log("pause ads",{internalCall:g}),de.pause();return}ee({message:`pause video, internalCall: ${g}`}),Z.log("pause video",{internalCall:g}),g&&((M=s==null?void 0:s.onPause)==null||M.call(s)),N.pause()},xa=c=>{var M;pr(qt);let g=!c;if($e(qt.playerPhase)==="ads"){ee({message:`play ads, internalCall: ${g}`}),Z.log("play ads",{internalCall:g}),de.play();return}ee({message:`play video, internalCall: ${g}`}),Z.log("play video",{internalCall:g}),g&&((M=s==null?void 0:s.onPlay)==null||M.call(s)),N.play()},Cp=c=>{pr(qt);let g=!c;if($e(qt.playerPhase)==="ads"){ee({message:"player cannot be stopped during ads via external method"});return}ee({message:`player will be stopped, internalCall: ${g}`}),k==null||k()},Jl=(c,g)=>{pr(qt),ee({message:`first start, show ads: ${c}, internalCall: ${!g}`}),Z.log("first start",{showAds:c,external:g}),c?Qe.set("ads"):(Qe.set("video"),g?N.play():qt.actions.internal.togglePlay())},ed=()=>(ee({message:"getting time codes"}),m),Nc=()=>{let c=ed();if(!c||[0,1].includes(c.length))return;let g=N.info.position$.getValue();return c.find(M=>M.time>g)},Tp=c=>{let g=c;g||(g=Nc());let M=N.info.position$.getValue();Z.log("seek to next episode",Me({currentTime:M},g)),g&&(ee({message:"seek to next episode"}),Bn(g.time,Fs.EPISODE,!0))},Ge=()=>{let c=ed();if(!c||[0,1].includes(c.length))return;let g=N.info.position$.getValue(),M=c.findIndex(Ee=>Ee.time>g),oe=M===-1?c.length-2:M-2;if(!(oe<0))return c[oe]},vi=c=>{let g=c;g||(g=Ge());let M=N.info.position$.getValue();Z.log("seek to prev episode",Me({currentTime:M},g)),g&&(ee({message:"seek to prev episode"}),Bn(g.time,Fs.EPISODE,!0))},Uo=()=>(ee({message:"getting preview thumbs data"}),Z.log("get preview thumbs data",Me({},p)),p),Mr=()=>ht(null,null,function*(){let c=ge==null?void 0:ge.isActive(),g="none";ge!=null&&ge.isActive()?(g="exit",yield ge==null?void 0:ge.exit()):(g="request",yield ge==null?void 0:ge.request()),Z.log("toggle picture in picture",{isActive:c,action:g})}),bn=(c=-90)=>{Z.log("rotate video",{alphaDiff:c}),Ot.update(g=>g+c)},Bc=ae([]);I==null||I.subscribe(c=>{let g=[];for(let M=0;M<c.length;M++){let{range:[oe,Ee],subjects:tt}=c[M];M===0&&oe!==0&&g.push({time:0,text:"",interactive:!1,completed:!0}),g.push({time:oe/1e3,text:"",interactive:!0,completed:ve.features.interactiveTimeOpenUri?!tt.length||tt.every(kt=>kt.isRemoved):!tt.length}),Ee!==1/0&&g.push({time:Ee/1e3,text:"",interactive:!1,completed:!0})}Bc.set(g)});let a$=ae(!1);C==null||C.subscribe(c=>{c&&$e(fe)&&fo()});let Yv=c=>{if(!x)return c;let g=$e(Bc),M=$e(en),Ee=$e(br)/M,tt=g.find(kt=>kt.interactive&&!kt.completed&&kt.time>Ee);return typeof(tt==null?void 0:tt.time)=="number"?Math.min(c,tt.time-.05):c},l$=()=>{qt.ui.episodes.panelOpened$.set(!1)},d$=()=>{Z.log("destroy store"),clearTimeout(Fo),clearTimeout(ei),Ne.unsubscribe(),Bt.unsubscribe(),N.destroy(),de.destroy(),X==null||X.destroy(),_e==null||_e.destroy(),Re.unsubscribe(),nt==null||nt.disconnect(),nt=null,Ae.destroy()},c$=mi([kn,rt,Zi],([c,g,M])=>v.features.doubleForwardAvailable&&!c&&g==="video"&&M),Ip=ae(!1),jv=2,Hc=null,Xv=c=>{if(!$e(hr)&&c)return;let g=N.info.currentPlaybackRate$.getValue();c?g!==jv&&(Hc=g,Xe(jv,!1),Ip.set(!0)):(Hc&&Xe(Hc,!1),Ip.set(!1),Hc=null)};rt.subscribe(c=>{c!=="video"&&Xv(!1)});let u$=()=>{ya(!1),Mi.set(!0)},p$=()=>{xa(!1),Mi.set(!1)},Ep=!1,f$=()=>{Pr.set(!0),Ep=N.info.playbackState$.getValue()===zl.PLAYING,ya(!1)},m$=()=>{Pr.set(!1),!$e(Mi)&&Ep&&xa(!1),Ep=!1};N.events.playing$.subscribe(()=>{$e(Mi)&&ya(!1)});let qt={interfaceLanguage$:Se,isCyrillicRelatedInterface$:ye,initVideo:at,videoId:t,isClip:o,playerPhase:rt,vsid:Lt,state:{positionExact$:Ui,positionWithScrubbing$:ir,duration$:en,playbackState$:Pi,playbackStateRealistic$:Pn,isPlaying$:hr,isLoaderVisible:so,bufferedProgress$:bo,isLive$:fr,canChangePlaybackSpeed$:Zi,isActiveLive$:kn,isOldestAvailableLive$:_r,isRewindableLive$:wo,isEnded$:lo,muted$:Zo,volume$:Ro,trafficSavingEnabled$:_o,highQualityEnabled$:mn,autoQualityLimitingAvailable$:Hr,availableVideoStreams$:Ji,availableAudioStreams$:jn,videoStream$:Xn,audioStream$:mt,currentQuality$:on,isAutoQualityEnabled$:tn,availableQualities$:Wr,currentPlaybackRate$:vn,availablePlaybackRates$:gn,currentSubtitle$:eo,availableTextTracks$:Vn,availableSubtitlesList$:et,currentSubtitleCaptions$:Co,isAutoSubtitleCaptionVisible$:rn,chromecastState$:mr,chromecastDeviceName$:vr,chromecastConnected$:$r,currentFormat$:Ur,throughputEstimation$:zr,videoBitrate$:Jo,videoSize$:An,errorLog$:Le,crashed$:we,isAudioAvailable$:gr,isAudioDisabled:!!l,canDownload:ve.features.download&&!!d,availableSources$:$o,hasMpegSources$:ki,isInteractive:x,showInteractiveGraph:ve.features.interactiveGraph,showSeekToInteractive:ve.features.seekToInteractive,showPlayPrevChapter:ve.features.interactivePlayPrevChapter,showInteractiveTimeIndicator:ve.features.interactiveTimeIndicator&&!!$e(Bc).length,interactiveEpisodes$:Bc,isInteractiveTime$:C?ni(C):ae(!1),isInteractiveExpectation$:a$,hasInteractiveBranches:P,playPrevChapterDisabledTooltip:E,looped$:Ye,loadedMetadata$:Wt,isAutoQualityAvailable$:nn,previewTrackActive:Mi,previewTrackDragInProgress:Pr},ui:{t:Fe,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$:ai},modals:{hotKeyMap:{show:ae(!1),data:ae({title:"",closeBtnText:"",groups:[]})}},isFullscreen:lt,isFullscreenOpenedByKeyboard:Et,rotateAlpha:Ot,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:$i,isMobile:It,mobileNotReportControlHidden$:ll,icon3DVideoVisible:ae(!1),scrubbingInProgress:fe,volumeChangingInProgress:Gr,is3DVideo:q,currentGridType$:Ar,additionalButtonsDeprecated$:Gs,additionalDesktopControlPanelRightButtons$:Xl,additionalSettingsMenuItems$:rl,additionalContextMenuItems$:Qi,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:ls,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$:Ip,doubleForwardAvailable$:c$,previewTrackActive:Mi,previewTrackDragInProgress:Pr,previewTrackAvailable:Cs,isPreviewTrackHorizontallyAligned:po},ads:{position:ae(0),duration:ae(0),playbackState:ae("inactive"),canSkip:ae(!1),secondsToWatchBeforeSkip:ae(0),postrollPassed:ae(!1)},webApi:{pictureInPictureApi:ge,annotationsApi:ze,slotsApi:ie,focusManager:We},actions:{internal:{preload:co,firstStart:c=>Jl(c,!1),play:()=>xa(!1),pause:()=>ya(!1),togglePlay:Jn,toggleMuted:ws,openSettingsMenu:Ss,closeSettingsMenu:zi,openSettingsSubMenu:as,closeSettingsSubMenu:ss,setVolume:c=>On(c,!1),setMuted:c=>xi(c,!1),startVolumeChanging:ha,stopVolumeChanging:jl,setVideoStream:ii,setAudioStream:c=>yr(c,!1),setQuality:(c,g)=>Bo(c,g,!1),setTrafficSavingEnabled:(c,g)=>Nn(c,g,!1),setHighQualityEnabled:(c,g)=>Er(c,g,!1),setPlaybackRate:Xe,incrementPlaybackRate:Xt,decrementPlaybackRate:Li,setSubtitle:c=>yo(c,!1),toggleSubtitle:()=>an(!1),togglePictureInPicture:Mr,startScrubbing:Tt,progressScrubbing:Jt,completeScrubbing:ds,toggleChromecast:Dc,switchToActiveLive:$p,switchFromAdsToVideo:yp,switchFromVideoToAds:Mc,skipAd:Lc,setLiveWaitingStart:xp,setLiveWaitingRecover:Vc,setLiveWaitingRecord:wp,getDebugTextData:Rc,getTraceTextData:Sp,getDebugPanelData:Oc,getVideoElement:$a,seekTime:(c,g,M)=>Bn(c,g,M),clearDelayedBufferingCheckTimeout:ns,seekEpisodeStartTime:ga,seekToPercent:Qs,getNextEpisode:Nc,seekToNextEpisode:Tp,getPrevEpisode:Ge,seekToPrevEpisode:vi,startLogging:z,stopLogging:Mt,startCameraManualRotation:ct,stopCameraManualRotation:_i,moveCameraFocusPX:Zt,holdCamera:wt,releaseCamera:dt,getVideoEpisodes:ed,getPreviewThumbsData:Uo,downloadVideo:Rn,addLanguage:Bf,setLanguage:Ke,nextMovie:ao,videoRotate:bn,correctSeekTimeToInteractive:Yv,replayInteractive:R,setLooped:At,reportProblem:fi,setAutoplayNextEnabled:Do,setTimerNextVideoRunning:To,prevVideoClick:Io,nextVideoClick:Wi,nextVideoAnnouncementShow:No,nextVideoAnnouncementClick:Dn,nextVideoAnnouncementAuto:Ir,nextVideoAnnouncementCancel:Eo,checkFullscreenSupport:jt,changeDoubleForwardOn:Xv,closePreviewTrack:p$,previewTrackOpened:u$,previewTrackDragStarted:f$,previewTrackDragFinished:m$},external:{firstStart:c=>Jl(c,!0),play:()=>xa(!0),pause:()=>ya(!0),stop:()=>Cp(!0),seekTime:c=>ut(c),seekEpisodeStartTime:c=>Po(c),setPlaybackRate:c=>uo(c),setAutoQualityLimits:c=>di(c),setMuted:c=>xi(c,!0),toggleSubtitle:()=>an(!0),changeSubtitle:er,setVolume:c=>On(c,!0),returnFocusToEpisodes:l$,updateAdditionalSettingsItem:pt,addAdditionalSettingsItem:vt,removeAdditionalSettingsItem:qi,updateAdditionalContextItem:hi,addAdditionalContextItem:Di,removeAdditionalContextItem:ba,updateAdditionalButton:sl,addAdditionalButton:Zl,removeAdditionalButton:_a,setLiveLowLatency:al,hideControls:()=>qs(!1),showControls:()=>qs(!0),setQuality:c=>Bo(c,{appliesTo:"to-video"},!0),setTrafficSavingEnabled:c=>Nn(c,"to-video",!0),setHighQualityEnabled:c=>Er(c,"to-video",!0),changeAudioStream:rs}},callbacks:s,setUiCallbacks:c=>{Ie=Me({},c)},getAdmanWrapper:()=>de,getLogger:()=>ce,getPlayer:()=>N,destroy:d$};return qt};function Qn(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}=Hs(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 _2=["disabledControls$","additionalButtons"],b2=["interactiveTimeIndicator"],Kl=(i,e,t,o)=>{if(i){for(let[r,a]of Object.entries(e))if(!_2.includes(r)){let l=o||b2.includes(r);a.set(Qn(i,t,r,l))}}};var Ju=(i,e,t)=>ht(null,null,function*(){yield ho(),e&&t&&(t.focus(),i.set(!1))});var $2=Pe('<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 Am(i){Ze(i,{children:(e,t)=>{var o=$2();$(e,o)},$$slots:{default:!0}})}function km(i,e){B(e,!0);let[t,o]=Be(),r=()=>w(s,"$contextMenuVisible$",t),a=h(e,"disabled",3,!1),l=h(e,"ariaLabel",3,""),d=xe(),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);He(()=>{n(b)&&Pt(()=>{v.set(n(b))})});let y=C=>{let R=da(C),k=K_(n(b));p.set(k),u.set(R),s.set(!r())},_=()=>{m.set(!0)},x=()=>{m.set(!1)},I=f(()=>r()?"opened":"");Ut(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)=>{Am(C,{})},$$slots:{default:!0}}),H(),o()}var y2=i=>{i.stopPropagation()},x2=L("<div><!> <div></div> <div></div></div>"),w2={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 oc(i,e){var ce;B(e,!0),Q(i,w2);let[t,o]=Be(),r=()=>w(x,"$isMobile",t),a=()=>w(k,"$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=xe(),y=xo(),{interactiveControlsOpacity$:_}=y,x=b.ui.isMobile,I=b.ui.isFullscreen,C=b.state.isInteractiveTime$,R=y.showInteractiveTimeIndicatorTooltip$,k=b.ui.controlsVisible,P=(ce=b.callbacks)==null?void 0:ce.onInteractiveTimeIndicatorClick,E=b.ui.currentGridType$,W=f(()=>!r()&&a()),F=f(()=>Ns(l(),"s")),U=f(()=>!d()||!!s()||n(W)),j=K(!1);He(()=>{O(j,n(U),!0)});let se=()=>{O(j,!0)},G=()=>{var de;re(),(de=n(v))==null||de.addEventListener("animationiteration",se,{once:!0})},re=()=>{var de;O(j,!1),(de=n(v))==null||de.removeEventListener("animationiteration",se)},X=de=>{R.set(de)},Te=f(()=>u()&&!n(U));He(()=>{u()?G():re()});let ue=()=>{n(U)||(R.set(!0),P==null||P())};cn(()=>{R.clearTimeout(),re()});let te=()=>{R.set(!1)},be=Y("tooltip_interactive_interaction_time_indicator");var Ce=x2();let me;Ce.__mousemove=[y2],Ce.__click=ue;var qe=T(Ce);Mo(qe,{get tooltipContent(){return be},get tooltipVisible(){return n(Te)},initialTranslateYPx:72,tooltipPlacement:"bottom",onTooltipVisibilityChange:X,get ref(){return p()},set ref(de){p(de)},children:(de,_e)=>{Qd(de,{completed:!0})},$$slots:{default:!0}});var ve=A(qe,2);let pe;it(ve,de=>p(de),()=>p());var Z=A(ve,2);let N;it(Z,de=>O(v,de),()=>n(v)),S(Ce),D((de,_e,ge)=>{me=ne(Ce,1,"interactive-episode-icon-animated s-26",null,me,de),pe=ne(ve,1,"ref-block s-26",null,pe,_e),N=ne(Z,1,"pulse s-26",null,N,ge)},[()=>({mobile:r(),fullscreen:m(),invisible:n(U),"icon-small":n(F)}),()=>({hidden:n(U)}),()=>({paused:n(j)})]),ft("mouseleave",Ce,te),$(i,Ce),H(),o()}Je(["mousemove","click"]);function ep(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);Mo(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,ts(()=>{var y;return(y=e.buttonComponentProps)!=null?y:{}}))}),$(d,u)},$$slots:{default:!0}}),H()}var Us={prevButton:100,replayButton:200,playButton:300,nextButton:400,playPrevChapterButton:500,seekToInteractiveButton:600,interactiveGraphButton:700,liveButton:800};var C2=Pe('<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 fa(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(()=>`${un(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=C2();$(l,s)},$$slots:{default:!0}}),H()}var T2=L('<div class="icon-background-mobile s-22"><!></div>'),I2={hash:"s-22",code:".icon-background-mobile.s-22{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 Qa(i,e){B(e,!0),Q(i,I2);let t=h(e,"ref",15,void 0),o=h(e,"isMobile",3,!1),r=h(e,"disabled",3,!1),l=xe().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}`);Ut(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=T2(),C=T(I);let R=f(()=>e.type==="prev");fa(C,{get size(){return"32"},get reversed(){return n(R)}}),S(I),$(x,I)},_=x=>{let I=f(()=>e.type==="prev");fa(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 E2=Pe('<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 nc(i,e){B(e,!0);let t=f(()=>un(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=E2();$(o,a)},$$slots:{default:!0}}),H()}import{noop as P2}from"@vkontakte/videoplayer-shared/es2015";var A2=L('<div class="icon-background-mobile s-24"></div>'),k2=L("<!> <div><!></div>",1),L2={hash:"s-24",code:".mobile.s-24{align-items:center;display:flex;justify-content:center;position:relative}.icon-background-mobile.s-24{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 ql(i,e){B(e,!0),Q(i,L2);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,P2),d=Y("tooltip_restart"),s=f(()=>`${o()?"btn-m--play":""} ${a()}`);Ut(i,{get className(){return n(s)},testId:"replay-btn",get ariaLabel(){return d},get disabled(){return r()},get click(){return l()},get ariaKeyShortCut(){return hs.KeyK},get ref(){return t()},set ref(u){t(u)},children:(u,m)=>{var p=k2(),v=le(p);{var b=C=>{var R=A2();$(C,R)};V(v,C=>{o()&&C(b)})}var y=A(v,2);let _;var x=T(y);let I=f(()=>o()?"48":"24");nc(x,{get size(){return n(I)}}),S(y),D(C=>_=ne(y,1,"s-24",null,_,C),[()=>({mobile:o()})]),$(u,p)},$$slots:{default:!0}}),H()}var M2=Pe('<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 zs(i,e){B(e,!0);let t=f(()=>un(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=M2();$(o,a)},$$slots:{default:!0}}),H()}import{noop as V2}from"@vkontakte/videoplayer-shared/es2015";var R2=L('<div class="icon-background-mobile s-1y"><!></div>'),O2={hash:"s-1y",code:".icon-background-mobile.s-1y{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 Ql(i,e){B(e,!0),Q(i,O2);let[t,o]=Be(),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,V2),b=xe().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)?zs:Tn),k=f(()=>`${d()?"btn-m--play":""} ${m()}`),P=f(()=>n(x)?n(_):p());Ut(i,{get className(){return n(k)},testId:"play-btn",get click(){return n(P)},get disabled(){return u()},get ariaLabel(){return n(C)},get ariaKeyShortCut(){return hs.KeyK},get ref(){return l()},set ref(E){l(E)},children:(E,W)=>{var F=Oe();let U=f(()=>n(R));var j=le(F);{var se=re=>{var X=R2(),Te=T(X);Hi(Te,()=>n(U),(ue,te)=>{te(ue,{get size(){return"48"}})}),S(X),$(re,X)},G=re=>{var X=Oe(),Te=le(X);Hi(Te,()=>n(U),(ue,te)=>{te(ue,{get size(){return"24"}})}),$(re,X)};V(j,re=>{d()?re(se):re(G,!1)})}$(E,F)},$$slots:{default:!0}}),H(),o()}var D2=Pe('<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 Lm(i){Ze(i,{testId:"play-prev-chapter-icon",children:(e,t)=>{var o=D2();$(e,o)},$$slots:{default:!0}})}function rc(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":"");Ut(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)=>{Lm(d,{})},$$slots:{default:!0}}),H()}var N2=L('<span class="gutter s-25"><span><!></span></span>'),B2={hash:"s-25",code:".gutter.s-25{--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-25{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-25{background-color:var(--toggle-color-autoplay-on);transform:translateX(calc(var(--gutterWidth) - var(--togglerWidth) + var(--togglerGap)))}"};function sc(i,e){B(e,!0),Q(i,B2);let[t,o]=Be(),r=()=>w(s,"$autoplayNextEnabled$",t),a=h(e,"ref",15,void 0),l=xe(),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");Ut(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=N2(),C=T(I);let R;var k=T(C);{var P=W=>{Tn(W,{get size(){return v},fill:b})},E=W=>{zs(W,{get size(){return v},fill:b})};V(k,W=>{r()?W(P):W(E,!1)})}S(C),S(I),D(W=>R=ne(C,1,"toggler s-25",null,R,W),[()=>({enabled:r()})]),$(_,I)},$$slots:{default:!0}}),H(),o()}var H2=Pe('<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 Mm(i){Ze(i,{testId:"seek-to-interactive-icon",children:(e,t)=>{var o=H2();ti(),$(e,o)},$$slots:{default:!0}})}function ac(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":"");Ut(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)=>{Mm(d,{})},$$slots:{default:!0}}),H()}var F2=Pe('<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>'),U2=Pe('<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 Vm(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=U2(),d=A(le(l));{var s=u=>{var m=F2();$(u,m)};V(d,u=>{t()&&u(s)})}$(r,l)},$$slots:{default:!0}})}function lc(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=xe().ui.t,s=f(()=>a()?d("tooltip_interactive_graph_on"):d("tooltip_interactive_graph_off")),u=f(()=>o()?"hidden":"");Ut(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());Vm(m,{get isOpened(){return n(v)}})},$$slots:{default:!0}}),H()}import{PlaybackState as vb}from"@vkontakte/videoplayer-core/es2015";function dc(i,e){B(e,!0);let[t,o]=Be(),r=()=>w(u,"$playbackState$",t),a=h(e,"isMobile",3,!1),l=h(e,"isLiveActive",3,!1),d=h(e,"ariaLabel",3,""),s=xe(),u=s.state.playbackState$,m=s.actions.internal.switchToActiveLive,p=s.actions.internal.togglePlay,v=f(()=>()=>{if(!l()){m();return}r()===vb.PAUSED&&p()}),b=f(()=>a()?"":"btn--live btn-full-opacity"),y=f(()=>l()?"btn-live":"btn-live-offset"),_=f(()=>l()&&r()===vb.PLAYING);Ut(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)=>{Rd(x,{get isActive(){return l()}})},$$slots:{default:!0}}),H(),o()}import{noop as gb}from"@vkontakte/videoplayer-shared/es2015";var z2=L('<div class="icon icon-error-stub"><div class="inner"></div></div>'),W2=L('<img class="icon" aria-hidden="true"/>');function Ga(i,e){"use strict";let t=K(!1),o=()=>{O(t,!0)};var r=Oe(),a=le(r);{var l=s=>{var u=z2();$(s,u)},d=s=>{var u=W2();D(()=>De(u,"src",e.icon)),ft("error",u,o),Va(u),$(s,u)};V(a,s=>{n(t)?s(l):s(d,!1)})}$(i,r)}function Rm(i,e){B(e,!0);let t=h(e,"disabled",3,!1),o=h(e,"onClick",3,gb),r=h(e,"ref",15),a=f(()=>o()===gb),l=f(()=>n(a)||t()),d=f(()=>n(a)?"btn-full-opacity":"");Mo(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});Ut(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)=>{Ga(p,{get icon(){return e.icon}})},$$slots:{default:!0}})},$$slots:{default:!0}}),H()}var hb=i=>!!i.buttonComponent;var Ws={vkLogo:100,autoplayNext:200,volume:300,subtitles:400,settings:500,context:600,fullscreen:700,chromecast:800};var tp=(i,e,t,o)=>{if(i)for(let[r,a]of Object.entries(e))a.set(Qn(i,t,r,o))};import{interpolate as Om}from"@vkontakte/videoplayer-shared/es2015";var _b=10,bb=40,Dm=.2,q2=.5,Q2=65,G2=114,Y2=4,$b=({onPreviewTrackOpened:i,getTimelineRef:e,isHorizontal:t})=>{let o=f(()=>t?Q2:G2),r=K(!1),a=K(0),l=K(0),d=f(()=>n(o)+_b-bb-Y2),s=f(()=>Om(n(a),[Dm,1],[0,-n(d)])),u=f(()=>Om(n(a),[Dm,1],[0,bb])),m=f(()=>Om(n(a),[Dm,1],[0,n(o)+_b]));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)>=q2?1:0,!0),n(a)===1&&i()},closePreviewTrack:()=>{O(a,0)}}};var j2=i=>i;function ma(i,{delay:e=0,duration:t=400,easing:o=j2}={}){let r=+getComputedStyle(i).opacity;return{delay:e,duration:t,easing:o,css:a=>`opacity: ${a*r}`}}var X2=L('<span class="root s-2a"> </span>'),Z2={hash:"s-2a",code:".root.s-2a{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 Nm(i,e){Q(i,Z2);var t=X2(),o=T(t,!0);S(t),D(()=>he(o,e.time)),$(i,t)}var J2=L('<div class="tooltip-wrapper s-14"><div><!></div></div>'),ew={hash:"s-14",code:'.tooltip-wrapper.s-14{display:block;position:relative}.tooltip.s-14{bottom:100%;opacity:0;position:absolute;transform:translateX(-50%);transition:opacity .2s;visibility:hidden}.pointer.s-14: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-14{opacity:1;visibility:visible}'};function Bm(i,e){Q(i,ew);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=J2(),b=T(v);let y;var _=T(b);oi(_,()=>{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)),D(x=>{je(v,`transform: translate(${n(p)}px, ${a()}px);`),y=ne(b,1,"tooltip s-14",null,y,x),je(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 tw=Pe('<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 Hm(i){Ze(i,{height:"20",width:"20",shadow:!0,children:(e,t)=>{var o=tw();ti(),$(e,o)},$$slots:{default:!0}})}var iw=L('<div class="rich-seek-hint s-13"><span class="icon_wrapper s-13"><!></span> <span class="rich-seek-hint-text s-13"> </span></div>'),ow=L('<div class="preview s-13"><!></div>'),nw=L('<div class="time s-13"> </div>'),rw=L('<div><!> <div class="episode s-13"><!></div> <!></div>'),sw={hash:"s-13",code:".timeline-preview.s-13{border-radius:2px;bottom:18px;pointer-events:none}.timeline-preview.mobile.s-13{bottom:72px}.preview.s-13{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-13{margin-bottom:4px;margin-top:10px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.episode.s-13,.time.s-13{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-13{color:var(--white)}.rich-seek-hint.s-13{position:absolute;text-align:center;top:-12px;transform:translateY(-100%)}.icon_wrapper.s-13{display:inline-block;height:20px;margin-right:6px;vertical-align:top;width:20px}.rich-seek-hint-text.s-13{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 Fm(i,e){B(e,!0),Q(i,sw);let[t,o]=Be(),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=xe(),_=y.ui.rotateAlpha,x=y.ui.playerSize,I=y.ui.previewTrackAvailable,C=K(0),R=K(0),k=K(""),P=K(0),E=K(0),W=K(0),F=K(0),U=f(()=>zu(p(),v(),m())),j=f(()=>Ul(r())),se=f(()=>yb(r())),G=f(Te),re=f(()=>(n(se)?1:-1)*(n(C)/2-n(R)/2)),X=f(()=>n(re)*-1);He(()=>{(_e=>{O(C,_e.width,!0),O(R,_e.height,!0)})(te())}),He(()=>{(_e=>{O(k,_e.imgSrc,!0),O(P,_e.imgWidth,!0),O(E,_e.imgHeight,!0),O(W,_e.imgOffsetX,!0),O(F,_e.imgOffsetY,!0)})(be(p()))});function Te(){var ie;let _e=u()?d.MOBILE:d.DESKTOP,{isVertical:ge}=ue(),ze=30;return(ie=n(U))!=null&&ie.text&&(ze+=16),(ge||n(j))&&(ze+=18,ze+=50),Math.min(Math.max(a().height-ze,0),_e)}function ue(){let _e=e.previewThumbsData.frameWidth,ge=e.previewThumbsData.frameHeight,ze=ge>_e;return{width:_e,height:ge,isHorizontal:!ze,isVertical:ze}}function te(){let{height:_e,isHorizontal:ge,isVertical:ze,width:ie}=ue();return ge&&(_e=_e/ie*n(G),ie=n(G)),ze&&(ie=ie/_e*n(G),_e=n(G)),{width:ie,height:_e}}function be(_e){let ge;e.previewThumbsData.isUV?ge=Math.floor(v()*_e/e.previewThumbsData.frequency):ge=Math.min(e.previewThumbsData.countTotal,Math.max(0,Math.floor(e.previewThumbsData.countTotal*_e)));let ze=Math.floor(ge/e.previewThumbsData.countPerImage),ie=Math.floor(ge%e.previewThumbsData.countPerImage/e.previewThumbsData.countPerRow),We=ge%e.previewThumbsData.countPerRow,ee=Math.floor(e.previewThumbsData.countPerImage/e.previewThumbsData.countPerRow);!e.previewThumbsData.isUV&&ze===Math.floor(e.previewThumbsData.countTotal/e.previewThumbsData.countPerImage)&&(ee=Math.floor(e.previewThumbsData.countTotal%e.previewThumbsData.countPerImage/e.previewThumbsData.countPerRow),e.previewThumbsData.countTotal%e.previewThumbsData.countPerImage%e.previewThumbsData.countPerRow>0&&ee++);let ke=e.previewThumbsData.countPerRow;!e.previewThumbsData.isUV&&ze===Math.floor(e.previewThumbsData.countTotal/e.previewThumbsData.countPerImage)&&e.previewThumbsData.countTotal%e.previewThumbsData.countPerImage>0&&(ke=Math.min(e.previewThumbsData.countPerRow,e.previewThumbsData.countTotal%e.previewThumbsData.countPerImage));let Ue=n(C)*ke,Ie=n(R)*ee,Ae=-We*n(C),Ne=-ie*n(R);return{imgSrc:e.previewThumbsData.links[ze],imgWidth:Ue,imgHeight:Ie,imgOffsetX:Ae,imgOffsetY:Ne}}var Ce=rw();let me;var qe=T(Ce);{var ve=_e=>{var ge=ow(),ze=T(ge);{var ie=We=>{var ee=iw(),ke=T(ee),Ue=T(ke);Hm(Ue,{}),S(ke);var Ie=A(ke,2),Ae=T(Ie,!0);S(Ie),S(ee),D(Ne=>he(Ae,Ne),[()=>Y("preview_track_notification_text")]),$(We,ee)};V(ze,We=>{l()&&We(ie)})}S(ge),D(()=>je(ge,`width: ${n(C)}px; height: ${n(R)}px; background-image: url(${n(k)}); background-size: ${n(P)}px ${n(E)}px; background-position: ${n(W)}px ${n(F)}px;
61
+ transform: rotate(${r()}deg) ${n(j)?`translate(${n(re)}px, ${n(X)}px)`:""};
62
+ `)),$(_e,ge)};V(qe,_e=>{n(k)&&_e(ve)})}var pe=A(qe,2),Z=T(pe);{var N=_e=>{var ge=Oe(),ze=le(ge);{var ie=ee=>{var ke=gs();D(Ue=>he(ke,Ue),[()=>Y("tooltip_episode_unfinished")]),$(ee,ke)},We=ee=>{var ke=gs();D(()=>he(ke,n(U).text||"")),$(ee,ke)};V(ze,ee=>{b()&&n(U).completed===!1?ee(ie):ee(We,!1)})}$(_e,ge)};V(Z,_e=>{n(U)&&_e(N)})}S(pe);var ce=A(pe,2);{var de=_e=>{var ge=nw(),ze=T(ge,!0);S(ge),D(()=>he(ze,s())),$(_e,ge)};V(ce,_e=>{b()||_e(de)})}S(Ce),D(_e=>{me=ne(Ce,1,"timeline-preview s-13",null,me,_e),je(Ce,`width: ${n(j)?n(R):n(C)}px;`)},[()=>({mobile:u()})]),$(i,Ce),H(),o()}var aw=L('<span class="time s-g"> </span>'),lw=L("<!> <!>",1),dw={hash:"s-g",code:".time.s-g{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 Um(i,e){var Re,we,Ke,Se,yt;B(e,!0),Q(i,dw);let[t,o]=Be(),r=()=>w(G,"$interactiveEpisodes$",t),a=()=>w(E,"$duration$",t),l=()=>w(P,"$position$",t),d=()=>w(Te,"$isInteractiveExpectation$",t),s=()=>w(X,"$isInteractiveTime$",t),u=()=>w(Ce,"$previewTrackActive",t),m=()=>w(W,"$isLive$",t),p=()=>w(be,"$disabledControls$",t),v=()=>w(U,"$isMobile",t),b=()=>w(F,"$isActiveLive$",t),y=()=>w(k,"$bufferedProgress$",t),_=h(e,"showTimeline",3,!1),x=h(e,"withEpisodes",3,!0),I=h(e,"ref",15,void 0),C=xe(),R=Rt(),k=C.state.bufferedProgress$,P=C.state.positionWithScrubbing$,E=C.state.duration$,W=C.state.isLive$,F=C.state.isActiveLive$,U=C.ui.isMobile,j=R.features.episodes&&x()?C.actions.internal.getVideoEpisodes():void 0,se=C.actions.internal.getPreviewThumbsData(),G=C.state.interactiveEpisodes$,re=C.state.isInteractive,X=C.state.isInteractiveTime$,Te=C.state.isInteractiveExpectation$,ue=C.actions.internal.correctSeekTimeToInteractive,te=(Re=C.callbacks)==null?void 0:Re.onDisabledTimelineClick,be=C.ui.controls.disabledControls$,Ce=C.ui.previewTrackActive,me=(Ke=(we=C.callbacks)==null?void 0:we.uiInfo)==null?void 0:Ke.onTimelineMouseEnter,qe=(yt=(Se=C.callbacks)==null?void 0:Se.uiInfo)==null?void 0:yt.onTimelineMouseLeave,ve=C.ui.t,pe=R.features.interactiveResponsiveUi,Z=f(()=>re?r():j),N=f(()=>jo(a())),ce=f(()=>jo(l())),de=f(()=>l()/a()),_e=f(()=>d()||s()),ge=K(!1),ze=K(""),ie=K(0),We=K(0),ee=K(0),ke=f(()=>({containerWidth:n(We),translateXPx:n(ie),translateYPx:re&&se?-36:-16,active:n(ge)&&_()&&!n(_e)&&!pe&&!u(),pointer:!R.features.timelinePreview||!se||m()})),Ue=ve("aria_timeline"),Ie=f(()=>ve("aria_timeline_value",{position:n(ce),duration:n(N)}));function Ae(ye){return!ue||!re?ye:ue(ye*a())/a()}function Ne(ye,Fe){var Qe;(Qe=e.onSliderPointerDown)==null||Qe.call(e,Fe),C.actions.internal.startScrubbing(Ae(ye))}function gt(ye){s()||C.actions.internal.progressScrubbing(Ae(ye))}function It(ye){var Fe;C.actions.internal.completeScrubbing(Ae(ye)),O(ge,!1),(Fe=e.onSliderPointerUp)==null||Fe.call(e)}function Lt(ye,Fe,Qe){var rt;(rt=e.onSliderPointerEnter)==null||rt.call(e,ye),jt(ye,Fe,Qe),O(ge,!0)}function lt(ye,Fe,Qe,rt){var Kt;(Kt=e.onSliderMove)==null||Kt.call(e,rt,ye),jt(ye,Fe,Qe),O(ge,!0)}function Et(){var ye;O(ge,!1),(ye=e.onSliderLeave)==null||ye.call(e)}function jt(ye,Fe,Qe){O(ee,Ae(ye),!0),O(ie,Fe,!0),Qe&&O(We,Qe,!0),O(ze,zt(ye),!0)}function zt(ye){let Fe=jo((m()?1-ye:ye)*a());return m()?`-${Fe}`:Fe}let Ot=f(()=>p().has("TIMELINE"));var Wt=lw(),q=le(Wt);Bm(q,ts(()=>n(ke),{get leftOffset(){return e.tooltipLeftOffset},get rightOffset(){return e.tooltipRightOffset},children:(ye,Fe)=>{var Qe=Oe(),rt=le(Qe);{var Kt=ai=>{Fm(ai,{get time(){return n(ze)},get isMobile(){return v()},get videoEpisodes(){return n(Z)},get previewThumbsData(){return se},get progress(){return n(ee)},get duration(){return a()},get isInteractive(){return re}})},Nt=ai=>{var $i=aw(),gi=T($i,!0);S($i),D(()=>he(gi,n(ze))),$(ai,$i)};V(rt,ai=>{R.features.timelinePreview&&se&&!m()?ai(Kt):ai(Nt,!1)})}$(ye,Qe)},$$slots:{default:!0}}));var Le=A(q,2);Ka(Le,{className:"timeline-slider",get isActiveLive(){return b()},get isMobile(){return v()},get ariaLabel(){return Ue},ariaValueMin:0,get ariaValueMax(){return a()},get ariaValueNow(){return l()},get ariaValueText(){return n(Ie)},get loadedProgress(){return y()},get filledProgress(){return n(de)},get handleProgress(){return n(de)},get videoEpisodes(){return n(Z)},onPointerDown:Ne,onHandleMove:gt,onPointerMove:lt,onPointerUp:It,onPointerEnter:Lt,onPointerLeave:Et,get onMouseEnter(){return me},get onMouseLeave(){return qe},get onDisabledClick(){return te},get isInteractive(){return re},get disabled(){return n(Ot)},get handleAlwaysVisible(){return u()},get hideHandel(){return s()},testId:"progress_bar",onContextMenu:It,get ref(){return I()},set ref(ye){I(ye)}}),$(i,Wt),H(),o()}var cw={hash:"s-f",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 cc(i,e){B(e,!0),Q(i,cw);let[t,o]=Be(),r=()=>w(s,"$isMobile",t),a=h(e,"position",3,0),l=h(e,"duration",3,0),d=xe(),s=d.ui.isMobile,u=d.ui.t,m=f(()=>jo(l())),p=f(()=>jo(a())),v=f(()=>a()/l()),b=f(()=>u("aria_timeline_value",{position:n(p),duration:n(m)})),y=f(()=>Math.round(n(v)*100));Ka(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 uw=L("<div><!></div>"),pw=L("<div></div>"),fw={hash:"s-d",code:".timeline.s-d{align-items:center;bottom:0;box-sizing:border-box;display:flex;min-width:86px;pointer-events:all;position:relative;width:100%}.timeline.mobile.s-d{height:16px;margin-top:6px;padding:6px 12px 7px}.withoutPadding.s-d{padding:0}.timeline-stub.s-d{min-width:20px;width:100%}.timeline-stub.mobile.s-d{height:8px}"};function Ya(i,e){B(e,!0),Q(i,fw);let[t,o]=Be(),r=()=>w(x,"$isLive$",t),a=()=>w(R,"$isMobile",t),l=()=>w(k,"$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=xe(),_=Rt(),x=y.state.isLive$,I=y.ads.duration,C=y.ads.position,R=y.ui.isMobile,k=ae(!1),P=f(()=>!p()&&(!r()||r()&&e.canRewindLive&&e.isRewindableLive||u()));var E=Oe(),W=le(E);{var F=j=>{var se=uw();let G;var re=T(se);{var X=ue=>{cc(ue,{get position(){return d()},get duration(){return s()}})},Te=ue=>{Um(ue,{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(re,ue=>{u()?ue(X):ue(Te,!1)})}S(se),Vs(se,()=>Vl(m()&&_.features.usePerformanceFix,k,_.disableInvisibleComponentsTimeout)),D(ue=>G=ne(se,1,"timeline s-d",null,G,ue),[()=>({withoutPadding:!v(),mobile:a(),"out-of-flow":l()})]),$(j,se)},U=j=>{var se=pw();let G;D(re=>G=ne(se,1,"timeline-stub s-d",null,G,re),[()=>({mobile:a()})]),$(j,se)};V(W,j=>{n(P)?j(F):j(U,!1)})}$(i,E),H(),o()}import{getRangeAroundIndex as mw}from"@vkontakte/videoplayer-shared/es2015";import{ThinOneStat as vw}from"@vkontakte/videoplayer-statistics/es2015";var gw=(i,e,t,o,r,a,l)=>{O(e,!0),O(t,i.clientX,!0),O(o,n(r),!0),a(l())},hw=L("<div></div>"),_w=L('<div><div class="track s-2c"></div></div>'),bw={hash:"s-2c",code:'.root.s-2c{display:flex;height:var(--preview-track-frame-height-horizontal);overflow:hidden;position:relative;width:100%}.root.is-vertical-video.s-2c,.root.vertically-rotated.s-2c{height:var(--preview-track-frame-height-vertical)}.root.s-2c: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-2c{bottom:0;display:flex;left:0;padding:0 50%;top:0}.frame.s-2c,.track.s-2c{position:absolute}.frame.s-2c{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-2c .frame:where(.s-2c){transform-origin:0 0}.rotate-1.s-2c{transform:rotate(-90deg) translateX(-100%)}.rotate-2.s-2c{transform:rotate(-180deg)}.rotate-3.s-2c{transform:rotate(-270deg) translateY(-100%)}'};function Wm(i,e){B(e,!0),Q(i,bw);let[t,o]=Be(),r=()=>w(R,"$rotateAlpha",t),a=()=>w(_,"$position$",t),l=()=>w(y,"$duration$",t),d=xe(),{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,k=K(void 0),P=K(!1),E=K(0),W=K(0),F=K(0),U=K(0),j=f(()=>v<=b),se=f(()=>Ul(r())),G=f(()=>n(j)?!n(se):n(se)),re=114,X=65,Te=3,ue=f(()=>n(G)?re:X),te=f(()=>n(j)?re:X),be=f(()=>n(j)?"var(--preview-track-frame-height-horizontal)":"var(--preview-track-frame-height-vertical)"),Ce=f(()=>m*n(ue)),me=K(0);He(()=>{O(U,Math.ceil(-n(F)/n(ue))-1),O(F,-n(Ce)*a()/l())});let qe=()=>{C(ve(),!0,vw.ActionSeekType.RICH)},ve=()=>l()*-n(F)/n(Ce)/l(),pe=!1,Z=Ie=>{if(!n(P))return!1;let Ae=Ie.clientX-n(E);O(F,n(W)+Ae),O(F,Math.max(Math.min(n(F),0),-n(Ce)),!0),Math.abs(Ae)>1&&(pe=!0),I(ve())},N=Ie=>{n(P)&&(O(P,!1),!pe&&Ie&&O(F,-(Ie.offsetX-n(me)/2)),pe=!1,qe())},ce=()=>{n(P)&&N()},de=f(()=>s/u),_e=(Ie,Ae)=>{if(Ie!==p.length-1)return u;let Ne=0,gt=Ae*u;for(let It=1;It<=u;It++)Ie*s+Ne+gt<m&&Ne++;return Ne},ge=f(()=>Math.floor(n(U)/s)),ze=f(()=>mw(3,n(ge),p.length-1)),ie=(Ie,Ae,Ne)=>{let gt=s*n(ue);return Ie*gt+Ae*n(ue)*u+n(me)/2-Te/2+Ne*n(ue)},We=f(()=>[`--row-numbers: ${n(de)}`,`--column-numbers: ${u}`,`--frame-width: ${n(te)}px`,`--frame-height: ${n(be)}`].join(";"));var ee=_w();let ke;var Ue=T(ee);Ue.__pointerdown=[gw,P,E,W,F,x,ve],Ue.__pointermove=Z,Ue.__pointerup=N,bi(Ue,20,()=>n(ze),Ie=>Ie,(Ie,Ae)=>{var Ne=Oe(),gt=le(Ne);bi(gt,16,()=>Array.from({length:n(de)},(It,Lt)=>Lt),It=>It,(It,Lt)=>{var lt=Oe(),Et=le(lt);bi(Et,16,()=>Array.from({length:_e(Ae,Lt)},(jt,zt)=>zt),jt=>jt,(jt,zt)=>{var Ot=hw();D((Wt,q)=>{je(Ot,Wt),ne(Ot,1,q,"s-2c")},[()=>`--row-index: ${Lt}; --column-index: ${zt}; left: ${ie(Ae,Lt,zt)}px; background-image: url(${p[Ae]});`,()=>`frame rotate-${Math.abs(r())/90%4}`]),$(jt,Ot)}),$(It,lt)}),$(Ie,Ne)}),S(Ue),S(ee),it(ee,Ie=>O(k,Ie),()=>n(k)),D(Ie=>{ke=ne(ee,1,"root s-2c",null,ke,Ie),je(ee,n(We)),je(Ue,`transform: translateX(${n(F)}px); width: ${n(Ce)}px;`)},[()=>({"is-vertical-video":!n(j),"vertically-rotated":n(se)})]),ft("mouseleave",Ue,ce),Sn(ee,"clientWidth",Ie=>O(me,Ie)),$(i,ee),H(),o()}Je(["pointerdown","pointermove","pointerup"]);var $w=L('<div class="notification s-2b"><span class="description s-2b"> </span></div>'),yw={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 Km(i,e){B(e,!1),Q(i,yw);let t=340,{ui:{t:o}}=xe();Yo();var r=$w(),a=T(r),l=T(a,!0);S(a),S(r),D(d=>he(l,d),[()=>o("preview_track_close_tooltip")],lr),Rs(3,r,()=>ma,()=>({duration:t})),$(i,r),H()}import{getRangeAroundIndex as xw}from"@vkontakte/videoplayer-shared/es2015";var ww=L('<div class="preview-track-close tooltip s-28"><!></div>'),Sw=L('<div class="preview-track-control s-28"><!> <div class="preview-track-close s-28"><!></div> <!></div>'),Cw=L('<div class="wrapper-preview-track s-28"><!></div>'),Tw=L('<div class="enriched-timeline s-28"><!> <!> <!></div>'),Iw={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 qm(i,e){B(e,!0),Q(i,Iw);let[t,o]=Be(),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=xe(),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()||{},k=f(()=>r().width>100),P=K(!x_()),E=()=>{n(P)&&(y_(),O(P,!1))},W=ue=>{let te=Math.floor(a()*ue/R),be=Math.floor(te/I),Ce=xw(3,be,C.length-1);for(let me of Ce){let qe=new Image;qe.src=C[me]}},F=(ue,te)=>{W(te),!l()&&e.onTimelineMove(ue)};var U=Tw(),j=T(U);{var se=ue=>{var te=Sw(),be=T(te);let Ce=f(()=>jo(d()));Nm(be,{get time(){return n(Ce)}});var me=A(be,2),qe=T(me);Ds(qe,{onClick:()=>m.actions.internal.closePreviewTrack()}),S(me);var ve=A(me,2);{var pe=Z=>{var N=ww(),ce=T(N);Km(ce,{}),S(N),$(Z,N)};V(ve,Z=>{n(P)&&Z(pe)})}S(te),ft("mouseleave",me,E),Rs(3,te,()=>ma,()=>({duration:p})),$(ue,te)};V(j,ue=>{l()&&ue(se)})}var G=A(j,2);let re=f(()=>!n(k));Ya(G,{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:W,get ref(){return u()},set ref(ue){u(ue)}});var X=A(G,2);{var Te=ue=>{var te=Cw(),be=T(te);Wm(be,{}),S(te),D(()=>je(te,`height: ${e.animatedPreviewTrackHeight}px;`)),$(ue,te)};V(X,ue=>{e.previewTrackAvailable&&ue(Te)})}S(U),D(()=>je(U,`transform: translateY(${e.animatedOffsetY}px);`)),$(i,U),H(),o()}var Pw=L('<div><!> <div class="controls s-16" data-testid="player_controls"><div class="controls-left s-16"><!> <!> <!></div> <div class="controls-right s-16"></div></div></div> <!>',1),Aw={hash:"s-16",code:'.wrapper-bottom.s-16{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-16:before{background:var(--controls-gradient);content:"";height:var(--controls-gradient-height);position:absolute;width:100%}.wrapper-bottom.s-16>:where(.s-16){pointer-events:auto}.controls.s-16{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-16,.controls-right.s-16{align-content:center;display:flex}.controls-left.s-16{flex-grow:1;min-width:0;overflow:hidden}.controls-left.s-16 >:not(:first-child),.controls-right.s-16 >*{margin-left:var(--controls-desktop-item-margin-left)}.controls-hidden.s-16{transform:translateY(100%);visibility:visible}.wrapper-bottom.no-smooth.s-16{transition:none}'};function Gm(i,e){var _a,al;B(e,!0),Q(i,Aw);let[t,o]=Be(),r=()=>w(Vo,"$disabledControls$",t),a=()=>w(wt,"$adPlaybackState",t),l=()=>w(Nt,"$playbackState$",t),d=()=>w(Ei,"$currentSubtitle$",t),s=()=>w(gi,"$isEnded$",t),u=()=>w(Pi,"$currentGridType$",t),m=()=>w(ro,"$isLive$",t),p=()=>w(nt,"$chromecastState$",t),v=()=>w(at,"$isPictureInPictureActive",t),b=()=>w(ui,"$pictureInPictureType$",t),y=()=>w(st,"$availableSubtitlesList$",t),_=()=>w(Bt,"$contextMenuOpenedByKeyboard$",t),x=()=>w(xt,"$showContextMenuBtn$",t),I=()=>w(pi,"$isRewindableLive$",t),C=()=>w(so,"$isActiveLive$",t),R=()=>w(mr,"$graphIsOpened$",t),k=()=>w(Xo,"$contextMenuVisible$",t),P=()=>w(dt,"$isFullscreen",t),E=()=>w(Pn,"$autoplayNextEnabled",t),W=()=>w(n(Oo),"$prevButton",t),F=()=>w(n(_n),"$replayButton",t),U=()=>w(n(Co),"$playButton",t),j=()=>w(n(rn),"$nextButton",t),se=()=>w(n(bo),"$playPrevChapterButton",t),G=()=>w(n($o),"$seekToInteractiveButton",t),re=()=>w(n(ki),"$interactiveGraphButton",t),X=()=>w(n(Kr),"$liveButton",t),Te=()=>w(n(Rn),"$time",t),ue=()=>w(n(ws),"$episodes",t),te=()=>w(n(zi),"$vkLogo",t),be=()=>w(n(Ss),"$volume",t),Ce=()=>w(n(ss),"$subtitles",t),me=()=>w(n(as),"$settings",t),qe=()=>w(n(Tr),"$context",t),ve=()=>w(n(sn),"$fullscreen",t),pe=()=>w(n(On),"$chromecast",t),Z=()=>w(En,"$additionalDesktopControlPanelRightButtons$",t),N=()=>w(Ui,"$playerSize",t),ce=()=>w(Ro,"$isInteractiveTime$",t),de=()=>w(ut,"$previewTrackActive",t),_e=()=>w(ao,"$settingsMenuVisible",t),ge=()=>w(Io,"$settingButtonRef$",t),ze=()=>w(z,"$startedByKeyboard$",t),ie=()=>w(ai,"$isAudioAvailable$",t),We=()=>w(Wt,"$fakeIsPlaying$",t),ee=()=>w(xs,"$seekToInteractiveDisabledTooltip$",t),ke=()=>w(uo,"$isPreviewTrackHorizontallyAligned$",t),Ue=()=>w(Po,"$previewTrackAvailable",t),Ie=()=>w(di,"$previewTrackDragInProgress",t),Ae=()=>w(Zt,"$adPosition",t),Ne=()=>w(Kt,"$position$",t),gt=()=>w(_i,"$adDuration",t),It=()=>w(rt,"$duration$",t),Lt=h(e,"playerControlsWrapperRef",15,void 0),lt=h(e,"playerControlsRef",15,void 0),Et=h(e,"isAds",3,!1),jt=h(e,"logoTargetUrl",3,""),zt=h(e,"isOneVideoPlaylist",3,!1),Ot=h(e,"customFullscreenSupported",3,!0),{fakeIsPlaying$:Wt}=xo(),q=xe(),Le=xo(),Re=Rt(),we=q.actions.internal.toggleMuted,Ke=q.actions.internal.togglePlay,Se=q.actions.internal.pause,yt=q.actions.internal.toggleSubtitle,ye=q.actions.internal.checkFullscreenSupport,Fe=(_a=q.callbacks)==null?void 0:_a.onAudioDoesNotExistHint,Qe=(al=q.callbacks)==null?void 0:al.onAudioDisabledHint,rt=q.state.duration$,Kt=q.state.positionWithScrubbing$,Nt=q.state.playbackState$,ai=q.state.isAudioAvailable$,$i=q.state.isAudioDisabled,gi=q.state.isEnded$,ro=q.state.isLive$,so=q.state.isActiveLive$,pi=q.state.isRewindableLive$,{isActive$:at,type$:ui}=Le.pictureInPicture$,ao=q.ui.settingsMenu.visible$,St=q.ui.settingsMenu.openedByBtnKeyboard$,Ct=q.ui.controls,Si=q.actions.internal.getVideoEpisodes(),nt=q.state.chromecastState$,st=q.state.availableSubtitlesList$,Ei=q.state.currentSubtitle$,Vo=Ct.disabledControls$,Xo=q.ui.contextMenu.visible$,xt=q.ui.contextMenu.showContextMenuBtn$,Bt=q.ui.contextMenu.openedByBtnKeyboard$,z=q.ui.startedByKeyboard$,Mt=q.ui.controlBlocks,ct=q.ui.t,_i=q.ads.duration,Zt=q.ads.position,wt=q.ads.playbackState,dt=q.ui.isFullscreen,Ui=q.ui.playerSize,Pi=q.ui.currentGridType$,En=q.ui.additionalDesktopControlPanelRightButtons$,Pn=q.ui.autoplayNextEnabled$,Ci=q.actions.internal.getVideoElement,lo=q.actions.internal.replayInteractive,fr=q.actions.internal.prevVideoClick,Zi=q.actions.internal.nextVideoClick,yi=q.state.isInteractive,Ro=q.state.isInteractiveTime$,Zo=q.state.showInteractiveGraph,_o=q.state.showSeekToInteractive,mn=q.state.showPlayPrevChapter,Hr=q.state.showInteractiveTimeIndicator,Fr=q.state.playPrevChapterDisabledTooltip,xs=Le.seekToInteractiveDisabledTooltip$,mr=Le.graphIsOpened$,vr=Re.features.interactiveResponsiveUi,Ur=f(()=>r().has("EPISODE_BUTTON")),zr=f(()=>r().has("GRAPH_BUTTON")),Jo=f(()=>r().has("SEEK_TO_INTERACTIVE_BUTTON")),An=f(()=>r().has("PLAY_BUTTON")),Yn=f(()=>r().has("REPLAY_BUTTON")),gr=f(()=>r().has("PLAY_PREV_CHAPTER_BUTTON")),ns=()=>q.actions.internal.toggleChromecast(),en=f(()=>Et()?a()==="playing":l()===Qm.PLAYING),hr=f(()=>d().value!=="off"),kn=f(()=>s()&&!Et()||yi),_r=f(()=>vr?n(kn)&&oo(u(),"m"):n(kn)),br=f(()=>!s()||yi||Et()),wo=f(()=>oo(u(),"m")),$r=f(()=>e.showNextPrevButtons&&oo(u(),"m")&&!Et()&&e.nextButtonActive),Ji=f(()=>e.showNextPrevButtons&&oo(u(),"m")&&!Et()&&e.prevButtonActive),jn=f(()=>!Et()&&!!m()),Xn=f(()=>p()!==xb.NOT_AVAILABLE&&!(v()&&b()===1)&&oo(u(),"m")&&!yi),mt=f(()=>e.showAutoplayNext&&!zt()&&oo(u(),"s")),ii=f(()=>y().length>0&&oo(u(),"m")),yr=f(()=>_()||x()),xr=f(()=>oo(u(),"s")&&!Et()),rs=f(()=>!e.logoHidden&&!Et()),Ln=f(()=>Re.features.fullscreen&&ye()&&(e.logoHidden||oo(u(),vr?"xs":"s"))&&!(v()&&b()===1)&&(yi?Ot():!0)),wr=f(()=>(!m()||Et())&&!(Re.features.interactiveHideTime&&yi)),So=f(()=>Zo&&oo(u(),"m")),tn=f(()=>vr?_o&&oo(u(),"s"):_o),Sr=f(()=>vr?mn&&oo(u(),"s"):mn),on=f(()=>!Et()&&!m()&&!!(Si!=null&&Si.length)&&n(wo)&&!n(Ur)),nn=f(()=>!I()||!!C()),Wr=f(()=>R()?ct("tooltip_interactive_graph_on"):ct("tooltip_interactive_graph_off")),vn=f(()=>k()?ct("tooltip_context_menu_close"):ct("tooltip_context_menu_open")),gn=(pt,vt)=>pt?vt&&vt===Qm.PAUSED?ct("tooltip_play"):"":ct("tooltip_live"),Ai=f(()=>gn(n(nn),l())),Mn=f(()=>Re.logoType==="vk_video"?ct("tooltip_vk_video_logo"):ct("tooltip_vk_logo")),eo=f(()=>n(hr)?ct("tooltip_subtitles_on"):ct("tooltip_subtitles_off")),Vn=f(()=>P()?ct("tooltip_fullscreen_on"):ct("tooltip_fullscreen_off")),Zn=f(()=>p()===xb.CONNECTED?ct("tooltip_chromecast_on"):ct("tooltip_chromecast_off")),hn=f(()=>E()?ct("tooltip_autoplay_on"):ct("tooltip_autoplay_off")),Cr=K(0),et=ci({}),li=ci({}),Oo=f(()=>Ct.prevButton),_n=f(()=>Ct.replayButton),Co=f(()=>Ct.playButton),rn=f(()=>Ct.nextButton),bo=f(()=>Ct.playPrevChapterButton),$o=f(()=>Ct.seekToInteractiveButton),ki=f(()=>Ct.interactiveGraphButton),Kr=f(()=>Ct.liveButton),Rn=f(()=>Ct.time),ws=f(()=>Ct.episodes),zi=f(()=>Ct.vkLogo),Ss=f(()=>Ct.volume),ss=f(()=>Ct.subtitles),as=f(()=>Ct.settings),Tr=f(()=>Ct.context),sn=f(()=>Ct.fullscreen),On=f(()=>Ct.chromecast),xi=f(()=>({prevButton:W()?W().right-W().left:0,replayButton:F()?F().right-F().left:0,playButton:U()?U().right-U().left:0,nextButton:j()?j().right-j().left:0,playPrevChapterButton:se()?se().right-se().left:0,seekToInteractiveButton:G()?G().right-G().left:0,interactiveGraphButton:re()?re().right-re().left:0,liveButton:X()?X().right-X().left:0,time:Te()?Te().right-Te().left:0,episodes:ue()?ue().right-ue().left:0,vkLogo:te()?te().right-te().left:0,volume:be()?be().right-be().left:0,subtitles:Ce()?Ce().right-Ce().left:0,settings:me()?me().right-me().left:0,context:qe()?qe().right-qe().left:0,fullscreen:ve()?ve().right-ve().left:0,chromecast:pe()?pe().right-pe().left:0,additionalButtons:Z().length?Z().reduce(pt=>[...pt,40],[]):[]})),Ye=K(0);He(()=>{(!n(Ye)||n(Ye)<n(xi).time)&&Pt(()=>O(Ye,n(xi).time,!0))});let At=K(!1);He(()=>{let pt=0;n(on)&&(oo(u(),"xl")?pt=n(xi).time:pt=60);let vt=n(xi).prevButton+n(xi).playButton+n(xi).nextButton+n(xi).seekToInteractiveButton+n(xi).interactiveGraphButton+n(xi).liveButton+n(Ye)+pt;O(At,n(wr)&&n(Cr)>=vt,!0)});let fi=f(()=>n(At)&&oo(u(),"m")),Do=wb(Kl,260),To=wb(tp,260);He(()=>{N(),ce(),de(),Do(Ci(),Ct,et,e.showControls),To(Ci(),Mt,li,e.showControls)}),He(()=>{li.bottom=Lt()});let Io=ae();He(()=>{_e(),ge()&&Pt(()=>Ol(ge(),_e(),St))});let Wi;He(()=>{ze(),Pt(()=>Ju(z,ze(),Wi))});function No(){ca({isAudioDisabled:$i,isAudioAvailable:ie(),isAds:Et(),audioIsNotExistHintCallback:Fe,audioDisabledHintCallback:Qe})&&we()}let Dn=yi?lo:Ke,Ir=f(()=>We()!==null),Eo=f(()=>n(Ir)?We():n(en)),co=f(()=>n(Eo)?ct("tooltip_pause"):ct("tooltip_play")),Jn=ct("tooltip_episodes"),Bo=f(()=>{var pt,vt,qi,Oi;return n(Ji)?{id:"prevButton",type:"desktop-control-panel-left",weight:Us.prevButton,buttonComponent:Qa,buttonComponentProps:{disabled:!e.prevButtonActive,type:"prev",click:fr.bind(null,!0)},tooltipEnabled:!((vt=(pt=q.callbacks)==null?void 0:pt.uiInfo)!=null&&vt.onPrevButtonMouseEnter)&&!((Oi=(qi=q.callbacks)==null?void 0:qi.uiInfo)!=null&&Oi.onPrevButtonMouseLeave),mouseEnter:()=>{var Qi,hi,Di;(Di=(hi=(Qi=q.callbacks)==null?void 0:Qi.uiInfo)==null?void 0:hi.onPrevButtonMouseEnter)==null||Di.call(hi,Qn(Ci(),et,"prevButton",e.showControls))},mouseLeave:()=>{var Qi,hi,Di;(Di=(hi=(Qi=q.callbacks)==null?void 0:Qi.uiInfo)==null?void 0:hi.onPrevButtonMouseLeave)==null||Di.call(hi,Qn(Ci(),et,"prevButton",e.showControls))},tooltipText:ct("tooltip_previous"),disabled:!e.prevButtonActive}:void 0}),Nn=f(()=>n(_r)?{id:"replayButton",type:"desktop-control-panel-left",weight:Us.replayButton,buttonComponent:ql,buttonComponentProps:{disabled:n(Yn),click:Dn},tooltipText:ct("tooltip_restart"),disabled:n(Yn)}:void 0),Er=f(()=>n(br)?{id:"playButton",type:"desktop-control-panel-left",weight:Us.playButton,buttonComponent:Ql,buttonComponentProps:{disabled:n(An),isPlaying:n(en),click:Ke},tooltipText:n(co),disabled:n(An)}:void 0),qr=f(()=>{var pt,vt,qi,Oi;return n($r)?{id:"nextButton",type:"desktop-control-panel-left",weight:Us.nextButton,buttonComponent:Qa,buttonComponentProps:{disabled:!e.nextButtonActive,type:"next",click:Zi.bind(null,!0)},tooltipEnabled:!((vt=(pt=q.callbacks)==null?void 0:pt.uiInfo)!=null&&vt.onNextButtonMouseEnter)&&!((Oi=(qi=q.callbacks)==null?void 0:qi.uiInfo)!=null&&Oi.onNextButtonMouseLeave),mouseEnter:()=>{var Qi,hi,Di;(Di=(hi=(Qi=q.callbacks)==null?void 0:Qi.uiInfo)==null?void 0:hi.onNextButtonMouseEnter)==null||Di.call(hi,Qn(Ci(),et,"nextButton",e.showControls))},mouseLeave:()=>{var Qi,hi,Di;(Di=(hi=(Qi=q.callbacks)==null?void 0:Qi.uiInfo)==null?void 0:hi.onNextButtonMouseLeave)==null||Di.call(hi,Qn(Ci(),et,"nextButton",e.showControls))},tooltipText:ct("tooltip_next"),disabled:!e.nextButtonActive}:void 0}),Qr=f(()=>yi&&n(Sr)?{id:"playPrevChapterButton",type:"desktop-control-panel-left",weight:Us.playPrevChapterButton,buttonComponent:rc,buttonComponentProps:{disabled:n(gr),click:e.playPrevChapter},tooltipText:ct("tooltip_interactive_go_back"),disabledTooltipContent:ct(Fr),disabled:n(gr)}:void 0),Xe=f(()=>yi&&n(tn)?{id:"seekToInteractiveButton",type:"desktop-control-panel-left",weight:Us.seekToInteractiveButton,buttonComponent:ac,buttonComponentProps:{disabled:n(Jo),click:e.seekToInteractive},tooltipText:ct("tooltip_interactive_seek"),disabled:n(Jo),disabledTooltipContent:ct(ee())}:void 0),Xt=f(()=>yi&&n(So)?{id:"interactiveGraphButton",type:"desktop-control-panel-left",weight:Us.interactiveGraphButton,buttonComponent:lc,buttonComponentProps:{disabled:n(zr),click:mr.toggle,graphIsOpened:R()},tooltipText:n(Wr)}:void 0),Li=f(()=>n(jn)?{id:"liveButton",type:"desktop-control-panel-left",weight:Us.liveButton,buttonComponent:dc,buttonComponentProps:{isLiveActive:n(nn),ariaLabel:n(Ai)},tooltipText:n(Ai),disabled:n(nn)&&l()===Qm.PLAYING}:void 0),yo=f(()=>[n(Bo),n(Nn),n(Er),n(qr),n(Qr),n(Xe),n(Xt),n(Li)].filter(pt=>!!pt).sort(Fa)),an=f(()=>n(rs)?{id:"vkLogo",type:"desktop-control-panel-right",weight:Ws.vkLogo,buttonComponent:Yd,buttonComponentProps:{targetUrl:jt(),logoClickable:e.logoClickable,click:Se},tooltipText:n(Mn),disabledTooltipContent:"",disabled:!e.logoClickable}:void 0),er=f(()=>n(mt)?{id:"autoplayNext",type:"desktop-control-panel-right",weight:Ws.autoplayNext,buttonComponent:sc,tooltipText:n(hn)}:void 0),Ho=f(()=>({id:"volume",type:"desktop-control-panel-right",weight:Ws.volume,buttonComponent:vm,buttonComponentProps:{click:No,isAds:Et()}})),tr=f(()=>n(ii)?{id:"subtitles",type:"desktop-control-panel-right",weight:Ws.subtitles,buttonComponent:cm,buttonComponentProps:{isSubtitlesEnabled:n(hr),click:yt},tooltipText:n(eo)}:void 0),ls=f(()=>n(xr)?{id:"settings",type:"desktop-control-panel-right",weight:Ws.settings,buttonComponent:Hl,buttonComponentProps:{ref$:Io},tooltipText:_e()?void 0:ct("tooltip_settings_off")}:void 0),qs=f(()=>Re.features.contextMenuButton?{id:"context",type:"desktop-control-panel-right",weight:Ws.context,buttonComponent:km,buttonComponentProps:{ariaLabel:ct("aria_label_context_menu")},className:n(yr)?"":"out-of-view",tooltipText:n(vn)}:void 0),Bn=f(()=>n(Ln)?{id:"fullscreen",type:"desktop-control-panel-right",weight:Ws.fullscreen,buttonComponent:Gd,buttonComponentProps:{isFullscreen:P(),click:e.toggleFullscreen},tooltipText:n(Vn)}:void 0),ga=f(()=>n(Xn)?{id:"chromecast",type:"desktop-control-panel-right",weight:Ws.chromecast,buttonComponent:Xd,buttonComponentProps:{state:p(),click:ns},tooltipText:n(Zn)}:void 0),Qs=f(()=>[n(an),n(er),n(Ho),n(tr),n(ls),n(qs),n(Bn),n(ga),...Z()].filter(pt=>!!pt).sort(Fa)),ut=q.ui.previewTrackActive,di=q.ui.previewTrackDragInProgress,Po=q.ui.previewTrackAvailable,uo=q.ui.isPreviewTrackHorizontallyAligned,Mi=f(()=>$b({onPreviewTrackOpened:q.actions.internal.previewTrackOpened,getTimelineRef:()=>et.timeline,isHorizontal:ke()})),Pr=f(()=>n(Mi).progressBarY),Cs=f(()=>n(Mi).controlsY),Ts=f(()=>n(Mi).onPointerDown),po=f(()=>n(Mi).onPointerMove),Vi=f(()=>n(Mi).onPointerUp),fe=f(()=>n(Mi).calculatedHeight),Tt=f(()=>n(Mi).closePreviewTrack);He(()=>{de()||n(Tt)()});let Jt;Vt(()=>()=>Jt&&clearTimeout(Jt));let ei=pt=>{de()||!Ue()||(n(Ts)(pt),Jt=setTimeout(()=>{q.actions.internal.previewTrackDragStarted()},200))},Fo=()=>{de()||n(Vi)(),Jt&&clearTimeout(Jt),Ie()&&q.actions.internal.previewTrackDragFinished()},fo=pt=>{n(po)(pt)},Ki=-(parseInt("24")/2+4);var ds=Pw(),ir=le(ds);let Gr;var ha=T(ir);{var jl=pt=>{let vt=f(()=>n(Pr)()),qi=f(()=>n(fe)());qm(pt,{get animatedOffsetY(){return n(vt)},get animatedPreviewTrackHeight(){return n(qi)},get canRewindLive(){return e.canRewindLive},get isAds(){return Et()},onTimelineMove:fo,onTimelinePointerDown:ei,onTimelinePointerUp:Fo,get previewTrackAvailable(){return Ue()},get timelineRef(){return et.timeline},set timelineRef(Oi){et.timeline=Oi}})};V(ha,pt=>{e.showControls&&pt(jl)})}var Ar=A(ha,2),cs=T(Ar),Gs=T(cs);bi(Gs,17,()=>n(yo),pt=>pt.id,(pt,vt)=>{ep(pt,{get buttonComponent(){return n(vt).buttonComponent},get buttonComponentProps(){return n(vt).buttonComponentProps},get tooltipText(){return n(vt).tooltipText},get disabledTooltipContent(){return n(vt).disabledTooltipContent},get disabled(){return n(vt).disabled},get className(){return n(vt).className},get tooltipEnabled(){return n(vt).tooltipEnabled},get mouseEnter(){return n(vt).mouseEnter},get mouseLeave(){return n(vt).mouseLeave},get tooltipVisible(){return e.showControls},get ref(){return et[n(vt).id]},set ref(qi){et[n(vt).id]=qi}})});var kr=A(Gs,2);{var nl=pt=>{let vt=f(()=>!e.showControls),qi=f(()=>Et()?Ae():Ne()),Oi=f(()=>Et()?gt():It());qd(pt,{get isHidden(){return n(vt)},isMobile:!1,get showDuration(){return n(fi)},get position(){return n(qi)},get duration(){return n(Oi)},get ref(){return et.time},set ref(Qi){et.time=Qi}})};V(kr,pt=>{n(wr)&&pt(nl)})}var Xl=A(kr,2);let Lr=f(()=>!n(on));Mo(Xl,{className:"w-max",get disabled(){return n(Lr)},get tooltipContent(){return Jn},get tooltipVisible(){return e.showControls},tooltipPlacement:"top-left",get initialTranslateXPx(){return Ki},get ref(){return et.episodes},set ref(pt){et.episodes=pt},children:(pt,vt)=>{var qi=Oe(),Oi=le(qi);{var Qi=hi=>{Zd(hi,{get position(){return Ne()},get duration(){return It()},get timeCodes(){return Si}})};V(Oi,hi=>{n(on)&&hi(Qi)})}$(pt,qi)},$$slots:{default:!0}}),S(cs);var rl=A(cs,2);bi(rl,21,()=>n(Qs),pt=>pt.id,(pt,vt)=>{var qi=Oe(),Oi=le(qi);{var Qi=Di=>{ep(Di,{get buttonComponent(){return n(vt).buttonComponent},get buttonComponentProps(){return n(vt).buttonComponentProps},get tooltipText(){return n(vt).tooltipText},get disabledTooltipContent(){return n(vt).disabledTooltipContent},get disabled(){return n(vt).disabled},get className(){return n(vt).className},get tooltipVisible(){return e.showControls},get ref(){return et[n(vt).id]},set ref(ba){et[n(vt).id]=ba}})},hi=Di=>{let ba=f(()=>!!n(vt).disabled);Rm(Di,{get id(){return n(vt).id},get testId(){return n(vt).testId},get icon(){return n(vt).icon},get ariaLabel(){return n(vt).ariaLabel},get tooltipText(){return n(vt).tooltipText},get disabledTooltipContent(){return n(vt).disabledTooltipContent},get disabled(){return n(ba)},get onClick(){return n(vt).onClick},get disableMouseupTooltipShow(){return n(vt).disableMouseupTooltipShow},get tooltipVisible(){return e.showControls},get ref(){return et[n(vt).id]},set ref(ll){et[n(vt).id]=ll}})};V(Oi,Di=>{hb(n(vt))?Di(Qi):Di(hi,!1)})}$(pt,qi)}),S(rl),S(Ar),it(Ar,pt=>lt(pt),()=>lt()),S(ir),it(ir,pt=>Lt(pt),()=>Lt());var sl=A(ir,2);{var Zl=pt=>{oc(pt,{get ref(){return et.interactiveTimeIndicator},set ref(vt){et.interactiveTimeIndicator=vt}})};V(sl,pt=>{Hr&&pt(Zl)})}D((pt,vt)=>{Gr=ne(ir,1,"wrapper-bottom s-16",null,Gr,pt),je(ir,`transform: ${e.showControls?"translateY(0)":"translateY(100%)"}`),je(Ar,vt),Ar.inert=de()},[()=>({hidden:e.bottomHidden,"controls-hidden":!e.showControls,"no-smooth":e.bottomNoSmooth||Ie()}),()=>`transform: translateY(${n(Cs)()}px);`]),Sn(cs,"clientWidth",pt=>O(Cr,pt)),$(i,ds),H(),o()}import{ChromecastState as Cb,PlaybackState as Tb}from"@vkontakte/videoplayer-core/es2015";import{noop as Sb}from"@vkontakte/videoplayer-shared/es2015";var kw=L('<div class="icon icon-error-stub s-20"><div class="inner s-20"></div></div>'),Lw=L('<img class="icon s-20" aria-hidden="true"/>'),Mw={hash:"s-20",code:".icon.s-20{height:24px!important;width:24px!important}.inner.s-20{background-color:var(--white);height:16px;width:16px}"};function Ym(i,e){Q(i,Mw);let t=h(e,"disabled",3,!1),o=h(e,"onClick",3,Sb),r=f(()=>o()===Sb),a=f(()=>n(r)||t()),l=K(!1),d=()=>{O(l,!0)},s=f(()=>n(r)?"btn-full-opacity":"");Ut(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=kw();$(_,x)},y=_=>{var x=Lw();D(()=>De(x,"src",e.iconUrl)),ft("error",x,d),Va(x),$(_,x)};V(v,_=>{n(l)?_(b):_(y,!1)})}$(u,p)},$$slots:{default:!0}})}var Vw=Pe('<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 jm(i){Ze(i,{testId:"muted-icon",children:(e,t)=>{var o=Vw();$(e,o)},$$slots:{default:!0}})}import{noop as Rw}from"@vkontakte/videoplayer-shared/es2015";function ip(i,e){B(e,!0);let t=h(e,"muted",3,!1),o=h(e,"click",3,Rw),r=h(e,"ref",15,void 0),l=xe().ui.t,d=f(()=>t()?l("tooltip_volume"):l("tooltip_volume_muted")),s=f(()=>t()?"btn-mobile-muted":"btn-mobile-unmuted");Ut(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=_=>{jm(_,{})},y=_=>{pa(_,{get size(){return"24"}})};V(v,_=>{t()?_(b):_(y,!1)})}$(u,p)},$$slots:{default:!0}}),H()}var Ow=Pe('<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>'),Dw=Pe('<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>'),Nw=Pe('<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 Xm(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=Nw(),d=A(le(l));{var s=m=>{var p=Ow();$(m,p)},u=m=>{var p=Dw();$(m,p)};V(d,m=>{t()?m(s):m(u,!1)})}$(r,l)},$$slots:{default:!0}})}import{noop as Bw}from"@vkontakte/videoplayer-shared/es2015";function Zm(i,e){B(e,!0);let t=h(e,"ref",15,void 0),o=h(e,"isPictureInPictureActive",3,!1),r=h(e,"click",3,Bw),a=Y("menu_pip");Ut(i,{testId:"btn-pip",get ariaLabel(){return a},get click(){return r()},get ref(){return t()},set ref(l){t(l)},children:(l,d)=>{Xm(l,{get isActive(){return o()}})},$$slots:{default:!0}}),H()}import{debounceFn as Ib}from"@vkontakte/videoplayer-shared/es2015";var Hw=(i,e,t,o)=>{n(e)&&t.onDisabledPlayPrevChapterClick(n(o))},Fw=(i,e,t,o)=>{n(e)&&t.onDisabledSeekToInteractiveClick(n(o))},Uw=L("<div><!></div>"),zw=L("<div><!></div>"),Ww=L("<div><!></div>"),Kw=L("<!> <!> <!>",1),qw=L("<div></div> <div></div> <div><!> <!> <!> <!> <!> <!></div> <div><!> <!> <!> <!></div> <!>",1),Qw=L('<div class="wrapper-middle s-15"><!></div>'),Gw=L("<div><!></div> <!> <div><!></div>",1),Yw=L('<div aria-hidden="true">·</div> <!>',1),jw=L('<!> <!> <div><div><div class="controls mobile s-15" data-testid="bottom-controls"><div class="controls-group contain s-15"><!> <!> <!> <!></div> <div class="controls-group s-15"><!> <!> <!></div></div> <!></div></div> <!>',1),Xw={hash:"s-15",code:".wrapper-bottom.s-15{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-15>:where(.s-15){pointer-events:auto}.wrapper-bottom.ads-timeline-mobile.s-15{height:9px;padding:0 4px 4px}.wrapper-middle.s-15{align-items:center;left:50%;top:50%;transform:translate(-50%,-50%)}.wrapper-middle.s-15,.wrapper-top-right.s-15{display:flex;position:absolute;transition:opacity var(--controls-transition-duration);z-index:var(--controls-container-z-index)}.wrapper-top-right.s-15{right:8px;top:4px}.wrapper-top-left.s-15{left:8px;position:absolute;top:4px;z-index:var(--controls-container-z-index)}.wrapper-middle-left.s-15,.wrapper-middle-left-second.s-15,.wrapper-middle-right.s-15{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-15{left:12px}.wrapper-middle-left-second.s-15{left:64px}.wrapper-middle-right.s-15{right:12px}.controls.s-15{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-15,.controls-group.s-15{display:flex}.controls-group.contain.s-15{min-width:0}.controls-group.s-15 >:not(:first-child){margin-left:8px}.hidden.s-15{opacity:0;visibility:hidden}.controls-hidden.s-15{transform:translateY(100%);visibility:visible}.wrapper-bottom.no-smooth.s-15{transition:none}.overlay-mobile.s-15{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-15,.wrapper-top-right.fullscreen.s-15{top:16px}.controls-wrapper.fullscreen.s-15{bottom:30px;position:absolute;width:calc(100% - 8px)}}@media screen and (orientation:landscape){.wrapper-top-left.fullscreen.s-15{left:44px;top:12px}.wrapper-top-right.fullscreen.s-15{right:44px;top:12px}.wrapper-middle-left.fullscreen.s-15{left:44px}.wrapper-middle-left-second.fullscreen.s-15{left:96px}.wrapper-middle-right.fullscreen.s-15{right:44px}.controls-wrapper.fullscreen.s-15{bottom:32px;left:36px;position:absolute;right:36px;width:calc(100% - 72px)}}"};function Jm(i,e){var On,xi;B(e,!0),Q(i,Xw);let[t,o]=Be(),r=()=>w(Pi,"$seekToInteractiveDisabledTooltip$",t),a=()=>w(Ct,"$disabledControls$",t),l=()=>w(zt,"$playbackState$",t),d=()=>w(Vo,"$adPlaybackState",t),s=()=>w(q,"$isEnded$",t),u=()=>w(xt,"$playerSize",t),m=()=>w(yt,"$scrubbingInProgress",t),p=()=>w(ao,"$chromecastState$",t),v=()=>w(Fe,"$isPictureInPictureActive",t),b=()=>w(Qe,"$pictureInPictureType$",t),y=()=>w(ye,"$mobileNotReportControlHidden$",t),_=()=>w(pi,"$chromecastHidden",t),x=()=>w(lt,"$playerPhase",t),I=()=>w(ro,"$pipHidden",t),C=()=>w(nt,"$currentGridType$",t),R=()=>w($i,"$vkLogoHidden",t),k=()=>w(ai,"$volumeHidden",t),P=()=>w(Le,"$isLive$",t),E=()=>w(rt,"$settingsMenuVisible",t),W=()=>w(Se,"$isRewindableLive$",t),F=()=>w(Ke,"$isActiveLive$",t),U=()=>w(Ot,"$isAudioAvailable$",t),j=()=>w(we,"$muted$",t),se=()=>w(Re,"$volume$",t),G=()=>w(_i,"$isInteractiveTime$",t),re=()=>w(Sr,"$settingButtonRef$",t),X=()=>w(Si,"$startedByKeyboard$",t),Te=()=>w(Xo,"$isFullscreen",t),ue=()=>w(Bt,"$additionalButtons$",t),te=()=>w(gi,"$autoplayNextToggleHidden",t),be=()=>w(St,"$crashed$",t),Ce=()=>w(so,"$settingsHidden",t),me=()=>w(En,"$graphIsOpened$",t),qe=()=>w(Ei,"$adPosition",t),ve=()=>w(st,"$adDuration",t),pe=()=>w(jt,"$position$",t),Z=()=>w(Et,"$duration$",t),N=h(e,"playerControlsWrapperRef",15,void 0),ce=h(e,"playerControlsRef",15,void 0),de=h(e,"isAds",3,!1),_e=h(e,"logoTargetUrl",3,""),ge=h(e,"isOneVideoPlaylist",3,!1),ze=h(e,"customFullscreenSupported",3,!0),ie=xe(),We=xo(),ee=Rt(),ke=ie.actions.internal.toggleMuted,Ue=ie.actions.internal.togglePlay,Ie=ie.actions.internal.pause,Ae=ie.actions.internal.prevVideoClick,Ne=ie.actions.internal.nextVideoClick,gt=ie.actions.internal.checkFullscreenSupport,It=(On=ie.callbacks)==null?void 0:On.onAudioDoesNotExistHint,Lt=(xi=ie.callbacks)==null?void 0:xi.onAudioDisabledHint,lt=ie.playerPhase,Et=ie.state.duration$,jt=ie.state.positionWithScrubbing$,zt=ie.state.playbackState$,Ot=ie.state.isAudioAvailable$,Wt=ie.state.isAudioDisabled,q=ie.state.isEnded$,Le=ie.state.isLive$,Re=ie.state.volume$,we=ie.state.muted$,Ke=ie.state.isActiveLive$,Se=ie.state.isRewindableLive$,yt=ie.ui.scrubbingInProgress,ye=ie.ui.mobileNotReportControlHidden$,{isActive$:Fe,type$:Qe}=We.pictureInPicture$,rt=ie.ui.settingsMenu.visible$,Kt=ie.ui.settingsMenu.openedByBtnKeyboard$,Nt=ie.ui.controls,{volume:ai,vkLogo:$i,autoplayNextToggle:gi,pip:ro,settings:so,chromecast:pi}=ie.ui.hiddenControls,at=ie.actions.internal.getVideoEpisodes(),ui=ie.webApi.pictureInPictureApi,ao=ie.state.chromecastState$,St=ie.state.crashed$,Ct=Nt.disabledControls$,Si=ie.ui.startedByKeyboard$,nt=ie.ui.currentGridType$,st=ie.ads.duration,Ei=ie.ads.position,Vo=ie.ads.playbackState,Xo=ie.ui.isFullscreen,xt=ie.ui.playerSize,Bt=ie.ui.additionalButtonsDeprecated$,z=ie.actions.internal.getVideoElement,Mt=ie.actions.internal.replayInteractive,ct=ie.state.isInteractive,_i=ie.state.isInteractiveTime$,Zt=ie.state.showInteractiveGraph,wt=ie.state.showSeekToInteractive,dt=ie.state.showPlayPrevChapter,Ui=ie.state.showInteractiveTimeIndicator,Pi=We.seekToInteractiveDisabledTooltip$,En=We.graphIsOpened$,Pn=ie.ui.controlBlocks,Ci=f(()=>Y(ie.state.playPrevChapterDisabledTooltip)),lo=f(()=>Y(r())),fr=f(()=>a().has("EPISODE_BUTTON")),Zi=f(()=>a().has("GRAPH_BUTTON")),yi=f(()=>a().has("SEEK_TO_INTERACTIVE_BUTTON")),Ro=f(()=>a().has("PLAY_BUTTON")),Zo=f(()=>a().has("REPLAY_BUTTON")),_o=f(()=>a().has("PLAY_PREV_CHAPTER_BUTTON")),mn=f(()=>l()===Tb.PLAYING),Hr=f(()=>d()==="paused"),Fr=f(()=>s()&&!de()&&!ct),xs=f(()=>!s()||de()),mr=f(()=>e.showNextPrevButtons&&!de()&&e.prevButtonActive),vr=f(()=>e.showNextPrevButtons&&!de()&&e.nextButtonActive),Ur=f(()=>u().width>300),zr=f(()=>u().width>400),Jo=f(m),An=f(()=>p()!==Cb.NOT_AVAILABLE&&!(v()&&b()===1)&&!y()&&!ct&&!_()),Yn=f(()=>x()==="LiveWaitingStart"),gr=f(()=>!!ui&&p()!==Cb.CONNECTED&&!y()&&(b()===1&&n(Yn)||!n(Yn))&&!n(Jo)&&!ct&&!I()),ns=K(!1);Vt(()=>{let Ye=ui==null?void 0:ui.info.isActive$.subscribe(At=>O(ns,At,!0));return()=>Ye==null?void 0:Ye.unsubscribe()});let en=f(()=>!n(Jo)&&oo(C(),"s")),hr=f(()=>!e.logoHidden&&u().width>350&&!R()),kn=f(()=>ee.features.fullscreen&&gt()&&!(v()&&b()===1)&&(ct?ze():!0)&&!n(Jo)&&!n(ns)),_r=f(()=>!k()&&!n(Jo)),br=f(()=>(!P()||de())&&u().width>260&&!n(Jo)&&!(ee.features.interactiveHideTime&&ct)),wo=f(()=>E()||e.showControls),$r=f(()=>!de()&&!P()&&!!(at!=null&&at.length)&&n(Ur)&&!n(fr)&&!n(Jo)),Ji=f(()=>!W()||!!F()),jn=f(()=>Zt&&oo(C(),"m")),Xn=f(()=>!U()||j()||se()===0),mt=ci({}),ii=ci({}),yr=Ib(Kl,260),xr=Ib(tp,260);He(()=>{u(),G(),yr(z(),Nt,mt,e.showControls),xr(z(),Pn,ii,e.showControls)});let rs=()=>ie.actions.internal.toggleChromecast();function Ln(){return ht(this,null,function*(){ui!=null&&ui.isActive()?yield ui==null?void 0:ui.exit():yield ui==null?void 0:ui.request()})}function wr(){ca({isAudioDisabled:Wt,audioDisabledHintCallback:Lt,isAudioAvailable:U(),audioIsNotExistHintCallback:It,isAds:de()})&&ke()}let So=K(""),tn=(Ye,At)=>{if(!Ye){O(So,Y("tooltip_live"),!0);return}At&&At===Tb.PAUSED&&O(So,Y("tooltip_play"),!0)};He(()=>{tn(n(Ji),l())});let Sr=ae();He(()=>{re()&&Ol(re(),E(),Kt)}),He(()=>{Ju(Si,X(),mt.playButton)});var on=jw(),nn=le(on);{var Wr=Ye=>{var At=qw(),fi=le(At);let Do;var To=A(fi,2);let Io;it(To,ut=>ii.topLeft=ut,()=>ii==null?void 0:ii.topLeft);var Wi=A(To,2);let No;var Dn=T(Wi);bi(Dn,1,ue,({iconUrl:ut,ariaLabel:di,testId:Po,onClick:uo,tooltip:Mi})=>ut,(ut,di)=>{let Po=()=>n(di).iconUrl,uo=()=>n(di).ariaLabel,Mi=()=>n(di).testId,Pr=()=>n(di).onClick,Cs=()=>n(di).tooltip,Ts=f(()=>{var po;return(po=uo())!=null?po:Cs()});Ym(ut,{get iconUrl(){return Po()},get ariaLabel(){return n(Ts)},get testId(){return Mi()},get onClick(){return Pr()}})});var Ir=A(Dn,2);{var Eo=ut=>{sc(ut,{get ref(){return mt.autoplayNextToggle},set ref(di){mt.autoplayNextToggle=di}})};V(Ir,ut=>{e.showAutoplayNext&&!ge()&&!te()&&ut(Eo)})}var co=A(Ir,2);{var Jn=ut=>{Xd(ut,{isMobile:!0,click:rs,get state(){return p()},get ref(){return mt.chromecast},set ref(di){mt.chromecast=di}})};V(co,ut=>{n(An)&&ut(Jn)})}var Bo=A(co,2);{var Nn=ut=>{Zm(ut,{click:Ln,get isPictureInPictureActive(){return v()},get ref(){return mt.pip},set ref(di){mt.pip=di}})};V(Bo,ut=>{n(gr)&&ut(Nn)})}var Er=A(Bo,2);{var qr=ut=>{Hl(ut,{get ref$(){return Sr}})};V(Er,ut=>{be()&&!Ce()&&ut(qr)})}var Qr=A(Er,2);{var Xe=ut=>{Yd(ut,{get click(){return Ie},get targetUrl(){return _e()},get logoClickable(){return e.logoClickable},get ref(){return mt.vkLogo},set ref(di){mt.vkLogo=di}})};V(Qr,ut=>{n(hr)&&ut(Xe)})}S(Wi),it(Wi,ut=>ii.topRight=ut,()=>ii==null?void 0:ii.topRight);var Xt=A(Wi,2);let Li;var yo=T(Xt);{var an=ut=>{let di=f(()=>Ae.bind(null,!0));Qa(ut,{get click(){return n(di)},type:"prev",isMobile:!0,get ref(){return mt.prevButton},set ref(Po){mt.prevButton=Po}})};V(yo,ut=>{n(mr)&&ut(an)})}var er=A(yo,2);{var Ho=ut=>{Ql(ut,{get disabled(){return n(Ro)},get click(){return Ue},isMobile:!0,get isPlaying(){return n(mn)},get ref(){return mt.playButton},set ref(di){mt.playButton=di}})};V(er,ut=>{n(xs)&&ut(Ho)})}var tr=A(er,2);{var ls=ut=>{ql(ut,{get disabled(){return n(Zo)},get click(){return Ue},isMobile:!0,get ref(){return mt.replayButton},set ref(di){mt.replayButton=di}})};V(tr,ut=>{n(Fr)&&ut(ls)})}var qs=A(tr,2);{var Bn=ut=>{let di=f(()=>Ne.bind(null,!0));Qa(ut,{get click(){return n(di)},type:"next",isMobile:!0,get ref(){return mt.nextButton},set ref(Po){mt.nextButton=Po}})};V(qs,ut=>{n(vr)&&ut(Bn)})}S(Xt),it(Xt,ut=>ii.middle=ut,()=>ii==null?void 0:ii.middle);var ga=A(Xt,2);{var Qs=ut=>{var di=Kw(),Po=le(di);{var uo=po=>{var Vi=Uw();let fe;Vi.__click=[Hw,_o,e,Ci];var Tt=T(Vi);let Jt=f(()=>!e.showControls);rc(Tt,{get hidden(){return n(Jt)},get disabled(){return n(_o)},get click(){return e.playPrevChapter},get ref(){return mt.playPrevChapterButton},set ref(ei){mt.playPrevChapterButton=ei}}),S(Vi),D(ei=>fe=ne(Vi,1,"wrapper-middle-left s-15",null,fe,ei),[()=>({fullscreen:Te(),hidden:!e.showControls})]),$(po,Vi)};V(Po,po=>{dt&&po(uo)})}var Mi=A(Po,2);{var Pr=po=>{var Vi=zw();let fe;var Tt=T(Vi);let Jt=f(()=>!e.showControls&&!me());lc(Tt,{get hidden(){return n(Jt)},get disabled(){return n(Zi)},get click(){return En.toggle},get graphIsOpened(){return me()},get ref(){return mt.interactiveGraphButton},set ref(ei){mt.interactiveGraphButton=ei}}),S(Vi),D(ei=>fe=ne(Vi,1,wd(dt?"wrapper-middle-left-second":"wrapper-middle-left"),"s-15",fe,ei),[()=>({fullscreen:Te(),hidden:!e.showControls&&!me()})]),$(po,Vi)};V(Mi,po=>{n(jn)&&po(Pr)})}var Cs=A(Mi,2);{var Ts=po=>{var Vi=Ww();let fe;Vi.__click=[Fw,yi,e,lo];var Tt=T(Vi);let Jt=f(()=>!e.showControls);ac(Tt,{get hidden(){return n(Jt)},get disabled(){return n(yi)},get click(){return e.seekToInteractive},get ref(){return mt.seekToInteractiveButton},set ref(ei){mt.seekToInteractiveButton=ei}}),S(Vi),D(ei=>fe=ne(Vi,1,"wrapper-middle-right s-15",null,fe,ei),[()=>({fullscreen:Te(),hidden:!e.showControls})]),$(po,Vi)};V(Cs,po=>{wt&&po(Ts)})}$(ut,di)};V(ga,ut=>{ct&&!m()&&ut(Qs)})}D((ut,di,Po,uo)=>{Do=ne(fi,1,"overlay-mobile s-15",null,Do,ut),Io=ne(To,1,"wrapper-top-left s-15",null,Io,di),No=ne(Wi,1,"wrapper-top-right s-15",null,No,Po),Li=ne(Xt,1,"wrapper-middle s-15",null,Li,uo)},[()=>({hidden:!n(wo)}),()=>({hidden:!e.showControls,fullscreen:Te()}),()=>({hidden:!e.showControls&&!y(),fullscreen:Te()}),()=>({hidden:!e.showControls||m()||e.endScreenShown&&e.showNextPrevButtons})]),$(Ye,At)};V(nn,Ye=>{de()||Ye(Wr)})}var vn=A(nn,2);{var gn=Ye=>{var At=Gw(),fi=le(At);let Do;var To=T(fi);ip(To,{get muted(){return j()},click:wr,get ref(){return mt.volume},set ref(Eo){mt.volume=Eo}}),S(fi);var Io=A(fi,2);{var Wi=Eo=>{var co=Qw(),Jn=T(co);let Bo=f(()=>!n(Hr));Ql(Jn,{get disabled(){return n(Ro)},get click(){return Ue},isMobile:!0,get isPlaying(){return n(Bo)},get ref(){return mt.playButton},set ref(Nn){mt.playButton=Nn}}),S(co),$(Eo,co)};V(Io,Eo=>{n(Hr)&&Eo(Wi)})}var No=A(Io,2);let Dn;var Ir=T(No);cc(Ir,{get position(){return qe()},get duration(){return ve()}}),S(No),D((Eo,co)=>{Do=ne(fi,1,"wrapper-top-right s-15",null,Do,Eo),Dn=ne(No,1,"wrapper-bottom ads-timeline-mobile s-15",null,Dn,co)},[()=>({fullscreen:Te()}),()=>({fullscreen:Te()})]),$(Ye,At)};V(vn,Ye=>{de()&&d()!=="inactive"&&Ye(gn)})}var Ai=A(vn,2);let Mn;var eo=T(Ai);let Vn;var Zn=T(eo),hn=T(Zn),Cr=T(hn);{var et=Ye=>{Mo(Ye,{get disabled(){return n(Zo)},get ref(){return mt.replayButton},set ref(At){mt.replayButton=At},children:(At,fi)=>{ql(At,{get disabled(){return n(Zo)},get click(){return Mt}})},$$slots:{default:!0}})};V(Cr,Ye=>{ct&&Ye(et)})}var li=A(Cr,2);{var Oo=Ye=>{Mo(Ye,{get ref(){return mt.liveButton},set ref(At){mt.liveButton=At},children:(At,fi)=>{dc(At,{get isLiveActive(){return n(Ji)},isMobile:!0,get ariaLabel(){return n(So)}})},$$slots:{default:!0}})};V(li,Ye=>{!de()&&P()&&Ye(Oo)})}var _n=A(li,2);{var Co=Ye=>{let At=f(()=>de()?qe():pe()),fi=f(()=>de()?ve():Z()),Do=f(()=>!e.showControls);qd(Ye,{get showDuration(){return n(zr)},get position(){return n(At)},get duration(){return n(fi)},isMobile:!0,get isHidden(){return n(Do)},get ref(){return mt.time},set ref(To){mt.time=To}})};V(_n,Ye=>{n(br)&&Ye(Co)})}var rn=A(_n,2);let bo=f(()=>!n($r));Mo(rn,{className:"w-max",get disabled(){return n(bo)},get ref(){return mt.episodes},set ref(Ye){mt.episodes=Ye},children:(Ye,At)=>{var fi=Oe(),Do=le(fi);{var To=Io=>{var Wi=Yw(),No=A(le(Wi),2);Zd(No,{get position(){return pe()},get duration(){return Z()},get timeCodes(){return at}}),$(Io,Wi)};V(Do,Io=>{n($r)&&Io(To)})}$(Ye,fi)},$$slots:{default:!0}}),S(hn),it(hn,Ye=>ii.bottomLeft=Ye,()=>ii==null?void 0:ii.bottomLeft);var $o=A(hn,2),ki=T($o);{var Kr=Ye=>{Mo(Ye,{get ref(){return mt.volume},set ref(At){mt.volume=At},children:(At,fi)=>{ip(At,{get muted(){return n(Xn)},click:wr})},$$slots:{default:!0}})};V(ki,Ye=>{n(_r)&&Ye(Kr)})}var Rn=A(ki,2);{var ws=Ye=>{Mo(Ye,{get ref(){return mt.settings},set ref(At){mt.settings=At},children:(At,fi)=>{Hl(At,{get ref$(){return Sr}})},$$slots:{default:!0}})};V(Rn,Ye=>{n(en)&&Ye(ws)})}var zi=A(Rn,2);{var Ss=Ye=>{Mo(Ye,{get ref(){return mt.fullscreen},set ref(At){mt.fullscreen=At},children:(At,fi)=>{Gd(At,{get click(){return e.toggleFullscreen},get isFullscreen(){return Te()}})},$$slots:{default:!0}})};V(zi,Ye=>{n(kn)&&Ye(Ss)})}S($o),it($o,Ye=>ii.bottomRight=Ye,()=>ii==null?void 0:ii.bottomRight),S(Zn),it(Zn,Ye=>ce(Ye),()=>ce());var ss=A(Zn,2);let as=f(()=>!e.showControls);Ya(ss,{get isHidden(){return n(as)},get isAds(){return de()},get canRewindLive(){return e.canRewindLive},get isRewindableLive(){return W()},get ref(){return mt.timeline},set ref(Ye){mt.timeline=Ye}}),S(eo),it(eo,Ye=>ii.bottom=Ye,()=>ii==null?void 0:ii.bottom),S(Ai),it(Ai,Ye=>N(Ye),()=>N());var Tr=A(Ai,2);{var sn=Ye=>{oc(Ye,{get ref(){return mt.interactiveTimeIndicator},set ref(At){mt.interactiveTimeIndicator=At}})};V(Tr,Ye=>{Ui&&Ye(sn)})}D((Ye,At)=>{Mn=ne(Ai,1,"wrapper-bottom mobile s-15",null,Mn,Ye),Vn=ne(eo,1,"controls-wrapper s-15",null,Vn,At)},[()=>({hidden:e.bottomHidden,"controls-hidden":!e.showControls,"no-smooth":e.bottomNoSmooth}),()=>({fullscreen:Te()})]),$(i,on),H(),o()}Je(["click"]);function uc(i,e){B(e,!0);let[t,o]=Be(),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,Eb),_=h(e,"onDisabledSeekToInteractiveClick",3,Eb),I=xe().ui.isMobile,C=K(!1);Vt(()=>{let E=setTimeout(()=>O(C,!0),0);return()=>clearTimeout(E)});var R=Oe(),k=le(R);{var P=E=>{var W=Oe(),F=le(W);{var U=se=>{Jm(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(G){l(G)},get playerControlsRef(){return d()},set playerControlsRef(G){d(G)}})},j=se=>{Gm(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(G){l(G)},get playerControlsRef(){return d()},set playerControlsRef(G){d(G)}})};V(F,se=>{r()?se(U):se(j,!1)})}$(E,W)};V(k,E=>{n(C)&&E(P)})}$(i,R),H(),o()}var Zw=Pe('<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(()=>`${un(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=Zw();$(r,l)},$$slots:{default:!0}}),H()}var Jw=Pe('<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=Jw();$(a,d)},$$slots:{default:!0}}),H()}var eS=L('<span class="hot-key-helpers-text s-v"> </span>'),tS=L('<div data-testid="hotkey-helper-icon" class="s-v"><!> <!> <!> <!> <!> <!> <!> <!> <!> <!></div> <!>',1),iS=L("<div><!></div>"),oS={hash:"s-v",code:'.hot-key-helpers-container.s-v{align-items:center;animation:s-v-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-v{left:calc(25% - 100px)}.hot-key-helpers-container--right.s-v{left:calc(75% - 100px)}.hot-key-helpers-text.s-v{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-v{animation:s-v-fadeOut ease var(--controls-transition-duration);height:0;visibility:hidden;width:0}@keyframes s-v-fadeIn{0%{opacity:0}to{opacity:1}}@keyframes s-v-fadeOut{0%{opacity:1}to{opacity:0}}'};function tv(i,e){B(e,!0),Q(i,oS);let[t,o]=Be(),r=()=>w(e.data,"$data",t),a=xe(),{features:l}=Rt(),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=iS();let y;var _=T(b);{var x=I=>{var C=tS(),R=le(C),k=T(R);{var P=ce=>{let de=f(()=>n(p)==="BACKWARD_SEEK");ev(ce,{get reversed(){return n(de)},shadow:!0})};V(k,ce=>{["BACKWARD_SEEK","FORWARD_SEEK"].includes(n(p))&&ce(P)})}var E=A(k,2);{var W=ce=>{zs(ce,{get size(){return"48"},shadow:!0})};V(E,ce=>{n(p)==="PAUSE"&&!l.playbackStatusShow&&ce(W)})}var F=A(E,2);{var U=ce=>{Tn(ce,{get size(){return"48"},shadow:!0})};V(F,ce=>{n(p)==="PLAY"&&!l.playbackStatusShow&&ce(U)})}var j=A(F,2);{var se=ce=>{nc(ce,{get size(){return"48"},shadow:!0})};V(j,ce=>{n(p)==="REPLAY"&&!l.playbackStatusShow&&ce(se)})}var G=A(j,2);{var re=ce=>{ua(ce,{get size(){return"48"},type:"off",shadow:!0})};V(G,ce=>{n(p)==="SUBTITLES_OFF"&&ce(re)})}var X=A(G,2);{var Te=ce=>{ua(ce,{get size(){return"48"},shadow:!0})};V(X,ce=>{n(p)==="SUBTITLES_ON"&&ce(Te)})}var ue=A(X,2);{var te=ce=>{let de=f(()=>n(p)==="RATE_DOWN");pc(ce,{get size(){return"48"},get reversed(){return n(de)},testId:"rate-change-icon",shadow:!0})};V(ue,ce=>{["RATE_DOWN","RATE_UP"].includes(n(p))&&ce(te)})}var be=A(ue,2);{var Ce=ce=>{let de=f(()=>n(p)==="EPISODE_PREV");fa(ce,{get size(){return"48"},get reversed(){return n(de)},shadow:!0})};V(be,ce=>{["EPISODE_PREV","EPISODE_NEXT"].includes(n(p))&&ce(Ce)})}var me=A(be,2);{var qe=ce=>{pa(ce,{get size(){return"48"},volume:0,shadow:!0})};V(me,ce=>{n(p)==="MUTE"&&ce(qe)})}var ve=A(me,2);{var pe=ce=>{pa(ce,{get size(){return"48"},volume:1,shadow:!0})};V(ve,ce=>{n(p)==="VOLUME"&&ce(pe)})}S(R);var Z=A(R,2);{var N=ce=>{var de=eS(),_e=T(de,!0);S(de),D(()=>he(_e,n(v))),$(ce,de)};V(Z,ce=>{n(v)&&ce(N)})}D(()=>De(R,"data-type",n(p))),$(I,C)};V(_,I=>{!n(s)&&n(p)&&I(x)})}S(b),D(I=>y=ne(b,1,"hot-key-helpers-container s-v",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 nS=(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}},rS=(i,e,t)=>{e.has(i.code)&&(i.preventDefault(),i.stopPropagation(),t())},sS=L('<div tabindex="0" role="button"><div class="button-block s-p" aria-hidden="true"><div class="button-row s-p"><div class="button button-up s-p"><!></div> <div class="button button-right s-p"><!></div></div> <div class="button-row s-p"><div class="button button-left s-p"><!></div> <div class="button button-down s-p"><!></div></div></div></div>'),aS={hash:"s-p",code:".immersive-controls.s-p{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-p{left:20px;top:50px}.button-block.s-p{height:40px;margin:auto;transform:rotate(45deg);width:40px}.button-row.s-p{display:flex;flex-direction:row;position:relative}.button.s-p{cursor:pointer;height:20px;text-align:center;width:20px}.button.s-p svg{opacity:.7;transition:opacity .2s linear}.button.button-up.s-p svg{transform:rotate(-45deg) translate(-1px,-1px)}.button.button-right.s-p svg{transform:rotate(45deg) translate(1px,-1px)}.button.button-down.s-p svg{transform:rotate(135deg) translate(1px,-3px)}.button.button-left.s-p svg{transform:rotate(-135deg) translate(-1px,-3px)}.button.s-p:hover svg{opacity:1}"};function fc(i,e){B(e,!0),Q(i,aS);let t=h(e,"isShifted",3,!1),o=xe(),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=sS();let v;p.__keydown=[nS,r,a,l,s,d],p.__keyup=[rS,r,u];var b=T(p),y=T(b),_=T(y);_.__mousedown=a,_.__mouseup=u;var x=T(_);Nr(x,{direction:"up",useBtnColor:!0}),S(_);var I=A(_,2);I.__mousedown=d,I.__mouseup=u;var C=T(I);Nr(C,{direction:"up",useBtnColor:!0}),S(I),S(y);var R=A(y,2),k=T(R);k.__mousedown=s,k.__mouseup=u;var P=T(k);Nr(P,{direction:"up",useBtnColor:!0}),S(k);var E=A(k,2);E.__mousedown=l,E.__mouseup=u;var W=T(E);Nr(W,{direction:"up",useBtnColor:!0}),S(E),S(R),S(b),S(p),D(F=>{v=ne(p,1,"immersive-controls s-p",null,v,F),De(p,"aria-label",m)},[()=>({"m-shifted":t()})]),ft("mouseleave",_,u),ft("mouseleave",I,u),ft("mouseleave",k,u),ft("mouseleave",E,u),$(i,p),H()}Je(["keydown","keyup","mousedown","mouseup"]);import{ValueSubject as Ab,Subscription as lS,filterChanged as dS,filter as cS}from"@vkontakte/videoplayer-shared/es2015";var Pb=(i=1e3)=>{let e=null,t=()=>{e&&(clearTimeout(e),e=null)};return{add:o=>{t(),e=setTimeout(o,i)},clear:t}};var op=class{constructor(){this.flickeringTimeout=Pb(1e3);this.subscriptions=new lS;this.isAuto=!1;this.isLive=!1;this.captions$=new Ab([]);this.captionsPrepared$=new Ab([])}subscribe(){return this.subscriptions.add(this.captions$.pipe(cS(()=>this.isEnabled()),dS()).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 uS=L('<span class="caption-line s-e"><span class="caption-segment s-e"> </span></span>'),pS=L('<span class="caption-line s-e"><span class="caption-segment s-e"></span></span>'),fS=L('<span class="caption-line s-e"><span class="caption-segment s-e"> </span></span>'),mS=L('<div><span class="caption s-e"><!></span></div>'),vS=L("<div><!></div>"),gS={hash:"s-e",code:".subtitles-container.s-e{height:100%;left:0;pointer-events:none;position:absolute;top:0;transition:transform var(--controls-transition-duration);width:100%}.subtitles-container.shifted.s-e{transform:translateY(calc(var(--controls-height)*-1))}.subtitles-container.preview-track-active.s-e{transform:translateY(calc(var(--preview-track-height)*-1))}.preview-track-active.s-e .subtitles-caption:where(.s-e){bottom:var(--preview-track-controls-top-offset)}.subtitles-caption.s-e{bottom:4%;display:flex;justify-content:center;left:4%;position:absolute;right:4%}.subtitles-caption.mobile.s-e{bottom:8%}.subtitles-container.auto.s-e .subtitles-caption:where(.s-e){left:var(--subtitles-caption-margin);right:var(--subtitles-caption-margin)}.caption.s-e{background:rgba(0,0,0,.4);border-radius:4px;display:block;overflow-wrap:normal;padding:4px 8px}.subtitles-container.auto.s-e .caption:where(.s-e){width:100%}.caption-line.s-e{display:block;text-align:center}.subtitles-container.auto.s-e .caption-line:where(.s-e){text-align:left}.caption-segment.s-e{color:var(--white);display:inline-block;font-size:13px;line-height:1.2;white-space:pre-wrap}"};function Xa(i,e){B(e,!0),Q(i,gS);let[t,o]=Be(),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=xe(),p=Rt(),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),k=f(()=>u()&&!l()||n(R)<=p.minSubtitlesFontSize?p.minSubtitlesFontSize:n(R)),P=K(null);He(()=>{var G,re,X;(G=n(P))==null||G.setIsAuto(n(I)),(re=n(P))==null||re.setIsLive(n(C)),(X=n(P))==null||X.setCaptions(e.captions)});let E=K(ci([[]]));Vt(()=>{O(P,new op().subscribe(),!0);let G=n(P).captionsPrepared$.subscribe(re=>{O(E,re,!0)});return()=>{var re;(re=n(P))==null||re.destroy(),G.unsubscribe()}}),Vt(()=>{if(n(I)){let G=window.setTimeout(()=>{b.set(!1)},p.autoSubtitlesTimeout);return()=>{window.clearTimeout(G)}}else b.set(!1)});let W=f(()=>e.playerSize.width<400?10:e.playerSize.width<550?14:24);var F=vS();let U;var j=T(F);{var se=G=>{var re=mS();let X;var Te=T(re),ue=T(Te);{var te=Ce=>{var me=uS(),qe=T(me),ve=T(qe,!0);S(qe),S(me),D(pe=>{var Z;je(qe,`font-size: ${(Z=n(k))!=null?Z:""}px`),he(ve,pe)},[()=>Y("subtitles_auto_caption")]),$(Ce,me)},be=(Ce,me)=>{{var qe=pe=>{var Z=Oe(),N=le(Z);bi(N,17,()=>n(E),yd,(ce,de)=>{var _e=pS(),ge=T(_e);bi(ge,21,()=>n(de),({value:ze,timeAppeared:ie})=>ie,(ze,ie)=>{let We=()=>n(ie).value,ee=()=>n(ie).timeAppeared;var ke=Oe(),Ue=le(ke);{var Ie=Ae=>{var Ne=gs();D(()=>he(Ne,We())),$(Ae,Ne)};V(Ue,Ae=>{(!ee()||ee()<=e.position)&&Ae(Ie)})}$(ze,ke)}),S(ge),S(_e),D(()=>{var ze;return je(ge,`font-size: ${(ze=n(k))!=null?ze:""}px`)}),$(ce,_e)}),$(pe,Z)},ve=pe=>{var Z=Oe(),N=le(Z);bi(N,17,()=>e.captions,({value:ce})=>ce,(ce,de)=>{let _e=()=>n(de).value;var ge=fS(),ze=T(ge),ie=T(ze,!0);S(ze),S(ge),D(()=>{var We;je(ze,`font-size: ${(We=n(k))!=null?We:""}px`),he(ie,_e())}),$(ce,ge)}),$(pe,Z)};V(Ce,pe=>{var Z;n(I)&&((Z=n(E))!=null&&Z.length)?pe(qe):pe(ve,!1)},me)}};V(ue,Ce=>{n(I)&&s()?Ce(te):Ce(be,!1)})}S(Te),S(re),D(Ce=>{var me;X=ne(re,1,"subtitles-caption s-e",null,X,Ce),je(re,`--subtitles-caption-margin: ${(me=n(W))!=null?me:""}%`)},[()=>({mobile:u()})]),$(G,re)};V(j,G=>{var re;(e.captions.length||(re=n(E))!=null&&re.length)&&G(se)})}S(F),D(G=>U=ne(F,1,"subtitles-container s-e",null,U,G),[()=>({shifted:e.shifted,"preview-track-active":d(),auto:n(I)&&!n(C)&&!s()})]),$(i,F),H(),o()}import{ChromecastState as hS}from"@vkontakte/videoplayer-core/es2015";var _S=L('<div class="text s-n"> </div>'),bS=L('<div><div class="icon_wrapper s-n"><!></div> <!></div>'),$S={hash:"s-n",code:".wrapper.s-n{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-n{background-size:cover}.icon_wrapper.s-n{align-items:center;display:flex;flex-direction:column;width:400px}.text.s-n{margin-top:20px}"};function mc(i,e){B(e,!0),Q(i,$S);let t=h(e,"chromecastDeviceName",3,"chromecastDeviceName"),o=Rt();var r=bS();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);jd(d,{get size(){return"48"},get iconState(){return hS.CONNECTED}}),S(l);var s=A(l,2);{var u=m=>{var p=_S(),v=T(p);S(p),D(()=>{var b;return he(v,`Видео воспроизводится на ${(b=t())!=null?b:""}`)}),$(m,p)};V(s,m=>{t()&&m(u)})}S(r),D(m=>{a=ne(r,1,"wrapper s-n",null,a,m),je(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()}Je(["contextmenu","click","dblclick"]);var yS=Pe('<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 iv(i){Ze(i,{width:"200",height:"200",viewBox:"460 190 130 90",testId:"error-icon",children:(e,t)=>{var o=yS();$(e,o)},$$slots:{default:!0}})}var xS=L('<div class="container s-4"><!></div>'),wS={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 Za(i){Q(i,wS);var e=xS(),t=T(e);iv(t,{}),S(e),$(i,e)}var SS=L('<div class="playButton s-a" tabindex="0" role="button"><div class="playButtonBackground s-a"></div> <!></div>'),CS=L('<div data-testid="unstarted-thumb"><!></div>'),TS={hash:"s-a",code:".container.s-a{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-a{opacity:0;visibility:hidden}.container.bgCover.s-a{background-size:cover}.playButton.s-a{align-items:center;display:flex;height:var(--big-play-size);justify-content:center;margin:auto;width:var(--big-play-size)}.playButton.s-a,.playButtonBackground.s-a{bottom:0;left:0;position:absolute;right:0;top:0}.playButtonBackground.s-a{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-a:hover .playButtonBackground:where(.s-a){background-color:var(--big-play-hover-bg-color);transform:scale(1.15)}.playButton.s-a svg{position:relative}"};function Ja(i,e){B(e,!0),Q(i,TS);let t=h(e,"iconVisible",3,!0),o=xe(),r=Rt(),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=CS();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=SS();y.__keydown=d;var _=A(T(y),2);Tn(_,{get size(){return"48"}}),S(y),D(()=>De(y,"aria-label",l)),$(b,y)};V(p,b=>{t()&&b(v)})}return S(u),D(b=>{m=ne(u,1,"container s-a",null,m,b),je(u,`background-color: #222; background-image: url('${e.thumbUrl||""}')`)},[()=>({hidden:e.hidden,bgCover:r.features.previewNoEmptySpace})]),$(i,u),H({handlePressKey:d,handleClick:s})}Je(["click","contextmenu","keydown"]);var IS=L('<span class="text s-y"> </span>'),ES=(i,e)=>{var t;return(t=e.onTitleClicked)==null?void 0:t.call(e)},PS=L('<a target="_blank" class="link s-y"><!></a>'),AS=(i,e)=>e.onTitleClicked(),kS=L("<button><!></button>"),LS=L('<div data-testid="video_title"><!></div>'),MS={hash:"s-y",code:".title.s-y{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-y,.title.s-y{color:var(--white)}.link.s-y{pointer-events:auto;text-decoration:none}.link.s-y:hover{text-decoration:underline}.text.s-y{pointer-events:auto}.size-sm.s-y{font-size:14px;font-weight:500;line-height:18px}.hidden.s-y{opacity:0;transform:translateY(calc(var(--controls-gradient-height)*-1));visibility:hidden}"};function ov(i,e){B(e,!0),Q(i,MS);let t=b=>{var y=IS(),_=T(y,!0);S(y),it(y,x=>l(x),()=>l()),D(()=>he(_,o())),ft("mouseenter",y,function(...x){var I;(I=e.onMouseEnter)==null||I.apply(this,x)}),ft("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);Vt(()=>{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=LS();let u;var m=T(s);{var p=b=>{var y=PS();y.__click=[ES,e];var _=T(y);t(_),S(y),D(()=>De(y,"href",e.titleLinkHref)),$(b,y)},v=(b,y)=>{{var _=I=>{var C=kS();C.__click=[AS,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)),D(b=>u=ne(s,1,`title size-${a()}`,"s-y",u,b),[()=>({hidden:r()})]),$(i,s),H()}Je(["click"]);import{throttleFn as HS}from"@vkontakte/videoplayer-shared/es2015";var VS=L('<div class="timer__cell cell s-17"><span class="cell__value s-17"> </span> <span class="cell__unit s-17"> </span></div> <span class="timer__points s-17"> </span>',1),RS=L('<div class="timer__cell cell s-17"><span class="cell__value s-17"> </span> <span class="cell__unit s-17"> </span></div> <span class="timer__points s-17"> </span>',1),OS=L('<div class="timer__cell cell s-17"><span class="cell__value s-17"> </span> <span class="cell__unit s-17"> </span></div> <span class="timer__points s-17"> </span>',1),DS=L('<div class="timer__cell cell s-17"><span class="cell__value s-17"> </span> <span class="cell__unit s-17"> </span></div>'),NS=L("<div><!> <!> <!> <!></div>"),BS={hash:"s-17",code:".timer__container.s-17{align-items:flex-start;display:flex;justify-content:center}.cell.s-17{align-items:center;display:flex;flex-direction:column}.cell__value.s-17{font-size:48px;font-weight:600;line-height:1.2}.small.s-17 .cell__value:where(.s-17){font-size:24px}.cell__unit.s-17{font-size:14px;font-weight:400;line-height:1.2}.small.s-17 .cell__unit:where(.s-17){font-size:12px}.timer__points.s-17{display:inline-block;font-size:42px;font-weight:600;line-height:1.2;margin:0 8px}.small.s-17 .timer__points:where(.s-17){font-size:20px}"};function nv(i,e){B(e,!0),Q(i,BS);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 j=Math.floor(F/3600);O(o,u(j),!0);let se=Math.floor(F/60)%60;O(r,u(se),!0);let G=F%60;O(a,u(G),!0)},b=()=>{let F=Math.floor(Date.now()/1e3),U=e.startTime-F;v(U),U>=1?l=requestAnimationFrame(b):e.onTimerOver()};Vt(()=>{l=requestAnimationFrame(b)}),cn(()=>{cancelAnimationFrame(l)});var y=NS();let _;var x=T(y);{var I=F=>{var U=VS(),j=le(U);let se;var G=T(j),re=T(G,!0);S(G);var X=A(G,2),Te=T(X,!0);S(X),S(j);var ue=A(j,2),te=T(ue,!0);S(ue),D((be,Ce,me)=>{se=je(j,"",se,{width:be}),he(re,n(t)),he(Te,Ce),he(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=A(x,2);{var R=F=>{var U=RS(),j=le(U);let se;var G=T(j),re=T(G,!0);S(G);var X=A(G,2),Te=T(X,!0);S(X),S(j);var ue=A(j,2),te=T(ue,!0);S(ue),D((be,Ce,me)=>{se=je(j,"",se,{width:be}),he(re,n(o)),he(Te,Ce),he(te,me)},[()=>p(n(o)),()=>Y("waiting_live_hour_value"),()=>Y("waiting_live_colon")]),$(F,U)};V(C,F=>{n(o)&&F(R)})}var k=A(C,2);{var P=F=>{var U=OS(),j=le(U);let se;var G=T(j),re=T(G,!0);S(G);var X=A(G,2),Te=T(X,!0);S(X),S(j);var ue=A(j,2),te=T(ue,!0);S(ue),D((be,Ce,me)=>{se=je(j,"",se,{width:be}),he(re,n(r)),he(Te,Ce),he(te,me)},[()=>p(n(r)),()=>Y("waiting_live_minute_value"),()=>Y("waiting_live_colon")]),$(F,U)};V(k,F=>{n(r)&&F(P)})}var E=A(k,2);{var W=F=>{var U=DS();let j;var se=T(U),G=T(se,!0);S(se);var re=A(se,2),X=T(re,!0);S(re),S(U),D((Te,ue)=>{j=je(U,"",j,{width:Te}),he(G,n(a)),he(X,ue)},[()=>p(n(a)),()=>Y("waiting_live_second_value")]),$(F,U)};V(E,F=>{n(a)&&F(W)})}S(y),D(F=>_=ne(y,1,"timer__container s-17",null,_,F),[()=>({small:e.isSmallSize})]),$(i,y),H()}var FS=L('<div class="waiting s-j"><span> </span></div>'),US=L('<div class="upcoming-timer timer s-j"><span> </span> <!></div>'),zS=L('<div class="waiting-container s-j"><!></div>'),WS={hash:"s-j",code:'.waiting-container.s-j{background-color:var(--black);background-position:50%;background-repeat:no-repeat;background-size:cover;white-space:nowrap}.waiting-container.s-j,.waiting-container.s-j:before{height:100%;left:0;position:absolute;top:0;width:100%}.waiting-container.s-j:before{backdrop-filter:blur(15px);background-color:rgba(0,0,0,.56);content:"";z-index:1}.waiting.s-j{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-j{font-size:20px;font-weight:600;line-height:1.2}.upcoming-timer.s-j{left:50%;position:absolute;top:50%;transform:translate(-50%,-50%);z-index:2}.timer.s-j{align-items:center;display:flex;flex-direction:column;justify-content:center}.timer__title.s-j{display:inline-block;font-size:20px;font-weight:600;line-height:1.2;margin-bottom:12px;vertical-align:middle}.small.s-j{font-size:15px}.medium.s-j{font-size:17px}'};function vc(i,e){B(e,!0),Q(i,WS);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?HS(()=>{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;He(()=>{n(s),n(d),n(o),p==null||p()}),cn(()=>{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=zS();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=FS(),C=T(I);let R;var k=T(C,!0);S(C),S(I),it(I,P=>O(r,P),()=>n(r)),D((P,E)=>{R=ne(C,1,"waiting__title s-j",null,R,P),he(k,E)},[()=>({medium:n(m),small:n(u)}),()=>Y("waiting_live_upcoming_title")]),$(x,I)},_=x=>{var I=US(),C=T(I);let R;var k=T(C,!0);S(C);var P=A(C,2);let E=f(()=>n(u)||n(m)),W=f(()=>t()||0);nv(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)),D((F,U)=>{R=ne(C,1,"timer__title s-j",null,R,F),he(k,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),D(()=>je(v,`background-image: url(${e.thumbUrl})`)),Sn(v,"clientWidth",x=>O(d,x)),Sn(v,"clientHeight",x=>O(s,x)),$(i,v),H()}Je(["contextmenu","click"]);var KS=L('<div class="waiting-container s-q"><div class="waiting-caption s-q"><!> <p class="waiting-title s-q"> </p></div></div>'),qS={hash:"s-q",code:'.waiting-container.s-q{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-q,.waiting-container.s-q:before{height:100%;left:0;position:absolute;top:0;width:100%}.waiting-container.s-q:before{backdrop-filter:blur(10px);background-color:rgba(0,0,0,.4);content:""}.waiting-caption.s-q{align-items:center;display:flex;flex-direction:column;position:relative}.waiting-title.s-q{font-size:20px;font-weight:400;line-height:1.2;margin:0;padding:20px;text-align:center}'};function el(i,e){B(e,!0),Q(i,qS);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=KS();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);za(d,{style:"position: static; transform: translate(0, 0)"});var s=A(d,2),u=T(s,!0);S(s),S(l),S(a),D(()=>{je(a,`background-image: url('${t()}')`),he(u,n(r))}),$(i,a),H()}Je(["contextmenu","click"]);var QS=Pe('<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 rv(i){Ze(i,{width:"16",height:"16",testId:"check-mark-icon",children:(e,t)=>{var o=QS();$(e,o)},$$slots:{default:!0}})}var GS=L('<div class="select-icon s-1w"><!></div>'),YS={hash:"s-1w",code:".select-icon.s-1w{margin-right:auto;opacity:.9;padding-right:12px;position:relative;top:3px}"};function gc(i){Q(i,YS);var e=GS(),t=T(e);rv(t,{}),S(e),$(i,e)}var jS=(i,e)=>{i.stopPropagation(),e.item.selectItem(e.item.value)},XS=(i,e)=>{Dl(i,()=>e.item.selectItem(e.item.value))},ZS=L("<p> </p>"),JS=L('<p class="sublabel s-1r"> </p>'),eC=L('<li role="menuitem" tabindex="0"><!> <div><!> <!></div></li>'),tC={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 sv(i,e){B(e,!0),Q(i,tC);let t=h(e,"isMobile",3,!1);var o=eC();let r;o.__click=[jS,e],o.__keydown=[XS,e];var a=T(o);{var l=y=>{gc(y,{})};V(a,y=>{e.item.selected&&y(l)})}var d=A(a,2);let s;var u=T(d);{var m=y=>{var _=Oe(),x=le(_);Hi(x,()=>e.item.valueComponent,(I,C)=>{C(I,ts(()=>{var R;return(R=e.item.valueComponentParams)!=null?R:{}}))}),$(y,_)},p=y=>{var _=ZS();let x;var I=T(_,!0);S(_),D(C=>{var R;x=ne(_,1,"label s-1r",null,x,C),he(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=A(u,2);{var b=y=>{var _=JS(),x=T(_,!0);S(_),D(()=>he(x,e.item.sublabel)),$(y,_)};V(v,y=>{e.item.sublabel&&y(b)})}S(d),S(o),D((y,_,x)=>{var I;r=ne(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=ne(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()}Je(["click","keydown"]);var iC=L('<li role="menuitem" tabindex="0" aria-haspopup="true"><!> <div><!></div></li>');function av(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(()=>_=>Ru(_,n(r)));var l=iC();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=_=>{gc(_,{})};V(s,_=>{e.item.selected&&_(u)})}var m=A(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,k)=>{k(R,ts(()=>{var P;return(P=e.item.valueComponentParams)!=null?P:{}}))}),$(_,x)},y=_=>{var x=gs();D(()=>he(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]}),D((_,x)=>{var I;d=ne(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=ne(m,1,"menu-item-value",null,p,x)},[()=>({mobile:t(),bottomBordered:e.item.bottomBordered}),()=>({"submenu-value-mobile":t()})]),$(i,l),H()}Je(["click","keydown"]);var os={"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 nC=(i,e)=>{z_(i,e.returnFromSubMenu,e.closeSettingsMenu)},rC=(i,e)=>{i.stopPropagation(),e.returnFromSubMenu()},sC=(i,e)=>{Nd(i)&&(Br(i),e.returnFromSubMenu())},aC=L('<div><ul role="menu"><li role="menuitem" tabindex="0" data-testid="return-to-settings-menu"><!> <p class="title s-1i"> </p></li> <!></ul></div>'),lC={hash:"s-1i",code:".sub-menu.s-1i{--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-1i .item.mobile{font-size:14px;line-height:var(--item-label-line-height);padding:var(--item-padding-vertical-mobile) 17px}.sub-menu.s-1i{padding-top:calc(var(--edge-item-padding-vertical) + var(--item-padding-vertical) + var(--item-label-line-height))}.sub-menu.mobile.s-1i{padding-top:calc(var(--edge-item-padding-vertical-mobile) + var(--item-padding-vertical-mobile) + var(--item-label-line-height) + 1px)}.sub-menu.s-1i .items:where(.s-1i) .item.header:where(.s-1i){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-1i .title:where(.s-1i){margin-left:8px}.sub-menu.s-1i .item{padding:var(--item-padding-vertical) 12px;padding-right:22px}.items.s-1i .item:first-child:not(.mobile){padding-top:var(--edge-item-padding-vertical)}.items.s-1i .item:last-child:not(.mobile){padding-bottom:var(--edge-item-padding-vertical)}.items.s-1i .item.mobile:first-child{padding-top:var(--edge-item-padding-vertical-mobile)}.items.s-1i .item.mobile:last-child{padding-bottom:var(--edge-item-padding-vertical-mobile)}.sub-menu.s-1i .item.bottomBordered{border-bottom:var(--divider-border)}.sub-menu.s-1i .item .sublabel{font-size:12px;line-height:14px}.item.s-1i:not(.mobile) p:where(.s-1i),.sub-menu.s-1i .item:not(.mobile) .label{font-size:13px;line-height:var(--item-label-line-height)}"};function dv(i,e){B(e,!0),Q(i,lC);let[t,o]=Be(),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);Vt(()=>{let G=e.items.findIndex(re=>re.selected);u().children[G+1].focus()});let m=xe(),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=aC();let R;var k=T(C);let P;k.__keydown=[nC,e];var E=T(k);let W;E.__click=[rC,e],E.__keydown=[sC,e];var F=T(E);Nr(F,{direction:"left"});var U=A(F,2),j=T(U,!0);S(U),S(E),it(E,G=>O(b,G),()=>n(b));var se=A(E,2);bi(se,17,()=>e.items,yd,(G,re)=>{var X=Oe(),Te=le(X);{var ue=be=>{sv(be,{get item(){return n(re)},get isMobile(){return l()}})},te=(be,Ce)=>{{var me=qe=>{av(qe,{get isMobile(){return l()},get item(){return n(re)},get openSubMenuList(){return e.openSubMenuList},get refMenuItems(){return e.refMenuItems}})};V(be,qe=>{n(re).type==="OPEN_SUB_MENU"&&qe(me)},Ce)}};V(Te,be=>{n(re).type==="SELECT_VALUE"?be(ue):be(te,!1)})}$(G,X)}),S(k),it(k,G=>u(G),()=>u()),S(C),D((G,re,X)=>{R=ne(C,1,"sub-menu menu s-1i",null,R,G),De(C,"data-testid",`${e.id}-sub-menu`),je(C,`min-width: ${n(I)}px`),P=ne(k,1,"items s-1i",null,P,re),je(k,n(x)),W=ne(E,1,"item header back s-1i",null,W,X),De(E,"aria-label",s()),he(j,e.title)},[()=>({desktop:!l(),mobile:l()}),()=>({mobile:l()}),()=>({mobile:l()})]),Sn(E,"clientWidth",G=>O(y,G)),Sn(E,"clientHeight",G=>O(_,G)),$(i,C),H(),o()}Je(["keydown","click"]);import{noop as dC}from"@vkontakte/videoplayer-shared/es2015";var cC=(i,e)=>Ru(i,e()),uC=(i,e)=>{i.stopPropagation(),e()()},pC=L('<div class="value s-1k"> </div>'),fC=L('<li role="menuitem" tabindex="0" aria-haspopup="true"><div class="icon-wrapper"><!></div> <div class="label"> </div> <!></li>'),mC={hash:"s-1k",code:".value.s-1k{opacity:.7;overflow:hidden;position:relative;text-overflow:ellipsis}"};function cv(i,e){B(e,!0),Q(i,mC);let t=h(e,"isMobile",3,!1),o=h(e,"onClick",3,dC),r=h(e,"valueComponent",3,void 0),a=h(e,"iconProps",19,()=>({})),l=h(e,"ref",15);var d=fC();let s;d.__click=[uC,o],d.__keydown=[cC,o];var u=T(d),m=T(u);{var p=C=>{Ga(C,{get icon(){return e.icon}})},v=C=>{var R=Oe();let k=f(()=>e.icon);var P=le(R);Hi(P,()=>n(k),(E,W)=>{W(E,ts(a))}),$(C,R)};V(m,C=>{typeof e.icon=="string"?C(p):C(v,!1)})}S(u);var b=A(u,2),y=T(b,!0);S(b);var _=A(b,2);{var x=C=>{var R=Oe();let k=f(r);var P=le(R);Hi(P,()=>n(k),(E,W)=>{W(E,{})}),$(C,R)},I=C=>{var R=pC(),k=T(R,!0);S(R),D(()=>he(k,e.value)),$(C,R)};V(_,C=>{r()?C(x):C(I,!1)})}S(d),it(d,C=>l(C),()=>l()),D(C=>{s=ne(d,1,"item",null,s,C),De(d,"aria-label",e.ariaLabel),De(d,"data-testid",e.id),he(y,e.label)},[()=>({mobile:t()})]),$(i,d),H()}Je(["click","keydown"]);import{noop as Lb}from"@vkontakte/videoplayer-shared/es2015";var vC=(i,e)=>{Dl(i,()=>e())},gC=L('<div class="icon icon-error-stub"><div class="inner"></div></div>'),hC=L('<img class="icon" aria-hidden="true"/>'),_C=L('<li role="menuitem" tabindex="0"><div class="icon-wrapper"><!></div> <div class="label s-1j"> </div></li>'),bC={hash:"s-1j",code:".label.s-1j{overflow:hidden;text-overflow:ellipsis}"};function uv(i,e){B(e,!0),Q(i,bC);let t=h(e,"isMobile",3,!1),o=h(e,"onClick",3,Lb),r=h(e,"closeSettings",3,Lb),a=K(!1),l=()=>{O(a,!0)},d=x=>{x==null||x.stopPropagation(),o()(),r()()};var s=_C();let u;s.__click=d,s.__keydown=[vC,d];var m=T(s),p=T(m);{var v=x=>{var I=Oe(),C=le(I);{var R=P=>{var E=gC();$(P,E)},k=P=>{var E=hC();D(()=>De(E,"src",e.icon)),ft("error",E,l),Va(E),$(P,E)};V(C,P=>{n(a)?P(R):P(k,!1)})}$(x,I)},b=x=>{var I=Oe();let C=f(()=>e.icon);var R=le(I);Hi(R,()=>n(C),(k,P)=>{P(k,{})}),$(x,I)};V(p,x=>{typeof e.icon=="string"?x(v):x(b,!1)})}S(m);var y=A(m,2),_=T(y,!0);S(y),S(s),D(x=>{var I;u=ne(s,1,"item",null,u,x),De(s,"aria-label",(I=e.ariaLabel)!=null?I:e.label),De(s,"data-testid",e.id),he(_,e.label)},[()=>({mobile:t()})]),$(i,s),H()}Je(["click","keydown"]);import{noop as xC}from"@vkontakte/videoplayer-shared/es2015";var $C=L('<div class="toggle_wrap s-1q"><div></div> <div class="toggle-label s-1q"></div></div>'),yC={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 pv(i,e){Q(i,yC);let t=h(e,"enabled",3,!1);var o=$C(),r=T(o);let a;ti(2),S(o),D(l=>a=ne(r,1,"toggle s-1q",null,a,l),[()=>({on:t()})]),$(i,o)}var wC=(i,e,t)=>{W_(i,e(),o=>t()(o))},SC=(i,e,t)=>{i.stopPropagation(),e()(!t())},CC=L('<div><div class="icon-wrapper"><!></div> <div class="label"> </div> <!></div>'),TC=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,xC),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=[SC,o,r],d.__keydown=[wC,r,o];var u=T(d);Wa(u,{get content(){return a()},get isMobile(){return t()},placement:"left",translateX:10,isFullWidthWrapper:!0,get maxTooltipWidth(){return l()},children:(m,p)=>{var v=CC();let b;var y=T(v),_=T(y);{var x=P=>{Ga(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,j)=>{j(U,{})}),$(P,E)};V(_,P=>{typeof e.icon=="string"?P(x):P(I,!1)})}S(y);var C=A(y,2),R=T(C,!0);S(C);var k=A(C,2);pv(k,{get enabled(){return r()}}),S(v),D(P=>{b=ne(v,1,"switch-wrapper",null,b,P),he(R,e.label)},[()=>({mobile:t()})]),$(m,v)},$$slots:{default:!0}}),S(d),D(m=>{var p;s=ne(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()}Je(["click","keydown"]);import{isValidURL as XC,VideoQuality as zb}from"@vkontakte/videoplayer-shared/es2015";var Mb=()=>{let i=K(ci([])),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)}}};import{getVideoQualityLabel as IC}from"@vkontakte/videoplayer-shared/es2015";var EC=L('<div class="quality-icon s-1o"><!></div>'),PC=L('<div class="quality-label s-1o"><span> </span> <!></div>'),AC={hash:"s-1o",code:".quality-label.s-1o{position:relative}.quality.s-1o{font-size:13px;line-height:18px}.quality.sub.s-1o{opacity:.7}.quality-icon.s-1o{display:flex;padding-left:2px;position:absolute;right:0;top:0;transform:translateX(100%)}.quality-icon.s-1o svg{color:var(--blue-light)}"};function tl(i,e){B(e,!0),Q(i,AC);let t=h(e,"isSubCase",3,!1),o=f(()=>e.quality?IC(e.quality):""),r=f(()=>Fu(e.quality));var a=PC(),l=T(a);let d;var s=T(l,!0);S(l);var u=A(l,2);{var m=p=>{var v=EC();let b=f(()=>n(r));var y=T(v);Hi(y,()=>n(b),(_,x)=>{x(_,{})}),S(v),D(()=>De(v,"data-testid",`${n(o)}-icon`)),$(p,v)};V(u,p=>{n(r)&&!e.isMobile&&p(m)})}S(a),D(p=>{d=ne(l,1,"s-1o",null,d,p),he(s,e.label)},[()=>({sub:!t(),quality:!e.isMobile})]),$(i,a),H()}import{VideoQuality as kC}from"@vkontakte/videoplayer-shared/es2015";import{VideoQuality as Vb}from"@vkontakte/videoplayer-core/es2015";var Rb=({quality:i,availableQualities:e})=>{let t=e.find(o=>o.value===i);return t?t.displayValue:i},Ob=({quality:i,availableQualities:e,isAutoQualityEnabled:t})=>{if(!i)return"...";let o=Rb({quality:i,availableQualities:e});return t?i===Vb.INVARIANT?Y("auto_quality_invariant"):Y("auto_quality",{actual:o}):o},Db=({quality:i,availableQualities:e,prefix:t,onlyPrefix:o})=>i?o||i===Vb.INVARIANT?t:`${t}${Rb({quality:i,availableQualities:e})}`:"...";var LC=L('<div class="menu-item-value-wrapper s-1t"><!></div>'),MC={hash:"s-1t",code:".menu-item-value-wrapper.s-1t{line-height:normal}"};function Gl(i,e){B(e,!0),Q(i,MC);let[t,o]=Be(),r=()=>w(s,"$currentQuality$",t),a=()=>w(u,"$availableQualities$",t),l=()=>w(m,"$isMobile$",t),d=xe(),s=d.state.currentQuality$,u=d.state.availableQualities$,m=d.ui.isMobile,p=" · ",v=f(()=>e.prefix+(e.selected&&r()!==kC.INVARIANT?p:"")),b=f(()=>Db({prefix:n(v),quality:r(),availableQualities:a(),onlyPrefix:!e.selected}));var y=LC(),_=T(y);let x=f(()=>e.selected?r():void 0);tl(_,{get quality(){return n(x)},get label(){return n(b)},get isMobile(){return l()},isSubCase:!0}),S(y),$(i,y),H(),o()}var VC=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")},RC={br:!0,span:!0},mv=(i,e={})=>{var d,s,u,m,p,v,b;if(!i)return i;let t=Me(Me({},RC),e),o=Object.keys(t);if(!o.length)return i;let r=VC(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?mv(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 hc(i,e){B(e,!1);let t=h(e,"message",8),o=mv(t());Yo();var r=Oe(),a=le(r);{var l=d=>{var s=Oe(),u=le(s);xd(u,()=>o),$(d,s)};V(a,d=>{o&&d(l)})}$(i,r),H()}var OC=L('<p class="quality-applies sublabel s-1s"><!></p>'),DC={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 vv(i,e){B(e,!1),Q(i,DC),Yo();var t=OC(),o=T(t);let r=lr(()=>Y("quality_applience",{action:`<span>${Y("quality_applience_action")}</span>`}));hc(o,{get message(){return n(r)}}),S(t),$(i,t),H()}var Bb=({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:Gl,valueComponentParams:{prefix:Y("other_quality"),selected:o},children:"quality-other-settings"}},gv=({appliesTo:i,labelWithQuality:e,selected:t},{selectQuality:o})=>({id:"quality-auto",type:"SELECT_VALUE",value:"auto",label:Y("auto_quality_limit"),valueComponent:e?Gl:void 0,valueComponentParams:{prefix:Y("auto_quality_limit"),selected:t},selectItem:()=>o("auto",i),selected:t}),Hb=()=>({id:"quality-appliance-settings",type:"OPEN_SUB_MENU",valueComponent:vv,bottomBordered:!0,children:"quality-appliance"}),hv=({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?Gl:void 0,valueComponentParams:{prefix:Y("high_quality"),selected:t},sublabel:Y("high_quality_description")}),_v=({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?Gl:void 0,valueComponentParams:{prefix:Y("traffic_saving_quality"),selected:t},sublabel:Y("traffic_saving_quality_description")});var np=(i,e)=>String(e.findIndex(t=>t.id===i.id)+1),rp=(i,e)=>{var l;if(!i)return"";let{language:t,label:o}=i,r;if(t==="und"?r=void 0:t&&(r=(l=Jd(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=np(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=np(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=np(i,d);return Y("audio_stream_display_language_index",{language:r,index:s})}}let a=np(i,e);return Y("audio_stream_display_unknown",{index:a})};var NC={"quality-settings":i=>{let{isAutoQualityEnabled:e,isAutoQualityAvailable:t,trafficSavingEnabled:o,highQualityEnabled:r}=i,a=[];return t&&a.push({handler:gv,selected:e&&!o&&!r||!1}),a.push({handler:_v,selected:o},{handler:hv,selected:r}),{title:Y("submenu_quality"),id:"quality-settings",items:[Hb(i),...a.map(({handler:l,selected:d})=>l({labelWithQuality:!0,appliesTo:"to-video",selected:d},i)),Bb(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:tl,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:gv,selected:((t=wu())==null?void 0:t.type)==="auto_quality"},{handler:_v,selected:((o=wu())==null?void 0:o.type)==="traffic_saving"},{handler:hv,selected:((r=wu())==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:rp(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===In?"sub_off":void 0}))})},Fb=({subMenuId:i,context:e})=>i?[NC[i](e)]:[];var BC=Pe('<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 bv(i){Ze(i,{testId:"traffic-saving-icon",children:(e,t)=>{var o=BC();$(e,o)},$$slots:{default:!0}})}var HC=Pe('<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 $v(i){Ze(i,{width:"18",height:"15",children:(e,t)=>{var o=HC();$(e,o)},$$slots:{default:!0}})}var FC=Pe('<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 yv(i){Ze(i,{testId:"play-speed-icon",children:(e,t)=>{var o=FC();$(e,o)},$$slots:{default:!0}})}var UC=Pe('<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=UC();$(e,o)},$$slots:{default:!0}})}var zC=Pe('<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 wv(i){Ze(i,{testId:"report-icon",children:(e,t)=>{var o=zC();$(e,o)},$$slots:{default:!0}})}var WC=Pe('<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 sp(i){Ze(i,{children:(e,t)=>{var o=WC();$(e,o)},$$slots:{default:!0}})}var KC=Pe('<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 Sv(i){Ze(i,{testId:"info-icon",children:(e,t)=>{var o=KC();$(e,o)},$$slots:{default:!0}})}var qC=L('<div class="menu-item-value-wrapper s-1u"><!></div>'),QC={hash:"s-1u",code:".menu-item-value-wrapper.s-1u{line-height:normal}"};function Cv(i,e){B(e,!0),Q(i,QC);let[t,o]=Be(),r=()=>w(u,"$currentQuality$",t),a=()=>w(m,"$availableQualities$",t),l=()=>w(p,"$isAutoQualityEnabled$",t),d=()=>w(v,"$isMobile$",t),s=xe(),u=s.state.currentQuality$,m=s.state.availableQualities$,p=s.state.isAutoQualityEnabled$,v=s.ui.isMobile,b=f(()=>Ob({quality:r(),availableQualities:a(),isAutoQualityEnabled:l()}));var y=qC(),_=T(y);tl(_,{get quality(){return r()},get label(){return n(b)},get isMobile(){return d()}}),S(y),$(i,y),H(),o()}var YC={"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:Kd,label:Y("menu_quality"),value:e,valueComponent:Cv,weight:os["quality-settings"],children:t?"quality-settings":"quality-other-settings"}},"traffic-saving-switch":({trafficSavingEnabled:i,toggleTrafficSaving:e})=>({id:"traffic-saving-switch",weight:os["traffic-saving-settings"],type:"SWITCH",onClick:t=>e(t,"to-video"),ariaLabel:Y("aria_label_submenu_traffic_saving"),icon:bv,label:Y("menu_traffic_saving"),enabled:i,tooltipText:Y("traffic_saving_helper_text"),maxTooltipWidth:175}),"audio-tracks-settings":({currentAudioStream:i,availableAudioStreams:e})=>{let t=rp(i,e);return{id:"audio-tracks-settings",weight:os["audio-language-settings"],type:"OPEN_SUB_MENU",ariaLabel:Y("aria_label_menu_audio_languages",{actual:t}),icon:$v,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:os["playback-rate-settings"],type:"OPEN_SUB_MENU",ariaLabel:Y("aria_label_menu_rate",{actual:t}),icon:yv,label:Y("menu_playback_rate"),value:`${e}x`,children:"playback-rate"}},"subtitles-settings":({currentSubtitle:i})=>({id:"subtitles-settings",weight:os["subtitles-settings"],type:"OPEN_SUB_MENU",ariaLabel:Y("aria_label_menu_subtitle",{actual:i.displayValue}),icon:ua,iconProps:{type:"outline"},label:Y("subtitles_caption"),value:i.displayValue,children:"subtitles"}),download:({onDownloadClick:i})=>({id:"download",weight:os.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:os.report,type:"CLICK",onClick:i,label:Y("menu_report"),ariaLabel:`${Y("menu_report")}. ${Y("aria_label_new_tab_alert")}`,icon:wv,isHiddenFor:["desktop"]}),"copy-data":({onCopyDataClick:i})=>({id:"copy-data",weight:os["copy-data"],type:"CLICK",onClick:i,label:Y("menu_copy_debug"),ariaLabel:Y("menu_copy_debug"),icon:sp,isHiddenFor:["desktop"]}),"save-trace-info":({onSaveTraceDataClick:i})=>({id:"save-trace-info",weight:os["save-trace-info"],type:"CLICK",onClick:i,label:Y("menu_save_debug"),ariaLabel:Y("menu_save_debug"),icon:sp,isHiddenFor:["desktop"]}),"debug-info":({toggleShowDebugInfo:i})=>({id:"debug-info",weight:os["debug-info"],type:"CLICK",onClick:i,ariaLabel:Y("aria_label_menu_debug_overlay"),label:Y("menu_debug_overlay"),icon:Sv,isHiddenFor:["desktop"]})},Ub=({items:i,context:e,additionalSettingsMenuItems:t})=>{let{isMobile:o}=e;return[...i.map(r=>YC[r](e)),...t.map(r=>Qt(Me({},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(Fa)};var ZC=(i,e)=>{Vu(i,e)},JC=L('<div><div> </div> <div class="close s-r" data-testid="close-settings-menu"></div></div>'),eT=L('<div data-testid="settings-menu" role="presentation"><!> <ul role="menu"></ul></div>'),tT=L("<div><!> <!></div>"),iT={hash:"s-r",code:'.settings-menu-container.mobile.s-r{width:100%;-webkit-touch-callout:none;-webkit-user-select:none;user-select:none}.settings-menu-container.s-r ul{list-style-type:none;margin:0;padding:0}.settings-menu-container.s-r .menu{background-color:var(--settings-bg);border-radius:var(--settings-radius);overflow:hidden;transition:opacity .2s,visibility .2s}.settings-menu-container.s-r .menu .item:first-child:not(.mobile){border-top-left-radius:var(--settings-radius);border-top-right-radius:var(--settings-radius)}.settings-menu-container.s-r .menu .item:last-child{border-bottom-left-radius:var(--settings-radius);border-bottom-right-radius:var(--settings-radius)}.settings-menu-container.s-r .settings-menu .item:first-child:not(.mobile){padding-top:6px}.settings-menu-container.s-r .settings-menu .item:last-child:not(.mobile){padding-bottom:6px}.settings-menu-container.s-r .menu.desktop{bottom:0;max-width:100%;position:absolute;right:0}.settings-menu.s-r{line-height:40px}.settings-menu.desktop.s-r{min-width:300px}.settings-menu-container.s-r .menu.mobile{background:var(--mobile-settings-bg);font-size:15px;line-height:50px;width:100%}.settings-menu-container.s-r .menu.mobile.hidden{display:none}.settings-menu-container.s-r .menu .item:not(.switch-item),.settings-menu-container.s-r .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-r .menu .item:hover{background-color:var(--settings-item-bg-hover)}.settings-menu-container.s-r .menu .item.mobile:hover{background:var(--mobile-settings-bg)}.settings-menu.s-r .item:not(.switch-item),.settings-menu.s-r .switch-wrapper{padding:0 32px 0 18px}.settings-menu.s-r .item.mobile:not(.switch-item),.settings-menu.s-r .switch-wrapper.mobile{padding:0 14px}.settings-menu.s-r .icon-wrapper{align-items:center;display:flex;height:24px;justify-content:center;margin-right:16px;min-width:24px;width:24px}.settings-menu.s-r .label{flex-grow:1;margin-right:24px;overflow:hidden;text-overflow:ellipsis}.settings-menu.s-r .item.header.mobile:where(.s-r){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-r .items::-webkit-scrollbar{width:8px}.settings-menu-container.s-r .items::-webkit-scrollbar-track{background-color:#3a3a3a;border-radius:4px;box-shadow:none}.settings-menu-container.s-r .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-r .items::-webkit-scrollbar-thumb:hover{background-color:#777}.settings-menu-container.s-r .items.mobile{max-height:160px;overflow-x:hidden;overflow-y:auto;text-align:left}.close.s-r{height:12px;margin-right:-12px;padding:12px;position:relative;width:12px}.close.s-r:after,.close.s-r:before{background-color:var(--white);content:" ";height:12px;left:18px;position:absolute;width:2px}.close.s-r:before{transform:rotate(45deg)}.close.s-r:after{transform:rotate(-45deg)}'};function _c(i,e){B(e,!0),Q(i,iT);let[t,o]=Be(),r=()=>w(ge,"$settingsMenuVisible",t),a=()=>w(ze,"$settingsMenuOpenedByKeyboard",t),l=()=>w(Ne,"$debugPanelVisible",t),d=()=>w(We,"$isMobile",t),s=()=>w(Ae,"$playerSize",t),u=()=>w(_e,"$hasMpegSources$",t),m=()=>w(ee,"$mobileNotReportControlHidden$",t),p=()=>w(me,"$autoQualityLimitingAvailable$",t),v=()=>w(ce,"$availableSubtitlesList$",t),b=()=>w(ke,"$isLiveWithPlaybackSpeed",t),y=()=>w(te,"$availableAudioStreams$",t),_=()=>w(Z,"$availablePlaybackRates$",t),x=()=>w(ue,"$currentAudioStream$",t),I=()=>w(pe,"$currentPlaybackRate$",t),C=()=>w(Ue,"$trafficSavingEnabled",t),R=()=>w(be,"$currentQuality$",t),k=()=>w(qe,"$isAutoQualityEnabled$",t),P=()=>w(N,"$currentSubtitle$",t),E=()=>w(It,"$additionalSettingsMenuItems$",t),W=()=>w(ve,"$isAutoQualityAvailable$",t),F=()=>w(Ce,"$availableQualities$",t),U=()=>w(Ie,"$highQualityEnabled",t),j=h(e,"ref",15,void 0),se=h(e,"playerControlsHeight",3,0),G=ci({}),re=ci({}),X=xe(),Te=Rt(),ue=X.state.audioStream$,te=X.state.availableAudioStreams$,be=X.state.currentQuality$,Ce=X.state.availableQualities$,me=X.state.autoQualityLimitingAvailable$,qe=X.state.isAutoQualityEnabled$,ve=X.state.isAutoQualityAvailable$,pe=X.state.currentPlaybackRate$,Z=X.state.availablePlaybackRates$,N=X.state.currentSubtitle$,ce=X.state.availableSubtitlesList$,de=X.state.canDownload,_e=X.state.hasMpegSources$,ge=X.ui.settingsMenu.visible$,ze=X.ui.settingsMenu.openedByBtnKeyboard$,ie=X.ui.settingsMenu.ref$,We=X.ui.isMobile,ee=X.ui.mobileNotReportControlHidden$,ke=X.state.canChangePlaybackSpeed$,Ue=X.state.trafficSavingEnabled$,Ie=X.state.highQualityEnabled$,Ae=X.ui.playerSize,Ne=X.ui.debugPanelVisible,gt=X.state.isInteractiveTime$,It=X.ui.additionalSettingsMenuItems$,Lt=X.ui.t,lt=X.actions.internal.downloadVideo,Et=X.actions.internal.closeSettingsMenu,jt=X.actions.internal.openSettingsSubMenu,zt=X.actions.internal.closeSettingsSubMenu,Ot=K(!1),Wt=K(void 0),q=Mb();He(()=>{!r()&&q.current&&(zt(re[q.current]),q.popAllSubMenus())}),He(()=>{r()||O(Wt,void 0)}),He(()=>{!q.current&&n(Wt)&&U_(G,n(Wt))}),He(()=>{j()&&ie.set(j())});function Le(xt){return ht(this,null,function*(){var z;q.pushSubMenu(xt),yield ho(),jt(xt,re[xt]);let Bt=(z=j())==null?void 0:z.firstElementChild;Bt&&qf(Bt)})}function Re(xt){var Bt;xt==null||xt.stopPropagation(),a()||(Bt=e.returnFocus)==null||Bt.call(e),Et(),O(Ot,!1)}function we(xt,Bt){X.actions.internal.setQuality(xt,{appliesTo:Bt,byUser:!0}),Re()}function Ke(xt){X.actions.internal.setAudioStream(xt),Re()}function Se(xt,Bt){X.actions.internal.setTrafficSavingEnabled(xt,Bt),Te.features.qualityDetailsSubMenuEnabled&&Re()}function yt(xt,Bt){X.actions.internal.setHighQualityEnabled(xt,Bt),Re()}function ye(xt){X.actions.internal.setPlaybackRate(xt),Re()}function Fe(xt){X.actions.internal.setSubtitle(xt),Re()}function Qe(){lt()}function rt(){XC(e.supportLink)&&window.open(e.supportLink,"_blank"),X.actions.internal.reportProblem(),X.actions.internal.pause()}function Kt(){Rl(X.actions.internal.getDebugTextData())}let Nt=()=>{let xt=X.actions.internal.getTraceTextData(),Bt=new Blob([...xt],{type:"application/json"}),z=window.URL.createObjectURL(Bt);Na(z,"vk_player_trace_info","json")};function ai(){Ne.set(!l())}function $i(){O(Ot,!0)}function gi(){O(Ot,!1)}function ro(){return d()?`max-height: ${Math.round(s().height*.6)}px`:`max-height: ${s().height-32-se()}px; overflow: auto;`}let so=f(()=>de&&u()&&!m()),pi=f(()=>Te.features.trafficSaving&&!m()&&p()&&!Te.features.qualityDetailsSubMenuEnabled),at=f(()=>v().length>0&&!m()),ui=f(()=>!!b()&&!m()),ao=f(()=>Te.features.audioLanguages&&y().length>=2&&!m()),St=f(()=>!m());Vt(()=>gt.subscribe(xt=>{xt&&!d()&&!n(Ot)&&!a()&&Re()}));let Ct=f(()=>{let xt=[n(St)&&"quality-settings",n(ao)&&"audio-tracks-settings",n(ui)&&"playback-rate-settings",n(at)&&"subtitles-settings",n(pi)&&"traffic-saving-switch",n(so)&&"download",Te.showSupport&&"show-support","copy-data",Te.features.saveTraceInfoToFile&&"save-trace-info","debug-info"].filter(Bt=>!!Bt);return Ub({items:xt,context:{qualityDetailsSubMenuEnabled:Te.features.qualityDetailsSubMenuEnabled,availablePlaybackRates:_(),currentAudioStream:x(),availableAudioStreams:y(),currentPlaybackRate:I(),selectPlaybackRate:ye,trafficSavingEnabled:C(),toggleTrafficSaving:Se,currentQuality:R()||zb.INVARIANT,isAutoQualityEnabled:k()||!1,currentSubtitle:P(),isMobile:d(),onDownloadClick:Qe,onCopyDataClick:Kt,onReportProblemClick:rt,onSaveTraceDataClick:Nt,toggleShowDebugInfo:ai},additionalSettingsMenuItems:E()})}),Si=f(()=>Fb({subMenuId:q.current,context:{availablePlaybackRates:_(),selectPlaybackRate:ye,trafficSavingEnabled:C(),toggleTrafficSaving:Se,currentQuality:R()||zb.INVARIANT,isAutoQualityEnabled:k()||!1,isAutoQualityAvailable:W()||!1,availableQualities:F(),highQualityEnabled:U(),toggleHighQuality:yt,availableAudioStreams:y(),availableSubtitlesList:v(),closeSettingsMenu:Et,currentAudioStream:x(),isMobile:d(),selectAudioLanguage:Ke,selectQuality:we,selectSubtitle:Fe}}));var nt=tT();let st;var Ei=T(nt);{var Vo=xt=>{var Bt=eT();let z;Bt.__keydown=[ZC,Et];var Mt=T(Bt);{var ct=wt=>{var dt=JC();let Ui;var Pi=T(dt),En=T(Pi,!0);S(Pi);var Pn=A(Pi,2);Pn.__click=Re,S(dt),D((Ci,lo)=>{Ui=ne(dt,1,"item header s-r",null,Ui,Ci),he(En,lo)},[()=>({mobile:d()}),()=>Lt("submenu_settings")]),$(wt,dt)};V(Mt,wt=>{d()&&wt(ct)})}var _i=A(Mt,2);let Zt;bi(_i,21,()=>n(Ct),wt=>wt.id,(wt,dt)=>{var Ui=Oe(),Pi=le(Ui);{var En=Ci=>{cv(Ci,{get isMobile(){return d()},get id(){return n(dt).id},get icon(){return n(dt).icon},get iconProps(){return n(dt).iconProps},get label(){return n(dt).label},get ariaLabel(){return n(dt).ariaLabel},get value(){return n(dt).value},get valueComponent(){return n(dt).valueComponent},onClick:()=>{Le(n(dt).children),O(Wt,n(dt).id,!0)},get ref(){return G[n(dt).id]},set ref(lo){G[n(dt).id]=lo}})},Pn=(Ci,lo)=>{{var fr=yi=>{let Ro=f(()=>`${n(dt).id}-menu-item`);uv(yi,{get isMobile(){return d()},get id(){return n(Ro)},get onClick(){return n(dt).onClick},get icon(){return n(dt).icon},get label(){return n(dt).label},get ariaLabel(){return n(dt).ariaLabel},closeSettings:Re})},Zi=(yi,Ro)=>{{var Zo=_o=>{let mn=f(()=>`${n(dt).id}-menu-item`);fv(_o,{get isMobile(){return d()},get id(){return n(mn)},get onClick(){return n(dt).onClick},get icon(){return n(dt).icon},get label(){return n(dt).label},get ariaLabel(){return n(dt).ariaLabel},get enabled(){return n(dt).enabled},get tooltipText(){return n(dt).tooltipText},get maxTooltipWidth(){return n(dt).maxTooltipWidth}})};V(yi,_o=>{n(dt).type==="SWITCH"&&_o(Zo)},Ro)}};V(Ci,yi=>{n(dt).type==="CLICK"?yi(fr):yi(Zi,!1)},lo)}};V(Pi,Ci=>{n(dt).type==="OPEN_SUB_MENU"?Ci(En):Ci(Pn,!1)})}$(wt,Ui)}),S(_i),it(_i,wt=>j(wt),()=>j()),S(Bt),D((wt,dt,Ui)=>{z=ne(Bt,1,"settings-menu menu s-r",null,z,wt),Zt=ne(_i,1,"items",null,Zt,dt),je(_i,Ui)},[()=>({desktop:!d(),mobile:d(),hidden:!!q.current}),()=>({mobile:d()}),ro]),ft("mouseenter",Bt,$i),ft("mouseleave",Bt,gi),$(xt,Bt)};V(Ei,xt=>{r()&&xt(Vo)})}var Xo=A(Ei,2);bi(Xo,17,()=>n(Si),xt=>xt.id,(xt,Bt)=>{let z=f(()=>{var Mt;return(Mt=n(Bt).minWidth)!=null?Mt:137});dv(xt,{get isMobile(){return d()},get playerControlsHeight(){return se()},get returnFromSubMenu(){return q.popSubMenu},get id(){return n(Bt).id},get title(){return n(Bt).title},get closeSettingsMenu(){return Et},openSubMenuList:Le,get items(){return n(Bt).items},get minWidth(){return n(z)},get refMenuItems(){return G},get listRef(){return re[n(Bt).id]},set listRef(Mt){re[n(Bt).id]=Mt}})}),S(nt),D(xt=>st=ne(nt,1,"settings-menu-container s-r",null,st,xt),[()=>({mobile:d(),hidden:!r()})]),$(i,nt),H(),o()}Je(["keydown","click"]);var oT=L('<button class="btn s-1e"> </button>'),nT={hash:"s-1e",code:"button.btn.s-1e{background:hsla(0,0%,100%,.1);border-radius:8px;font-size:14px;line-height:18px;margin-top:12px;padding:6px 12px 7px}"};function Tv(i,e){Q(i,nT);var t=oT();t.__click=function(...r){var a;(a=e.onClick)==null||a.apply(this,r)};var o=T(t,!0);S(t),D(()=>he(o,e.label)),$(i,t)}Je(["click"]);var rT=L('<div class="container s-s"><div class="notification s-s"><div><p class="description s-s"><!></p> <!></div> <!></div></div>'),sT={hash:"s-s",code:".container.s-s{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-s{background:var(--notification-bg);border-radius:var(--notification-radius);display:inline-flex;gap:10px;padding:9px 14px 10px 12px;pointer-events:auto}.description.s-s{font-size:13px;line-height:16px;margin:0;white-space:pre}"};function bc(i,e){B(e,!0),Q(i,sT);let t=340,{features:{forceAutoQualityWhenSevereStallHappens:o}}=Rt(),{ui:{t:r}}=xe(),a=r(o?"slow_video_notification_force_description":"slow_video_notification_suggest_description");var l=rT(),d=T(l),s=T(d),u=T(s),m=T(u);hc(m,{get message(){return a}}),S(u);var p=A(u,2);{var v=y=>{let _=f(()=>r("slow_video_notification_button"));Tv(y,{get label(){return n(_)},get onClick(){return e.onSelectAutoQuality}})};V(p,y=>{o||y(v)})}S(s);var b=A(s,2);Ds(b,{get onClick(){return e.onClose}}),S(d),S(l),Rs(3,d,()=>ma,()=>({duration:t})),$(i,l),H()}import{isIntersecting as Wb,Subscription as aT}from"@vkontakte/videoplayer-shared/es2015";var il="annotation",ap=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",il),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=Hs(d,this.shadowRootContainer);o.forEach(_=>{let x=s==null?void 0:s[_],I=x?$e(x):null,C=u==null?void 0:u[_];I&&(C==null||C.set(Wb(I,y)))})}));m.observe(d,{childList:!0,subtree:!0}),l.observer=m;let p=new aT;o.forEach(b=>{s&&p.add(s[b].subscribe(y=>{let _=u==null?void 0:u[b];y&&y.isDisplayed?_==null||_.set(Wb(y,Hs(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 lT=L('<div class="container s-5"><!></div>'),dT={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 $c(i,e){B(e,!0),Q(i,dT);let t=h(e,"reversed",3,!1);var o=Oe(),r=le(o);Ls(r,()=>e.Icon,a=>{var l=lT(),d=T(l);Hi(d,()=>e.Icon,(s,u)=>{u(s,{get size(){return"48"},get reversed(){return t()}})}),S(l),D(()=>je(l,`animation-duration: ${e.duration}ms`)),$(a,l)}),$(i,o),H()}import{PlaybackState as Kb}from"@vkontakte/videoplayer-core/es2015";var cT=L('<div class="container s-z"><!></div>'),uT={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 Iv(i,e){B(e,!0),Q(i,uT);let[t,o]=Be(),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}}=xe(),{features:{playbackStatusShow:v},playbackStatusAnimationDuration:b}=Rt(),y=0,_=K(null),x=K(!1);He(()=>{r()===Kb.PLAYING?O(_,Tn,!0):r()===Kb.PAUSED?O(_,zs,!0):O(_,null)}),He(()=>{if(!(!v||a()||l()))return y=window.setTimeout(()=>{y=0,O(_,null)},b),()=>{y&&(window.clearTimeout(y),y=0)}}),He(()=>{d()&&!n(x)&&(O(x,!0),O(_,null))});var I=Oe(),C=le(I);{var R=k=>{var P=cT(),E=T(P);$c(E,{get duration(){return b},get Icon(){return n(_)}}),S(P),$(k,P)};V(C,k=>{n(_)&&v&&k(R)})}$(i,I),H(),o()}var pT=L('<div><div data-testid="video-container"></div></div>'),fT={hash:"s-b",code:".video-container.s-b,.video-wrapper.s-b{height:100%;left:0;position:absolute;top:0;width:100%}.video-wrapper.s-b{background:var(--black)}.video-container.s-b,.video-wrapper.s-b{z-index:var(--video-container-z-index)}.video-container.s-b{transition:var(--rotate-transition-duration) ease all}.video-container.fast-rotate.s-b{transition:none}.nocursor.s-b{cursor:none}"};function ol(i,e){B(e,!0),Q(i,fT);let[t,o]=Be(),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}}=xe(),{isSmoothVideoRotate:_}=Rt(),x=f(()=>u()&&r()%180?a().height/a().width:1);var I=pT();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 k;it(R,P=>u(P),()=>u()),S(I),D((P,E)=>{C=ne(I,1,"video-wrapper s-b",null,C,P),k=ne(R,1,"video-container s-b",null,k,E),je(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()}Je(["contextmenu","mousedown","mouseup","click","dblclick"]);var mT=L('<div><span class="text s-10"> </span> <!></div>'),vT={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 Ev(i,e){B(e,!0),Q(i,vT);let{ui:{t}}=xe();var o=mT();let r;var a=T(o),l=T(a,!0);S(a);var d=A(a,2);pc(d,{get size(){return"16"},fill:"currentColor"}),S(o),D((s,u)=>{r=ne(o,1,"root s-10",null,r,s),he(l,u)},[()=>({visible:e.isVisible}),()=>t("double_forward_label")]),$(i,o),H()}var gT=L('<div class="container s-12" role="button" data-testid="preview-track-overlay"><div class="icon s-12"><!></div></div>'),hT={hash:"s-12",code:".container.s-12{background-color:rgba(0,0,0,.48);cursor:pointer;height:100%;position:absolute;width:100%}.container.s-12,.icon.s-12{align-items:center;display:flex;justify-content:center}.icon.s-12{background-color:#00000073;border-radius:100%;height:64px;transition:transform .2s;transition-timing-function:ease-out;width:64px;will-change:transform}.container.s-12:hover .icon:where(.s-12){transform:scale(1.15)}"};function Pv(i,e){B(e,!1),Q(i,hT);let o=xe().actions.internal.closePreviewTrack,r=200,a=u=>{u.stopPropagation(),o()};Yo();var l=gT();l.__click=a;var d=T(l),s=T(d);return Tn(s,{get size(){return"32"}}),S(d),S(l),Rs(3,l,()=>ma,()=>({duration:r})),$(i,l),_f(e,"handleClick",a),H({handleClick:a})}Je(["click"]);var _T=(i,e,t,o,r,a)=>{if(i.stopPropagation(),e()||o()){a();return}},bT=L("<div><!></div>"),$T=L('<div class="spherical-video-icon s-8"><!></div>'),yT=L("<div><!></div>"),xT=L('<div class="settings-menu s-8"><!></div>'),wT=L("<!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!>",1),ST=L("<!> <!> <!>",1),CT=L('<div class="blocked s-8"></div>'),TT=L('<div class="player-wrapper s-8"><!> <div class="overlay-container"></div></div> <!>',1),IT={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 Av(i,e){B(e,!0),Q(i,IT);let[t,o]=Be(),r=()=>w(xr,"$notificationsToShow$",t),a=()=>w(pi,"$playerPhase",t),l=()=>w(Vo,"$isLoaderVisible",t),d=()=>w(gi,"$adPlaybackState",t),s=()=>w(_i,"$crashed",t),u=()=>w(fr,"$isInteractiveTime$",t),m=()=>w(St,"$settingsMenuVisible",t),p=()=>w(Zi,"$isInteractiveExpectation$",t),v=()=>w(ao,"$controlsVisible",t),b=()=>w(Ro,"$touched",t),y=()=>w(br,"$graphIsOpened$",t),_=()=>w(at,"$isFullscreen",t),x=()=>w(zr,"$autoplayNextEnabled$",t),I=()=>w(z,"$postrollPassed",t),C=()=>w(Xo,"$isEnded$",t),R=()=>w(Wr,"$cursorInside",t),k=()=>w(An,"$isControlsAvailable",t),P=()=>w(gr,"$doubleForwardOn$",t),E=()=>w(kn,"$fakeIsPlaying$",t),W=()=>w(tn,"$bottomNoSmooth",t),F=()=>w(Fr,"$interactiveTimeIndicator",t),U=()=>w(Pi,"$playerSize",t),j=()=>w(Pn,"$is3DVideo",t),se=()=>w(ns,"$doubleForwardAvailable$",t),G=()=>w(st,"$contextMenuVisible$",t),re=()=>w($i,"$playbackState$",t),X=()=>w(Zo,"$hotKeyMapData",t),Te=()=>w(Si,"$scrubbingInProgress",t),ue=()=>w(nt,"$volumeChangingInProgress",t),te=()=>w(xt,"$chromecastConnected$",t),be=()=>w(on,"$controlsTimeoutActive",t),Ce=()=>w(En,"$adsPlaybackState",t),me=()=>w(Ct,"$settingsMenuOpenedByKeyboard",t),qe=()=>w(yo,"$contextMenuOpenedByKeyboard$",t),ve=()=>w(Ho,"$contextMenuOpenedByHotKey$",t),pe=()=>w(an,"$contextMenuButtonRef$",t),Z=()=>w(tr,"$contextMenuLastActiveElem$",t),N=()=>w(ui,"$isFullscreenOpenedByKeyboard",t),ce=()=>w(mn,"$positionExact$",t),de=()=>w(ai,"$language$",t),_e=()=>w(qs,"$previewTrackActive$",t),ge=()=>w(Ci,"$icon3DVideoVisible",t),ze=()=>w(Bt,"$chromecastDeviceName$",t),ie=()=>w(dt,"$currentSubtitle$",t),We=()=>w(Ui,"$currentSubtitleCaptions$",t),ee=()=>w(ro,"$position$",t),ke=()=>w(so,"$duration$",t),Ue=()=>w(Mt,"$isLive$",t),Ie=()=>w(ct,"$isPlaying$",t),Ae=()=>w(mr,"$contextMenuPosition$",t),Ne=()=>w(_o,"$showHotKeyMap",t),gt=()=>w(Ei,"$debugPanelVisible",t),It=()=>w(Jo,"$userActionsDisabled$",t),Lt=h(e,"videoContainer",15),lt=h(e,"adsSlotId",3,void 0),Et=h(e,"adsParams",3,void 0),jt=h(e,"adsAutoplayParam",3,void 0),zt=h(e,"duration",3,void 0),Ot=h(e,"logoTargetUrl",3,""),Wt=h(e,"showNextPrevButtons",3,!1),q=h(e,"nextButtonActive",3,!1),Le=h(e,"prevButtonActive",3,!1),Re=h(e,"endScreenVideoTitle",3,void 0),we=h(e,"endScreenVideoThumb",3,void 0),Ke=h(e,"isOneVideoPlaylist",3,!1),Se=h(e,"shadowRootContainer",3,void 0),yt=h(e,"outerContainerRef",3,void 0),ye=h(e,"playerStarted",3,!1),Fe=h(e,"fullScreenTarget",3,void 0),Qe=h(e,"showMiniTimer",3,!1),rt=h(e,"showEndScreen",3,!0),Kt=h(e,"keyboardControls",15),Nt=e.store.getLogger().createComponentLog("Root component"),ai=e.store.interfaceLanguage$,$i=e.store.state.playbackState$,gi=e.store.ads.playbackState,ro=e.store.state.positionWithScrubbing$,so=e.store.state.duration$,pi=e.store.playerPhase,at=e.store.ui.isFullscreen,ui=e.store.ui.isFullscreenOpenedByKeyboard,ao=e.store.ui.controlsVisible,St=e.store.ui.settingsMenu.visible$,Ct=e.store.ui.settingsMenu.openedByBtnKeyboard$,Si=e.store.ui.scrubbingInProgress,nt=e.store.ui.volumeChangingInProgress,st=e.store.ui.contextMenu.visible$,Ei=e.store.ui.debugPanelVisible,Vo=e.store.state.isLoaderVisible,Xo=e.store.state.isEnded$,xt=e.store.state.chromecastConnected$,Bt=e.store.state.chromecastDeviceName$,z=e.store.ads.postrollPassed,Mt=e.store.state.isLive$,ct=e.store.state.isPlaying$,_i=e.store.state.crashed$,Zt=e.store.webApi.annotationsApi,wt=e.store.webApi.pictureInPictureApi,dt=e.store.state.currentSubtitle$,Ui=e.store.state.currentSubtitleCaptions$,Pi=e.store.ui.playerSize,En=e.store.ads.playbackState,Pn=e.store.ui.is3DVideo,Ci=e.store.ui.icon3DVideoVisible,lo=e.store.state.isInteractive,fr=e.store.state.isInteractiveTime$,Zi=e.store.state.isInteractiveExpectation$,yi=e.store.state.hasInteractiveBranches,Ro=e.store.ui.touched,Zo=e.store.ui.modals.hotKeyMap.data,_o=e.store.ui.modals.hotKeyMap.show,mn=e.store.state.positionExact$,Hr=e.store.ui.overlayContainer$,Fr=e.store.ui.controls.interactiveTimeIndicator,xs=e.store.state.showInteractiveTimeIndicator,mr=e.store.ui.contextMenu.position$,vr=e.store.actions.internal.setQuality,Ur=e.store.actions.internal.closeSettingsMenu,zr=e.store.ui.autoplayNextEnabled$,Jo=e.store.ui.userActionsDisabled,An=e.store.ui.isControlsAvailable,Yn=e.store.ui.videoTitleInfo,gr=e.store.ui.doubleForwardOn$,ns=e.store.ui.doubleForwardAvailable$,en=e.store.actions.internal.getVideoElement,hr=e.store.actions.internal.checkFullscreenSupport,{fakeIsPlaying$:kn,notifications$:_r,graphIsOpened$:br}=xo(),wo=K(void 0),$r=K(void 0),Ji=K(void 0),jn=K(void 0),Xn,mt,ii;Zo.set(V_());let{closeNotification:yr,notificationsToShow$:xr}=_r,rs=f(()=>!!r().slow_video),Ln=()=>yr("slow_video"),wr=f(()=>(a()==="video"&&l()||a()==="ads"&&d()==="inactive")&&!s()),So=K(void 0),tn=ae(!1),Sr,on=ae(!1),nn=ae(),Wr=ae(!1),vn=K(!1),gn=K(!1),Ai=K(!1),Mn=K(!(e.autoplay&&!e.uiConfig.controls.showOnStartupAtAutoplay)),eo=f(()=>u()&&!m()&&!(n(vn)||n(gn))&&!(n(Ai)&&!p())),Vn=!0,Zn=f(()=>e.uiConfig.features.thumbTimer&&Qe()&&a()==="video"&&!v()&&!s()&&!lo&&(e.uiConfig.hideThumbTimerAfterTouch&&!b()||!e.uiConfig.hideThumbTimerAfterTouch)),hn=e.uiConfig.titleShowBehaviour,Cr=f(()=>!["video","thumb"].includes(a())||hn==="never"||y()?!1:hn==="fullscreen"?_():!0),et=f(()=>hn==="always"||a()==="thumb"?!1:!v()),li=K(!1),Oo=f(()=>(rt()||e.showAutoplayNext&&x())&&!!Re()&&!!we()&&(e.showAds&&I()||!e.showAds)&&C()&&!s()&&!n(li)&&!yi),_n=f(()=>R()&&!(v()||n(Oo))&&!u()&&k()&&!P()),Co=K(!1),rn=f(()=>E()!==null),{toggle:bo}=kn,$o=!1,ki=null;wt==null||wt.setContext(rd());let Kr=()=>{e.autoplay&&!lo&&e.uiConfig.controls.showOnStartupAtAutoplay&&zi(e.uiConfig.controls.hideTimeout)};e.store.setUiCallbacks({onStarted:Kr});let Rn=()=>{window.clearTimeout(Xn),on.set(!1)},ws=()=>{window.clearTimeout(mt),nn.set(null)},zi=fe=>{Rn(),on.set(!0),Xn=window.setTimeout(()=>on.set(!1),fe);let Tt=fe-100;Sr=window.setTimeout(()=>{W()&&tn.set(!1)},Tt>0?Tt:fe)},Ss=(fe,Tt)=>{ws(),nn.set(Tt),mt=window.setTimeout(()=>nn.set(null),fe)},ss=Pn.subscribe(fe=>{Ci.set(fe),fe&&(window.clearTimeout(ii),ii=window.setTimeout(()=>Ci.set(!1),e.uiConfig.controls.hide360IconTimeout))}),as=()=>ht(null,null,function*(){var Tt,Jt,ei,Fo;let fe=sa();if(fe){let fo=Md(),Ki=On();fe=fo===Ki||fo===Se()}if(fe){zi(e.uiConfig.controls.hideTimeoutFullscreen);try{yield wt==null?void 0:wt.exit()}catch(fo){Nt({message:String(fo)})}}at.set(fe),e.store.getAdmanWrapper().setFullscreen(fe),_()?(Jt=(Tt=e.store.callbacks)==null?void 0:Tt.onFullscreenEnter)==null||Jt.call(Tt):(Fo=(ei=e.store.callbacks)==null?void 0:ei.onFullscreenExit)==null||Fo.call(ei)}),Tr=fe=>{Pi.set(fe)},sn=()=>{if(n(wo)){let{width:fe,height:Tt}=n(wo).getBoundingClientRect();Pi.set({width:fe,height:Tt})}};Vt(()=>{var Tt;return Lu(as),e.uiConfig.features.annotationsInside&&(Zt==null||Zt.init(n(wo))),wt==null||wt.assignPlayerContainer(n(wo)),wt==null||wt.setExternalEventHandlers({resize:Tr,leavepictureinpicture:sn}),e.interactiveContainer&&((Tt=Lt().parentElement)==null||Tt.insertBefore(e.interactiveContainer,Lt().nextSibling)),()=>{window.clearTimeout(Xn),window.clearTimeout(Sr),window.clearTimeout(mt),window.clearTimeout(ii),ss(),wt==null||wt.dispose().catch(Jt=>{Nt({message:String(Jt)})}),Mu(as)}});let On=()=>{let fe=e.uiConfig.features.fullscreenInternalTargetPlayerContainer||!yt()?n(wo):yt(),Tt=fe.getRootNode(),Jt=Tt instanceof ShadowRoot?Tt.host:Tt,ei=Fe()instanceof HTMLElement&&Fe().contains(Jt);return e.uiConfig.allowChangingFullscreenTarget&&Fe()&&ei?Fe():fe},xi=()=>{st.set(!1)},Ye=()=>{Ur(),xi()},At=()=>ht(null,null,function*(){if(!hr()){Nt({message:"fullscreen disabled"});return}xi(),sa()?(yield ku(document),Nt({message:"exit fullscreen"})):(Nt({message:"request fullscreen"}),yield Au(On()))}),fi=fe=>{y()||(fe.preventDefault(),st.set(!0),mr.set({left:fe.clientX,top:fe.clientY}))};function Do(){Wr.set(!0),lo||zi(e.uiConfig.controls.hideTimeoutCursor)}function To(fe){var fo,Ki;let{relatedTarget:Tt}=fe,ei=!!(Tt&&((fo=n(Ji))!=null&&fo.contains(Tt)))&&((Ki=Kt())==null?void 0:Ki.isFocused()),Fo=e.uiConfig.controls.showOnStartupAtAutoplay||!!Tt;!lo&&!ei&&Fo&&(tn.set(!0),zi(e.uiConfig.controls.hideTimeoutCursor))}function Io(){Wr.set(!1),O(gn,!1),O(vn,!1),$o=!1,e.store.actions.internal.releaseCamera(),zi(e.uiConfig.controls.hideTimeout),P()&&Bo()}function Wi(fe){return fe?fe.offsetTop+Wi(fe.offsetParent):0}function No(fe){return fe?fe.offsetLeft+No(fe.offsetParent):0}function Dn(fe){if(F()&&xs){let Tt=fe.currentTarget,Jt=Wi(Tt),ei=No(Tt),Fo=fe.pageX-ei,fo=fe.pageY-Jt,{left:Ki,bottom:ds,right:ir}=F(),Gr=ir-Ki;return Fo>=Ki-Gr&&fo<=ds+Gr}}function Ir(fe){if(n(wo)){let Tt=Wi(fe.currentTarget),Jt=U().height,ei=fe.pageY-Tt;if(Dn(fe)){O(gn,!1);return}ei<40?O(gn,!0):ei>Jt-40?O(vn,!0):(O(gn,!1),m()||O(vn,!1))}}function Eo(fe){Ir(fe),!n(eo)&&!P()&&zi(e.uiConfig.controls.hideTimeoutCursor),j()&&$o&&ki&&e.store.actions.internal.moveCameraFocusPX(ki.clientX-fe.clientX,ki.clientY-fe.clientY,fe.timeStamp-ki.timeStamp),ki=fe}let co=null,Jn=()=>{co=window.setTimeout(()=>{e.store.actions.internal.changeDoubleForwardOn(!0),Rn()},e.uiConfig.doubleForwardActivationTime)},Bo=()=>{e.store.actions.internal.changeDoubleForwardOn(!1),co&&clearTimeout(co),co=null},Nn=fe=>{fe.preventDefault(),fe.button===0&&($o=!0,e.store.actions.internal.holdCamera(),se()&&Jn()),!$o&&zi(e.uiConfig.controls.hideTimeoutCursor)},Er=fe=>{fe.preventDefault(),fe.button===0&&(ki=fe,$o=!1,e.store.actions.internal.releaseCamera()),!P()&&zi(e.uiConfig.controls.hideTimeoutCursor)},qr=fe=>{fe.preventDefault(),Vn&&(Nt({message:"double click on video"}),At(),zi(e.uiConfig.controls.hideTimeoutCursor))},Qr=fe=>{var Tt;if(fe.preventDefault(),P()){Bo();return}if(co&&Bo(),G()||m()){Ye();return}if(!(C()&&!yi)){if(n(rn))return bo();if((Tt=Kt())==null||Tt.focus(),!ye()){e.firstStart(),zi(e.uiConfig.controls.hideTimeoutCursor);return}(!e.uiConfig.preventPauseOnVideoClick||re()!==Qb.PLAYING)&&e.store.actions.internal.togglePlay(),zi(e.uiConfig.controls.hideTimeoutCursor)}},Xe=fe=>{Ye(),Ro.set(!0),zi(e.uiConfig.controls.hideTimeout),fe&&Ss(e.uiConfig.controls.hideHotKeyHelpers,fe)},Xt=()=>{var fe,Tt;Ye(),(fe=e.store.callbacks)!=null&&fe.onOpenHotKeyMap?(Tt=e.store.callbacks)==null||Tt.onOpenHotKeyMap(X()):_o.update(Jt=>!Jt)},Li=()=>{Ro.set(!0)},yo=e.store.ui.contextMenu.openedByBtnKeyboard$,an=e.store.ui.contextMenu.btnRef$,er=K(void 0),Ho=e.store.ui.contextMenu.openedByHotKey$,tr=e.store.ui.contextMenu.lastActiveElem$,ls=K(!1),qs=e.store.ui.previewTrackActive;He(()=>{Hr.set(n(So))}),He(()=>{O(Ai,n(Mn)&&re()!==Qb.PLAYING,!0),n(Mn)||Pt(()=>O(Mn,!0))}),He(()=>{var Tt,Jt;let fe=(n(Ai)||C()||m()||Te()||ue()||te()||be()||n(ls))&&!n(eo)&&(a()==="video"||a()==="ads"&&(e.uiConfig.controls.showOnStartupAtAutoplay||Ce()!=="inactive"))&&!s()&&k();ao.set(fe),!fe&&!be()&&((Tt=n(Ji))!=null&&Tt.contains(Hu()))&&((Jt=Kt())==null||Jt.focus())}),He(()=>{!Te()&&n(Co)&&!u()&&zi(e.uiConfig.controls.hideTimeoutCursor),Pt(()=>O(Co,Te(),!0))}),He(()=>{n(jn),m(),me(),Pt(()=>Bd(n(jn),m(),me()))}),He(()=>{n(er),G(),qe(),ve(),Pt(()=>{let fe=qe()||ve();Bd(n(er),G(),fe)})}),He(()=>{let fe=pe();fe&&(G(),Pt(()=>Ol(fe,G(),yo)))}),He(()=>{let fe=Z();fe&&(G(),Pt(()=>F_(fe,G(),Ho)))}),He(()=>{var fe;!N()&&_()&&(Pt(()=>ui.set(!1)),(fe=Kt())==null||fe.focus())}),He(()=>{y()&&Ye()});let Bn=K(void 0),ga=fe=>{Yn.set(Qn(en(),{title:n(Bn)},"title",fe))},Qs=(fe,Tt)=>{var fo,Ki;let Jt=(Ki=(fo=e.store.callbacks)==null?void 0:fo.uiInfo)==null?void 0:Ki.onUpcomingLiveViewStateChanged;if(!Jt)return;let ei=!!Tt,Fo=Me(Me({},Qn(n(wo),{upcomingLiveScreen:Tt},"upcomingLiveScreen",ei)),fe);Jt(Fo)},ut="",di=f(()=>{var fe;return n(et)?ut:(fe=e.getVideoDeeplink)==null?void 0:fe.call(e,ce())});He(()=>{ut=n(di)});var Po=TT();ft("blur",Aa,Ye);var uo=le(Po);uo.__mousemove=Eo;var Mi=T(uo);let Pr=f(()=>a()==="ads"),Cs=f(()=>n(rn)?bo:void 0);it(Zf(Mi,{startDoubleForwardActivationTimer:Jn,stopDoubleForward:Bo,toggleFullscreen:At,hideContextMenu:Ye,showHotKeyHelpers:Xe,showKeyMap:Xt,get isAds(){return n(Pr)},get fakePlayButtonHandler(){return n(Cs)},get nextButtonActive(){return q()},get prevButtonActive(){return Le()},children:(fe,Tt)=>{var Jt=ST(),ei=le(Jt);ol(ei,{get hideCursor(){return n(_n)},onClick:Qr,onContextMenu:fi,onMouseDown:Nn,onMouseUp:Er,onDblClick:qr,get videoContainer(){return Lt()},set videoContainer(Ki){Lt(Ki)}});var Fo=A(ei,2);Oa(Fo,()=>"slot",!1,(Ki,ds)=>{io(Ki,()=>({name:il}))});var fo=A(Fo,2);Ls(fo,de,Ki=>{var ds=wT(),ir=le(ds);let Gr=f(()=>a()!=="thumb"||s()||lo&&e.autoplay);Ja(ir,{get hidden(){return n(Gr)},get thumbUrl(){return e.thumbUrl},get startVideo(){return e.firstStart},onContextMenu:fi,onClick:xi});var ha=A(ir,2);{var jl=Ge=>{Pv(Ge,{})};V(ha,Ge=>{_e()&&Ge(jl)})}var Ar=A(ha,2);Iv(Ar,{});var cs=A(Ar,2);Ev(cs,{get isVisible(){return P()}});var Gs=A(cs,2);{var kr=Ge=>{let vi=f(()=>{var Uo;return(Uo=e.live)==null?void 0:Uo.startTime});vc(Ge,{get thumbUrl(){return e.thumbUrl},get startTime(){return n(vi)},onUpcomingLiveViewStateChanged:Qs,onContextMenu:fi,onClick:xi})};V(Gs,Ge=>{a()==="LiveWaitingStart"&&Ge(kr)})}var nl=A(Gs,2);{var Xl=Ge=>{el(Ge,{kind:"recover",get thumbUrl(){return e.thumbUrl},onContextMenu:fi,onClick:xi})};V(nl,Ge=>{a()==="LiveWaitingRecover"&&Ge(Xl)})}var Lr=A(nl,2);{var rl=Ge=>{el(Ge,{kind:"record",get thumbUrl(){return e.thumbUrl},onContextMenu:fi,onClick:xi})};V(Lr,Ge=>{a()==="LiveWaitingRecord"&&Ge(rl)})}var sl=A(Lr,2);{var Zl=Ge=>{var vi=bT();let Uo;var Mr=T(vi);Vd(Mr,{get adsSlotId(){return lt()},get adsParams(){return Et()},get adsAutoplayParam(){return jt()},get duration(){return zt()},get adsExternalApi(){return e.adsExternalApi},get adsJson(){return e.adsJson}}),S(vi),D(bn=>Uo=ne(vi,1,"ads-container s-8",null,Uo,bn),[()=>({hidden:a()!=="ads"})]),$(Ge,vi)};V(sl,Ge=>{e.showAds&&ye()&&Ge(Zl)})}var _a=A(sl,2);{var al=Ge=>{let vi=f(()=>!rt()&&e.showAutoplayNext&&x());Yf(Ge,{get title(){return Re()},get thumb(){return we()},get isHide(){return n(vi)},clickCloseIcon:()=>O(li,!0)})};V(_a,Ge=>{n(Oo)&&Re()&&we()&&Ge(al)})}var pt=A(_a,2);{var vt=Ge=>{let vi=f(()=>_()?"md":"sm"),Uo=f(()=>{var Mr;return(Mr=e.store.callbacks)==null?void 0:Mr.onTitleClicked});ov(Ge,{get title(){return e.title},get isHidden(){return n(et)},onVisibilityChanged:ga,get titleLinkHref(){return n(di)},onMouseEnter:()=>{O(ls,!0)},onMouseLeave:()=>{O(ls,!1)},get size(){return n(vi)},get onTitleClicked(){return n(Uo)},get ref(){return n(Bn)},set ref(Mr){O(Bn,Mr,!0)}})};V(pt,Ge=>{n(Cr)&&Ge(vt)})}var qi=A(pt,2);{var Oi=Ge=>{let vi=f(()=>a()==="video"&&v());fc(Ge,{get isShifted(){return n(vi)}})};V(qi,Ge=>{j()&&Ge(Oi)})}var Qi=A(qi,2);{var hi=Ge=>{var vi=$T(),Uo=T(vi);Ld(Uo,{}),S(vi),$(Ge,vi)};V(Qi,Ge=>{ge()&&Ge(hi)})}var Di=A(Qi,2);{var ba=Ge=>{mc(Ge,{get thumbUrl(){return e.thumbUrl},get chromecastDeviceName(){return ze()},onClick:Qr,onContextMenu:fi,onDblClick:qr})};V(Di,Ge=>{te()&&Ge(ba)})}var ll=A(Di,2);{var $p=Ge=>{Xa(Ge,{get shifted(){return v()},get captions(){return We()},get position(){return ee()},get playerSize(){return U()}})};V(ll,Ge=>{ie().value!=="off"&&a()==="video"&&Ge($p)})}var Lc=A(ll,2);{var yp=Ge=>{var vi=yT();vi.__contextmenu=fi,vi.__click=[_T,G,st,m,St,Ye];var Uo=T(vi);Za(Uo,{}),S(vi),$(Ge,vi)};V(Lc,Ge=>{s()&&Ge(yp)})}var Mc=A(Lc,2);{var xp=Ge=>{let vi=f(()=>a()==="thumb"||a()==="LiveWaitingStart"||a()==="LiveWaitingRecover"||a()==="LiveWaitingRecord"),Uo=f(()=>a()==="ads"),Mr=f(()=>e.canRewindLive&&ke()!==0);uc(Ge,{get bottomHidden(){return n(vi)},get bottomNoSmooth(){return W()},get showControls(){return v()},get isAds(){return n(Uo)},get canRewindLive(){return n(Mr)},get logoClickable(){return e.logoClickable},get logoHidden(){return e.logoHidden},get logoTargetUrl(){return Ot()},get showAutoplayNext(){return e.showAutoplayNext},get showNextPrevButtons(){return Wt()},get nextButtonActive(){return q()},get prevButtonActive(){return Le()},get isOneVideoPlaylist(){return Ke()},customFullscreenSupported:Vn,toggleFullscreen:At,get seekToInteractive(){return e.seekToInteractive},get playPrevChapter(){return e.playPrevChapter},get playerControlsWrapperRef(){return n($r)},set playerControlsWrapperRef(bn){O($r,bn,!0)},get playerControlsRef(){return n(Ji)},set playerControlsRef(bn){O(Ji,bn,!0)}})};V(Mc,Ge=>{ye()&&Ge(xp)})}var Vc=A(Mc,2);{var wp=Ge=>{var vi=xT(),Uo=T(vi);let Mr=f(()=>{var bn;return(bn=n(Ji))==null?void 0:bn.clientHeight});_c(Uo,{get supportLink(){return e.supportLink},get playerControlsHeight(){return n(Mr)},returnFocus:()=>{var bn;return(bn=Kt())==null?void 0:bn.focus()},get ref(){return n(jn)},set ref(bn){O(jn,bn,!0)}}),S(vi),$(Ge,vi)};V(Vc,Ge=>{!te()&&a()!=="ads"&&Ge(wp)})}var Rc=A(Vc,2);let Sp=f(()=>!n(Zn));Dd(Rc,{get isLive(){return Ue()},get isHidden(){return n(Sp)},get isPlaying(){return Ie()},get position(){return ee()},get duration(){return ke()}});var Oc=A(Rc,2);tv(Oc,{get data(){return nn}});var $a=A(Oc,2);Gf($a,{get supportLink(){return e.supportLink},returnFocus:()=>{var Ge;return(Ge=Kt())==null?void 0:Ge.focus()},get visible(){return G()},get playerContainerRef(){return n(wo)},get position(){return Ae()},get menuElementRef(){return n(er)},set menuElementRef(Ge){O(er,Ge,!0)}});var Dc=A($a,2);{var ya=Ge=>{bc(Ge,{onClose:Ln,onSelectAutoQuality:()=>{vr("auto"),Ln()}})};V(Dc,Ge=>{n(rs)&&Ge(ya)})}var xa=A(Dc,2);{var Cp=Ge=>{za(Ge,{})};V(xa,Ge=>{n(wr)&&Ge(Cp)})}var Jl=A(xa,2);{var ed=Ge=>{tm(Ge,{})};V(Jl,Ge=>{Ne()&&Ge(ed)})}var Nc=A(Jl,2);{var Tp=Ge=>{Ud(Ge,{})};V(Nc,Ge=>{gt()&&Ge(Tp)})}$(Ki,ds)}),$(fe,Jt)},$$slots:{default:!0}}),fe=>Kt(fe),()=>Kt());var Ts=A(Mi,2);it(Ts,fe=>O(So,fe),()=>n(So)),S(uo),it(uo,fe=>O(wo,fe),()=>n(wo));var po=A(uo,2);{var Vi=fe=>{var Tt=CT();$(fe,Tt)};V(po,fe=>{It()&&fe(Vi)})}ft("mouseenter",uo,Do),ft("mouseleave",uo,Io),ft("click",uo,Li,!0),ft("focusin",uo,To,!0),$(i,Po),H(),o()}Je(["mousemove","contextmenu","click"]);import{clientChecker as yc,PlaybackState as DT}from"@vkontakte/videoplayer-core/es2015";import{noop as NT}from"@vkontakte/videoplayer-shared/es2015";var ET=L('<div></div> <div class="info s-m"><div class="triangles-wrapper s-m"><div></div> <div></div> <div></div></div> <p class="step-caption s-m"> </p></div>',1),PT=L("<div><!></div>"),AT={hash:"s-m",code:".double-click-area.s-m{height:100%;overflow:hidden;position:absolute;top:0;width:25%}.double-click-area.left.s-m{left:0}.double-click-area.right.s-m{right:0}.semicircle.s-m{background-color:rgba(0,0,0,.5);height:100%;position:absolute;top:0;width:100%}.semicircle.left.s-m{border-bottom-right-radius:50%;border-top-right-radius:50%;left:0}.semicircle.right.s-m{border-bottom-left-radius:50%;border-top-left-radius:50%;right:0}.info.s-m{align-items:center;flex-direction:column;left:50%;position:absolute;top:50%;transform:translate(-50%,-50%)}.info.s-m,.triangles-wrapper.s-m{display:flex;justify-content:center}.triangles-wrapper.s-m{margin-bottom:10px;position:relative}.triangle.s-m{animation:s-m-blink .5s infinite;border-bottom:6px solid transparent;border-top:6px solid transparent;height:0;opacity:0;width:0}.triangle.left.s-m:nth-child(3),.triangle.right.s-m:first-child{animation-delay:0s}.triangle.left.s-m:nth-child(2),.triangle.right.s-m:nth-child(2){animation-delay:.1s}.triangle.left.s-m:first-child,.triangle.right.s-m:nth-child(3){animation-delay:.2s}@keyframes s-m-blink{0%{opacity:0}50%{opacity:1}to{opacity:0}}.triangle.left.s-m{border-right:8px solid var(--white)}.triangle.right.s-m{border-left:8px solid var(--white)}.triangle.s-m:not(:last-child){margin-right:5px}.step-caption.s-m{color:var(--white);font-size:12px;line-height:1;margin:0;text-align:center}"};function lp(i,e){B(e,!0),Q(i,AT);let t=h(e,"seekStep",3,0),o=K(!1),r=0,a=0,l=K(ci(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)};cn(()=>{window.clearTimeout(r)});var s=PT();s.__click=d;var u=T(s);{var m=p=>{var v=ET(),b=le(v),y=A(b,2),_=T(y),x=T(_),I=A(x,2),C=A(I,2);S(_);var R=A(_,2),k=T(R,!0);S(R),S(y),D(P=>{var E,W,F,U;ne(b,1,`semicircle ${(E=e.side)!=null?E:""}`,"s-m"),ne(x,1,`triangle ${(W=e.side)!=null?W:""}`,"s-m"),ne(I,1,`triangle ${(F=e.side)!=null?F:""}`,"s-m"),ne(C,1,`triangle ${(U=e.side)!=null?U:""}`,"s-m"),he(k,P)},[()=>Y("doubletap_seek_step",{seconds:n(l).toFixed(0)})]),$(p,v)};V(u,p=>{n(o)&&p(m)})}S(s),D(()=>{var p;return ne(s,1,`double-click-area ${(p=e.side)!=null?p:""}`,"s-m")}),$(i,s),H()}Je(["click"]);var kT=(i,e,t)=>{e(!1),t()},LT=L('<div class="overlay s-l"></div> <div class="next-video s-l"><div class="top s-l"><div class="caption s-l"> </div> <!></div> <div class="row s-l"><div class="column s-l"><div class="thumb s-l"><div></div> <!></div></div> <div class="column s-l"><div class="title s-l"> </div></div></div></div>',1),MT={hash:"s-l",code:".overlay.s-l{background:rgba(0,0,0,.72);height:100%;position:absolute;width:100%}.next-video.s-l{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-l{display:flex;justify-content:space-between}.caption.s-l{color:var(--white);font-size:11px;font-weight:700;opacity:.8;text-transform:uppercase}.row.s-l{background:rgba(48,48,48,.8);cursor:pointer;display:flex;flex-direction:row;height:102px;margin-top:6px;width:100%}.column.s-l{display:flex;flex-basis:50%;flex-direction:column}.thumb.s-l{align-items:center;background:no-repeat 50%;background-size:cover;display:flex;justify-content:space-around;position:relative}.thumb.s-l,.thumb-overlay.s-l{height:100%;width:100%}.thumb-overlay.s-l{position:absolute}.thumb-overlay.withOpacity.s-l{background:var(--black);opacity:.3}.title.s-l{color:var(--white);font-size:12px;font-weight:700;line-height:1.6;max-height:52px;overflow:hidden;padding:10px 16px}"};function kv(i,e){B(e,!0),Q(i,MT);let[t,o]=Be(),r=()=>w(d,"$autoplayNextEnabled$",t),a=()=>w(s,"$timerNextVideoRunning$",t),l=xe(),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()};Vt(()=>{e.isHide||m(),e.isHide&&r()&&(u(!1),v())});var x=Oe(),I=le(x);{var C=R=>{var k=LT(),P=A(le(k),2),E=T(P),W=T(E),F=T(W,!0);S(W);var U=A(W,2);Ds(U,{onClick:_}),S(E);var j=A(E,2);j.__click=[kT,u,p];var se=T(j),G=T(se),re=T(G);let X;var Te=A(re,2);{var ue=me=>{zd(me,{get isRunning(){return a()},onTimerEnded:y})};V(Te,me=>{r()&&me(ue)})}S(G),S(se);var te=A(se,2),be=T(te),Ce=T(be,!0);S(be),S(te),S(j),S(P),D((me,qe)=>{he(F,me),je(G,`background-image: url('${e.thumb}')`),X=ne(re,1,"thumb-overlay s-l",null,X,qe),he(Ce,e.title)},[()=>r()?Y("end_screen_next_video"):Y("end_screen_recommended_video"),()=>({withOpacity:r()})]),$(R,k)};V(I,R=>{e.isHide||R(C)})}$(i,x),H(),o()}Je(["click"]);import{clientChecker as VT}from"@vkontakte/videoplayer-core/es2015";var Gb=({getFullscreenTarget:i,fullScreenChangeHandler:e})=>{let t=null,o;Vt(()=>{VT.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))}),cn(()=>{t==null||t(),clearTimeout(o)})};import{VideoFormat as RT}from"@vkontakte/videoplayer-core/es2015";var dp=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}};import{clientChecker as OT}from"@vkontakte/videoplayer-core/es2015";var Yb=({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=()=>OT.device.isIOS&&$e(l)===RT.DASH_LIVE_CMAF,p=()=>{s==null||s(),s=null},v=b=>{if(p(),!m()||!b)return;let y=u();if(!y)return;let _=new dp(y),x=$e(d),I=$e(a),C=$e(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)}),k=()=>{let P=_.getCurrentShowingId();o($e(a).find(E=>E.value===P))};y.textTracks.addEventListener("change",k),s=()=>{R(),_.detachAll(),y.textTracks.removeEventListener("change",k)}};Vt(()=>t.subscribe(v)),cn(p)};var BT=(i,e,t,o)=>{if(i.stopPropagation(),e()){o();return}},HT=L("<!> <!>",1),FT=L("<div><!></div>"),UT=L('<div class="spherical-video-icon s-9"><!></div>'),zT=L("<div><!></div>"),WT=L('<div class="settings-mobile s-9"><!></div>'),KT=L("<!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!> <!>",1),qT=L('<div class="player-wrapper s-9" role="region" tabindex="-1"><!> <!> <!> <div class="overlay-container"></div></div>'),QT={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 Lv(i,e){var hn,Cr;B(e,!0),Q(i,QT);let[t,o]=Be(),r=()=>w(Ke,"$playerPhase",t),a=()=>w($i,"$isLoaderVisible",t),l=()=>w(Le,"$adPlaybackState",t),d=()=>w(Ct,"$crashed",t),s=()=>w(mr,"$notificationsToShow$",t),u=()=>w(q,"$playbackState$",t),m=()=>w(zt,"$graphIsOpened$",t),p=()=>w(Fe,"$interactiveHideMobileControls",t),v=()=>w(gi,"$isEnded$",t),b=()=>w(_i,"$isInteractiveExpectation$",t),y=()=>w(yt,"$controlsVisible",t),_=()=>w(dt,"$touched",t),x=()=>w(Pi,"$autoplayNextEnabled$",t),I=()=>w(pi,"$postrollPassed",t),C=()=>w(zr,"$bottomNoSmooth",t),R=()=>w(st,"$videoSize",t),k=()=>w(xt,"$playerSize",t),P=()=>w(Se,"$isFullscreen",t),E=()=>w(Re,"$position$",t),W=()=>w(we,"$duration$",t),F=()=>w(En,"$loadedMetadata",t),U=()=>w(Qe,"$settingsMenuVisible",t),j=()=>w(Kt,"$scrubbingInProgress",t),se=()=>w(Nt,"$volumeChangingInProgress",t),G=()=>w(ro,"$chromecastConnected$",t),re=()=>w(ye,"$isControlsAvailable",t),X=()=>w(ct,"$isInteractiveTime$",t),Te=()=>w(ao,"$isActiveLive",t),ue=()=>w(rt,"$settingsMenuOpenedByKeyboard",t),te=()=>w(Wt,"$language$",t),be=()=>w(wt,"$disabledControls$",t),Ce=()=>w(Bt,"$is3DVideo",t),me=()=>w(z,"$icon3DVideoVisible",t),qe=()=>w(so,"$chromecastDeviceName$",t),ve=()=>w(Ei,"$currentSubtitle$",t),pe=()=>w(Vo,"$currentSubtitleCaptions$",t),Z=()=>w(Xo,"$realDuration$",t),N=()=>w(at,"$isLive$",t),ce=()=>w(ui,"$isPlaying$",t),de=()=>w(ai,"$debugPanelVisible",t),_e=h(e,"videoContainer",15),ge=h(e,"adsSlotId",3,void 0),ze=h(e,"adsParams",3,void 0),ie=h(e,"adsAutoplayParam",3,void 0),We=h(e,"duration",3,void 0),ee=h(e,"logoTargetUrl",3,""),ke=h(e,"showNextPrevButtons",3,!1),Ue=h(e,"nextButtonActive",3,!1),Ie=h(e,"prevButtonActive",3,!1),Ae=h(e,"endScreenVideoTitle",3,void 0),Ne=h(e,"endScreenVideoThumb",3,void 0),gt=h(e,"isOneVideoPlaylist",3,!1),It=h(e,"showMiniTimer",3,!1),Lt=h(e,"fullScreenTarget",3,void 0),lt=h(e,"playerStarted",3,!1),Et=h(e,"showEndScreen",3,!0),{notifications$:jt,graphIsOpened$:zt}=xo(),Ot=e.store.getLogger().createComponentLog("Root component"),Wt=e.store.interfaceLanguage$,q=e.store.state.playbackState$,Le=e.store.ads.playbackState,Re=e.store.state.positionWithScrubbing$,we=e.store.state.duration$,Ke=e.store.playerPhase,Se=e.store.ui.isFullscreen,yt=e.store.ui.controlsVisible,ye=e.store.ui.isControlsAvailable,Fe=e.store.ui.interactiveHideMobileControls,Qe=e.store.ui.settingsMenu.visible$,rt=e.store.ui.settingsMenu.openedByBtnKeyboard$,Kt=e.store.ui.scrubbingInProgress,Nt=e.store.ui.volumeChangingInProgress,ai=e.store.ui.debugPanelVisible,$i=e.store.state.isLoaderVisible,gi=e.store.state.isEnded$,ro=e.store.state.chromecastConnected$,so=e.store.state.chromecastDeviceName$,pi=e.store.ads.postrollPassed,at=e.store.state.isLive$,ui=e.store.state.isPlaying$,ao=e.store.state.isActiveLive$,St=e.store.state.isRewindableLive$,Ct=e.store.state.crashed$,Si=e.store.webApi.annotationsApi,nt=e.store.webApi.pictureInPictureApi,st=e.store.state.videoSize$,Ei=e.store.state.currentSubtitle$,Vo=e.store.state.currentSubtitleCaptions$,Xo=e.store.state.duration$,xt=e.store.ui.playerSize,Bt=e.store.ui.is3DVideo,z=e.store.ui.icon3DVideoVisible,Mt=e.store.state.isInteractive,ct=e.store.state.isInteractiveTime$,_i=e.store.state.isInteractiveExpectation$,Zt=e.store.state.hasInteractiveBranches,wt=e.store.ui.controls.disabledControls$,dt=e.store.ui.touched,Ui=e.store.ui.overlayContainer$,Pi=e.store.ui.autoplayNextEnabled$,En=e.store.state.loadedMetadata$,Pn=e.store.actions.internal.closeSettingsMenu,Ci=(hn=e.store.callbacks)==null?void 0:hn.onDisabledPlayPrevChapterClick,lo=(Cr=e.store.callbacks)==null?void 0:Cr.onDisabledSeekToInteractiveClick,fr=e.store.actions.internal.setQuality,Zi=K(void 0),yi=K(void 0),Ro=K(void 0),Zo=K(void 0),_o,mn,Hr=f(()=>(r()==="video"&&a()||r()==="ads"&&l()==="inactive")&&!d()),Fr=K(void 0),{closeNotification:xs,notificationsToShow$:mr}=jt,vr=f(()=>!!s().slow_video),Ur=()=>xs("slow_video"),zr=ae(!1),Jo,An=K(!1),Yn=f(()=>u()!==DT.PLAYING),gr=K(!1),ns=f(()=>m()||p()||!n(An)&&(v()&&!!Zt||n(Yn)&&b())),en=K(!0),hr=f(()=>e.uiConfig.features.thumbTimer&&It()&&r()==="video"&&!y()&&!d()&&!Mt&&(e.uiConfig.hideThumbTimerAfterTouch&&!_()||!e.uiConfig.hideThumbTimerAfterTouch)),kn=K(!1),_r=f(()=>(Et()||e.showAutoplayNext&&x())&&!!Ae()&&!!Ne()&&(e.showAds&&I()||!e.showAds)&&v()&&!d()&&!n(kn)),br=K(!1);nt==null||nt.setContext(rd());let wo=et=>{et&&!Mt&&Ji(e.uiConfig.controls.hideTimeoutMobile)};e.store.setUiCallbacks({onStarted:wo});let $r=()=>{clearTimeout(_o),O(An,!1),p()&&Fe.set(!1)},Ji=et=>{$r(),O(An,!0),_o=setTimeout(()=>O(An,!1),et);let li=et-100;Jo=setTimeout(()=>{C()&&zr.set(!1)},li>0?li:et)},jn=Bt.subscribe(et=>{z.set(et),et&&(clearTimeout(mn),mn=setTimeout(()=>z.set(!1),e.uiConfig.controls.hide360IconTimeout))}),Xn=(...li)=>ht(null,[...li],function*(et=sa()){var Oo,_n,Co,rn,bo,$o;if(et&&!yc.device.isIOS){let ki=Md(),Kr=Ln(),Rn=yc.browser.isSamsungBrowser&&ki===e.shadowRootContainer;et=ki===Kr||Rn}if(et){Ji(e.uiConfig.controls.hideTimeoutFullscreen);try{yield nt==null?void 0:nt.exit()}catch(ki){Ot({message:String(ki)})}try{let ki=(Oo=R())!=null&&Oo.width&&((_n=R())!=null&&_n.height)?R():k();yield L_(ki)}catch(ki){Ot({message:String(ki)})}}Se.set(et),e.store.getAdmanWrapper().setFullscreen(et),P()?(rn=(Co=e.store.callbacks)==null?void 0:Co.onFullscreenEnter)==null||rn.call(Co):($o=(bo=e.store.callbacks)==null?void 0:bo.onFullscreenExit)==null||$o.call(bo)}),mt=et=>{xt.set(et)},ii=()=>{if(n(Zi)){let{width:et,height:li}=n(Zi).getBoundingClientRect();xt.set({width:et,height:li})}};Vt(()=>{var et;return Lu(Xn),e.uiConfig.features.annotationsInside&&(Si==null||Si.init(n(Zi))),nt==null||nt.assignPlayerContainer(n(Zi)),nt==null||nt.setExternalEventHandlers({resize:mt,leavepictureinpicture:ii}),O(en,!yc.device.isIphoneOrOldIpad),e.interactiveContainer&&((et=_e().parentElement)==null||et.insertBefore(e.interactiveContainer,_e().nextSibling)),()=>{clearTimeout(_o),clearTimeout(Jo),clearTimeout(mn),jn(),nt==null||nt.dispose().catch(li=>{Ot({message:String(li)})}),Mu(Xn)}});let yr=K(!0),xr=K(!0),rs=et=>{let li=E()+(et==="forward"?1:-1)*e.uiConfig.controls.seekStepMobile/1e3;li<0?(O(yr,!1),li=0):li>=W()&&(O(xr,!1),li=W()),O(gr,!0),e.seekTime(li)},Ln=()=>yc.device.isIOS?n(Zi):!e.uiConfig.allowChangingFullscreenTarget||!Lt()?e.outerContainerRef:Lt().contains(e.outerContainerRef)?Lt():e.outerContainerRef,wr=()=>ht(null,null,function*(){try{if(sa())yield ku(document),Ot({message:"exit fullscreen"});else{if(Ot({message:"request fullscreen"}),yc.device.isIOS&&!F())return;yield Au(Ln())}}catch(et){Ot({message:String(et)})}}),So=()=>{Pn()},tn=et=>{if(et.preventDefault(),U()){So();return}if(!lt()){e.firstStart(),Ji(e.uiConfig.controls.hideTimeoutCursor);return}O(gr,!1),y()?$r():Ji(e.uiConfig.controls.hideTimeoutMobile)},Sr=()=>{dt.set(!0)},on=()=>{Mt||(zr.set(!0),Ji(e.uiConfig.controls.hideTimeoutCursor))},nn=et=>{Ci&&(Ci(et),Ji(e.uiConfig.controls.hideTimeoutMobile))},Wr=et=>{lo&&(lo(et),Ji(e.uiConfig.controls.hideTimeoutMobile))};He(()=>{Ui.set(n(Fr))}),He(()=>{yt.set((n(Yn)||U()||j()||se()||G()||!n(_r)&&(v()||n(An)&&!n(gr)))&&!n(ns)&&r()==="video"&&!d()&&re())}),He(()=>{!j()&&n(br)&&!X()&&Ji(e.uiConfig.controls.hideTimeoutMobile),O(br,j(),!0)}),He(()=>{O(yr,E()>0),O(xr,!Te()&&E()<W(),!0)}),He(()=>{Bd(n(Zo),U(),ue(),!0)});let vn=Y("aria_label_video_player");Gb({fullScreenChangeHandler:Xn,getFullscreenTarget:Ln}),Yb({store:e.store,getFullscreenTarget:Ln});let gn=(et,li)=>{var rn,bo;let Oo=(bo=(rn=e.store.callbacks)==null?void 0:rn.uiInfo)==null?void 0:bo.onUpcomingLiveViewStateChanged;if(!Oo)return;let _n=!!li,Co=Me(Me({},Qn(n(Zi),{upcomingLiveScreen:li},"upcomingLiveScreen",_n)),et);Oo(Co)};var Ai=qT();ft("blur",Aa,So);var Mn=T(Ai);ol(Mn,{onClick:tn,get videoContainer(){return _e()},set videoContainer(et){_e(et)}});var eo=A(Mn,2);Oa(eo,()=>"slot",!1,(et,li)=>{io(et,()=>({name:il}))});var Vn=A(eo,2);Ls(Vn,te,et=>{var li=KT(),Oo=le(li);let _n=f(()=>r()!=="thumb"||d()||Mt&&e.autoplay||e.uiConfig.features.disableThumbUnstartedOnAutoplay&&e.autoplay);Ja(Oo,{get hidden(){return n(_n)},get thumbUrl(){return e.thumbUrl},get startVideo(){return e.firstStart}});var Co=A(Oo,2);{var rn=Xe=>{var Xt=HT(),Li=le(Xt);{var yo=Ho=>{let tr=f(()=>e.uiConfig.controls.seekStepMobile/1e3);lp(Ho,{side:"left",get seekStep(){return n(tr)},handleSingleFirstClick:tn,handleSecondClick:()=>rs("backward")})};V(Li,Ho=>{n(yr)&&Ho(yo)})}var an=A(Li,2);{var er=Ho=>{let tr=f(()=>e.uiConfig.controls.seekStepMobile/1e3);lp(Ho,{side:"right",get seekStep(){return n(tr)},handleSingleFirstClick:tn,handleSecondClick:()=>rs("forward")})};V(an,Ho=>{n(xr)&&Ho(er)})}$(Xe,Xt)};V(Co,Xe=>{e.canRewindLive&&St&&!be().has("TIMELINE")&&Xe(rn)})}var bo=A(Co,2);{var $o=Xe=>{let Xt=f(()=>{var Li;return(Li=e.live)==null?void 0:Li.startTime});vc(Xe,{get thumbUrl(){return e.thumbUrl},get startTime(){return n(Xt)},onUpcomingLiveViewStateChanged:gn})};V(bo,Xe=>{r()==="LiveWaitingStart"&&Xe($o)})}var ki=A(bo,2);{var Kr=Xe=>{el(Xe,{kind:"recover",get thumbUrl(){return e.thumbUrl}})};V(ki,Xe=>{r()==="LiveWaitingRecover"&&Xe(Kr)})}var Rn=A(ki,2);{var ws=Xe=>{el(Xe,{kind:"record",get thumbUrl(){return e.thumbUrl}})};V(Rn,Xe=>{r()==="LiveWaitingRecord"&&Xe(ws)})}var zi=A(Rn,2);{var Ss=Xe=>{var Xt=FT();let Li;var yo=T(Xt);Vd(yo,{get adsSlotId(){return ge()},get adsParams(){return ze()},get adsAutoplayParam(){return ie()},get duration(){return We()},get adsExternalApi(){return e.adsExternalApi},get adsJson(){return e.adsJson}}),S(Xt),D(an=>Li=ne(Xt,1,"ads-container s-9",null,Li,an),[()=>({hidden:r()!=="ads"})]),$(Xe,Xt)};V(zi,Xe=>{e.showAds&&lt()&&Xe(Ss)})}var ss=A(zi,2);{var as=Xe=>{let Xt=f(()=>!Et()&&e.showAutoplayNext&&x());kv(Xe,{get title(){return Ae()},get thumb(){return Ne()},get isHide(){return n(Xt)},clickCloseIcon:()=>O(kn,!0)})};V(ss,Xe=>{n(_r)&&Ae()&&Ne()&&Xe(as)})}var Tr=A(ss,2);{var sn=Xe=>{fc(Xe,{})};V(Tr,Xe=>{Ce()&&Xe(sn)})}var On=A(Tr,2);{var xi=Xe=>{var Xt=UT(),Li=T(Xt);Ld(Li,{}),S(Xt),$(Xe,Xt)};V(On,Xe=>{me()&&Xe(xi)})}var Ye=A(On,2);{var At=Xe=>{mc(Xe,{get thumbUrl(){return e.thumbUrl},get chromecastDeviceName(){return qe()},onClick:tn})};V(Ye,Xe=>{G()&&Xe(At)})}var fi=A(Ye,2);{var Do=Xe=>{Xa(Xe,{get shifted(){return y()},get captions(){return pe()},get position(){return E()},get playerSize(){return k()},isMobile:!0})};V(fi,Xe=>{ve().value!=="off"&&Xe(Do)})}var To=A(fi,2);{var Io=Xe=>{var Xt=zT();Xt.__click=[BT,U,Qe,So];var Li=T(Xt);Za(Li,{}),S(Xt),$(Xe,Xt)};V(To,Xe=>{d()&&Xe(Io)})}var Wi=A(To,2);{var No=Xe=>{let Xt=f(()=>r()==="thumb"||r()==="LiveWaitingStart"||r()==="LiveWaitingRecover"||r()==="LiveWaitingRecord"||r()==="ads"),Li=f(()=>r()==="ads"),yo=f(()=>e.canRewindLive&&Z()!==0);uc(Xe,{get bottomHidden(){return n(Xt)},get showControls(){return y()},get bottomNoSmooth(){return C()},get isAds(){return n(Li)},get canRewindLive(){return n(yo)},get logoClickable(){return e.logoClickable},get logoHidden(){return e.logoHidden},get logoTargetUrl(){return ee()},get showAutoplayNext(){return e.showAutoplayNext},get showNextPrevButtons(){return ke()},get nextButtonActive(){return Ue()},get prevButtonActive(){return Ie()},get isOneVideoPlaylist(){return gt()},get customFullscreenSupported(){return n(en)},get endScreenShown(){return n(_r)},toggleFullscreen:wr,get seekToInteractive(){return e.seekToInteractive},get playPrevChapter(){return e.playPrevChapter},onDisabledPlayPrevChapterClick:nn,onDisabledSeekToInteractiveClick:Wr,get playerControlsWrapperRef(){return n(yi)},set playerControlsWrapperRef(an){O(yi,an,!0)},get playerControlsRef(){return n(Ro)},set playerControlsRef(an){O(Ro,an,!0)}})};V(Wi,Xe=>{lt()&&Xe(No)})}var Dn=A(Wi,2);{var Ir=Xe=>{var Xt=WT(),Li=T(Xt);_c(Li,{get supportLink(){return e.supportLink},get returnFocus(){return NT},get ref(){return n(Zo)},set ref(yo){O(Zo,yo,!0)}}),S(Xt),$(Xe,Xt)};V(Dn,Xe=>{U()&&Xe(Ir)})}var Eo=A(Dn,2);let co=f(()=>!n(hr));Dd(Eo,{get isLive(){return N()},get isHidden(){return n(co)},get isPlaying(){return ce()},get position(){return E()},get duration(){return W()}});var Jn=A(Eo,2);{var Bo=Xe=>{za(Xe,{})};V(Jn,Xe=>{n(Hr)&&Xe(Bo)})}var Nn=A(Jn,2);{var Er=Xe=>{Ud(Xe,{})};V(Nn,Xe=>{de()&&Xe(Er)})}var qr=A(Nn,2);{var Qr=Xe=>{bc(Xe,{onClose:Ur,onSelectAutoQuality:()=>{fr("auto"),Ur()}})};V(qr,Xe=>{n(vr)&&Xe(Qr)})}$(et,li)});var Zn=A(Vn,2);it(Zn,et=>O(Fr,et),()=>n(Fr)),S(Ai),it(Ai,et=>O(Zi,et),()=>n(Zi)),D(()=>De(Ai,"aria-label",vn)),ft("click",Ai,Sr,!0),ft("focusin",Ai,on,!0),$(i,Ai),H(),o()}Je(["click"]);function cp(i){let e="";return no(i.timelineSliderFilledColor)&&(e+=`--timeline-slider-filled-bg:${i.timelineSliderFilledColor};`),no(i.timelineSliderHandleColor)&&(e+=`--timeline-slider-handle-bg:${i.timelineSliderHandleColor};`),no(i.timelineSliderLoadedColor)&&(e+=`--timeline-slider-loaded-bg:${i.timelineSliderLoadedColor};`),no(i.timelineSliderColor)&&(e+=`--timeline-slider-bg:${i.timelineSliderColor};`),no(i.volumeSliderColor)&&(e+=`--volume-slider-bg:${i.volumeSliderColor};`),no(i.volumeSliderHandleColor)&&(e+=`--volume-slider-handle-bg:${i.volumeSliderHandleColor};`),no(i.volumeSliderFilledColor)&&(e+=`--volume-slider-filled-bg:${i.volumeSliderFilledColor};`),no(i.controlsTimeColor)&&(e+=`--controls-time:${i.controlsTimeColor};`),no(i.timelineSliderFilledActiveLiveColor)&&(e+=`--timeline-slider-filled-active-live-bg:${i.timelineSliderFilledActiveLiveColor};`),no(i.timelineSliderHandleActiveLiveColor)&&(e+=`--timeline-slider-handle-active-live-bg:${i.timelineSliderHandleActiveLiveColor};`),no(i.buttonColor)&&(e+=`--btn-color:${i.buttonColor};`),no(i.buttonToggleOnColor)&&(e+=`--toggle-color-on:${i.buttonToggleOnColor};`,e+=`--toggle-color-autoplay-on:${i.buttonToggleOnColor};`),no(i.focusedColor)&&(e+=`--focused:${i.focusedColor};`),no(i.focusedOutlineWidth)&&(e+=`--focused-outline-width:${i.focusedOutlineWidth};`),no(i.focusedOutlineRadius)&&(e+=`--focused-outline-radius:${i.focusedOutlineRadius};`),no(i.controlsDesktopPaddingHorizontal)&&(e+=`--controls-desktop-padding-horizontal:${i.controlsDesktopPaddingHorizontal};`),no(i.timelinePaddingHorizontal)&&(e+=`--timeline-padding-horizontal:${i.timelinePaddingHorizontal};`),no(i.settingsBackgroundColor)&&(e+=`--settings-bg:${i.settingsBackgroundColor};`),no(i.font)&&(e+=`--font:${i.font};`),no(i.controlsGradientHeight)&&(e+=`--controls-gradient-height:${i.controlsGradientHeight};`),no(i.controlsGradient)&&(e+=`--controls-gradient:${i.controlsGradient};`),e.length&&e||void 0}function no(i){return typeof i=="string"&&!i.includes(";")}import{debounceFn as GT}from"@vkontakte/videoplayer-shared/es2015";var YT=L('<div class="time-container s-7"><!></div>'),jT=L('<div class="player-wrapper s-7" role="region"><!> <!> <!> <!> <!> <div><!></div></div>'),XT={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 Mv(i,e){B(e,!0),Q(i,XT);let[t,o]=Be(),r=()=>w(X,"$scrubbingInProgress",t),a=()=>w(G,"$playerSize",t),l=()=>w(E,"$isPlaying$",t),d=()=>w(k,"$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(j,"$isLive$",t),_=()=>w(se,"$isRewindableLive$",t),x=h(e,"outsideDuration",3,0),I=h(e,"videoContainer",15),{playerPhase:C,state:{crashed$:R,duration$:k,positionExact$:P,isPlaying$:E,currentSubtitle$:W,currentSubtitleCaptions$:F,positionWithScrubbing$:U,isLive$:j,isRewindableLive$:se},ui:{playerSize:G,controls:re,scrubbingInProgress:X},actions:{internal:{getVideoElement:Te}}}=xe(),ue=8,te=K(!1),be=ci({}),Ce=K(!1),me=f(()=>!r()&&!n(Ce)),qe=()=>{O(te,!0)},ve=()=>{O(te,!1)},pe=GT(Kl,260);He(()=>{a(),pe(Te(),re,be,n(te))});let Z=f(()=>l()?jo(d()-s()):jo(isFinite(d())?d():x()));var N=jT(),ce=T(N);ol(ce,{hideCursor:!1,get videoContainer(){return I()},set videoContainer(Ae){I(Ae)}});var de=A(ce,2);Oa(de,()=>"slot",!1,(Ae,Ne)=>{io(Ae,()=>({name:il}))});var _e=A(de,2);let ge=f(()=>u()!=="thumb"||m());Ja(_e,{get hidden(){return n(ge)},get thumbUrl(){return e.thumbUrl},iconVisible:!1});var ze=A(_e,2);{var ie=Ae=>{Xa(Ae,{shifted:!1,get captions(){return v()},get position(){return b()},get playerSize(){return a()}})};V(ze,Ae=>{p().value!=="off"&&n(me)&&Ae(ie)})}var We=A(ze,2);{var ee=Ae=>{var Ne=YT(),gt=T(Ne);Od(gt,{get isLive(){return y()},get isPlaying(){return l()},get time(){return n(Z)}}),S(Ne),$(Ae,Ne)};V(We,Ae=>{n(me)&&Ae(ee)})}var ke=A(We,2);let Ue;var Ie=T(ke);Ya(Ie,{get canRewindLive(){return e.canRewindLive},get isRewindableLive(){return _()},isAds:!1,needPadding:!1,isHidden:!1,withEpisodes:!1,tooltipLeftOffset:ue,tooltipRightOffset:ue,get ref(){return be.timeline},set ref(Ae){be.timeline=Ae}}),S(ke),S(N),D(Ae=>Ue=ne(ke,1,"timeline s-7",null,Ue,Ae),[()=>({visible:n(te)})]),ft("mouseenter",N,qe),ft("mouseleave",N,ve),ft("mouseenter",ke,()=>O(Ce,!0)),ft("mouseleave",ke,()=>O(Ce,!1)),$(i,N),H(),o()}var iI=L("<div><!></div>"),oI={hash:"s-1",code:'.vk-vp-root.s-1{--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-1{overflow:visible}.vk-vp-root.s-1 *{-webkit-tap-highlight-color:transparent}.vk-vp-root.s-1 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-1 p{margin:0}.vk-vp-root.s-1 svg:not(.interactive-root svg){pointer-events:none}.vk-vp-root.s-1 .interactive-root{font-family:var(--vk-vp-int-custom-font,inherit)}.vk-vp-root.s-1 :focus,.vk-vp-root.s-1 :focus-visible{outline:none}.vk-vp-root.s-1 :focus-visible{border-radius:var(--focused-outline-radius);box-shadow:var(--focused-element-shadow)}.vk-vp-root.s-1 .focus-hidden:focus-visible{box-shadow:none}.vk-vp-root.s-1 .hidden{opacity:0;visibility:hidden}.vk-vp-root.s-1 .out-of-flow{content-visibility:hidden!important}.vk-vp-root.s-1 .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-1 .out-of-view{left:-1000vh!important;position:absolute!important}.vk-vp-root.s-1 .icon.icon-error-stub{align-items:center;display:flex;justify-content:center}'};function Rv(i,e){B(e,!0),Q(i,oI);let[t,o]=Be(),r=()=>w(lt,"$isLive$",t),a=()=>w(Si,"$availableSubtitlesList$",t),l=()=>w(nt,"$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),k=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),j=h(e,"adsSlotId",7,void 0),se=h(e,"adsParams",7,void 0),G=h(e,"adsAutoplayParam",7,void 0),re=h(e,"duration",7,void 0),X=h(e,"logoClickable",7),Te=h(e,"logoHidden",7),ue=h(e,"isMobile",7),te=h(e,"showNextPrevButtons",7,!1),be=h(e,"nextButtonActive",7,!1),Ce=h(e,"prevButtonActive",7,!1),me=h(e,"endScreenVideoTitle",7,void 0),qe=h(e,"endScreenVideoThumb",7,void 0),ve=h(e,"isOneVideoPlaylist",7,!1),pe=h(e,"supportLink",7),Z=h(e,"shadowRootContainer",7),N=h(e,"outerContainerRef",7),ce=h(e,"fullScreenTarget",7,void 0),de=h(e,"failoverHosts",7,void 0),_e=h(e,"showMiniTimer",7,!1),ge=h(e,"saveRate",7),ze=h(e,"seekToInteractive",7,jb),ie=h(e,"playPrevChapter",7,jb),We=h(e,"volumeMultiplier",7),ee=h(e,"showAutoplayNext",7),ke=h(e,"showEndScreen",7,!0),Ue=h(e,"keyboardControls",15,void 0),{subscribers:Ie,stores:Ae}=u();Bh(p());let Ne=Rt(),gt=p().logoLink,It=s().ui.debugPanelVisible,Lt=s().ui.playerSize,lt=s().state.isLive$,jt=s().state.isInteractive&&Vv.device.isAndroid,zt=K(void 0),Ot=null,Wt=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}),Yh(s(),Ae),He(()=>{var z,Mt;s().ui.isMobile.set(ue()),(Mt=(z=m().callbacks)==null?void 0:z.onDomReady)==null||Mt.call(z)});let q=(z=!1)=>{O(Wt,!0),z?s().actions.external.firstStart(U()):s().actions.internal.firstStart(U())},Le=()=>{if(Ne.features.qualityDetailsSubMenuEnabled){let z=__(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{b_(s().videoId),Vf()&&s().actions.internal.setTrafficSavingEnabled(!0);let Mt=kf(s().videoId);Mt&&s().actions.internal.setQuality(Mt)}};function Re(z){var wt,dt,Ui;let Mt=d()||z;Mt&&s().initVideo({container:n(zt),sources:Mt,failoverHosts:de(),subtitles:x(),subtitlesForcedLanguage:I(),volumeMultiplier:We()});let ct=JT.get(Id)==="true";It.set(ct),W()>0&&s().actions.external.seekTime(W());let _i=ue()?Ne.volumeDefault:(dt=(wt=P())!=null?wt:$u())!=null?dt:Ne.volumeDefault,Zt=(Ui=E())!=null?Ui:p_();if(s().actions.external.setVolume(_i),s().actions.external.setMuted(Zt),s().getAdmanWrapper().setInitialVolume(Zt?0:_i),Le(),Ne.features.saveRate&&ge()){let Pi=v_();Pi&&!r()&&s().actions.internal.setPlaybackRate(Pi)}if(ee()){let Pi=h_();Pi&&s().actions.internal.setAutoplayNextEnabled(Pi)}s().ui.isAutoplay.set(k()),k()&&q(),R()&&Ne.features.preload&&s().actions.internal.preload()}let we=z=>{if(window.ResizeObserver){let Mt,ct;Ot=new ResizeObserver(eI(_i=>{let Zt=_i[0];if(Zt.contentBoxSize){let wt=Array.isArray(Zt.contentBoxSize)?Zt.contentBoxSize[0]:Zt.contentBoxSize;Mt=wt.inlineSize,ct=wt.blockSize}else Zt.contentRect&&(Mt=Zt.contentRect.width,ct=Zt.contentRect.height);Lt.set({width:Mt,height:ct})},300)),Ot.observe(z)}z.clientWidth&&z.clientHeight&&Lt.set({width:z.clientWidth,height:z.clientHeight})},Ke=()=>{document.hidden&&s().actions.external.stop()};Vt(()=>{var ct,_i,Zt,wt;jt&&document.addEventListener("visibilitychange",Ke),Ne.debugLog&&s().actions.internal.startLogging(),we(n(zt));let z=Ie.map(dt=>dt.init({store:s(),microStores:Ae,config:m(),interactiveController:_(),uiConfig:p()})),Mt=()=>{jt&&document.removeEventListener("visibilitychange",Ke),Ot==null||Ot.disconnect(),z.forEach(dt=>dt.unsubscribe()),s().destroy()};return((ct=C())==null?void 0:ct.status)==="upcoming"?(s().actions.internal.setLiveWaitingStart(!0),Mt):((_i=C())==null?void 0:_i.status)==="waiting"?(s().actions.internal.setLiveWaitingRecover(!0),Mt):(((Zt=C())==null?void 0:Zt.status)==="finished"||((wt=C())==null?void 0:wt.status)==="postlive")&&!(d()&&ZT(d()))?(s().actions.internal.setLiveWaitingRecord(!0),Mt):(Re(),Mt)});function Se(){n(Wt)?s().actions.external.play():q(!0)}function yt(){s().actions.external.pause()}function ye(z){s().actions.external.setMuted(z)}function Fe(){s().actions.external.toggleSubtitle()}function Qe(z,Mt){s().actions.external.changeSubtitle(z,Mt)}function rt(z){s().actions.external.changeAudioStream(z)}function Kt(){var z;(z=s().webApi.slotsApi)!=null&&z.haveSlots()&&s().actions.external.hideControls()}function Nt(){var z;(z=s().webApi.slotsApi)!=null&&z.haveSlots()&&s().actions.external.showControls()}function ai(z){ue()||z>=0&&z<=1&&s().actions.external.setVolume(z)}function $i(z){s().actions.internal.seekTime(z,tI.UNKNOWN)}function gi(z){s().actions.external.seekEpisodeStartTime(z)}function ro(){s().actions.external.returnFocusToEpisodes()}function so(z){s().actions.external.setPlaybackRate(z)}function pi(z){s().actions.external.setAutoQualityLimits(z)}function at(){s().actions.external.setQuality("auto")}function ui(z){s().actions.external.setTrafficSavingEnabled(z)}function ao(z){s().actions.external.setHighQualityEnabled(z)}let St=cp(Ne.view),Ct=m().playerView==="preview",Si=s().state.availableSubtitlesList$;if(Ne.features.initSubtitles){let z=!1;He(()=>{var Mt;if(!z&&a().length){z=!0;let ct;if(Ne.features.userVideoPrefs&&s().videoId){let Zt=Su(Ne.userSalt,String(s().videoId));Zt!=null&&Zt.subtitleTrackId&&(ct=a().find(wt=>wt.value===Zt.subtitleTrackId))}let _i=(Mt=I())!=null?Mt:Of();_i&&(ct=a().find(Zt=>Zt.language===_i)),s().actions.internal.setSubtitle(ct)}})}let nt=s().ui.isPreviewTrackHorizontallyAligned;var st=iI();let Ei;var Vo=T(st);{var Xo=z=>{Lv(z,{get store(){return s()},get uiConfig(){return Ne},get thumbUrl(){return b()},get interactiveContainer(){return y()},get live(){return C()},get autoplay(){return k()},get canRewindLive(){return F()},get showAds(){return U()},get adsSlotId(){return j()},get adsParams(){return se()},get adsAutoplayParam(){return G()},get duration(){return re()},get logoClickable(){return X()},get logoHidden(){return Te()},get logoTargetUrl(){return gt},get nextButtonActive(){return be()},get prevButtonActive(){return Ce()},get endScreenVideoTitle(){return me()},get endScreenVideoThumb(){return qe()},get isOneVideoPlaylist(){return ve()},get supportLink(){return pe()},get shadowRootContainer(){return Z()},get outerContainerRef(){return N()},get fullScreenTarget(){return ce()},get showMiniTimer(){return _e()},get playerStarted(){return n(Wt)},get seekToInteractive(){return ze()},get playPrevChapter(){return ie()},firstStart:q,seekTime:$i,get showEndScreen(){return ke()},get showAutoplayNext(){return ee()},get showNextPrevButtons(){return te()},get adsExternalApi(){return e.adsExternalApi},get adsJson(){return e.adsJson},get videoContainer(){return n(zt)},set videoContainer(Mt){O(zt,Mt,!0)}})},xt=z=>{var Mt=Oe(),ct=le(Mt);{var _i=wt=>{Mv(wt,{get thumbUrl(){return b()},get outsideDuration(){return re()},get canRewindLive(){return F()},get videoContainer(){return n(zt)},set videoContainer(dt){O(zt,dt,!0)}})},Zt=wt=>{Av(wt,{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 k()},get canRewindLive(){return F()},get showAds(){return U()},get adsSlotId(){return j()},get adsParams(){return se()},get adsAutoplayParam(){return G()},get duration(){return re()},get logoClickable(){return X()},get logoHidden(){return Te()},get logoTargetUrl(){return gt},get nextButtonActive(){return be()},get prevButtonActive(){return Ce()},get endScreenVideoTitle(){return me()},get endScreenVideoThumb(){return qe()},get isOneVideoPlaylist(){return ve()},get supportLink(){return pe()},get shadowRootContainer(){return Z()},get outerContainerRef(){return N()},get fullScreenTarget(){return ce()},get showMiniTimer(){return _e()},get playerStarted(){return n(Wt)},get seekToInteractive(){return ze()},get playPrevChapter(){return ie()},firstStart:q,get showEndScreen(){return ke()},get showAutoplayNext(){return ee()},get showNextPrevButtons(){return te()},get adsExternalApi(){return e.adsExternalApi},get adsJson(){return e.adsJson},get getVideoDeeplink(){return e.getVideoDeeplink},get videoContainer(){return n(zt)},set videoContainer(dt){O(zt,dt,!0)},get keyboardControls(){return Ue()},set keyboardControls(dt){Ue(dt)}})};V(ct,wt=>{Ct?wt(_i):wt(Zt,!1)})}$(z,Mt)};V(Vo,z=>{ue()?z(Xo):z(xt,!1)})}S(st),D(z=>{Ei=ne(st,1,"vk-vp-root s-1",null,Ei,z),je(st,St)},[()=>({"root--miui-browser":Vv.device.isMobile&&Vv.browser.isMiuiBrowser,"visible-outside":Ct,"preview-track-horizontally-alinged":l()})]),$(i,st);var Bt=H({initVideo:Re,play:Se,pause:yt,setMuted:ye,toggleSubtitle:Fe,changeSubtitle:Qe,changeAudioStream:rt,hideControls:Kt,showControls:Nt,setVolume:ai,seekTime:$i,seekEpisodeStartTime:gi,returnFocusToEpisodes:ro,setPlaybackRate:so,setAutoQualityLimits:pi,setAutoQuality:at,toggleTrafficSaving:ui,toggleHighQuality:ao,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 k()},set autoplay(z){k(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 j()},set adsSlotId(z){j(z)},get adsParams(){return se()},set adsParams(z){se(z)},get adsAutoplayParam(){return G()},set adsAutoplayParam(z){G(z)},get duration(){return re()},set duration(z){re(z)},get logoClickable(){return X()},set logoClickable(z){X(z)},get logoHidden(){return Te()},set logoHidden(z){Te(z)},get isMobile(){return ue()},set isMobile(z){ue(z)},get showNextPrevButtons(){return te()},set showNextPrevButtons(z){te(z)},get nextButtonActive(){return be()},set nextButtonActive(z){be(z)},get prevButtonActive(){return Ce()},set prevButtonActive(z){Ce(z)},get endScreenVideoTitle(){return me()},set endScreenVideoTitle(z){me(z)},get endScreenVideoThumb(){return qe()},set endScreenVideoThumb(z){qe(z)},get isOneVideoPlaylist(){return ve()},set isOneVideoPlaylist(z){ve(z)},get supportLink(){return pe()},set supportLink(z){pe(z)},get shadowRootContainer(){return Z()},set shadowRootContainer(z){Z(z)},get outerContainerRef(){return N()},set outerContainerRef(z){N(z)},get fullScreenTarget(){return ce()},set fullScreenTarget(z){ce(z)},get failoverHosts(){return de()},set failoverHosts(z){de(z)},get showMiniTimer(){return _e()},set showMiniTimer(z){_e(z)},get saveRate(){return ge()},set saveRate(z){ge(z)},get showAutoplayNext(){return ee()},set showAutoplayNext(z){ee(z)},get seekToInteractive(){return ze()},set seekToInteractive(z){ze(z)},get playPrevChapter(){return ie()},set playPrevChapter(z){ie(z)},get volumeMultiplier(){return We()},set volumeMultiplier(z){We(z)},get showEndScreen(){return ke()},set showEndScreen(z){ke(z)},get keyboardControls(){return Ue()},set keyboardControls(z){Ue(z)}});return o(),Bt}var nI=Pe('<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 Ov(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=nI();ti(9),$(r,l)},$$slots:{default:!0}})}var rI=L('<div class="title s-2"> </div>'),sI=L('<div class="playerStub s-2"><!> <!></div>'),aI={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 Dv(i,e){Q(i,aI);var t=sI(),o=T(t);{var r=d=>{var s=rI(),u=T(s,!0);S(s),D(()=>he(u,e.title)),$(d,s)};V(o,d=>{e.title&&d(r)})}var a=A(o,2);{var l=d=>{let s=f(()=>!!e.thumbUrl);Ov(d,{get isWhite(){return n(s)}})};V(a,d=>{(!e.title||!e.thumbUrl)&&d(l)})}S(t),D(()=>je(t,e.thumbUrl?`background-image: url('${e.thumbUrl}')`:"")),$(i,t)}var lI=L('<div class="playerError s-0"><!></div>'),dI={hash:"s-0",code:".playerError.s-0{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 Nv(i){Q(i,dI);var e=lI(),t=T(e);Za(t,{}),S(e),$(i,e)}import{now as UI,ValueSubject as zI}from"@vkontakte/videoplayer-shared/es2015";import{cloneDeepWith as WI,InterfaceLanguage as KI,isNonNullable as qv,Logger as qI,Observable as QI,Subscription as r$,once as GI,InternalsExposure as YI,skip as jI,getPlayerId as XI}from"@vkontakte/videoplayer-shared/es2015";import{clientChecker as s$,isMobile as ZI}from"@vkontakte/videoplayer-core/es2015";import{OneStat as JI,ThinOneStat as eE,MediascopePixel as tE}from"@vkontakte/videoplayer-statistics/es2015";import{Logger as cI,Subscription as uI}from"@vkontakte/videoplayer-shared/es2015";var up=class{constructor(){this.subscription=new uI,this.logger=new cI,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=$e(e.state.currentPlaybackRate$),r=$e(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()}};import{ValueSubject as Fv,detectEmbed as hI}from"@vkontakte/videoplayer-shared/es2015";var pI=Pe('<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),fI=L('<div><div><!></div> <span class="title s-6"> </span></div>'),mI={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 Bv(i,e){B(e,!0),Q(i,mI);let[t,o]=Be(),r=()=>w(u,"$interfaceLanguage$",t),a=()=>w(m,"$isMobile$",t),l=xe(),d=Rt(),s=!!l.webApi.pictureInPictureApi,u=l.interfaceLanguage$,m=l.ui.isMobile,p=l.ui.t,v=f(()=>r()&&p("pip_dummy_title")),b=cp(d.view);var y=fI();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=pI();ti(),$(P,W)},$$slots:{default:!0}}),S(x);var R=A(x,2),k=T(R,!0);S(R),S(y),D((P,E)=>{_=ne(y,1,"player-pip-dummy s-6",null,_,P),je(y,b),I=ne(x,1,"dummy-image s-6",null,I,E),he(k,n(v))},[()=>({"is-pip-api":s}),()=>({desktop:!a()})]),$(i,y),H(),o()}var vI=Object.defineProperty,gI=(i,e,t)=>e in i?vI(i,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):i[e]=t,va=(i,e,t)=>gI(i,typeof e!="symbol"?e+"":e,t),Hv=(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())}),_I=460,bI=280,xc=class{constructor({enabled:e=!0}={enabled:!0}){va(this,"playerDomElement"),va(this,"playerParentShadowRoot"),va(this,"playerDummyElement"),va(this,"svelteContext"),va(this,"pipWindow"),va(this,"info",{isActive$:new Fv(!1),isEnabled$:new Fv(!1),type:1}),va(this,"pipActive",!1),va(this,"pipApi"),this.info.isEnabled$=new Fv(e),Gu()&&(this.pipApi=new Bs({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}=hI();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 Hv(this,null,function*(){var e,t;if(!this.isSupported()||!this.playerDomElement||!this.playerParentShadowRoot)return;this.pipWindow=yield documentPictureInPicture.requestWindow({width:_I,height:bI,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=Jr(Bv,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||(Ra(this.playerDummyElement),this.playerParentShadowRoot.append(this.playerDomElement),this.info.isActive$.next(!1),this.pipWindow=void 0)})})}exit(){return Hv(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 Hv(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 Xb(i){return i instanceof xc}var pp=class{static getLatestSupportedVersion(e){let t=new Bs(e),o=new xc(e);if(o.isSupported())return o;if(t.isSupported())return t}};function wc(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 Zb="Inner error. Unexpectedly root annotation container null reference exception",Jb="Annotation with such name already exists",e$="Annotation with such name does not exist";var Yl=class extends Error{constructor(e){super(e),this.name="AnnotationError"}};import{observeElementSize as $I,Subscription as yI,throttleFn as xI}from"@vkontakte/videoplayer-shared/es2015";var wI="1",SI=100,fp=class{constructor(e){this.annotationsInside=e;this.annotations=new Map;this.subscriptions=new yI}init(e){if(this.rootAnnotationsContainer=e,this.annotationsInside)return;let t=xI(()=>{for(let o of this.annotations.values())this.isElementExceedsBoundaries(o,this.playerSize.width,this.playerSize.height)?o.style.visibility="hidden":o.style.visibility="visible"},SI);this.subscriptions.add($I(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 Yl(Zb);if(this.annotations.has(e))throw new Yl(Jb);t.style.zIndex=(o=t.style.zIndex)!=null?o:wI,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 Yl(e$);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(){}};import{assertNonNullable as mp,Subscription as CI}from"@vkontakte/videoplayer-shared/es2015";var fn=class{init({store:e,microStores:t,interactiveController:o,config:r}){return mp(e),mp(t),mp(r),r.interactiveData&&mp(o),this.subscription=new CI,this.subscription}};var Sc=class extends fn{constructor(){super(...arguments);this.stateName="fakeIsPlaying$";this.state$=Qt(Me({},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 Cc=class extends fn{constructor(){super(...arguments);this.stateName="interactiveControlsOpacity$";this.state$=Qt(Me({},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=$e(m),v=()=>p&&$e(u);return o.add(u.subscribe(b=>{if(!p)return;let y=$e(l);$e(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=$e(d);if(v()){this.state$.set(!0);return}y&&this.state$.set(!b)})),o}};var Tc=class extends fn{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}};import{combine as TI}from"@vkontakte/videoplayer-shared/es2015";var Uv=ae(!1),vp=null,Ic=class extends fn{constructor(){super(...arguments);this.stateName="showInteractiveTimeIndicatorTooltip$";this.state$=Qt(Me({},Uv),{set:(t,o=!1)=>{t!==$e(Uv)&&(this.clearTimeout(),Uv.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=>{$e(l)&&p&&this.state$.set(!1)}));let m=(a==null?void 0:a.interactiveData)||{tooltipHelpHintActive:!1};return o.add(TI({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)}};import{combine as II,noop as EI}from"@vkontakte/videoplayer-shared/es2015";var Ec=class extends fn{constructor(){super(...arguments);this.stateName="graphIsOpened$";this.graphMadePause=!1;this.state$=Qt(Me({},ae(null)),{toggle:EI});this.checkIfShouldHide=t=>Ns(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($e(l)))return;let s=$e(this.state$),{isEnded$:u,playbackState$:m}=r.state,{disabledControls$:p}=r.ui.controls,v=$e(u),b=$e(m);if(s)try{yield a==null?void 0:a.toggleGraphView(!1),this.state$.set(!1),p.remove(wf),!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(wf),!v&&this.graphMadePause&&r.actions.internal.pause()}catch(y){d({message:"Cant show graph"})}}}),o.add(II({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}};import{ValueSubject as t$}from"@vkontakte/videoplayer-shared/es2015";var Pc=class extends fn{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 t$(!1),isEnabled$:new t$(!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}};import{filter as kI,filterChanged as LI}from"@vkontakte/videoplayer-shared/es2015";import{safeStorage as zv}from"@vkontakte/videoplayer-shared/es2015";var i$=({maxShowCount:i,timeout:e})=>{let t=[i!==0?PI({maxCount:i}):void 0,e!==0?AI({timeout:e}):void 0].filter(o=>!!o);return{notificationShowed:o=>t.forEach(r=>r.notificationShowed(o)),canShowNotification:o=>t.every(r=>r.canShowNotification(o))}},PI=({maxCount:i})=>{let e={};return{notificationShowed:t=>{var o,r;e[t]=((o=e[t])!=null?o:0)+1,zv.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}}},AI=({timeout:i})=>{let e="videoplayer_notifications_manager",t=()=>{try{return JSON.parse(zv.get(e)||"{}")}catch(a){return{}}},o=a=>zv.set(e,JSON.stringify(a)),r=a=>{let l=t();delete l[a],o(l)};return{notificationShowed:a=>{o(Qt(Me({},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 Ac=class extends fn{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=i$({maxShowCount:a,timeout:l});let u=r.getPlayer();return o.add(u.events.severeStallOccured$.pipe(LI(),kI(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 o$=()=>[Sc,Cc,Tc,Ic,Ec,Pc,Ac].reduce(({subscribers:i,stores:e},t)=>{let o=new t;return{subscribers:[...i,o],stores:Qt(Me({},e),{[o.stateName]:o.state$})}},{subscribers:[],stores:{}});import{devNull as kc}from"@vkontakte/videoplayer-shared/es2015";var gp=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 hp=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 gp(()=>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 MI=L('<div class="root s-3"><!></div>'),VI={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 Wv(i,e){B(e,!0),Q(i,VI);let t=null,o=K(null);He(()=>(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);Ls(m,()=>n(o),p=>{var v=MI(),b=T(v);let y=f(()=>n(o)==="prev");$c(b,{get duration(){return e.animationDuration},get Icon(){return fa},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})}import{getWindow as RI}from"@vkontakte/videoplayer-shared/es2015";var Kv=RI().HTMLElement||class{constructor(){this.isConnected=!1}};var OI=Object.defineProperty,DI=Object.defineProperties,NI=Object.getOwnPropertyDescriptors,n$=Object.getOwnPropertySymbols,BI=Object.prototype.hasOwnProperty,HI=Object.prototype.propertyIsEnumerable,Gv=(i,e,t)=>e in i?OI(i,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):i[e]=t,Ks=(i,e)=>{for(var t in e||(e={}))BI.call(e,t)&&Gv(i,t,e[t]);if(n$)for(var t of n$(e))HI.call(e,t)&&Gv(i,t,e[t]);return i},FI=(i,e)=>DI(i,NI(e)),Yt=(i,e,t)=>Gv(i,typeof e!="symbol"?e+"":e,t),_p=(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())}),iE={preload:!0,autoplay:!1,repeat:!1,loop:!1,fromTime:0,canRewindLive:!0,showAds:!1,interfaceLanguage:KI.RU,isCyrillicRelatedInterface:!0,logoClickable:!1,logoHidden:!1,isTouch:ZI(),isMediaSessionEnabled:!0,isPictureInPictureEnabled:!0,isAudioDisabled:!1,callbacks:{uiInfo:{}},tuningConfig:{},saveRate:!0,volumeMultiplier:1,showEndScreen:!0,showAutoplayNext:!0,showNextPrevButtons:!0},Gn=K(void 0),Qv=ci({animationDuration:0,playbackStatusShow:!1}),bp=class extends Kv{constructor(){super(),Yt(this,"svelteStubComponent"),Yt(this,"svelteRootComponent"),Yt(this,"sveltePersistentLayerComponent"),Yt(this,"svelteErrorComponent"),Yt(this,"store"),Yt(this,"microStoresRoot"),Yt(this,"statistics"),Yt(this,"sentry"),Yt(this,"_shadowRoot"),Yt(this,"playerContainer"),Yt(this,"rootContainer"),Yt(this,"stateContainer"),Yt(this,"shadowRootContainer"),Yt(this,"playerId"),Yt(this,"uiConfig"),Yt(this,"coreConfig"),Yt(this,"statisticsConfig"),Yt(this,"metaConfig"),Yt(this,"interactiveController"),Yt(this,"interactiveContainer"),Yt(this,"graphMadePause"),Yt(this,"currentPlayingVideoIndex",0),Yt(this,"needToRepeatPlaylist",!1),Yt(this,"videoConfig"),Yt(this,"pictureInPictureApi"),Yt(this,"mediaSessionApi"),Yt(this,"unsubscribePlayerPhaseSubscription"),Yt(this,"logger"),Yt(this,"log"),Yt(this,"subscription"),Yt(this,"interactiveSubscription"),Yt(this,"annotationsApi"),Yt(this,"slotsApi"),Yt(this,"focusManager"),Yt(this,"prevIsid"),Yt(this,"isInited",!1),Yt(this,"postponedInitParams",null),Yt(this,"internalsExposure",null),Yt(this,"shadowDOMCallbacksDisabled",!1),Yt(this,"fatalError$",new zI(null)),Yt(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}=wc(this.videoConfig,t),R=(o=C==null?void 0:C.projectInfo)==null?void 0:o.pid,k=(a=(r=this.interactiveController)==null?void 0:r.state.isReplay$.getValue())!=null?a:!1;k&&(this.prevIsid=void 0);let{unitedVideoId:P,isClip:E=!1}=e;if(this.uiConfig.features.statistics&&P)try{return new JI(Ks({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||k)&&{projectId:Number(R)}),Ks({refreshAuthToken:v,userSalt:u,config:this.statisticsConfig},this.interactiveController&&{useIsid:!0,isid:this.prevIsid}))}catch(F){console.error(F),this.log({message:F.message})}}),kc.create("ui"),this.logger=new qI,this.log=this.logger.createComponentLog("VKVideoPlayer"),this.subscription=new r$,this.interactiveSubscription=new r$,this.graphMadePause=!1,this.fatalError$.subscribe(e=>{this.unmountComponent(this.svelteErrorComponent),e&&(this.unmountComponent(this.svelteStubComponent),this.unmountComponent(this.svelteRootComponent),this.svelteErrorComponent=Jr(Nv,{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=ci({title:o,thumbUrl:r}),l={target:this.playerContainer,props:a};this.svelteStubComponent=Jr(Dv,l),this.sveltePersistentLayerComponent=Jr(Wv,{target:this.playerContainer,props:Qv}),this.postponedInitParams&&(this.initPlayer(...this.postponedInitParams),this.postponedInitParams=null)}updatePersistentLayerProps(){if(!this.uiConfig)return;let{playbackStatusNextVideoAnimationDuration:e,features:{playbackStatusShow:t,playbackStatusNextVideoShow:o}}=this.uiConfig;Qv.animationDuration=e,Qv.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(),kc.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}=wc(this.videoConfig,t),{unitedVideoId:l}=e;if(this.uiConfig.features.thinStatistics&&l)return new eE.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:k,fromTime:P,canRewindLive:E,supportLink:W,showAds:F,adsSlotId:U,adsParams:j={},adsAutoplayParam:se,interfaceLanguage:G,isCyrillicRelatedInterface:re,logoClickable:X,logoHidden:Te,isMobile:ue,isTouch:te,isAudioDisabled:be,isLiveCatchUpMode:Ce,fullScreenTarget:me,failoverHosts:qe,canDownload:ve,callbacks:pe,interactiveData:Z,showThumbTimer:N,additionalButtons:ce=[],additionalSettingsMenuItems:de=[],additionalContextMenuItems:_e=[],repeat:ge,loop:ze,saveRate:ie,volumeMultiplier:We,showEndScreen:ee,showAutoplayNext:ke,mediascopePixels:Ue}=wc(this.videoConfig,t),{sources:Ie,title:Ae,thumbUrl:Ne,unitedVideoId:gt,isClip:It=!1,duration:Lt,adsParams:lt={},videoEpisodes:Et,previewThumbsData:jt,subtitles:zt,subtitlesForcedLanguage:Ot,live:Wt,adsExternalApi:q,adsJson:Le}=e;if(!Ie&&!Wt){let pi=new Error("empty sources and live");this.fatalError$.next(pi),(r=pe.onCrashed)==null||r.call(pe,pi.message);return}let Re=Ks(Ks({},j),lt),we=this.getNextVideoInfo(),Ke={sources:Ie,title:Ae,thumbUrl:Ne,subtitles:zt,subtitlesForcedLanguage:Ot,unitedVideoId:gt,isClip:It,live:Wt,albumId:y,statPlace:_,autoplay:C,muted:k,volume:R,fromTime:P,canRewindLive:E,showAds:F,adsSlotId:U,adsParams:Re,adsAutoplayParam:se,duration:Lt,logoClickable:X,logoHidden:Te,isTouch:te!=null?te:ue,repeat:ge,loop:ze,showNextPrevButtons:this.needToShowNextPrevButtons(),nextButtonActive:this.isNextButtonActive(),prevButtonActive:this.isPrevButtonActive(),endScreenVideoTitle:we.nextVideoTitle,endScreenVideoThumb:we.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(Ke)}`});let yt=(a=this.interactiveController)==null?void 0:a.state.statistics$.getValue(),ye=(yt==null?void 0:yt.oneStat)||this.createOneStat(e,t),Fe=this.createThinOneStat(e,t),Qe;Ue&&(Qe=new tE({pixels:Ue})),(ye||Fe)&&(this.statistics=new ju(ye,Fe,Qe,yt==null?void 0:yt.statSubscription)),this.uiConfig.features.sentry&&this.uiConfig.sentry.dsn&&new Ba(this.uiConfig.sentry,{version:Ll,env:hu},{movieId:gt,albumId:y,place:_,autoplay:(l=C&&!this.interactiveController)!=null?l:!1,mobile:te!=null?te:ue,clip:It}),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=Ks(Ks({},this.sentry),Ba.getInstance());let Kt=!!Z,Nt=[],ai="tooltip_interactive_go_back_disabled_first";if(Kt&&this.interactiveController){let pi=this.interactiveController.state.isInitialChapter$.getValue(),at=this.interactiveController.getHistoryState();pi&&Nt.push("REPLAY_BUTTON"),this.interactiveController.getIsSeekable().getValue()||Nt.push("SEEK_TO_INTERACTIVE_BUTTON"),at.hasPrevChapter$.getValue()||(Nt.push("PLAY_PREV_CHAPTER_BUTTON"),pi||(at.isGoBackLimited$.getValue()?ai="tooltip_interactive_go_back_disabled_limit":ai="tooltip_interactive_go_back_disabled"))}let $i=()=>{var pi;this.isInited=!1,this.prevIsid=void 0;let at=(o==null?void 0:o.info.isEnded$.getValue())&&((pi=this.interactiveController)==null?void 0:pi.state.isEndChapter$.getValue());pe.onReplayInteractiveVideo&&!at?pe.onReplayInteractiveVideo():this.replayInteractiveVideo()},gi=ge&&this.videoConfig.videos.length===1;this.store=mb({player:o,interfaceLanguage:G,isCyrillicRelatedInterface:re,videoId:gt,isClip:It,isLiveCatchUpMode:Ce,isAudioDisabled:be,statAuthToken:x,callbacks:pe,webApi:Se,videoEpisodes:Et,previewThumbsData:jt,canDownload:ve,uiConfig:this.uiConfig,coreConfig:this.coreConfig,metaConfig:this.metaConfig,disabledControls:Nt,isInteractive:Kt,saveRate:ie,interactiveRanges$:(m=this.interactiveController)==null?void 0:m.state.interactiveRanges$,isInteractiveTime$:(p=this.interactiveController)==null?void 0:p.state.isInteractiveTime$,stopPlayer:()=>this.stop(),replayInteractive:$i,playPrevChapterDisabledTooltip:ai,hasInteractiveBranches:!!((b=(v=this.interactiveController)==null?void 0:v.getChapterBranches())!=null&&b.length),additionalButtons:this.uiConfig.features.additionalButtons?ce:[],additionalSettingsMenuItems:de!=null?de:[],additionalContextMenuItems:_e!=null?_e:[],playPrevVideo:()=>this.playPrevVideo(),playNextVideo:()=>this.playNextVideo(),onVideoChanged:pi=>{var at;return(at=this.sveltePersistentLayerComponent)==null?void 0:at.startVideoChangedAnimation(pi)},looped:this.uiConfig.features.useLoopSetting?ze:gi,statistics:this.statistics,internalsExposure:this.internalsExposure,playerView:this.videoConfig.playerView,playerId:this.playerId,videoElement:this.videoConfig.videoElement});let{stores:ro}=this.microStoresRoot=o$(),so=()=>{var pi,at,ui,ao,St,Ct;if(!this.store||!this.microStoresRoot||!this.videoConfig)return;this.subscription.add(this.store.state.currentFormat$.subscribe(nt=>{var st;return(st=pe==null?void 0:pe.onCurrentFormatChanged)==null?void 0:st.call(pe,nt)})),this.subscription.add(ro.interactiveControlsOpacity$.subscribe(nt=>{var st;nt!==null&&((st=this==null?void 0:this.interactiveController)==null||st.setDisabledControls(nt))})),this.subscription.add(this.store.state.throughputEstimation$.subscribe(nt=>{var st;return(st=pe==null?void 0:pe.onThroughputEstimationChanged)==null?void 0:st.call(pe,nt)})),this.subscription.add(this.store.state.trafficSavingEnabled$.subscribe(nt=>{var st;return(st=pe==null?void 0:pe.onTrafficSavingEnabledChanged)==null?void 0:st.call(pe,nt)})),this.subscription.add(this.store.state.highQualityEnabled$.subscribe(nt=>{var st;return(st=pe==null?void 0:pe.onHighQualityEnabledChanged)==null?void 0:st.call(pe,nt)})),this.subscription.add(this.store.state.isAutoQualityEnabled$.subscribe(nt=>{var st;return(st=pe==null?void 0:pe.onAutoQualityEnabledChanged)==null?void 0:st.call(pe,!!nt)})),this.subscription.add(new QI(nt=>{this.store&&this.subscription.add(this.store.state.currentPlaybackRate$.subscribe(st=>nt.next(st)))}).pipe(jI(1)).subscribe(nt=>{var st;return(st=pe==null?void 0:pe.onCurrentPlaybackRateChanged)==null?void 0:st.call(pe,nt)})),this.subscription.add(this.store.state.volume$.subscribe(nt=>{var st;return(st=pe==null?void 0:pe.onVolumeChange)==null?void 0:st.call(pe,nt)})),this.subscription.add(this.store.state.muted$.subscribe(nt=>{var st,Ei,Vo,Xo;if(nt)(st=pe==null?void 0:pe.onMute)==null||st.call(pe);else{let xt=(Vo=((Ei=this.store)==null?void 0:Ei.state.volume$)&&$e(this.store.state.volume$))!=null?Vo:0;(Xo=pe==null?void 0:pe.onUnmute)==null||Xo.call(pe,xt)}})),this.subscription.add(this.store.state.videoBitrate$.subscribe(nt=>{var st;return(st=pe==null?void 0:pe.onVideoBitrateChanged)==null?void 0:st.call(pe,nt)})),this.subscription.add(this.store.state.isInteractiveTime$.subscribe(nt=>{var st;let Ei=(st=this.store)==null?void 0:st.ui.controls.disabledControls$;Ei&&(nt&&!Ei.includes(Ed)&&Ei.add(Ed),nt||Ei.remove(Ed))})),this.subscription.add(this.store.ui.isFullscreen.subscribe(nt=>_p(this,null,function*(){var st;if(!s$.browser.isSamsungBrowser||!nt||!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(nt=>{var st;return(st=pe==null?void 0:pe.onVSIDChanged)==null?void 0:st.call(pe,nt)})),this.initMediaSession(),O(Gn,{interactiveController:this.interactiveController,interactiveContainer:this.interactiveContainer,sources:Ie,store:this.store,microStoresRoot:this.microStoresRoot,videoConfig:this.videoConfig,uiConfig:this.uiConfig,title:Ae,thumbUrl:Ne,subtitles:zt,subtitlesForcedLanguage:Ot,live:Wt,preload:I,autoplay:C,muted:k,volume:R,fromTime:P,canRewindLive:E,supportLink:W,showAds:F,adsSlotId:U,adsParams:Re,adsAutoplayParam:se,duration:Lt,logoClickable:X,logoHidden:Te,isMobile:te!=null?te:ue,failoverHosts:qe,fullScreenTarget:me,saveRate:ie,shadowRootContainer:this.shadowRootContainer,showMiniTimer:N,outerContainerRef:this.rootContainer,showNextPrevButtons:this.needToShowNextPrevButtons(),nextButtonActive:this.isNextButtonActive(),prevButtonActive:this.isPrevButtonActive(),endScreenVideoTitle:we.nextVideoTitle,endScreenVideoThumb:we.nextVideoThumb,isOneVideoPlaylist:this.isOneVideoPlaylist(),playPrevChapter:()=>this.playPrevChapter(),seekToInteractive:()=>this.seekToInteractive(),volumeMultiplier:We,showEndScreen:ee,showAutoplayNext:ke,adsExternalApi:q,adsJson:Le,getVideoDeeplink:this.videoConfig.getVideoDeeplink},!0);let Si={target:this.playerContainer,props:n(Gn)};this.svelteRootComponent=Jr(Rv,Si),this.addPlayerInfoSubscriptions(),this.isInited||(this.isInited=!0,(ui=(at=(pi=this.videoConfig)==null?void 0:pi.callbacks)==null?void 0:at.onInited)==null||ui.call(at)),(ao=this.internalsExposure)==null||ao.expose({player:this,videoConfig:this.videoConfig,coreConfig:this.coreConfig,uiConfig:this.uiConfig,statisticsConfig:this.statisticsConfig,logger:this.logger,log:this.log}),this.uiConfig.devNullLog&&((Ct=(St=this.videoConfig)==null?void 0:St.callbacks)!=null&&Ct.onDevNullLog)?kc.subscribe("ui",this.videoConfig.callbacks.onDevNullLog):kc.destroy("ui")};this.coreConfig.asyncResolveClientChecker?s$.isInited$.subscribe(pi=>{pi&&(console.log("UI SDK async start"),so())}):so()}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&&qv(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 _p(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?$e(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]=FI(Ks({},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,k,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(Pd)),I==="action-choice-canceled"){let j=$e(this.store.state.isPlaying$)||U;if(((P=(R=this.videoConfig)==null?void 0:R.isTouch)!=null?P:(k=this.videoConfig)!=null&&k.isMobile)&&j){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(Pd)})),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,k,P;C.length&&((P=(k=(R=this.videoConfig)==null?void 0:R.callbacks)==null?void 0:k.onInteractiveHistoryChanged)==null||P.call(k,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,k;(k=(C=this.videoConfig)==null?void 0:(R=C.callbacks).onInteractiveChapterChanged)==null||k.call(R,I.chapter,I.manifestVideo)})),this.uiConfig.features.interactiveTimeIndicator&&this.subscription.add(this.interactiveController.events.noInteraction$.subscribe(()=>{var I,C,R,k;(I=this.microStoresRoot)==null||I.stores.showInteractiveTimeIndicatorTooltip$.set(!0,!0),(k=(C=this.videoConfig)==null?void 0:(R=C.callbacks).onInteractiveTimeIndicatorClick)==null||k.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,k,P,E,W,F,U,j,se;if(!this.isConnected){this.postponedInitParams=[e,t];return}if(!Array.isArray(e.videos)||e.videos.length===0&&!e.interactiveData){let G=new Error("empty videos");this.fatalError$.next(G),(r=(o=e.callbacks)==null?void 0:o.onCrashed)==null||r.call(o,G.message);return}else this.fatalError$.next(null);if(this.videoConfig=wc(iE,WI(e,G=>G instanceof Kv?G:void 0)),this.playerId=XI(e.playerId),this.uiConfig=Nh((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 YI("ui",this.playerId))),kc.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:[UI()]}),qv(this.videoConfig.isMediaSessionEnabled)&&(this.uiConfig.features.mediaSession=(v=(p=this.uiConfig.features.mediaSession)!=null?p:this.videoConfig.isMediaSessionEnabled)!=null?v:!0),qv(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=Ks({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,(k=this.videoConfig).autoplay&&(k.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&&((j=this.videoConfig.videos)!=null&&j[this.videoConfig.videoIndex])?this.videoConfig.videoIndex:0,this.needToRepeatPlaylist=this.videoConfig.repeat,this.uiConfig.features.pip){let G={enabled:this.videoConfig.pipEnabled};this.uiConfig.features.dpip?this.pictureInPictureApi=pp.getLatestSupportedVersion(G):this.pictureInPictureApi=new Bs(G)}this.mediaSessionApi=this.uiConfig.features.mediaSession?new up:void 0,this.slotsApi=this.uiConfig.features.slots?new ap(this.uiConfig.disabledSlotIds):void 0,this.annotationsApi=this.uiConfig.features.annotations?new fp(this.uiConfig.features.annotationsInside):void 0,this.annotationsApi&&!this.uiConfig.features.annotationsInside&&this.annotationsApi.init(this.rootContainer),this.focusManager=this._shadowRoot?new hp(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]),Xb(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(Gn)&&(n(Gn).showNextPrevButtons=this.needToShowNextPrevButtons(),n(Gn).nextButtonActive=this.isNextButtonActive(),n(Gn).prevButtonActive=this.isPrevButtonActive(),n(Gn).endScreenVideoTitle=o.nextVideoTitle,n(Gn).endScreenVideoThumb=o.nextVideoThumb,n(Gn).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}=Ks({},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(Gn)&&(n(Gn).needToRepeatPlaylist=this.needToRepeatPlaylist,n(Gn).showNextPrevButtons=this.needToShowNextPrevButtons(),n(Gn).nextButtonActive=this.isNextButtonActive(),n(Gn).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 _p(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 _p(this,null,function*(){var t,o;if(this.interactiveController&&((t=this.store)!=null&&t.state.positionExact$)){let r=$e(this.store.state.positionExact$),l=$e(this.store.state.interactiveEpisodes$).find(s=>!s.completed);this.interactiveController.events.playerChanged$.pipe(GI()).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&&Ra(e)}};import{InterfaceLanguage as Qne,VKNumericLanguage as Gne,loadVKLangPack as Yne}from"@vkontakte/videoplayer-shared/es2015";import{VideoQuality as Xne,VideoFormat as Zne}from"@vkontakte/videoplayer-core/es2015";var Bne=()=>{window.customElements.define("vk-video-player",bp)};export{Xu as ControlButtonType,_s as GridTypes,Qne as InterfaceLanguage,Hd as MenuItemType,bs as PlayerPhase,Ll as VERSION,Gne as VKNumericLanguage,Zne as VideoFormat,Xne as VideoQuality,Yne as loadVKLangPack,Bne as registerPlayerWebComponent};