web/website/control-panel/native-editor/js/worker.50c79144.worker.js
Dev 6deb4a2e7d DuneRealms V2 clean baseline
Owner-authorised history reset; current source tree preserved exactly.
2026-11-13 00:05:14 +01:00

8 lines
No EOL
59 KiB
JavaScript

(function(){var t={6880:function(t){!function(e,r){t.exports=r()}(0,(function(){return function(t){var e={};function r(n){if(e[n])return e[n].exports;var i=e[n]={i:n,l:!1,exports:{}};return t[n].call(i.exports,i,i.exports,r),i.l=!0,i.exports}return r.m=t,r.c=e,r.d=function(t,e,n){r.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:n})},r.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},r.t=function(t,e){if(1&e&&(t=r(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var n=Object.create(null);if(r.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var i in t)r.d(n,i,function(e){return t[e]}.bind(null,i));return n},r.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return r.d(e,"a",e),e},r.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},r.p="",r(r.s=90)}({17:function(t,e,r){"use strict";e.__esModule=!0,e.default=void 0;var n=r(18),i=function(){function t(){}return t.getFirstMatch=function(t,e){var r=e.match(t);return r&&r.length>0&&r[1]||""},t.getSecondMatch=function(t,e){var r=e.match(t);return r&&r.length>1&&r[2]||""},t.matchAndReturnConst=function(t,e,r){if(t.test(e))return r},t.getWindowsVersionName=function(t){switch(t){case"NT":return"NT";case"XP":return"XP";case"NT 5.0":return"2000";case"NT 5.1":return"XP";case"NT 5.2":return"2003";case"NT 6.0":return"Vista";case"NT 6.1":return"7";case"NT 6.2":return"8";case"NT 6.3":return"8.1";case"NT 10.0":return"10";default:return}},t.getMacOSVersionName=function(t){var e=t.split(".").splice(0,2).map((function(t){return parseInt(t,10)||0}));if(e.push(0),10===e[0])switch(e[1]){case 5:return"Leopard";case 6:return"Snow Leopard";case 7:return"Lion";case 8:return"Mountain Lion";case 9:return"Mavericks";case 10:return"Yosemite";case 11:return"El Capitan";case 12:return"Sierra";case 13:return"High Sierra";case 14:return"Mojave";case 15:return"Catalina";default:return}},t.getAndroidVersionName=function(t){var e=t.split(".").splice(0,2).map((function(t){return parseInt(t,10)||0}));if(e.push(0),!(1===e[0]&&e[1]<5))return 1===e[0]&&e[1]<6?"Cupcake":1===e[0]&&e[1]>=6?"Donut":2===e[0]&&e[1]<2?"Eclair":2===e[0]&&2===e[1]?"Froyo":2===e[0]&&e[1]>2?"Gingerbread":3===e[0]?"Honeycomb":4===e[0]&&e[1]<1?"Ice Cream Sandwich":4===e[0]&&e[1]<4?"Jelly Bean":4===e[0]&&e[1]>=4?"KitKat":5===e[0]?"Lollipop":6===e[0]?"Marshmallow":7===e[0]?"Nougat":8===e[0]?"Oreo":9===e[0]?"Pie":void 0},t.getVersionPrecision=function(t){return t.split(".").length},t.compareVersions=function(e,r,n){void 0===n&&(n=!1);var i=t.getVersionPrecision(e),o=t.getVersionPrecision(r),s=Math.max(i,o),a=0,u=t.map([e,r],(function(e){var r=s-t.getVersionPrecision(e),n=e+new Array(r+1).join(".0");return t.map(n.split("."),(function(t){return new Array(20-t.length).join("0")+t})).reverse()}));for(n&&(a=s-Math.min(i,o)),s-=1;s>=a;){if(u[0][s]>u[1][s])return 1;if(u[0][s]===u[1][s]){if(s===a)return 0;s-=1}else if(u[0][s]<u[1][s])return-1}},t.map=function(t,e){var r,n=[];if(Array.prototype.map)return Array.prototype.map.call(t,e);for(r=0;r<t.length;r+=1)n.push(e(t[r]));return n},t.find=function(t,e){var r,n;if(Array.prototype.find)return Array.prototype.find.call(t,e);for(r=0,n=t.length;r<n;r+=1){var i=t[r];if(e(i,r))return i}},t.assign=function(t){for(var e,r,n=t,i=arguments.length,o=new Array(i>1?i-1:0),s=1;s<i;s++)o[s-1]=arguments[s];if(Object.assign)return Object.assign.apply(Object,[t].concat(o));var a=function(){var t=o[e];"object"==typeof t&&null!==t&&Object.keys(t).forEach((function(e){n[e]=t[e]}))};for(e=0,r=o.length;e<r;e+=1)a();return t},t.getBrowserAlias=function(t){return n.BROWSER_ALIASES_MAP[t]},t.getBrowserTypeByAlias=function(t){return n.BROWSER_MAP[t]||""},t}();e.default=i,t.exports=e.default},18:function(t,e,r){"use strict";e.__esModule=!0,e.ENGINE_MAP=e.OS_MAP=e.PLATFORMS_MAP=e.BROWSER_MAP=e.BROWSER_ALIASES_MAP=void 0,e.BROWSER_ALIASES_MAP={"Amazon Silk":"amazon_silk","Android Browser":"android",Bada:"bada",BlackBerry:"blackberry",Chrome:"chrome",Chromium:"chromium",Electron:"electron",Epiphany:"epiphany",Firefox:"firefox",Focus:"focus",Generic:"generic","Google Search":"google_search",Googlebot:"googlebot","Internet Explorer":"ie","K-Meleon":"k_meleon",Maxthon:"maxthon","Microsoft Edge":"edge","MZ Browser":"mz","NAVER Whale Browser":"naver",Opera:"opera","Opera Coast":"opera_coast",PhantomJS:"phantomjs",Puffin:"puffin",QupZilla:"qupzilla",QQ:"qq",QQLite:"qqlite",Safari:"safari",Sailfish:"sailfish","Samsung Internet for Android":"samsung_internet",SeaMonkey:"seamonkey",Sleipnir:"sleipnir",Swing:"swing",Tizen:"tizen","UC Browser":"uc",Vivaldi:"vivaldi","WebOS Browser":"webos",WeChat:"wechat","Yandex Browser":"yandex",Roku:"roku"},e.BROWSER_MAP={amazon_silk:"Amazon Silk",android:"Android Browser",bada:"Bada",blackberry:"BlackBerry",chrome:"Chrome",chromium:"Chromium",electron:"Electron",epiphany:"Epiphany",firefox:"Firefox",focus:"Focus",generic:"Generic",googlebot:"Googlebot",google_search:"Google Search",ie:"Internet Explorer",k_meleon:"K-Meleon",maxthon:"Maxthon",edge:"Microsoft Edge",mz:"MZ Browser",naver:"NAVER Whale Browser",opera:"Opera",opera_coast:"Opera Coast",phantomjs:"PhantomJS",puffin:"Puffin",qupzilla:"QupZilla",qq:"QQ Browser",qqlite:"QQ Browser Lite",safari:"Safari",sailfish:"Sailfish",samsung_internet:"Samsung Internet for Android",seamonkey:"SeaMonkey",sleipnir:"Sleipnir",swing:"Swing",tizen:"Tizen",uc:"UC Browser",vivaldi:"Vivaldi",webos:"WebOS Browser",wechat:"WeChat",yandex:"Yandex Browser"},e.PLATFORMS_MAP={tablet:"tablet",mobile:"mobile",desktop:"desktop",tv:"tv"},e.OS_MAP={WindowsPhone:"Windows Phone",Windows:"Windows",MacOS:"macOS",iOS:"iOS",Android:"Android",WebOS:"WebOS",BlackBerry:"BlackBerry",Bada:"Bada",Tizen:"Tizen",Linux:"Linux",ChromeOS:"Chrome OS",PlayStation4:"PlayStation 4",Roku:"Roku"},e.ENGINE_MAP={EdgeHTML:"EdgeHTML",Blink:"Blink",Trident:"Trident",Presto:"Presto",Gecko:"Gecko",WebKit:"WebKit"}},90:function(t,e,r){"use strict";e.__esModule=!0,e.default=void 0;var n,i=(n=r(91))&&n.__esModule?n:{default:n},o=r(18);function s(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}var a=function(){function t(){}var e,r,n;return t.getParser=function(t,e){if(void 0===e&&(e=!1),"string"!=typeof t)throw new Error("UserAgent should be a string");return new i.default(t,e)},t.parse=function(t){return new i.default(t).getResult()},e=t,n=[{key:"BROWSER_MAP",get:function(){return o.BROWSER_MAP}},{key:"ENGINE_MAP",get:function(){return o.ENGINE_MAP}},{key:"OS_MAP",get:function(){return o.OS_MAP}},{key:"PLATFORMS_MAP",get:function(){return o.PLATFORMS_MAP}}],(r=null)&&s(e.prototype,r),n&&s(e,n),t}();e.default=a,t.exports=e.default},91:function(t,e,r){"use strict";e.__esModule=!0,e.default=void 0;var n=u(r(92)),i=u(r(93)),o=u(r(94)),s=u(r(95)),a=u(r(17));function u(t){return t&&t.__esModule?t:{default:t}}var c=function(){function t(t,e){if(void 0===e&&(e=!1),null==t||""===t)throw new Error("UserAgent parameter can't be empty");this._ua=t,this.parsedResult={},!0!==e&&this.parse()}var e=t.prototype;return e.getUA=function(){return this._ua},e.test=function(t){return t.test(this._ua)},e.parseBrowser=function(){var t=this;this.parsedResult.browser={};var e=a.default.find(n.default,(function(e){if("function"==typeof e.test)return e.test(t);if(e.test instanceof Array)return e.test.some((function(e){return t.test(e)}));throw new Error("Browser's test function is not valid")}));return e&&(this.parsedResult.browser=e.describe(this.getUA())),this.parsedResult.browser},e.getBrowser=function(){return this.parsedResult.browser?this.parsedResult.browser:this.parseBrowser()},e.getBrowserName=function(t){return t?String(this.getBrowser().name).toLowerCase()||"":this.getBrowser().name||""},e.getBrowserVersion=function(){return this.getBrowser().version},e.getOS=function(){return this.parsedResult.os?this.parsedResult.os:this.parseOS()},e.parseOS=function(){var t=this;this.parsedResult.os={};var e=a.default.find(i.default,(function(e){if("function"==typeof e.test)return e.test(t);if(e.test instanceof Array)return e.test.some((function(e){return t.test(e)}));throw new Error("Browser's test function is not valid")}));return e&&(this.parsedResult.os=e.describe(this.getUA())),this.parsedResult.os},e.getOSName=function(t){var e=this.getOS().name;return t?String(e).toLowerCase()||"":e||""},e.getOSVersion=function(){return this.getOS().version},e.getPlatform=function(){return this.parsedResult.platform?this.parsedResult.platform:this.parsePlatform()},e.getPlatformType=function(t){void 0===t&&(t=!1);var e=this.getPlatform().type;return t?String(e).toLowerCase()||"":e||""},e.parsePlatform=function(){var t=this;this.parsedResult.platform={};var e=a.default.find(o.default,(function(e){if("function"==typeof e.test)return e.test(t);if(e.test instanceof Array)return e.test.some((function(e){return t.test(e)}));throw new Error("Browser's test function is not valid")}));return e&&(this.parsedResult.platform=e.describe(this.getUA())),this.parsedResult.platform},e.getEngine=function(){return this.parsedResult.engine?this.parsedResult.engine:this.parseEngine()},e.getEngineName=function(t){return t?String(this.getEngine().name).toLowerCase()||"":this.getEngine().name||""},e.parseEngine=function(){var t=this;this.parsedResult.engine={};var e=a.default.find(s.default,(function(e){if("function"==typeof e.test)return e.test(t);if(e.test instanceof Array)return e.test.some((function(e){return t.test(e)}));throw new Error("Browser's test function is not valid")}));return e&&(this.parsedResult.engine=e.describe(this.getUA())),this.parsedResult.engine},e.parse=function(){return this.parseBrowser(),this.parseOS(),this.parsePlatform(),this.parseEngine(),this},e.getResult=function(){return a.default.assign({},this.parsedResult)},e.satisfies=function(t){var e=this,r={},n=0,i={},o=0;if(Object.keys(t).forEach((function(e){var s=t[e];"string"==typeof s?(i[e]=s,o+=1):"object"==typeof s&&(r[e]=s,n+=1)})),n>0){var s=Object.keys(r),u=a.default.find(s,(function(t){return e.isOS(t)}));if(u){var c=this.satisfies(r[u]);if(void 0!==c)return c}var f=a.default.find(s,(function(t){return e.isPlatform(t)}));if(f){var l=this.satisfies(r[f]);if(void 0!==l)return l}}if(o>0){var d=Object.keys(i),p=a.default.find(d,(function(t){return e.isBrowser(t,!0)}));if(void 0!==p)return this.compareVersion(i[p])}},e.isBrowser=function(t,e){void 0===e&&(e=!1);var r=this.getBrowserName().toLowerCase(),n=t.toLowerCase(),i=a.default.getBrowserTypeByAlias(n);return e&&i&&(n=i.toLowerCase()),n===r},e.compareVersion=function(t){var e=[0],r=t,n=!1,i=this.getBrowserVersion();if("string"==typeof i)return">"===t[0]||"<"===t[0]?(r=t.substr(1),"="===t[1]?(n=!0,r=t.substr(2)):e=[],">"===t[0]?e.push(1):e.push(-1)):"="===t[0]?r=t.substr(1):"~"===t[0]&&(n=!0,r=t.substr(1)),e.indexOf(a.default.compareVersions(i,r,n))>-1},e.isOS=function(t){return this.getOSName(!0)===String(t).toLowerCase()},e.isPlatform=function(t){return this.getPlatformType(!0)===String(t).toLowerCase()},e.isEngine=function(t){return this.getEngineName(!0)===String(t).toLowerCase()},e.is=function(t,e){return void 0===e&&(e=!1),this.isBrowser(t,e)||this.isOS(t)||this.isPlatform(t)},e.some=function(t){var e=this;return void 0===t&&(t=[]),t.some((function(t){return e.is(t)}))},t}();e.default=c,t.exports=e.default},92:function(t,e,r){"use strict";e.__esModule=!0,e.default=void 0;var n,i=(n=r(17))&&n.__esModule?n:{default:n},o=/version\/(\d+(\.?_?\d+)+)/i,s=[{test:[/googlebot/i],describe:function(t){var e={name:"Googlebot"},r=i.default.getFirstMatch(/googlebot\/(\d+(\.\d+))/i,t)||i.default.getFirstMatch(o,t);return r&&(e.version=r),e}},{test:[/opera/i],describe:function(t){var e={name:"Opera"},r=i.default.getFirstMatch(o,t)||i.default.getFirstMatch(/(?:opera)[\s/](\d+(\.?_?\d+)+)/i,t);return r&&(e.version=r),e}},{test:[/opr\/|opios/i],describe:function(t){var e={name:"Opera"},r=i.default.getFirstMatch(/(?:opr|opios)[\s/](\S+)/i,t)||i.default.getFirstMatch(o,t);return r&&(e.version=r),e}},{test:[/SamsungBrowser/i],describe:function(t){var e={name:"Samsung Internet for Android"},r=i.default.getFirstMatch(o,t)||i.default.getFirstMatch(/(?:SamsungBrowser)[\s/](\d+(\.?_?\d+)+)/i,t);return r&&(e.version=r),e}},{test:[/Whale/i],describe:function(t){var e={name:"NAVER Whale Browser"},r=i.default.getFirstMatch(o,t)||i.default.getFirstMatch(/(?:whale)[\s/](\d+(?:\.\d+)+)/i,t);return r&&(e.version=r),e}},{test:[/MZBrowser/i],describe:function(t){var e={name:"MZ Browser"},r=i.default.getFirstMatch(/(?:MZBrowser)[\s/](\d+(?:\.\d+)+)/i,t)||i.default.getFirstMatch(o,t);return r&&(e.version=r),e}},{test:[/focus/i],describe:function(t){var e={name:"Focus"},r=i.default.getFirstMatch(/(?:focus)[\s/](\d+(?:\.\d+)+)/i,t)||i.default.getFirstMatch(o,t);return r&&(e.version=r),e}},{test:[/swing/i],describe:function(t){var e={name:"Swing"},r=i.default.getFirstMatch(/(?:swing)[\s/](\d+(?:\.\d+)+)/i,t)||i.default.getFirstMatch(o,t);return r&&(e.version=r),e}},{test:[/coast/i],describe:function(t){var e={name:"Opera Coast"},r=i.default.getFirstMatch(o,t)||i.default.getFirstMatch(/(?:coast)[\s/](\d+(\.?_?\d+)+)/i,t);return r&&(e.version=r),e}},{test:[/opt\/\d+(?:.?_?\d+)+/i],describe:function(t){var e={name:"Opera Touch"},r=i.default.getFirstMatch(/(?:opt)[\s/](\d+(\.?_?\d+)+)/i,t)||i.default.getFirstMatch(o,t);return r&&(e.version=r),e}},{test:[/yabrowser/i],describe:function(t){var e={name:"Yandex Browser"},r=i.default.getFirstMatch(/(?:yabrowser)[\s/](\d+(\.?_?\d+)+)/i,t)||i.default.getFirstMatch(o,t);return r&&(e.version=r),e}},{test:[/ucbrowser/i],describe:function(t){var e={name:"UC Browser"},r=i.default.getFirstMatch(o,t)||i.default.getFirstMatch(/(?:ucbrowser)[\s/](\d+(\.?_?\d+)+)/i,t);return r&&(e.version=r),e}},{test:[/Maxthon|mxios/i],describe:function(t){var e={name:"Maxthon"},r=i.default.getFirstMatch(o,t)||i.default.getFirstMatch(/(?:Maxthon|mxios)[\s/](\d+(\.?_?\d+)+)/i,t);return r&&(e.version=r),e}},{test:[/epiphany/i],describe:function(t){var e={name:"Epiphany"},r=i.default.getFirstMatch(o,t)||i.default.getFirstMatch(/(?:epiphany)[\s/](\d+(\.?_?\d+)+)/i,t);return r&&(e.version=r),e}},{test:[/puffin/i],describe:function(t){var e={name:"Puffin"},r=i.default.getFirstMatch(o,t)||i.default.getFirstMatch(/(?:puffin)[\s/](\d+(\.?_?\d+)+)/i,t);return r&&(e.version=r),e}},{test:[/sleipnir/i],describe:function(t){var e={name:"Sleipnir"},r=i.default.getFirstMatch(o,t)||i.default.getFirstMatch(/(?:sleipnir)[\s/](\d+(\.?_?\d+)+)/i,t);return r&&(e.version=r),e}},{test:[/k-meleon/i],describe:function(t){var e={name:"K-Meleon"},r=i.default.getFirstMatch(o,t)||i.default.getFirstMatch(/(?:k-meleon)[\s/](\d+(\.?_?\d+)+)/i,t);return r&&(e.version=r),e}},{test:[/micromessenger/i],describe:function(t){var e={name:"WeChat"},r=i.default.getFirstMatch(/(?:micromessenger)[\s/](\d+(\.?_?\d+)+)/i,t)||i.default.getFirstMatch(o,t);return r&&(e.version=r),e}},{test:[/qqbrowser/i],describe:function(t){var e={name:/qqbrowserlite/i.test(t)?"QQ Browser Lite":"QQ Browser"},r=i.default.getFirstMatch(/(?:qqbrowserlite|qqbrowser)[/](\d+(\.?_?\d+)+)/i,t)||i.default.getFirstMatch(o,t);return r&&(e.version=r),e}},{test:[/msie|trident/i],describe:function(t){var e={name:"Internet Explorer"},r=i.default.getFirstMatch(/(?:msie |rv:)(\d+(\.?_?\d+)+)/i,t);return r&&(e.version=r),e}},{test:[/\sedg\//i],describe:function(t){var e={name:"Microsoft Edge"},r=i.default.getFirstMatch(/\sedg\/(\d+(\.?_?\d+)+)/i,t);return r&&(e.version=r),e}},{test:[/edg([ea]|ios)/i],describe:function(t){var e={name:"Microsoft Edge"},r=i.default.getSecondMatch(/edg([ea]|ios)\/(\d+(\.?_?\d+)+)/i,t);return r&&(e.version=r),e}},{test:[/vivaldi/i],describe:function(t){var e={name:"Vivaldi"},r=i.default.getFirstMatch(/vivaldi\/(\d+(\.?_?\d+)+)/i,t);return r&&(e.version=r),e}},{test:[/seamonkey/i],describe:function(t){var e={name:"SeaMonkey"},r=i.default.getFirstMatch(/seamonkey\/(\d+(\.?_?\d+)+)/i,t);return r&&(e.version=r),e}},{test:[/sailfish/i],describe:function(t){var e={name:"Sailfish"},r=i.default.getFirstMatch(/sailfish\s?browser\/(\d+(\.\d+)?)/i,t);return r&&(e.version=r),e}},{test:[/silk/i],describe:function(t){var e={name:"Amazon Silk"},r=i.default.getFirstMatch(/silk\/(\d+(\.?_?\d+)+)/i,t);return r&&(e.version=r),e}},{test:[/phantom/i],describe:function(t){var e={name:"PhantomJS"},r=i.default.getFirstMatch(/phantomjs\/(\d+(\.?_?\d+)+)/i,t);return r&&(e.version=r),e}},{test:[/slimerjs/i],describe:function(t){var e={name:"SlimerJS"},r=i.default.getFirstMatch(/slimerjs\/(\d+(\.?_?\d+)+)/i,t);return r&&(e.version=r),e}},{test:[/blackberry|\bbb\d+/i,/rim\stablet/i],describe:function(t){var e={name:"BlackBerry"},r=i.default.getFirstMatch(o,t)||i.default.getFirstMatch(/blackberry[\d]+\/(\d+(\.?_?\d+)+)/i,t);return r&&(e.version=r),e}},{test:[/(web|hpw)[o0]s/i],describe:function(t){var e={name:"WebOS Browser"},r=i.default.getFirstMatch(o,t)||i.default.getFirstMatch(/w(?:eb)?[o0]sbrowser\/(\d+(\.?_?\d+)+)/i,t);return r&&(e.version=r),e}},{test:[/bada/i],describe:function(t){var e={name:"Bada"},r=i.default.getFirstMatch(/dolfin\/(\d+(\.?_?\d+)+)/i,t);return r&&(e.version=r),e}},{test:[/tizen/i],describe:function(t){var e={name:"Tizen"},r=i.default.getFirstMatch(/(?:tizen\s?)?browser\/(\d+(\.?_?\d+)+)/i,t)||i.default.getFirstMatch(o,t);return r&&(e.version=r),e}},{test:[/qupzilla/i],describe:function(t){var e={name:"QupZilla"},r=i.default.getFirstMatch(/(?:qupzilla)[\s/](\d+(\.?_?\d+)+)/i,t)||i.default.getFirstMatch(o,t);return r&&(e.version=r),e}},{test:[/firefox|iceweasel|fxios/i],describe:function(t){var e={name:"Firefox"},r=i.default.getFirstMatch(/(?:firefox|iceweasel|fxios)[\s/](\d+(\.?_?\d+)+)/i,t);return r&&(e.version=r),e}},{test:[/electron/i],describe:function(t){var e={name:"Electron"},r=i.default.getFirstMatch(/(?:electron)\/(\d+(\.?_?\d+)+)/i,t);return r&&(e.version=r),e}},{test:[/MiuiBrowser/i],describe:function(t){var e={name:"Miui"},r=i.default.getFirstMatch(/(?:MiuiBrowser)[\s/](\d+(\.?_?\d+)+)/i,t);return r&&(e.version=r),e}},{test:[/chromium/i],describe:function(t){var e={name:"Chromium"},r=i.default.getFirstMatch(/(?:chromium)[\s/](\d+(\.?_?\d+)+)/i,t)||i.default.getFirstMatch(o,t);return r&&(e.version=r),e}},{test:[/chrome|crios|crmo/i],describe:function(t){var e={name:"Chrome"},r=i.default.getFirstMatch(/(?:chrome|crios|crmo)\/(\d+(\.?_?\d+)+)/i,t);return r&&(e.version=r),e}},{test:[/GSA/i],describe:function(t){var e={name:"Google Search"},r=i.default.getFirstMatch(/(?:GSA)\/(\d+(\.?_?\d+)+)/i,t);return r&&(e.version=r),e}},{test:function(t){var e=!t.test(/like android/i),r=t.test(/android/i);return e&&r},describe:function(t){var e={name:"Android Browser"},r=i.default.getFirstMatch(o,t);return r&&(e.version=r),e}},{test:[/playstation 4/i],describe:function(t){var e={name:"PlayStation 4"},r=i.default.getFirstMatch(o,t);return r&&(e.version=r),e}},{test:[/safari|applewebkit/i],describe:function(t){var e={name:"Safari"},r=i.default.getFirstMatch(o,t);return r&&(e.version=r),e}},{test:[/.*/i],describe:function(t){var e=-1!==t.search("\\(")?/^(.*)\/(.*)[ \t]\((.*)/:/^(.*)\/(.*) /;return{name:i.default.getFirstMatch(e,t),version:i.default.getSecondMatch(e,t)}}}];e.default=s,t.exports=e.default},93:function(t,e,r){"use strict";e.__esModule=!0,e.default=void 0;var n,i=(n=r(17))&&n.__esModule?n:{default:n},o=r(18),s=[{test:[/Roku\/DVP/],describe:function(t){var e=i.default.getFirstMatch(/Roku\/DVP-(\d+\.\d+)/i,t);return{name:o.OS_MAP.Roku,version:e}}},{test:[/windows phone/i],describe:function(t){var e=i.default.getFirstMatch(/windows phone (?:os)?\s?(\d+(\.\d+)*)/i,t);return{name:o.OS_MAP.WindowsPhone,version:e}}},{test:[/windows /i],describe:function(t){var e=i.default.getFirstMatch(/Windows ((NT|XP)( \d\d?.\d)?)/i,t),r=i.default.getWindowsVersionName(e);return{name:o.OS_MAP.Windows,version:e,versionName:r}}},{test:[/Macintosh(.*?) FxiOS(.*?)\//],describe:function(t){var e={name:o.OS_MAP.iOS},r=i.default.getSecondMatch(/(Version\/)(\d[\d.]+)/,t);return r&&(e.version=r),e}},{test:[/macintosh/i],describe:function(t){var e=i.default.getFirstMatch(/mac os x (\d+(\.?_?\d+)+)/i,t).replace(/[_\s]/g,"."),r=i.default.getMacOSVersionName(e),n={name:o.OS_MAP.MacOS,version:e};return r&&(n.versionName=r),n}},{test:[/(ipod|iphone|ipad)/i],describe:function(t){var e=i.default.getFirstMatch(/os (\d+([_\s]\d+)*) like mac os x/i,t).replace(/[_\s]/g,".");return{name:o.OS_MAP.iOS,version:e}}},{test:function(t){var e=!t.test(/like android/i),r=t.test(/android/i);return e&&r},describe:function(t){var e=i.default.getFirstMatch(/android[\s/-](\d+(\.\d+)*)/i,t),r=i.default.getAndroidVersionName(e),n={name:o.OS_MAP.Android,version:e};return r&&(n.versionName=r),n}},{test:[/(web|hpw)[o0]s/i],describe:function(t){var e=i.default.getFirstMatch(/(?:web|hpw)[o0]s\/(\d+(\.\d+)*)/i,t),r={name:o.OS_MAP.WebOS};return e&&e.length&&(r.version=e),r}},{test:[/blackberry|\bbb\d+/i,/rim\stablet/i],describe:function(t){var e=i.default.getFirstMatch(/rim\stablet\sos\s(\d+(\.\d+)*)/i,t)||i.default.getFirstMatch(/blackberry\d+\/(\d+([_\s]\d+)*)/i,t)||i.default.getFirstMatch(/\bbb(\d+)/i,t);return{name:o.OS_MAP.BlackBerry,version:e}}},{test:[/bada/i],describe:function(t){var e=i.default.getFirstMatch(/bada\/(\d+(\.\d+)*)/i,t);return{name:o.OS_MAP.Bada,version:e}}},{test:[/tizen/i],describe:function(t){var e=i.default.getFirstMatch(/tizen[/\s](\d+(\.\d+)*)/i,t);return{name:o.OS_MAP.Tizen,version:e}}},{test:[/linux/i],describe:function(){return{name:o.OS_MAP.Linux}}},{test:[/CrOS/],describe:function(){return{name:o.OS_MAP.ChromeOS}}},{test:[/PlayStation 4/],describe:function(t){var e=i.default.getFirstMatch(/PlayStation 4[/\s](\d+(\.\d+)*)/i,t);return{name:o.OS_MAP.PlayStation4,version:e}}}];e.default=s,t.exports=e.default},94:function(t,e,r){"use strict";e.__esModule=!0,e.default=void 0;var n,i=(n=r(17))&&n.__esModule?n:{default:n},o=r(18),s=[{test:[/googlebot/i],describe:function(){return{type:"bot",vendor:"Google"}}},{test:[/huawei/i],describe:function(t){var e=i.default.getFirstMatch(/(can-l01)/i,t)&&"Nova",r={type:o.PLATFORMS_MAP.mobile,vendor:"Huawei"};return e&&(r.model=e),r}},{test:[/nexus\s*(?:7|8|9|10).*/i],describe:function(){return{type:o.PLATFORMS_MAP.tablet,vendor:"Nexus"}}},{test:[/ipad/i],describe:function(){return{type:o.PLATFORMS_MAP.tablet,vendor:"Apple",model:"iPad"}}},{test:[/Macintosh(.*?) FxiOS(.*?)\//],describe:function(){return{type:o.PLATFORMS_MAP.tablet,vendor:"Apple",model:"iPad"}}},{test:[/kftt build/i],describe:function(){return{type:o.PLATFORMS_MAP.tablet,vendor:"Amazon",model:"Kindle Fire HD 7"}}},{test:[/silk/i],describe:function(){return{type:o.PLATFORMS_MAP.tablet,vendor:"Amazon"}}},{test:[/tablet(?! pc)/i],describe:function(){return{type:o.PLATFORMS_MAP.tablet}}},{test:function(t){var e=t.test(/ipod|iphone/i),r=t.test(/like (ipod|iphone)/i);return e&&!r},describe:function(t){var e=i.default.getFirstMatch(/(ipod|iphone)/i,t);return{type:o.PLATFORMS_MAP.mobile,vendor:"Apple",model:e}}},{test:[/nexus\s*[0-6].*/i,/galaxy nexus/i],describe:function(){return{type:o.PLATFORMS_MAP.mobile,vendor:"Nexus"}}},{test:[/[^-]mobi/i],describe:function(){return{type:o.PLATFORMS_MAP.mobile}}},{test:function(t){return"blackberry"===t.getBrowserName(!0)},describe:function(){return{type:o.PLATFORMS_MAP.mobile,vendor:"BlackBerry"}}},{test:function(t){return"bada"===t.getBrowserName(!0)},describe:function(){return{type:o.PLATFORMS_MAP.mobile}}},{test:function(t){return"windows phone"===t.getBrowserName()},describe:function(){return{type:o.PLATFORMS_MAP.mobile,vendor:"Microsoft"}}},{test:function(t){var e=Number(String(t.getOSVersion()).split(".")[0]);return"android"===t.getOSName(!0)&&e>=3},describe:function(){return{type:o.PLATFORMS_MAP.tablet}}},{test:function(t){return"android"===t.getOSName(!0)},describe:function(){return{type:o.PLATFORMS_MAP.mobile}}},{test:function(t){return"macos"===t.getOSName(!0)},describe:function(){return{type:o.PLATFORMS_MAP.desktop,vendor:"Apple"}}},{test:function(t){return"windows"===t.getOSName(!0)},describe:function(){return{type:o.PLATFORMS_MAP.desktop}}},{test:function(t){return"linux"===t.getOSName(!0)},describe:function(){return{type:o.PLATFORMS_MAP.desktop}}},{test:function(t){return"playstation 4"===t.getOSName(!0)},describe:function(){return{type:o.PLATFORMS_MAP.tv}}},{test:function(t){return"roku"===t.getOSName(!0)},describe:function(){return{type:o.PLATFORMS_MAP.tv}}}];e.default=s,t.exports=e.default},95:function(t,e,r){"use strict";e.__esModule=!0,e.default=void 0;var n,i=(n=r(17))&&n.__esModule?n:{default:n},o=r(18),s=[{test:function(t){return"microsoft edge"===t.getBrowserName(!0)},describe:function(t){if(/\sedg\//i.test(t))return{name:o.ENGINE_MAP.Blink};var e=i.default.getFirstMatch(/edge\/(\d+(\.?_?\d+)+)/i,t);return{name:o.ENGINE_MAP.EdgeHTML,version:e}}},{test:[/trident/i],describe:function(t){var e={name:o.ENGINE_MAP.Trident},r=i.default.getFirstMatch(/trident\/(\d+(\.?_?\d+)+)/i,t);return r&&(e.version=r),e}},{test:function(t){return t.test(/presto/i)},describe:function(t){var e={name:o.ENGINE_MAP.Presto},r=i.default.getFirstMatch(/presto\/(\d+(\.?_?\d+)+)/i,t);return r&&(e.version=r),e}},{test:function(t){var e=t.test(/gecko/i),r=t.test(/like gecko/i);return e&&!r},describe:function(t){var e={name:o.ENGINE_MAP.Gecko},r=i.default.getFirstMatch(/gecko\/(\d+(\.?_?\d+)+)/i,t);return r&&(e.version=r),e}},{test:[/(apple)?webkit\/537\.36/i],describe:function(){return{name:o.ENGINE_MAP.Blink}}},{test:[/(apple)?webkit/i],describe:function(t){var e={name:o.ENGINE_MAP.WebKit},r=i.default.getFirstMatch(/webkit\/(\d+(\.?_?\d+)+)/i,t);return r&&(e.version=r),e}}];e.default=s,t.exports=e.default}})}))},9306:function(t,e,r){"use strict";var n=r(4901),i=r(6823),o=TypeError;t.exports=function(t){if(n(t))return t;throw new o(i(t)+" is not a function")}},3506:function(t,e,r){"use strict";var n=r(3925),i=String,o=TypeError;t.exports=function(t){if(n(t))return t;throw new o("Can't set "+i(t)+" as a prototype")}},8551:function(t,e,r){"use strict";var n=r(34),i=String,o=TypeError;t.exports=function(t){if(n(t))return t;throw new o(i(t)+" is not an object")}},7811:function(t){"use strict";t.exports="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof DataView},7394:function(t,e,r){"use strict";var n=r(4576),i=r(6706),o=r(2195),s=n.ArrayBuffer,a=n.TypeError;t.exports=s&&i(s.prototype,"byteLength","get")||function(t){if("ArrayBuffer"!==o(t))throw new a("ArrayBuffer expected");return t.byteLength}},3238:function(t,e,r){"use strict";var n=r(4576),i=r(7476),o=r(7394),s=n.ArrayBuffer,a=s&&s.prototype,u=a&&i(a.slice);t.exports=function(t){if(0!==o(t))return!1;if(!u)return!1;try{return u(t,0,0),!1}catch(e){return!0}}},5169:function(t,e,r){"use strict";var n=r(3238),i=TypeError;t.exports=function(t){if(n(t))throw new i("ArrayBuffer is detached");return t}},5636:function(t,e,r){"use strict";var n=r(4576),i=r(9504),o=r(6706),s=r(7696),a=r(5169),u=r(7394),c=r(4483),f=r(1548),l=n.structuredClone,d=n.ArrayBuffer,p=n.DataView,h=Math.min,g=d.prototype,v=p.prototype,y=i(g.slice),b=o(g,"resizable","get"),m=o(g,"maxByteLength","get"),w=i(v.getInt8),M=i(v.setInt8);t.exports=(f||c)&&function(t,e,r){var n,i=u(t),o=void 0===e?i:s(e),g=!b||!b(t);if(a(t),f&&(t=l(t,{transfer:[t]}),i===o&&(r||g)))return t;if(i>=o&&(!r||g))n=y(t,0,o);else{var v=r&&!g&&m?{maxByteLength:m(t)}:void 0;n=new d(o,v);for(var S=new p(t),A=new p(n),O=h(o,i),P=0;P<O;P++)M(A,P,w(S,P))}return f||c(t),n}},4644:function(t,e,r){"use strict";var n,i,o,s=r(7811),a=r(3724),u=r(4576),c=r(4901),f=r(34),l=r(9297),d=r(6955),p=r(6823),h=r(6699),g=r(6840),v=r(2106),y=r(1625),b=r(2787),m=r(2967),w=r(8227),M=r(3392),S=r(1181),A=S.enforce,O=S.get,P=u.Int8Array,_=P&&P.prototype,x=u.Uint8ClampedArray,E=x&&x.prototype,F=P&&b(P),k=_&&b(_),T=Object.prototype,B=u.TypeError,R=w("toStringTag"),N=M("TYPED_ARRAY_TAG"),L="TypedArrayConstructor",j=s&&!!m&&"Opera"!==d(u.opera),C=!1,I={Int8Array:1,Uint8Array:1,Uint8ClampedArray:1,Int16Array:2,Uint16Array:2,Int32Array:4,Uint32Array:4,Float32Array:4,Float64Array:8},W={BigInt64Array:8,BigUint64Array:8},z=function(t){if(!f(t))return!1;var e=d(t);return"DataView"===e||l(I,e)||l(W,e)},U=function(t){var e=b(t);if(f(e)){var r=O(e);return r&&l(r,L)?r[L]:U(e)}},V=function(t){if(!f(t))return!1;var e=d(t);return l(I,e)||l(W,e)},D=function(t){if(V(t))return t;throw new B("Target is not a typed array")},G=function(t){if(c(t)&&(!m||y(F,t)))return t;throw new B(p(t)+" is not a typed array constructor")},q=function(t,e,r,n){if(a){if(r)for(var i in I){var o=u[i];if(o&&l(o.prototype,t))try{delete o.prototype[t]}catch(s){try{o.prototype[t]=e}catch(c){}}}k[t]&&!r||g(k,t,r?e:j&&_[t]||e,n)}},K=function(t,e,r){var n,i;if(a){if(m){if(r)for(n in I)if(i=u[n],i&&l(i,t))try{delete i[t]}catch(o){}if(F[t]&&!r)return;try{return g(F,t,r?e:j&&F[t]||e)}catch(o){}}for(n in I)i=u[n],!i||i[t]&&!r||g(i,t,e)}};for(n in I)i=u[n],o=i&&i.prototype,o?A(o)[L]=i:j=!1;for(n in W)i=u[n],o=i&&i.prototype,o&&(A(o)[L]=i);if((!j||!c(F)||F===Function.prototype)&&(F=function(){throw new B("Incorrect invocation")},j))for(n in I)u[n]&&m(u[n],F);if((!j||!k||k===T)&&(k=F.prototype,j))for(n in I)u[n]&&m(u[n].prototype,k);if(j&&b(E)!==k&&m(E,k),a&&!l(k,R))for(n in C=!0,v(k,R,{configurable:!0,get:function(){return f(this)?this[N]:void 0}}),I)u[n]&&h(u[n],N,n);t.exports={NATIVE_ARRAY_BUFFER_VIEWS:j,TYPED_ARRAY_TAG:C&&N,aTypedArray:D,aTypedArrayConstructor:G,exportTypedArrayMethod:q,exportTypedArrayStaticMethod:K,getTypedArrayConstructor:U,isView:z,isTypedArray:V,TypedArray:F,TypedArrayPrototype:k}},5370:function(t,e,r){"use strict";var n=r(6198);t.exports=function(t,e,r){var i=0,o=arguments.length>2?r:n(e),s=new t(o);while(o>i)s[i]=e[i++];return s}},9617:function(t,e,r){"use strict";var n=r(5397),i=r(5610),o=r(6198),s=function(t){return function(e,r,s){var a=n(e),u=o(a);if(0===u)return!t&&-1;var c,f=i(s,u);if(t&&r!==r){while(u>f)if(c=a[f++],c!==c)return!0}else for(;u>f;f++)if((t||f in a)&&a[f]===r)return t||f||0;return!t&&-1}};t.exports={includes:s(!0),indexOf:s(!1)}},4527:function(t,e,r){"use strict";var n=r(3724),i=r(4376),o=TypeError,s=Object.getOwnPropertyDescriptor,a=n&&!function(){if(void 0!==this)return!0;try{Object.defineProperty([],"length",{writable:!1}).length=1}catch(t){return t instanceof TypeError}}();t.exports=a?function(t,e){if(i(t)&&!s(t,"length").writable)throw new o("Cannot set read only .length");return t.length=e}:function(t,e){return t.length=e}},7628:function(t,e,r){"use strict";var n=r(6198);t.exports=function(t,e){for(var r=n(t),i=new e(r),o=0;o<r;o++)i[o]=t[r-o-1];return i}},9928:function(t,e,r){"use strict";var n=r(6198),i=r(1291),o=RangeError;t.exports=function(t,e,r,s){var a=n(t),u=i(r),c=u<0?a+u:u;if(c>=a||c<0)throw new o("Incorrect index");for(var f=new e(a),l=0;l<a;l++)f[l]=l===c?s:t[l];return f}},2195:function(t,e,r){"use strict";var n=r(9504),i=n({}.toString),o=n("".slice);t.exports=function(t){return o(i(t),8,-1)}},6955:function(t,e,r){"use strict";var n=r(2140),i=r(4901),o=r(2195),s=r(8227),a=s("toStringTag"),u=Object,c="Arguments"===o(function(){return arguments}()),f=function(t,e){try{return t[e]}catch(r){}};t.exports=n?o:function(t){var e,r,n;return void 0===t?"Undefined":null===t?"Null":"string"==typeof(r=f(e=u(t),a))?r:c?o(e):"Object"===(n=o(e))&&i(e.callee)?"Arguments":n}},7740:function(t,e,r){"use strict";var n=r(9297),i=r(5031),o=r(7347),s=r(4913);t.exports=function(t,e,r){for(var a=i(e),u=s.f,c=o.f,f=0;f<a.length;f++){var l=a[f];n(t,l)||r&&n(r,l)||u(t,l,c(e,l))}}},2211:function(t,e,r){"use strict";var n=r(9039);t.exports=!n((function(){function t(){}return t.prototype.constructor=null,Object.getPrototypeOf(new t)!==t.prototype}))},6699:function(t,e,r){"use strict";var n=r(3724),i=r(4913),o=r(6980);t.exports=n?function(t,e,r){return i.f(t,e,o(1,r))}:function(t,e,r){return t[e]=r,t}},6980:function(t){"use strict";t.exports=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}}},2106:function(t,e,r){"use strict";var n=r(283),i=r(4913);t.exports=function(t,e,r){return r.get&&n(r.get,e,{getter:!0}),r.set&&n(r.set,e,{setter:!0}),i.f(t,e,r)}},6840:function(t,e,r){"use strict";var n=r(4901),i=r(4913),o=r(283),s=r(9433);t.exports=function(t,e,r,a){a||(a={});var u=a.enumerable,c=void 0!==a.name?a.name:e;if(n(r)&&o(r,c,a),a.global)u?t[e]=r:s(e,r);else{try{a.unsafe?t[e]&&(u=!0):delete t[e]}catch(f){}u?t[e]=r:i.f(t,e,{value:r,enumerable:!1,configurable:!a.nonConfigurable,writable:!a.nonWritable})}return t}},9433:function(t,e,r){"use strict";var n=r(4576),i=Object.defineProperty;t.exports=function(t,e){try{i(n,t,{value:e,configurable:!0,writable:!0})}catch(r){n[t]=e}return e}},3724:function(t,e,r){"use strict";var n=r(9039);t.exports=!n((function(){return 7!==Object.defineProperty({},1,{get:function(){return 7}})[1]}))},4483:function(t,e,r){"use strict";var n,i,o,s,a=r(4576),u=r(9429),c=r(1548),f=a.structuredClone,l=a.ArrayBuffer,d=a.MessageChannel,p=!1;if(c)p=function(t){f(t,{transfer:[t]})};else if(l)try{d||(n=u("worker_threads"),n&&(d=n.MessageChannel)),d&&(i=new d,o=new l(2),s=function(t){i.port1.postMessage(null,[t])},2===o.byteLength&&(s(o),0===o.byteLength&&(p=s)))}catch(h){}t.exports=p},4055:function(t,e,r){"use strict";var n=r(4576),i=r(34),o=n.document,s=i(o)&&i(o.createElement);t.exports=function(t){return s?o.createElement(t):{}}},6837:function(t){"use strict";var e=TypeError,r=9007199254740991;t.exports=function(t){if(t>r)throw e("Maximum allowed index exceeded");return t}},8727:function(t){"use strict";t.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]},6193:function(t,e,r){"use strict";var n=r(4215);t.exports="NODE"===n},2839:function(t,e,r){"use strict";var n=r(4576),i=n.navigator,o=i&&i.userAgent;t.exports=o?String(o):""},9519:function(t,e,r){"use strict";var n,i,o=r(4576),s=r(2839),a=o.process,u=o.Deno,c=a&&a.versions||u&&u.version,f=c&&c.v8;f&&(n=f.split("."),i=n[0]>0&&n[0]<4?1:+(n[0]+n[1])),!i&&s&&(n=s.match(/Edge\/(\d+)/),(!n||n[1]>=74)&&(n=s.match(/Chrome\/(\d+)/),n&&(i=+n[1]))),t.exports=i},4215:function(t,e,r){"use strict";var n=r(4576),i=r(2839),o=r(2195),s=function(t){return i.slice(0,t.length)===t};t.exports=function(){return s("Bun/")?"BUN":s("Cloudflare-Workers")?"CLOUDFLARE":s("Deno/")?"DENO":s("Node.js/")?"NODE":n.Bun&&"string"==typeof Bun.version?"BUN":n.Deno&&"object"==typeof Deno.version?"DENO":"process"===o(n.process)?"NODE":n.window&&n.document?"BROWSER":"REST"}()},6518:function(t,e,r){"use strict";var n=r(4576),i=r(7347).f,o=r(6699),s=r(6840),a=r(9433),u=r(7740),c=r(2796);t.exports=function(t,e){var r,f,l,d,p,h,g=t.target,v=t.global,y=t.stat;if(f=v?n:y?n[g]||a(g,{}):n[g]&&n[g].prototype,f)for(l in e){if(p=e[l],t.dontCallGetSet?(h=i(f,l),d=h&&h.value):d=f[l],r=c(v?l:g+(y?".":"#")+l,t.forced),!r&&void 0!==d){if(typeof p==typeof d)continue;u(p,d)}(t.sham||d&&d.sham)&&o(p,"sham",!0),s(f,l,p,t)}}},9039:function(t){"use strict";t.exports=function(t){try{return!!t()}catch(e){return!0}}},616:function(t,e,r){"use strict";var n=r(9039);t.exports=!n((function(){var t=function(){}.bind();return"function"!=typeof t||t.hasOwnProperty("prototype")}))},9565:function(t,e,r){"use strict";var n=r(616),i=Function.prototype.call;t.exports=n?i.bind(i):function(){return i.apply(i,arguments)}},350:function(t,e,r){"use strict";var n=r(3724),i=r(9297),o=Function.prototype,s=n&&Object.getOwnPropertyDescriptor,a=i(o,"name"),u=a&&"something"===function(){}.name,c=a&&(!n||n&&s(o,"name").configurable);t.exports={EXISTS:a,PROPER:u,CONFIGURABLE:c}},6706:function(t,e,r){"use strict";var n=r(9504),i=r(9306);t.exports=function(t,e,r){try{return n(i(Object.getOwnPropertyDescriptor(t,e)[r]))}catch(o){}}},7476:function(t,e,r){"use strict";var n=r(2195),i=r(9504);t.exports=function(t){if("Function"===n(t))return i(t)}},9504:function(t,e,r){"use strict";var n=r(616),i=Function.prototype,o=i.call,s=n&&i.bind.bind(o,o);t.exports=n?s:function(t){return function(){return o.apply(t,arguments)}}},9429:function(t,e,r){"use strict";var n=r(4576),i=r(6193);t.exports=function(t){if(i){try{return n.process.getBuiltinModule(t)}catch(e){}try{return Function('return require("'+t+'")')()}catch(e){}}}},7751:function(t,e,r){"use strict";var n=r(4576),i=r(4901),o=function(t){return i(t)?t:void 0};t.exports=function(t,e){return arguments.length<2?o(n[t]):n[t]&&n[t][e]}},5966:function(t,e,r){"use strict";var n=r(9306),i=r(4117);t.exports=function(t,e){var r=t[e];return i(r)?void 0:n(r)}},4576:function(t,e,r){"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 r.g&&r.g)||n("object"==typeof this&&this)||function(){return this}()||Function("return this")()},9297:function(t,e,r){"use strict";var n=r(9504),i=r(8981),o=n({}.hasOwnProperty);t.exports=Object.hasOwn||function(t,e){return o(i(t),e)}},421:function(t){"use strict";t.exports={}},5917:function(t,e,r){"use strict";var n=r(3724),i=r(9039),o=r(4055);t.exports=!n&&!i((function(){return 7!==Object.defineProperty(o("div"),"a",{get:function(){return 7}}).a}))},7055:function(t,e,r){"use strict";var n=r(9504),i=r(9039),o=r(2195),s=Object,a=n("".split);t.exports=i((function(){return!s("z").propertyIsEnumerable(0)}))?function(t){return"String"===o(t)?a(t,""):s(t)}:s},3706:function(t,e,r){"use strict";var n=r(9504),i=r(4901),o=r(7629),s=n(Function.toString);i(o.inspectSource)||(o.inspectSource=function(t){return s(t)}),t.exports=o.inspectSource},1181:function(t,e,r){"use strict";var n,i,o,s=r(8622),a=r(4576),u=r(34),c=r(6699),f=r(9297),l=r(7629),d=r(6119),p=r(421),h="Object already initialized",g=a.TypeError,v=a.WeakMap,y=function(t){return o(t)?i(t):n(t,{})},b=function(t){return function(e){var r;if(!u(e)||(r=i(e)).type!==t)throw new g("Incompatible receiver, "+t+" required");return r}};if(s||l.state){var m=l.state||(l.state=new v);m.get=m.get,m.has=m.has,m.set=m.set,n=function(t,e){if(m.has(t))throw new g(h);return e.facade=t,m.set(t,e),e},i=function(t){return m.get(t)||{}},o=function(t){return m.has(t)}}else{var w=d("state");p[w]=!0,n=function(t,e){if(f(t,w))throw new g(h);return e.facade=t,c(t,w,e),e},i=function(t){return f(t,w)?t[w]:{}},o=function(t){return f(t,w)}}t.exports={set:n,get:i,has:o,enforce:y,getterFor:b}},4376:function(t,e,r){"use strict";var n=r(2195);t.exports=Array.isArray||function(t){return"Array"===n(t)}},1108:function(t,e,r){"use strict";var n=r(6955);t.exports=function(t){var e=n(t);return"BigInt64Array"===e||"BigUint64Array"===e}},4901:function(t){"use strict";var e="object"==typeof document&&document.all;t.exports="undefined"==typeof e&&void 0!==e?function(t){return"function"==typeof t||t===e}:function(t){return"function"==typeof t}},2796:function(t,e,r){"use strict";var n=r(9039),i=r(4901),o=/#|\.prototype\./,s=function(t,e){var r=u[a(t)];return r===f||r!==c&&(i(e)?n(e):!!e)},a=s.normalize=function(t){return String(t).replace(o,".").toLowerCase()},u=s.data={},c=s.NATIVE="N",f=s.POLYFILL="P";t.exports=s},4117:function(t){"use strict";t.exports=function(t){return null===t||void 0===t}},34:function(t,e,r){"use strict";var n=r(4901);t.exports=function(t){return"object"==typeof t?null!==t:n(t)}},3925:function(t,e,r){"use strict";var n=r(34);t.exports=function(t){return n(t)||null===t}},6395:function(t){"use strict";t.exports=!1},757:function(t,e,r){"use strict";var n=r(7751),i=r(4901),o=r(1625),s=r(7040),a=Object;t.exports=s?function(t){return"symbol"==typeof t}:function(t){var e=n("Symbol");return i(e)&&o(e.prototype,a(t))}},6198:function(t,e,r){"use strict";var n=r(8014);t.exports=function(t){return n(t.length)}},283:function(t,e,r){"use strict";var n=r(9504),i=r(9039),o=r(4901),s=r(9297),a=r(3724),u=r(350).CONFIGURABLE,c=r(3706),f=r(1181),l=f.enforce,d=f.get,p=String,h=Object.defineProperty,g=n("".slice),v=n("".replace),y=n([].join),b=a&&!i((function(){return 8!==h((function(){}),"length",{value:8}).length})),m=String(String).split("String"),w=t.exports=function(t,e,r){"Symbol("===g(p(e),0,7)&&(e="["+v(p(e),/^Symbol\(([^)]*)\).*$/,"$1")+"]"),r&&r.getter&&(e="get "+e),r&&r.setter&&(e="set "+e),(!s(t,"name")||u&&t.name!==e)&&(a?h(t,"name",{value:e,configurable:!0}):t.name=e),b&&r&&s(r,"arity")&&t.length!==r.arity&&h(t,"length",{value:r.arity});try{r&&s(r,"constructor")&&r.constructor?a&&h(t,"prototype",{writable:!1}):t.prototype&&(t.prototype=void 0)}catch(i){}var n=l(t);return s(n,"source")||(n.source=y(m,"string"==typeof e?e:"")),t};Function.prototype.toString=w((function(){return o(this)&&d(this).source||c(this)}),"toString")},741:function(t){"use strict";var e=Math.ceil,r=Math.floor;t.exports=Math.trunc||function(t){var n=+t;return(n>0?r:e)(n)}},4913:function(t,e,r){"use strict";var n=r(3724),i=r(5917),o=r(8686),s=r(8551),a=r(6969),u=TypeError,c=Object.defineProperty,f=Object.getOwnPropertyDescriptor,l="enumerable",d="configurable",p="writable";e.f=n?o?function(t,e,r){if(s(t),e=a(e),s(r),"function"===typeof t&&"prototype"===e&&"value"in r&&p in r&&!r[p]){var n=f(t,e);n&&n[p]&&(t[e]=r.value,r={configurable:d in r?r[d]:n[d],enumerable:l in r?r[l]:n[l],writable:!1})}return c(t,e,r)}:c:function(t,e,r){if(s(t),e=a(e),s(r),i)try{return c(t,e,r)}catch(n){}if("get"in r||"set"in r)throw new u("Accessors not supported");return"value"in r&&(t[e]=r.value),t}},7347:function(t,e,r){"use strict";var n=r(3724),i=r(9565),o=r(8773),s=r(6980),a=r(5397),u=r(6969),c=r(9297),f=r(5917),l=Object.getOwnPropertyDescriptor;e.f=n?l:function(t,e){if(t=a(t),e=u(e),f)try{return l(t,e)}catch(r){}if(c(t,e))return s(!i(o.f,t,e),t[e])}},8480:function(t,e,r){"use strict";var n=r(1828),i=r(8727),o=i.concat("length","prototype");e.f=Object.getOwnPropertyNames||function(t){return n(t,o)}},3717:function(t,e){"use strict";e.f=Object.getOwnPropertySymbols},2787:function(t,e,r){"use strict";var n=r(9297),i=r(4901),o=r(8981),s=r(6119),a=r(2211),u=s("IE_PROTO"),c=Object,f=c.prototype;t.exports=a?c.getPrototypeOf:function(t){var e=o(t);if(n(e,u))return e[u];var r=e.constructor;return i(r)&&e instanceof r?r.prototype:e instanceof c?f:null}},1625:function(t,e,r){"use strict";var n=r(9504);t.exports=n({}.isPrototypeOf)},1828:function(t,e,r){"use strict";var n=r(9504),i=r(9297),o=r(5397),s=r(9617).indexOf,a=r(421),u=n([].push);t.exports=function(t,e){var r,n=o(t),c=0,f=[];for(r in n)!i(a,r)&&i(n,r)&&u(f,r);while(e.length>c)i(n,r=e[c++])&&(~s(f,r)||u(f,r));return f}},8773:function(t,e){"use strict";var r={}.propertyIsEnumerable,n=Object.getOwnPropertyDescriptor,i=n&&!r.call({1:2},1);e.f=i?function(t){var e=n(this,t);return!!e&&e.enumerable}:r},2967:function(t,e,r){"use strict";var n=r(6706),i=r(34),o=r(7750),s=r(3506);t.exports=Object.setPrototypeOf||("__proto__"in{}?function(){var t,e=!1,r={};try{t=n(Object.prototype,"__proto__","set"),t(r,[]),e=r instanceof Array}catch(a){}return function(r,n){return o(r),s(n),i(r)?(e?t(r,n):r.__proto__=n,r):r}}():void 0)},4270:function(t,e,r){"use strict";var n=r(9565),i=r(4901),o=r(34),s=TypeError;t.exports=function(t,e){var r,a;if("string"===e&&i(r=t.toString)&&!o(a=n(r,t)))return a;if(i(r=t.valueOf)&&!o(a=n(r,t)))return a;if("string"!==e&&i(r=t.toString)&&!o(a=n(r,t)))return a;throw new s("Can't convert object to primitive value")}},5031:function(t,e,r){"use strict";var n=r(7751),i=r(9504),o=r(8480),s=r(3717),a=r(8551),u=i([].concat);t.exports=n("Reflect","ownKeys")||function(t){var e=o.f(a(t)),r=s.f;return r?u(e,r(t)):e}},7750:function(t,e,r){"use strict";var n=r(4117),i=TypeError;t.exports=function(t){if(n(t))throw new i("Can't call method on "+t);return t}},6119:function(t,e,r){"use strict";var n=r(5745),i=r(3392),o=n("keys");t.exports=function(t){return o[t]||(o[t]=i(t))}},7629:function(t,e,r){"use strict";var n=r(6395),i=r(4576),o=r(9433),s="__core-js_shared__",a=t.exports=i[s]||o(s,{});(a.versions||(a.versions=[])).push({version:"3.38.1",mode:n?"pure":"global",copyright:"© 2014-2024 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.38.1/LICENSE",source:"https://github.com/zloirock/core-js"})},5745:function(t,e,r){"use strict";var n=r(7629);t.exports=function(t,e){return n[t]||(n[t]=e||{})}},1548:function(t,e,r){"use strict";var n=r(4576),i=r(9039),o=r(9519),s=r(4215),a=n.structuredClone;t.exports=!!a&&!i((function(){if("DENO"===s&&o>92||"NODE"===s&&o>94||"BROWSER"===s&&o>97)return!1;var t=new ArrayBuffer(8),e=a(t,{transfer:[t]});return 0!==t.byteLength||8!==e.byteLength}))},4495:function(t,e,r){"use strict";var n=r(9519),i=r(9039),o=r(4576),s=o.String;t.exports=!!Object.getOwnPropertySymbols&&!i((function(){var t=Symbol("symbol detection");return!s(t)||!(Object(t)instanceof Symbol)||!Symbol.sham&&n&&n<41}))},5610:function(t,e,r){"use strict";var n=r(1291),i=Math.max,o=Math.min;t.exports=function(t,e){var r=n(t);return r<0?i(r+e,0):o(r,e)}},5854:function(t,e,r){"use strict";var n=r(2777),i=TypeError;t.exports=function(t){var e=n(t,"number");if("number"==typeof e)throw new i("Can't convert number to bigint");return BigInt(e)}},7696:function(t,e,r){"use strict";var n=r(1291),i=r(8014),o=RangeError;t.exports=function(t){if(void 0===t)return 0;var e=n(t),r=i(e);if(e!==r)throw new o("Wrong length or index");return r}},5397:function(t,e,r){"use strict";var n=r(7055),i=r(7750);t.exports=function(t){return n(i(t))}},1291:function(t,e,r){"use strict";var n=r(741);t.exports=function(t){var e=+t;return e!==e||0===e?0:n(e)}},8014:function(t,e,r){"use strict";var n=r(1291),i=Math.min;t.exports=function(t){var e=n(t);return e>0?i(e,9007199254740991):0}},8981:function(t,e,r){"use strict";var n=r(7750),i=Object;t.exports=function(t){return i(n(t))}},2777:function(t,e,r){"use strict";var n=r(9565),i=r(34),o=r(757),s=r(5966),a=r(4270),u=r(8227),c=TypeError,f=u("toPrimitive");t.exports=function(t,e){if(!i(t)||o(t))return t;var r,u=s(t,f);if(u){if(void 0===e&&(e="default"),r=n(u,t,e),!i(r)||o(r))return r;throw new c("Can't convert object to primitive value")}return void 0===e&&(e="number"),a(t,e)}},6969:function(t,e,r){"use strict";var n=r(2777),i=r(757);t.exports=function(t){var e=n(t,"string");return i(e)?e:e+""}},2140:function(t,e,r){"use strict";var n=r(8227),i=n("toStringTag"),o={};o[i]="z",t.exports="[object z]"===String(o)},655:function(t,e,r){"use strict";var n=r(6955),i=String;t.exports=function(t){if("Symbol"===n(t))throw new TypeError("Cannot convert a Symbol value to a string");return i(t)}},6823:function(t){"use strict";var e=String;t.exports=function(t){try{return e(t)}catch(r){return"Object"}}},3392:function(t,e,r){"use strict";var n=r(9504),i=0,o=Math.random(),s=n(1..toString);t.exports=function(t){return"Symbol("+(void 0===t?"":t)+")_"+s(++i+o,36)}},7040:function(t,e,r){"use strict";var n=r(4495);t.exports=n&&!Symbol.sham&&"symbol"==typeof Symbol.iterator},8686:function(t,e,r){"use strict";var n=r(3724),i=r(9039);t.exports=n&&i((function(){return 42!==Object.defineProperty((function(){}),"prototype",{value:42,writable:!1}).prototype}))},2812:function(t){"use strict";var e=TypeError;t.exports=function(t,r){if(t<r)throw new e("Not enough arguments");return t}},8622:function(t,e,r){"use strict";var n=r(4576),i=r(4901),o=n.WeakMap;t.exports=i(o)&&/native code/.test(String(o))},8227:function(t,e,r){"use strict";var n=r(4576),i=r(5745),o=r(9297),s=r(3392),a=r(4495),u=r(7040),c=n.Symbol,f=i("wks"),l=u?c["for"]||c:c&&c.withoutSetter||s;t.exports=function(t){return o(f,t)||(f[t]=a&&o(c,t)?c[t]:l("Symbol."+t)),f[t]}},6573:function(t,e,r){"use strict";var n=r(3724),i=r(2106),o=r(3238),s=ArrayBuffer.prototype;n&&!("detached"in s)&&i(s,"detached",{configurable:!0,get:function(){return o(this)}})},7936:function(t,e,r){"use strict";var n=r(6518),i=r(5636);i&&n({target:"ArrayBuffer",proto:!0},{transferToFixedLength:function(){return i(this,arguments.length?arguments[0]:void 0,!1)}})},8100:function(t,e,r){"use strict";var n=r(6518),i=r(5636);i&&n({target:"ArrayBuffer",proto:!0},{transfer:function(){return i(this,arguments.length?arguments[0]:void 0,!0)}})},4114:function(t,e,r){"use strict";var n=r(6518),i=r(8981),o=r(6198),s=r(4527),a=r(6837),u=r(9039),c=u((function(){return 4294967297!==[].push.call({length:4294967296},1)})),f=function(){try{Object.defineProperty([],"length",{writable:!1}).push()}catch(t){return t instanceof TypeError}},l=c||!f();n({target:"Array",proto:!0,arity:1,forced:l},{push:function(t){var e=i(this),r=o(e),n=arguments.length;a(r+n);for(var u=0;u<n;u++)e[r]=arguments[u],r++;return s(e,r),r}})},7467:function(t,e,r){"use strict";var n=r(7628),i=r(4644),o=i.aTypedArray,s=i.exportTypedArrayMethod,a=i.getTypedArrayConstructor;s("toReversed",(function(){return n(o(this),a(this))}))},4732:function(t,e,r){"use strict";var n=r(4644),i=r(9504),o=r(9306),s=r(5370),a=n.aTypedArray,u=n.getTypedArrayConstructor,c=n.exportTypedArrayMethod,f=i(n.TypedArrayPrototype.sort);c("toSorted",(function(t){void 0!==t&&o(t);var e=a(this),r=s(u(e),e);return f(r,t)}))},9577:function(t,e,r){"use strict";var n=r(9928),i=r(4644),o=r(1108),s=r(1291),a=r(5854),u=i.aTypedArray,c=i.getTypedArrayConstructor,f=i.exportTypedArrayMethod,l=!!function(){try{new Int8Array(1)["with"](2,{valueOf:function(){throw 8}})}catch(t){return 8===t}}();f("with",{with:function(t,e){var r=u(this),i=s(t),f=o(r)?a(e):+e;return n(r,c(r),i,f)}}["with"],!l)},4603:function(t,e,r){"use strict";var n=r(6840),i=r(9504),o=r(655),s=r(2812),a=URLSearchParams,u=a.prototype,c=i(u.append),f=i(u["delete"]),l=i(u.forEach),d=i([].push),p=new a("a=1&a=2&b=3");p["delete"]("a",1),p["delete"]("b",void 0),p+""!=="a=2"&&n(u,"delete",(function(t){var e=arguments.length,r=e<2?void 0:arguments[1];if(e&&void 0===r)return f(this,t);var n=[];l(this,(function(t,e){d(n,{key:e,value:t})})),s(e,1);var i,a=o(t),u=o(r),p=0,h=0,g=!1,v=n.length;while(p<v)i=n[p++],g||i.key===a?(g=!0,f(this,i.key)):h++;while(h<v)i=n[h++],i.key===a&&i.value===u||c(this,i.key,i.value)}),{enumerable:!0,unsafe:!0})},7566:function(t,e,r){"use strict";var n=r(6840),i=r(9504),o=r(655),s=r(2812),a=URLSearchParams,u=a.prototype,c=i(u.getAll),f=i(u.has),l=new a("a=1");!l.has("a",2)&&l.has("a",void 0)||n(u,"has",(function(t){var e=arguments.length,r=e<2?void 0:arguments[1];if(e&&void 0===r)return f(this,t);var n=c(this,t);s(e,1);var i=o(r),a=0;while(a<n.length)if(n[a++]===i)return!0;return!1}),{enumerable:!0,unsafe:!0})},8721:function(t,e,r){"use strict";var n=r(3724),i=r(9504),o=r(2106),s=URLSearchParams.prototype,a=i(s.forEach);n&&!("size"in s)&&o(s,"size",{get:function(){var t=0;return a(this,(function(){t++})),t},configurable:!0,enumerable:!0})},8272:function(t){"use strict";t.exports=JSON.parse('{"base":"/luckperms-editor/","selfHosted":true,"bytebinUrl":"https://usercontent.luckperms.net/","bytesocksUrl":"wss://usersockets.luckperms.net/","apiUrl":"https://metadata.luckperms.net/"}')}},e={};function r(n){var i=e[n];if(void 0!==i)return i.exports;var o=e[n]={exports:{}};return t[n].call(o.exports,o,o.exports,r),o.exports}!function(){r.n=function(t){var e=t&&t.__esModule?function(){return t["default"]}:function(){return t};return r.d(e,{a:e}),e}}(),function(){r.d=function(t,e){for(var n in e)r.o(e,n)&&!r.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:e[n]})}}(),function(){r.g=function(){if("object"===typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(t){if("object"===typeof window)return window}}()}(),function(){r.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)}}();!function(){"use strict";r(4114),r(6573),r(8100),r(7936),r(7467),r(4732),r(9577),r(4603),r(7566),r(8721);for(var t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",e="undefined"===typeof Uint8Array?[]:new Uint8Array(256),n=0;n<t.length;n++)e[t.charCodeAt(n)]=n;var i=function(e){var r,n=new Uint8Array(e),i=n.length,o="";for(r=0;r<i;r+=3)o+=t[n[r]>>2],o+=t[(3&n[r])<<4|n[r+1]>>4],o+=t[(15&n[r+1])<<2|n[r+2]>>6],o+=t[63&n[r+2]];return i%3===2?o=o.substring(0,o.length-1)+"=":i%3===1&&(o=o.substring(0,o.length-2)+"=="),o},o=function(t){var r,n,i,o,s,a=.75*t.length,u=t.length,c=0;"="===t[t.length-1]&&(a--,"="===t[t.length-2]&&a--);var f=new ArrayBuffer(a),l=new Uint8Array(f);for(r=0;r<u;r+=4)n=e[t.charCodeAt(r)],i=e[t.charCodeAt(r+1)],o=e[t.charCodeAt(r+2)],s=e[t.charCodeAt(r+3)],l[c++]=n<<2|i>>4,l[c++]=(15&i)<<4|o>>2,l[c++]=(3&o)<<6|63&s;return f},s=r(6880),a=r.n(s);
/**
* @license
* Copyright 2019 Google LLC
* SPDX-License-Identifier: Apache-2.0
*/
const u=Symbol("Comlink.proxy"),c=Symbol("Comlink.endpoint"),f=Symbol("Comlink.releaseProxy"),l=Symbol("Comlink.finalizer"),d=Symbol("Comlink.thrown"),p=t=>"object"===typeof t&&null!==t||"function"===typeof t,h={canHandle:t=>p(t)&&t[u],serialize(t){const{port1:e,port2:r}=new MessageChannel;return b(t,e),[r,[r]]},deserialize(t){return t.start(),M(t)}},g={canHandle:t=>p(t)&&d in t,serialize({value:t}){let e;return e=t instanceof Error?{isError:!0,value:{message:t.message,name:t.name,stack:t.stack}}:{isError:!1,value:t},[e,[]]},deserialize(t){if(t.isError)throw Object.assign(new Error(t.value.message),t.value);throw t.value}},v=new Map([["proxy",h],["throw",g]]);function y(t,e){for(const r of t){if(e===r||"*"===r)return!0;if(r instanceof RegExp&&r.test(e))return!0}return!1}function b(t,e=globalThis,r=["*"]){e.addEventListener("message",(function n(i){if(!i||!i.data)return;if(!y(r,i.origin))return void console.warn(`Invalid origin '${i.origin}' for comlink proxy`);const{id:o,type:s,path:a}=Object.assign({path:[]},i.data),u=(i.data.argumentList||[]).map(L);let c;try{const e=a.slice(0,-1).reduce(((t,e)=>t[e]),t),r=a.reduce(((t,e)=>t[e]),t);switch(s){case"GET":c=r;break;case"SET":e[a.slice(-1)[0]]=L(i.data.value),c=!0;break;case"APPLY":c=r.apply(e,u);break;case"CONSTRUCT":{const t=new r(...u);c=R(t)}break;case"ENDPOINT":{const{port1:e,port2:r}=new MessageChannel;b(t,r),c=B(e,[e])}break;case"RELEASE":c=void 0;break;default:return}}catch(f){c={value:f,[d]:0}}Promise.resolve(c).catch((t=>({value:t,[d]:0}))).then((r=>{const[i,a]=N(r);e.postMessage(Object.assign(Object.assign({},i),{id:o}),a),"RELEASE"===s&&(e.removeEventListener("message",n),w(e),l in t&&"function"===typeof t[l]&&t[l]())})).catch((t=>{const[r,n]=N({value:new TypeError("Unserializable return value"),[d]:0});e.postMessage(Object.assign(Object.assign({},r),{id:o}),n)}))})),e.start&&e.start()}function m(t){return"MessagePort"===t.constructor.name}function w(t){m(t)&&t.close()}function M(t,e){return E(t,[],e)}function S(t){if(t)throw new Error("Proxy has been released and is not useable")}function A(t){return j(t,{type:"RELEASE"}).then((()=>{w(t)}))}const O=new WeakMap,P="FinalizationRegistry"in globalThis&&new FinalizationRegistry((t=>{const e=(O.get(t)||0)-1;O.set(t,e),0===e&&A(t)}));function _(t,e){const r=(O.get(e)||0)+1;O.set(e,r),P&&P.register(t,e,t)}function x(t){P&&P.unregister(t)}function E(t,e=[],r=function(){}){let n=!1;const i=new Proxy(r,{get(r,o){if(S(n),o===f)return()=>{x(i),A(t),n=!0};if("then"===o){if(0===e.length)return{then:()=>i};const r=j(t,{type:"GET",path:e.map((t=>t.toString()))}).then(L);return r.then.bind(r)}return E(t,[...e,o])},set(r,i,o){S(n);const[s,a]=N(o);return j(t,{type:"SET",path:[...e,i].map((t=>t.toString())),value:s},a).then(L)},apply(r,i,o){S(n);const s=e[e.length-1];if(s===c)return j(t,{type:"ENDPOINT"}).then(L);if("bind"===s)return E(t,e.slice(0,-1));const[a,u]=k(o);return j(t,{type:"APPLY",path:e.map((t=>t.toString())),argumentList:a},u).then(L)},construct(r,i){S(n);const[o,s]=k(i);return j(t,{type:"CONSTRUCT",path:e.map((t=>t.toString())),argumentList:o},s).then(L)}});return _(i,t),i}function F(t){return Array.prototype.concat.apply([],t)}function k(t){const e=t.map(N);return[e.map((t=>t[0])),F(e.map((t=>t[1])))]}const T=new WeakMap;function B(t,e){return T.set(t,e),t}function R(t){return Object.assign(t,{[u]:!0})}function N(t){for(const[e,r]of v)if(r.canHandle(t)){const[n,i]=r.serialize(t);return[{type:"HANDLER",name:e,value:n},i]}return[{type:"RAW",value:t},T.get(t)||[]]}function L(t){switch(t.type){case"HANDLER":return v.get(t.name).deserialize(t.value);case"RAW":return t.value}}function j(t,e,r){return new Promise((n=>{const i=C();t.addEventListener("message",(function e(r){r.data&&r.data.id&&r.data.id===i&&(t.removeEventListener("message",e),n(r.data))})),t.start&&t.start(),t.postMessage(Object.assign({id:i},e),r)}))}function C(){return new Array(4).fill(0).map((()=>Math.floor(Math.random()*Number.MAX_SAFE_INTEGER).toString(16))).join("-")}const I=r(8272),W=!0,z=!1;let U;class V{constructor(t,e,r,n){this.socket=t,this.signVerifyAlgorithm=e,this.keys=r,this.pluginKey=n,this.listeners=[],this.lastPing=0,this.lastPong=0,this.keepaliveTask=null}async send(t){const e=JSON.stringify(t),r=await crypto.subtle.sign(this.signVerifyAlgorithm,this.keys.privateKey,(new TextEncoder).encode(e));this.socket.send(JSON.stringify({msg:e,signature:i(r)}))}registerListener(t){this.listeners.push(t)}async onReceive(t){const{msg:e,signature:r}=t;if(!e||!r)return;const n=await crypto.subtle.verify(this.signVerifyAlgorithm,this.pluginKey,o(r),(new TextEncoder).encode(e));if(!n)return;const i=JSON.parse(e),s=[];this.listeners.forEach(((t,e)=>{const r=t(i);r===z&&s.unshift(e)})),s.forEach((t=>this.listeners.splice(t,1)))}}function D(t,e,r,n,i,o,s,a){console.log("[WS] Creating socket...");const u=new URL(I.bytesocksUrl,s);"https:"===u.protocol?u.protocol="wss:":"http:"===u.protocol&&(u.protocol="ws:");const c=new WebSocket(`${u}${t}`),f=new V(c,r,n,i);c.onmessage=t=>{const e=JSON.parse(t.data);f.onReceive(e)},c.onopen=()=>{console.log("[WS] Socket open, initialising connection..."),G(f,e,n.encodedPublicKey,o,a)},c.onclose=()=>{a.close()},U=f}function G(t,e,r,n,i){const o=`${Q(4)}-${Q(4)}`;function s(e){if("hello-reply"===e.type&&e.nonce===o){if("accepted"===e.state||"trusted"===e.state)return console.log("[WS] Established connection with plugin!"),"trusted"===e.state&&(t.send({type:"connected"}),i.trusted()),K(t),i.connect(),z;if("untrusted"===e.state)return i.trust(o),W;if("invalid"===e.state)return console.log("[WS] Session data has expired, disconnecting."),i.reused(),t.socket.close(),z;if("rejected"===e.state)return console.log("[WS] Rejected by plugin, disconnecting."),t.socket.close(),z;throw new Error(`unknown state: ${e.state}`)}return W}t.registerListener(s);const{browser:u,os:c}=a().parse(n);t.send({type:"hello",nonce:o,sessionId:e,browser:`${u.name} on ${c.name}`,publicKey:r})}function q(t){const e=U;return new Promise(((r,n)=>{if(!e||1!==e.socket.readyState)return void n(new Error("Socket closed"));let i=setTimeout((()=>{n(new Error("Timeout waiting for plugin to ack change"))}),2e3);function o(t){if("change-response"===t.type){if("accepted"===t.state)return clearTimeout(i),i=setTimeout((()=>{n(new Error("Timeout waiting for plugin to reply with new code"))}),1e4),W;if("applied"===t.state)return clearTimeout(i),r(t.newSessionCode),console.log(`[WS] Applying new session data: ${t.newSessionCode}`),z}return W}e.registerListener(o),e.send({type:"change-request",code:t})}))}function K(t){function e(e){if("pong"===e.type){if(!e.ok)return console.log("[WS] Plugin closed the connection, disconnecting..."),t.socket.close(),z;t.lastPong=Date.now()}return W}t.registerListener(e),t.keepaliveTask=setInterval((()=>{if(1===t.socket.readyState){if(0!==t.lastPing&&Date.now()-t.lastPong>11e3)return console.log("[WS] Plugin stopped responding to keepalive, disconnecting"),void t.socket.close();t.lastPing=Date.now(),t.send({type:"ping"})}else clearInterval(t.keepaliveTask)}),1e4)}function Q(t){function e(t){return t.toString(16).padStart(2,"0")}const r=new Uint8Array((t||40)/2);return crypto.getRandomValues(r),Array.from(r,e).join("")}b({socketConnect:D,sendChangesViaSocket:q})}()})();
//# sourceMappingURL=worker.50c79144.worker.js.map