"use strict";(globalThis.webpackChunkscrollsequence2=globalThis.webpackChunkscrollsequence2||[]).push([[970],{970:(e,s,t)=>{var a;t.r(s),t.d(s,{FFFSType:()=>n,FFmpeg:()=>E}),function(e){e.LOAD="LOAD",e.EXEC="EXEC",e.FFPROBE="FFPROBE",e.WRITE_FILE="WRITE_FILE",e.READ_FILE="READ_FILE",e.DELETE_FILE="DELETE_FILE",e.RENAME="RENAME",e.CREATE_DIR="CREATE_DIR",e.LIST_DIR="LIST_DIR",e.DELETE_DIR="DELETE_DIR",e.ERROR="ERROR",e.DOWNLOAD="DOWNLOAD",e.PROGRESS="PROGRESS",e.LOG="LOG",e.MOUNT="MOUNT",e.UNMOUNT="UNMOUNT"}(a||(a={}));const r=(()=>{let e=0;return()=>e++})(),i=(new Error("unknown message type"),new Error("ffmpeg is not loaded, call `await ffmpeg.load()` first")),o=new Error("called FFmpeg.terminate()");new Error("failed to import ffmpeg-core.js");class E{#e=null;#s={};#t={};#a=[];#r=[];loaded=!1;#i=()=>{this.#e&&(this.#e.onmessage=({data:{id:e,type:s,data:t}})=>{switch(s){case a.LOAD:this.loaded=!0,this.#s[e](t);break;case a.MOUNT:case a.UNMOUNT:case a.EXEC:case a.FFPROBE:case a.WRITE_FILE:case a.READ_FILE:case a.DELETE_FILE:case a.RENAME:case a.CREATE_DIR:case a.LIST_DIR:case a.DELETE_DIR:this.#s[e](t);break;case a.LOG:this.#a.forEach((e=>e(t)));break;case a.PROGRESS:this.#r.forEach((e=>e(t)));break;case a.ERROR:this.#t[e](t)}delete this.#s[e],delete this.#t[e]})};#o=({type:e,data:s},t=[],a)=>this.#e?new Promise(((i,o)=>{const E=r();this.#e&&this.#e.postMessage({id:E,type:e,data:s},t),this.#s[E]=i,this.#t[E]=o,a?.addEventListener("abort",(()=>{o(new DOMException(`Message # ${E} was aborted`,"AbortError"))}),{once:!0})})):Promise.reject(i);on(e,s){"log"===e?this.#a.push(s):"progress"===e&&this.#r.push(s)}off(e,s){"log"===e?this.#a=this.#a.filter((e=>e!==s)):"progress"===e&&(this.#r=this.#r.filter((e=>e!==s)))}load=({classWorkerURL:e,...s}={},{signal:r}={})=>(this.#e||(this.#e=e?new Worker(new URL(e,"file:///C:/Users/alesk/Local%20Sites/scrollsequence/app/public/wp-content/plugins/scrollsequence/v2/node_modules/@ffmpeg/ffmpeg/dist/esm/classes.js"),{type:"module"}):new Worker(new URL(t.p+t.u(138),t.b),{type:void 0}),this.#i()),this.#o({type:a.LOAD,data:s},void 0,r));exec=(e,s=-1,{signal:t}={})=>this.#o({type:a.EXEC,data:{args:e,timeout:s}},void 0,t);ffprobe=(e,s=-1,{signal:t}={})=>this.#o({type:a.FFPROBE,data:{args:e,timeout:s}},void 0,t);terminate=()=>{const e=Object.keys(this.#t);for(const s of e)this.#t[s](o),delete this.#t[s],delete this.#s[s];this.#e&&(this.#e.terminate(),this.#e=null,this.loaded=!1)};writeFile=(e,s,{signal:t}={})=>{const r=[];return s instanceof Uint8Array&&r.push(s.buffer),this.#o({type:a.WRITE_FILE,data:{path:e,data:s}},r,t)};mount=(e,s,t)=>this.#o({type:a.MOUNT,data:{fsType:e,options:s,mountPoint:t}},[]);unmount=e=>this.#o({type:a.UNMOUNT,data:{mountPoint:e}},[]);readFile=(e,s="binary",{signal:t}={})=>this.#o({type:a.READ_FILE,data:{path:e,encoding:s}},void 0,t);deleteFile=(e,{signal:s}={})=>this.#o({type:a.DELETE_FILE,data:{path:e}},void 0,s);rename=(e,s,{signal:t}={})=>this.#o({type:a.RENAME,data:{oldPath:e,newPath:s}},void 0,t);createDir=(e,{signal:s}={})=>this.#o({type:a.CREATE_DIR,data:{path:e}},void 0,s);listDir=(e,{signal:s}={})=>this.#o({type:a.LIST_DIR,data:{path:e}},void 0,s);deleteDir=(e,{signal:s}={})=>this.#o({type:a.DELETE_DIR,data:{path:e}},void 0,s)}var n;!function(e){e.MEMFS="MEMFS",e.NODEFS="NODEFS",e.NODERAWFS="NODERAWFS",e.IDBFS="IDBFS",e.WORKERFS="WORKERFS",e.PROXYFS="PROXYFS"}(n||(n={}))}}]);