-
Notifications
You must be signed in to change notification settings - Fork 490
/
Copy pathwav-worker.min.js
5 lines (5 loc) · 24.7 KB
/
wav-worker.min.js
1
2
3
4
5
/*!
* lex-web-ui v0.21.7
* (c) 2017-2021 Amazon.com, Inc. or its affiliates. All Rights Reserved.
* Released under the Amazon Software License.
*/(()=>{var t={9306:(t,r,e)=>{"use strict";var n=e(4901),o=e(6823),i=TypeError;t.exports=function(t){if(n(t))return t;throw new i(o(t)+" is not a function")}},3506:(t,r,e)=>{"use strict";var n=e(3925),o=String,i=TypeError;t.exports=function(t){if(n(t))return t;throw new i("Can't set "+o(t)+" as a prototype")}},8551:(t,r,e)=>{"use strict";var n=e(34),o=String,i=TypeError;t.exports=function(t){if(n(t))return t;throw new i(o(t)+" is not an object")}},7811:t=>{"use strict";t.exports="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof DataView},7394:(t,r,e)=>{"use strict";var n=e(4576),o=e(6706),i=e(2195),u=n.ArrayBuffer,s=n.TypeError;t.exports=u&&o(u.prototype,"byteLength","get")||function(t){if("ArrayBuffer"!==i(t))throw new s("ArrayBuffer expected");return t.byteLength}},3238:(t,r,e)=>{"use strict";var n=e(4576),o=e(7476),i=e(7394),u=n.ArrayBuffer,s=u&&u.prototype,c=s&&o(s.slice);t.exports=function(t){if(0!==i(t))return!1;if(!c)return!1;try{return c(t,0,0),!1}catch(r){return!0}}},5169:(t,r,e)=>{"use strict";var n=e(3238),o=TypeError;t.exports=function(t){if(n(t))throw new o("ArrayBuffer is detached");return t}},5636:(t,r,e)=>{"use strict";var n=e(4576),o=e(9504),i=e(6706),u=e(7696),s=e(5169),c=e(7394),a=e(4483),f=e(1548),p=n.structuredClone,y=n.ArrayBuffer,l=n.DataView,v=Math.min,h=y.prototype,g=l.prototype,d=o(h.slice),b=i(h,"resizable","get"),x=i(h,"maxByteLength","get"),w=o(g.getInt8),m=o(g.setInt8);t.exports=(f||a)&&function(t,r,e){var n,o=c(t),i=void 0===r?o:u(r),h=!b||!b(t);if(s(t),f&&(t=p(t,{transfer:[t]}),o===i&&(e||h)))return t;if(o>=i&&(!e||h))n=d(t,0,i);else{var g=e&&!h&&x?{maxByteLength:x(t)}:void 0;n=new y(i,g);for(var A=new l(t),O=new l(n),T=v(i,o),S=0;S<T;S++)m(O,S,w(A,S))}return f||a(t),n}},4644:(t,r,e)=>{"use strict";var n,o,i,u=e(7811),s=e(3724),c=e(4576),a=e(4901),f=e(34),p=e(9297),y=e(6955),l=e(6823),v=e(6699),h=e(6840),g=e(2106),d=e(1625),b=e(2787),x=e(2967),w=e(8227),m=e(3392),A=e(1181),O=A.enforce,T=A.get,S=c.Int8Array,j=S&&S.prototype,E=c.Uint8ClampedArray,B=E&&E.prototype,P=S&&b(S),C=j&&b(j),M=Object.prototype,_=c.TypeError,D=w("toStringTag"),I=m("TYPED_ARRAY_TAG"),U="TypedArrayConstructor",R=u&&!!x&&"Opera"!==y(c.opera),k=!1,F={Int8Array:1,Uint8Array:1,Uint8ClampedArray:1,Int16Array:2,Uint16Array:2,Int32Array:4,Uint32Array:4,Float32Array:4,Float64Array:8},L={BigInt64Array:8,BigUint64Array:8},N=function(t){if(!f(t))return!1;var r=y(t);return"DataView"===r||p(F,r)||p(L,r)},W=function(t){var r=b(t);if(f(r)){var e=T(r);return e&&p(e,U)?e[U]:W(r)}},z=function(t){if(!f(t))return!1;var r=y(t);return p(F,r)||p(L,r)},V=function(t){if(z(t))return t;throw new _("Target is not a typed array")},q=function(t){if(a(t)&&(!x||d(P,t)))return t;throw new _(l(t)+" is not a typed array constructor")},Y=function(t,r,e,n){if(s){if(e)for(var o in F){var i=c[o];if(i&&p(i.prototype,t))try{delete i.prototype[t]}catch(u){try{i.prototype[t]=r}catch(a){}}}C[t]&&!e||h(C,t,e?r:R&&j[t]||r,n)}},G=function(t,r,e){var n,o;if(s){if(x){if(e)for(n in F)if(o=c[n],o&&p(o,t))try{delete o[t]}catch(i){}if(P[t]&&!e)return;try{return h(P,t,e?r:R&&P[t]||r)}catch(i){}}for(n in F)o=c[n],!o||o[t]&&!e||h(o,t,r)}};for(n in F)o=c[n],i=o&&o.prototype,i?O(i)[U]=o:R=!1;for(n in L)o=c[n],i=o&&o.prototype,i&&(O(i)[U]=o);if((!R||!a(P)||P===Function.prototype)&&(P=function(){throw new _("Incorrect invocation")},R))for(n in F)c[n]&&x(c[n],P);if((!R||!C||C===M)&&(C=P.prototype,R))for(n in F)c[n]&&x(c[n].prototype,C);if(R&&b(B)!==C&&x(B,C),s&&!p(C,D))for(n in k=!0,g(C,D,{configurable:!0,get:function(){return f(this)?this[I]:void 0}}),F)c[n]&&v(c[n],I,n);t.exports={NATIVE_ARRAY_BUFFER_VIEWS:R,TYPED_ARRAY_TAG:k&&I,aTypedArray:V,aTypedArrayConstructor:q,exportTypedArrayMethod:Y,exportTypedArrayStaticMethod:G,getTypedArrayConstructor:W,isView:N,isTypedArray:z,TypedArray:P,TypedArrayPrototype:C}},5370:(t,r,e)=>{"use strict";var n=e(6198);t.exports=function(t,r,e){var o=0,i=arguments.length>2?e:n(r),u=new t(i);while(i>o)u[o]=r[o++];return u}},9617:(t,r,e)=>{"use strict";var n=e(5397),o=e(5610),i=e(6198),u=function(t){return function(r,e,u){var s=n(r),c=i(s);if(0===c)return!t&&-1;var a,f=o(u,c);if(t&&e!==e){while(c>f)if(a=s[f++],a!==a)return!0}else for(;c>f;f++)if((t||f in s)&&s[f]===e)return t||f||0;return!t&&-1}};t.exports={includes:u(!0),indexOf:u(!1)}},4527:(t,r,e)=>{"use strict";var n=e(3724),o=e(4376),i=TypeError,u=Object.getOwnPropertyDescriptor,s=n&&!function(){if(void 0!==this)return!0;try{Object.defineProperty([],"length",{writable:!1}).length=1}catch(t){return t instanceof TypeError}}();t.exports=s?function(t,r){if(o(t)&&!u(t,"length").writable)throw new i("Cannot set read only .length");return t.length=r}:function(t,r){return t.length=r}},7628:(t,r,e)=>{"use strict";var n=e(6198);t.exports=function(t,r){for(var e=n(t),o=new r(e),i=0;i<e;i++)o[i]=t[e-i-1];return o}},9928:(t,r,e)=>{"use strict";var n=e(6198),o=e(1291),i=RangeError;t.exports=function(t,r,e,u){var s=n(t),c=o(e),a=c<0?s+c:c;if(a>=s||a<0)throw new i("Incorrect index");for(var f=new r(s),p=0;p<s;p++)f[p]=p===a?u:t[p];return f}},2195:(t,r,e)=>{"use strict";var n=e(9504),o=n({}.toString),i=n("".slice);t.exports=function(t){return i(o(t),8,-1)}},6955:(t,r,e)=>{"use strict";var n=e(2140),o=e(4901),i=e(2195),u=e(8227),s=u("toStringTag"),c=Object,a="Arguments"===i(function(){return arguments}()),f=function(t,r){try{return t[r]}catch(e){}};t.exports=n?i:function(t){var r,e,n;return void 0===t?"Undefined":null===t?"Null":"string"==typeof(e=f(r=c(t),s))?e:a?i(r):"Object"===(n=i(r))&&o(r.callee)?"Arguments":n}},7740:(t,r,e)=>{"use strict";var n=e(9297),o=e(5031),i=e(7347),u=e(4913);t.exports=function(t,r,e){for(var s=o(r),c=u.f,a=i.f,f=0;f<s.length;f++){var p=s[f];n(t,p)||e&&n(e,p)||c(t,p,a(r,p))}}},2211:(t,r,e)=>{"use strict";var n=e(9039);t.exports=!n((function(){function t(){}return t.prototype.constructor=null,Object.getPrototypeOf(new t)!==t.prototype}))},6699:(t,r,e)=>{"use strict";var n=e(3724),o=e(4913),i=e(6980);t.exports=n?function(t,r,e){return o.f(t,r,i(1,e))}:function(t,r,e){return t[r]=e,t}},6980:t=>{"use strict";t.exports=function(t,r){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:r}}},2106:(t,r,e)=>{"use strict";var n=e(283),o=e(4913);t.exports=function(t,r,e){return e.get&&n(e.get,r,{getter:!0}),e.set&&n(e.set,r,{setter:!0}),o.f(t,r,e)}},6840:(t,r,e)=>{"use strict";var n=e(4901),o=e(4913),i=e(283),u=e(9433);t.exports=function(t,r,e,s){s||(s={});var c=s.enumerable,a=void 0!==s.name?s.name:r;if(n(e)&&i(e,a,s),s.global)c?t[r]=e:u(r,e);else{try{s.unsafe?t[r]&&(c=!0):delete t[r]}catch(f){}c?t[r]=e:o.f(t,r,{value:e,enumerable:!1,configurable:!s.nonConfigurable,writable:!s.nonWritable})}return t}},9433:(t,r,e)=>{"use strict";var n=e(4576),o=Object.defineProperty;t.exports=function(t,r){try{o(n,t,{value:r,configurable:!0,writable:!0})}catch(e){n[t]=r}return r}},3724:(t,r,e)=>{"use strict";var n=e(9039);t.exports=!n((function(){return 7!==Object.defineProperty({},1,{get:function(){return 7}})[1]}))},4483:(t,r,e)=>{"use strict";var n,o,i,u,s=e(4576),c=e(9429),a=e(1548),f=s.structuredClone,p=s.ArrayBuffer,y=s.MessageChannel,l=!1;if(a)l=function(t){f(t,{transfer:[t]})};else if(p)try{y||(n=c("worker_threads"),n&&(y=n.MessageChannel)),y&&(o=new y,i=new p(2),u=function(t){o.port1.postMessage(null,[t])},2===i.byteLength&&(u(i),0===i.byteLength&&(l=u)))}catch(v){}t.exports=l},4055:(t,r,e)=>{"use strict";var n=e(4576),o=e(34),i=n.document,u=o(i)&&o(i.createElement);t.exports=function(t){return u?i.createElement(t):{}}},6837:t=>{"use strict";var r=TypeError,e=9007199254740991;t.exports=function(t){if(t>e)throw r("Maximum allowed index exceeded");return t}},8727:t=>{"use strict";t.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]},6193:(t,r,e)=>{"use strict";var n=e(4215);t.exports="NODE"===n},2839:(t,r,e)=>{"use strict";var n=e(4576),o=n.navigator,i=o&&o.userAgent;t.exports=i?String(i):""},9519:(t,r,e)=>{"use strict";var n,o,i=e(4576),u=e(2839),s=i.process,c=i.Deno,a=s&&s.versions||c&&c.version,f=a&&a.v8;f&&(n=f.split("."),o=n[0]>0&&n[0]<4?1:+(n[0]+n[1])),!o&&u&&(n=u.match(/Edge\/(\d+)/),(!n||n[1]>=74)&&(n=u.match(/Chrome\/(\d+)/),n&&(o=+n[1]))),t.exports=o},4215:(t,r,e)=>{"use strict";var n=e(4576),o=e(2839),i=e(2195),u=function(t){return o.slice(0,t.length)===t};t.exports=function(){return u("Bun/")?"BUN":u("Cloudflare-Workers")?"CLOUDFLARE":u("Deno/")?"DENO":u("Node.js/")?"NODE":n.Bun&&"string"==typeof Bun.version?"BUN":n.Deno&&"object"==typeof Deno.version?"DENO":"process"===i(n.process)?"NODE":n.window&&n.document?"BROWSER":"REST"}()},6518:(t,r,e)=>{"use strict";var n=e(4576),o=e(7347).f,i=e(6699),u=e(6840),s=e(9433),c=e(7740),a=e(2796);t.exports=function(t,r){var e,f,p,y,l,v,h=t.target,g=t.global,d=t.stat;if(f=g?n:d?n[h]||s(h,{}):n[h]&&n[h].prototype,f)for(p in r){if(l=r[p],t.dontCallGetSet?(v=o(f,p),y=v&&v.value):y=f[p],e=a(g?p:h+(d?".":"#")+p,t.forced),!e&&void 0!==y){if(typeof l==typeof y)continue;c(l,y)}(t.sham||y&&y.sham)&&i(l,"sham",!0),u(f,p,l,t)}}},9039:t=>{"use strict";t.exports=function(t){try{return!!t()}catch(r){return!0}}},616:(t,r,e)=>{"use strict";var n=e(9039);t.exports=!n((function(){var t=function(){}.bind();return"function"!=typeof t||t.hasOwnProperty("prototype")}))},9565:(t,r,e)=>{"use strict";var n=e(616),o=Function.prototype.call;t.exports=n?o.bind(o):function(){return o.apply(o,arguments)}},350:(t,r,e)=>{"use strict";var n=e(3724),o=e(9297),i=Function.prototype,u=n&&Object.getOwnPropertyDescriptor,s=o(i,"name"),c=s&&"something"===function(){}.name,a=s&&(!n||n&&u(i,"name").configurable);t.exports={EXISTS:s,PROPER:c,CONFIGURABLE:a}},6706:(t,r,e)=>{"use strict";var n=e(9504),o=e(9306);t.exports=function(t,r,e){try{return n(o(Object.getOwnPropertyDescriptor(t,r)[e]))}catch(i){}}},7476:(t,r,e)=>{"use strict";var n=e(2195),o=e(9504);t.exports=function(t){if("Function"===n(t))return o(t)}},9504:(t,r,e)=>{"use strict";var n=e(616),o=Function.prototype,i=o.call,u=n&&o.bind.bind(i,i);t.exports=n?u:function(t){return function(){return i.apply(t,arguments)}}},9429:(t,r,e)=>{"use strict";var n=e(4576),o=e(6193);t.exports=function(t){if(o){try{return n.process.getBuiltinModule(t)}catch(r){}try{return Function('return require("'+t+'")')()}catch(r){}}}},7751:(t,r,e)=>{"use strict";var n=e(4576),o=e(4901),i=function(t){return o(t)?t:void 0};t.exports=function(t,r){return arguments.length<2?i(n[t]):n[t]&&n[t][r]}},5966:(t,r,e)=>{"use strict";var n=e(9306),o=e(4117);t.exports=function(t,r){var e=t[r];return o(e)?void 0:n(e)}},4576:function(t,r,e){"use strict";var n=function(t){return t&&t.Math===Math&&t};t.exports=n("object"==typeof globalThis&&globalThis)||n("object"==typeof window&&window)||n("object"==typeof self&&self)||n("object"==typeof e.g&&e.g)||n("object"==typeof this&&this)||function(){return this}()||Function("return this")()},9297:(t,r,e)=>{"use strict";var n=e(9504),o=e(8981),i=n({}.hasOwnProperty);t.exports=Object.hasOwn||function(t,r){return i(o(t),r)}},421:t=>{"use strict";t.exports={}},5917:(t,r,e)=>{"use strict";var n=e(3724),o=e(9039),i=e(4055);t.exports=!n&&!o((function(){return 7!==Object.defineProperty(i("div"),"a",{get:function(){return 7}}).a}))},7055:(t,r,e)=>{"use strict";var n=e(9504),o=e(9039),i=e(2195),u=Object,s=n("".split);t.exports=o((function(){return!u("z").propertyIsEnumerable(0)}))?function(t){return"String"===i(t)?s(t,""):u(t)}:u},3706:(t,r,e)=>{"use strict";var n=e(9504),o=e(4901),i=e(7629),u=n(Function.toString);o(i.inspectSource)||(i.inspectSource=function(t){return u(t)}),t.exports=i.inspectSource},1181:(t,r,e)=>{"use strict";var n,o,i,u=e(8622),s=e(4576),c=e(34),a=e(6699),f=e(9297),p=e(7629),y=e(6119),l=e(421),v="Object already initialized",h=s.TypeError,g=s.WeakMap,d=function(t){return i(t)?o(t):n(t,{})},b=function(t){return function(r){var e;if(!c(r)||(e=o(r)).type!==t)throw new h("Incompatible receiver, "+t+" required");return e}};if(u||p.state){var x=p.state||(p.state=new g);x.get=x.get,x.has=x.has,x.set=x.set,n=function(t,r){if(x.has(t))throw new h(v);return r.facade=t,x.set(t,r),r},o=function(t){return x.get(t)||{}},i=function(t){return x.has(t)}}else{var w=y("state");l[w]=!0,n=function(t,r){if(f(t,w))throw new h(v);return r.facade=t,a(t,w,r),r},o=function(t){return f(t,w)?t[w]:{}},i=function(t){return f(t,w)}}t.exports={set:n,get:o,has:i,enforce:d,getterFor:b}},4376:(t,r,e)=>{"use strict";var n=e(2195);t.exports=Array.isArray||function(t){return"Array"===n(t)}},1108:(t,r,e)=>{"use strict";var n=e(6955);t.exports=function(t){var r=n(t);return"BigInt64Array"===r||"BigUint64Array"===r}},4901:t=>{"use strict";var r="object"==typeof document&&document.all;t.exports="undefined"==typeof r&&void 0!==r?function(t){return"function"==typeof t||t===r}:function(t){return"function"==typeof t}},2796:(t,r,e)=>{"use strict";var n=e(9039),o=e(4901),i=/#|\.prototype\./,u=function(t,r){var e=c[s(t)];return e===f||e!==a&&(o(r)?n(r):!!r)},s=u.normalize=function(t){return String(t).replace(i,".").toLowerCase()},c=u.data={},a=u.NATIVE="N",f=u.POLYFILL="P";t.exports=u},4117:t=>{"use strict";t.exports=function(t){return null===t||void 0===t}},34:(t,r,e)=>{"use strict";var n=e(4901);t.exports=function(t){return"object"==typeof t?null!==t:n(t)}},3925:(t,r,e)=>{"use strict";var n=e(34);t.exports=function(t){return n(t)||null===t}},6395:t=>{"use strict";t.exports=!1},757:(t,r,e)=>{"use strict";var n=e(7751),o=e(4901),i=e(1625),u=e(7040),s=Object;t.exports=u?function(t){return"symbol"==typeof t}:function(t){var r=n("Symbol");return o(r)&&i(r.prototype,s(t))}},6198:(t,r,e)=>{"use strict";var n=e(8014);t.exports=function(t){return n(t.length)}},283:(t,r,e)=>{"use strict";var n=e(9504),o=e(9039),i=e(4901),u=e(9297),s=e(3724),c=e(350).CONFIGURABLE,a=e(3706),f=e(1181),p=f.enforce,y=f.get,l=String,v=Object.defineProperty,h=n("".slice),g=n("".replace),d=n([].join),b=s&&!o((function(){return 8!==v((function(){}),"length",{value:8}).length})),x=String(String).split("String"),w=t.exports=function(t,r,e){"Symbol("===h(l(r),0,7)&&(r="["+g(l(r),/^Symbol\(([^)]*)\).*$/,"$1")+"]"),e&&e.getter&&(r="get "+r),e&&e.setter&&(r="set "+r),(!u(t,"name")||c&&t.name!==r)&&(s?v(t,"name",{value:r,configurable:!0}):t.name=r),b&&e&&u(e,"arity")&&t.length!==e.arity&&v(t,"length",{value:e.arity});try{e&&u(e,"constructor")&&e.constructor?s&&v(t,"prototype",{writable:!1}):t.prototype&&(t.prototype=void 0)}catch(o){}var n=p(t);return u(n,"source")||(n.source=d(x,"string"==typeof r?r:"")),t};Function.prototype.toString=w((function(){return i(this)&&y(this).source||a(this)}),"toString")},741:t=>{"use strict";var r=Math.ceil,e=Math.floor;t.exports=Math.trunc||function(t){var n=+t;return(n>0?e:r)(n)}},4913:(t,r,e)=>{"use strict";var n=e(3724),o=e(5917),i=e(8686),u=e(8551),s=e(6969),c=TypeError,a=Object.defineProperty,f=Object.getOwnPropertyDescriptor,p="enumerable",y="configurable",l="writable";r.f=n?i?function(t,r,e){if(u(t),r=s(r),u(e),"function"===typeof t&&"prototype"===r&&"value"in e&&l in e&&!e[l]){var n=f(t,r);n&&n[l]&&(t[r]=e.value,e={configurable:y in e?e[y]:n[y],enumerable:p in e?e[p]:n[p],writable:!1})}return a(t,r,e)}:a:function(t,r,e){if(u(t),r=s(r),u(e),o)try{return a(t,r,e)}catch(n){}if("get"in e||"set"in e)throw new c("Accessors not supported");return"value"in e&&(t[r]=e.value),t}},7347:(t,r,e)=>{"use strict";var n=e(3724),o=e(9565),i=e(8773),u=e(6980),s=e(5397),c=e(6969),a=e(9297),f=e(5917),p=Object.getOwnPropertyDescriptor;r.f=n?p:function(t,r){if(t=s(t),r=c(r),f)try{return p(t,r)}catch(e){}if(a(t,r))return u(!o(i.f,t,r),t[r])}},8480:(t,r,e)=>{"use strict";var n=e(1828),o=e(8727),i=o.concat("length","prototype");r.f=Object.getOwnPropertyNames||function(t){return n(t,i)}},3717:(t,r)=>{"use strict";r.f=Object.getOwnPropertySymbols},2787:(t,r,e)=>{"use strict";var n=e(9297),o=e(4901),i=e(8981),u=e(6119),s=e(2211),c=u("IE_PROTO"),a=Object,f=a.prototype;t.exports=s?a.getPrototypeOf:function(t){var r=i(t);if(n(r,c))return r[c];var e=r.constructor;return o(e)&&r instanceof e?e.prototype:r instanceof a?f:null}},1625:(t,r,e)=>{"use strict";var n=e(9504);t.exports=n({}.isPrototypeOf)},1828:(t,r,e)=>{"use strict";var n=e(9504),o=e(9297),i=e(5397),u=e(9617).indexOf,s=e(421),c=n([].push);t.exports=function(t,r){var e,n=i(t),a=0,f=[];for(e in n)!o(s,e)&&o(n,e)&&c(f,e);while(r.length>a)o(n,e=r[a++])&&(~u(f,e)||c(f,e));return f}},8773:(t,r)=>{"use strict";var e={}.propertyIsEnumerable,n=Object.getOwnPropertyDescriptor,o=n&&!e.call({1:2},1);r.f=o?function(t){var r=n(this,t);return!!r&&r.enumerable}:e},2967:(t,r,e)=>{"use strict";var n=e(6706),o=e(34),i=e(7750),u=e(3506);t.exports=Object.setPrototypeOf||("__proto__"in{}?function(){var t,r=!1,e={};try{t=n(Object.prototype,"__proto__","set"),t(e,[]),r=e instanceof Array}catch(s){}return function(e,n){return i(e),u(n),o(e)?(r?t(e,n):e.__proto__=n,e):e}}():void 0)},4270:(t,r,e)=>{"use strict";var n=e(9565),o=e(4901),i=e(34),u=TypeError;t.exports=function(t,r){var e,s;if("string"===r&&o(e=t.toString)&&!i(s=n(e,t)))return s;if(o(e=t.valueOf)&&!i(s=n(e,t)))return s;if("string"!==r&&o(e=t.toString)&&!i(s=n(e,t)))return s;throw new u("Can't convert object to primitive value")}},5031:(t,r,e)=>{"use strict";var n=e(7751),o=e(9504),i=e(8480),u=e(3717),s=e(8551),c=o([].concat);t.exports=n("Reflect","ownKeys")||function(t){var r=i.f(s(t)),e=u.f;return e?c(r,e(t)):r}},7750:(t,r,e)=>{"use strict";var n=e(4117),o=TypeError;t.exports=function(t){if(n(t))throw new o("Can't call method on "+t);return t}},6119:(t,r,e)=>{"use strict";var n=e(5745),o=e(3392),i=n("keys");t.exports=function(t){return i[t]||(i[t]=o(t))}},7629:(t,r,e)=>{"use strict";var n=e(6395),o=e(4576),i=e(9433),u="__core-js_shared__",s=t.exports=o[u]||i(u,{});(s.versions||(s.versions=[])).push({version:"3.39.0",mode:n?"pure":"global",copyright:"© 2014-2024 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.39.0/LICENSE",source:"https://github.com/zloirock/core-js"})},5745:(t,r,e)=>{"use strict";var n=e(7629);t.exports=function(t,r){return n[t]||(n[t]=r||{})}},1548:(t,r,e)=>{"use strict";var n=e(4576),o=e(9039),i=e(9519),u=e(4215),s=n.structuredClone;t.exports=!!s&&!o((function(){if("DENO"===u&&i>92||"NODE"===u&&i>94||"BROWSER"===u&&i>97)return!1;var t=new ArrayBuffer(8),r=s(t,{transfer:[t]});return 0!==t.byteLength||8!==r.byteLength}))},4495:(t,r,e)=>{"use strict";var n=e(9519),o=e(9039),i=e(4576),u=i.String;t.exports=!!Object.getOwnPropertySymbols&&!o((function(){var t=Symbol("symbol detection");return!u(t)||!(Object(t)instanceof Symbol)||!Symbol.sham&&n&&n<41}))},5610:(t,r,e)=>{"use strict";var n=e(1291),o=Math.max,i=Math.min;t.exports=function(t,r){var e=n(t);return e<0?o(e+r,0):i(e,r)}},5854:(t,r,e)=>{"use strict";var n=e(2777),o=TypeError;t.exports=function(t){var r=n(t,"number");if("number"==typeof r)throw new o("Can't convert number to bigint");return BigInt(r)}},7696:(t,r,e)=>{"use strict";var n=e(1291),o=e(8014),i=RangeError;t.exports=function(t){if(void 0===t)return 0;var r=n(t),e=o(r);if(r!==e)throw new i("Wrong length or index");return e}},5397:(t,r,e)=>{"use strict";var n=e(7055),o=e(7750);t.exports=function(t){return n(o(t))}},1291:(t,r,e)=>{"use strict";var n=e(741);t.exports=function(t){var r=+t;return r!==r||0===r?0:n(r)}},8014:(t,r,e)=>{"use strict";var n=e(1291),o=Math.min;t.exports=function(t){var r=n(t);return r>0?o(r,9007199254740991):0}},8981:(t,r,e)=>{"use strict";var n=e(7750),o=Object;t.exports=function(t){return o(n(t))}},2777:(t,r,e)=>{"use strict";var n=e(9565),o=e(34),i=e(757),u=e(5966),s=e(4270),c=e(8227),a=TypeError,f=c("toPrimitive");t.exports=function(t,r){if(!o(t)||i(t))return t;var e,c=u(t,f);if(c){if(void 0===r&&(r="default"),e=n(c,t,r),!o(e)||i(e))return e;throw new a("Can't convert object to primitive value")}return void 0===r&&(r="number"),s(t,r)}},6969:(t,r,e)=>{"use strict";var n=e(2777),o=e(757);t.exports=function(t){var r=n(t,"string");return o(r)?r:r+""}},2140:(t,r,e)=>{"use strict";var n=e(8227),o=n("toStringTag"),i={};i[o]="z",t.exports="[object z]"===String(i)},6823:t=>{"use strict";var r=String;t.exports=function(t){try{return r(t)}catch(e){return"Object"}}},3392:(t,r,e)=>{"use strict";var n=e(9504),o=0,i=Math.random(),u=n(1..toString);t.exports=function(t){return"Symbol("+(void 0===t?"":t)+")_"+u(++o+i,36)}},7040:(t,r,e)=>{"use strict";var n=e(4495);t.exports=n&&!Symbol.sham&&"symbol"==typeof Symbol.iterator},8686:(t,r,e)=>{"use strict";var n=e(3724),o=e(9039);t.exports=n&&o((function(){return 42!==Object.defineProperty((function(){}),"prototype",{value:42,writable:!1}).prototype}))},8622:(t,r,e)=>{"use strict";var n=e(4576),o=e(4901),i=n.WeakMap;t.exports=o(i)&&/native code/.test(String(i))},8227:(t,r,e)=>{"use strict";var n=e(4576),o=e(5745),i=e(9297),u=e(3392),s=e(4495),c=e(7040),a=n.Symbol,f=o("wks"),p=c?a["for"]||a:a&&a.withoutSetter||u;t.exports=function(t){return i(f,t)||(f[t]=s&&i(a,t)?a[t]:p("Symbol."+t)),f[t]}},6573:(t,r,e)=>{"use strict";var n=e(3724),o=e(2106),i=e(3238),u=ArrayBuffer.prototype;n&&!("detached"in u)&&o(u,"detached",{configurable:!0,get:function(){return i(this)}})},7936:(t,r,e)=>{"use strict";var n=e(6518),o=e(5636);o&&n({target:"ArrayBuffer",proto:!0},{transferToFixedLength:function(){return o(this,arguments.length?arguments[0]:void 0,!1)}})},8100:(t,r,e)=>{"use strict";var n=e(6518),o=e(5636);o&&n({target:"ArrayBuffer",proto:!0},{transfer:function(){return o(this,arguments.length?arguments[0]:void 0,!0)}})},4114:(t,r,e)=>{"use strict";var n=e(6518),o=e(8981),i=e(6198),u=e(4527),s=e(6837),c=e(9039),a=c((function(){return 4294967297!==[].push.call({length:4294967296},1)})),f=function(){try{Object.defineProperty([],"length",{writable:!1}).push()}catch(t){return t instanceof TypeError}},p=a||!f();n({target:"Array",proto:!0,arity:1,forced:p},{push:function(t){var r=o(this),e=i(r),n=arguments.length;s(e+n);for(var c=0;c<n;c++)r[e]=arguments[c],e++;return u(r,e),e}})},7467:(t,r,e)=>{"use strict";var n=e(7628),o=e(4644),i=o.aTypedArray,u=o.exportTypedArrayMethod,s=o.getTypedArrayConstructor;u("toReversed",(function(){return n(i(this),s(this))}))},4732:(t,r,e)=>{"use strict";var n=e(4644),o=e(9504),i=e(9306),u=e(5370),s=n.aTypedArray,c=n.getTypedArrayConstructor,a=n.exportTypedArrayMethod,f=o(n.TypedArrayPrototype.sort);a("toSorted",(function(t){void 0!==t&&i(t);var r=s(this),e=u(c(r),r);return f(e,t)}))},9577:(t,r,e)=>{"use strict";var n=e(9928),o=e(4644),i=e(1108),u=e(1291),s=e(5854),c=o.aTypedArray,a=o.getTypedArrayConstructor,f=o.exportTypedArrayMethod,p=!!function(){try{new Int8Array(1)["with"](2,{valueOf:function(){throw 8}})}catch(t){return 8===t}}();f("with",{with:function(t,r){var e=c(this),o=u(t),f=i(e)?s(r):+r;return n(e,a(e),o,f)}}["with"],!p)}},r={};function e(n){var o=r[n];if(void 0!==o)return o.exports;var i=r[n]={exports:{}};return t[n].call(i.exports,i,i.exports,e),i.exports}(()=>{e.g=function(){if("object"===typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(t){if("object"===typeof window)return window}}()})();e(4114),e(6573),e(8100),e(7936),e(7467),e(4732),e(9577);const n=16,o=n/8,i=16e3,u=1;let s=0,c=[];const a={sampleRate:44e3,numChannels:1,useDownsample:!0,useTrim:!0,quietTrimThreshold:8e-4,quietTrimSlackBack:4e3};function f(t){Object.assign(a,t),h()}function p(t){for(let r=0;r<a.numChannels;r++)c[r].push(t[r]);s+=t[0].length}function y(t){const r=[];for(let i=0;i<a.numChannels;i++)r.push(g(c[i],s));let e;e=2===a.numChannels&&2===u?d(r[0],r[1]):r[0];const n=m(e,i),o=w(n),f=new Blob([o],{type:t});self.postMessage({command:"exportWAV",data:f})}function l(){const t=[];for(let r=0;r<a.numChannels;r++)t.push(g(c[r],s));self.postMessage({command:"getBuffer",data:t})}function v(){s=0,c=[],h()}function h(){for(let t=0;t<a.numChannels;t++)c[t]=[]}function g(t,r){const e=new Float32Array(r);let n=0;for(let o=0;o<t.length;o++)e.set(t[o],n),n+=t[o].length;return e}function d(t,r){const e=t.length+r.length,n=new Float32Array(e);let o=0,i=0;while(o<e)n[o++]=t[i],n[o++]=r[i],i++;return n}function b(t,r,e){for(let n=0,o=r;n<e.length;n++,o+=2){const r=Math.max(-1,Math.min(1,e[n]));t.setInt16(o,r<0?32768*r:32767*r,!0)}}function x(t,r){t.setUint32(0,1380533830,!1),t.setUint32(4,36+r,!0),t.setUint32(8,1463899717,!1),t.setUint32(12,1718449184,!1),t.setUint32(16,16,!0),t.setUint16(20,1,!0),t.setUint16(22,u,!0),t.setUint32(24,i,!0),t.setUint32(28,i*o*u,!0),t.setUint16(32,o*u,!0),t.setUint16(34,n,!0),t.setUint32(36,1684108385,!1)}function w(t){const r=new ArrayBuffer(44+2*t.length),e=new DataView(r);return x(e,t.length),b(e,44,t),e}function m(t,r){if(r===a.sampleRate)return t;const e=t.length,n=a.sampleRate/r,o=Math.round(e/n),i=new Float32Array(o);let u=0,s=0,c=0,f=e;while(u<i.length){const r=Math.round((u+1)*n);let o=0,p=0;for(let n=s;n<r&&n<e;n++)o+=t[n],p++;o>a.quietTrimThreshold&&(0===c&&(c=u),f=u),i[u]=o/p,u++,s=r}return a.useTrim?i.slice(Math.max(0,c-a.quietTrimSlackBack),Math.min(o,f+a.quietTrimSlackBack)):i}self.onmessage=t=>{switch(t.data.command){case"init":f(t.data.config);break;case"record":p(t.data.buffer);break;case"exportWav":y(t.data.type);break;case"getBuffer":l();break;case"clear":v();break;case"close":self.close();break;default:break}}})();