From 7a2b1e40b404652e001fc64b062c74597fefb70d Mon Sep 17 00:00:00 2001 From: Zack Spear Date: Mon, 31 Oct 2022 09:40:47 -1000 Subject: [PATCH] refactor(upc): v1.8.0 start trial --- .../dynamix.my.servers/webComps/unraid.min.js | 34 +++++++++---------- 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/plugins/dynamix.my.servers/webComps/unraid.min.js b/plugins/dynamix.my.servers/webComps/unraid.min.js index b46025c90..516481e1a 100644 --- a/plugins/dynamix.my.servers/webComps/unraid.min.js +++ b/plugins/dynamix.my.servers/webComps/unraid.min.js @@ -1,5 +1,5 @@ /*! UPC -* vuejs-regwiz v1.7.6 +* vuejs-regwiz v1.8.0 * Licenses @ licenses.txt * * Unraid is a registered trademark of Lime Technology, Inc. @@ -26,7 +26,7 @@ var r=Object.freeze({});function n(e){return null==e}function i(e){return null!= * (c) 2021 Evan You * @license MIT */ -function(e){if(Number(e.version.split(".")[0])>=2)e.mixin({beforeCreate:r});else{var t=e.prototype._init;e.prototype._init=function(e){void 0===e&&(e={}),e.init=e.init?[r].concat(e.init):r,t.call(this,e)}}function r(){var e=this.$options;e.store?this.$store="function"==typeof e.store?e.store():e.store:e.parent&&e.parent.$store&&(this.$store=e.parent.$store)}}(u=e)}f.state.get=function(){return this._vm._data.$$state},f.state.set=function(e){},d.prototype.commit=function(e,t,r){var n=this,i=y(e,t,r),o=i.type,a=i.payload,s=(i.options,{type:o,payload:a}),c=this._mutations[o];c&&(this._withCommit((function(){c.forEach((function(e){e(a)}))})),this._subscribers.slice().forEach((function(e){return e(s,n.state)})))},d.prototype.dispatch=function(e,t){var r=this,n=y(e,t),i=n.type,o=n.payload,a={type:i,payload:o},s=this._actions[i];if(s){try{this._actionSubscribers.slice().filter((function(e){return e.before})).forEach((function(e){return e.before(a,r.state)}))}catch(e){}var c=s.length>1?Promise.all(s.map((function(e){return e(o)}))):s[0](o);return new Promise((function(e,t){c.then((function(t){try{r._actionSubscribers.filter((function(e){return e.after})).forEach((function(e){return e.after(a,r.state)}))}catch(e){}e(t)}),(function(e){try{r._actionSubscribers.filter((function(e){return e.error})).forEach((function(t){return t.error(a,r.state,e)}))}catch(e){}t(e)}))}))}},d.prototype.subscribe=function(e,t){return h(e,this._subscribers,t)},d.prototype.subscribeAction=function(e,t){return h("function"==typeof e?{before:e}:e,this._actionSubscribers,t)},d.prototype.watch=function(e,t,r){var n=this;return this._watcherVM.$watch((function(){return e(n.state,n.getters)}),t,r)},d.prototype.replaceState=function(e){var t=this;this._withCommit((function(){t._vm._data.$$state=e}))},d.prototype.registerModule=function(e,t,r){void 0===r&&(r={}),"string"==typeof e&&(e=[e]),this._modules.register(e,t),v(this,this.state,e,this._modules.get(e),r.preserveState),g(this,this.state)},d.prototype.unregisterModule=function(e){var t=this;"string"==typeof e&&(e=[e]),this._modules.unregister(e),this._withCommit((function(){var r=b(t.state,e.slice(0,-1));u.delete(r,e[e.length-1])})),m(this)},d.prototype.hasModule=function(e){return"string"==typeof e&&(e=[e]),this._modules.isRegistered(e)},d.prototype.hotUpdate=function(e){this._modules.update(e),m(this,!0)},d.prototype._withCommit=function(e){var t=this._committing;this._committing=!0,e(),this._committing=t},Object.defineProperties(d.prototype,f);var x=O((function(e,t){var r={};return k(t).forEach((function(t){var n=t.key,i=t.val;r[n]=function(){var t=this.$store.state,r=this.$store.getters;if(e){var n=T(this.$store,"mapState",e);if(!n)return;t=n.context.state,r=n.context.getters}return"function"==typeof i?i.call(this,t,r):t[i]},r[n].vuex=!0})),r})),_=O((function(e,t){var r={};return k(t).forEach((function(t){var n=t.key,i=t.val;r[n]=function(){for(var t=[],r=arguments.length;r--;)t[r]=arguments[r];var n=this.$store.commit;if(e){var o=T(this.$store,"mapMutations",e);if(!o)return;n=o.context.commit}return"function"==typeof i?i.apply(this,[n].concat(t)):n.apply(this.$store,[i].concat(t))}})),r})),E=O((function(e,t){var r={};return k(t).forEach((function(t){var n=t.key,i=t.val;i=e+i,r[n]=function(){if(!e||T(this.$store,"mapGetters",e))return this.$store.getters[i]},r[n].vuex=!0})),r})),S=O((function(e,t){var r={};return k(t).forEach((function(t){var n=t.key,i=t.val;r[n]=function(){for(var t=[],r=arguments.length;r--;)t[r]=arguments[r];var n=this.$store.dispatch;if(e){var o=T(this.$store,"mapActions",e);if(!o)return;n=o.context.dispatch}return"function"==typeof i?i.apply(this,[n].concat(t)):n.apply(this.$store,[i].concat(t))}})),r}));function k(e){return function(e){return Array.isArray(e)||s(e)}(e)?Array.isArray(e)?e.map((function(e){return{key:e,val:e}})):Object.keys(e).map((function(t){return{key:t,val:e[t]}})):[]}function O(e){return function(t,r){return"string"!=typeof t?(r=t,t=""):"/"!==t.charAt(t.length-1)&&(t+="/"),e(t,r)}}function T(e,t,r){return e._modulesNamespaceMap[r]}function I(e,t,r){var n=r?e.groupCollapsed:e.group;try{n.call(e,t)}catch(r){e.log(t)}}function A(e){try{e.groupEnd()}catch(t){e.log("—— log end ——")}}function R(){var e=new Date;return" @ "+C(e.getHours(),2)+":"+C(e.getMinutes(),2)+":"+C(e.getSeconds(),2)+"."+C(e.getMilliseconds(),3)}function C(e,t){return function(e,t){return new Array(t+1).join(e)}("0",t-e.toString().length)+e}var P={Store:d,install:w,version:"3.6.2",mapState:x,mapMutations:_,mapGetters:E,mapActions:S,createNamespacedHelpers:function(e){return{mapState:x.bind(null,e),mapGetters:E.bind(null,e),mapMutations:_.bind(null,e),mapActions:S.bind(null,e)}},createLogger:function(e){void 0===e&&(e={});var t=e.collapsed;void 0===t&&(t=!0);var r=e.filter;void 0===r&&(r=function(e,t,r){return!0});var n=e.transformer;void 0===n&&(n=function(e){return e});var i=e.mutationTransformer;void 0===i&&(i=function(e){return e});var a=e.actionFilter;void 0===a&&(a=function(e,t){return!0});var s=e.actionTransformer;void 0===s&&(s=function(e){return e});var c=e.logMutations;void 0===c&&(c=!0);var l=e.logActions;void 0===l&&(l=!0);var u=e.logger;return void 0===u&&(u=console),function(e){var p=o(e.state);void 0!==u&&(c&&e.subscribe((function(e,a){var s=o(a);if(r(e,p,s)){var c=R(),l=i(e),d="mutation "+e.type+c;I(u,d,t),u.log("%c prev state","color: #9E9E9E; font-weight: bold",n(p)),u.log("%c mutation","color: #03A9F4; font-weight: bold",l),u.log("%c next state","color: #4CAF50; font-weight: bold",n(s)),A(u)}p=s})),l&&e.subscribeAction((function(e,r){if(a(e,r)){var n=R(),i=s(e),o="action "+e.type+n;I(u,o,t),u.log("%c action","color: #03A9F4; font-weight: bold",i),A(u)}})))}}};t.a=P}).call(this,r("c8ba"))},"2f6c":function(e,t,r){"use strict";r.d(t,"a",(function(){return o})),r.d(t,"b",(function(){return a}));var n=r("ad67"),i={Name:[],Document:["definitions"],OperationDefinition:["name","variableDefinitions","directives","selectionSet"],VariableDefinition:["variable","type","defaultValue","directives"],Variable:["name"],SelectionSet:["selections"],Field:["alias","name","arguments","directives","selectionSet"],Argument:["name","value"],FragmentSpread:["name","directives"],InlineFragment:["typeCondition","directives","selectionSet"],FragmentDefinition:["name","variableDefinitions","typeCondition","directives","selectionSet"],IntValue:[],FloatValue:[],StringValue:[],BooleanValue:[],NullValue:[],EnumValue:[],ListValue:["values"],ObjectValue:["fields"],ObjectField:["name","value"],Directive:["name","arguments"],NamedType:["name"],ListType:["type"],NonNullType:["type"],SchemaDefinition:["directives","operationTypes"],OperationTypeDefinition:["type"],ScalarTypeDefinition:["description","name","directives"],ObjectTypeDefinition:["description","name","interfaces","directives","fields"],FieldDefinition:["description","name","arguments","type","directives"],InputValueDefinition:["description","name","type","defaultValue","directives"],InterfaceTypeDefinition:["description","name","directives","fields"],UnionTypeDefinition:["description","name","directives","types"],EnumTypeDefinition:["description","name","directives","values"],EnumValueDefinition:["description","name","directives"],InputObjectTypeDefinition:["description","name","directives","fields"],DirectiveDefinition:["description","name","arguments","locations"],SchemaExtension:["directives","operationTypes"],ScalarTypeExtension:["name","directives"],ObjectTypeExtension:["name","interfaces","directives","fields"],InterfaceTypeExtension:["name","directives","fields"],UnionTypeExtension:["name","directives","types"],EnumTypeExtension:["name","directives","values"],InputObjectTypeExtension:["name","directives","fields"]},o=Object.freeze({});function a(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:i,a=void 0,l=Array.isArray(e),u=[e],p=-1,d=[],f=void 0,h=void 0,m=void 0,g=[],v=[],b=e;do{var y=++p===u.length,w=y&&0!==d.length;if(y){if(h=0===v.length?void 0:g[g.length-1],f=m,m=v.pop(),w){if(l)f=f.slice();else{for(var x={},_=0,E=Object.keys(f);_{try{t=new n(t,r)}catch(e){return!1}return t.test(e)}},"35d6":function(e,t,r){"use strict";function n(e,t,r){!function(e,t){const r=t._injectedStyles||(t._injectedStyles={});for(var n=0;n0){var n=r.connection.filter?r.connection.filter:[];n.sort();var i=t,o={};return n.forEach((function(e){o[e]=i[e]})),r.connection.key+"("+JSON.stringify(o)+")"}return r.connection.key}var a=e;if(t){var c=s()(t);a+="("+c+")"}return r&&Object.keys(r).forEach((function(e){-1===u.indexOf(e)&&(r[e]&&Object.keys(r[e]).length?a+="@"+e+"("+JSON.stringify(r[e])+")":a+="@"+e)})),a}function d(e,t){if(e.arguments&&e.arguments.length){var r={};return e.arguments.forEach((function(e){var n=e.name,i=e.value;return c(r,n,i,t)})),r}return null}function f(e){return e.alias?e.alias.value:e.name.value}function h(e){return"Field"===e.kind}function m(e){return"InlineFragment"===e.kind}function g(e){return e&&"id"===e.type&&"boolean"==typeof e.generated}function v(e,t){return void 0===t&&(t=!1),Object(o.a)({type:"id",generated:t},"string"==typeof e?{id:e,typename:void 0}:e)}function b(e){return null!=e&&"object"==typeof e&&"json"===e.type}function y(e,t){if(e.directives&&e.directives.length){var r={};return e.directives.forEach((function(e){r[e.name.value]=d(e,t)})),r}return null}function w(e,t){return void 0===t&&(t={}),function(e){return e?e.filter(E).map((function(e){var t=e.arguments;e.name.value,Object(i.b)(t&&1===t.length,14);var r=t[0];Object(i.b)(r.name&&"if"===r.name.value,15);var n=r.value;return Object(i.b)(n&&("Variable"===n.kind||"BooleanValue"===n.kind),16),{directive:e,ifArgument:r}})):[]}(e.directives).every((function(e){var r=e.directive,n=e.ifArgument,o=!1;return"Variable"===n.value.kind?(o=t[n.value.name.value],Object(i.b)(void 0!==o,13)):o=n.value.value,"skip"===r.name.value?!o:o}))}function x(e,t){return function(e){var t=[];return Object(n.b)(e,{Directive:function(e){t.push(e.name.value)}}),t}(t).some((function(t){return e.indexOf(t)>-1}))}function _(e){return e&&x(["client"],e)&&x(["export"],e)}function E(e){var t=e.name.value;return"skip"===t||"include"===t}function S(e,t){var r=t,n=[];return e.definitions.forEach((function(e){if("OperationDefinition"===e.kind)throw new i.a(11);"FragmentDefinition"===e.kind&&n.push(e)})),void 0===r&&(Object(i.b)(1===n.length,12),r=n[0].name.value),Object(o.a)(Object(o.a)({},e),{definitions:Object(o.f)([{kind:"OperationDefinition",operation:"query",selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:r}}]}}],e.definitions)})}function k(e){for(var t=[],r=1;r1){var n=[];t=ae(t,n);for(var i=1;i{switch(t){case"===":return"object"==typeof e&&(e=e.version),"object"==typeof r&&(r=r.version),e===r;case"!==":return"object"==typeof e&&(e=e.version),"object"==typeof r&&(r=r.version),e!==r;case"":case"=":case"==":return n(e,r,l);case"!=":return i(e,r,l);case">":return o(e,r,l);case">=":return a(e,r,l);case"<":return s(e,r,l);case"<=":return c(e,r,l);default:throw new TypeError("Invalid operator: "+t)}}},"56c3":function(e,t){e.exports={functional:!0,render(e,t){const{_c:r,_v:n,data:i,children:o=[]}=t,{class:a,staticClass:s,style:c,staticStyle:l,attrs:u={},...p}=i;return r("svg",{class:[a,s],style:[c,l],attrs:Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32"},u),...p},o.concat([r("path",{attrs:{d:"M26 25v6H6v-6H5a2 2 0 01-2-2v-9c0-.421.13-.812.353-1.134l3.9-9.96A3 3 0 0110.048 1H21.89a3 3 0 012.788 1.891l3.966 9.972c.224.323.355.715.355 1.137v9a2 2 0 01-2 2h-1zm-.26-2H26a1 1 0 001-1v-7a1 1 0 00-1-1H6a1 1 0 00-1 1v7a1 1 0 001 1h.25L8 16h15.927l1.814 7zm.559-11l-3.11-7.745A2 2 0 0021.334 3H10.61a2 2 0 00-1.86 1.265L5.695 12h20.604zM8 24h16l-1.314-6H9.25L8 24zm0 2v3h16v-3H8zm4-6h2.2l-.2 2h-2.5l.5-2zm5.8 0H20l.5 2H18l-.2-2z"}})]))}}},"59c8":function(e){e.exports=JSON.parse('{"getStarted":"Get Started","signIn":"Sign In","signUp":"Sign Up","signInUp":"Sign In / Up","signOut":"Sign Out","error":"Error","fixError":"Fix Error","closeLaunchpad":"Close and continue to webGUI","installPlugin":"Install Plugin","noThanks":"No thanks","closePromo":"Close My Servers details and continue to webGUI","promoHeading":"Enhance your Unraid experience with these
My Servers (BETA) features","learnMore":"Learn more","checkoutTheMyServersDocs":"Checkout the My Servers docs","popUp":"Pop-up","backToPopUp":"Back to @:popUp","closePopUp":"Close @:popUp","close":"Close","contactSupport":"Contact Support","lanIp":"LAN IP {0}","continueToUnraid":"Continue to Unraid","year":"year","years":"years","month":"month","months":"months","day":"day","days":"days","hour":"hour","hours":"hours","minute":"minute","minutes":"minutes","second":"second","seconds":"seconds","ago":"ago","basicPlusPro":{"heading":"Thank you for choosing Unraid OS and My Servers!","message":{"registered":"Connect to My Servers by signing in to Unraid.net","upgradeEligible":"To support more storage devices as your server grows, click Upgrade Key."}},"actions":{"purchase":"Purchase Key","upgrade":"Upgrade Key","recover":"Recover Key","replace":"Replace Key","replaceIneligible":"Replace Key Ineligible","startTrial":"Start Free 30 Day Trial","extend":"Extend Trial","signOutUnraidNet":"Sign Out of Unraid.net","redeemActivationCode":"Redeem Activation Code"},"stateData":{"ENOKEYFILE":{"humanReadable":"No Keyfile","heading":"Let\'s unleash your hardware!","message":"

Your server will not be usable until you purchase a Registration key or install a free 30-day Trial key. A Trial key provides all the functionality of a Pro Registration key.

Registration keys are bound to your USB Flash boot device serial number (GUID). Please use a high quality name brand device at least 1GB in size.

Note: USB memory card readers are generally not supported because most do not present unique serial numbers.

Important:

  • Please make sure your server time is accurate to within 5 minutes
  • Please make sure there is a DNS server specified
"},"TRIAL":{"humanReadable":"Trial","heading":"Thank you for choosing Unraid OS!","message":"

Your Trial key includes all the functionality and device support of a Pro key.

After your Trial has reached expiration, your server still functions normally until the next time you Stop the array or reboot your server.

At that point you may either purchase a license key or request a Trial extension.

","_extraMsg":"

You have {parsedExpireTime} remaining on your Trial key.

"},"EEXPIRED":{"humanReadable":"Trial Expired","heading":"Your Trial has expired","message":{"base":"To continue using Unraid OS you may purchase a license key.","extensionNotEligible":"You have used all your Trial extensions. @:stateData.EEXPIRED.message.base","extensionEligible":"@:stateData.EEXPIRED.message.base Alternately, you may request a Trial extension."}},"BASIC":{"humanReadable":"Basic"},"PLUS":{"humanReadable":"Plus"},"PRO":{"humanReadable":"Pro"},"EGUID":{"humanReadable":"GUID Error","error":{"heading":"Registration key / GUID mismatch","message":{"default":"The license key file does not correspond to the USB Flash boot device. Please copy the correct key file to the /config directory on your USB Flash boot device or choose Purchase Key.","replacementIneligible":"Your Unraid registration key is ineligible for replacement as it has been replaced within the last 12 months.","replacementEligible":"The license key file does not correspond to the USB Flash boot device. Please copy the correct key file to the /config directory on your USB Flash boot device or choose Purchase Key or Replace Key.","blacklisted":"Your Unraid registration key is ineligible for replacement as it is blacklisted."}}},"ENOKEYFILE2":{"humanReadable":"Missing key file","error":{"heading":"@:stateData.ENOKEYFILE2.humanReadable","message":"It appears that your license key file is corrupted or missing. The key file should be located in the /config directory on your USB Flash boot device. If you do not have a backup copy of your license key file you may install the My Servers (beta) plugin to attempt to recover your key. If this was an expired Trial installation, you may purchase a license key."}},"ETRIAL":{"humanReadable":"Invalid installation","error":{"heading":"@:stateData.ETRIAL.humanReadable","message":"It is not possible to use a Trial key with an existing Unraid OS installation. You may purchase a license key corresponding to this USB Flash device to continue using this installation."}},"ENOKEYFILE1":{"humanReadable":"No Keyfile","error":{"heading":"No USB flash configuration data","message":"There is a problem with your USB Flash device"}},"ENOFLASH":{"humanReadable":"No Flash","error":{"heading":"Cannot access your USB Flash boot device","message":"There is a physical problem accessing your USB Flash boot device"}},"EGUID1":{"humanReadable":"Multiple License Keys Present","error":{"heading":"@:stateData.EGUID1.humanReadable","message":"There are multiple license key files present on your USB flash device and none of them correspond to the USB Flash boot device. Please remove all key files, except the one you want to replace, from the /config directory on your USB Flash boot device. Alternately you may purchase a license key for this USB flash device. If you want to replace one of your license keys with a new key bound to this USB Flash device, please first remove all other key files first."}},"EBLACKLISTED":{"humanReadable":"BLACKLISTED","error":{"heading":"Blacklisted USB Flash GUID","message":"This USB Flash boot device has been blacklisted. This can occur as a result of transferring your license key to a replacement USB Flash device, and you are currently booted from your old USB Flash device. A USB Flash device may also be blacklisted if we discover the serial number is not unique – this is common with USB card readers."}},"EBLACKLISTED1":{"humanReadable":"@:stateData.EBLACKLISTED.humanReadable","error":{"heading":"USB Flash device error","message":"This USB Flash device has an invalid GUID. Please try a different USB Flash device"}},"EBLACKLISTED2":{"humanReadable":"@:stateData.EBLACKLISTED.humanReadable","error":{"heading":"USB Flash has no serial number","message":"@:stateData.EBLACKLISTED.error.message"}},"ENOCONN":{"humanReadable":"Trial Requires Internet Connection","error":{"heading":"Cannot validate Unraid Trial key","message":"Your Trial key requires an internet connection. Please check Settings > Network"}},"STALE":{"humanReadable":"Stale","error":{"heading":"Stale Server","message":"Please refresh the page to ensure you load your latest configuration"}}},"upc":{"avatarAlt":"{0}\'s Avatar","confirmClosure":"Confirm closure then continue to webGUI","closeDropdown":"Close dropdown","openDropdown":"Open dropdown","pleaseConfirmClosureYouHaveOpenPopUp":"Please confirm closure. You have an open pop-up.","trialHasExpiredSeeOptions":"Trial has expired, see options below","errorCertRequiresSignIn":"Sign In before your Unraid.net SSL certificate expires","removeMyServersPlugin":"Remove My Servers plugin","continueUsingMyServers":"Continue using My Servers","confirmMyServersPluginRemoval":"Confirm My Servers plugin removal","removingMyServersPlugin":"Removing My Servers plugin…","enhanceYourExperienceWithMyServers":"Enhance your experience with My Servers","connectYourUnraidnetAccountToGetStarted":"Connect your Unraid.net account to get started","thankYouForInstallingMyServers":"Thank you installing My Servers!","lanIpCopied":"LAN IP Copied","installingMyServers":"Installing My Servers (beta)","noRemoteApikeyRegisteredWithPlg":{"heading":"My Servers Error","msg":"Unraid.net re-authentication required"},"errorTooManyDisks":{"heading":"Too many devices","msg":{"base":"You must upgrade your key to support more devices.","basic":"Your Basic key supports 6 devices.","plus":"Your Plus key supports 12 devices."}},"extraLinks":{"newTab":"Opens {0} in new tab","myServers":"My Servers Dashboard","forums":"Unraid Forums","settings":{"text":"Settings","title":"Settings > Management Access • Unraid.net"}},"meta":{"trial":{"active":{"date":"Trial key expires at {date}","timeDiff":"Trial expires in {timeDiff}"},"expired":{"date":"Trial key expired at {date}","timeDiff":"Trial expired {timeDiff}"}},"uptime":{"date":"Server up since {date}","readable":"Uptime {timeDiff}"}},"myServers":{"heading":"My Servers","beta":"beta","restarting":"Restarting…","errors":{"unraidApi":{"heading":"Unraid API Error","message":"Failed to connect to Unraid API."},"myServers":{"heading":"My Servers Error","message":"Please wait a moment and reload the page."}},"closeDetails":"Close Details","loading":"Loading My Servers data","displayingLastKnown":"Displaying last known server data","mothership":{"connected":"Connected to Mothership","notConnected":"Not Connected to Mothership"},"accessLabels":{"current":"Current server","local":"Local access","offline":"Server Offline","remote":"Remote access","unavailable":"Access unavailable"},"api":{"start":"Restart unraid-api","startTitle":"Executes `unraid-api start`; no terminal needed","stop":"Stop unraid-api"}},"opensNewHttpsWindow":{"base":"Opens new HTTPS window to {0}","signIn":"@:upc.opensNewHttpsWindow.base @:signIn","signOut":"@:upc.opensNewHttpsWindow.base @:signOut","purchase":"@:upc.opensNewHttpsWindow.base @:actions.purchase","upgrade":"@:upc.opensNewHttpsWindow.base @:actions.upgrade"},"signInActions":{"resolve":"@:signIn to resolve","purchaseKey":"@:signIn to @:actions.purchase","purchaseKeyOrExtendTrial":"@:upc.signInActions.purchaseKey or @:actions.extend"}},"wanIpCheck":{"checking":"Checking Wan IPs","avatarAlt":"{0}\'s Avatar","match":"Remark: your WAN IPv4 is {0}","mismatch":"Remark: Unraid\'s WAN IPv4 {0} does not match your client\'s WAN IPv4 {1}. This may indicate a complex network that will not work with this Remote Access solution. Ignore this message if you are currently connected via Remote Access or VPN","resolveError":"DNS issue, unable to resolve wanip4.unraid.net"},"regWizPopUp":{"regWiz":"Registration Wizard","toHome":"To Registration Wizard Home","continueTrial":"Continue Trial","serverInfoToggle":"Toggle server info visibility","youCanSafelyCloseThisWindow":"You can safely close this window","automaticallyClosingIn":"Automatically closing in","byeBye":"bye, bye 👋","browserWillSelfDestructIn":"Browser will self destruct in","closingPopUpMayLeadToErrors":"Closing this pop-up window while actions are being preformed may lead to unintended errors.","goBack":"Go Back","shutDown":"Shut Down","haveAccountSignIn":"Already have an account? Sign In","noAccountSignUp":"Don\'t have an account? Sign Up","willConnectYourServerToMyServers":"This will connect your server to My Servers BETA","serverInfo":{"flash":"Flash","product":"Product","GUID":"GUID","name":"Name","ip":"IP"},"forms":{"displayName":"Display Name","emailAddress":"Email Address","displayNameOrEmailAddress":"@:regWizPopUp.forms.displayName or @:regWizPopUp.forms.emailAddress","displayNameRootMessage":"Use your Unraid.net credentials, not your local server credentials.","honeyPotCopy":"If you fill this field out then your email will not be sent","fieldRequired":"This field is required","submit":"Submit","submitting":"submitting…","notValid":"Form not valid","cancel":"Cancel","confirm":"Confirm","createMyAccount":"Create My Account","subject":"Subject","password":"Password","togglePasswordVisibility":"Toggle Password Visibility","message":"Message","confirmPassword":"Confirm Password","passwordMustMatch":"Password confirmation must match","passwordMinimum":"8 or more characters","comments":"comments","newsletterCopy":"Sign me up for the monthly Unraid newsletter: a digest of recent blog posts, community videos, popular forum threads, product announcements, and more.","terms":{"iAgree":"I agree to the","text":"Terms of Use"}},"routes":{"extendTrial":{"heading":{"loading":"Extending Trial","error":"Trial Extension Failed"},"message":"Not ready to purchase?
Receive an additional 15 days for your trial."},"forgotPassword":{"heading":"Forgot Password","subheading":"After resetting your password come back to the Registration Wizard pop-up window to Sign In and complete your server\'s registration.","resetPasswordNow":"Reset Password Now","backToSignIn":"Back to Sign In"},"signIn":{"heading":{"signIn":"Unraid.net Sign In","recover":"Unraid.net Sign In to Recover Key","replace":"Unraid.net Sign In to Replace Key"},"subheading":"Please sign in with your Unraid.net account","form":{"replacementConditions":{"name":"Acknowledge Replacement Conditions","label":"I acknowledge that replacing a license key results in permanently blacklisting the previous USB Flash GUID."},"label":{"password":{"replace":"Unraid.net account password"}}}},"signUp":{"heading":"Create Unraid.net Account","subheading":"This will start your free 30-day Trial"},"signOut":{"heading":"Unraid.net Sign Out"},"success":{"heading":{"username":"Hi {0}!","default":"Success!"},"subheading":{"extention":"Your trial will expire in 15 days.","newTrial":"Your trial will expire in 30 days."},"signIn":{"tileTitle":{"actionFail":"{0} was not signed in to your Unraid.net account","actionSuccess":"{0} is signed in to your Unraid.net account","loading":"Signing in {0} to Unraid.net account"}},"signOut":{"tileTitle":{"actionFail":"{0} was not signed out of your Unraid.net account","actionSuccess":"{0} was signed out of your Unraid.net account","loading":"Signing out {0} from Unraid.net account"}},"keys":{"trial":"Trial","basic":"Basic","plus":"Plus","pro":"Pro"},"extended":"{0} Key Extended","recovered":"{0} Key Recovered","replaced":"{0} Key Replaced","created":"{0} Key Created","install":{"loading":"Installing {0} Key","error":"{0} Key Install Error","success":"Installed {0} Key","manualInstructions":"To manually install the key paste the key file url into the Key file URL field on the webGUI Registration page and then click Install Key","copyFail":"Unable to copy","copySuccess":"Copied key url!","copyButton":"Copy Key URL","copyBeforeClose":"Please copy the Key URL before closing this window"},"timeout":"Communication with {0} has timed out","loading1":"Please keep this window open.","loading2":"Still working our magic","countdown":{"success":{"prefix":"Auto closing in","text":"You can safely close this window"},"error":{"prefix":"Auto redirecting in","text":"Back to Registration Home","complete":"Back in a flash ⚡️"}}},"troubleshoot":{"heading":{"default":"Troubleshoot","success":"Thank you for contacting Unraid."},"subheading":{"default":"Forgot what Unraid.net account you used? Have a USB flash device that already has an account associated with it? Just give us the details about what happened and we\'ll do our best to get you up and running again.","success":"We have received your e-mail and will respond in the order it was received. While we strive to respond to all requests as quickly as possible, please allow for up to 3 business days for a response."},"relevantServerData":"Your USB Flash GUID and other relevant server data will also be sent"},"verifyEmail":{"heading":"Verify Email","form":{"verificationCode":"verification code","verifyCode":"Paste / Enter code"},"noCode":"Didn\'t get code?"},"whatIsMyServers":{"heading":"What is My Servers?","subheading":"Expand your server\'s capabilities","copy":"With an Unraid.net account you can start using My Servers (beta) which gives you access to the following features:","features":{"secureRemoteAccess":{"heading":"Secure remote access","copy":"Whether you need to add a share, container, or virtual machine, do it all from the webGui from anytime and anywhere using HTTPS. Best of all, all SSL certificates are verified by Let\'s Encrypt, so no browser security warnings."},"realTimeMonitoring":{"heading":"Real-time Monitoring","copy":"Get quick real-time info on the status of your servers such as storage, container, and VM usage. And not just for one server, but all the servers in your Unraid fleet!"},"usbFlashBackup":{"heading":"USB Flash Backup","copy":"Click a button and your flash is automatically backed up to Unraid.net, enabling easy recovery in the event of a device failure. Never self-manage/host your flash backups again!"},"regKeyManagement":{"heading":"Registration key management","copy":"Download any registration key linked to your account. Upgrade keys to higher editions."},"plusMore":{"heading":"Plus more on the way","copy":"All you need is an active internet connection, an Unraid.net account, and the My Servers plugin. Get started by installing the plugin."}}},"replaceKey":{"subheading":{"registered":"A record of your replacement will be sent to your Unraid.net account email address","notRegistered":"A record of your replacement will be sent to this email"}},"notFound":{"subheading":"Page Not Found"},"notAllowed":{"subheading":"Page Not Allowed"}}},"upcTrigger":{"upgrade":"To support more storage devices as your server grows click the Open Dropdown button","default":"Key management is done via the dropdown in the top right of the webGUI on every page","open":"Open Dropdown"},"yargYePirate":"Oh no! Are you pirating Unraid OS?
Are you ready to buy a real license?","keyFileNotValid":"Key file not valid","installFailed":{"heading":"My Servers plugin install failed","message":"The My Servers plugin install is incomplete. Please uninstall and reinstall the My Servers plugin. Be sure to let the install complete before you close the window."}}')},"5a0c":function(e,t,r){e.exports=function(){"use strict";var e=6e4,t=36e5,r="millisecond",n="second",i="minute",o="hour",a="day",s="week",c="month",l="quarter",u="year",p="date",d="Invalid Date",f=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,h=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,m={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_")},g=function(e,t,r){var n=String(e);return!n||n.length>=t?e:""+Array(t+1-n.length).join(r)+e},v={s:g,z:function(e){var t=-e.utcOffset(),r=Math.abs(t),n=Math.floor(r/60),i=r%60;return(t<=0?"+":"-")+g(n,2,"0")+":"+g(i,2,"0")},m:function e(t,r){if(t.date()e.replace(a,(e,t)=>t?t.toUpperCase():""),c=/\B([A-Z])/g,l=e=>e.replace(c,"-$1").toLowerCase();function u(e,t,r){e[t]=[].concat(e[t]||[]),e[t].unshift(r)}function p(e,t){if(e){(e.$options[t]||[]).forEach(t=>{t.call(e)})}}function d(e,t,{type:r}={}){if((e=>/function Boolean/.test(String(e)))(r))return"true"===e||"false"===e?"true"===e:""===e||e===t||null!=e||e;if((e=>/function Number/.test(String(e)))(r)){const t=parseFloat(e,10);return isNaN(t)?e:t}return e}function f(e,t){const r=[];for(let n=0,i=t.length;n(e[t]=c[r[n]],e),{}),u(t,"beforeCreate",(function(){const e=this.$emit;this.$emit=(t,...r)=>(this.$root.$options.customElement.dispatchEvent(function(e,t){return new CustomEvent(e,{bubbles:!1,cancelable:!1,detail:t})}(t,r)),e.call(this,t,...r))})),u(t,"created",(function(){i.forEach(e=>{this.$root.props[e]=this[e]})})),i.forEach(e=>{Object.defineProperty(m.prototype,e,{get(){return this._wrapper.props[e]},set(t){this._wrapper.props[e]=t},enumerable:!1,configurable:!0})}),a=!0}function h(e,t){const r=s(t),n=e.hasAttribute(t)?e.getAttribute(t):void 0;e._wrapper.props[r]=d(n,t,o[r])}class m extends HTMLElement{constructor(){const r=super();r.attachShadow({mode:"open"});const n=r._wrapper=new e({name:"shadow-root",customElement:r,shadowRoot:r.shadowRoot,data:()=>({props:{},slotChildren:[]}),render(e){return e(t,{ref:"inner",props:this.props},this.slotChildren)}});new MutationObserver(e=>{let t=!1;for(let n=0;n{e.props=function(e){const t={};return e.forEach(e=>{t[e]=void 0}),t}(i),n.forEach(e=>{h(this,e)})};a?r():t().then(e=>{(e.__esModule||"Module"===e[Symbol.toStringTag])&&(e=e.default),c(e),r()}),e.slotChildren=Object.freeze(f(e.$createElement,this.childNodes)),e.$mount(),this.shadowRoot.appendChild(e.$el)}}disconnectedCallback(){p(this.vueComponent,"deactivated")}}return r||c(t),m};function v(e,t,r,n,i,o,a,s){var c,l="function"==typeof e?e.options:e;if(t&&(l.render=t,l.staticRenderFns=r,l._compiled=!0),n&&(l.functional=!0),o&&(l._scopeId="data-v-"+o),a?(c=function(e){(e=e||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext)||"undefined"==typeof __VUE_SSR_CONTEXT__||(e=__VUE_SSR_CONTEXT__),i&&i.call(this,e),e&&e._registeredComponents&&e._registeredComponents.add(a)},l._ssrRegister=c):i&&(c=s?function(){i.call(this,(l.functional?this.parent:this).$root.$options.shadowRoot)}:i),c)if(l.functional){l._injectStyles=c;var u=l.render;l.render=function(e,t){return c.call(t),u(e,t)}}else{var p=l.beforeCreate;l.beforeCreate=p?[].concat(p,c):[c]}return{exports:e,options:l}}r("24fb"),r("35d6");var b=r("2f62"),y=["compactDisplay","currency","currencyDisplay","currencySign","localeMatcher","notation","numberingSystem","signDisplay","style","unit","unitDisplay","useGrouping","minimumIntegerDigits","minimumFractionDigits","maximumFractionDigits","minimumSignificantDigits","maximumSignificantDigits"];function w(e,t){"undefined"!=typeof console&&(console.warn("[vue-i18n] "+e),t&&console.warn(t.stack))}var x=Array.isArray;function _(e){return null!==e&&"object"==typeof e}function E(e){return"boolean"==typeof e}function S(e){return"string"==typeof e}var k=Object.prototype.toString;function O(e){return"[object Object]"===k.call(e)}function T(e){return null==e}function I(e){return"function"==typeof e}function A(){for(var e=[],t=arguments.length;t--;)e[t]=arguments[t];var r=null,n=null;return 1===e.length?_(e[0])||x(e[0])?n=e[0]:"string"==typeof e[0]&&(r=e[0]):2===e.length&&("string"==typeof e[0]&&(r=e[0]),(_(e[1])||x(e[1]))&&(n=e[1])),{locale:r,params:n}}function R(e){return JSON.parse(JSON.stringify(e))}function C(e,t){return!!~e.indexOf(t)}var P=Object.prototype.hasOwnProperty;function N(e,t){return P.call(e,t)}function M(e){for(var t=arguments,r=Object(e),n=1;n/g,">").replace(/"/g,""").replace(/'/g,"'")}(e[t]))})),e}var L={name:"i18n",functional:!0,props:{tag:{type:[String,Boolean,Object],default:"span"},path:{type:String,required:!0},locale:{type:String},places:{type:[Array,Object]}},render:function(e,t){var r=t.data,n=t.parent,i=t.props,o=t.slots,a=n.$i18n;if(a){var s=i.path,c=i.locale,l=i.places,u=o(),p=a.i(s,c,function(e){var t;for(t in e)if("default"!==t)return!1;return Boolean(t)}(u)||l?function(e,t){var r=t?function(e){return Array.isArray(e)?e.reduce(F,{}):Object.assign({},e)}(t):{};if(!e)return r;var n=(e=e.filter((function(e){return e.tag||""!==e.text.trim()}))).every($);return e.reduce(n?j:F,r)}(u.default,l):u),d=i.tag&&!0!==i.tag||!1===i.tag?i.tag:"span";return d?e(d,r,p):p}}};function j(e,t){return t.data&&t.data.attrs&&t.data.attrs.place&&(e[t.data.attrs.place]=t),e}function F(e,t,r){return e[r]=t,e}function $(e){return Boolean(e.data&&e.data.attrs&&e.data.attrs.place)}var V,G={name:"i18n-n",functional:!0,props:{tag:{type:[String,Boolean,Object],default:"span"},value:{type:Number,required:!0},format:{type:[String,Object]},locale:{type:String}},render:function(e,t){var r=t.props,n=t.parent,i=t.data,o=n.$i18n;if(!o)return null;var a=null,s=null;S(r.format)?a=r.format:_(r.format)&&(r.format.key&&(a=r.format.key),s=Object.keys(r.format).reduce((function(e,t){var n;return C(y,t)?Object.assign({},e,((n={})[t]=r.format[t],n)):e}),null));var c=r.locale||o.locale,l=o._ntp(r.value,c,a,s),u=l.map((function(e,t){var r,n=i.scopedSlots&&i.scopedSlots[e.type];return n?n(((r={})[e.type]=e.value,r.index=t,r.parts=l,r)):e.value})),p=r.tag&&!0!==r.tag||!1===r.tag?r.tag:"span";return p?e(p,{attrs:i.attrs,class:i.class,staticClass:i.staticClass},u):u}};function z(e,t,r){H(e,r)&&Y(e,t,r)}function B(e,t,r,n){if(H(e,r)){var i=r.context.$i18n;(function(e,t){var r=t.context;return e._locale===r.$i18n.locale})(e,r)&&D(t.value,t.oldValue)&&D(e._localeMessage,i.getLocaleMessage(i.locale))||Y(e,t,r)}}function W(e,t,r,n){if(r.context){var i=r.context.$i18n||{};t.modifiers.preserve||i.preserveDirectiveContent||(e.textContent=""),e._vt=void 0,delete e._vt,e._locale=void 0,delete e._locale,e._localeMessage=void 0,delete e._localeMessage}else w("Vue instance does not exists in VNode context")}function H(e,t){var r=t.context;return r?!!r.$i18n||(w("VueI18n instance does not exists in Vue instance"),!1):(w("Vue instance does not exists in VNode context"),!1)}function Y(e,t,r){var n,i,o=function(e){var t,r,n,i;return S(e)?t=e:O(e)&&(t=e.path,r=e.locale,n=e.args,i=e.choice),{path:t,locale:r,args:n,choice:i}}(t.value),a=o.path,s=o.locale,c=o.args,l=o.choice;if(a||s||c)if(a){var u=r.context;e._vt=e.textContent=null!=l?(n=u.$i18n).tc.apply(n,[a,l].concat(q(s,c))):(i=u.$i18n).t.apply(i,[a].concat(q(s,c))),e._locale=u.$i18n.locale,e._localeMessage=u.$i18n.getLocaleMessage(u.$i18n.locale)}else w("`path` is required in v-t directive");else w("value type not supported")}function q(e,t){var r=[];return e&&r.push(e),t&&(Array.isArray(t)||O(t))&&r.push(t),r}function Q(e,t){void 0===t&&(t={bridge:!1}),Q.installed=!0,(V=e).version&&Number(V.version.split(".")[0]),function(e){e.prototype.hasOwnProperty("$i18n")||Object.defineProperty(e.prototype,"$i18n",{get:function(){return this._i18n}}),e.prototype.$t=function(e){for(var t=[],r=arguments.length-1;r-- >0;)t[r]=arguments[r+1];var n=this.$i18n;return n._t.apply(n,[e,n.locale,n._getMessages(),this].concat(t))},e.prototype.$tc=function(e,t){for(var r=[],n=arguments.length-2;n-- >0;)r[n]=arguments[n+2];var i=this.$i18n;return i._tc.apply(i,[e,i.locale,i._getMessages(),this,t].concat(r))},e.prototype.$te=function(e,t){var r=this.$i18n;return r._te(e,r.locale,r._getMessages(),t)},e.prototype.$d=function(e){for(var t,r=[],n=arguments.length-1;n-- >0;)r[n]=arguments[n+1];return(t=this.$i18n).d.apply(t,[e].concat(r))},e.prototype.$n=function(e){for(var t,r=[],n=arguments.length-1;n-- >0;)r[n]=arguments[n+1];return(t=this.$i18n).n.apply(t,[e].concat(r))}}(V),V.mixin(function(e){function t(){this!==this.$root&&this.$options.__INTLIFY_META__&&this.$el&&this.$el.setAttribute("data-intlify",this.$options.__INTLIFY_META__)}return void 0===e&&(e=!1),e?{mounted:t}:{beforeCreate:function(){var e=this.$options;if(e.i18n=e.i18n||(e.__i18n?{}:null),e.i18n){if(e.i18n instanceof pe){if(e.__i18n)try{var t=e.i18n&&e.i18n.messages?e.i18n.messages:{};e.__i18n.forEach((function(e){t=M(t,JSON.parse(e))})),Object.keys(t).forEach((function(r){e.i18n.mergeLocaleMessage(r,t[r])}))}catch(e){}this._i18n=e.i18n,this._i18nWatcher=this._i18n.watchI18nData()}else if(O(e.i18n)){var r=this.$root&&this.$root.$i18n&&this.$root.$i18n instanceof pe?this.$root.$i18n:null;if(r&&(e.i18n.root=this.$root,e.i18n.formatter=r.formatter,e.i18n.fallbackLocale=r.fallbackLocale,e.i18n.formatFallbackMessages=r.formatFallbackMessages,e.i18n.silentTranslationWarn=r.silentTranslationWarn,e.i18n.silentFallbackWarn=r.silentFallbackWarn,e.i18n.pluralizationRules=r.pluralizationRules,e.i18n.preserveDirectiveContent=r.preserveDirectiveContent),e.__i18n)try{var n=e.i18n&&e.i18n.messages?e.i18n.messages:{};e.__i18n.forEach((function(e){n=M(n,JSON.parse(e))})),e.i18n.messages=n}catch(e){}var i=e.i18n.sharedMessages;i&&O(i)&&(e.i18n.messages=M(e.i18n.messages,i)),this._i18n=new pe(e.i18n),this._i18nWatcher=this._i18n.watchI18nData(),(void 0===e.i18n.sync||e.i18n.sync)&&(this._localeWatcher=this.$i18n.watchLocale()),r&&r.onComponentInstanceCreated(this._i18n)}}else this.$root&&this.$root.$i18n&&this.$root.$i18n instanceof pe?this._i18n=this.$root.$i18n:e.parent&&e.parent.$i18n&&e.parent.$i18n instanceof pe&&(this._i18n=e.parent.$i18n)},beforeMount:function(){var e=this.$options;e.i18n=e.i18n||(e.__i18n?{}:null),e.i18n?(e.i18n instanceof pe||O(e.i18n))&&(this._i18n.subscribeDataChanging(this),this._subscribing=!0):(this.$root&&this.$root.$i18n&&this.$root.$i18n instanceof pe||e.parent&&e.parent.$i18n&&e.parent.$i18n instanceof pe)&&(this._i18n.subscribeDataChanging(this),this._subscribing=!0)},mounted:t,beforeDestroy:function(){if(this._i18n){var e=this;this.$nextTick((function(){e._subscribing&&(e._i18n.unsubscribeDataChanging(e),delete e._subscribing),e._i18nWatcher&&(e._i18nWatcher(),e._i18n.destroyVM(),delete e._i18nWatcher),e._localeWatcher&&(e._localeWatcher(),delete e._localeWatcher)}))}}}}(t.bridge)),V.directive("t",{bind:z,update:B,unbind:W}),V.component(L.name,L),V.component(G.name,G),V.config.optionMergeStrategies.i18n=function(e,t){return void 0===t?e:t}}var K=function(){this._caches=Object.create(null)};K.prototype.interpolate=function(e,t){if(!t)return[e];var r=this._caches[e];return r||(r=function(e){var t=[],r=0,n="";for(;r0)p--,u=4,d[0]();else{if(p=0,void 0===r)return!1;if(!1===(r=re(r)))return!1;d[1]()}};null!==u;)if(l++,"\\"!==(t=e[l])||!f()){if(i=te(t),8===(o=(s=Z[u])[i]||s.else||8))return;if(u=o[0],(a=d[o[1]])&&(n=void 0===(n=o[2])?t:n,!1===a()))return;if(7===u)return c}}(e))&&(this._cache[e]=t),t||[]},ne.prototype.getPathValue=function(e,t){if(!_(e))return null;var r=this.parsePath(t);if(0===r.length)return null;for(var n=r.length,i=e,o=0;o/,ae=/(?:@(?:\.[a-z]+)?:(?:[\w\-_|./]+|\([\w\-_|./]+\)))/g,se=/^@(?:\.([a-z]+))?:/,ce=/[()]/g,le={upper:function(e){return e.toLocaleUpperCase()},lower:function(e){return e.toLocaleLowerCase()},capitalize:function(e){return""+e.charAt(0).toLocaleUpperCase()+e.substr(1)}},ue=new K,pe=function(e){var t=this;void 0===e&&(e={}),!V&&"undefined"!=typeof window&&window.Vue&&Q(window.Vue);var r=e.locale||"en-US",n=!1!==e.fallbackLocale&&(e.fallbackLocale||"en-US"),i=e.messages||{},o=e.dateTimeFormats||e.datetimeFormats||{},a=e.numberFormats||{};this._vm=null,this._formatter=e.formatter||ue,this._modifiers=e.modifiers||{},this._missing=e.missing||null,this._root=e.root||null,this._sync=void 0===e.sync||!!e.sync,this._fallbackRoot=void 0===e.fallbackRoot||!!e.fallbackRoot,this._formatFallbackMessages=void 0!==e.formatFallbackMessages&&!!e.formatFallbackMessages,this._silentTranslationWarn=void 0!==e.silentTranslationWarn&&e.silentTranslationWarn,this._silentFallbackWarn=void 0!==e.silentFallbackWarn&&!!e.silentFallbackWarn,this._dateTimeFormatters={},this._numberFormatters={},this._path=new ne,this._dataListeners=new Set,this._componentInstanceCreatedListener=e.componentInstanceCreatedListener||null,this._preserveDirectiveContent=void 0!==e.preserveDirectiveContent&&!!e.preserveDirectiveContent,this.pluralizationRules=e.pluralizationRules||{},this._warnHtmlInMessage=e.warnHtmlInMessage||"off",this._postTranslation=e.postTranslation||null,this._escapeParameterHtml=e.escapeParameterHtml||!1,this.getChoiceIndex=function(e,r){var n=Object.getPrototypeOf(t);if(n&&n.getChoiceIndex)return n.getChoiceIndex.call(t,e,r);return t.locale in t.pluralizationRules?t.pluralizationRules[t.locale].apply(t,[e,r]):function(e,t){return e=Math.abs(e),2===t?e?e>1?1:0:1:e?Math.min(e,2):0}(e,r)},this._exist=function(e,r){return!(!e||!r||T(t._path.getPathValue(e,r))&&!e[r])},"warn"!==this._warnHtmlInMessage&&"error"!==this._warnHtmlInMessage||Object.keys(i).forEach((function(e){t._checkLocaleMessage(e,t._warnHtmlInMessage,i[e])})),this._initVM({locale:r,fallbackLocale:n,messages:i,dateTimeFormats:o,numberFormats:a})},de={vm:{configurable:!0},messages:{configurable:!0},dateTimeFormats:{configurable:!0},numberFormats:{configurable:!0},availableLocales:{configurable:!0},locale:{configurable:!0},fallbackLocale:{configurable:!0},formatFallbackMessages:{configurable:!0},missing:{configurable:!0},formatter:{configurable:!0},silentTranslationWarn:{configurable:!0},silentFallbackWarn:{configurable:!0},preserveDirectiveContent:{configurable:!0},warnHtmlInMessage:{configurable:!0},postTranslation:{configurable:!0},sync:{configurable:!0}};pe.prototype._checkLocaleMessage=function(e,t,r){var n=function(e,t,r,i){if(O(r))Object.keys(r).forEach((function(o){var a=r[o];O(a)?(i.push(o),i.push("."),n(e,t,a,i),i.pop(),i.pop()):(i.push(o),n(e,t,a,i),i.pop())}));else if(x(r))r.forEach((function(r,o){O(r)?(i.push("["+o+"]"),i.push("."),n(e,t,r,i),i.pop(),i.pop()):(i.push("["+o+"]"),n(e,t,r,i),i.pop())}));else if(S(r)){if(oe.test(r)){var o="Detected HTML in message '"+r+"' of keypath '"+i.join("")+"' at '"+t+"'. Consider component interpolation with '' to avoid XSS. See https://bit.ly/2ZqJzkp";"warn"===e?w(o):"error"===e&&function(e,t){"undefined"!=typeof console&&(console.error("[vue-i18n] "+e),t&&console.error(t.stack))}(o)}}};n(t,e,r,[])},pe.prototype._initVM=function(e){var t=V.config.silent;V.config.silent=!0,this._vm=new V({data:e,__VUE18N__INSTANCE__:!0}),V.config.silent=t},pe.prototype.destroyVM=function(){this._vm.$destroy()},pe.prototype.subscribeDataChanging=function(e){this._dataListeners.add(e)},pe.prototype.unsubscribeDataChanging=function(e){!function(e,t){if(e.delete(t));}(this._dataListeners,e)},pe.prototype.watchI18nData=function(){var e=this;return this._vm.$watch("$data",(function(){for(var t=function(e){var t=[];return e.forEach((function(e){return t.push(e)})),t}(e._dataListeners),r=t.length;r--;)V.nextTick((function(){t[r]&&t[r].$forceUpdate()}))}),{deep:!0})},pe.prototype.watchLocale=function(){if(!this._sync||!this._root)return null;var e=this._vm;return this._root.$i18n.vm.$watch("locale",(function(t){e.$set(e,"locale",t),e.$forceUpdate()}),{immediate:!0})},pe.prototype.onComponentInstanceCreated=function(e){this._componentInstanceCreatedListener&&this._componentInstanceCreatedListener(e,this)},de.vm.get=function(){return this._vm},de.messages.get=function(){return R(this._getMessages())},de.dateTimeFormats.get=function(){return R(this._getDateTimeFormats())},de.numberFormats.get=function(){return R(this._getNumberFormats())},de.availableLocales.get=function(){return Object.keys(this.messages).sort()},de.locale.get=function(){return this._vm.locale},de.locale.set=function(e){this._vm.$set(this._vm,"locale",e)},de.fallbackLocale.get=function(){return this._vm.fallbackLocale},de.fallbackLocale.set=function(e){this._localeChainCache={},this._vm.$set(this._vm,"fallbackLocale",e)},de.formatFallbackMessages.get=function(){return this._formatFallbackMessages},de.formatFallbackMessages.set=function(e){this._formatFallbackMessages=e},de.missing.get=function(){return this._missing},de.missing.set=function(e){this._missing=e},de.formatter.get=function(){return this._formatter},de.formatter.set=function(e){this._formatter=e},de.silentTranslationWarn.get=function(){return this._silentTranslationWarn},de.silentTranslationWarn.set=function(e){this._silentTranslationWarn=e},de.silentFallbackWarn.get=function(){return this._silentFallbackWarn},de.silentFallbackWarn.set=function(e){this._silentFallbackWarn=e},de.preserveDirectiveContent.get=function(){return this._preserveDirectiveContent},de.preserveDirectiveContent.set=function(e){this._preserveDirectiveContent=e},de.warnHtmlInMessage.get=function(){return this._warnHtmlInMessage},de.warnHtmlInMessage.set=function(e){var t=this,r=this._warnHtmlInMessage;if(this._warnHtmlInMessage=e,r!==e&&("warn"===e||"error"===e)){var n=this._getMessages();Object.keys(n).forEach((function(e){t._checkLocaleMessage(e,t._warnHtmlInMessage,n[e])}))}},de.postTranslation.get=function(){return this._postTranslation},de.postTranslation.set=function(e){this._postTranslation=e},de.sync.get=function(){return this._sync},de.sync.set=function(e){this._sync=e},pe.prototype._getMessages=function(){return this._vm.messages},pe.prototype._getDateTimeFormats=function(){return this._vm.dateTimeFormats},pe.prototype._getNumberFormats=function(){return this._vm.numberFormats},pe.prototype._warnDefault=function(e,t,r,n,i,o){if(!T(r))return r;if(this._missing){var a=this._missing.apply(null,[e,t,n,i]);if(S(a))return a}if(this._formatFallbackMessages){var s=A.apply(void 0,i);return this._render(t,o,s.params,t)}return t},pe.prototype._isFallbackRoot=function(e){return!e&&!T(this._root)&&this._fallbackRoot},pe.prototype._isSilentFallbackWarn=function(e){return this._silentFallbackWarn instanceof RegExp?this._silentFallbackWarn.test(e):this._silentFallbackWarn},pe.prototype._isSilentFallback=function(e,t){return this._isSilentFallbackWarn(t)&&(this._isFallbackRoot()||e!==this.fallbackLocale)},pe.prototype._isSilentTranslationWarn=function(e){return this._silentTranslationWarn instanceof RegExp?this._silentTranslationWarn.test(e):this._silentTranslationWarn},pe.prototype._interpolate=function(e,t,r,n,i,o,a){if(!t)return null;var s,c=this._path.getPathValue(t,r);if(x(c)||O(c))return c;if(T(c)){if(!O(t))return null;if(!S(s=t[r])&&!I(s))return null}else{if(!S(c)&&!I(c))return null;s=c}return S(s)&&(s.indexOf("@:")>=0||s.indexOf("@.")>=0)&&(s=this._link(e,t,s,n,"raw",o,a)),this._render(s,i,o,r)},pe.prototype._link=function(e,t,r,n,i,o,a){var s=r,c=s.match(ae);for(var l in c)if(c.hasOwnProperty(l)){var u=c[l],p=u.match(se),d=p[0],f=p[1],h=u.replace(d,"").replace(ce,"");if(C(a,h))return s;a.push(h);var m=this._interpolate(e,t,h,n,"raw"===i?"string":i,"raw"===i?void 0:o,a);if(this._isFallbackRoot(m)){if(!this._root)throw Error("unexpected error");var g=this._root.$i18n;m=g._translate(g._getMessages(),g.locale,g.fallbackLocale,h,n,i,o)}m=this._warnDefault(e,h,m,n,x(o)?o:[o],i),this._modifiers.hasOwnProperty(f)?m=this._modifiers[f](m):le.hasOwnProperty(f)&&(m=le[f](m)),a.pop(),s=m?s.replace(u,m):s}return s},pe.prototype._createMessageContext=function(e,t,r,n){var i=this,o=x(e)?e:[],a=_(e)?e:{},s=this._getMessages(),c=this.locale;return{list:function(e){return o[e]},named:function(e){return a[e]},values:e,formatter:t,path:r,messages:s,locale:c,linked:function(e){return i._interpolate(c,s[c]||{},e,null,n,void 0,[e])}}},pe.prototype._render=function(e,t,r,n){if(I(e))return e(this._createMessageContext(r,this._formatter||ue,n,t));var i=this._formatter.interpolate(e,r,n);return i||(i=ue.interpolate(e,r,n)),"string"!==t||S(i)?i:i.join("")},pe.prototype._appendItemToChain=function(e,t,r){var n=!1;return C(e,t)||(n=!0,t&&(n="!"!==t[t.length-1],t=t.replace(/!/g,""),e.push(t),r&&r[t]&&(n=r[t]))),n},pe.prototype._appendLocaleToChain=function(e,t,r){var n,i=t.split("-");do{var o=i.join("-");n=this._appendItemToChain(e,o,r),i.splice(-1,1)}while(i.length&&!0===n);return n},pe.prototype._appendBlockToChain=function(e,t,r){for(var n=!0,i=0;i0;)o[a]=arguments[a+4];if(!e)return"";var s=A.apply(void 0,o);this._escapeParameterHtml&&(s.params=U(s.params));var c=s.locale||t,l=this._translate(r,c,this.fallbackLocale,e,n,"string",s.params);if(this._isFallbackRoot(l)){if(!this._root)throw Error("unexpected error");return(i=this._root).$t.apply(i,[e].concat(o))}return l=this._warnDefault(c,e,l,n,o,"string"),this._postTranslation&&null!=l&&(l=this._postTranslation(l,e)),l},pe.prototype.t=function(e){for(var t,r=[],n=arguments.length-1;n-- >0;)r[n]=arguments[n+1];return(t=this)._t.apply(t,[e,this.locale,this._getMessages(),null].concat(r))},pe.prototype._i=function(e,t,r,n,i){var o=this._translate(r,t,this.fallbackLocale,e,n,"raw",i);if(this._isFallbackRoot(o)){if(!this._root)throw Error("unexpected error");return this._root.$i18n.i(e,t,i)}return this._warnDefault(t,e,o,n,[i],"raw")},pe.prototype.i=function(e,t,r){return e?(S(t)||(t=this.locale),this._i(e,t,this._getMessages(),null,r)):""},pe.prototype._tc=function(e,t,r,n,i){for(var o,a=[],s=arguments.length-5;s-- >0;)a[s]=arguments[s+5];if(!e)return"";void 0===i&&(i=1);var c={count:i,n:i},l=A.apply(void 0,a);return l.params=Object.assign(c,l.params),a=null===l.locale?[l.params]:[l.locale,l.params],this.fetchChoice((o=this)._t.apply(o,[e,t,r,n].concat(a)),i)},pe.prototype.fetchChoice=function(e,t){if(!e||!S(e))return null;var r=e.split("|");return r[t=this.getChoiceIndex(t,r.length)]?r[t].trim():e},pe.prototype.tc=function(e,t){for(var r,n=[],i=arguments.length-2;i-- >0;)n[i]=arguments[i+2];return(r=this)._tc.apply(r,[e,this.locale,this._getMessages(),null,t].concat(n))},pe.prototype._te=function(e,t,r){for(var n=[],i=arguments.length-3;i-- >0;)n[i]=arguments[i+3];var o=A.apply(void 0,n).locale||t;return this._exist(r[o],e)},pe.prototype.te=function(e,t){return this._te(e,this.locale,this._getMessages(),t)},pe.prototype.getLocaleMessage=function(e){return R(this._vm.messages[e]||{})},pe.prototype.setLocaleMessage=function(e,t){"warn"!==this._warnHtmlInMessage&&"error"!==this._warnHtmlInMessage||this._checkLocaleMessage(e,this._warnHtmlInMessage,t),this._vm.$set(this._vm.messages,e,t)},pe.prototype.mergeLocaleMessage=function(e,t){"warn"!==this._warnHtmlInMessage&&"error"!==this._warnHtmlInMessage||this._checkLocaleMessage(e,this._warnHtmlInMessage,t),this._vm.$set(this._vm.messages,e,M(void 0!==this._vm.messages[e]&&Object.keys(this._vm.messages[e]).length?Object.assign({},this._vm.messages[e]):{},t))},pe.prototype.getDateTimeFormat=function(e){return R(this._vm.dateTimeFormats[e]||{})},pe.prototype.setDateTimeFormat=function(e,t){this._vm.$set(this._vm.dateTimeFormats,e,t),this._clearDateTimeFormat(e,t)},pe.prototype.mergeDateTimeFormat=function(e,t){this._vm.$set(this._vm.dateTimeFormats,e,M(this._vm.dateTimeFormats[e]||{},t)),this._clearDateTimeFormat(e,t)},pe.prototype._clearDateTimeFormat=function(e,t){for(var r in t){var n=e+"__"+r;this._dateTimeFormatters.hasOwnProperty(n)&&delete this._dateTimeFormatters[n]}},pe.prototype._localizeDateTime=function(e,t,r,n,i){for(var o=t,a=n[o],s=this._getLocaleChain(t,r),c=0;c0;)t[r]=arguments[r+1];var n=this.locale,i=null;return 1===t.length?S(t[0])?i=t[0]:_(t[0])&&(t[0].locale&&(n=t[0].locale),t[0].key&&(i=t[0].key)):2===t.length&&(S(t[0])&&(i=t[0]),S(t[1])&&(n=t[1])),this._d(e,n,i)},pe.prototype.getNumberFormat=function(e){return R(this._vm.numberFormats[e]||{})},pe.prototype.setNumberFormat=function(e,t){this._vm.$set(this._vm.numberFormats,e,t),this._clearNumberFormat(e,t)},pe.prototype.mergeNumberFormat=function(e,t){this._vm.$set(this._vm.numberFormats,e,M(this._vm.numberFormats[e]||{},t)),this._clearNumberFormat(e,t)},pe.prototype._clearNumberFormat=function(e,t){for(var r in t){var n=e+"__"+r;this._numberFormatters.hasOwnProperty(n)&&delete this._numberFormatters[n]}},pe.prototype._getNumberFormatter=function(e,t,r,n,i,o){for(var a=t,s=n[a],c=this._getLocaleChain(t,r),l=0;l0;)t[r]=arguments[r+1];var n=this.locale,i=null,o=null;return 1===t.length?S(t[0])?i=t[0]:_(t[0])&&(t[0].locale&&(n=t[0].locale),t[0].key&&(i=t[0].key),o=Object.keys(t[0]).reduce((function(e,r){var n;return C(y,r)?Object.assign({},e,((n={})[r]=t[0][r],n)):e}),null)):2===t.length&&(S(t[0])&&(i=t[0]),S(t[1])&&(n=t[1])),this._n(e,n,i,o)},pe.prototype._ntp=function(e,t,r,n){if(!pe.availabilities.numberFormat)return[];if(!r)return(n?new Intl.NumberFormat(t,n):new Intl.NumberFormat(t)).formatToParts(e);var i=this._getNumberFormatter(e,t,this.fallbackLocale,this._getNumberFormats(),r,n),o=i&&i.formatToParts(e);if(this._isFallbackRoot(o)){if(!this._root)throw Error("unexpected error");return this._root.$i18n._ntp(e,t,r,n)}return o||[]},Object.defineProperties(pe.prototype,de),Object.defineProperty(pe,"availabilities",{get:function(){if(!ie){var e="undefined"!=typeof Intl;ie={dateTimeFormat:e&&void 0!==Intl.DateTimeFormat,numberFormat:e&&void 0!==Intl.NumberFormat}}return ie}}),pe.install=Q,pe.version="8.26.1";var fe=pe;o.default.use(fe);var he=new fe({locale:"en_US",fallbackLocale:"en_US",messages:function(){const e=r("4b3b"),t={};return e.keys().forEach(r=>{const n=r.match(/([A-Za-z0-9-_]+)\./i);if(n&&n.length>1){const i=n[1];t[i]=e(r)}}),t}()});const me="production",ge="https://registration.unraid.net",ve="https://unraid.net/preflight",be=Object({VUE_APP_REGWIZ_URL:"https://registration.unraid.net",VUE_APP_PURCHASE_URL:"https://unraid.net/preflight",VUE_APP_MIN_API_VER:"2.49.2",VUE_APP_REC_API_VER:"2.52.1",VUE_APP_MIN_OS_VER:"6.10.0",VUE_APP_REC_OS_VER:"6.11.0",NODE_ENV:"production",BASE_URL:"/"}).VUE_APP_DEV_GRAPH_URL||null,ye=(Object({VUE_APP_REGWIZ_URL:"https://registration.unraid.net",VUE_APP_PURCHASE_URL:"https://unraid.net/preflight",VUE_APP_MIN_API_VER:"2.49.2",VUE_APP_REC_API_VER:"2.52.1",VUE_APP_MIN_OS_VER:"6.10.0",VUE_APP_REC_OS_VER:"6.11.0",NODE_ENV:"production",BASE_URL:"/"}).VUE_APP_DEV_APIKEY,"2.49.2"),we=navigator.userAgent.toLowerCase(),xe={url:ge,name:"UnraidRegistrationWizard",width:600,height:810},_e={errorMessage:"",errorMessageSubtext:"",loading:!0,submissionFrom:null,darkMode:window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches,darkTheme:{alpha:"#1c1b1b",beta:"#f2f2f2",gamma:"#999999"},lightTheme:{alpha:"#f2f2f2",beta:"#1c1b1b",gamma:"#999999"},csrf:null,postMessageError:null,isLaunchpadOpen:!1,isPromoOpen:!1,triggerUPC:!1,ts:null,deviceCount:0,flashproduct:null,flashvendor:null,guid:"",regGuid:"",keyfile:null,servername:null,serverdesc:null,wanip:sessionStorage.getItem("upc_wanip")||null,site:null,wanFQDN:null,state:"",reggen:0,registered:null,internalip:null,internalport:null,protocol:null,license:"",expiretime:null,regWizTime:null,rawServerState:null,plgPath:null,guidRegistered:!1,guidValid:null,guidValidationRunning:!1,replaceable:null,guidForValidation:null,guidBlacklisted:null,id:null,isPopUpOpen:!1,popUpWindow:"",regAtOpen:null,forumaccount:null,userEmail:"",username:"",avatar:"",userPassword:"",apikey:"",ipsValidated:!1,accountAction:null,keyServerAction:"",licenseAction:null,receivedSuccessNewServerState:null,purchaseWindow:{url:new URL(ve),name:"UnraidPurchaseLicense",width:1198,height:900,sendSessionToPopUp:!0},redeemWindow:{url:new URL(ve+"?r=1"),name:"UnraidPurchaseLicense",width:1198,height:900,sendSessionToPopUp:!0},wizardWindow:xe,signInPayload:{...xe,url:xe.url+"/#/sign-in"},signUpPayload:{...xe,url:xe.url+"/#/sign-up"},signOutPayload:{...xe,url:xe.url+"/#/sign-out",width:600,height:500},extendTrialPayload:{...xe,url:xe.url+"/#/extend-trial"},recoverKeyPayload:{...xe,url:xe.url+"/#/recover-key"},replaceKeyPayload:{...xe,url:xe.url+"/#/replace-key"},troubleshootPayload:{...xe,url:xe.url+"/#/troubleshoot"},locale:"en_US",messages:null,graphOnline:!1,graphReconnected:!1,myServers:[],myServersLoading:!1,myServersError:null,myServersErrorShowSupportBtn:!1,myServersEnv:null,apiVersion:"0.0.0",cloud:null,hideMyServers:!1,osVersion:null,plgVersion:null,plgInstalled:null,hasRemoteApikey:null,config:null,hasUnraidNetSSL:!1,flashBackupActivated:!1,extraOrigins:[],myServersOutOfDate:{enabled:!0,error:!1,heading:"My Servers Update Available",message:"Please update to the latest version of the My Servers plugin",link:"/Plugins",linkSameTab:!0,linkText:"Learn More"},devEnv:!1,signOutTriggered:!1,apiReport:null,osGui:we.includes("linux")&&we.includes("firefox"),pirateKey:sessionStorage.getItem("upc_yargMatey")||!1};var Ee=r("2426"),Se=r.n(Ee),ke=r("61bb"),Oe=r.n(ke);const Te="GUID_NOT_RECEIVED",Ie=!(!window.opener||window.opener===window),Ae=Ie?window.opener.parent:window.parent,Re=[ve,ge,"https://launchpad.unraid.test:8081","https://launchpad.unraid.test:6969","https://registration.unraid.net","https://registration-dev.unraid.net","https://registration-dev-logs.unraid.net","https://unraid.net","https://staging.unraid.net","https://craft.unraid.test"],Ce='API error unexpected response for "owner".',Pe=e=>{try{return[null,JSON.parse(e)]}catch(e){return[e]}};var Ne=r("329c"),Me=r.n(Ne);var De=(e,t,r)=>{if(Me()(e,`>=${t} <${r}`,{includePrerelease:!1}))return!0;return!!Me()(e,">="+r,{includePrerelease:!0})};const Ue={actions:[],humanReadable:"",heading:"",message:"",messageCenter:!1,error:!1,withKey:!1},Le={...Ue,humanReadable:he.tc("stateData.ENOFLASH.humanReadable"),error:{heading:he.tc("stateData.ENOFLASH.error.heading"),message:he.tc("stateData.ENOFLASH.error.message"),signInToFix:!1}};let je="";const Fe={statePhpPath:e=>`/plugins/${e.plgPath||"dynamix.unraid.net"}/include/state.php`,myServersCfgPath:e=>(e.plgPath||"Unraid.net")+"/myservers.cfg",requireGuidValidation:e=>!Ie||e.guidRegistered,validApiKeyLength:e=>64===e.apikey.length,validApiKeyForUpc:e=>!!e.apikey&&e.apikey.startsWith("unupc_"),hasRemoteApikey:e=>!0===e.hasRemoteApikey||!(!e.validApiKeyLength||!e.validApiKeyForUpc),showExpiretime:e=>("TRIAL"===e.state||"EEXPIRED"===e.state)&&e.expiretime>0,trialExtensionEligible:e=>!(e.reggen&&!(e.reggen<2)),signedOutWithKey:(e,t)=>!(!t.stateData.withKey||e.registered),stateData:(e,t)=>{switch(e.state){case"ENOKEYFILE":return{...Ue,actions:[e.registered?"signOut":"register","startTrial","purchase","redeem"],humanReadable:he.tc("stateData.ENOKEYFILE.humanReadable"),heading:he.tc("stateData.ENOKEYFILE.heading"),message:he.tc("stateData.ENOKEYFILE.message")};case"TRIAL":return{...Ue,actions:["purchase",e.registered?"signOut":"register",e.registered?"continueTrial":null],humanReadable:he.tc("stateData.TRIAL.humanReadable"),heading:he.tc("stateData.TRIAL.heading"),message:he.tc("stateData.TRIAL.message"),withKey:!0};case"EEXPIRED":return{...Ue,actions:[e.registered?"signOut":"register",t.trialExtensionEligible?"extend":null,"purchase"],humanReadable:he.tc("stateData.EEXPIRED.humanReadable"),error:{heading:he.tc("stateData.EEXPIRED.heading"),message:t.trialExtensionEligible?he.tc("stateData.EEXPIRED.message.extensionEligible"):he.tc("stateData.EEXPIRED.message.extensionNotEligible")},withKey:!0};case"BASIC":return{...Ue,actions:[e.registered?"signOut":"register","upgrade"],humanReadable:he.tc("stateData.BASIC.humanReadable"),heading:he.tc("basicPlusPro.heading"),message:e.registered?e.guidRegistered?he.tc("basicPlusPro.message.upgradeEligible"):"":he.tc("basicPlusPro.message.registered"),messageCenter:!e.registered,withKey:!0};case"PLUS":return{...Ue,actions:[e.registered?"signOut":"register","upgrade"],humanReadable:he.tc("stateData.PLUS.humanReadable"),heading:he.tc("basicPlusPro.heading"),message:e.registered?e.guidRegistered?he.tc("basicPlusPro.message.upgradeEligible"):"":he.tc("basicPlusPro.message.registered"),messageCenter:!e.registered,withKey:!0};case"PRO":return{...Ue,actions:[e.registered?"signOut":"register",e.registered?"close":null],humanReadable:he.tc("stateData.PRO.humanReadable"),heading:he.tc("basicPlusPro.heading"),message:e.registered?"":he.tc("basicPlusPro.message.registered"),messageCenter:!e.registered,withKey:!0};case"EGUID":return je=e.replaceable?he.tc("stateData.EGUID.error.message.replacementEligible"):!1===e.replaceable&&e.guidBlacklisted?`${he.tc("stateData.EGUID.error.message.default")}
${he.tc("stateData.EGUID.error.message.blacklisted")}`:!1!==e.replaceable||e.guidBlacklisted?he.tc("stateData.EGUID.error.message.replacementEligible"):`${he.tc("stateData.EGUID.error.message.default")}
${he.tc("stateData.EGUID.error.message.replacementIneligible")}`,{...Ue,actions:["purchase","replace",e.registered?"signOut":"register"],humanReadable:he.tc("stateData.EGUID.humanReadable"),error:{heading:he.tc("stateData.EGUID.error.heading"),message:je,signInToFix:!0}};case"EGUID1":return{...Ue,actions:["purchase",e.registered?"signOut":"register"],humanReadable:he.tc("stateData.EGUID1.humanReadable"),error:{heading:he.tc("stateData.EGUID1.error.heading"),message:he.tc("stateData.EGUID1.error.message"),signInToFix:!0}};case"ENOKEYFILE2":return{...Ue,actions:["purchase",e.registered?"signOut":"register",e.registered?"recover":null],humanReadable:he.tc("stateData.ENOKEYFILE2.humanReadable"),error:{heading:he.tc("stateData.ENOKEYFILE2.error.heading"),message:he.tc("stateData.ENOKEYFILE2.error.message"),signInToFix:!0}};case"ETRIAL":return{...Ue,actions:[e.registered?"signOut":"register","purchase"],humanReadable:he.tc("stateData.ETRIAL.humanReadable"),error:{heading:he.tc("stateData.ETRIAL.error.heading"),message:he.tc("stateData.ETRIAL.error.message"),signInToFix:!0}};case"ENOKEYFILE1":return{...Ue,humanReadable:he.tc("stateData.ENOKEYFILE1.humanReadable"),error:{heading:he.tc("stateData.ENOKEYFILE1.error.heading"),message:he.tc("stateData.ENOKEYFILE1.error.message"),signInToFix:!1}};case"ENOFLASH":case"ENOFLASH1":case"ENOFLASH2":case"ENOFLASH3":case"ENOFLASH4":case"ENOFLASH5":case"ENOFLASH6":case"ENOFLASH7":return Le;case"EBLACKLISTED":return{...Ue,humanReadable:he.tc("stateData.EBLACKLISTED.humanReadable"),error:{heading:he.tc("stateData.EBLACKLISTED.error.heading"),message:he.tc("stateData.EBLACKLISTED.error.message"),signInToFix:!1}};case"EBLACKLISTED1":return{...Ue,humanReadable:he.tc("stateData.EBLACKLISTED1.humanReadable"),error:{heading:he.tc("stateData.EBLACKLISTED1.error.heading"),message:he.tc("stateData.EBLACKLISTED1.error.message"),signInToFix:!1}};case"EBLACKLISTED2":return{...Ue,humanReadable:he.tc("stateData.EBLACKLISTED2.humanReadable"),error:{heading:he.tc("stateData.EBLACKLISTED2.error.heading"),message:he.tc("stateData.EBLACKLISTED2.error.message"),signInToFix:!1}};case"ENOCONN":return{...Ue,humanReadable:he.tc("stateData.ENOCONN.humanReadable"),error:{heading:he.tc("stateData.ENOCONN.error.heading"),message:he.tc("stateData.ENOCONN.error.message"),signInToFix:!1}};case"STALE":return{...Ue,humanReadable:he.tc("stateData.STALE.humanReadable"),error:{heading:he.tc("stateData.STALE.error.heading"),message:he.tc("stateData.STALE.error.message"),signInToFix:!1}};default:return{...Ue}}},stateDataKeyActions:(e,t)=>!!(t.stateData.actions.includes("purchase")||t.stateData.actions.includes("upgrade")||t.stateData.actions.includes("recover")||t.stateData.actions.includes("replace")||t.stateData.actions.includes("extend")),keyTypeForPurchase:e=>{switch(e.state){case"BASIC":return"Basic";case"PLUS":return"Plus";case"PRO":return"Pro";default:return"Trial"}},isRemoteAccess:e=>e.wanFQDN||e.site&&e.site.includes("www.")&&e.site.includes("unraid.net"),noRemoteApikeyRegisteredWithPlg:e=>!(!e.registered||e.hideMyServers||!e.validApiKeyLength||!e.validApiKeyForUpc),errorTooManyDisks:e=>!(!e.config||e.config.valid||"INVALID"!==e.config.error),allowedOrigins:e=>[...Re,...e.extraOrigins],myServersNotMinApiVer:e=>!e.apiVersion||e.apiVersion&&Se()(e.apiVersion,ye),myServersNotRecApiVer:e=>!e.apiVersion||e.apiVersion&&Se()(e.apiVersion,"2.52.1"),osPrerelease:e=>{if(e.osVersion){return Oe()(e.osVersion).prerelease.length}return!1},osVersionValid:e=>e.osVersion&&De(e.osVersion,"6.10.0","6.11.0"),allowApiOutOfDate:(e,t)=>!t.plgInstallFailed&&e.apiVersion&&(t.myServersNotMinApiVer||t.myServersNotRecApiVer)&&!e.devMode&&!e.hideMyServers,myServersOutOfDate:(e,t)=>t.allowApiOutOfDate&&t.myServersNotMinApiVer?{...e.myServersOutOfDate,error:!0,message:"The My Servers plugin is out-of-date and will not connect to Unraid's cloud services. Please update the plugin.",linkText:"Update now"}:t.osVersionValid||t.osPrerelease?t.allowApiOutOfDate&&!t.myServersNotMinApiVer&&t.myServersNotRecApiVer?e.myServersOutOfDate:!t.osVersionValid&&t.osPrerelease?{enabled:!0,error:!1,heading:"Unraid OS Out-of-date",message:"RC releases are not meant to used long term, please update to a stable release of Unraid."+(e.plgInstalled&&!t.plgInstallFailed?" This version of Unraid will be blocked from My Servers in the future.":""),link:" https://forums.unraid.net/topic/128328-my-servers-dropping-support-for-older-versions-of-unraid/",linkSameTab:!1,linkText:he.tc("learnMore")}:{enabled:!1,error:!1}:{enabled:!0,error:!0,heading:"Unraid OS Out-of-date",message:"You are running an unsupported release of Unraid, please upgrade to the current version."+(e.plgInstalled&&!t.plgInstallFailed?" This version of Unraid will be blocked from My Servers in the future.":""),link:" https://forums.unraid.net/topic/128328-my-servers-dropping-support-for-older-versions-of-unraid/",linkSameTab:!1,linkText:he.tc("learnMore")},errorMessage:(e,t)=>!t.stateData.error&&e.myServersError&&e.myServersErrorShowSupportBtn?e.myServersError:!t.stateData.error&&e.cloud&&e.cloud.error&&e.myServersErrorShowSupportBtn?e.cloud.error:null,server:(e,t)=>({guid:e.guid||Te,regGuid:e.regGuid,guidRegistered:e.guidRegistered||e.regWizTime,guidValid:e.guidValid,hasRemoteApikey:t.hasRemoteApikey,regWizTime:e.regWizTime,keyfile:e.keyfile,keyTypeForPurchase:t.keyTypeForPurchase,flashproduct:e.flashproduct,flashvendor:e.flashvendor,servername:e.servername,serverdesc:e.serverdesc,internalip:e.internalip,site:e.site,wanFQDN:e.wanFQDN,state:e.state,internalport:e.internalport,protocol:e.protocol,registered:e.registered,reggen:e.reggen,userEmail:e.userEmail,expiretime:e.expiretime,ts:e.ts,locale:e.locale,deviceCount:e.deviceCount,plgPath:e.plgPath,plgVersion:e.plgVersion,osVersion:e.osVersion,apiVersion:e.apiVersion,extraOrigins:e.extraOrigins,errorMessage:t.errorMessage,apiReport:e.apiReport,osGui:e.osGui,username:e.username,avatar:e.avatar,hideMyServers:e.hideMyServers,flashBackupActivated:e.flashBackupActivated}),features:e=>[{title:he.tc("regWizPopUp.routes.whatIsMyServers.features.secureRemoteAccess.heading"),copy:he.tc("regWizPopUp.routes.whatIsMyServers.features.secureRemoteAccess.copy"),svg:"ui--remote-access"},{title:he.tc("regWizPopUp.routes.whatIsMyServers.features.usbFlashBackup.heading"),copy:he.tc("regWizPopUp.routes.whatIsMyServers.features.usbFlashBackup.copy"),svg:"ui--usb"},{title:he.tc("regWizPopUp.routes.whatIsMyServers.features.realTimeMonitoring.heading"),copy:he.tc("regWizPopUp.routes.whatIsMyServers.features.realTimeMonitoring.copy"),svg:"ui--diagnostics"},{title:he.tc("regWizPopUp.routes.whatIsMyServers.features.regKeyManagement.heading"),copy:he.tc("regWizPopUp.routes.whatIsMyServers.features.regKeyManagement.copy"),svg:"ui--key"},{title:he.tc("regWizPopUp.routes.whatIsMyServers.features.plusMore.heading"),copy:he.tc("regWizPopUp.routes.whatIsMyServers.features.plusMore.copy"),svg:"util--star",center:!0}],plgInstallFailed:e=>e.plgInstalled&&e.plgInstalled.includes("_installFailed")};var $e=r("786a"),Ve=r.n($e),Ge=r("626e");const ze=((e,t)=>{void 0===t&&(t={keys:[],values:[]});const r=t.keys,n=void 0===r?[]:r,i=t.values,o=void 0===i?[]:i,a=(e,t)=>{const r=Ge.key(e)||Ge.value(t),i=n.some(t=>t.test(e))||o.some(e=>e.test(t));return r||i};return{map:t=>Ve.a.default(t).map(t=>!!a((void 0).key,t)&&(void 0).update(e)),forEach:t=>{Ve.a.default(t).forEach(t=>{a((void 0).key,t)&&(void 0).update(e)})}}})("[REDACTED]",{keys:["guid"],values:[]}),Be={...Object.fromEntries(Object.entries(console).map(([e,t])=>{if("debug"===e)return[e,()=>{}];if("function"==typeof method){const r=t.bind(console);return[e,(e,...t)=>t.length>=1?r(e,...t.map(e=>ze.map(e))):r(e)]}return[e,t]}))},We={SET_APP_ERROR_MESSAGE(e,t){Be.debug("[SET_APP_ERROR_MESSAGE]: initial %o",t);const[r,n]=Pe(t);n&&!r||!t||(Be.debug("[SET_APP_ERROR_MESSAGE]: no json use original string %o",t),e.errorMessage=t),n||!1!==t&&""!==t||(Be.debug("[SET_APP_ERROR_MESSAGE]: allow falsely values to reset the field %o",t),e.errorMessage=""),n&&n.error&&(Be.debug("[SET_APP_ERROR_MESSAGE]: we got json %o",t),e.errorMessage=n.error),e.errorMessage&&Be.error("[SET_APP_ERROR_MESSAGE]: %s",e.errorMessage)},SET_APP_ERROR_MESSAGE_SUBTEXT(e,t){Be.debug("[SET_APP_ERROR_MESSAGE_SUBTEXT]: %o",t),e.errorMessageSubtext=t,e.errorMessageSubtext&&Be.error("[SET_APP_ERROR_MESSAGE_SUBTEXT]: %s",e.errorMessageSubtext)},SET_LOADING_STATE(e,t){Be.debug("[SET_LOADING_STATE]: %o",t),e.loading=t},SET_IS_LAUNCHPAD_OPEN(e,t){Be.debug("[SET_IS_LAUNCHPAD_OPEN]: %o",t),t||sessionStorage.removeItem("clickedInstallMyServers"),e.isLaunchpadOpen=t},SET_IS_PROMO_OPEN(e,t){Be.debug("[SET_IS_PROMO_OPEN]: %o",t),e.isPromoOpen=t},SET_STATE(e,t){Be.debug("[SET_STATE]: %o",t),e.state=t},SET_CONFIG(e,t){Be.debug("[SET_CONFIG]: %o",t),e.config=t},CHANGE_GUID_REGISTERED(e,t){Be.debug("[CHANGE_GUID_REGISTERED]: %o",t),e.guidRegistered=t},CHANGE_GUID_VALID(e,t){Be.debug("[CHANGE_GUID_VALID]: %o",t),e.guidValid=t},CHANGE_GUID_VALIDATION_RUNNING(e,t){Be.debug("[CHANGE_GUID_VALIDATION_RUNNING]: %o",t),e.guidValidationRunning=t},CHANGE_GUID_FOR_VALIDATION(e,t){Be.debug("[CHANGE_GUID_FOR_VALIDATION]: %o",t),e.guidForValidation=t},CHANGE_GUID_BLACKLISTED(e,t){Be.debug("[CHANGE_GUID_BLACKLISTED]: %o",t),e.guidBlacklisted=t},CHANGE_REPLACEABLE(e,t){Be.debug("[CHANGE_REPLACEABLE]: %o",t),e.replaceable=t},CHANGE_POP_UP_WINDOW(e,t){Be.debug("[CHANGE_POP_UP_WINDOW]: %o",t),e.popUpWindow=t,e.isPopUpOpen=!!t,e.regAtOpen=null},STATE_AT_OPEN(e,t){e.regAtOpen=t},MUTATE_KEYSERVER_RESPONSE(e,t){Be.debug("[MUTATE_KEYSERVER_RESPONSE]: %o",t),t.license&&(e.license=t.license),t.newKey&&(e.keyfile=t.newKey),t.trial&&(e.keyfile=t.trial),t.apikey&&(e.apikey=t.apikey),t.validated&&(e.ipsValidated=t.validated),t.email&&(e.userEmail=t.email),t.password&&(e.userPassword=t.password),(t.action||t.keyServerAction)&&(e.keyServerAction=t.action||t.keyServerAction),t.username&&(e.username=t.username),t.avatar&&(e.avatar=t.avatar)},SET_TRIAL(e,t){Be.debug("[SET_TRIAL]: %o",t),e.license=t.license,e.keyfile=t.trial,e.keyServerAction="extendTrial"},SET_USER_EMAIL(e,t){Be.debug("[SET_USER_EMAIL]: %s",t),e.userEmail=t},SET_FULL_SERVER_STATE(e,t){if(Be.debug("[SET_FULL_SERVER_STATE] start %o",t),!t)return Be.error("[SET_FULL_SERVER_STATE] No state data…🤬");let r=t;return(r.registered||0===r.registered)&&(r.registered=Boolean(Number(r.registered))),(r.hasRemoteApikey||0===r.hasRemoteApikey)&&(r.hasRemoteApikey=Boolean(Number(r.hasRemoteApikey))),r.email&&(r={...r,userEmail:r.email},delete r.email),Be.debug("[SET_FULL_SERVER_STATE] ✨ mutateData ✨ %o",{state:e,mutateData:r}),e=Object.assign(e,r),!0},SET_RAW_SERVER_STATE:(e,t)=>Ie?(e.rawServerState=t,Be.debug("[SET_RAW_SERVER_STATE] %o",t)):Be.debug("[SET_RAW_SERVER_STATE] ❌ skipped not needed in non-pop-up ❌ %o",{CAN_POST_MESSAGE:Ie}),SIGN_OUT(e){Be.debug("[SIGN_OUT]: %s","✨"),e.registered=!1,e.license="",e.keyfile="",e.apikey="",e.ipsValidated=!1,e.userEmail="",e.userPassword="",e.username="",e.avatar=""},SUBMISSION_FROM(e,t){Be.debug("[SUBMISSION_FROM]: %s",t),e.submissionFrom=t},SET_WANIP(e,t){Be.debug("[SET_WANIP]: %s",t),e.wanip=t,sessionStorage.setItem("upc_wanip",t)},SET_SERVERDESC(e,t){Be.debug("[SET_SERVERDESC]: %s",t),e.serverdesc=t},SET_SITE(e,t){Be.debug("[SET_SITE]: %s",t),e.site=t},SET_CSRF(e,t){Be.debug("[SET_CSRF]: %s",t),e.csrf=t},LICENSE_PINGBACK(e,t){Be.debug("[LICENSE_PINGBACK]: %o",t),e.licenseAction=t},ACCOUNT_PINGBACK(e,t){Be.debug("[ACCOUNT_PINGBACK]: %o",t),e.accountAction=t},RECEIVED_SUCCESS_NEW_SERVERSTATE(e,t){Be.debug("[RECEIVED_SUCCESS_NEW_SERVERSTATE]: %o",t),e.receivedSuccessNewServerState=t},SET_UPTIME(e,t){Be.debug("[SET_UPTIME]: %s",t),e.uptime=t},SET_EXPIRE_TIME(e,t){Be.debug("[SET_EXPIRE_TIME]: %s",t),e.expiretime=t},SET_REGWIZ_TIME(e,t){Be.debug("[SET_REGWIZ_TIME]: %s",t),e.regWizTime=t},CHANGE_GUID_FORUMACCOUNT(e,t){Be.debug("[CHANGE_GUID_FORUMACCOUNT]: %s",t),e.forumaccount=t},SET_LOCALE(e,t){Be.debug("[SET_LOCALE]: %s",t),e.locale=t},LOCALE_MESSAGES(e,t){const[r,n]=Pe(decodeURIComponent(t));r?Be.warn("[LOCALE_MESSAGES]: %o",r):(Be.debug("[LOCALE_MESSAGES]: %o",n),e.messages=n)},SET_API_KEY(e,t){Be.debug("[SET_API_KEY]: %s",t),e.apikey=t},SET_GRAPH_ONLINE(e,t){Be.debug("[SET_GRAPH_ONLINE]: %o",t),e.graphOnline=t},SET_GRAPH_RECONNECTED(e,t){Be.debug("[SET_GRAPH_RECONNECTED]: %o",t),e.graphReconnected=t},SET_MY_SERVERS(e,t){Be.debug("[SET_MY_SERVERS]: %o",t),e.myServers=[...t]},SET_MY_SERVERS_LOADING(e,t){Be.debug("[SET_MY_SERVERS_LOADING]: %o",t),e.myServersLoading=t},SET_MY_SERVERS_ERROR(e,t){t?Be.error("[SET_MY_SERVERS_ERROR]: %o",t):Be.debug("[SET_MY_SERVERS_ERROR] unset"),e.myServersError=t?t.replace("Graphql","unraid-api").replace("offline","stopped"):null},SET_MY_SERVERS_ERROR_SHOW_SUPPORT_BTN(e,t){Be.debug("[SET_MY_SERVERS_ERROR_SHOW_SUPPORT_BTN]",t),e.myServersErrorShowSupportBtn=t},SET_MY_SERVERS_ENV(e,t){Be.debug("[SET_MY_SERVERS_ENV]: %o",t),e.myServersEnv=t},SET_MY_SERVERS_API_VERSION(e,t){Be.debug("[SET_MY_SERVERS_API_VERSION]: %o",t),e.apiVersion=t},TRIGGER_UPC(e,t){Be.debug("[TRIGGER_UPC]: %o",t),e.triggerUPC=t},SET_HIDE_MY_SERVERS(e,t){Be.debug("[SET_HIDE_MY_SERVERS]: %o",t),e.hideMyServers=!!t},SET_PLG_PATH:(e,t)=>"dynamix.my.servers"!==t?Be.warn("[SET_PLG_PATH] value not allowed",t):(Be.debug("[SET_PLG_PATH]: %o",t),e.plgPath=t,!0),SET_POST_MESSAGE_ERROR(e,t){e.postMessageError=t,e.postMessageError&&Be.error("[SET_POST_MESSAGE_ERROR]: %o",e.postMessageError)},SET_OWNER(e,t){Be.debug("[SET_OWNER]: %o",t),e.username=t&&t.username?t.username:"",e.avatar=t&&t.avatar?t.avatar:"",e.registered=!(!t||!t.username)},SET_REGISTRATION_SUB(e,t){Be.debug("[SET_REGISTRATION_SUB]: %o",t),t.keyfile&&(e.keyfile=t.keyFile.contents),t.expiration&&(e.expiretime=t.expiration)},SET_DEV_MODE(e,t){Be.debug("[SET_DEV_MODE]: %o",t),e.devEnv=t},SET_SIGN_OUT_TRIGGERED(e,t){Be.debug("[SET_SIGN_OUT_TRIGGERED]: %o",t),e.signOutTriggered=t},SET_API_EXECUTE_RESPONSE(e,t){Be.debug("[SET_API_EXECUTE_RESPONSE]: %o",t),e.apiReport=t},SET_MY_SERVERS_CLOUD(e,t){Be.debug("[SET_MY_SERVERS_CLOUD]: %o",t),e.cloud=t},SET_REPLACE_KEY(e,t){Be.debug("[SET_REPLACE_KEY]: %o",t),e.license=t.license,e.keyfile=t.newkey,e.keyServerAction="replace"},SET_PIRATE_KEY(e,t){Be.debug("[SET_PIRATE_KEY]: %s",t),e.pirateKey=!!t,e.pirateKey?sessionStorage.setItem("upc_yargMatey",t):sessionStorage.removeItem("upc_yargMatey")}};var He=r("0e49"),Ye=r.n(He),qe=function(){return(qe=Object.assign||function(e){for(var t,r=1,n=arguments.length;r1&&void 0!==arguments[1]?arguments[1]:e.prototype.toString;e.prototype.toJSON=t,e.prototype.inspect=t,Xe.a&&(e.prototype[Xe.a]=t)}function Ze(e){return(Ze="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function et(e,t){for(var r,n=/\r\n|[\n\r]/g,i=1,o=t+1;(r=n.exec(e.body))&&r.index120){for(var d=Math.floor(c/80),f=c%80,h=[],m=0;m0||Ke(0,"line in locationOffset is 1-indexed and must be positive"),this.locationOffset.column>0||Ke(0,"column in locationOffset is 1-indexed and must be positive")};!function(e){"function"==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e.prototype,Symbol.toStringTag,{get:function(){return this.constructor.name}})}(ct);var lt=r("04b4"),ut=Object.freeze({SOF:"",EOF:"",BANG:"!",DOLLAR:"$",AMP:"&",PAREN_L:"(",PAREN_R:")",SPREAD:"...",COLON:":",EQUALS:"=",AT:"@",BRACKET_L:"[",BRACKET_R:"]",BRACE_L:"{",PIPE:"|",BRACE_R:"}",NAME:"Name",INT:"Int",FLOAT:"Float",STRING:"String",BLOCK_STRING:"BlockString",COMMENT:"Comment"});function pt(){return this.lastToken=this.token,this.token=this.lookahead()}function dt(){var e=this.token;if(e.kind!==ut.EOF)do{e=e.next||(e.next=mt(this,e))}while(e.kind===ut.COMMENT);return e}function ft(e,t,r,n,i,o,a){this.kind=e,this.start=t,this.end=r,this.line=n,this.column=i,this.value=a,this.prev=o,this.next=null}function ht(e){return isNaN(e)?ut.EOF:e<127?JSON.stringify(String.fromCharCode(e)):'"\\u'.concat(("00"+e.toString(16).toUpperCase()).slice(-4),'"')}function mt(e,t){var r=e.source,n=r.body,i=n.length,o=function(e,t,r){var n=e.length,i=t;for(;i=i)return new ft(ut.EOF,i,i,a,s,t);var c=n.charCodeAt(o);switch(c){case 33:return new ft(ut.BANG,o,o+1,a,s,t);case 35:return function(e,t,r,n,i){var o,a=e.body,s=t;do{o=a.charCodeAt(++s)}while(!isNaN(o)&&(o>31||9===o));return new ft(ut.COMMENT,t,s,r,n,i,a.slice(t+1,s))}(r,o,a,s,t);case 36:return new ft(ut.DOLLAR,o,o+1,a,s,t);case 38:return new ft(ut.AMP,o,o+1,a,s,t);case 40:return new ft(ut.PAREN_L,o,o+1,a,s,t);case 41:return new ft(ut.PAREN_R,o,o+1,a,s,t);case 46:if(46===n.charCodeAt(o+1)&&46===n.charCodeAt(o+2))return new ft(ut.SPREAD,o,o+3,a,s,t);break;case 58:return new ft(ut.COLON,o,o+1,a,s,t);case 61:return new ft(ut.EQUALS,o,o+1,a,s,t);case 64:return new ft(ut.AT,o,o+1,a,s,t);case 91:return new ft(ut.BRACKET_L,o,o+1,a,s,t);case 93:return new ft(ut.BRACKET_R,o,o+1,a,s,t);case 123:return new ft(ut.BRACE_L,o,o+1,a,s,t);case 124:return new ft(ut.PIPE,o,o+1,a,s,t);case 125:return new ft(ut.BRACE_R,o,o+1,a,s,t);case 65:case 66:case 67:case 68:case 69:case 70:case 71:case 72:case 73:case 74:case 75:case 76:case 77:case 78:case 79:case 80:case 81:case 82:case 83:case 84:case 85:case 86:case 87:case 88:case 89:case 90:case 95:case 97:case 98:case 99:case 100:case 101:case 102:case 103:case 104:case 105:case 106:case 107:case 108:case 109:case 110:case 111:case 112:case 113:case 114:case 115:case 116:case 117:case 118:case 119:case 120:case 121:case 122:return function(e,t,r,n,i){var o=e.body,a=o.length,s=t+1,c=0;for(;s!==a&&!isNaN(c=o.charCodeAt(s))&&(95===c||c>=48&&c<=57||c>=65&&c<=90||c>=97&&c<=122);)++s;return new ft(ut.NAME,t,s,r,n,i,o.slice(t,s))}(r,o,a,s,t);case 45:case 48:case 49:case 50:case 51:case 52:case 53:case 54:case 55:case 56:case 57:return function(e,t,r,n,i,o){var a=e.body,s=r,c=t,l=!1;if(45===s&&(s=a.charCodeAt(++c)),48===s){if((s=a.charCodeAt(++c))>=48&&s<=57)throw at(e,c,"Invalid number, unexpected digit after 0: ".concat(ht(s),"."))}else c=gt(e,c,s),s=a.charCodeAt(c);if(46===s&&(l=!0,s=a.charCodeAt(++c),c=gt(e,c,s),s=a.charCodeAt(c)),69!==s&&101!==s||(l=!0,43!==(s=a.charCodeAt(++c))&&45!==s||(s=a.charCodeAt(++c)),c=gt(e,c,s),s=a.charCodeAt(c)),46===s||69===s||101===s)throw at(e,c,"Invalid number, expected digit but got: ".concat(ht(s),"."));return new ft(l?ut.FLOAT:ut.INT,t,c,n,i,o,a.slice(t,c))}(r,o,c,a,s,t);case 34:return 34===n.charCodeAt(o+1)&&34===n.charCodeAt(o+2)?function(e,t,r,n,i,o){var a=e.body,s=t+3,c=s,l=0,u="";for(;s=48&&o<=57){do{o=n.charCodeAt(++i)}while(o>=48&&o<=57);return i}throw at(e,i,"Invalid number, expected digit but got: ".concat(ht(o),"."))}function vt(e,t,r,n){return bt(e)<<12|bt(t)<<8|bt(r)<<4|bt(n)}function bt(e){return e>=48&&e<=57?e-48:e>=65&&e<=70?e-55:e>=97&&e<=102?e-87:-1}Je(ft,(function(){return{kind:this.kind,value:this.value,line:this.line,column:this.column}}));var yt=Object.freeze({QUERY:"QUERY",MUTATION:"MUTATION",SUBSCRIPTION:"SUBSCRIPTION",FIELD:"FIELD",FRAGMENT_DEFINITION:"FRAGMENT_DEFINITION",FRAGMENT_SPREAD:"FRAGMENT_SPREAD",INLINE_FRAGMENT:"INLINE_FRAGMENT",VARIABLE_DEFINITION:"VARIABLE_DEFINITION",SCHEMA:"SCHEMA",SCALAR:"SCALAR",OBJECT:"OBJECT",FIELD_DEFINITION:"FIELD_DEFINITION",ARGUMENT_DEFINITION:"ARGUMENT_DEFINITION",INTERFACE:"INTERFACE",UNION:"UNION",ENUM:"ENUM",ENUM_VALUE:"ENUM_VALUE",INPUT_OBJECT:"INPUT_OBJECT",INPUT_FIELD_DEFINITION:"INPUT_FIELD_DEFINITION"});var wt=function(){function e(e,t){var r="string"==typeof e?new ct(e):e;r instanceof ct||Ke(0,"Must provide Source. Received: ".concat(Object(Qe.a)(r))),this._lexer=function(e,t){var r=new ft(ut.SOF,0,0,0,0,null);return{source:e,options:t,lastToken:r,token:r,line:1,lineStart:0,advance:pt,lookahead:dt}}(r),this._options=t||{}}var t=e.prototype;return t.parseName=function(){var e=this.expectToken(ut.NAME);return{kind:st.a.NAME,value:e.value,loc:this.loc(e)}},t.parseDocument=function(){var e=this._lexer.token;return{kind:st.a.DOCUMENT,definitions:this.many(ut.SOF,this.parseDefinition,ut.EOF),loc:this.loc(e)}},t.parseDefinition=function(){if(this.peek(ut.NAME))switch(this._lexer.token.value){case"query":case"mutation":case"subscription":return this.parseOperationDefinition();case"fragment":return this.parseFragmentDefinition();case"schema":case"scalar":case"type":case"interface":case"union":case"enum":case"input":case"directive":return this.parseTypeSystemDefinition();case"extend":return this.parseTypeSystemExtension()}else{if(this.peek(ut.BRACE_L))return this.parseOperationDefinition();if(this.peekDescription())return this.parseTypeSystemDefinition()}throw this.unexpected()},t.parseOperationDefinition=function(){var e=this._lexer.token;if(this.peek(ut.BRACE_L))return{kind:st.a.OPERATION_DEFINITION,operation:"query",name:void 0,variableDefinitions:[],directives:[],selectionSet:this.parseSelectionSet(),loc:this.loc(e)};var t,r=this.parseOperationType();return this.peek(ut.NAME)&&(t=this.parseName()),{kind:st.a.OPERATION_DEFINITION,operation:r,name:t,variableDefinitions:this.parseVariableDefinitions(),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet(),loc:this.loc(e)}},t.parseOperationType=function(){var e=this.expectToken(ut.NAME);switch(e.value){case"query":return"query";case"mutation":return"mutation";case"subscription":return"subscription"}throw this.unexpected(e)},t.parseVariableDefinitions=function(){return this.optionalMany(ut.PAREN_L,this.parseVariableDefinition,ut.PAREN_R)},t.parseVariableDefinition=function(){var e=this._lexer.token;return{kind:st.a.VARIABLE_DEFINITION,variable:this.parseVariable(),type:(this.expectToken(ut.COLON),this.parseTypeReference()),defaultValue:this.expectOptionalToken(ut.EQUALS)?this.parseValueLiteral(!0):void 0,directives:this.parseDirectives(!0),loc:this.loc(e)}},t.parseVariable=function(){var e=this._lexer.token;return this.expectToken(ut.DOLLAR),{kind:st.a.VARIABLE,name:this.parseName(),loc:this.loc(e)}},t.parseSelectionSet=function(){var e=this._lexer.token;return{kind:st.a.SELECTION_SET,selections:this.many(ut.BRACE_L,this.parseSelection,ut.BRACE_R),loc:this.loc(e)}},t.parseSelection=function(){return this.peek(ut.SPREAD)?this.parseFragment():this.parseField()},t.parseField=function(){var e,t,r=this._lexer.token,n=this.parseName();return this.expectOptionalToken(ut.COLON)?(e=n,t=this.parseName()):t=n,{kind:st.a.FIELD,alias:e,name:t,arguments:this.parseArguments(!1),directives:this.parseDirectives(!1),selectionSet:this.peek(ut.BRACE_L)?this.parseSelectionSet():void 0,loc:this.loc(r)}},t.parseArguments=function(e){var t=e?this.parseConstArgument:this.parseArgument;return this.optionalMany(ut.PAREN_L,t,ut.PAREN_R)},t.parseArgument=function(){var e=this._lexer.token,t=this.parseName();return this.expectToken(ut.COLON),{kind:st.a.ARGUMENT,name:t,value:this.parseValueLiteral(!1),loc:this.loc(e)}},t.parseConstArgument=function(){var e=this._lexer.token;return{kind:st.a.ARGUMENT,name:this.parseName(),value:(this.expectToken(ut.COLON),this.parseValueLiteral(!0)),loc:this.loc(e)}},t.parseFragment=function(){var e=this._lexer.token;this.expectToken(ut.SPREAD);var t=this.expectOptionalKeyword("on");return!t&&this.peek(ut.NAME)?{kind:st.a.FRAGMENT_SPREAD,name:this.parseFragmentName(),directives:this.parseDirectives(!1),loc:this.loc(e)}:{kind:st.a.INLINE_FRAGMENT,typeCondition:t?this.parseNamedType():void 0,directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet(),loc:this.loc(e)}},t.parseFragmentDefinition=function(){var e=this._lexer.token;return this.expectKeyword("fragment"),this._options.experimentalFragmentVariables?{kind:st.a.FRAGMENT_DEFINITION,name:this.parseFragmentName(),variableDefinitions:this.parseVariableDefinitions(),typeCondition:(this.expectKeyword("on"),this.parseNamedType()),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet(),loc:this.loc(e)}:{kind:st.a.FRAGMENT_DEFINITION,name:this.parseFragmentName(),typeCondition:(this.expectKeyword("on"),this.parseNamedType()),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet(),loc:this.loc(e)}},t.parseFragmentName=function(){if("on"===this._lexer.token.value)throw this.unexpected();return this.parseName()},t.parseValueLiteral=function(e){var t=this._lexer.token;switch(t.kind){case ut.BRACKET_L:return this.parseList(e);case ut.BRACE_L:return this.parseObject(e);case ut.INT:return this._lexer.advance(),{kind:st.a.INT,value:t.value,loc:this.loc(t)};case ut.FLOAT:return this._lexer.advance(),{kind:st.a.FLOAT,value:t.value,loc:this.loc(t)};case ut.STRING:case ut.BLOCK_STRING:return this.parseStringLiteral();case ut.NAME:return"true"===t.value||"false"===t.value?(this._lexer.advance(),{kind:st.a.BOOLEAN,value:"true"===t.value,loc:this.loc(t)}):"null"===t.value?(this._lexer.advance(),{kind:st.a.NULL,loc:this.loc(t)}):(this._lexer.advance(),{kind:st.a.ENUM,value:t.value,loc:this.loc(t)});case ut.DOLLAR:if(!e)return this.parseVariable()}throw this.unexpected()},t.parseStringLiteral=function(){var e=this._lexer.token;return this._lexer.advance(),{kind:st.a.STRING,value:e.value,block:e.kind===ut.BLOCK_STRING,loc:this.loc(e)}},t.parseList=function(e){var t=this,r=this._lexer.token;return{kind:st.a.LIST,values:this.any(ut.BRACKET_L,(function(){return t.parseValueLiteral(e)}),ut.BRACKET_R),loc:this.loc(r)}},t.parseObject=function(e){var t=this,r=this._lexer.token;return{kind:st.a.OBJECT,fields:this.any(ut.BRACE_L,(function(){return t.parseObjectField(e)}),ut.BRACE_R),loc:this.loc(r)}},t.parseObjectField=function(e){var t=this._lexer.token,r=this.parseName();return this.expectToken(ut.COLON),{kind:st.a.OBJECT_FIELD,name:r,value:this.parseValueLiteral(e),loc:this.loc(t)}},t.parseDirectives=function(e){for(var t=[];this.peek(ut.AT);)t.push(this.parseDirective(e));return t},t.parseDirective=function(e){var t=this._lexer.token;return this.expectToken(ut.AT),{kind:st.a.DIRECTIVE,name:this.parseName(),arguments:this.parseArguments(e),loc:this.loc(t)}},t.parseTypeReference=function(){var e,t=this._lexer.token;return this.expectOptionalToken(ut.BRACKET_L)?(e=this.parseTypeReference(),this.expectToken(ut.BRACKET_R),e={kind:st.a.LIST_TYPE,type:e,loc:this.loc(t)}):e=this.parseNamedType(),this.expectOptionalToken(ut.BANG)?{kind:st.a.NON_NULL_TYPE,type:e,loc:this.loc(t)}:e},t.parseNamedType=function(){var e=this._lexer.token;return{kind:st.a.NAMED_TYPE,name:this.parseName(),loc:this.loc(e)}},t.parseTypeSystemDefinition=function(){var e=this.peekDescription()?this._lexer.lookahead():this._lexer.token;if(e.kind===ut.NAME)switch(e.value){case"schema":return this.parseSchemaDefinition();case"scalar":return this.parseScalarTypeDefinition();case"type":return this.parseObjectTypeDefinition();case"interface":return this.parseInterfaceTypeDefinition();case"union":return this.parseUnionTypeDefinition();case"enum":return this.parseEnumTypeDefinition();case"input":return this.parseInputObjectTypeDefinition();case"directive":return this.parseDirectiveDefinition()}throw this.unexpected(e)},t.peekDescription=function(){return this.peek(ut.STRING)||this.peek(ut.BLOCK_STRING)},t.parseDescription=function(){if(this.peekDescription())return this.parseStringLiteral()},t.parseSchemaDefinition=function(){var e=this._lexer.token;this.expectKeyword("schema");var t=this.parseDirectives(!0),r=this.many(ut.BRACE_L,this.parseOperationTypeDefinition,ut.BRACE_R);return{kind:st.a.SCHEMA_DEFINITION,directives:t,operationTypes:r,loc:this.loc(e)}},t.parseOperationTypeDefinition=function(){var e=this._lexer.token,t=this.parseOperationType();this.expectToken(ut.COLON);var r=this.parseNamedType();return{kind:st.a.OPERATION_TYPE_DEFINITION,operation:t,type:r,loc:this.loc(e)}},t.parseScalarTypeDefinition=function(){var e=this._lexer.token,t=this.parseDescription();this.expectKeyword("scalar");var r=this.parseName(),n=this.parseDirectives(!0);return{kind:st.a.SCALAR_TYPE_DEFINITION,description:t,name:r,directives:n,loc:this.loc(e)}},t.parseObjectTypeDefinition=function(){var e=this._lexer.token,t=this.parseDescription();this.expectKeyword("type");var r=this.parseName(),n=this.parseImplementsInterfaces(),i=this.parseDirectives(!0),o=this.parseFieldsDefinition();return{kind:st.a.OBJECT_TYPE_DEFINITION,description:t,name:r,interfaces:n,directives:i,fields:o,loc:this.loc(e)}},t.parseImplementsInterfaces=function(){var e=[];if(this.expectOptionalKeyword("implements")){this.expectOptionalToken(ut.AMP);do{e.push(this.parseNamedType())}while(this.expectOptionalToken(ut.AMP)||this._options.allowLegacySDLImplementsInterfaces&&this.peek(ut.NAME))}return e},t.parseFieldsDefinition=function(){return this._options.allowLegacySDLEmptyFields&&this.peek(ut.BRACE_L)&&this._lexer.lookahead().kind===ut.BRACE_R?(this._lexer.advance(),this._lexer.advance(),[]):this.optionalMany(ut.BRACE_L,this.parseFieldDefinition,ut.BRACE_R)},t.parseFieldDefinition=function(){var e=this._lexer.token,t=this.parseDescription(),r=this.parseName(),n=this.parseArgumentDefs();this.expectToken(ut.COLON);var i=this.parseTypeReference(),o=this.parseDirectives(!0);return{kind:st.a.FIELD_DEFINITION,description:t,name:r,arguments:n,type:i,directives:o,loc:this.loc(e)}},t.parseArgumentDefs=function(){return this.optionalMany(ut.PAREN_L,this.parseInputValueDef,ut.PAREN_R)},t.parseInputValueDef=function(){var e=this._lexer.token,t=this.parseDescription(),r=this.parseName();this.expectToken(ut.COLON);var n,i=this.parseTypeReference();this.expectOptionalToken(ut.EQUALS)&&(n=this.parseValueLiteral(!0));var o=this.parseDirectives(!0);return{kind:st.a.INPUT_VALUE_DEFINITION,description:t,name:r,type:i,defaultValue:n,directives:o,loc:this.loc(e)}},t.parseInterfaceTypeDefinition=function(){var e=this._lexer.token,t=this.parseDescription();this.expectKeyword("interface");var r=this.parseName(),n=this.parseDirectives(!0),i=this.parseFieldsDefinition();return{kind:st.a.INTERFACE_TYPE_DEFINITION,description:t,name:r,directives:n,fields:i,loc:this.loc(e)}},t.parseUnionTypeDefinition=function(){var e=this._lexer.token,t=this.parseDescription();this.expectKeyword("union");var r=this.parseName(),n=this.parseDirectives(!0),i=this.parseUnionMemberTypes();return{kind:st.a.UNION_TYPE_DEFINITION,description:t,name:r,directives:n,types:i,loc:this.loc(e)}},t.parseUnionMemberTypes=function(){var e=[];if(this.expectOptionalToken(ut.EQUALS)){this.expectOptionalToken(ut.PIPE);do{e.push(this.parseNamedType())}while(this.expectOptionalToken(ut.PIPE))}return e},t.parseEnumTypeDefinition=function(){var e=this._lexer.token,t=this.parseDescription();this.expectKeyword("enum");var r=this.parseName(),n=this.parseDirectives(!0),i=this.parseEnumValuesDefinition();return{kind:st.a.ENUM_TYPE_DEFINITION,description:t,name:r,directives:n,values:i,loc:this.loc(e)}},t.parseEnumValuesDefinition=function(){return this.optionalMany(ut.BRACE_L,this.parseEnumValueDefinition,ut.BRACE_R)},t.parseEnumValueDefinition=function(){var e=this._lexer.token,t=this.parseDescription(),r=this.parseName(),n=this.parseDirectives(!0);return{kind:st.a.ENUM_VALUE_DEFINITION,description:t,name:r,directives:n,loc:this.loc(e)}},t.parseInputObjectTypeDefinition=function(){var e=this._lexer.token,t=this.parseDescription();this.expectKeyword("input");var r=this.parseName(),n=this.parseDirectives(!0),i=this.parseInputFieldsDefinition();return{kind:st.a.INPUT_OBJECT_TYPE_DEFINITION,description:t,name:r,directives:n,fields:i,loc:this.loc(e)}},t.parseInputFieldsDefinition=function(){return this.optionalMany(ut.BRACE_L,this.parseInputValueDef,ut.BRACE_R)},t.parseTypeSystemExtension=function(){var e=this._lexer.lookahead();if(e.kind===ut.NAME)switch(e.value){case"schema":return this.parseSchemaExtension();case"scalar":return this.parseScalarTypeExtension();case"type":return this.parseObjectTypeExtension();case"interface":return this.parseInterfaceTypeExtension();case"union":return this.parseUnionTypeExtension();case"enum":return this.parseEnumTypeExtension();case"input":return this.parseInputObjectTypeExtension()}throw this.unexpected(e)},t.parseSchemaExtension=function(){var e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("schema");var t=this.parseDirectives(!0),r=this.optionalMany(ut.BRACE_L,this.parseOperationTypeDefinition,ut.BRACE_R);if(0===t.length&&0===r.length)throw this.unexpected();return{kind:st.a.SCHEMA_EXTENSION,directives:t,operationTypes:r,loc:this.loc(e)}},t.parseScalarTypeExtension=function(){var e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("scalar");var t=this.parseName(),r=this.parseDirectives(!0);if(0===r.length)throw this.unexpected();return{kind:st.a.SCALAR_TYPE_EXTENSION,name:t,directives:r,loc:this.loc(e)}},t.parseObjectTypeExtension=function(){var e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("type");var t=this.parseName(),r=this.parseImplementsInterfaces(),n=this.parseDirectives(!0),i=this.parseFieldsDefinition();if(0===r.length&&0===n.length&&0===i.length)throw this.unexpected();return{kind:st.a.OBJECT_TYPE_EXTENSION,name:t,interfaces:r,directives:n,fields:i,loc:this.loc(e)}},t.parseInterfaceTypeExtension=function(){var e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("interface");var t=this.parseName(),r=this.parseDirectives(!0),n=this.parseFieldsDefinition();if(0===r.length&&0===n.length)throw this.unexpected();return{kind:st.a.INTERFACE_TYPE_EXTENSION,name:t,directives:r,fields:n,loc:this.loc(e)}},t.parseUnionTypeExtension=function(){var e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("union");var t=this.parseName(),r=this.parseDirectives(!0),n=this.parseUnionMemberTypes();if(0===r.length&&0===n.length)throw this.unexpected();return{kind:st.a.UNION_TYPE_EXTENSION,name:t,directives:r,types:n,loc:this.loc(e)}},t.parseEnumTypeExtension=function(){var e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("enum");var t=this.parseName(),r=this.parseDirectives(!0),n=this.parseEnumValuesDefinition();if(0===r.length&&0===n.length)throw this.unexpected();return{kind:st.a.ENUM_TYPE_EXTENSION,name:t,directives:r,values:n,loc:this.loc(e)}},t.parseInputObjectTypeExtension=function(){var e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("input");var t=this.parseName(),r=this.parseDirectives(!0),n=this.parseInputFieldsDefinition();if(0===r.length&&0===n.length)throw this.unexpected();return{kind:st.a.INPUT_OBJECT_TYPE_EXTENSION,name:t,directives:r,fields:n,loc:this.loc(e)}},t.parseDirectiveDefinition=function(){var e=this._lexer.token,t=this.parseDescription();this.expectKeyword("directive"),this.expectToken(ut.AT);var r=this.parseName(),n=this.parseArgumentDefs(),i=this.expectOptionalKeyword("repeatable");this.expectKeyword("on");var o=this.parseDirectiveLocations();return{kind:st.a.DIRECTIVE_DEFINITION,description:t,name:r,arguments:n,repeatable:i,locations:o,loc:this.loc(e)}},t.parseDirectiveLocations=function(){this.expectOptionalToken(ut.PIPE);var e=[];do{e.push(this.parseDirectiveLocation())}while(this.expectOptionalToken(ut.PIPE));return e},t.parseDirectiveLocation=function(){var e=this._lexer.token,t=this.parseName();if(void 0!==yt[t.value])return t;throw this.unexpected(e)},t.loc=function(e){if(!this._options.noLocation)return new xt(e,this._lexer.lastToken,this._lexer.source)},t.peek=function(e){return this._lexer.token.kind===e},t.expectToken=function(e){var t=this._lexer.token;if(t.kind===e)return this._lexer.advance(),t;throw at(this._lexer.source,t.start,"Expected ".concat(e,", found ").concat(_t(t)))},t.expectOptionalToken=function(e){var t=this._lexer.token;if(t.kind===e)return this._lexer.advance(),t},t.expectKeyword=function(e){var t=this._lexer.token;if(t.kind!==ut.NAME||t.value!==e)throw at(this._lexer.source,t.start,'Expected "'.concat(e,'", found ').concat(_t(t)));this._lexer.advance()},t.expectOptionalKeyword=function(e){var t=this._lexer.token;return t.kind===ut.NAME&&t.value===e&&(this._lexer.advance(),!0)},t.unexpected=function(e){var t=e||this._lexer.token;return at(this._lexer.source,t.start,"Unexpected ".concat(_t(t)))},t.any=function(e,t,r){this.expectToken(e);for(var n=[];!this.expectOptionalToken(r);)n.push(t.call(this));return n},t.optionalMany=function(e,t,r){if(this.expectOptionalToken(e)){var n=[];do{n.push(t.call(this))}while(!this.expectOptionalToken(r));return n}return[]},t.many=function(e,t,r){this.expectToken(e);var n=[];do{n.push(t.call(this))}while(!this.expectOptionalToken(r));return n},e}();function xt(e,t,r){this.start=e.start,this.end=t.end,this.startToken=e,this.endToken=t,this.source=r}function _t(e){var t=e.value;return t?"".concat(e.kind,' "').concat(t,'"'):e.kind}Je(xt,(function(){return{start:this.start,end:this.end}}));var Et=new Map,St=new Map,kt=!0,Ot=!1;function Tt(e){return e.replace(/[\s,]+/g," ").trim()}function It(e){var t=new Set,r=[];return e.definitions.forEach((function(e){if("FragmentDefinition"===e.kind){var n=e.name.value,i=function(e){return Tt(e.source.body.substring(e.start,e.end))}(e.loc),o=St.get(n);o&&!o.has(i)?kt&&console.warn("Warning: fragment with name "+n+" already exists.\ngraphql-tag enforces all fragment names across your application to be unique; read more about\nthis in the docs: http://dev.apollodata.com/core/fragments.html#unique-names"):o||St.set(n,o=new Set),o.add(i),t.has(i)||(t.add(i),r.push(e))}else r.push(e)})),qe(qe({},e),{definitions:r})}function At(e){var t=Tt(e);if(!Et.has(t)){var r=function(e,t){return new wt(e,t).parseDocument()}(e,{experimentalFragmentVariables:Ot});if(!r||"Document"!==r.kind)throw new Error("Not a valid GraphQL document.");Et.set(t,function(e){var t=new Set(e.definitions);t.forEach((function(e){e.loc&&delete e.loc,Object.keys(e).forEach((function(r){var n=e[r];n&&"object"==typeof n&&t.add(n)}))}));var r=e.loc;return r&&(delete r.startToken,delete r.endToken),e}(It(r)))}return Et.get(t)}function Rt(e){for(var t=[],r=1;r0}var or,ar=function(e){function t(r){var n=r.graphQLErrors,i=r.networkError,o=r.errorMessage,a=r.extraInfo,s=e.call(this,o)||this;return s.graphQLErrors=n||[],s.networkError=i||null,s.message=o||function(e){var t="";return ir(e.graphQLErrors)&&e.graphQLErrors.forEach((function(e){var r=e?e.message:"Error message not found.";t+="GraphQL error: "+r+"\n"})),e.networkError&&(t+="Network error: "+e.networkError.message+"\n"),t=t.replace(/\n$/,"")}(s),s.extraInfo=a,s.__proto__=t.prototype,s}return Object(Lt.c)(t,e),t}(Error);!function(e){e[e.normal=1]="normal",e[e.refetch=2]="refetch",e[e.poll=3]="poll"}(or||(or={}));var sr=function(e){function t(t){var r=t.queryManager,n=t.options,i=t.shouldSubscribe,o=void 0===i||i,a=e.call(this,(function(e){return a.onSubscribe(e)}))||this;a.observers=new Set,a.subscriptions=new Set,a.isTornDown=!1,a.options=n,a.variables=n.variables||{},a.queryId=r.generateQueryId(),a.shouldSubscribe=o;var s=Object(jt.m)(n.query);return a.queryName=s&&s.name&&s.name.value,a.queryManager=r,a}return Object(Lt.c)(t,e),t.prototype.result=function(){var e=this;return new Promise((function(t,r){var n={next:function(r){t(r),e.observers.delete(n),e.observers.size||e.queryManager.removeQuery(e.queryId),setTimeout((function(){i.unsubscribe()}),0)},error:r},i=e.subscribe(n)}))},t.prototype.currentResult=function(){var e=this.getCurrentResult();return void 0===e.data&&(e.data={}),e},t.prototype.getCurrentResult=function(){if(this.isTornDown){var e=this.lastResult;return{data:!this.lastError&&e&&e.data||void 0,error:this.lastError,loading:!1,networkStatus:Zt.error}}var t,r=this.queryManager.getCurrentQueryResult(this),n=r.data,i=r.partial,o=this.queryManager.queryStore.get(this.queryId),a=this.options.fetchPolicy,s="network-only"===a||"no-cache"===a;if(o){var c=o.networkStatus;if(function(e,t){return void 0===t&&(t="none"),e&&(e.networkError||"none"===t&&ir(e.graphQLErrors))}(o,this.options.errorPolicy))return{data:void 0,loading:!1,networkStatus:c,error:new ar({graphQLErrors:o.graphQLErrors,networkError:o.networkError})};o.variables&&(this.options.variables=Object(Lt.a)(Object(Lt.a)({},this.options.variables),o.variables),this.variables=this.options.variables),t={data:n,loading:rr(c),networkStatus:c},o.graphQLErrors&&"all"===this.options.errorPolicy&&(t.errors=o.graphQLErrors)}else{var l=s||i&&"cache-only"!==a;t={data:n,loading:l,networkStatus:l?Zt.loading:Zt.ready}}return i||this.updateLastResult(Object(Lt.a)(Object(Lt.a)({},t),{stale:!1})),Object(Lt.a)(Object(Lt.a)({},t),{partial:i})},t.prototype.isDifferentFromLastResult=function(e){var t=this.lastResultSnapshot;return!(t&&e&&t.networkStatus===e.networkStatus&&t.stale===e.stale&&Object(Ft.a)(t.data,e.data))},t.prototype.getLastResult=function(){return this.lastResult},t.prototype.getLastError=function(){return this.lastError},t.prototype.resetLastResults=function(){delete this.lastResult,delete this.lastResultSnapshot,delete this.lastError,this.isTornDown=!1},t.prototype.resetQueryStoreErrors=function(){var e=this.queryManager.queryStore.get(this.queryId);e&&(e.networkError=null,e.graphQLErrors=[])},t.prototype.refetch=function(e){var t=this.options.fetchPolicy;return"cache-only"===t?Promise.reject(new Gt.a(1)):("no-cache"!==t&&"cache-and-network"!==t&&(t="network-only"),Object(Ft.a)(this.variables,e)||(this.variables=Object(Lt.a)(Object(Lt.a)({},this.variables),e)),Object(Ft.a)(this.options.variables,this.variables)||(this.options.variables=Object(Lt.a)(Object(Lt.a)({},this.options.variables),this.variables)),this.queryManager.fetchQuery(this.queryId,Object(Lt.a)(Object(Lt.a)({},this.options),{fetchPolicy:t}),or.refetch))},t.prototype.fetchMore=function(e){var t=this;Object(Gt.b)(e.updateQuery,2);var r=Object(Lt.a)(Object(Lt.a)({},e.query?e:Object(Lt.a)(Object(Lt.a)(Object(Lt.a)({},this.options),e),{variables:Object(Lt.a)(Object(Lt.a)({},this.variables),e.variables)})),{fetchPolicy:"network-only"}),n=this.queryManager.generateQueryId();return this.queryManager.fetchQuery(n,r,or.normal,this.queryId).then((function(i){return t.updateQuery((function(t){return e.updateQuery(t,{fetchMoreResult:i.data,variables:r.variables})})),t.queryManager.stopQuery(n),i}),(function(e){throw t.queryManager.stopQuery(n),e}))},t.prototype.subscribeToMore=function(e){var t=this,r=this.queryManager.startGraphQLSubscription({query:e.document,variables:e.variables}).subscribe({next:function(r){var n=e.updateQuery;n&&t.updateQuery((function(e,t){var i=t.variables;return n(e,{subscriptionData:r,variables:i})}))},error:function(t){e.onError&&e.onError(t)}});return this.subscriptions.add(r),function(){t.subscriptions.delete(r)&&r.unsubscribe()}},t.prototype.setOptions=function(e){var t=this.options.fetchPolicy;this.options=Object(Lt.a)(Object(Lt.a)({},this.options),e),e.pollInterval?this.startPolling(e.pollInterval):0===e.pollInterval&&this.stopPolling();var r=e.fetchPolicy;return this.setVariables(this.options.variables,t!==r&&("cache-only"===t||"standby"===t||"network-only"===r),e.fetchResults)},t.prototype.setVariables=function(e,t,r){return void 0===t&&(t=!1),void 0===r&&(r=!0),this.isTornDown=!1,e=e||this.variables,!t&&Object(Ft.a)(e,this.variables)?this.observers.size&&r?this.result():Promise.resolve():(this.variables=this.options.variables=e,this.observers.size?this.queryManager.fetchQuery(this.queryId,this.options):Promise.resolve())},t.prototype.updateQuery=function(e){var t=this.queryManager,r=t.getQueryWithPreviousResult(this.queryId),n=r.previousResult,i=r.variables,o=r.document,a=Object(jt.I)((function(){return e(n,{variables:i})}));a&&(t.dataStore.markUpdateQueryResult(o,i,a),t.broadcastQueries())},t.prototype.stopPolling=function(){this.queryManager.stopPollingQuery(this.queryId),this.options.pollInterval=void 0},t.prototype.startPolling=function(e){ur(this),this.options.pollInterval=e,this.queryManager.startPollingQuery(this.options,this.queryId)},t.prototype.updateLastResult=function(e){var t=this.lastResult;return this.lastResult=e,this.lastResultSnapshot=this.queryManager.assumeImmutableResults?e:Object(jt.f)(e),t},t.prototype.onSubscribe=function(e){var t=this;try{var r=e._subscription._observer;r&&!r.error&&(r.error=cr)}catch(e){}var n=!this.observers.size;return this.observers.add(e),e.next&&this.lastResult&&e.next(this.lastResult),e.error&&this.lastError&&e.error(this.lastError),n&&this.setUpQuery(),function(){t.observers.delete(e)&&!t.observers.size&&t.tearDownQuery()}},t.prototype.setUpQuery=function(){var e=this,t=this.queryManager,r=this.queryId;this.shouldSubscribe&&t.addObservableQuery(r,this),this.options.pollInterval&&(ur(this),t.startPollingQuery(this.options,r));var n=function(t){e.updateLastResult(Object(Lt.a)(Object(Lt.a)({},e.lastResult),{errors:t.graphQLErrors,networkStatus:Zt.error,loading:!1})),lr(e.observers,"error",e.lastError=t)};t.observeQuery(r,this.options,{next:function(r){if(e.lastError||e.isDifferentFromLastResult(r)){var n=e.updateLastResult(r),i=e.options,o=i.query,a=i.variables,s=i.fetchPolicy;t.transform(o).hasClientExports?t.getLocalState().addExportedVariables(o,a).then((function(i){var a=e.variables;e.variables=e.options.variables=i,!r.loading&&n&&"cache-only"!==s&&t.transform(o).serverQuery&&!Object(Ft.a)(a,i)?e.refetch():lr(e.observers,"next",r)})):lr(e.observers,"next",r)}},error:n}).catch(n)},t.prototype.tearDownQuery=function(){var e=this.queryManager;this.isTornDown=!0,e.stopPollingQuery(this.queryId),this.subscriptions.forEach((function(e){return e.unsubscribe()})),this.subscriptions.clear(),e.removeObservableQuery(this.queryId),e.stopQuery(this.queryId),this.observers.clear()},t}(nr);function cr(e){}function lr(e,t,r){var n=[];e.forEach((function(e){return e[t]&&n.push(e)})),n.forEach((function(e){return e[t](r)}))}function ur(e){var t=e.options.fetchPolicy;Object(Gt.b)("cache-first"!==t&&"cache-only"!==t,3)}var pr=function(){function e(){this.store={}}return e.prototype.getStore=function(){return this.store},e.prototype.get=function(e){return this.store[e]},e.prototype.initMutation=function(e,t,r){this.store[e]={mutation:t,variables:r||{},loading:!0,error:null}},e.prototype.markMutationError=function(e,t){var r=this.store[e];r&&(r.loading=!1,r.error=t)},e.prototype.markMutationResult=function(e){var t=this.store[e];t&&(t.loading=!1,t.error=null)},e.prototype.reset=function(){this.store={}},e}(),dr=function(){function e(){this.store={}}return e.prototype.getStore=function(){return this.store},e.prototype.get=function(e){return this.store[e]},e.prototype.initQuery=function(e){var t=this.store[e.queryId];Object(Gt.b)(!t||t.document===e.document||Object(Ft.a)(t.document,e.document),19);var r,n=!1,i=null;e.storePreviousVariables&&t&&t.networkStatus!==Zt.loading&&(Object(Ft.a)(t.variables,e.variables)||(n=!0,i=t.variables)),r=n?Zt.setVariables:e.isPoll?Zt.poll:e.isRefetch?Zt.refetch:Zt.loading;var o=[];t&&t.graphQLErrors&&(o=t.graphQLErrors),this.store[e.queryId]={document:e.document,variables:e.variables,previousVariables:i,networkError:null,graphQLErrors:o,networkStatus:r,metadata:e.metadata},"string"==typeof e.fetchMoreForQueryId&&this.store[e.fetchMoreForQueryId]&&(this.store[e.fetchMoreForQueryId].networkStatus=Zt.fetchMore)},e.prototype.markQueryResult=function(e,t,r){this.store&&this.store[e]&&(this.store[e].networkError=null,this.store[e].graphQLErrors=ir(t.errors)?t.errors:[],this.store[e].previousVariables=null,this.store[e].networkStatus=Zt.ready,"string"==typeof r&&this.store[r]&&(this.store[r].networkStatus=Zt.ready))},e.prototype.markQueryError=function(e,t,r){this.store&&this.store[e]&&(this.store[e].networkError=t,this.store[e].networkStatus=Zt.error,"string"==typeof r&&this.markQueryResultClient(r,!0))},e.prototype.markQueryResultClient=function(e,t){var r=this.store&&this.store[e];r&&(r.networkError=null,r.previousVariables=null,t&&(r.networkStatus=Zt.ready))},e.prototype.stopQuery=function(e){delete this.store[e]},e.prototype.reset=function(e){var t=this;Object.keys(this.store).forEach((function(r){e.indexOf(r)<0?t.stopQuery(r):t.store[r].networkStatus=Zt.loading}))},e}();var fr=function(){function e(e){var t=e.cache,r=e.client,n=e.resolvers,i=e.fragmentMatcher;this.cache=t,r&&(this.client=r),n&&this.addResolvers(n),i&&this.setFragmentMatcher(i)}return e.prototype.addResolvers=function(e){var t=this;this.resolvers=this.resolvers||{},Array.isArray(e)?e.forEach((function(e){t.resolvers=Object(jt.A)(t.resolvers,e)})):this.resolvers=Object(jt.A)(this.resolvers,e)},e.prototype.setResolvers=function(e){this.resolvers={},this.addResolvers(e)},e.prototype.getResolvers=function(){return this.resolvers||{}},e.prototype.runResolvers=function(e){var t=e.document,r=e.remoteResult,n=e.context,i=e.variables,o=e.onlyRunForcedResolvers,a=void 0!==o&&o;return Object(Lt.b)(this,void 0,void 0,(function(){return Object(Lt.d)(this,(function(e){return t?[2,this.resolveDocument(t,r.data,n,i,this.fragmentMatcher,a).then((function(e){return Object(Lt.a)(Object(Lt.a)({},r),{data:e.result})}))]:[2,r]}))}))},e.prototype.setFragmentMatcher=function(e){this.fragmentMatcher=e},e.prototype.getFragmentMatcher=function(){return this.fragmentMatcher},e.prototype.clientQuery=function(e){return Object(jt.s)(["client"],e)&&this.resolvers?e:null},e.prototype.serverQuery=function(e){return this.resolvers?Object(jt.C)(e):e},e.prototype.prepareContext=function(e){void 0===e&&(e={});var t=this.cache;return Object(Lt.a)(Object(Lt.a)({},e),{cache:t,getCacheKey:function(e){if(t.config)return t.config.dataIdFromObject(e);Object(Gt.b)(!1,6)}})},e.prototype.addExportedVariables=function(e,t,r){return void 0===t&&(t={}),void 0===r&&(r={}),Object(Lt.b)(this,void 0,void 0,(function(){return Object(Lt.d)(this,(function(n){return e?[2,this.resolveDocument(e,this.buildRootValueFromCache(e,t)||{},this.prepareContext(r),t).then((function(e){return Object(Lt.a)(Object(Lt.a)({},t),e.exportedVariables)}))]:[2,Object(Lt.a)({},t)]}))}))},e.prototype.shouldForceResolvers=function(e){var t=!1;return Object(tr.b)(e,{Directive:{enter:function(e){if("client"===e.name.value&&e.arguments&&(t=e.arguments.some((function(e){return"always"===e.name.value&&"BooleanValue"===e.value.kind&&!0===e.value.value}))))return tr.a}}}),t},e.prototype.buildRootValueFromCache=function(e,t){return this.cache.diff({query:Object(jt.d)(e),variables:t,returnPartialData:!0,optimistic:!1}).result},e.prototype.resolveDocument=function(e,t,r,n,i,o){return void 0===r&&(r={}),void 0===n&&(n={}),void 0===i&&(i=function(){return!0}),void 0===o&&(o=!1),Object(Lt.b)(this,void 0,void 0,(function(){var a,s,c,l,u,p,d,f,h;return Object(Lt.d)(this,(function(m){return a=Object(jt.l)(e),s=Object(jt.j)(e),c=Object(jt.g)(s),l=a.operation,u=l?function(e){return e.charAt(0).toUpperCase()+e.slice(1)}(l):"Query",d=(p=this).cache,f=p.client,h={fragmentMap:c,context:Object(Lt.a)(Object(Lt.a)({},r),{cache:d,client:f}),variables:n,fragmentMatcher:i,defaultOperationType:u,exportedVariables:{},onlyRunForcedResolvers:o},[2,this.resolveSelectionSet(a.selectionSet,t,h).then((function(e){return{result:e,exportedVariables:h.exportedVariables}}))]}))}))},e.prototype.resolveSelectionSet=function(e,t,r){return Object(Lt.b)(this,void 0,void 0,(function(){var n,i,o,a,s,c=this;return Object(Lt.d)(this,(function(l){return n=r.fragmentMap,i=r.context,o=r.variables,a=[t],s=function(e){return Object(Lt.b)(c,void 0,void 0,(function(){var s,c;return Object(Lt.d)(this,(function(l){return Object(jt.F)(e,o)?Object(jt.t)(e)?[2,this.resolveField(e,t,r).then((function(t){var r;void 0!==t&&a.push(((r={})[Object(jt.E)(e)]=t,r))}))]:(Object(jt.v)(e)?s=e:(s=n[e.name.value],Object(Gt.b)(s,7)),s&&s.typeCondition&&(c=s.typeCondition.name.value,r.fragmentMatcher(t,c,i))?[2,this.resolveSelectionSet(s.selectionSet,t,r).then((function(e){a.push(e)}))]:[2]):[2]}))}))},[2,Promise.all(e.selections.map(s)).then((function(){return Object(jt.B)(a)}))]}))}))},e.prototype.resolveField=function(e,t,r){return Object(Lt.b)(this,void 0,void 0,(function(){var n,i,o,a,s,c,l,u,p,d=this;return Object(Lt.d)(this,(function(f){return n=r.variables,i=e.name.value,o=Object(jt.E)(e),a=i!==o,s=t[o]||t[i],c=Promise.resolve(s),r.onlyRunForcedResolvers&&!this.shouldForceResolvers(e)||(l=t.__typename||r.defaultOperationType,(u=this.resolvers&&this.resolvers[l])&&((p=u[a?i:o])&&(c=Promise.resolve(p(t,Object(jt.b)(e,n),r.context,{field:e,fragmentMap:r.fragmentMap}))))),[2,c.then((function(t){return void 0===t&&(t=s),e.directives&&e.directives.forEach((function(e){"export"===e.name.value&&e.arguments&&e.arguments.forEach((function(e){"as"===e.name.value&&"StringValue"===e.value.kind&&(r.exportedVariables[e.value.value]=t)}))})),e.selectionSet?null==t?t:Array.isArray(t)?d.resolveSubSelectedArray(e,t,r):e.selectionSet?d.resolveSelectionSet(e.selectionSet,t,r):void 0:t}))]}))}))},e.prototype.resolveSubSelectedArray=function(e,t,r){var n=this;return Promise.all(t.map((function(t){return null===t?null:Array.isArray(t)?n.resolveSubSelectedArray(e,t,r):e.selectionSet?n.resolveSelectionSet(e.selectionSet,t,r):void 0})))},e}();function hr(e){var t=new Set,r=null;return new nr((function(n){return t.add(n),r=r||e.subscribe({next:function(e){t.forEach((function(t){return t.next&&t.next(e)}))},error:function(e){t.forEach((function(t){return t.error&&t.error(e)}))},complete:function(){t.forEach((function(e){return e.complete&&e.complete()}))}}),function(){t.delete(n)&&!t.size&&r&&(r.unsubscribe(),r=null)}}))}var mr=Object.prototype.hasOwnProperty,gr=function(){function e(e){var t=e.link,r=e.queryDeduplication,n=void 0!==r&&r,i=e.store,o=e.onBroadcast,a=void 0===o?function(){}:o,s=e.ssrMode,c=void 0!==s&&s,l=e.clientAwareness,u=void 0===l?{}:l,p=e.localState,d=e.assumeImmutableResults;this.mutationStore=new pr,this.queryStore=new dr,this.clientAwareness={},this.idCounter=1,this.queries=new Map,this.fetchQueryRejectFns=new Map,this.transformCache=new(jt.e?WeakMap:Map),this.inFlightLinkObservables=new Map,this.pollingInfoByQueryId=new Map,this.link=t,this.queryDeduplication=n,this.dataStore=i,this.onBroadcast=a,this.clientAwareness=u,this.localState=p||new fr({cache:i.getCache()}),this.ssrMode=c,this.assumeImmutableResults=!!d}return e.prototype.stop=function(){var e=this;this.queries.forEach((function(t,r){e.stopQueryNoBroadcast(r)})),this.fetchQueryRejectFns.forEach((function(e){e(new Gt.a(8))}))},e.prototype.mutate=function(e){var t=e.mutation,r=e.variables,n=e.optimisticResponse,i=e.updateQueries,o=e.refetchQueries,a=void 0===o?[]:o,s=e.awaitRefetchQueries,c=void 0!==s&&s,l=e.update,u=e.errorPolicy,p=void 0===u?"none":u,d=e.fetchPolicy,f=e.context,h=void 0===f?{}:f;return Object(Lt.b)(this,void 0,void 0,(function(){var e,o,s,u=this;return Object(Lt.d)(this,(function(f){switch(f.label){case 0:return Object(Gt.b)(t,9),Object(Gt.b)(!d||"no-cache"===d,10),e=this.generateQueryId(),t=this.transform(t).document,this.setQuery(e,(function(){return{document:t}})),r=this.getVariables(t,r),this.transform(t).hasClientExports?[4,this.localState.addExportedVariables(t,r,h)]:[3,2];case 1:r=f.sent(),f.label=2;case 2:return o=function(){var e={};return i&&u.queries.forEach((function(t,r){var n=t.observableQuery;if(n){var o=n.queryName;o&&mr.call(i,o)&&(e[r]={updater:i[o],query:u.queryStore.get(r)})}})),e},this.mutationStore.initMutation(e,t,r),this.dataStore.markMutationInit({mutationId:e,document:t,variables:r,updateQueries:o(),update:l,optimisticResponse:n}),this.broadcastQueries(),s=this,[2,new Promise((function(i,u){var f,m;s.getObservableFromLink(t,Object(Lt.a)(Object(Lt.a)({},h),{optimisticResponse:n}),r,!1).subscribe({next:function(n){Object(jt.q)(n)&&"none"===p?m=new ar({graphQLErrors:n.errors}):(s.mutationStore.markMutationResult(e),"no-cache"!==d&&s.dataStore.markMutationResult({mutationId:e,result:n,document:t,variables:r,updateQueries:o(),update:l}),f=n)},error:function(t){s.mutationStore.markMutationError(e,t),s.dataStore.markMutationComplete({mutationId:e,optimisticResponse:n}),s.broadcastQueries(),s.setQuery(e,(function(){return{document:null}})),u(new ar({networkError:t}))},complete:function(){if(m&&s.mutationStore.markMutationError(e,m),s.dataStore.markMutationComplete({mutationId:e,optimisticResponse:n}),s.broadcastQueries(),m)u(m);else{"function"==typeof a&&(a=a(f));var t=[];ir(a)&&a.forEach((function(e){if("string"==typeof e)s.queries.forEach((function(r){var n=r.observableQuery;n&&n.queryName===e&&t.push(n.refetch())}));else{var r={query:e.query,variables:e.variables,fetchPolicy:"network-only"};e.context&&(r.context=e.context),t.push(s.query(r))}})),Promise.all(c?t:[]).then((function(){s.setQuery(e,(function(){return{document:null}})),"ignore"===p&&f&&Object(jt.q)(f)&&delete f.errors,i(f)}))}}})}))]}}))}))},e.prototype.fetchQuery=function(e,t,r,n){return Object(Lt.b)(this,void 0,void 0,(function(){var i,o,a,s,c,l,u,p,d,f,h,m,g,v,b,y,w,x,_=this;return Object(Lt.d)(this,(function(E){switch(E.label){case 0:return i=t.metadata,o=void 0===i?null:i,a=t.fetchPolicy,s=void 0===a?"cache-first":a,c=t.context,l=void 0===c?{}:c,u=this.transform(t.query).document,p=this.getVariables(u,t.variables),this.transform(u).hasClientExports?[4,this.localState.addExportedVariables(u,p,l)]:[3,2];case 1:p=E.sent(),E.label=2;case 2:if(t=Object(Lt.a)(Object(Lt.a)({},t),{variables:p}),h=f="network-only"===s||"no-cache"===s,f||(m=this.dataStore.getCache().diff({query:u,variables:p,returnPartialData:!0,optimistic:!1}),g=m.complete,v=m.result,h=!g||"cache-and-network"===s,d=v),b=h&&"cache-only"!==s&&"standby"!==s,Object(jt.s)(["live"],u)&&(b=!0),y=this.idCounter++,w="no-cache"!==s?this.updateQueryWatch(e,u,t):void 0,this.setQuery(e,(function(){return{document:u,lastRequestId:y,invalidated:!0,cancel:w}})),this.invalidate(n),this.queryStore.initQuery({queryId:e,document:u,storePreviousVariables:b,variables:p,isPoll:r===or.poll,isRefetch:r===or.refetch,metadata:o,fetchMoreForQueryId:n}),this.broadcastQueries(),b){if(x=this.fetchRequest({requestId:y,queryId:e,document:u,options:t,fetchMoreForQueryId:n}).catch((function(t){throw function(e){return e.hasOwnProperty("graphQLErrors")}(t)?t:(y>=_.getQuery(e).lastRequestId&&(_.queryStore.markQueryError(e,t,n),_.invalidate(e),_.invalidate(n),_.broadcastQueries()),new ar({networkError:t}))})),"cache-and-network"!==s)return[2,x];x.catch((function(){}))}return this.queryStore.markQueryResultClient(e,!b),this.invalidate(e),this.invalidate(n),this.transform(u).hasForcedResolvers?[2,this.localState.runResolvers({document:u,remoteResult:{data:d},context:l,variables:p,onlyRunForcedResolvers:!0}).then((function(r){return _.markQueryResult(e,r,t,n),_.broadcastQueries(),r}))]:(this.broadcastQueries(),[2,{data:d}])}}))}))},e.prototype.markQueryResult=function(e,t,r,n){var i=r.fetchPolicy,o=r.variables,a=r.errorPolicy;"no-cache"===i?this.setQuery(e,(function(){return{newData:{result:t.data,complete:!0}}})):this.dataStore.markQueryResult(t,this.getQuery(e).document,o,n,"ignore"===a||"all"===a)},e.prototype.queryListenerForObserver=function(e,t,r){var n=this;function i(e,t){if(r[e])try{r[e](t)}catch(e){}}return function(r,o){if(n.invalidate(e,!1),r){var a=n.getQuery(e),s=a.observableQuery,c=a.document,l=s?s.options.fetchPolicy:t.fetchPolicy;if("standby"!==l){var u=rr(r.networkStatus),p=s&&s.getLastResult(),d=!(!p||p.networkStatus===r.networkStatus),f=t.returnPartialData||!o&&r.previousVariables||d&&t.notifyOnNetworkStatusChange||"cache-only"===l||"cache-and-network"===l;if(!u||f){var h=ir(r.graphQLErrors),m=s&&s.options.errorPolicy||t.errorPolicy||"none";if("none"===m&&h||r.networkError)return i("error",new ar({graphQLErrors:r.graphQLErrors,networkError:r.networkError}));try{var g=void 0,v=void 0;if(o)"no-cache"!==l&&"network-only"!==l&&n.setQuery(e,(function(){return{newData:null}})),g=o.result,v=!o.complete;else{var b=s&&s.getLastError(),y="none"!==m&&(b&&b.graphQLErrors)!==r.graphQLErrors;if(p&&p.data&&!y)g=p.data,v=!1;else{var w=n.dataStore.getCache().diff({query:c,variables:r.previousVariables||r.variables,returnPartialData:!0,optimistic:!0});g=w.result,v=!w.complete}}var x=v&&!(t.returnPartialData||"cache-only"===l),_={data:x?p&&p.data:g,loading:u,networkStatus:r.networkStatus,stale:x};"all"===m&&h&&(_.errors=r.graphQLErrors),i("next",_)}catch(e){i("error",new ar({networkError:e}))}}}}}},e.prototype.transform=function(e){var t=this.transformCache;if(!t.has(e)){var r=this.dataStore.getCache(),n=r.transformDocument(e),i=Object(jt.D)(r.transformForLink(n)),o=this.localState.clientQuery(n),a=this.localState.serverQuery(i),s={document:n,hasClientExports:Object(jt.r)(n),hasForcedResolvers:this.localState.shouldForceResolvers(n),clientQuery:o,serverQuery:a,defaultVars:Object(jt.h)(Object(jt.m)(n))},c=function(e){e&&!t.has(e)&&t.set(e,s)};c(e),c(n),c(o),c(a)}return t.get(e)},e.prototype.getVariables=function(e,t){return Object(Lt.a)(Object(Lt.a)({},this.transform(e).defaultVars),t)},e.prototype.watchQuery=function(e,t){void 0===t&&(t=!0),Object(Gt.b)("standby"!==e.fetchPolicy,11),e.variables=this.getVariables(e.query,e.variables),void 0===e.notifyOnNetworkStatusChange&&(e.notifyOnNetworkStatusChange=!1);var r=Object(Lt.a)({},e);return new sr({queryManager:this,options:r,shouldSubscribe:t})},e.prototype.query=function(e){var t=this;return Object(Gt.b)(e.query,12),Object(Gt.b)("Document"===e.query.kind,13),Object(Gt.b)(!e.returnPartialData,14),Object(Gt.b)(!e.pollInterval,15),new Promise((function(r,n){var i=t.watchQuery(e,!1);t.fetchQueryRejectFns.set("query:"+i.queryId,n),i.result().then(r,n).then((function(){return t.fetchQueryRejectFns.delete("query:"+i.queryId)}))}))},e.prototype.generateQueryId=function(){return String(this.idCounter++)},e.prototype.stopQueryInStore=function(e){this.stopQueryInStoreNoBroadcast(e),this.broadcastQueries()},e.prototype.stopQueryInStoreNoBroadcast=function(e){this.stopPollingQuery(e),this.queryStore.stopQuery(e),this.invalidate(e)},e.prototype.addQueryListener=function(e,t){this.setQuery(e,(function(e){return e.listeners.add(t),{invalidated:!1}}))},e.prototype.updateQueryWatch=function(e,t,r){var n=this,i=this.getQuery(e).cancel;i&&i();return this.dataStore.getCache().watch({query:t,variables:r.variables,optimistic:!0,previousResult:function(){var t=null,r=n.getQuery(e).observableQuery;if(r){var i=r.getLastResult();i&&(t=i.data)}return t},callback:function(t){n.setQuery(e,(function(){return{invalidated:!0,newData:t}}))}})},e.prototype.addObservableQuery=function(e,t){this.setQuery(e,(function(){return{observableQuery:t}}))},e.prototype.removeObservableQuery=function(e){var t=this.getQuery(e).cancel;this.setQuery(e,(function(){return{observableQuery:null}})),t&&t()},e.prototype.clearStore=function(){this.fetchQueryRejectFns.forEach((function(e){e(new Gt.a(16))}));var e=[];return this.queries.forEach((function(t,r){t.observableQuery&&e.push(r)})),this.queryStore.reset(e),this.mutationStore.reset(),this.dataStore.reset()},e.prototype.resetStore=function(){var e=this;return this.clearStore().then((function(){return e.reFetchObservableQueries()}))},e.prototype.reFetchObservableQueries=function(e){var t=this;void 0===e&&(e=!1);var r=[];return this.queries.forEach((function(n,i){var o=n.observableQuery;if(o){var a=o.options.fetchPolicy;o.resetLastResults(),"cache-only"===a||!e&&"standby"===a||r.push(o.refetch()),t.setQuery(i,(function(){return{newData:null}})),t.invalidate(i)}})),this.broadcastQueries(),Promise.all(r)},e.prototype.observeQuery=function(e,t,r){return this.addQueryListener(e,this.queryListenerForObserver(e,t,r)),this.fetchQuery(e,t)},e.prototype.startQuery=function(e,t,r){return this.addQueryListener(e,r),this.fetchQuery(e,t).catch((function(){})),e},e.prototype.startGraphQLSubscription=function(e){var t=this,r=e.query,n=e.fetchPolicy,i=e.variables;r=this.transform(r).document,i=this.getVariables(r,i);var o=function(e){return t.getObservableFromLink(r,{},e,!1).map((function(i){if(n&&"no-cache"===n||(t.dataStore.markSubscriptionResult(i,r,e),t.broadcastQueries()),Object(jt.q)(i))throw new ar({graphQLErrors:i.errors});return i}))};if(this.transform(r).hasClientExports){var a=this.localState.addExportedVariables(r,i).then(o);return new nr((function(e){var t=null;return a.then((function(r){return t=r.subscribe(e)}),e.error),function(){return t&&t.unsubscribe()}}))}return o(i)},e.prototype.stopQuery=function(e){this.stopQueryNoBroadcast(e),this.broadcastQueries()},e.prototype.stopQueryNoBroadcast=function(e){this.stopQueryInStoreNoBroadcast(e),this.removeQuery(e)},e.prototype.removeQuery=function(e){this.fetchQueryRejectFns.delete("query:"+e),this.fetchQueryRejectFns.delete("fetchRequest:"+e),this.getQuery(e).subscriptions.forEach((function(e){return e.unsubscribe()})),this.queries.delete(e)},e.prototype.getCurrentQueryResult=function(e,t){void 0===t&&(t=!0);var r=e.options,n=r.variables,i=r.query,o=r.fetchPolicy,a=r.returnPartialData,s=e.getLastResult(),c=this.getQuery(e.queryId).newData;if(c&&c.complete)return{data:c.result,partial:!1};if("no-cache"===o||"network-only"===o)return{data:void 0,partial:!1};var l=this.dataStore.getCache().diff({query:i,variables:n,previousResult:s?s.data:void 0,returnPartialData:!0,optimistic:t}),u=l.result,p=l.complete;return{data:p||a?u:void 0,partial:!p}},e.prototype.getQueryWithPreviousResult=function(e){var t;if("string"==typeof e){var r=this.getQuery(e).observableQuery;Object(Gt.b)(r,17),t=r}else t=e;var n=t.options,i=n.variables,o=n.query;return{previousResult:this.getCurrentQueryResult(t,!1).data,variables:i,document:o}},e.prototype.broadcastQueries=function(){var e=this;this.onBroadcast(),this.queries.forEach((function(t,r){t.invalidated&&t.listeners.forEach((function(n){n&&n(e.queryStore.get(r),t.newData)}))}))},e.prototype.getLocalState=function(){return this.localState},e.prototype.getObservableFromLink=function(e,t,r,n){var i,o=this;void 0===n&&(n=this.queryDeduplication);var a=this.transform(e).serverQuery;if(a){var s=this.inFlightLinkObservables,c=this.link,l={query:a,variables:r,operationName:Object(jt.n)(a)||void 0,context:this.prepareContext(Object(Lt.a)(Object(Lt.a)({},t),{forceFetch:!n}))};if(t=l.context,n){var u=s.get(a)||new Map;s.set(a,u);var p=JSON.stringify(r);if(!(i=u.get(p))){u.set(p,i=hr(Jt(c,l)));var d=function(){u.delete(p),u.size||s.delete(a),f.unsubscribe()},f=i.subscribe({next:d,error:d,complete:d})}}else i=hr(Jt(c,l))}else i=nr.of({data:{}}),t=this.prepareContext(t);var h=this.transform(e).clientQuery;return h&&(i=function(e,t){return new nr((function(r){var n=r.next,i=r.error,o=r.complete,a=0,s=!1,c={next:function(e){++a,new Promise((function(r){r(t(e))})).then((function(e){--a,n&&n.call(r,e),s&&c.complete()}),(function(e){--a,i&&i.call(r,e)}))},error:function(e){i&&i.call(r,e)},complete:function(){s=!0,a||o&&o.call(r)}},l=e.subscribe(c);return function(){return l.unsubscribe()}}))}(i,(function(e){return o.localState.runResolvers({document:h,remoteResult:e,context:t,variables:r})}))),i},e.prototype.fetchRequest=function(e){var t,r,n=this,i=e.requestId,o=e.queryId,a=e.document,s=e.options,c=e.fetchMoreForQueryId,l=s.variables,u=s.errorPolicy,p=void 0===u?"none":u,d=s.fetchPolicy;return new Promise((function(e,u){var f=n.getObservableFromLink(a,s.context,l),h="fetchRequest:"+o;n.fetchQueryRejectFns.set(h,u);var m=function(){n.fetchQueryRejectFns.delete(h),n.setQuery(o,(function(e){e.subscriptions.delete(g)}))},g=f.map((function(e){if(i>=n.getQuery(o).lastRequestId&&(n.markQueryResult(o,e,s,c),n.queryStore.markQueryResult(o,e,c),n.invalidate(o),n.invalidate(c),n.broadcastQueries()),"none"===p&&ir(e.errors))return u(new ar({graphQLErrors:e.errors}));if("all"===p&&(r=e.errors),c||"no-cache"===d)t=e.data;else{var f=n.dataStore.getCache().diff({variables:l,query:a,optimistic:!1,returnPartialData:!0}),h=f.result;(f.complete||s.returnPartialData)&&(t=h)}})).subscribe({error:function(e){m(),u(e)},complete:function(){m(),e({data:t,errors:r,loading:!1,networkStatus:Zt.ready,stale:!1})}});n.setQuery(o,(function(e){e.subscriptions.add(g)}))}))},e.prototype.getQuery=function(e){return this.queries.get(e)||{listeners:new Set,invalidated:!1,document:null,newData:null,lastRequestId:1,observableQuery:null,subscriptions:new Set}},e.prototype.setQuery=function(e,t){var r=this.getQuery(e),n=Object(Lt.a)(Object(Lt.a)({},r),t(r));this.queries.set(e,n)},e.prototype.invalidate=function(e,t){void 0===t&&(t=!0),e&&this.setQuery(e,(function(){return{invalidated:t}}))},e.prototype.prepareContext=function(e){void 0===e&&(e={});var t=this.localState.prepareContext(e);return Object(Lt.a)(Object(Lt.a)({},t),{clientAwareness:this.clientAwareness})},e.prototype.checkInFlight=function(e){var t=this.queryStore.get(e);return t&&t.networkStatus!==Zt.ready&&t.networkStatus!==Zt.error},e.prototype.startPollingQuery=function(e,t,r){var n=this,i=e.pollInterval;if(Object(Gt.b)(i,18),!this.ssrMode){var o=this.pollingInfoByQueryId.get(t);o||this.pollingInfoByQueryId.set(t,o={}),o.interval=i,o.options=Object(Lt.a)(Object(Lt.a)({},e),{fetchPolicy:"network-only"});var a=function(){var e=n.pollingInfoByQueryId.get(t);e&&(n.checkInFlight(t)?s():n.fetchQuery(t,e.options,or.poll).then(s,s))},s=function(){var e=n.pollingInfoByQueryId.get(t);e&&(clearTimeout(e.timeout),e.timeout=setTimeout(a,e.interval))};r&&this.addQueryListener(t,r),s()}return t},e.prototype.stopPollingQuery=function(e){this.pollingInfoByQueryId.delete(e)},e}(),vr=function(){function e(e){this.cache=e}return e.prototype.getCache=function(){return this.cache},e.prototype.markQueryResult=function(e,t,r,n,i){void 0===i&&(i=!1);var o=!Object(jt.q)(e);i&&Object(jt.q)(e)&&e.data&&(o=!0),!n&&o&&this.cache.write({result:e.data,dataId:"ROOT_QUERY",query:t,variables:r})},e.prototype.markSubscriptionResult=function(e,t,r){Object(jt.q)(e)||this.cache.write({result:e.data,dataId:"ROOT_SUBSCRIPTION",query:t,variables:r})},e.prototype.markMutationInit=function(e){var t,r=this;e.optimisticResponse&&(t="function"==typeof e.optimisticResponse?e.optimisticResponse(e.variables):e.optimisticResponse,this.cache.recordOptimisticTransaction((function(n){var i=r.cache;r.cache=n;try{r.markMutationResult({mutationId:e.mutationId,result:{data:t},document:e.document,variables:e.variables,updateQueries:e.updateQueries,update:e.update})}finally{r.cache=i}}),e.mutationId))},e.prototype.markMutationResult=function(e){var t=this;if(!Object(jt.q)(e.result)){var r=[{result:e.result.data,dataId:"ROOT_MUTATION",query:e.document,variables:e.variables}],n=e.updateQueries;n&&Object.keys(n).forEach((function(i){var o=n[i],a=o.query,s=o.updater,c=t.cache.diff({query:a.document,variables:a.variables,returnPartialData:!0,optimistic:!1}),l=c.result;if(c.complete){var u=Object(jt.I)((function(){return s(l,{mutationResult:e.result,queryName:Object(jt.n)(a.document)||void 0,queryVariables:a.variables})}));u&&r.push({result:u,dataId:"ROOT_QUERY",query:a.document,variables:a.variables})}})),this.cache.performTransaction((function(t){r.forEach((function(e){return t.write(e)}));var n=e.update;n&&Object(jt.I)((function(){return n(t,e.result)}))}))}},e.prototype.markMutationComplete=function(e){var t=e.mutationId;e.optimisticResponse&&this.cache.removeOptimistic(t)},e.prototype.markUpdateQueryResult=function(e,t,r){this.cache.write({result:r,dataId:"ROOT_QUERY",variables:t,query:e})},e.prototype.reset=function(){return this.cache.reset()},e}(),br=function(){function e(e){var t=this;this.defaultOptions={},this.resetStoreCallbacks=[],this.clearStoreCallbacks=[];var r=e.cache,n=e.ssrMode,i=void 0!==n&&n,o=e.ssrForceFetchDelay,a=void 0===o?0:o,s=e.connectToDevTools,c=e.queryDeduplication,l=void 0===c||c,u=e.defaultOptions,p=e.assumeImmutableResults,d=void 0!==p&&p,f=e.resolvers,h=e.typeDefs,m=e.fragmentMatcher,g=e.name,v=e.version,b=e.link;if(!b&&f&&(b=Xt.empty()),!b||!r)throw new Gt.a(4);this.link=b,this.cache=r,this.store=new vr(r),this.disableNetworkFetches=i||a>0,this.queryDeduplication=l,this.defaultOptions=u||{},this.typeDefs=h,a&&setTimeout((function(){return t.disableNetworkFetches=!1}),a),this.watchQuery=this.watchQuery.bind(this),this.query=this.query.bind(this),this.mutate=this.mutate.bind(this),this.resetStore=this.resetStore.bind(this),this.reFetchObservableQueries=this.reFetchObservableQueries.bind(this);void 0!==s&&(s&&"undefined"!=typeof window)&&(window.__APOLLO_CLIENT__=this),this.version="2.6.10",this.localState=new fr({cache:r,client:this,resolvers:f,fragmentMatcher:m}),this.queryManager=new gr({link:this.link,store:this.store,queryDeduplication:l,ssrMode:i,clientAwareness:{name:g,version:v},localState:this.localState,assumeImmutableResults:d,onBroadcast:function(){t.devToolsHookCb&&t.devToolsHookCb({action:{},state:{queries:t.queryManager.queryStore.getStore(),mutations:t.queryManager.mutationStore.getStore()},dataWithOptimisticResults:t.cache.extract(!0)})}})}return e.prototype.stop=function(){this.queryManager.stop()},e.prototype.watchQuery=function(e){return this.defaultOptions.watchQuery&&(e=Object(Lt.a)(Object(Lt.a)({},this.defaultOptions.watchQuery),e)),!this.disableNetworkFetches||"network-only"!==e.fetchPolicy&&"cache-and-network"!==e.fetchPolicy||(e=Object(Lt.a)(Object(Lt.a)({},e),{fetchPolicy:"cache-first"})),this.queryManager.watchQuery(e)},e.prototype.query=function(e){return this.defaultOptions.query&&(e=Object(Lt.a)(Object(Lt.a)({},this.defaultOptions.query),e)),Object(Gt.b)("cache-and-network"!==e.fetchPolicy,5),this.disableNetworkFetches&&"network-only"===e.fetchPolicy&&(e=Object(Lt.a)(Object(Lt.a)({},e),{fetchPolicy:"cache-first"})),this.queryManager.query(e)},e.prototype.mutate=function(e){return this.defaultOptions.mutate&&(e=Object(Lt.a)(Object(Lt.a)({},this.defaultOptions.mutate),e)),this.queryManager.mutate(e)},e.prototype.subscribe=function(e){return this.queryManager.startGraphQLSubscription(e)},e.prototype.readQuery=function(e,t){return void 0===t&&(t=!1),this.cache.readQuery(e,t)},e.prototype.readFragment=function(e,t){return void 0===t&&(t=!1),this.cache.readFragment(e,t)},e.prototype.writeQuery=function(e){var t=this.cache.writeQuery(e);return this.queryManager.broadcastQueries(),t},e.prototype.writeFragment=function(e){var t=this.cache.writeFragment(e);return this.queryManager.broadcastQueries(),t},e.prototype.writeData=function(e){var t=this.cache.writeData(e);return this.queryManager.broadcastQueries(),t},e.prototype.__actionHookForDevTools=function(e){this.devToolsHookCb=e},e.prototype.__requestRaw=function(e){return Jt(this.link,e)},e.prototype.initQueryManager=function(){return this.queryManager},e.prototype.resetStore=function(){var e=this;return Promise.resolve().then((function(){return e.queryManager.clearStore()})).then((function(){return Promise.all(e.resetStoreCallbacks.map((function(e){return e()})))})).then((function(){return e.reFetchObservableQueries()}))},e.prototype.clearStore=function(){var e=this;return Promise.resolve().then((function(){return e.queryManager.clearStore()})).then((function(){return Promise.all(e.clearStoreCallbacks.map((function(e){return e()})))}))},e.prototype.onResetStore=function(e){var t=this;return this.resetStoreCallbacks.push(e),function(){t.resetStoreCallbacks=t.resetStoreCallbacks.filter((function(t){return t!==e}))}},e.prototype.onClearStore=function(e){var t=this;return this.clearStoreCallbacks.push(e),function(){t.clearStoreCallbacks=t.clearStoreCallbacks.filter((function(t){return t!==e}))}},e.prototype.reFetchObservableQueries=function(e){return this.queryManager.reFetchObservableQueries(e)},e.prototype.extract=function(e){return this.cache.extract(e)},e.prototype.restore=function(e){return this.cache.restore(e)},e.prototype.addResolvers=function(e){this.localState.addResolvers(e)},e.prototype.setResolvers=function(e){this.localState.setResolvers(e)},e.prototype.getResolvers=function(){return this.localState.getResolvers()},e.prototype.setLocalStateFragmentMatcher=function(e){this.localState.setFragmentMatcher(e)},e}();var yr=r("7506"),wr={http:{includeQuery:!0,includeExtensions:!1},headers:{accept:"*/*","content-type":"application/json"},options:{method:"POST"}},xr=function(e,t,r){var n=new Error(r);throw n.name="ServerError",n.response=e,n.statusCode=e.status,n.result=t,n},_r=function(e,t){var r;try{r=JSON.stringify(e)}catch(e){var n=new Gt.a(2);throw n.parseError=e,n}return r},Er=function(e){void 0===e&&(e={});var t=e.uri,r=void 0===t?"/graphql":t,n=e.fetch,i=e.includeExtensions,o=e.useGETForQueries,a=Object(Lt.e)(e,["uri","fetch","includeExtensions","useGETForQueries"]);(function(e){if(!e&&"undefined"==typeof fetch)throw new Gt.a(1)})(n),n||(n=fetch);var s={http:{includeExtensions:i},options:a.fetchOptions,credentials:a.credentials,headers:a.headers};return new Xt((function(e){var t=function(e,t){return e.getContext().uri||("function"==typeof t?t(e):t||"/graphql")}(e,r),i=e.getContext(),a={};if(i.clientAwareness){var c=i.clientAwareness,l=c.name,u=c.version;l&&(a["apollographql-client-name"]=l),u&&(a["apollographql-client-version"]=u)}var p,d=Object(Lt.a)({},a,i.headers),f={http:i.http,options:i.fetchOptions,credentials:i.credentials,headers:d},h=function(e,t){for(var r=[],n=2;n=300&&xr(t,r,"Response not successful: Received status code "+t.status),Array.isArray(r)||r.hasOwnProperty("data")||r.hasOwnProperty("errors")||xr(t,r,"Server response was missing for query '"+(Array.isArray(e)?e.map((function(e){return e.operationName})):e.operationName)+"'."),r}))}}(e)).then((function(e){return r.next(e),r.complete(),e})).catch((function(e){"AbortError"!==e.name&&(e.result&&e.result.errors&&e.result.data&&r.next(e.result),r.error(e))})),function(){p&&p.abort()}}))}))};var Sr=function(e){function t(t){return e.call(this,Er(t).request)||this}return Object(Lt.c)(t,e),t}(Xt);function kr(e){return{kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"GeneratedClientQuery"},selectionSet:Tr(e)}]}}function Or(e,t){return{kind:"Document",definitions:[{kind:"FragmentDefinition",typeCondition:{kind:"NamedType",name:{kind:"Name",value:t||"__FakeType"}},name:{kind:"Name",value:"GeneratedClientQuery"},selectionSet:Tr(e)}]}}function Tr(e){if("number"==typeof e||"boolean"==typeof e||"string"==typeof e||null==e)return null;if(Array.isArray(e))return Tr(e[0]);var t=[];return Object.keys(e).forEach((function(r){var n={kind:"Field",name:{kind:"Name",value:r},selectionSet:Tr(e[r])||void 0};t.push(n)})),{kind:"SelectionSet",selections:t}}var Ir,Ar={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:null,variableDefinitions:null,directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",alias:null,name:{kind:"Name",value:"__typename"},arguments:[],directives:[],selectionSet:null}]}}]},Rr=function(){function e(){}return e.prototype.transformDocument=function(e){return e},e.prototype.transformForLink=function(e){return e},e.prototype.readQuery=function(e,t){return void 0===t&&(t=!1),this.read({query:e.query,variables:e.variables,optimistic:t})},e.prototype.readFragment=function(e,t){return void 0===t&&(t=!1),this.read({query:Object(jt.k)(e.fragment,e.fragmentName),variables:e.variables,rootId:e.id,optimistic:t})},e.prototype.writeQuery=function(e){this.write({dataId:"ROOT_QUERY",result:e.data,query:e.query,variables:e.variables})},e.prototype.writeFragment=function(e){this.write({dataId:e.id,result:e.data,variables:e.variables,query:Object(jt.k)(e.fragment,e.fragmentName)})},e.prototype.writeData=function(e){var t=e.id,r=e.data;if(void 0!==t){var n=null;try{n=this.read({rootId:t,optimistic:!1,query:Ar})}catch(e){}var i=n&&n.__typename||"__ClientData",o=Object.assign({__typename:i},r);this.writeFragment({id:t,fragment:Or(o,i),data:o})}else this.writeQuery({query:kr(r),data:r})},e}();Ir||(Ir={});var Cr=null,Pr={},Nr=1,Mr="@wry/context:Slot",Dr=Array,Ur=Dr[Mr]||function(){var e=function(){function e(){this.id=["slot",Nr++,Date.now(),Math.random().toString(36).slice(2)].join(":")}return e.prototype.hasValue=function(){for(var e=Cr;e;e=e.parent)if(this.id in e.slots){var t=e.slots[this.id];if(t===Pr)break;return e!==Cr&&(Cr.slots[this.id]=t),!0}return Cr&&(Cr.slots[this.id]=Pr),!1},e.prototype.getValue=function(){if(this.hasValue())return Cr.slots[this.id]},e.prototype.withValue=function(e,t,r,n){var i,o=((i={__proto__:null})[this.id]=e,i),a=Cr;Cr={parent:a,slots:o};try{return t.apply(n,r)}finally{Cr=a}},e.bind=function(e){var t=Cr;return function(){var r=Cr;try{return Cr=t,e.apply(this,arguments)}finally{Cr=r}}},e.noContext=function(e,t,r){if(!Cr)return e.apply(r,t);var n=Cr;try{return Cr=null,e.apply(r,t)}finally{Cr=n}},e}();try{Object.defineProperty(Dr,Mr,{value:Dr[Mr]=e,enumerable:!1,writable:!1,configurable:!1})}finally{return e}}();function Lr(){}Ur.bind,Ur.noContext;var jr=function(){function e(e,t){void 0===e&&(e=1/0),void 0===t&&(t=Lr),this.max=e,this.dispose=t,this.map=new Map,this.newest=null,this.oldest=null}return e.prototype.has=function(e){return this.map.has(e)},e.prototype.get=function(e){var t=this.getEntry(e);return t&&t.value},e.prototype.getEntry=function(e){var t=this.map.get(e);if(t&&t!==this.newest){var r=t.older,n=t.newer;n&&(n.older=r),r&&(r.newer=n),t.older=this.newest,t.older.newer=t,t.newer=null,this.newest=t,t===this.oldest&&(this.oldest=n)}return t},e.prototype.set=function(e,t){var r=this.getEntry(e);return r?r.value=t:(r={key:e,value:t,newer:null,older:this.newest},this.newest&&(this.newest.newer=r),this.newest=r,this.oldest=this.oldest||r,this.map.set(e,r),r.value)},e.prototype.clean=function(){for(;this.oldest&&this.map.size>this.max;)this.delete(this.oldest.key)},e.prototype.delete=function(e){var t=this.map.get(e);return!!t&&(t===this.newest&&(this.newest=t.older),t===this.oldest&&(this.oldest=t.newer),t.newer&&(t.newer.older=t.older),t.older&&(t.older.newer=t.newer),this.map.delete(e),this.dispose(t.value,e),!0)},e}(),Fr=new Ur,$r=[],Vr=[];function Gr(e,t){if(!e)throw new Error(t||"assertion failure")}function zr(e){switch(e.length){case 0:throw new Error("unknown value");case 1:return e[0];case 2:throw e[1]}}var Br=function(){function e(t,r){this.fn=t,this.args=r,this.parents=new Set,this.childValues=new Map,this.dirtyChildren=null,this.dirty=!0,this.recomputing=!1,this.value=[],++e.count}return e.prototype.recompute=function(){if(Gr(!this.recomputing,"already recomputing"),function(e){var t=Fr.getValue();if(t)return e.parents.add(t),t.childValues.has(e)||t.childValues.set(e,[]),Hr(e)?Qr(t,e):Kr(t,e),t}(this)||!Jr(this))return Hr(this)?function(e){var t=Zr(e);return Fr.withValue(e,Wr,[e]),function(e){if("function"==typeof e.subscribe)try{tn(e),e.unsubscribe=e.subscribe.apply(null,e.args)}catch(t){return e.setDirty(),!1}return!0}(e)&&function(e){e.dirty=!1,Hr(e)||qr(e)}(e),t.forEach(Jr),zr(e.value)}(this):zr(this.value)},e.prototype.setDirty=function(){this.dirty||(this.dirty=!0,this.value.length=0,Yr(this),tn(this))},e.prototype.dispose=function(){var e=this;Zr(this).forEach(Jr),tn(this),this.parents.forEach((function(t){t.setDirty(),en(t,e)}))},e.count=0,e}();function Wr(e){e.recomputing=!0,e.value.length=0;try{e.value[0]=e.fn.apply(null,e.args)}catch(t){e.value[1]=t}e.recomputing=!1}function Hr(e){return e.dirty||!(!e.dirtyChildren||!e.dirtyChildren.size)}function Yr(e){e.parents.forEach((function(t){return Qr(t,e)}))}function qr(e){e.parents.forEach((function(t){return Kr(t,e)}))}function Qr(e,t){if(Gr(e.childValues.has(t)),Gr(Hr(t)),e.dirtyChildren){if(e.dirtyChildren.has(t))return}else e.dirtyChildren=Vr.pop()||new Set;e.dirtyChildren.add(t),Yr(e)}function Kr(e,t){Gr(e.childValues.has(t)),Gr(!Hr(t));var r=e.childValues.get(t);0===r.length?e.childValues.set(t,function(e){return e.slice(0)}(t.value)):function(e,t){var r=e.length;return r>0&&r===t.length&&e[r-1]===t[r-1]}(r,t.value)||e.setDirty(),Xr(e,t),Hr(e)||qr(e)}function Xr(e,t){var r=e.dirtyChildren;r&&(r.delete(t),0===r.size&&(Vr.length<100&&Vr.push(r),e.dirtyChildren=null))}function Jr(e){return 0===e.parents.size&&"function"==typeof e.reportOrphan&&!0===e.reportOrphan()}function Zr(e){var t=$r;return e.childValues.size>0&&(t=[],e.childValues.forEach((function(r,n){en(e,n),t.push(n)}))),Gr(null===e.dirtyChildren),t}function en(e,t){t.parents.delete(e),e.childValues.delete(t),Xr(e,t)}function tn(e){var t=e.unsubscribe;"function"==typeof t&&(e.unsubscribe=void 0,t())}var rn=function(){function e(e){this.weakness=e}return e.prototype.lookup=function(){for(var e=[],t=0;t-1)},e.prototype.parseIntrospectionResult=function(e){var t={};return e.__schema.types.forEach((function(e){"UNION"!==e.kind&&"INTERFACE"!==e.kind||(t[e.name]=e.possibleTypes.map((function(e){return e.name})))})),t}}(),Object.prototype.hasOwnProperty),pn=function(){function e(e){var t=this;void 0===e&&(e=Object.create(null)),this.data=e,this.depend=sn((function(e){return t.data[e]}),{disposable:!0,makeCacheKey:function(e){return e}})}return e.prototype.toObject=function(){return this.data},e.prototype.get=function(e){return this.depend(e),this.data[e]},e.prototype.set=function(e,t){t!==this.data[e]&&(this.data[e]=t,this.depend.dirty(e))},e.prototype.delete=function(e){un.call(this.data,e)&&(delete this.data[e],this.depend.dirty(e))},e.prototype.clear=function(){this.replace(null)},e.prototype.replace=function(e){var t=this;e?(Object.keys(e).forEach((function(r){t.set(r,e[r])})),Object.keys(this.data).forEach((function(r){un.call(e,r)||t.delete(r)}))):Object.keys(this.data).forEach((function(e){t.delete(e)}))},e}();function dn(e){return new pn(e)}var fn=function(){function e(e){var t=this,r=void 0===e?{}:e,n=r.cacheKeyRoot,i=void 0===n?new rn(jt.e):n,o=r.freezeResults,a=void 0!==o&&o,s=this,c=s.executeStoreQuery,l=s.executeSelectionSet,u=s.executeSubSelectedArray;this.freezeResults=a,this.executeStoreQuery=sn((function(e){return c.call(t,e)}),{makeCacheKey:function(e){var t=e.query,r=e.rootValue,n=e.contextValue,o=e.variableValues,a=e.fragmentMatcher;if(n.store instanceof pn)return i.lookup(n.store,t,a,JSON.stringify(o),r.id)}}),this.executeSelectionSet=sn((function(e){return l.call(t,e)}),{makeCacheKey:function(e){var t=e.selectionSet,r=e.rootValue,n=e.execContext;if(n.contextValue.store instanceof pn)return i.lookup(n.contextValue.store,t,n.fragmentMatcher,JSON.stringify(n.variableValues),r.id)}}),this.executeSubSelectedArray=sn((function(e){return u.call(t,e)}),{makeCacheKey:function(e){var t=e.field,r=e.array,n=e.execContext;if(n.contextValue.store instanceof pn)return i.lookup(n.contextValue.store,t,r,JSON.stringify(n.variableValues))}})}return e.prototype.readQueryFromStore=function(e){return this.diffQueryAgainstStore(Object(Lt.a)(Object(Lt.a)({},e),{returnPartialData:!1})).result},e.prototype.diffQueryAgainstStore=function(e){var t=e.store,r=e.query,n=e.variables,i=e.previousResult,o=e.returnPartialData,a=void 0===o||o,s=e.rootId,c=void 0===s?"ROOT_QUERY":s,l=e.fragmentMatcherFunction,u=e.config,p=Object(jt.o)(r);n=Object(jt.c)({},Object(jt.h)(p),n);var d={store:t,dataIdFromObject:u&&u.dataIdFromObject,cacheRedirects:u&&u.cacheRedirects||{}},f=this.executeStoreQuery({query:r,rootValue:{type:"id",id:c,generated:!0,typename:"Query"},contextValue:d,variableValues:n,fragmentMatcher:l}),h=f.missing&&f.missing.length>0;return h&&!a&&f.missing.forEach((function(e){if(!e.tolerable)throw new Gt.a(8)})),i&&Object(Ft.a)(i,f.result)&&(f.result=i),{result:f.result,complete:!h}},e.prototype.executeStoreQuery=function(e){var t=e.query,r=e.rootValue,n=e.contextValue,i=e.variableValues,o=e.fragmentMatcher,a=void 0===o?mn:o,s=Object(jt.l)(t),c=Object(jt.j)(t),l={query:t,fragmentMap:Object(jt.g)(c),contextValue:n,variableValues:i,fragmentMatcher:a};return this.executeSelectionSet({selectionSet:s.selectionSet,rootValue:r,execContext:l})},e.prototype.executeSelectionSet=function(e){var t=this,r=e.selectionSet,n=e.rootValue,i=e.execContext,o=i.fragmentMap,a=i.contextValue,s=i.variableValues,c={result:null},l=[],u=a.store.get(n.id),p=u&&u.__typename||"ROOT_QUERY"===n.id&&"Query"||void 0;function d(e){var t;return e.missing&&(c.missing=c.missing||[],(t=c.missing).push.apply(t,e.missing)),e.result}return r.selections.forEach((function(e){var r;if(Object(jt.F)(e,s))if(Object(jt.t)(e)){var c=d(t.executeField(u,p,e,i));void 0!==c&&l.push(((r={})[Object(jt.E)(e)]=c,r))}else{var f=void 0;if(Object(jt.v)(e))f=e;else if(!(f=o[e.name.value]))throw new Gt.a(9);var h=f.typeCondition&&f.typeCondition.name.value,m=!h||i.fragmentMatcher(n,h,a);if(m){var g=t.executeSelectionSet({selectionSet:f.selectionSet,rootValue:n,execContext:i});"heuristic"===m&&g.missing&&(g=Object(Lt.a)(Object(Lt.a)({},g),{missing:g.missing.map((function(e){return Object(Lt.a)(Object(Lt.a)({},e),{tolerable:!0})}))})),l.push(d(g))}}})),c.result=Object(jt.B)(l),this.freezeResults,c},e.prototype.executeField=function(e,t,r,n){var i=n.variableValues,o=n.contextValue,a=function(e,t,r,n,i,o){o.resultKey;var a=o.directives,s=r;(n||a)&&(s=Object(jt.p)(s,n,a));var c=void 0;if(e&&void 0===(c=e[s])&&i.cacheRedirects&&"string"==typeof t){var l=i.cacheRedirects[t];if(l){var u=l[r];u&&(c=u(e,n,{getCacheKey:function(e){var t=i.dataIdFromObject(e);return t&&Object(jt.H)({id:t,typename:e.__typename})}}))}}return void 0===c?{result:c,missing:[{object:e,fieldName:s,tolerable:!1}]}:(Object(jt.w)(c)&&(c=c.json),{result:c})}(e,t,r.name.value,Object(jt.b)(r,i),o,{resultKey:Object(jt.E)(r),directives:Object(jt.i)(r,i)});return Array.isArray(a.result)?this.combineExecResults(a,this.executeSubSelectedArray({field:r,array:a.result,execContext:n})):r.selectionSet?null==a.result?a:this.combineExecResults(a,this.executeSelectionSet({selectionSet:r.selectionSet,rootValue:a.result,execContext:n})):(hn(r,a.result),this.freezeResults,a)},e.prototype.combineExecResults=function(){for(var e,t=[],r=0;r=0)return!0;r[e].push(t)}else r[e]=[t];return!1}var xn={fragmentMatcher:new ln,dataIdFromObject:function(e){if(e.__typename){if(void 0!==e.id)return e.__typename+":"+e.id;if(void 0!==e._id)return e.__typename+":"+e._id}return null},addTypename:!0,resultCaching:!0,freezeResults:!1};var _n=Object.prototype.hasOwnProperty,En=function(e){function t(t,r,n){var i=e.call(this,Object.create(null))||this;return i.optimisticId=t,i.parent=r,i.transaction=n,i}return Object(Lt.c)(t,e),t.prototype.toObject=function(){return Object(Lt.a)(Object(Lt.a)({},this.parent.toObject()),this.data)},t.prototype.get=function(e){return _n.call(this.data,e)?this.data[e]:this.parent.get(e)},t}(gn),Sn=function(e){function t(t){void 0===t&&(t={});var r=e.call(this)||this;r.watches=new Set,r.typenameDocumentCache=new Map,r.cacheKeyRoot=new rn(jt.e),r.silenceBroadcast=!1,r.config=Object(Lt.a)(Object(Lt.a)({},xn),t),r.config.customResolvers&&(r.config.cacheRedirects=r.config.customResolvers),r.config.cacheResolvers&&(r.config.cacheRedirects=r.config.cacheResolvers),r.addTypename=!!r.config.addTypename,r.data=r.config.resultCaching?new pn:new gn,r.optimisticData=r.data,r.storeWriter=new bn,r.storeReader=new fn({cacheKeyRoot:r.cacheKeyRoot,freezeResults:t.freezeResults});var n=r,i=n.maybeBroadcastWatch;return r.maybeBroadcastWatch=sn((function(e){return i.call(r,e)}),{makeCacheKey:function(e){if(!e.optimistic&&!e.previousResult)return n.data instanceof pn?n.cacheKeyRoot.lookup(e.query,JSON.stringify(e.variables)):void 0}}),r}return Object(Lt.c)(t,e),t.prototype.restore=function(e){return e&&this.data.replace(e),this},t.prototype.extract=function(e){return void 0===e&&(e=!1),(e?this.optimisticData:this.data).toObject()},t.prototype.read=function(e){if("string"==typeof e.rootId&&void 0===this.data.get(e.rootId))return null;var t=this.config.fragmentMatcher,r=t&&t.match;return this.storeReader.readQueryFromStore({store:e.optimistic?this.optimisticData:this.data,query:this.transformDocument(e.query),variables:e.variables,rootId:e.rootId,fragmentMatcherFunction:r,previousResult:e.previousResult,config:this.config})||null},t.prototype.write=function(e){var t=this.config.fragmentMatcher,r=t&&t.match;this.storeWriter.writeResultToStore({dataId:e.dataId,result:e.result,variables:e.variables,document:this.transformDocument(e.query),store:this.data,dataIdFromObject:this.config.dataIdFromObject,fragmentMatcherFunction:r}),this.broadcastWatches()},t.prototype.diff=function(e){var t=this.config.fragmentMatcher,r=t&&t.match;return this.storeReader.diffQueryAgainstStore({store:e.optimistic?this.optimisticData:this.data,query:this.transformDocument(e.query),variables:e.variables,returnPartialData:e.returnPartialData,previousResult:e.previousResult,fragmentMatcherFunction:r,config:this.config})},t.prototype.watch=function(e){var t=this;return this.watches.add(e),function(){t.watches.delete(e)}},t.prototype.evict=function(e){throw new Gt.a(7)},t.prototype.reset=function(){return this.data.clear(),this.broadcastWatches(),Promise.resolve()},t.prototype.removeOptimistic=function(e){for(var t=[],r=0,n=this.optimisticData;n instanceof En;)n.optimisticId===e?++r:t.push(n),n=n.parent;if(r>0){for(this.optimisticData=n;t.length>0;){var i=t.pop();this.performTransaction(i.transaction,i.optimisticId)}this.broadcastWatches()}},t.prototype.performTransaction=function(e,t){var r=this.data,n=this.silenceBroadcast;this.silenceBroadcast=!0,"string"==typeof t&&(this.data=this.optimisticData=new En(t,this.optimisticData,e));try{e(this)}finally{this.silenceBroadcast=n,this.data=r}this.broadcastWatches()},t.prototype.recordOptimisticTransaction=function(e,t){return this.performTransaction(e,t)},t.prototype.transformDocument=function(e){if(this.addTypename){var t=this.typenameDocumentCache.get(e);return t||(t=Object(jt.a)(e),this.typenameDocumentCache.set(e,t),this.typenameDocumentCache.set(t,t)),t}return e},t.prototype.broadcastWatches=function(){var e=this;this.silenceBroadcast||this.watches.forEach((function(t){return e.maybeBroadcastWatch(t)}))},t.prototype.maybeBroadcastWatch=function(e){e.callback(this.diff({query:e.query,variables:e.variables,previousResult:e.previousResult&&e.previousResult(),optimistic:e.optimistic}))},t}(Rr),kn=r("633a"),On=function(e){function t(t){var r=e.call(this)||this;return t instanceof kn.SubscriptionClient?r.subscriptionClient=t:r.subscriptionClient=new kn.SubscriptionClient(t.uri,t.options,t.webSocketImpl),r}return Object(Lt.c)(t,e),t.prototype.request=function(e){return this.subscriptionClient.request(e)},t}(Xt);function Tn(e){return new Xt((function(t,r){return new Vt((function(n){var i,o,a;try{i=r(t).subscribe({next:function(i){i.errors&&(a=e({graphQLErrors:i.errors,response:i,operation:t,forward:r}))?o=a.subscribe({next:n.next.bind(n),error:n.error.bind(n),complete:n.complete.bind(n)}):n.next(i)},error:function(i){(a=e({operation:t,networkError:i,graphQLErrors:i&&i.result&&i.result.errors,forward:r}))?o=a.subscribe({next:n.next.bind(n),error:n.error.bind(n),complete:n.complete.bind(n)}):n.error(i)},complete:function(){a||n.complete.bind(n)()}})}catch(i){e({networkError:i,operation:t,forward:r}),n.error(i)}return function(){i&&i.unsubscribe(),o&&i.unsubscribe()}}))}))}!function(e){function t(t){var r=e.call(this)||this;return r.link=Tn(t),r}Object(Lt.c)(t,e),t.prototype.request=function(e,t){return this.link.request(e,t)}}(Xt);var In=function(){function e(e,t,r,n){var i=this;this.operation=e,this.nextLink=t,this.delayFor=r,this.retryIf=n,this.retryCount=0,this.values=[],this.complete=!1,this.canceled=!1,this.observers=[],this.currentSubscription=null,this.onNext=function(e){i.values.push(e);for(var t=0,r=i.observers;t=i)&&(r?r(n,t):!!n)}}(i),r}return Object(Lt.c)(t,e),t.prototype.request=function(e,t){var r=new In(e,t,this.delayFor,this.retryIf);return r.start(),new Vt((function(e){return r.subscribe(e),function(){r.unsubscribe(e)}}))},t}(Xt);const Rn=new URL(be||window.location.origin),Cn={},Pn=e=>{Be.debug("[createGraphqlClient]");const t=new Xt((t,r)=>r(t).map(r=>{const{response:{headers:n}}=t.getContext();if(n){const t=n.get("x-environment")||null,r=n.get("x-unraid-api-version")||null;t&&e.commit("SET_MY_SERVERS_ENV",t),r&&e.commit("SET_MY_SERVERS_API_VERSION",r)}return r})).concat(new Sr({uri:`${Rn.protocol}//${Rn.host}/graphql`})),r=`${Rn.protocol.includes("https")?"wss://":"ws://"}${Rn.host}/graphql`,n=new On({uri:r,options:{timeout:65e3,reconnect:!0,connectionParams:{"x-api-key":e.state.apikey}}});let i;n.subscriptionClient.maxConnectTimeGenerator.setMin(3e3),n.subscriptionClient.onConnected(()=>{Be.debug("[🚀 wslink.onConnected 🚀]"),e.commit("SET_GRAPH_ONLINE",!0),e.state.myServersError&&e.commit("SET_MY_SERVERS_ERROR",null)}),n.subscriptionClient.onReconnected(()=>{Be.debug("[🚀 wslink.onReconnected 🚀]"),e.commit("SET_GRAPH_ONLINE",!0),e.commit("SET_GRAPH_RECONNECTED",!0),e.state.myServersError&&e.commit("SET_MY_SERVERS_ERROR",null)}),n.subscriptionClient.onDisconnected(()=>{Be.debug("[🚀 wslink.onDisconnected 🚀] 01"),e.state.graphOnline&&(clearTimeout(i),i=setTimeout(()=>{Be.debug("[🚀 wslink.onDisconnected 🚀] 02"),e.commit("SET_GRAPH_ONLINE",!1),e.state.myServersError||e.commit("SET_MY_SERVERS_ERROR","Disconnected from Unraid API")},150))});const o=Kt(({query:e})=>{const t=Object(jt.l)(e);return"OperationDefinition"===t.kind&&"subscription"===t.operation},n,t),a=function(e){return new Xt((function(t,r){var n=Object(Lt.e)(t,[]);return new Vt((function(i){var o;return Promise.resolve(n).then((function(r){return e(r,t.getContext())})).then(t.setContext).then((function(){o=r(t).subscribe({next:i.next.bind(i),error:i.error.bind(i),complete:i.complete.bind(i)})})).catch(i.error.bind(i)),function(){o&&o.unsubscribe()}}))}))}((t,{headers:r})=>({headers:{...r,"x-api-key":e.state.apikey}})),s=Tn(({graphQLErrors:t,networkError:r})=>{if(t){Be.error("[GraphQL error] %o",t);const r=t[0].message||t[0].error.message||"No error object - [UNRAID]";e.commit("SET_MY_SERVERS_ERROR",r)}if(r){Be.error("[Network error]",r);const t=r.message?r.message:r;e.commit("SET_MY_SERVERS_ERROR",t.includes("Unexpected token < in JSON at position 0")?"Unraid API • CORS Error":t)}e.commit("SET_MY_SERVERS_LOADING",!1)}),c=new An({delay:{initial:300,max:1/0,jitter:!0},attempts:{max:1/0,retryIf:(t,r)=>(Be.debug("[retryLink - retryIf]",{error:t,_operation:r}),e.commit("SET_GRAPH_ONLINE",!1),!!t)}});return new br({link:Xt.from([c,s,a,o]),connectToDevTools:!1,cache:new Sn,defaultOptions:{watchQuery:{fetchPolicy:"no-cache"},query:{fetchPolicy:"no-cache"},mutate:{fetchPolicy:"no-cache"},subscribe:{fetchPolicy:"no-cache",shouldResubscribe:!1}}})},Nn=e=>{if(!e.state.apikey)return Be.debug("[getGraphqlClient] NO API KEY");if(Object.keys(Cn).includes(e.state.apikey))return Be.debug("[getGraphqlClient] found existing client %o",Cn[e.state.apikey]),Cn[e.state.apikey];const t=Pn(e);return Cn[e.state.apikey]=t,Be.debug("[getGraphqlClient] new client inbound %o",t),t},Mn=(e,t)=>(Be.debug("[detectOwnersResponseError]",{"context.state.registered":e.state.registered,"context.state.signOutTriggered":e.state.signOutTriggered,"response.data.owner":t.data.owner,"context.state.myServersError":e.state.myServersError}),e.state.signOutTriggered?Be.debug("[detectOwnersResponseError] signed out; ignoring"):!t.data.owner||t.data.owner&&"root"===t.data.owner.username?(Be.error(Ce,t.data.owner),e.commit("SET_MY_SERVERS_ERROR",`${Ce} ${Se()(e.state.apiVersion,"2.43.3")?"Please update your My Servers plugin to potentially fix this error. Thanks for working with us as we try to solve this bug.":"Please sign out and then sign back in to potentially fix this error. If you have already tried this please contact support. Thanks for working with us as we try to solve this bug."}`),e.commit("SET_MY_SERVERS_ERROR_SHOW_SUPPORT_BTN",!0)):t.data.owner&&"root"!==t.data.owner.username&&e.state.myServersError&&e.state.myServersError.includes(Ce)?(e.commit("SET_MY_SERVERS_ERROR",""),e.commit("SET_MY_SERVERS_ERROR_SHOW_SUPPORT_BTN",!1)):Be.debug("[detectOwnersResponseError] PASSED"));var Dn=function(){return(Dn=Object.assign||function(e){for(var t,r=1,n=arguments.length;r0)&&(r(i.reverse()[0]),n.clearMeasures&&n.clearMeasures(t),$n.callbacks.delete(t),$n.callbacks.size<1&&($n.observer.disconnect(),n.clearResourceTimings&&n.clearResourceTimings()),!0)},$n={callbacks:new Map,observer:null,observe:function(e,t){if(e&&t){var r=jn.a.polyfill("performance",{doThrow:!1});(function(e,t){return!$n.observer&&e&&t&&($n.observer=new t((function(t){$n.callbacks.forEach((function(r,n){Fn(t,n,r,e)}))})),e.clearResourceTimings&&e.clearResourceTimings()),$n.observer})(r,jn.a.polyfill("PerformanceObserver",{doThrow:!1}))&&(Fn(r,e,t,r)||($n.callbacks.size<1&&$n.observer.observe({entryTypes:["resource","measure"]}),$n.callbacks.set(e,t)))}}},Vn=$n,Gn=function(e){this.error=e},zn=function(){return(zn=Object.assign||function(e){for(var t,r=1,n=arguments.length;r1?r[0]+e+"?"+r[1]:this._url+e})},e.prototype.options=function(e,t){return void 0===t&&(t=!0),this.selfFactory({options:t?Ln(this._options,e):e})},e.prototype.query=function(e,t){return void 0===t&&(t=!1),this.selfFactory({url:qn(this._url,e,t)})},e.prototype.headers=function(e){return this.selfFactory({options:Ln(this._options,{headers:e||{}})})},e.prototype.accept=function(e){return this.headers({Accept:e})},e.prototype.content=function(e){var t;return this.headers(((t={})[Hn]=e,t))},e.prototype.auth=function(e){return this.headers({Authorization:e})},e.prototype.catcher=function(e,t){var r=new Map(this._catchers);return r.set(e,t),this.selfFactory({catchers:r})},e.prototype.signal=function(e){return this.selfFactory({options:zn(zn({},this._options),{signal:e.signal})})},e.prototype.resolve=function(e,t){return void 0===t&&(t=!1),this.selfFactory({resolvers:t?[e]:Bn(Bn([],this._resolvers),[e])})},e.prototype.defer=function(e,t){return void 0===t&&(t=!1),this.selfFactory({deferredChain:t?[e]:Bn(Bn([],this._deferredChain),[e])})},e.prototype.middlewares=function(e,t){return void 0===t&&(t=!1),this.selfFactory({middlewares:t?e:Bn(Bn([],this._middlewares),e)})},e.prototype.method=function(e,t,r){void 0===t&&(t={}),void 0===r&&(r=null);var n=this.options(zn(zn({},t),{method:e})),i=n._options.headers;return function(e){var t=e._url,r=e._catchers,n=e._resolvers,i=e._middlewares,o=e._options,a=new Map(r),s=Ln(jn.a.defaults,o),c=jn.a.polyfill("AbortController",{doThrow:!1,instance:!0});!s.signal&&c&&(s.signal=c.signal);var l={ref:null,clear:function(){l.ref&&(clearTimeout(l.ref),l.ref=null)}},u=function(e){return function(t){return 0===e.length?t:1===e.length?e[0](t):e.reduceRight((function(r,n,i){return i===e.length-2?n(r(t)):n(r)}))}}(i)(jn.a.polyfill("fetch"))(t,s),p=u.catch((function(e){throw new Gn(e)})).then((function(e){return l.clear(),e.ok?e:e[jn.a.errorType||"text"]().then((function(t){var r=new Error(t);throw r[jn.a.errorType||"text"]=t,r.status=e.status,r.response=e,r}))})),d=function(t){return t.catch((function(t){l.clear();var r=t instanceof Gn?t.error:t;if(t instanceof Gn&&a.has("__fromFetch"))return a.get("__fromFetch")(r,e);if(a.has(r.status))return a.get(r.status)(r,e);if(a.has(r.name))return a.get(r.name)(r,e);throw r}))},f=function(e){return function(t){return d(e?p.then((function(t){return t&&t[e]()})).then((function(e){return t?t(e):e})):p.then((function(e){return t?t(e):e})))}},h={res:f(null),json:f("json"),blob:f("blob"),formData:f("formData"),arrayBuffer:f("arrayBuffer"),text:f("text"),perfs:function(e){return u.then((function(t){return Vn.observe(t.url,e)})),h},setTimeout:function(e,t){return void 0===t&&(t=c),l.clear(),l.ref=setTimeout((function(){return t.abort()}),e),h},controller:function(){return[c,h]},error:function(e,t){return a.set(e,t),h},badRequest:function(e){return h.error(400,e)},unauthorized:function(e){return h.error(401,e)},forbidden:function(e){return h.error(403,e)},notFound:function(e){return h.error(404,e)},timeout:function(e){return h.error(408,e)},internalError:function(e){return h.error(500,e)},fetchError:function(e){return h.error("__fromFetch",e)},onAbort:function(e){return h.error("AbortError",e)}};return n.reduce((function(t,r){return r(t,e)}),h)}((n=r?"object"!=typeof r||i&&!Object.entries(i).every((function(e){var t=e[0],r=e[1];return t.toLowerCase()!==Hn.toLowerCase()||r.startsWith(Wn)}))?n.body(r):n.json(r):n)._deferredChain.reduce((function(e,t){return t(e,e._url,e._options)}),n))},e.prototype.get=function(e){return this.method("GET",e)},e.prototype.delete=function(e){return this.method("DELETE",e)},e.prototype.put=function(e,t){return this.method("PUT",t,e)},e.prototype.post=function(e,t){return this.method("POST",t,e)},e.prototype.patch=function(e,t){return this.method("PATCH",t,e)},e.prototype.head=function(e){return this.method("HEAD",e)},e.prototype.opts=function(e){return this.method("OPTIONS",e)},e.prototype.replay=function(e){return this.method(this._options.method,e)},e.prototype.body=function(e){return this.selfFactory({options:zn(zn({},this._options),{body:e})})},e.prototype.json=function(e){var t,r=null===(t=Object.entries(this._options.headers||{}).find((function(e){var t=e[0],r=e[1];return t.toLowerCase()===Hn.toLowerCase()&&r.startsWith(Wn)})))||void 0===t?void 0:t[1];return this.content(r||Wn).body(JSON.stringify(e))},e.prototype.formData=function(e,t){return void 0===t&&(t=!1),this.body(function e(t,r,n,i){return void 0===r&&(r=!1),void 0===n&&(n=jn.a.polyfill("FormData",{instance:!0})),void 0===i&&(i=[]),Object.entries(t).forEach((function(t){var o=t[0],a=t[1],s=i.reduce((function(e,t){return e?e+"["+t+"]":t}),null);if(s=s?s+"["+o+"]":o,a instanceof Array)for(var c=0,l=a;cBe.error(e));const Jn=Xn("https://keys.lime-technology.com").catcher(e=>Be.error(e)),Zn=Xn("https://wanip4.unraid.net/").catcher(e=>Be.error(e)),ei=Xn("/webGui/include/InstallKey.php").catcher(e=>Be.error(e)),ti=Xn().catcher(e=>Be.error(e)),ri=Xn("/update.php").catcher(e=>Be.error(e)),ni=Xn("/webGui/include/UpdateDNS.php").catcher(e=>Be.error(e)),ii=Xn("/plugins/dynamix.my.servers/include/unraid-api.php").catcher(e=>Be.error(e)),oi=e=>Jn.url("/ips/newaccount").formUrl(e).post(),ai=(e,t)=>Jn.url(e).formUrl(t).post(),si=e=>Jn.url("/ips/validate").formUrl(e).post(),ci=e=>Jn.url("/ips/troubleshoot").formUrl(e).post(),li=e=>Jn.url("/account/server/unregister").formUrl(e).post(),ui=e=>Jn.url("/account/trial").formUrl(e).post(),pi=e=>Jn.url("/ips/updateaccount").formUrl(e).post(),di=e=>Jn.url("/account/license/transfer").formUrl(e).post();let fi=0;const hi=e=>{setTimeout(()=>{ni.formUrl({csrf_token:e}).post().res(e=>Be.debug("[WebguiUpdateDns] %o",e)).catch(e=>Be.error("[WebguiUpdateDns] %o",e))},500)},mi=e=>{e.preventDefault(),e.returnValue="",alert((void 0).$t("regWizPopUp.closingPopUpMayLeadToErrors"))},gi={openPopUp({commit:e,dispatch:t,state:r},n){if(Be.debug("[openPopUp] %o",n||"focus existing pop-up"),r.popUpWindow)return r.popUpWindow.focus();const i=((e,t,r,n)=>{const i=void 0!==window.screenLeft?window.screenLeft:window.screenX,o=void 0!==window.screenTop?window.screenTop:window.screenY,a=window.innerWidth?window.innerWidth:document.documentElement.clientWidth?document.documentElement.clientWidth:window.screen.width,s=window.innerHeight?window.innerHeight:document.documentElement.clientHeight?document.documentElement.clientHeight:window.screen.height,c=a/window.screen.availWidth>1?a/window.screen.availWidth:1,l=(a-r)/2/c+i,u=(s-n)/2/c+o,p=Object.entries({toolbar:"no",location:"yes",status:"no",menubar:"no",scrollbars:"yes",resizable:"yes",width:r/c,height:n/c,top:u,left:l}).reduce((e,t)=>e+`${t[0]}=${t[1]},`,"");return window.open(e,t,p)})(n.url,n.name,n.width,n.height),o=window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches,a=n.url.toString().includes("/preflight")?"#fff":"linear-gradient(to right, #E22828 0%, #ff8c2f 100%)";i.document.body.style.background=o?"#222":a;try{i.focus(),e("CHANGE_POP_UP_WINDOW",i),e("STATE_AT_OPEN",r.registered);const n=setInterval(()=>{r.popUpWindow||clearInterval(n),r.popUpWindow&&r.popUpWindow.closed&&(clearInterval(n),t("resetPopUp",{reloadWebGUI:!1}))},250);return window.onunload=()=>{r.popUpWindow&&!r.popUpWindow.closed&&r.popUpWindow.close()},!0}catch(e){return alert("Pop-up blocker detected.\nTo continue successfully please add this website to your browser's exeception list then refresh.")}},resetPopUp({commit:e,dispatch:t},r={reloadWebGUI:!0}){Be.debug("[resetPopUp] %o",r),e("CHANGE_POP_UP_WINDOW",null),t("updateServerState"),r.reloadWebGUI&&t("reloadWebGUI")},closePopUp({dispatch:e,state:t},r={reloadWebGUI:!1}){Be.debug("[closePopUp] %o",r),t.popUpWindow&&(t.popUpWindow.close(),e("resetPopUp",{reloadWebGUI:r.reloadWebGUI}))},reloadWebGUI(){Be.debug("[reloadWebGUI] %s","✨"),window.location.reload()},closePopUpFromPopUp({dispatch:e}){Be.debug("[closePopUpFromPopUp] %o"),e("resetPopUp"),window.close()},sendDataPostMessageToServer({state:e}){const t="SignOut"===e.submissionFrom?{event:"MYSERVERS_UNREGISTER"}:{event:"REG_WIZARD",keyfile:e.keyfile,license:e.license,email:e.userEmail,apikey:e.apikey,avatar:e.avatar,username:e.username,guid:e.guid};Be.debug("[sendDataPostMessageToServer] %o",t);try{return Ae.postMessage(JSON.stringify(t),e.osGui?"*":e.site)}catch(e){return Ie||Be.warn("[sendDataPostMessageToServer] !CAN_POST_MESSAGE",t),Be.error("[sendDataPostMessageToServer] %o",e)}},requestUpdatedServerStateFromUpc({state:e}){Be.debug("[requestUpdatedServerStateFromUpc]");try{return Ae.postMessage(JSON.stringify({event:"SUCCESS_NEW_STATE"}),e.osGui?"*":e.site)}catch(e){return Ie||Be.warn("[requestUpdatedServerStateFromUpc] !CAN_POST_MESSAGE",Ie),Be.error("[requestUpdatedServerStateFromUpc] %o",e)}},receivePostMessage({commit:e,dispatch:t,getters:r,state:n},i={event:null}){if(!i.event)return void Be.error("postMessage no event");Be.debug("[receivePostMessage] payload.event %o",i.event);const[o,a]=Pe(i.event.data);if(o)return;Be.log("[receivePostMessage] payload.event.data.event %o",a.event);const s=a&&a.event&&["REQUEST_API_REPORT","API_EXECUTE_PINGBACK"].includes(a.event),c=i.event.origin;if(c.includes("extension://"))return void Be.log("Skipping postMessage from browser extension",c);const l=c===ge,u=ve.includes(c),p=!!(a&&a.server&&a.server.site)&&c===a.server.site,d=c===n.site,f=!!(a&&a.server&&a.server.extraOrigins)&&a.server.extraOrigins.includes(c),h="SESSION"===a.event?p||f:d,m=s||l||u||h,g={"data.server.extraOrigins":a&&a.server?a.server.extraOrigins:"","data.server.site":a&&a.server?a.server.site:"","payload.event.origin":c,"state.site":n.site,pmOriginMatchesDataServerUrl:p,pmOriginMatchesStateSite:d,pmOriginIncludedInExtraOrigins:f,fromRegWiz:l,fromPurchase:u,fromWebGui:h,acceptDebugEvents:s,originAllowed:m};if(!m)return Be.error("[receivePostMessage] ❌ postMessage origin not allowed ❌ %o",g),e("SET_POST_MESSAGE_ERROR",g),void e("SET_RAW_SERVER_STATE",a.server);Be.debug("[receivePostMessage] originAllowed %o",g);const v=e=>{try{return Be.log("[receivePostMessage.sendBackPostMessage] %o",e.event),i.event.source.postMessage(JSON.stringify(e),n.osGui?"*":c)}catch(t){return Be.error("[sendBackPostMessage.catch] %o",{error:t,message:e})}},b=async t=>{if(!t)return Be.error("[installKey] missing license data: %s",t);let r=t.split("/");if(r=r[r.length-1].slice(0,-4).toUpperCase(),r===n.state)return v({event:"LICENSE_PINGBACK",message:"Failed to license new key – duplicate install detected",license:t,success:!1}),Be.error("[installKey] duplicate install detected",{state:n.state,keyType:r});Be.debug("[receivePostMessage.installKey] %o",t);return await ei.query({url:t}).get().res(r=>{Be.debug("[receivePostMessage.installKey] SUCCESS %o",r),setTimeout(()=>{hi(n.csrf)},1e3),v({event:"LICENSE_PINGBACK",message:"New license key installed",license:t,success:!0}),e("SET_PIRATE_KEY",!1)}).catch(e=>{Be.error("[receivePostMessage.installKey] FAILED: "+t,e),v({event:"LICENSE_PINGBACK",message:"Failed to license new key",license:t,success:!1})})},y=async()=>{Be.debug("[receivePostMessage.signOutUnraidNet] 👋");return await ri.formUrl({csrf_token:n.csrf,"#file":r.myServersCfgPath,"#section":"remote",apikey:"",avatar:"",email:"",username:"",wanaccess:"no",...!n.hideMyServers&&{"#command":"/plugins/dynamix.my.servers/scripts/.nginx_reload"}}).post().res(t=>{Be.debug("[receivePostMessage.signOutUnraidNet] WebguiUpdate.res %o",t),e("SET_SIGN_OUT_TRIGGERED",!0),v({event:"ACCOUNT_PINGBACK",success:!0,type:"signOut",webGuiPathname:window.location.pathname})}).catch(e=>{Be.error(`[receivePostMessage.signOutUnraidNet] WebguiUpdate.catch Sign out ${n.servername} from Unraid.net failed 😢 %o`,e),v({event:"ACCOUNT_PINGBACK",success:!1,type:"signOut",webGuiPathname:window.location.pathname})})};switch(a.event){case"SESSION":Be.debug("[receivePostMessage] SESSION"),e("SET_FULL_SERVER_STATE",a.server),e("SET_RAW_SERVER_STATE",a.server),he.mergeLocaleMessage(a.locale,a.messages),he.locale=a.locale,Be.debug(`[receivePostMessage] SESSION ${he.locale} locale & messages set`,he.messages);break;case"PREFLIGHT_REQUEST":if(Be.debug("[receivePostMessage] PREFLIGHT_REQUEST"),!r.allowedOrigins.includes(c)){Be.error("[🙅‍♂️ ACCESS DENIED]");break}try{t("updateServerState").then(e=>{Be.debug("[receivePostMessage] PREFLIGHT_REQUEST.updateServerState.then %o",{res:e,"getters.server":r.server}),v({event:"SESSION",server:{...r.server},locale:he.locale,messages:{...he.messages[he.locale]}})}).catch(e=>{Be.error("[receivePostMessage] PREFLIGHT_REQUEST.updateServerState.catch %o",e),v({event:"DELIVER_NEW_STATE",success:!1})})}catch(e){Be.error("[receivePostMessage] PREFLIGHT_REQUEST.updateServerState.trycatch %o",e),v({event:"DELIVER_NEW_STATE",success:!1})}break;case"LICENSE_PINGBACK":Be.debug("[receivePostMessage] LICENSE_PINGBACK"),e("LICENSE_PINGBACK",a);break;case"ACCOUNT_PINGBACK":Be.debug("[receivePostMessage] ACCOUNT_PINGBACK"),e("ACCOUNT_PINGBACK",a);break;case"DELIVER_NEW_STATE":Be.debug("[receivePostMessage] DELIVER_NEW_STATE %o",a);const i=!!n.license,o=n.licenseAction&&!n.licenseAction.success,s=n.state,l=a&&a.state?a.state:null,u=s===l;if(Be.debug("[receivePostMessage] DELIVER_NEW_STATE %o",{keyToInstall:i,failedKeyInstall:o,oldState:s,newState:l,potentiallyStaleState:u,deliverNewStateRetryCounter:fi}),o){e("RECEIVED_SUCCESS_NEW_SERVERSTATE",Date.now());break}if(i&&u&&fi<6){setTimeout(()=>{Be.debug("[potentiallyStaleState] %o",{potentiallyStaleState:u}),Be.debug("[deliverNewStateRetryCounter] %o",{deliverNewStateRetryCounter:fi}),t("requestUpdatedServerStateFromUpc"),fi+=1},350*fi);break}if(i&&u&&fi>=6){e("SET_APP_ERROR_MESSAGE",`Failed to receive latest server info${n.licenseAction&&n.licenseAction.success?" after successful key install":""}. Please close this pop-up and refresh the webGUI.`),e("RECEIVED_SUCCESS_NEW_SERVERSTATE",Date.now());break}e("SET_FULL_SERVER_STATE",a),e("SET_RAW_SERVER_STATE",a),e("RECEIVED_SUCCESS_NEW_SERVERSTATE",Date.now()),fi=0;break;case"KEY_PURCHASE":Be.debug("[receivePostMessage] KEY_PURCHASE"),b(a.license),a.oem&&y();break;case"MYSERVERS_UNREGISTER":Be.debug("[receivePostMessage] MYSERVERS_UNREGISTER WebguiUpdate"),y();break;case"REG_WIZARD":Be.debug("[receivePostMessage] REG_WIZARD %o",a),a.license&&b(a.license),Be.debug("[receivePostMessage] REG_WIZARD WebguiUpdate %o",a),ri.formUrl({csrf_token:n.csrf,"#file":r.myServersCfgPath,"#section":"remote",regWizTime:`${Date.now()}_${a.guid}`,...a.apikey&&{apikey:a.apikey},...a.email&&{email:a.email},...a.username&&{username:a.username},...a.avatar&&{avatar:a.avatar}}).post().res(r=>{Be.debug("[receivePostMessage] REG_WIZARD WebguiUpdate.res %o",r),a.license||hi(n.csrf),e("SET_SIGN_OUT_TRIGGERED",!1);let i=0;const o=setInterval(()=>{Be.debug("[receivePostMessage] REG_WIZARD WebguiUpdate.res intervalForUpdatedState"),i+=1;try{t("updateServerState").then(e=>{Be.debug("[receivePostMessage] REG_WIZARD WebguiUpdate.res intervalForUpdatedState updatedState %o",{updatedState:e,countIntervalRuns:i}),(!n.hideMyServers&&e.avatar&&e.username&&"root"!==e.username||n.hideMyServers&&i>=4)&&(clearInterval(o),v({event:"ACCOUNT_PINGBACK",success:!0,type:"signIn",webGuiPathname:window.location.pathname,res:e}))}).catch(e=>{Be.error("[receivePostMessage] REG_WIZARD WebguiUpdate.re intervalForUpdatedState error %o",{error:e,countIntervalRuns:i}),clearInterval(o),v({event:"ACCOUNT_PINGBACK",success:!1,type:"signIn",webGuiPathname:window.location.pathname})})}catch(e){Be.error("[receivePostMessage] REG_WIZARD WebguiUpdate catchError %o",{catchError:e,countIntervalRuns:i}),clearInterval(o),v({event:"ACCOUNT_PINGBACK",success:!1,type:"signIn",webGuiPathname:window.location.pathname})}},250)}).catch(e=>{Be.error("[WebguiUpdate] %o",e),v({event:"ACCOUNT_PINGBACK",success:!1,type:"signIn",webGuiPathname:window.location.pathname})});break;case"RELOAD":Be.debug("[receivePostMessage] RELOAD"),window.location.reload();break;case"SUCCESS_NEW_STATE":Be.debug("[receivePostMessage] SUCCESS_NEW_STATE");try{t("updateServerState").then(e=>{Be.debug("[receivePostMessage] SUCCESS_NEW_STATE.updateServerState.then"),v({...e,event:"DELIVER_NEW_STATE",success:!0})}).catch(e=>{Be.error("[receivePostMessage] SUCCESS_NEW_STATE.updateServerState.catch %o",e),v({event:"DELIVER_NEW_STATE",success:!1})})}catch(e){Be.error("[receivePostMessage] SUCCESS_NEW_STATE.updateServerState.trycatch %o",e),v({event:"DELIVER_NEW_STATE",success:!1})}break;case"REDIRECT_MAIN":Be.debug("[receivePostMessage] REDIRECT_MAIN"),window.location.href="/Main";break;case"REQUEST_API_REPORT":const p=n.apiVersion&&Ye()(n.apiVersion,"2.43.3")?"-vv":"-v";Be.debug("[receivePostMessage] REQUEST_API_REPORT %o",{apiVersion:n.apiVersion,param1:p});try{ii.formUrl({csrf_token:n.csrf,command:"report",param1:p}).post().json(t=>{Be.debug("👼 [receivePostMessage] REQUEST_API_REPORT WebguiUnraidApiCommand.json %o",t),e("SET_API_EXECUTE_RESPONSE",t.result),v({event:"API_EXECUTE_PINGBACK",result:t.result})}).catch(e=>{Be.error("[receivePostMessage] REQUEST_API_REPORT WebguiUnraidApiCommand.catch failed to execute `unraid-api` report 😢 %o",e),v({event:"API_EXECUTE_PINGBACK",error:e})})}catch(e){Be.error("[receivePostMessage] REQUEST_API_REPORT WebguiUnraidApiCommand.catch failed to execute `unraid-api` report 😢 %o",e),v({event:"API_EXECUTE_PINGBACK",error:e})}break;case"API_EXECUTE_PINGBACK":Be.debug("[receivePostMessage] API_EXECUTE_PINGBACK"),a&&a.result&&e("SET_API_EXECUTE_RESPONSE",a.result);break;case"YARG_MATEY":Be.debug("[receivePostMessage] YARG_MATEY"),e("SET_PIRATE_KEY",a.ts);break;default:Be.debug("[receivePostMessage] UNHANDLED_MESSAGE")}},setStateFromWebComponentProp({commit:e},t){Be.debug("[setStateFromWebComponentProp]");const[r,n]=Pe(decodeURIComponent(t));return r?Be.error("[setStateFromWebComponentProp] %o",t):e("SET_FULL_SERVER_STATE",n)},async updateServerState({commit:e,dispatch:t,getters:r,state:n}){if(Be.debug("[updateServerState]"),ge===window.location.origin)return Be.debug("[SKIPPED] updateServerState()");Be.debug("[updateServerState]",{"state.signOutTriggered":n.signOutTriggered,"state.hideMyServers":n.hideMyServers,"!state.graphOnline":!n.graphOnline,"!getters.validApiKeyLength":!r.validApiKeyLength,"!getters.validApiKeyForUpc":!r.validApiKeyForUpc}),!n.signOutTriggered&&!n.hideMyServers&&n.graphOnline&&r.validApiKeyLength&&r.validApiKeyForUpc?(Be.debug("[updateServerState] via serverStateFromApi"),await t("serverStateFromApi")):(Be.debug("[updateServerState] via ",r.statePhpPath),await ti.url(r.statePhpPath).get().json().then(t=>t?e("SET_FULL_SERVER_STATE",t):Be.error("[updateUpcFromStatePhp] no `res` skipping `SET_FULL_SERVER_STATE`")).catch(e=>{Be.error("[updateUpcFromStatePhp WebguiState.catch] %o",e),(e.toString().includes("Unexpected token")||e.toString().includes("503"))&&(window.location.href="/")}));const i=r.server;return Be.debug("[updateServerState] newState %o",i),i},async validateGuid({commit:e,getters:t,state:r}){await new Promise((n,i)=>{if(r.guidValidationRunning)return Be.debug("[validateGuid] already validating");e("CHANGE_GUID_VALIDATION_RUNNING",!0);const o=r.regWizTime?r.regWizTime.split("_")[1]:null,a=!!o&&o===r.guid;Be.debug("[validateGuid] %o",{guid:r.guid,regGuid:r.regGuid,regWizTimeGuid:o,previouslyRegistered:a});let s="GUID Invalid";if(!r.guid||r.guid===Te)return Be.debug(`[validateGuid] ${s} %o`,{"!state.guid":!r.guid,GUID_NOT_RECEIVED:Te}),s+=": not present",e("CHANGE_GUID_VALID",!1),e("CHANGE_REPLACEABLE",!1),e("SET_STATE","EBLACKLISTED1"),e("SET_APP_ERROR_MESSAGE",s),e("CHANGE_GUID_VALIDATION_RUNNING",!1),e("SET_LOADING_STATE",!1),n(!1);if(a&&!t.stateData.error)return Be.debug("[validateGuid] previouslyRegistered %s",r.guid),e("CHANGE_GUID_REGISTERED",!0),e("CHANGE_GUID_VALID",!0),e("CHANGE_GUID_FORUMACCOUNT",!0),e("CHANGE_GUID_VALIDATION_RUNNING",!1),e("SET_LOADING_STATE",!1),n(!0);const c=r.guid.includes("000000000000");if(r.guid&&r.guid!==Te&&(c||27!==r.guid.length))return c?(s+=": Too many consecutive zeros",e("SET_STATE","EBLACKLISTED2")):(s+=": Not long enough",e("SET_STATE","EBLACKLISTED1")),e("CHANGE_GUID_VALID",!1),e("CHANGE_REPLACEABLE",!1),e("SET_APP_ERROR_MESSAGE",s),e("CHANGE_GUID_VALIDATION_RUNNING",!1),e("SET_LOADING_STATE",!1),i(new Error(s));r.regGuid||Be.warn("[validateGuid] state.regGuid empty. Getting regGuid from state.regWizTime.");const l=r.regGuid||o||"";e("CHANGE_GUID_FOR_VALIDATION","EGUID"===r.state?l:r.guid),e("CHANGE_GUID_BLACKLISTED",null);try{const t=Jn.url("/validate/guid").formUrl({guid:r.guidForValidation}).post().forbidden(t=>{let n;const[i,o]=Pe(t.message);o&&!i||!t.message||(n=t.message),o&&o.error&&(n=o.error),Be.error("[validateGuid] POST.forbidden %o",n),n.includes("blacklisted")?(e("CHANGE_GUID_BLACKLISTED",!0),"EGUID"!==r.state?(e("SET_STATE","EBLACKLISTED"),e("SET_APP_ERROR_MESSAGE",n)):Be.warn("[validateGuid] skip EBLACKLISTED state overwrite")):n.includes("invalid GUID")&&("EGUID"!==r.state?(e("SET_STATE","EBLACKLISTED1"),e("SET_APP_ERROR_MESSAGE",n)):Be.warn("[validateGuid] skip EBLACKLISTED state overwrite")),e("CHANGE_GUID_VALID",!1),e("CHANGE_REPLACEABLE",!1)}).json(t=>{Be.debug("[validateGuid] POST.json %o",t),t.registered&&e("CHANGE_GUID_REGISTERED",t.registered),e("CHANGE_GUID_FORUMACCOUNT",t.forumaccount||!1),e("CHANGE_GUID_VALID",!0),e("CHANGE_REPLACEABLE",t.replaceable)}).catch(t=>{Be.error("[validateGuid] POST.catch %o",t),e("SET_APP_ERROR_MESSAGE",t.message),i(new Error(t))}).finally(()=>{Be.debug("[validateGuid] POST.finally"),e("CHANGE_GUID_VALIDATION_RUNNING",!1),e("SET_LOADING_STATE",!1)});return n(t)}catch(t){return Be.error("[validateGuid] try/catch %o",t),e("SET_APP_ERROR_MESSAGE",t),e("CHANGE_GUID_VALIDATION_RUNNING",!1),i(new Error(t))}})},async startTrial({commit:e,state:t}){Be.debug("[startTrial]"),e("SET_LOADING_STATE","Fetching trial…"),window.addEventListener("beforeunload",mi),t.isLaunchpadOpen||e("SET_IS_LAUNCHPAD_OPEN",!1),await i.startTrial({timestamp:Math.floor((new Date).getTime()/1e3),guid:t.guid}).json().then(t=>{e("SET_LOADING_STATE","Installing trial…"),ei.query({url:t.license}).get().res(t=>{Be.debug("[KeyServer.startTrial.WebguiInstallKey] SUCCESS %o",t),setTimeout(()=>{e("SET_LOADING_STATE","Verifying trial install…"),setTimeout(()=>{e("SET_LOADING_STATE","Reloading webgui…"),sessionStorage.setItem("showPromoPostTrialInstall",Date.now()),e("SET_PIRATE_KEY",!1),window.removeEventListener("beforeunload",mi),window.location.reload()},4e3)},1500)}).catch(r=>{Be.error("[KeyServer.startTrial.WebguiInstallKey.catch] FAILED: "+t,r);const[n,i]=Pe(r.message);e("SET_APP_ERROR_MESSAGE",i?i.errorMessage?i.errorMessage:i.error:r),e("SET_LOADING_STATE",!1)})}).catch(t=>{Be.error("[KeyServer.startTrial.catch] FAILED",t);const[r,n]=Pe(t.message);e("SET_APP_ERROR_MESSAGE",n?n.errorMessage?n.errorMessage:n.error:t),e("SET_LOADING_STATE",!1)})},togglePromo({commit:e,state:t}){Be.debug("[togglePromo]");const r="unraid-promo";if(!document.getElementsByTagName(r).length){const e=document.getElementsByTagName("body")[0],t=document.createElement(r);e.appendChild(t)}e("SET_IS_LAUNCHPAD_OPEN",!1),e("SET_IS_PROMO_OPEN",!t.isPromoOpen)},jumpToUpc({commit:e}){window.scrollTo({top:0,behavior:"smooth"}),e("TRIGGER_UPC",!0),setTimeout(()=>{e("TRIGGER_UPC",!1)},500)},async getWanIp({commit:e,state:t}){if(Be.debug("[getWanIp]"),t.wanip)return Be.debug("[getWanIp] SKIPPED",t.wanip);try{return e("SET_WANIP",await Zn.get().text())}catch(e){return Be.error("[getWanIp] Unable to get WAN IP")}},async executeUnraidApi({commit:e,state:t},r={command:"",param1:null}){Be.debug("[executeUnraidApi]",r);const{command:n,param1:i}=r;"start"===n&&e("SET_MY_SERVERS_LOADING",!0);return await ii.formUrl({csrf_token:t.csrf,command:n,param1:i}).post().json(e=>{Be.debug("👼 [executeUnraidApi] json %o",e)}).catch(e=>{Be.error(`[executeUnraidApi] catch failed to execute unraid-api ${n} 😢 %o`,e)})},fetchServers:async e=>{Be.debug("[fetchServers]"),e.commit("SET_MY_SERVERS_LOADING",!0);const t=await Nn(e).query({query:Pt`query initialGetServers { +function(e){if(Number(e.version.split(".")[0])>=2)e.mixin({beforeCreate:r});else{var t=e.prototype._init;e.prototype._init=function(e){void 0===e&&(e={}),e.init=e.init?[r].concat(e.init):r,t.call(this,e)}}function r(){var e=this.$options;e.store?this.$store="function"==typeof e.store?e.store():e.store:e.parent&&e.parent.$store&&(this.$store=e.parent.$store)}}(u=e)}f.state.get=function(){return this._vm._data.$$state},f.state.set=function(e){},d.prototype.commit=function(e,t,r){var n=this,i=y(e,t,r),o=i.type,a=i.payload,s=(i.options,{type:o,payload:a}),c=this._mutations[o];c&&(this._withCommit((function(){c.forEach((function(e){e(a)}))})),this._subscribers.slice().forEach((function(e){return e(s,n.state)})))},d.prototype.dispatch=function(e,t){var r=this,n=y(e,t),i=n.type,o=n.payload,a={type:i,payload:o},s=this._actions[i];if(s){try{this._actionSubscribers.slice().filter((function(e){return e.before})).forEach((function(e){return e.before(a,r.state)}))}catch(e){}var c=s.length>1?Promise.all(s.map((function(e){return e(o)}))):s[0](o);return new Promise((function(e,t){c.then((function(t){try{r._actionSubscribers.filter((function(e){return e.after})).forEach((function(e){return e.after(a,r.state)}))}catch(e){}e(t)}),(function(e){try{r._actionSubscribers.filter((function(e){return e.error})).forEach((function(t){return t.error(a,r.state,e)}))}catch(e){}t(e)}))}))}},d.prototype.subscribe=function(e,t){return h(e,this._subscribers,t)},d.prototype.subscribeAction=function(e,t){return h("function"==typeof e?{before:e}:e,this._actionSubscribers,t)},d.prototype.watch=function(e,t,r){var n=this;return this._watcherVM.$watch((function(){return e(n.state,n.getters)}),t,r)},d.prototype.replaceState=function(e){var t=this;this._withCommit((function(){t._vm._data.$$state=e}))},d.prototype.registerModule=function(e,t,r){void 0===r&&(r={}),"string"==typeof e&&(e=[e]),this._modules.register(e,t),v(this,this.state,e,this._modules.get(e),r.preserveState),g(this,this.state)},d.prototype.unregisterModule=function(e){var t=this;"string"==typeof e&&(e=[e]),this._modules.unregister(e),this._withCommit((function(){var r=b(t.state,e.slice(0,-1));u.delete(r,e[e.length-1])})),m(this)},d.prototype.hasModule=function(e){return"string"==typeof e&&(e=[e]),this._modules.isRegistered(e)},d.prototype.hotUpdate=function(e){this._modules.update(e),m(this,!0)},d.prototype._withCommit=function(e){var t=this._committing;this._committing=!0,e(),this._committing=t},Object.defineProperties(d.prototype,f);var x=O((function(e,t){var r={};return k(t).forEach((function(t){var n=t.key,i=t.val;r[n]=function(){var t=this.$store.state,r=this.$store.getters;if(e){var n=T(this.$store,"mapState",e);if(!n)return;t=n.context.state,r=n.context.getters}return"function"==typeof i?i.call(this,t,r):t[i]},r[n].vuex=!0})),r})),_=O((function(e,t){var r={};return k(t).forEach((function(t){var n=t.key,i=t.val;r[n]=function(){for(var t=[],r=arguments.length;r--;)t[r]=arguments[r];var n=this.$store.commit;if(e){var o=T(this.$store,"mapMutations",e);if(!o)return;n=o.context.commit}return"function"==typeof i?i.apply(this,[n].concat(t)):n.apply(this.$store,[i].concat(t))}})),r})),E=O((function(e,t){var r={};return k(t).forEach((function(t){var n=t.key,i=t.val;i=e+i,r[n]=function(){if(!e||T(this.$store,"mapGetters",e))return this.$store.getters[i]},r[n].vuex=!0})),r})),S=O((function(e,t){var r={};return k(t).forEach((function(t){var n=t.key,i=t.val;r[n]=function(){for(var t=[],r=arguments.length;r--;)t[r]=arguments[r];var n=this.$store.dispatch;if(e){var o=T(this.$store,"mapActions",e);if(!o)return;n=o.context.dispatch}return"function"==typeof i?i.apply(this,[n].concat(t)):n.apply(this.$store,[i].concat(t))}})),r}));function k(e){return function(e){return Array.isArray(e)||s(e)}(e)?Array.isArray(e)?e.map((function(e){return{key:e,val:e}})):Object.keys(e).map((function(t){return{key:t,val:e[t]}})):[]}function O(e){return function(t,r){return"string"!=typeof t?(r=t,t=""):"/"!==t.charAt(t.length-1)&&(t+="/"),e(t,r)}}function T(e,t,r){return e._modulesNamespaceMap[r]}function I(e,t,r){var n=r?e.groupCollapsed:e.group;try{n.call(e,t)}catch(r){e.log(t)}}function A(e){try{e.groupEnd()}catch(t){e.log("—— log end ——")}}function R(){var e=new Date;return" @ "+C(e.getHours(),2)+":"+C(e.getMinutes(),2)+":"+C(e.getSeconds(),2)+"."+C(e.getMilliseconds(),3)}function C(e,t){return function(e,t){return new Array(t+1).join(e)}("0",t-e.toString().length)+e}var P={Store:d,install:w,version:"3.6.2",mapState:x,mapMutations:_,mapGetters:E,mapActions:S,createNamespacedHelpers:function(e){return{mapState:x.bind(null,e),mapGetters:E.bind(null,e),mapMutations:_.bind(null,e),mapActions:S.bind(null,e)}},createLogger:function(e){void 0===e&&(e={});var t=e.collapsed;void 0===t&&(t=!0);var r=e.filter;void 0===r&&(r=function(e,t,r){return!0});var n=e.transformer;void 0===n&&(n=function(e){return e});var i=e.mutationTransformer;void 0===i&&(i=function(e){return e});var a=e.actionFilter;void 0===a&&(a=function(e,t){return!0});var s=e.actionTransformer;void 0===s&&(s=function(e){return e});var c=e.logMutations;void 0===c&&(c=!0);var l=e.logActions;void 0===l&&(l=!0);var u=e.logger;return void 0===u&&(u=console),function(e){var p=o(e.state);void 0!==u&&(c&&e.subscribe((function(e,a){var s=o(a);if(r(e,p,s)){var c=R(),l=i(e),d="mutation "+e.type+c;I(u,d,t),u.log("%c prev state","color: #9E9E9E; font-weight: bold",n(p)),u.log("%c mutation","color: #03A9F4; font-weight: bold",l),u.log("%c next state","color: #4CAF50; font-weight: bold",n(s)),A(u)}p=s})),l&&e.subscribeAction((function(e,r){if(a(e,r)){var n=R(),i=s(e),o="action "+e.type+n;I(u,o,t),u.log("%c action","color: #03A9F4; font-weight: bold",i),A(u)}})))}}};t.a=P}).call(this,r("c8ba"))},"2f6c":function(e,t,r){"use strict";r.d(t,"a",(function(){return o})),r.d(t,"b",(function(){return a}));var n=r("ad67"),i={Name:[],Document:["definitions"],OperationDefinition:["name","variableDefinitions","directives","selectionSet"],VariableDefinition:["variable","type","defaultValue","directives"],Variable:["name"],SelectionSet:["selections"],Field:["alias","name","arguments","directives","selectionSet"],Argument:["name","value"],FragmentSpread:["name","directives"],InlineFragment:["typeCondition","directives","selectionSet"],FragmentDefinition:["name","variableDefinitions","typeCondition","directives","selectionSet"],IntValue:[],FloatValue:[],StringValue:[],BooleanValue:[],NullValue:[],EnumValue:[],ListValue:["values"],ObjectValue:["fields"],ObjectField:["name","value"],Directive:["name","arguments"],NamedType:["name"],ListType:["type"],NonNullType:["type"],SchemaDefinition:["directives","operationTypes"],OperationTypeDefinition:["type"],ScalarTypeDefinition:["description","name","directives"],ObjectTypeDefinition:["description","name","interfaces","directives","fields"],FieldDefinition:["description","name","arguments","type","directives"],InputValueDefinition:["description","name","type","defaultValue","directives"],InterfaceTypeDefinition:["description","name","directives","fields"],UnionTypeDefinition:["description","name","directives","types"],EnumTypeDefinition:["description","name","directives","values"],EnumValueDefinition:["description","name","directives"],InputObjectTypeDefinition:["description","name","directives","fields"],DirectiveDefinition:["description","name","arguments","locations"],SchemaExtension:["directives","operationTypes"],ScalarTypeExtension:["name","directives"],ObjectTypeExtension:["name","interfaces","directives","fields"],InterfaceTypeExtension:["name","directives","fields"],UnionTypeExtension:["name","directives","types"],EnumTypeExtension:["name","directives","values"],InputObjectTypeExtension:["name","directives","fields"]},o=Object.freeze({});function a(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:i,a=void 0,l=Array.isArray(e),u=[e],p=-1,d=[],f=void 0,h=void 0,m=void 0,g=[],v=[],b=e;do{var y=++p===u.length,w=y&&0!==d.length;if(y){if(h=0===v.length?void 0:g[g.length-1],f=m,m=v.pop(),w){if(l)f=f.slice();else{for(var x={},_=0,E=Object.keys(f);_{try{t=new n(t,r)}catch(e){return!1}return t.test(e)}},"35d6":function(e,t,r){"use strict";function n(e,t,r){!function(e,t){const r=t._injectedStyles||(t._injectedStyles={});for(var n=0;n0){var n=r.connection.filter?r.connection.filter:[];n.sort();var i=t,o={};return n.forEach((function(e){o[e]=i[e]})),r.connection.key+"("+JSON.stringify(o)+")"}return r.connection.key}var a=e;if(t){var c=s()(t);a+="("+c+")"}return r&&Object.keys(r).forEach((function(e){-1===u.indexOf(e)&&(r[e]&&Object.keys(r[e]).length?a+="@"+e+"("+JSON.stringify(r[e])+")":a+="@"+e)})),a}function d(e,t){if(e.arguments&&e.arguments.length){var r={};return e.arguments.forEach((function(e){var n=e.name,i=e.value;return c(r,n,i,t)})),r}return null}function f(e){return e.alias?e.alias.value:e.name.value}function h(e){return"Field"===e.kind}function m(e){return"InlineFragment"===e.kind}function g(e){return e&&"id"===e.type&&"boolean"==typeof e.generated}function v(e,t){return void 0===t&&(t=!1),Object(o.a)({type:"id",generated:t},"string"==typeof e?{id:e,typename:void 0}:e)}function b(e){return null!=e&&"object"==typeof e&&"json"===e.type}function y(e,t){if(e.directives&&e.directives.length){var r={};return e.directives.forEach((function(e){r[e.name.value]=d(e,t)})),r}return null}function w(e,t){return void 0===t&&(t={}),function(e){return e?e.filter(E).map((function(e){var t=e.arguments;e.name.value,Object(i.b)(t&&1===t.length,14);var r=t[0];Object(i.b)(r.name&&"if"===r.name.value,15);var n=r.value;return Object(i.b)(n&&("Variable"===n.kind||"BooleanValue"===n.kind),16),{directive:e,ifArgument:r}})):[]}(e.directives).every((function(e){var r=e.directive,n=e.ifArgument,o=!1;return"Variable"===n.value.kind?(o=t[n.value.name.value],Object(i.b)(void 0!==o,13)):o=n.value.value,"skip"===r.name.value?!o:o}))}function x(e,t){return function(e){var t=[];return Object(n.b)(e,{Directive:function(e){t.push(e.name.value)}}),t}(t).some((function(t){return e.indexOf(t)>-1}))}function _(e){return e&&x(["client"],e)&&x(["export"],e)}function E(e){var t=e.name.value;return"skip"===t||"include"===t}function S(e,t){var r=t,n=[];return e.definitions.forEach((function(e){if("OperationDefinition"===e.kind)throw new i.a(11);"FragmentDefinition"===e.kind&&n.push(e)})),void 0===r&&(Object(i.b)(1===n.length,12),r=n[0].name.value),Object(o.a)(Object(o.a)({},e),{definitions:Object(o.f)([{kind:"OperationDefinition",operation:"query",selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:r}}]}}],e.definitions)})}function k(e){for(var t=[],r=1;r1){var n=[];t=ae(t,n);for(var i=1;i{switch(t){case"===":return"object"==typeof e&&(e=e.version),"object"==typeof r&&(r=r.version),e===r;case"!==":return"object"==typeof e&&(e=e.version),"object"==typeof r&&(r=r.version),e!==r;case"":case"=":case"==":return n(e,r,l);case"!=":return i(e,r,l);case">":return o(e,r,l);case">=":return a(e,r,l);case"<":return s(e,r,l);case"<=":return c(e,r,l);default:throw new TypeError("Invalid operator: "+t)}}},"56c3":function(e,t){e.exports={functional:!0,render(e,t){const{_c:r,_v:n,data:i,children:o=[]}=t,{class:a,staticClass:s,style:c,staticStyle:l,attrs:u={},...p}=i;return r("svg",{class:[a,s],style:[c,l],attrs:Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32"},u),...p},o.concat([r("path",{attrs:{d:"M26 25v6H6v-6H5a2 2 0 01-2-2v-9c0-.421.13-.812.353-1.134l3.9-9.96A3 3 0 0110.048 1H21.89a3 3 0 012.788 1.891l3.966 9.972c.224.323.355.715.355 1.137v9a2 2 0 01-2 2h-1zm-.26-2H26a1 1 0 001-1v-7a1 1 0 00-1-1H6a1 1 0 00-1 1v7a1 1 0 001 1h.25L8 16h15.927l1.814 7zm.559-11l-3.11-7.745A2 2 0 0021.334 3H10.61a2 2 0 00-1.86 1.265L5.695 12h20.604zM8 24h16l-1.314-6H9.25L8 24zm0 2v3h16v-3H8zm4-6h2.2l-.2 2h-2.5l.5-2zm5.8 0H20l.5 2H18l-.2-2z"}})]))}}},"59c8":function(e){e.exports=JSON.parse('{"getStarted":"Get Started","signIn":"Sign In","signUp":"Sign Up","signInUp":"Sign In / Up","signOut":"Sign Out","error":"Error","fixError":"Fix Error","closeLaunchpad":"Close and continue to webGUI","installPlugin":"Install Plugin","noThanks":"No thanks","closePromo":"Close My Servers details and continue to webGUI","promoHeading":"Enhance your Unraid experience with these
My Servers (BETA) features","learnMore":"Learn more","checkoutTheMyServersDocs":"Checkout the My Servers docs","popUp":"Pop-up","backToPopUp":"Back to @:popUp","closePopUp":"Close @:popUp","close":"Close","contactSupport":"Contact Support","lanIp":"LAN IP {0}","continueToUnraid":"Continue to Unraid","year":"year","years":"years","month":"month","months":"months","day":"day","days":"days","hour":"hour","hours":"hours","minute":"minute","minutes":"minutes","second":"second","seconds":"seconds","ago":"ago","basicPlusPro":{"heading":"Thank you for choosing Unraid OS and My Servers!","message":{"registered":"Connect to My Servers by signing in to Unraid.net","upgradeEligible":"To support more storage devices as your server grows, click Upgrade Key."}},"actions":{"purchase":"Purchase Key","upgrade":"Upgrade Key","recover":"Recover Key","replace":"Replace Key","replaceIneligible":"Replace Key Ineligible","startTrial":"Start Free 30 Day Trial","extend":"Extend Trial","signOutUnraidNet":"Sign Out of Unraid.net","redeemActivationCode":"Redeem Activation Code"},"stateData":{"ENOKEYFILE":{"humanReadable":"No Keyfile","heading":"Let\'s unleash your hardware!","message":"

Your server will not be usable until you purchase a Registration key or install a free 30-day Trial key. A Trial key provides all the functionality of a Pro Registration key.

Registration keys are bound to your USB Flash boot device serial number (GUID). Please use a high quality name brand device at least 1GB in size.

Note: USB memory card readers are generally not supported because most do not present unique serial numbers.

Important:

  • Please make sure your server time is accurate to within 5 minutes
  • Please make sure there is a DNS server specified
"},"TRIAL":{"humanReadable":"Trial","heading":"Thank you for choosing Unraid OS!","message":"

Your Trial key includes all the functionality and device support of a Pro key.

After your Trial has reached expiration, your server still functions normally until the next time you Stop the array or reboot your server.

At that point you may either purchase a license key or request a Trial extension.

","_extraMsg":"

You have {parsedExpireTime} remaining on your Trial key.

"},"EEXPIRED":{"humanReadable":"Trial Expired","heading":"Your Trial has expired","message":{"base":"To continue using Unraid OS you may purchase a license key.","extensionNotEligible":"You have used all your Trial extensions. @:stateData.EEXPIRED.message.base","extensionEligible":"@:stateData.EEXPIRED.message.base Alternately, you may request a Trial extension."}},"BASIC":{"humanReadable":"Basic"},"PLUS":{"humanReadable":"Plus"},"PRO":{"humanReadable":"Pro"},"EGUID":{"humanReadable":"GUID Error","error":{"heading":"Registration key / GUID mismatch","message":{"default":"The license key file does not correspond to the USB Flash boot device. Please copy the correct key file to the /config directory on your USB Flash boot device or choose Purchase Key.","replacementIneligible":"Your Unraid registration key is ineligible for replacement as it has been replaced within the last 12 months.","replacementEligible":"The license key file does not correspond to the USB Flash boot device. Please copy the correct key file to the /config directory on your USB Flash boot device or choose Purchase Key or Replace Key.","blacklisted":"Your Unraid registration key is ineligible for replacement as it is blacklisted."}}},"ENOKEYFILE2":{"humanReadable":"Missing key file","error":{"heading":"@:stateData.ENOKEYFILE2.humanReadable","message":"It appears that your license key file is corrupted or missing. The key file should be located in the /config directory on your USB Flash boot device. If you do not have a backup copy of your license key file you may install the My Servers (beta) plugin to attempt to recover your key. If this was an expired Trial installation, you may purchase a license key."}},"ETRIAL":{"humanReadable":"Invalid installation","error":{"heading":"@:stateData.ETRIAL.humanReadable","message":"It is not possible to use a Trial key with an existing Unraid OS installation. You may purchase a license key corresponding to this USB Flash device to continue using this installation."}},"ENOKEYFILE1":{"humanReadable":"No Keyfile","error":{"heading":"No USB flash configuration data","message":"There is a problem with your USB Flash device"}},"ENOFLASH":{"humanReadable":"No Flash","error":{"heading":"Cannot access your USB Flash boot device","message":"There is a physical problem accessing your USB Flash boot device"}},"EGUID1":{"humanReadable":"Multiple License Keys Present","error":{"heading":"@:stateData.EGUID1.humanReadable","message":"There are multiple license key files present on your USB flash device and none of them correspond to the USB Flash boot device. Please remove all key files, except the one you want to replace, from the /config directory on your USB Flash boot device. Alternately you may purchase a license key for this USB flash device. If you want to replace one of your license keys with a new key bound to this USB Flash device, please first remove all other key files first."}},"EBLACKLISTED":{"humanReadable":"BLACKLISTED","error":{"heading":"Blacklisted USB Flash GUID","message":"This USB Flash boot device has been blacklisted. This can occur as a result of transferring your license key to a replacement USB Flash device, and you are currently booted from your old USB Flash device. A USB Flash device may also be blacklisted if we discover the serial number is not unique – this is common with USB card readers."}},"EBLACKLISTED1":{"humanReadable":"@:stateData.EBLACKLISTED.humanReadable","error":{"heading":"USB Flash device error","message":"This USB Flash device has an invalid GUID. Please try a different USB Flash device"}},"EBLACKLISTED2":{"humanReadable":"@:stateData.EBLACKLISTED.humanReadable","error":{"heading":"USB Flash has no serial number","message":"@:stateData.EBLACKLISTED.error.message"}},"ENOCONN":{"humanReadable":"Trial Requires Internet Connection","error":{"heading":"Cannot validate Unraid Trial key","message":"Your Trial key requires an internet connection. Please check Settings > Network"}},"STALE":{"humanReadable":"Stale","error":{"heading":"Stale Server","message":"Please refresh the page to ensure you load your latest configuration"}}},"upc":{"avatarAlt":"{0}\'s Avatar","confirmClosure":"Confirm closure then continue to webGUI","closeDropdown":"Close dropdown","openDropdown":"Open dropdown","pleaseConfirmClosureYouHaveOpenPopUp":"Please confirm closure. You have an open pop-up.","trialHasExpiredSeeOptions":"Trial has expired, see options below","errorCertRequiresSignIn":"Sign In before your Unraid.net SSL certificate expires","removeMyServersPlugin":"Remove My Servers plugin","continueUsingMyServers":"Continue using My Servers","confirmMyServersPluginRemoval":"Confirm My Servers plugin removal","removingMyServersPlugin":"Removing My Servers plugin…","enhanceYourExperienceWithMyServers":"Enhance your experience with My Servers","connectYourUnraidnetAccountToGetStarted":"Connect your Unraid.net account to get started","thankYouForInstallingMyServers":"Thank you installing My Servers!","lanIpCopied":"LAN IP Copied","installingMyServers":"Installing My Servers (beta)","noRemoteApikeyRegisteredWithPlg":{"heading":"My Servers Error","msg":"Unraid.net re-authentication required"},"errorTooManyDisks":{"heading":"Too many devices","msg":{"base":"You must upgrade your key to support more devices.","basic":"Your Basic key supports 6 devices.","plus":"Your Plus key supports 12 devices."}},"extraLinks":{"newTab":"Opens {0} in new tab","myServers":"My Servers Dashboard","forums":"Unraid Forums","settings":{"text":"Settings","title":"Settings > Management Access • Unraid.net"}},"meta":{"trial":{"active":{"date":"Trial key expires at {date}","timeDiff":"Trial expires in {timeDiff}"},"expired":{"date":"Trial key expired at {date}","timeDiff":"Trial expired {timeDiff}"}},"uptime":{"date":"Server up since {date}","readable":"Uptime {timeDiff}"}},"myServers":{"heading":"My Servers","beta":"beta","restarting":"Restarting…","errors":{"unraidApi":{"heading":"Unraid API Error","message":"Failed to connect to Unraid API."},"myServers":{"heading":"My Servers Error","message":"Please wait a moment and reload the page."}},"closeDetails":"Close Details","loading":"Loading My Servers data","displayingLastKnown":"Displaying last known server data","mothership":{"connected":"Connected to Mothership","notConnected":"Not Connected to Mothership"},"accessLabels":{"current":"Current server","local":"Local access","offline":"Server Offline","remote":"Remote access","unavailable":"Access unavailable"},"api":{"start":"Restart unraid-api","startTitle":"Executes `unraid-api start`; no terminal needed","stop":"Stop unraid-api"}},"opensNewHttpsWindow":{"base":"Opens new HTTPS window to {0}","signIn":"@:upc.opensNewHttpsWindow.base @:signIn","signOut":"@:upc.opensNewHttpsWindow.base @:signOut","purchase":"@:upc.opensNewHttpsWindow.base @:actions.purchase","upgrade":"@:upc.opensNewHttpsWindow.base @:actions.upgrade"},"signInActions":{"resolve":"@:signIn to resolve","purchaseKey":"@:signIn to @:actions.purchase","purchaseKeyOrExtendTrial":"@:upc.signInActions.purchaseKey or @:actions.extend"}},"wanIpCheck":{"checking":"Checking Wan IPs","avatarAlt":"{0}\'s Avatar","match":"Remark: your WAN IPv4 is {0}","mismatch":"Remark: Unraid\'s WAN IPv4 {0} does not match your client\'s WAN IPv4 {1}. This may indicate a complex network that will not work with this Remote Access solution. Ignore this message if you are currently connected via Remote Access or VPN","resolveError":"DNS issue, unable to resolve wanip4.unraid.net"},"regWizPopUp":{"regWiz":"Registration Wizard","toHome":"To Registration Wizard Home","continueTrial":"Continue Trial","serverInfoToggle":"Toggle server info visibility","youCanSafelyCloseThisWindow":"You can safely close this window","automaticallyClosingIn":"Automatically closing in","byeBye":"bye, bye 👋","browserWillSelfDestructIn":"Browser will self destruct in","closingPopUpMayLeadToErrors":"Closing this pop-up window while actions are being preformed may lead to unintended errors.","goBack":"Go Back","shutDown":"Shut Down","haveAccountSignIn":"Already have an account? Sign In","noAccountSignUp":"Don\'t have an account? Sign Up","willConnectYourServerToMyServers":"This will connect your server to My Servers BETA","serverInfo":{"flash":"Flash","product":"Product","GUID":"GUID","name":"Name","ip":"IP"},"forms":{"displayName":"Display Name","emailAddress":"Email Address","displayNameOrEmailAddress":"@:regWizPopUp.forms.displayName or @:regWizPopUp.forms.emailAddress","displayNameRootMessage":"Use your Unraid.net credentials, not your local server credentials.","honeyPotCopy":"If you fill this field out then your email will not be sent","fieldRequired":"This field is required","submit":"Submit","submitting":"submitting…","notValid":"Form not valid","cancel":"Cancel","confirm":"Confirm","createMyAccount":"Create My Account","subject":"Subject","password":"Password","togglePasswordVisibility":"Toggle Password Visibility","message":"Message","confirmPassword":"Confirm Password","passwordMustMatch":"Password confirmation must match","passwordMinimum":"8 or more characters","comments":"comments","newsletterCopy":"Sign me up for the monthly Unraid newsletter: a digest of recent blog posts, community videos, popular forum threads, product announcements, and more.","terms":{"iAgree":"I agree to the","text":"Terms of Use"}},"routes":{"extendTrial":{"heading":{"loading":"Extending Trial","error":"Trial Extension Failed"},"message":"Not ready to purchase?
Receive an additional 15 days for your trial."},"forgotPassword":{"heading":"Forgot Password","subheading":"After resetting your password come back to the Registration Wizard pop-up window to Sign In and complete your server\'s registration.","resetPasswordNow":"Reset Password Now","backToSignIn":"Back to Sign In"},"signIn":{"heading":{"signIn":"Unraid.net Sign In","recover":"Unraid.net Sign In to Recover Key","replace":"Unraid.net Sign In to Replace Key"},"subheading":"Please sign in with your Unraid.net account","form":{"replacementConditions":{"name":"Acknowledge Replacement Conditions","label":"I acknowledge that replacing a license key results in permanently blacklisting the previous USB Flash GUID."},"label":{"password":{"replace":"Unraid.net account password"}}}},"signUp":{"heading":"Create Unraid.net Account","subheading":"This will start your free 30-day Trial"},"signOut":{"heading":"Unraid.net Sign Out"},"success":{"heading":{"username":"Hi {0}!","default":"Success!"},"subheading":{"extention":"Your trial will expire in 15 days.","newTrial":"Your trial will expire in 30 days."},"signIn":{"tileTitle":{"actionFail":"{0} was not signed in to your Unraid.net account","actionSuccess":"{0} is signed in to your Unraid.net account","loading":"Signing in {0} to Unraid.net account"}},"signOut":{"tileTitle":{"actionFail":"{0} was not signed out of your Unraid.net account","actionSuccess":"{0} was signed out of your Unraid.net account","loading":"Signing out {0} from Unraid.net account"}},"keys":{"trial":"Trial","basic":"Basic","plus":"Plus","pro":"Pro"},"extended":"{0} Key Extended","recovered":"{0} Key Recovered","replaced":"{0} Key Replaced","created":"{0} Key Created","install":{"loading":"Installing {0} Key","error":"{0} Key Install Error","success":"Installed {0} Key","manualInstructions":"To manually install the key paste the key file url into the Key file URL field on the webGUI Registration page and then click Install Key","copyFail":"Unable to copy","copySuccess":"Copied key url!","copyButton":"Copy Key URL","copyBeforeClose":"Please copy the Key URL before closing this window"},"timeout":"Communication with {0} has timed out","loading1":"Please keep this window open.","loading2":"Still working our magic","countdown":{"success":{"prefix":"Auto closing in","text":"You can safely close this window"},"error":{"prefix":"Auto redirecting in","text":"Back to Registration Home","complete":"Back in a flash ⚡️"}}},"troubleshoot":{"heading":{"default":"Troubleshoot","success":"Thank you for contacting Unraid."},"subheading":{"default":"Forgot what Unraid.net account you used? Have a USB flash device that already has an account associated with it? Just give us the details about what happened and we\'ll do our best to get you up and running again.","success":"We have received your e-mail and will respond in the order it was received. While we strive to respond to all requests as quickly as possible, please allow for up to 3 business days for a response."},"relevantServerData":"Your USB Flash GUID and other relevant server data will also be sent"},"verifyEmail":{"heading":"Verify Email","form":{"verificationCode":"verification code","verifyCode":"Paste / Enter code"},"noCode":"Didn\'t get code?"},"whatIsMyServers":{"heading":"What is My Servers?","subheading":"Expand your server\'s capabilities","copy":"With an Unraid.net account you can start using My Servers (beta) which gives you access to the following features:","features":{"secureRemoteAccess":{"heading":"Secure remote access","copy":"Whether you need to add a share, container, or virtual machine, do it all from the webGui from anytime and anywhere using HTTPS. Best of all, all SSL certificates are verified by Let\'s Encrypt, so no browser security warnings."},"realTimeMonitoring":{"heading":"Real-time Monitoring","copy":"Get quick real-time info on the status of your servers such as storage, container, and VM usage. And not just for one server, but all the servers in your Unraid fleet!"},"usbFlashBackup":{"heading":"USB Flash Backup","copy":"Click a button and your flash is automatically backed up to Unraid.net, enabling easy recovery in the event of a device failure. Never self-manage/host your flash backups again!"},"regKeyManagement":{"heading":"Registration key management","copy":"Download any registration key linked to your account. Upgrade keys to higher editions."},"plusMore":{"heading":"Plus more on the way","copy":"All you need is an active internet connection, an Unraid.net account, and the My Servers plugin. Get started by installing the plugin."}}},"replaceKey":{"subheading":{"registered":"A record of your replacement will be sent to your Unraid.net account email address","notRegistered":"A record of your replacement will be sent to this email"}},"notFound":{"subheading":"Page Not Found"},"notAllowed":{"subheading":"Page Not Allowed"}}},"upcTrigger":{"upgrade":"To support more storage devices as your server grows click the Open Dropdown button","default":"Key management is done via the dropdown in the top right of the webGUI on every page","open":"Open Dropdown"},"yargYePirate":"Oh no! Are you pirating Unraid OS?
Are you ready to buy a real license?","keyFileNotValid":"Key file not valid","installFailed":{"heading":"My Servers plugin install failed","message":"The My Servers plugin install is incomplete. Please uninstall and reinstall the My Servers plugin. Be sure to let the install complete before you close the window."}}')},"5a0c":function(e,t,r){e.exports=function(){"use strict";var e=6e4,t=36e5,r="millisecond",n="second",i="minute",o="hour",a="day",s="week",c="month",l="quarter",u="year",p="date",d="Invalid Date",f=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,h=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,m={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_")},g=function(e,t,r){var n=String(e);return!n||n.length>=t?e:""+Array(t+1-n.length).join(r)+e},v={s:g,z:function(e){var t=-e.utcOffset(),r=Math.abs(t),n=Math.floor(r/60),i=r%60;return(t<=0?"+":"-")+g(n,2,"0")+":"+g(i,2,"0")},m:function e(t,r){if(t.date()e.replace(a,(e,t)=>t?t.toUpperCase():""),c=/\B([A-Z])/g,l=e=>e.replace(c,"-$1").toLowerCase();function u(e,t,r){e[t]=[].concat(e[t]||[]),e[t].unshift(r)}function p(e,t){if(e){(e.$options[t]||[]).forEach(t=>{t.call(e)})}}function d(e,t,{type:r}={}){if((e=>/function Boolean/.test(String(e)))(r))return"true"===e||"false"===e?"true"===e:""===e||e===t||null!=e||e;if((e=>/function Number/.test(String(e)))(r)){const t=parseFloat(e,10);return isNaN(t)?e:t}return e}function f(e,t){const r=[];for(let n=0,i=t.length;n(e[t]=c[r[n]],e),{}),u(t,"beforeCreate",(function(){const e=this.$emit;this.$emit=(t,...r)=>(this.$root.$options.customElement.dispatchEvent(function(e,t){return new CustomEvent(e,{bubbles:!1,cancelable:!1,detail:t})}(t,r)),e.call(this,t,...r))})),u(t,"created",(function(){i.forEach(e=>{this.$root.props[e]=this[e]})})),i.forEach(e=>{Object.defineProperty(m.prototype,e,{get(){return this._wrapper.props[e]},set(t){this._wrapper.props[e]=t},enumerable:!1,configurable:!0})}),a=!0}function h(e,t){const r=s(t),n=e.hasAttribute(t)?e.getAttribute(t):void 0;e._wrapper.props[r]=d(n,t,o[r])}class m extends HTMLElement{constructor(){const r=super();r.attachShadow({mode:"open"});const n=r._wrapper=new e({name:"shadow-root",customElement:r,shadowRoot:r.shadowRoot,data:()=>({props:{},slotChildren:[]}),render(e){return e(t,{ref:"inner",props:this.props},this.slotChildren)}});new MutationObserver(e=>{let t=!1;for(let n=0;n{e.props=function(e){const t={};return e.forEach(e=>{t[e]=void 0}),t}(i),n.forEach(e=>{h(this,e)})};a?r():t().then(e=>{(e.__esModule||"Module"===e[Symbol.toStringTag])&&(e=e.default),c(e),r()}),e.slotChildren=Object.freeze(f(e.$createElement,this.childNodes)),e.$mount(),this.shadowRoot.appendChild(e.$el)}}disconnectedCallback(){p(this.vueComponent,"deactivated")}}return r||c(t),m};function v(e,t,r,n,i,o,a,s){var c,l="function"==typeof e?e.options:e;if(t&&(l.render=t,l.staticRenderFns=r,l._compiled=!0),n&&(l.functional=!0),o&&(l._scopeId="data-v-"+o),a?(c=function(e){(e=e||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext)||"undefined"==typeof __VUE_SSR_CONTEXT__||(e=__VUE_SSR_CONTEXT__),i&&i.call(this,e),e&&e._registeredComponents&&e._registeredComponents.add(a)},l._ssrRegister=c):i&&(c=s?function(){i.call(this,(l.functional?this.parent:this).$root.$options.shadowRoot)}:i),c)if(l.functional){l._injectStyles=c;var u=l.render;l.render=function(e,t){return c.call(t),u(e,t)}}else{var p=l.beforeCreate;l.beforeCreate=p?[].concat(p,c):[c]}return{exports:e,options:l}}r("24fb"),r("35d6");var b=r("2f62"),y=["compactDisplay","currency","currencyDisplay","currencySign","localeMatcher","notation","numberingSystem","signDisplay","style","unit","unitDisplay","useGrouping","minimumIntegerDigits","minimumFractionDigits","maximumFractionDigits","minimumSignificantDigits","maximumSignificantDigits"];function w(e,t){"undefined"!=typeof console&&(console.warn("[vue-i18n] "+e),t&&console.warn(t.stack))}var x=Array.isArray;function _(e){return null!==e&&"object"==typeof e}function E(e){return"boolean"==typeof e}function S(e){return"string"==typeof e}var k=Object.prototype.toString;function O(e){return"[object Object]"===k.call(e)}function T(e){return null==e}function I(e){return"function"==typeof e}function A(){for(var e=[],t=arguments.length;t--;)e[t]=arguments[t];var r=null,n=null;return 1===e.length?_(e[0])||x(e[0])?n=e[0]:"string"==typeof e[0]&&(r=e[0]):2===e.length&&("string"==typeof e[0]&&(r=e[0]),(_(e[1])||x(e[1]))&&(n=e[1])),{locale:r,params:n}}function R(e){return JSON.parse(JSON.stringify(e))}function C(e,t){return!!~e.indexOf(t)}var P=Object.prototype.hasOwnProperty;function N(e,t){return P.call(e,t)}function M(e){for(var t=arguments,r=Object(e),n=1;n/g,">").replace(/"/g,""").replace(/'/g,"'")}(e[t]))})),e}var L={name:"i18n",functional:!0,props:{tag:{type:[String,Boolean,Object],default:"span"},path:{type:String,required:!0},locale:{type:String},places:{type:[Array,Object]}},render:function(e,t){var r=t.data,n=t.parent,i=t.props,o=t.slots,a=n.$i18n;if(a){var s=i.path,c=i.locale,l=i.places,u=o(),p=a.i(s,c,function(e){var t;for(t in e)if("default"!==t)return!1;return Boolean(t)}(u)||l?function(e,t){var r=t?function(e){return Array.isArray(e)?e.reduce(F,{}):Object.assign({},e)}(t):{};if(!e)return r;var n=(e=e.filter((function(e){return e.tag||""!==e.text.trim()}))).every($);return e.reduce(n?j:F,r)}(u.default,l):u),d=i.tag&&!0!==i.tag||!1===i.tag?i.tag:"span";return d?e(d,r,p):p}}};function j(e,t){return t.data&&t.data.attrs&&t.data.attrs.place&&(e[t.data.attrs.place]=t),e}function F(e,t,r){return e[r]=t,e}function $(e){return Boolean(e.data&&e.data.attrs&&e.data.attrs.place)}var V,G={name:"i18n-n",functional:!0,props:{tag:{type:[String,Boolean,Object],default:"span"},value:{type:Number,required:!0},format:{type:[String,Object]},locale:{type:String}},render:function(e,t){var r=t.props,n=t.parent,i=t.data,o=n.$i18n;if(!o)return null;var a=null,s=null;S(r.format)?a=r.format:_(r.format)&&(r.format.key&&(a=r.format.key),s=Object.keys(r.format).reduce((function(e,t){var n;return C(y,t)?Object.assign({},e,((n={})[t]=r.format[t],n)):e}),null));var c=r.locale||o.locale,l=o._ntp(r.value,c,a,s),u=l.map((function(e,t){var r,n=i.scopedSlots&&i.scopedSlots[e.type];return n?n(((r={})[e.type]=e.value,r.index=t,r.parts=l,r)):e.value})),p=r.tag&&!0!==r.tag||!1===r.tag?r.tag:"span";return p?e(p,{attrs:i.attrs,class:i.class,staticClass:i.staticClass},u):u}};function z(e,t,r){H(e,r)&&Y(e,t,r)}function B(e,t,r,n){if(H(e,r)){var i=r.context.$i18n;(function(e,t){var r=t.context;return e._locale===r.$i18n.locale})(e,r)&&D(t.value,t.oldValue)&&D(e._localeMessage,i.getLocaleMessage(i.locale))||Y(e,t,r)}}function W(e,t,r,n){if(r.context){var i=r.context.$i18n||{};t.modifiers.preserve||i.preserveDirectiveContent||(e.textContent=""),e._vt=void 0,delete e._vt,e._locale=void 0,delete e._locale,e._localeMessage=void 0,delete e._localeMessage}else w("Vue instance does not exists in VNode context")}function H(e,t){var r=t.context;return r?!!r.$i18n||(w("VueI18n instance does not exists in Vue instance"),!1):(w("Vue instance does not exists in VNode context"),!1)}function Y(e,t,r){var n,i,o=function(e){var t,r,n,i;return S(e)?t=e:O(e)&&(t=e.path,r=e.locale,n=e.args,i=e.choice),{path:t,locale:r,args:n,choice:i}}(t.value),a=o.path,s=o.locale,c=o.args,l=o.choice;if(a||s||c)if(a){var u=r.context;e._vt=e.textContent=null!=l?(n=u.$i18n).tc.apply(n,[a,l].concat(q(s,c))):(i=u.$i18n).t.apply(i,[a].concat(q(s,c))),e._locale=u.$i18n.locale,e._localeMessage=u.$i18n.getLocaleMessage(u.$i18n.locale)}else w("`path` is required in v-t directive");else w("value type not supported")}function q(e,t){var r=[];return e&&r.push(e),t&&(Array.isArray(t)||O(t))&&r.push(t),r}function Q(e,t){void 0===t&&(t={bridge:!1}),Q.installed=!0,(V=e).version&&Number(V.version.split(".")[0]),function(e){e.prototype.hasOwnProperty("$i18n")||Object.defineProperty(e.prototype,"$i18n",{get:function(){return this._i18n}}),e.prototype.$t=function(e){for(var t=[],r=arguments.length-1;r-- >0;)t[r]=arguments[r+1];var n=this.$i18n;return n._t.apply(n,[e,n.locale,n._getMessages(),this].concat(t))},e.prototype.$tc=function(e,t){for(var r=[],n=arguments.length-2;n-- >0;)r[n]=arguments[n+2];var i=this.$i18n;return i._tc.apply(i,[e,i.locale,i._getMessages(),this,t].concat(r))},e.prototype.$te=function(e,t){var r=this.$i18n;return r._te(e,r.locale,r._getMessages(),t)},e.prototype.$d=function(e){for(var t,r=[],n=arguments.length-1;n-- >0;)r[n]=arguments[n+1];return(t=this.$i18n).d.apply(t,[e].concat(r))},e.prototype.$n=function(e){for(var t,r=[],n=arguments.length-1;n-- >0;)r[n]=arguments[n+1];return(t=this.$i18n).n.apply(t,[e].concat(r))}}(V),V.mixin(function(e){function t(){this!==this.$root&&this.$options.__INTLIFY_META__&&this.$el&&this.$el.setAttribute("data-intlify",this.$options.__INTLIFY_META__)}return void 0===e&&(e=!1),e?{mounted:t}:{beforeCreate:function(){var e=this.$options;if(e.i18n=e.i18n||(e.__i18n?{}:null),e.i18n){if(e.i18n instanceof pe){if(e.__i18n)try{var t=e.i18n&&e.i18n.messages?e.i18n.messages:{};e.__i18n.forEach((function(e){t=M(t,JSON.parse(e))})),Object.keys(t).forEach((function(r){e.i18n.mergeLocaleMessage(r,t[r])}))}catch(e){}this._i18n=e.i18n,this._i18nWatcher=this._i18n.watchI18nData()}else if(O(e.i18n)){var r=this.$root&&this.$root.$i18n&&this.$root.$i18n instanceof pe?this.$root.$i18n:null;if(r&&(e.i18n.root=this.$root,e.i18n.formatter=r.formatter,e.i18n.fallbackLocale=r.fallbackLocale,e.i18n.formatFallbackMessages=r.formatFallbackMessages,e.i18n.silentTranslationWarn=r.silentTranslationWarn,e.i18n.silentFallbackWarn=r.silentFallbackWarn,e.i18n.pluralizationRules=r.pluralizationRules,e.i18n.preserveDirectiveContent=r.preserveDirectiveContent),e.__i18n)try{var n=e.i18n&&e.i18n.messages?e.i18n.messages:{};e.__i18n.forEach((function(e){n=M(n,JSON.parse(e))})),e.i18n.messages=n}catch(e){}var i=e.i18n.sharedMessages;i&&O(i)&&(e.i18n.messages=M(e.i18n.messages,i)),this._i18n=new pe(e.i18n),this._i18nWatcher=this._i18n.watchI18nData(),(void 0===e.i18n.sync||e.i18n.sync)&&(this._localeWatcher=this.$i18n.watchLocale()),r&&r.onComponentInstanceCreated(this._i18n)}}else this.$root&&this.$root.$i18n&&this.$root.$i18n instanceof pe?this._i18n=this.$root.$i18n:e.parent&&e.parent.$i18n&&e.parent.$i18n instanceof pe&&(this._i18n=e.parent.$i18n)},beforeMount:function(){var e=this.$options;e.i18n=e.i18n||(e.__i18n?{}:null),e.i18n?(e.i18n instanceof pe||O(e.i18n))&&(this._i18n.subscribeDataChanging(this),this._subscribing=!0):(this.$root&&this.$root.$i18n&&this.$root.$i18n instanceof pe||e.parent&&e.parent.$i18n&&e.parent.$i18n instanceof pe)&&(this._i18n.subscribeDataChanging(this),this._subscribing=!0)},mounted:t,beforeDestroy:function(){if(this._i18n){var e=this;this.$nextTick((function(){e._subscribing&&(e._i18n.unsubscribeDataChanging(e),delete e._subscribing),e._i18nWatcher&&(e._i18nWatcher(),e._i18n.destroyVM(),delete e._i18nWatcher),e._localeWatcher&&(e._localeWatcher(),delete e._localeWatcher)}))}}}}(t.bridge)),V.directive("t",{bind:z,update:B,unbind:W}),V.component(L.name,L),V.component(G.name,G),V.config.optionMergeStrategies.i18n=function(e,t){return void 0===t?e:t}}var K=function(){this._caches=Object.create(null)};K.prototype.interpolate=function(e,t){if(!t)return[e];var r=this._caches[e];return r||(r=function(e){var t=[],r=0,n="";for(;r0)p--,u=4,d[0]();else{if(p=0,void 0===r)return!1;if(!1===(r=re(r)))return!1;d[1]()}};null!==u;)if(l++,"\\"!==(t=e[l])||!f()){if(i=te(t),8===(o=(s=Z[u])[i]||s.else||8))return;if(u=o[0],(a=d[o[1]])&&(n=void 0===(n=o[2])?t:n,!1===a()))return;if(7===u)return c}}(e))&&(this._cache[e]=t),t||[]},ne.prototype.getPathValue=function(e,t){if(!_(e))return null;var r=this.parsePath(t);if(0===r.length)return null;for(var n=r.length,i=e,o=0;o/,ae=/(?:@(?:\.[a-z]+)?:(?:[\w\-_|./]+|\([\w\-_|./]+\)))/g,se=/^@(?:\.([a-z]+))?:/,ce=/[()]/g,le={upper:function(e){return e.toLocaleUpperCase()},lower:function(e){return e.toLocaleLowerCase()},capitalize:function(e){return""+e.charAt(0).toLocaleUpperCase()+e.substr(1)}},ue=new K,pe=function(e){var t=this;void 0===e&&(e={}),!V&&"undefined"!=typeof window&&window.Vue&&Q(window.Vue);var r=e.locale||"en-US",n=!1!==e.fallbackLocale&&(e.fallbackLocale||"en-US"),i=e.messages||{},o=e.dateTimeFormats||e.datetimeFormats||{},a=e.numberFormats||{};this._vm=null,this._formatter=e.formatter||ue,this._modifiers=e.modifiers||{},this._missing=e.missing||null,this._root=e.root||null,this._sync=void 0===e.sync||!!e.sync,this._fallbackRoot=void 0===e.fallbackRoot||!!e.fallbackRoot,this._formatFallbackMessages=void 0!==e.formatFallbackMessages&&!!e.formatFallbackMessages,this._silentTranslationWarn=void 0!==e.silentTranslationWarn&&e.silentTranslationWarn,this._silentFallbackWarn=void 0!==e.silentFallbackWarn&&!!e.silentFallbackWarn,this._dateTimeFormatters={},this._numberFormatters={},this._path=new ne,this._dataListeners=new Set,this._componentInstanceCreatedListener=e.componentInstanceCreatedListener||null,this._preserveDirectiveContent=void 0!==e.preserveDirectiveContent&&!!e.preserveDirectiveContent,this.pluralizationRules=e.pluralizationRules||{},this._warnHtmlInMessage=e.warnHtmlInMessage||"off",this._postTranslation=e.postTranslation||null,this._escapeParameterHtml=e.escapeParameterHtml||!1,this.getChoiceIndex=function(e,r){var n=Object.getPrototypeOf(t);if(n&&n.getChoiceIndex)return n.getChoiceIndex.call(t,e,r);return t.locale in t.pluralizationRules?t.pluralizationRules[t.locale].apply(t,[e,r]):function(e,t){return e=Math.abs(e),2===t?e?e>1?1:0:1:e?Math.min(e,2):0}(e,r)},this._exist=function(e,r){return!(!e||!r||T(t._path.getPathValue(e,r))&&!e[r])},"warn"!==this._warnHtmlInMessage&&"error"!==this._warnHtmlInMessage||Object.keys(i).forEach((function(e){t._checkLocaleMessage(e,t._warnHtmlInMessage,i[e])})),this._initVM({locale:r,fallbackLocale:n,messages:i,dateTimeFormats:o,numberFormats:a})},de={vm:{configurable:!0},messages:{configurable:!0},dateTimeFormats:{configurable:!0},numberFormats:{configurable:!0},availableLocales:{configurable:!0},locale:{configurable:!0},fallbackLocale:{configurable:!0},formatFallbackMessages:{configurable:!0},missing:{configurable:!0},formatter:{configurable:!0},silentTranslationWarn:{configurable:!0},silentFallbackWarn:{configurable:!0},preserveDirectiveContent:{configurable:!0},warnHtmlInMessage:{configurable:!0},postTranslation:{configurable:!0},sync:{configurable:!0}};pe.prototype._checkLocaleMessage=function(e,t,r){var n=function(e,t,r,i){if(O(r))Object.keys(r).forEach((function(o){var a=r[o];O(a)?(i.push(o),i.push("."),n(e,t,a,i),i.pop(),i.pop()):(i.push(o),n(e,t,a,i),i.pop())}));else if(x(r))r.forEach((function(r,o){O(r)?(i.push("["+o+"]"),i.push("."),n(e,t,r,i),i.pop(),i.pop()):(i.push("["+o+"]"),n(e,t,r,i),i.pop())}));else if(S(r)){if(oe.test(r)){var o="Detected HTML in message '"+r+"' of keypath '"+i.join("")+"' at '"+t+"'. Consider component interpolation with '' to avoid XSS. See https://bit.ly/2ZqJzkp";"warn"===e?w(o):"error"===e&&function(e,t){"undefined"!=typeof console&&(console.error("[vue-i18n] "+e),t&&console.error(t.stack))}(o)}}};n(t,e,r,[])},pe.prototype._initVM=function(e){var t=V.config.silent;V.config.silent=!0,this._vm=new V({data:e,__VUE18N__INSTANCE__:!0}),V.config.silent=t},pe.prototype.destroyVM=function(){this._vm.$destroy()},pe.prototype.subscribeDataChanging=function(e){this._dataListeners.add(e)},pe.prototype.unsubscribeDataChanging=function(e){!function(e,t){if(e.delete(t));}(this._dataListeners,e)},pe.prototype.watchI18nData=function(){var e=this;return this._vm.$watch("$data",(function(){for(var t=function(e){var t=[];return e.forEach((function(e){return t.push(e)})),t}(e._dataListeners),r=t.length;r--;)V.nextTick((function(){t[r]&&t[r].$forceUpdate()}))}),{deep:!0})},pe.prototype.watchLocale=function(){if(!this._sync||!this._root)return null;var e=this._vm;return this._root.$i18n.vm.$watch("locale",(function(t){e.$set(e,"locale",t),e.$forceUpdate()}),{immediate:!0})},pe.prototype.onComponentInstanceCreated=function(e){this._componentInstanceCreatedListener&&this._componentInstanceCreatedListener(e,this)},de.vm.get=function(){return this._vm},de.messages.get=function(){return R(this._getMessages())},de.dateTimeFormats.get=function(){return R(this._getDateTimeFormats())},de.numberFormats.get=function(){return R(this._getNumberFormats())},de.availableLocales.get=function(){return Object.keys(this.messages).sort()},de.locale.get=function(){return this._vm.locale},de.locale.set=function(e){this._vm.$set(this._vm,"locale",e)},de.fallbackLocale.get=function(){return this._vm.fallbackLocale},de.fallbackLocale.set=function(e){this._localeChainCache={},this._vm.$set(this._vm,"fallbackLocale",e)},de.formatFallbackMessages.get=function(){return this._formatFallbackMessages},de.formatFallbackMessages.set=function(e){this._formatFallbackMessages=e},de.missing.get=function(){return this._missing},de.missing.set=function(e){this._missing=e},de.formatter.get=function(){return this._formatter},de.formatter.set=function(e){this._formatter=e},de.silentTranslationWarn.get=function(){return this._silentTranslationWarn},de.silentTranslationWarn.set=function(e){this._silentTranslationWarn=e},de.silentFallbackWarn.get=function(){return this._silentFallbackWarn},de.silentFallbackWarn.set=function(e){this._silentFallbackWarn=e},de.preserveDirectiveContent.get=function(){return this._preserveDirectiveContent},de.preserveDirectiveContent.set=function(e){this._preserveDirectiveContent=e},de.warnHtmlInMessage.get=function(){return this._warnHtmlInMessage},de.warnHtmlInMessage.set=function(e){var t=this,r=this._warnHtmlInMessage;if(this._warnHtmlInMessage=e,r!==e&&("warn"===e||"error"===e)){var n=this._getMessages();Object.keys(n).forEach((function(e){t._checkLocaleMessage(e,t._warnHtmlInMessage,n[e])}))}},de.postTranslation.get=function(){return this._postTranslation},de.postTranslation.set=function(e){this._postTranslation=e},de.sync.get=function(){return this._sync},de.sync.set=function(e){this._sync=e},pe.prototype._getMessages=function(){return this._vm.messages},pe.prototype._getDateTimeFormats=function(){return this._vm.dateTimeFormats},pe.prototype._getNumberFormats=function(){return this._vm.numberFormats},pe.prototype._warnDefault=function(e,t,r,n,i,o){if(!T(r))return r;if(this._missing){var a=this._missing.apply(null,[e,t,n,i]);if(S(a))return a}if(this._formatFallbackMessages){var s=A.apply(void 0,i);return this._render(t,o,s.params,t)}return t},pe.prototype._isFallbackRoot=function(e){return!e&&!T(this._root)&&this._fallbackRoot},pe.prototype._isSilentFallbackWarn=function(e){return this._silentFallbackWarn instanceof RegExp?this._silentFallbackWarn.test(e):this._silentFallbackWarn},pe.prototype._isSilentFallback=function(e,t){return this._isSilentFallbackWarn(t)&&(this._isFallbackRoot()||e!==this.fallbackLocale)},pe.prototype._isSilentTranslationWarn=function(e){return this._silentTranslationWarn instanceof RegExp?this._silentTranslationWarn.test(e):this._silentTranslationWarn},pe.prototype._interpolate=function(e,t,r,n,i,o,a){if(!t)return null;var s,c=this._path.getPathValue(t,r);if(x(c)||O(c))return c;if(T(c)){if(!O(t))return null;if(!S(s=t[r])&&!I(s))return null}else{if(!S(c)&&!I(c))return null;s=c}return S(s)&&(s.indexOf("@:")>=0||s.indexOf("@.")>=0)&&(s=this._link(e,t,s,n,"raw",o,a)),this._render(s,i,o,r)},pe.prototype._link=function(e,t,r,n,i,o,a){var s=r,c=s.match(ae);for(var l in c)if(c.hasOwnProperty(l)){var u=c[l],p=u.match(se),d=p[0],f=p[1],h=u.replace(d,"").replace(ce,"");if(C(a,h))return s;a.push(h);var m=this._interpolate(e,t,h,n,"raw"===i?"string":i,"raw"===i?void 0:o,a);if(this._isFallbackRoot(m)){if(!this._root)throw Error("unexpected error");var g=this._root.$i18n;m=g._translate(g._getMessages(),g.locale,g.fallbackLocale,h,n,i,o)}m=this._warnDefault(e,h,m,n,x(o)?o:[o],i),this._modifiers.hasOwnProperty(f)?m=this._modifiers[f](m):le.hasOwnProperty(f)&&(m=le[f](m)),a.pop(),s=m?s.replace(u,m):s}return s},pe.prototype._createMessageContext=function(e,t,r,n){var i=this,o=x(e)?e:[],a=_(e)?e:{},s=this._getMessages(),c=this.locale;return{list:function(e){return o[e]},named:function(e){return a[e]},values:e,formatter:t,path:r,messages:s,locale:c,linked:function(e){return i._interpolate(c,s[c]||{},e,null,n,void 0,[e])}}},pe.prototype._render=function(e,t,r,n){if(I(e))return e(this._createMessageContext(r,this._formatter||ue,n,t));var i=this._formatter.interpolate(e,r,n);return i||(i=ue.interpolate(e,r,n)),"string"!==t||S(i)?i:i.join("")},pe.prototype._appendItemToChain=function(e,t,r){var n=!1;return C(e,t)||(n=!0,t&&(n="!"!==t[t.length-1],t=t.replace(/!/g,""),e.push(t),r&&r[t]&&(n=r[t]))),n},pe.prototype._appendLocaleToChain=function(e,t,r){var n,i=t.split("-");do{var o=i.join("-");n=this._appendItemToChain(e,o,r),i.splice(-1,1)}while(i.length&&!0===n);return n},pe.prototype._appendBlockToChain=function(e,t,r){for(var n=!0,i=0;i0;)o[a]=arguments[a+4];if(!e)return"";var s=A.apply(void 0,o);this._escapeParameterHtml&&(s.params=U(s.params));var c=s.locale||t,l=this._translate(r,c,this.fallbackLocale,e,n,"string",s.params);if(this._isFallbackRoot(l)){if(!this._root)throw Error("unexpected error");return(i=this._root).$t.apply(i,[e].concat(o))}return l=this._warnDefault(c,e,l,n,o,"string"),this._postTranslation&&null!=l&&(l=this._postTranslation(l,e)),l},pe.prototype.t=function(e){for(var t,r=[],n=arguments.length-1;n-- >0;)r[n]=arguments[n+1];return(t=this)._t.apply(t,[e,this.locale,this._getMessages(),null].concat(r))},pe.prototype._i=function(e,t,r,n,i){var o=this._translate(r,t,this.fallbackLocale,e,n,"raw",i);if(this._isFallbackRoot(o)){if(!this._root)throw Error("unexpected error");return this._root.$i18n.i(e,t,i)}return this._warnDefault(t,e,o,n,[i],"raw")},pe.prototype.i=function(e,t,r){return e?(S(t)||(t=this.locale),this._i(e,t,this._getMessages(),null,r)):""},pe.prototype._tc=function(e,t,r,n,i){for(var o,a=[],s=arguments.length-5;s-- >0;)a[s]=arguments[s+5];if(!e)return"";void 0===i&&(i=1);var c={count:i,n:i},l=A.apply(void 0,a);return l.params=Object.assign(c,l.params),a=null===l.locale?[l.params]:[l.locale,l.params],this.fetchChoice((o=this)._t.apply(o,[e,t,r,n].concat(a)),i)},pe.prototype.fetchChoice=function(e,t){if(!e||!S(e))return null;var r=e.split("|");return r[t=this.getChoiceIndex(t,r.length)]?r[t].trim():e},pe.prototype.tc=function(e,t){for(var r,n=[],i=arguments.length-2;i-- >0;)n[i]=arguments[i+2];return(r=this)._tc.apply(r,[e,this.locale,this._getMessages(),null,t].concat(n))},pe.prototype._te=function(e,t,r){for(var n=[],i=arguments.length-3;i-- >0;)n[i]=arguments[i+3];var o=A.apply(void 0,n).locale||t;return this._exist(r[o],e)},pe.prototype.te=function(e,t){return this._te(e,this.locale,this._getMessages(),t)},pe.prototype.getLocaleMessage=function(e){return R(this._vm.messages[e]||{})},pe.prototype.setLocaleMessage=function(e,t){"warn"!==this._warnHtmlInMessage&&"error"!==this._warnHtmlInMessage||this._checkLocaleMessage(e,this._warnHtmlInMessage,t),this._vm.$set(this._vm.messages,e,t)},pe.prototype.mergeLocaleMessage=function(e,t){"warn"!==this._warnHtmlInMessage&&"error"!==this._warnHtmlInMessage||this._checkLocaleMessage(e,this._warnHtmlInMessage,t),this._vm.$set(this._vm.messages,e,M(void 0!==this._vm.messages[e]&&Object.keys(this._vm.messages[e]).length?Object.assign({},this._vm.messages[e]):{},t))},pe.prototype.getDateTimeFormat=function(e){return R(this._vm.dateTimeFormats[e]||{})},pe.prototype.setDateTimeFormat=function(e,t){this._vm.$set(this._vm.dateTimeFormats,e,t),this._clearDateTimeFormat(e,t)},pe.prototype.mergeDateTimeFormat=function(e,t){this._vm.$set(this._vm.dateTimeFormats,e,M(this._vm.dateTimeFormats[e]||{},t)),this._clearDateTimeFormat(e,t)},pe.prototype._clearDateTimeFormat=function(e,t){for(var r in t){var n=e+"__"+r;this._dateTimeFormatters.hasOwnProperty(n)&&delete this._dateTimeFormatters[n]}},pe.prototype._localizeDateTime=function(e,t,r,n,i){for(var o=t,a=n[o],s=this._getLocaleChain(t,r),c=0;c0;)t[r]=arguments[r+1];var n=this.locale,i=null;return 1===t.length?S(t[0])?i=t[0]:_(t[0])&&(t[0].locale&&(n=t[0].locale),t[0].key&&(i=t[0].key)):2===t.length&&(S(t[0])&&(i=t[0]),S(t[1])&&(n=t[1])),this._d(e,n,i)},pe.prototype.getNumberFormat=function(e){return R(this._vm.numberFormats[e]||{})},pe.prototype.setNumberFormat=function(e,t){this._vm.$set(this._vm.numberFormats,e,t),this._clearNumberFormat(e,t)},pe.prototype.mergeNumberFormat=function(e,t){this._vm.$set(this._vm.numberFormats,e,M(this._vm.numberFormats[e]||{},t)),this._clearNumberFormat(e,t)},pe.prototype._clearNumberFormat=function(e,t){for(var r in t){var n=e+"__"+r;this._numberFormatters.hasOwnProperty(n)&&delete this._numberFormatters[n]}},pe.prototype._getNumberFormatter=function(e,t,r,n,i,o){for(var a=t,s=n[a],c=this._getLocaleChain(t,r),l=0;l0;)t[r]=arguments[r+1];var n=this.locale,i=null,o=null;return 1===t.length?S(t[0])?i=t[0]:_(t[0])&&(t[0].locale&&(n=t[0].locale),t[0].key&&(i=t[0].key),o=Object.keys(t[0]).reduce((function(e,r){var n;return C(y,r)?Object.assign({},e,((n={})[r]=t[0][r],n)):e}),null)):2===t.length&&(S(t[0])&&(i=t[0]),S(t[1])&&(n=t[1])),this._n(e,n,i,o)},pe.prototype._ntp=function(e,t,r,n){if(!pe.availabilities.numberFormat)return[];if(!r)return(n?new Intl.NumberFormat(t,n):new Intl.NumberFormat(t)).formatToParts(e);var i=this._getNumberFormatter(e,t,this.fallbackLocale,this._getNumberFormats(),r,n),o=i&&i.formatToParts(e);if(this._isFallbackRoot(o)){if(!this._root)throw Error("unexpected error");return this._root.$i18n._ntp(e,t,r,n)}return o||[]},Object.defineProperties(pe.prototype,de),Object.defineProperty(pe,"availabilities",{get:function(){if(!ie){var e="undefined"!=typeof Intl;ie={dateTimeFormat:e&&void 0!==Intl.DateTimeFormat,numberFormat:e&&void 0!==Intl.NumberFormat}}return ie}}),pe.install=Q,pe.version="8.26.1";var fe=pe;o.default.use(fe);var he=new fe({locale:"en_US",fallbackLocale:"en_US",messages:function(){const e=r("4b3b"),t={};return e.keys().forEach(r=>{const n=r.match(/([A-Za-z0-9-_]+)\./i);if(n&&n.length>1){const i=n[1];t[i]=e(r)}}),t}()});const me="production",ge="https://registration.unraid.net",ve="https://unraid.net/preflight",be=ve.replace("preflight","upc/start-trial"),ye=Object({VUE_APP_REGWIZ_URL:"https://registration.unraid.net",VUE_APP_PURCHASE_URL:"https://unraid.net/preflight",VUE_APP_MIN_API_VER:"2.49.2",VUE_APP_REC_API_VER:"2.52.1",VUE_APP_MIN_OS_VER:"6.10.0",VUE_APP_REC_OS_VER:"6.11.0",NODE_ENV:"production",BASE_URL:"/"}).VUE_APP_DEV_GRAPH_URL||null,we=(Object({VUE_APP_REGWIZ_URL:"https://registration.unraid.net",VUE_APP_PURCHASE_URL:"https://unraid.net/preflight",VUE_APP_MIN_API_VER:"2.49.2",VUE_APP_REC_API_VER:"2.52.1",VUE_APP_MIN_OS_VER:"6.10.0",VUE_APP_REC_OS_VER:"6.11.0",NODE_ENV:"production",BASE_URL:"/"}).VUE_APP_DEV_APIKEY,"2.49.2"),xe=navigator.userAgent.toLowerCase(),_e={url:ge,name:"UnraidRegistrationWizard",width:600,height:810},Ee={errorMessage:"",errorMessageSubtext:"",loading:!0,submissionFrom:null,darkMode:window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches,darkTheme:{alpha:"#1c1b1b",beta:"#f2f2f2",gamma:"#999999"},lightTheme:{alpha:"#f2f2f2",beta:"#1c1b1b",gamma:"#999999"},csrf:null,postMessageError:null,isLaunchpadOpen:!1,isPromoOpen:!1,triggerUPC:!1,ts:null,deviceCount:0,flashproduct:null,flashvendor:null,guid:"",regGuid:"",keyfile:null,servername:null,serverdesc:null,wanip:sessionStorage.getItem("upc_wanip")||null,site:null,wanFQDN:null,state:"",reggen:0,registered:null,internalip:null,internalport:null,protocol:null,license:"",expiretime:null,regWizTime:null,rawServerState:null,plgPath:null,guidRegistered:!1,guidValid:null,guidValidationRunning:!1,replaceable:null,guidForValidation:null,guidBlacklisted:null,id:null,isPopUpOpen:!1,popUpWindow:"",regAtOpen:null,forumaccount:null,userEmail:"",username:"",avatar:"",userPassword:"",apikey:"",ipsValidated:!1,accountAction:null,keyServerAction:"",licenseAction:null,receivedSuccessNewServerState:null,purchaseWindow:{url:new URL(ve),name:"UnraidPurchaseLicense",width:1198,height:900,sendSessionToPopUp:!0},redeemWindow:{url:new URL(ve+"?r=1"),name:"UnraidPurchaseLicense",width:1198,height:900,sendSessionToPopUp:!0},trialWindow:{url:new URL(be),name:"UnraidStartTrial",width:400,height:400,sendSessionToPopUp:!0},wizardWindow:_e,signInPayload:{..._e,url:_e.url+"/#/sign-in"},signUpPayload:{..._e,url:_e.url+"/#/sign-up"},signOutPayload:{..._e,url:_e.url+"/#/sign-out",width:600,height:500},extendTrialPayload:{..._e,url:_e.url+"/#/extend-trial"},recoverKeyPayload:{..._e,url:_e.url+"/#/recover-key"},replaceKeyPayload:{..._e,url:_e.url+"/#/replace-key"},troubleshootPayload:{..._e,url:_e.url+"/#/troubleshoot"},locale:"en_US",messages:null,graphOnline:!1,graphReconnected:!1,myServers:[],myServersLoading:!1,myServersError:null,myServersErrorShowSupportBtn:!1,myServersEnv:null,apiVersion:"0.0.0",cloud:null,hideMyServers:!1,osVersion:null,plgVersion:null,plgInstalled:null,hasRemoteApikey:null,config:null,hasUnraidNetSSL:!1,flashBackupActivated:!1,extraOrigins:[],myServersOutOfDate:{enabled:!0,error:!1,heading:"My Servers Update Available",message:"Please update to the latest version of the My Servers plugin",link:"/Plugins",linkSameTab:!0,linkText:"Learn More"},devEnv:!1,signOutTriggered:!1,apiReport:null,osGui:xe.includes("linux")&&xe.includes("firefox"),pirateKey:sessionStorage.getItem("upc_yargMatey")||!1};var Se=r("2426"),ke=r.n(Se),Oe=r("61bb"),Te=r.n(Oe);const Ie="GUID_NOT_RECEIVED",Ae=!(!window.opener||window.opener===window),Re=Ae?window.opener.parent:window.parent,Ce=[ve,ge,"https://launchpad.unraid.test:8081","https://launchpad.unraid.test:6969","https://registration.unraid.net","https://registration-dev.unraid.net","https://registration-dev-logs.unraid.net","https://unraid.net","https://staging.unraid.net","https://craft.unraid.test"],Pe='API error unexpected response for "owner".',Ne=e=>{try{return[null,JSON.parse(e)]}catch(e){return[e]}};var Me=r("329c"),De=r.n(Me);var Ue=(e,t,r)=>{if(De()(e,`>=${t} <${r}`,{includePrerelease:!1}))return!0;return!!De()(e,">="+r,{includePrerelease:!0})};const Le={actions:[],humanReadable:"",heading:"",message:"",messageCenter:!1,error:!1,withKey:!1},je={...Le,humanReadable:he.tc("stateData.ENOFLASH.humanReadable"),error:{heading:he.tc("stateData.ENOFLASH.error.heading"),message:he.tc("stateData.ENOFLASH.error.message"),signInToFix:!1}};let Fe="";const $e={statePhpPath:e=>`/plugins/${e.plgPath||"dynamix.unraid.net"}/include/state.php`,myServersCfgPath:e=>(e.plgPath||"Unraid.net")+"/myservers.cfg",requireGuidValidation:e=>!Ae||e.guidRegistered,validApiKeyLength:e=>64===e.apikey.length,validApiKeyForUpc:e=>!!e.apikey&&e.apikey.startsWith("unupc_"),hasRemoteApikey:e=>!0===e.hasRemoteApikey||!(!e.validApiKeyLength||!e.validApiKeyForUpc),showExpiretime:e=>("TRIAL"===e.state||"EEXPIRED"===e.state)&&e.expiretime>0,trialExtensionEligible:e=>!(e.reggen&&!(e.reggen<2)),signedOutWithKey:(e,t)=>!(!t.stateData.withKey||e.registered),stateData:(e,t)=>{switch(e.state){case"ENOKEYFILE":return{...Le,actions:[e.registered?"signOut":"register","startTrial","purchase","redeem"],humanReadable:he.tc("stateData.ENOKEYFILE.humanReadable"),heading:he.tc("stateData.ENOKEYFILE.heading"),message:he.tc("stateData.ENOKEYFILE.message")};case"TRIAL":return{...Le,actions:["purchase",e.registered?"signOut":"register",e.registered?"continueTrial":null],humanReadable:he.tc("stateData.TRIAL.humanReadable"),heading:he.tc("stateData.TRIAL.heading"),message:he.tc("stateData.TRIAL.message"),withKey:!0};case"EEXPIRED":return{...Le,actions:[e.registered?"signOut":"register",t.trialExtensionEligible?"extend":null,"purchase"],humanReadable:he.tc("stateData.EEXPIRED.humanReadable"),error:{heading:he.tc("stateData.EEXPIRED.heading"),message:t.trialExtensionEligible?he.tc("stateData.EEXPIRED.message.extensionEligible"):he.tc("stateData.EEXPIRED.message.extensionNotEligible")},withKey:!0};case"BASIC":return{...Le,actions:[e.registered?"signOut":"register","upgrade"],humanReadable:he.tc("stateData.BASIC.humanReadable"),heading:he.tc("basicPlusPro.heading"),message:e.registered?e.guidRegistered?he.tc("basicPlusPro.message.upgradeEligible"):"":he.tc("basicPlusPro.message.registered"),messageCenter:!e.registered,withKey:!0};case"PLUS":return{...Le,actions:[e.registered?"signOut":"register","upgrade"],humanReadable:he.tc("stateData.PLUS.humanReadable"),heading:he.tc("basicPlusPro.heading"),message:e.registered?e.guidRegistered?he.tc("basicPlusPro.message.upgradeEligible"):"":he.tc("basicPlusPro.message.registered"),messageCenter:!e.registered,withKey:!0};case"PRO":return{...Le,actions:[e.registered?"signOut":"register",e.registered?"close":null],humanReadable:he.tc("stateData.PRO.humanReadable"),heading:he.tc("basicPlusPro.heading"),message:e.registered?"":he.tc("basicPlusPro.message.registered"),messageCenter:!e.registered,withKey:!0};case"EGUID":return Fe=e.replaceable?he.tc("stateData.EGUID.error.message.replacementEligible"):!1===e.replaceable&&e.guidBlacklisted?`${he.tc("stateData.EGUID.error.message.default")}
${he.tc("stateData.EGUID.error.message.blacklisted")}`:!1!==e.replaceable||e.guidBlacklisted?he.tc("stateData.EGUID.error.message.replacementEligible"):`${he.tc("stateData.EGUID.error.message.default")}
${he.tc("stateData.EGUID.error.message.replacementIneligible")}`,{...Le,actions:["purchase","replace",e.registered?"signOut":"register"],humanReadable:he.tc("stateData.EGUID.humanReadable"),error:{heading:he.tc("stateData.EGUID.error.heading"),message:Fe,signInToFix:!0}};case"EGUID1":return{...Le,actions:["purchase",e.registered?"signOut":"register"],humanReadable:he.tc("stateData.EGUID1.humanReadable"),error:{heading:he.tc("stateData.EGUID1.error.heading"),message:he.tc("stateData.EGUID1.error.message"),signInToFix:!0}};case"ENOKEYFILE2":return{...Le,actions:["purchase",e.registered?"signOut":"register",e.registered?"recover":null],humanReadable:he.tc("stateData.ENOKEYFILE2.humanReadable"),error:{heading:he.tc("stateData.ENOKEYFILE2.error.heading"),message:he.tc("stateData.ENOKEYFILE2.error.message"),signInToFix:!0}};case"ETRIAL":return{...Le,actions:[e.registered?"signOut":"register","purchase"],humanReadable:he.tc("stateData.ETRIAL.humanReadable"),error:{heading:he.tc("stateData.ETRIAL.error.heading"),message:he.tc("stateData.ETRIAL.error.message"),signInToFix:!0}};case"ENOKEYFILE1":return{...Le,humanReadable:he.tc("stateData.ENOKEYFILE1.humanReadable"),error:{heading:he.tc("stateData.ENOKEYFILE1.error.heading"),message:he.tc("stateData.ENOKEYFILE1.error.message"),signInToFix:!1}};case"ENOFLASH":case"ENOFLASH1":case"ENOFLASH2":case"ENOFLASH3":case"ENOFLASH4":case"ENOFLASH5":case"ENOFLASH6":case"ENOFLASH7":return je;case"EBLACKLISTED":return{...Le,humanReadable:he.tc("stateData.EBLACKLISTED.humanReadable"),error:{heading:he.tc("stateData.EBLACKLISTED.error.heading"),message:he.tc("stateData.EBLACKLISTED.error.message"),signInToFix:!1}};case"EBLACKLISTED1":return{...Le,humanReadable:he.tc("stateData.EBLACKLISTED1.humanReadable"),error:{heading:he.tc("stateData.EBLACKLISTED1.error.heading"),message:he.tc("stateData.EBLACKLISTED1.error.message"),signInToFix:!1}};case"EBLACKLISTED2":return{...Le,humanReadable:he.tc("stateData.EBLACKLISTED2.humanReadable"),error:{heading:he.tc("stateData.EBLACKLISTED2.error.heading"),message:he.tc("stateData.EBLACKLISTED2.error.message"),signInToFix:!1}};case"ENOCONN":return{...Le,humanReadable:he.tc("stateData.ENOCONN.humanReadable"),error:{heading:he.tc("stateData.ENOCONN.error.heading"),message:he.tc("stateData.ENOCONN.error.message"),signInToFix:!1}};case"STALE":return{...Le,humanReadable:he.tc("stateData.STALE.humanReadable"),error:{heading:he.tc("stateData.STALE.error.heading"),message:he.tc("stateData.STALE.error.message"),signInToFix:!1}};default:return{...Le}}},stateDataKeyActions:(e,t)=>!!(t.stateData.actions.includes("purchase")||t.stateData.actions.includes("upgrade")||t.stateData.actions.includes("recover")||t.stateData.actions.includes("replace")||t.stateData.actions.includes("extend")),keyTypeForPurchase:e=>{switch(e.state){case"BASIC":return"Basic";case"PLUS":return"Plus";case"PRO":return"Pro";default:return"Trial"}},isRemoteAccess:e=>e.wanFQDN||e.site&&e.site.includes("www.")&&e.site.includes("unraid.net"),noRemoteApikeyRegisteredWithPlg:e=>!(!e.registered||e.hideMyServers||!e.validApiKeyLength||!e.validApiKeyForUpc),errorTooManyDisks:e=>!(!e.config||e.config.valid||"INVALID"!==e.config.error),allowedOrigins:e=>[...Ce,...e.extraOrigins],myServersNotMinApiVer:e=>!e.apiVersion||e.apiVersion&&ke()(e.apiVersion,we),myServersNotRecApiVer:e=>!e.apiVersion||e.apiVersion&&ke()(e.apiVersion,"2.52.1"),osPrerelease:e=>{if(e.osVersion){return Te()(e.osVersion).prerelease.length}return!1},osVersionValid:e=>e.osVersion&&Ue(e.osVersion,"6.10.0","6.11.0"),allowApiOutOfDate:(e,t)=>!t.plgInstallFailed&&e.apiVersion&&(t.myServersNotMinApiVer||t.myServersNotRecApiVer)&&!e.devMode&&!e.hideMyServers,myServersOutOfDate:(e,t)=>t.allowApiOutOfDate&&t.myServersNotMinApiVer?{...e.myServersOutOfDate,error:!0,message:"The My Servers plugin is out-of-date and will not connect to Unraid's cloud services. Please update the plugin.",linkText:"Update now"}:t.osVersionValid||t.osPrerelease?t.allowApiOutOfDate&&!t.myServersNotMinApiVer&&t.myServersNotRecApiVer?e.myServersOutOfDate:!t.osVersionValid&&t.osPrerelease?{enabled:!0,error:!1,heading:"Unraid OS Out-of-date",message:"RC releases are not meant to used long term, please update to a stable release of Unraid."+(e.plgInstalled&&!t.plgInstallFailed?" This version of Unraid will be blocked from My Servers in the future.":""),link:" https://forums.unraid.net/topic/128328-my-servers-dropping-support-for-older-versions-of-unraid/",linkSameTab:!1,linkText:he.tc("learnMore")}:{enabled:!1,error:!1}:{enabled:!0,error:!0,heading:"Unraid OS Out-of-date",message:"You are running an unsupported release of Unraid, please upgrade to the current version."+(e.plgInstalled&&!t.plgInstallFailed?" This version of Unraid will be blocked from My Servers in the future.":""),link:" https://forums.unraid.net/topic/128328-my-servers-dropping-support-for-older-versions-of-unraid/",linkSameTab:!1,linkText:he.tc("learnMore")},errorMessage:(e,t)=>!t.stateData.error&&e.myServersError&&e.myServersErrorShowSupportBtn?e.myServersError:!t.stateData.error&&e.cloud&&e.cloud.error&&e.myServersErrorShowSupportBtn?e.cloud.error:null,server:(e,t)=>({guid:e.guid||Ie,regGuid:e.regGuid,guidRegistered:e.guidRegistered||e.regWizTime,guidValid:e.guidValid,hasRemoteApikey:t.hasRemoteApikey,regWizTime:e.regWizTime,keyfile:e.keyfile,keyTypeForPurchase:t.keyTypeForPurchase,flashproduct:e.flashproduct,flashvendor:e.flashvendor,servername:e.servername,serverdesc:e.serverdesc,internalip:e.internalip,site:e.site,wanFQDN:e.wanFQDN,state:e.state,internalport:e.internalport,protocol:e.protocol,registered:e.registered,reggen:e.reggen,userEmail:e.userEmail,expiretime:e.expiretime,ts:e.ts,locale:e.locale,deviceCount:e.deviceCount,plgPath:e.plgPath,plgVersion:e.plgVersion,osVersion:e.osVersion,apiVersion:e.apiVersion,extraOrigins:e.extraOrigins,errorMessage:t.errorMessage,apiReport:e.apiReport,osGui:e.osGui,username:e.username,avatar:e.avatar,hideMyServers:e.hideMyServers,flashBackupActivated:e.flashBackupActivated}),features:e=>[{title:he.tc("regWizPopUp.routes.whatIsMyServers.features.secureRemoteAccess.heading"),copy:he.tc("regWizPopUp.routes.whatIsMyServers.features.secureRemoteAccess.copy"),svg:"ui--remote-access"},{title:he.tc("regWizPopUp.routes.whatIsMyServers.features.usbFlashBackup.heading"),copy:he.tc("regWizPopUp.routes.whatIsMyServers.features.usbFlashBackup.copy"),svg:"ui--usb"},{title:he.tc("regWizPopUp.routes.whatIsMyServers.features.realTimeMonitoring.heading"),copy:he.tc("regWizPopUp.routes.whatIsMyServers.features.realTimeMonitoring.copy"),svg:"ui--diagnostics"},{title:he.tc("regWizPopUp.routes.whatIsMyServers.features.regKeyManagement.heading"),copy:he.tc("regWizPopUp.routes.whatIsMyServers.features.regKeyManagement.copy"),svg:"ui--key"},{title:he.tc("regWizPopUp.routes.whatIsMyServers.features.plusMore.heading"),copy:he.tc("regWizPopUp.routes.whatIsMyServers.features.plusMore.copy"),svg:"util--star",center:!0}],plgInstallFailed:e=>e.plgInstalled&&e.plgInstalled.includes("_installFailed")};var Ve=r("786a"),Ge=r.n(Ve),ze=r("626e");const Be=((e,t)=>{void 0===t&&(t={keys:[],values:[]});const r=t.keys,n=void 0===r?[]:r,i=t.values,o=void 0===i?[]:i,a=(e,t)=>{const r=ze.key(e)||ze.value(t),i=n.some(t=>t.test(e))||o.some(e=>e.test(t));return r||i};return{map:t=>Ge.a.default(t).map(t=>!!a((void 0).key,t)&&(void 0).update(e)),forEach:t=>{Ge.a.default(t).forEach(t=>{a((void 0).key,t)&&(void 0).update(e)})}}})("[REDACTED]",{keys:["guid"],values:[]}),We={...Object.fromEntries(Object.entries(console).map(([e,t])=>{if("debug"===e)return[e,()=>{}];if("function"==typeof method){const r=t.bind(console);return[e,(e,...t)=>t.length>=1?r(e,...t.map(e=>Be.map(e))):r(e)]}return[e,t]}))},He={SET_APP_ERROR_MESSAGE(e,t){We.debug("[SET_APP_ERROR_MESSAGE]: initial %o",t);const[r,n]=Ne(t);n&&!r||!t||(We.debug("[SET_APP_ERROR_MESSAGE]: no json use original string %o",t),e.errorMessage=t),n||!1!==t&&""!==t||(We.debug("[SET_APP_ERROR_MESSAGE]: allow falsely values to reset the field %o",t),e.errorMessage=""),n&&n.error&&(We.debug("[SET_APP_ERROR_MESSAGE]: we got json %o",t),e.errorMessage=n.error),e.errorMessage&&We.error("[SET_APP_ERROR_MESSAGE]: %s",e.errorMessage)},SET_APP_ERROR_MESSAGE_SUBTEXT(e,t){We.debug("[SET_APP_ERROR_MESSAGE_SUBTEXT]: %o",t),e.errorMessageSubtext=t,e.errorMessageSubtext&&We.error("[SET_APP_ERROR_MESSAGE_SUBTEXT]: %s",e.errorMessageSubtext)},SET_LOADING_STATE(e,t){We.debug("[SET_LOADING_STATE]: %o",t),e.loading=t},SET_IS_LAUNCHPAD_OPEN(e,t){We.debug("[SET_IS_LAUNCHPAD_OPEN]: %o",t),t||sessionStorage.removeItem("clickedInstallMyServers"),e.isLaunchpadOpen=t},SET_IS_PROMO_OPEN(e,t){We.debug("[SET_IS_PROMO_OPEN]: %o",t),e.isPromoOpen=t},SET_STATE(e,t){We.debug("[SET_STATE]: %o",t),e.state=t},SET_CONFIG(e,t){We.debug("[SET_CONFIG]: %o",t),e.config=t},CHANGE_GUID_REGISTERED(e,t){We.debug("[CHANGE_GUID_REGISTERED]: %o",t),e.guidRegistered=t},CHANGE_GUID_VALID(e,t){We.debug("[CHANGE_GUID_VALID]: %o",t),e.guidValid=t},CHANGE_GUID_VALIDATION_RUNNING(e,t){We.debug("[CHANGE_GUID_VALIDATION_RUNNING]: %o",t),e.guidValidationRunning=t},CHANGE_GUID_FOR_VALIDATION(e,t){We.debug("[CHANGE_GUID_FOR_VALIDATION]: %o",t),e.guidForValidation=t},CHANGE_GUID_BLACKLISTED(e,t){We.debug("[CHANGE_GUID_BLACKLISTED]: %o",t),e.guidBlacklisted=t},CHANGE_REPLACEABLE(e,t){We.debug("[CHANGE_REPLACEABLE]: %o",t),e.replaceable=t},CHANGE_POP_UP_WINDOW(e,t){We.debug("[CHANGE_POP_UP_WINDOW]: %o",t),e.popUpWindow=t,e.isPopUpOpen=!!t,e.regAtOpen=null},STATE_AT_OPEN(e,t){e.regAtOpen=t},MUTATE_KEYSERVER_RESPONSE(e,t){We.debug("[MUTATE_KEYSERVER_RESPONSE]: %o",t),t.license&&(e.license=t.license),t.newKey&&(e.keyfile=t.newKey),t.trial&&(e.keyfile=t.trial),t.apikey&&(e.apikey=t.apikey),t.validated&&(e.ipsValidated=t.validated),t.email&&(e.userEmail=t.email),t.password&&(e.userPassword=t.password),(t.action||t.keyServerAction)&&(e.keyServerAction=t.action||t.keyServerAction),t.username&&(e.username=t.username),t.avatar&&(e.avatar=t.avatar)},SET_TRIAL(e,t){We.debug("[SET_TRIAL]: %o",t),e.license=t.license,e.keyfile=t.trial,e.keyServerAction="extendTrial"},SET_USER_EMAIL(e,t){We.debug("[SET_USER_EMAIL]: %s",t),e.userEmail=t},SET_FULL_SERVER_STATE(e,t){if(We.debug("[SET_FULL_SERVER_STATE] start %o",t),!t)return We.error("[SET_FULL_SERVER_STATE] No state data…🤬");let r=t;return(r.registered||0===r.registered)&&(r.registered=Boolean(Number(r.registered))),(r.hasRemoteApikey||0===r.hasRemoteApikey)&&(r.hasRemoteApikey=Boolean(Number(r.hasRemoteApikey))),r.email&&(r={...r,userEmail:r.email},delete r.email),We.debug("[SET_FULL_SERVER_STATE] ✨ mutateData ✨ %o",{state:e,mutateData:r}),e=Object.assign(e,r),!0},SET_RAW_SERVER_STATE:(e,t)=>Ae?(e.rawServerState=t,We.debug("[SET_RAW_SERVER_STATE] %o",t)):We.debug("[SET_RAW_SERVER_STATE] ❌ skipped not needed in non-pop-up ❌ %o",{CAN_POST_MESSAGE:Ae}),SIGN_OUT(e){We.debug("[SIGN_OUT]: %s","✨"),e.registered=!1,e.license="",e.keyfile="",e.apikey="",e.ipsValidated=!1,e.userEmail="",e.userPassword="",e.username="",e.avatar=""},SUBMISSION_FROM(e,t){We.debug("[SUBMISSION_FROM]: %s",t),e.submissionFrom=t},SET_WANIP(e,t){We.debug("[SET_WANIP]: %s",t),e.wanip=t,sessionStorage.setItem("upc_wanip",t)},SET_SERVERDESC(e,t){We.debug("[SET_SERVERDESC]: %s",t),e.serverdesc=t},SET_SITE(e,t){We.debug("[SET_SITE]: %s",t),e.site=t},SET_CSRF(e,t){We.debug("[SET_CSRF]: %s",t),e.csrf=t},LICENSE_PINGBACK(e,t){We.debug("[LICENSE_PINGBACK]: %o",t),e.licenseAction=t},ACCOUNT_PINGBACK(e,t){We.debug("[ACCOUNT_PINGBACK]: %o",t),e.accountAction=t},RECEIVED_SUCCESS_NEW_SERVERSTATE(e,t){We.debug("[RECEIVED_SUCCESS_NEW_SERVERSTATE]: %o",t),e.receivedSuccessNewServerState=t},SET_UPTIME(e,t){We.debug("[SET_UPTIME]: %s",t),e.uptime=t},SET_EXPIRE_TIME(e,t){We.debug("[SET_EXPIRE_TIME]: %s",t),e.expiretime=t},SET_REGWIZ_TIME(e,t){We.debug("[SET_REGWIZ_TIME]: %s",t),e.regWizTime=t},CHANGE_GUID_FORUMACCOUNT(e,t){We.debug("[CHANGE_GUID_FORUMACCOUNT]: %s",t),e.forumaccount=t},SET_LOCALE(e,t){We.debug("[SET_LOCALE]: %s",t),e.locale=t},LOCALE_MESSAGES(e,t){const[r,n]=Ne(decodeURIComponent(t));r?We.warn("[LOCALE_MESSAGES]: %o",r):(We.debug("[LOCALE_MESSAGES]: %o",n),e.messages=n)},SET_API_KEY(e,t){We.debug("[SET_API_KEY]: %s",t),e.apikey=t},SET_GRAPH_ONLINE(e,t){We.debug("[SET_GRAPH_ONLINE]: %o",t),e.graphOnline=t},SET_GRAPH_RECONNECTED(e,t){We.debug("[SET_GRAPH_RECONNECTED]: %o",t),e.graphReconnected=t},SET_MY_SERVERS(e,t){We.debug("[SET_MY_SERVERS]: %o",t),e.myServers=[...t]},SET_MY_SERVERS_LOADING(e,t){We.debug("[SET_MY_SERVERS_LOADING]: %o",t),e.myServersLoading=t},SET_MY_SERVERS_ERROR(e,t){t?We.error("[SET_MY_SERVERS_ERROR]: %o",t):We.debug("[SET_MY_SERVERS_ERROR] unset"),e.myServersError=t?t.replace("Graphql","unraid-api").replace("offline","stopped"):null},SET_MY_SERVERS_ERROR_SHOW_SUPPORT_BTN(e,t){We.debug("[SET_MY_SERVERS_ERROR_SHOW_SUPPORT_BTN]",t),e.myServersErrorShowSupportBtn=t},SET_MY_SERVERS_ENV(e,t){We.debug("[SET_MY_SERVERS_ENV]: %o",t),e.myServersEnv=t},SET_MY_SERVERS_API_VERSION(e,t){We.debug("[SET_MY_SERVERS_API_VERSION]: %o",t),e.apiVersion=t},TRIGGER_UPC(e,t){We.debug("[TRIGGER_UPC]: %o",t),e.triggerUPC=t},SET_HIDE_MY_SERVERS(e,t){We.debug("[SET_HIDE_MY_SERVERS]: %o",t),e.hideMyServers=!!t},SET_PLG_PATH:(e,t)=>"dynamix.my.servers"!==t?We.warn("[SET_PLG_PATH] value not allowed",t):(We.debug("[SET_PLG_PATH]: %o",t),e.plgPath=t,!0),SET_POST_MESSAGE_ERROR(e,t){e.postMessageError=t,e.postMessageError&&We.error("[SET_POST_MESSAGE_ERROR]: %o",e.postMessageError)},SET_OWNER(e,t){We.debug("[SET_OWNER]: %o",t),e.username=t&&t.username?t.username:"",e.avatar=t&&t.avatar?t.avatar:"",e.registered=!(!t||!t.username)},SET_REGISTRATION_SUB(e,t){We.debug("[SET_REGISTRATION_SUB]: %o",t),t.keyfile&&(e.keyfile=t.keyFile.contents),t.expiration&&(e.expiretime=t.expiration)},SET_DEV_MODE(e,t){We.debug("[SET_DEV_MODE]: %o",t),e.devEnv=t},SET_SIGN_OUT_TRIGGERED(e,t){We.debug("[SET_SIGN_OUT_TRIGGERED]: %o",t),e.signOutTriggered=t},SET_API_EXECUTE_RESPONSE(e,t){We.debug("[SET_API_EXECUTE_RESPONSE]: %o",t),e.apiReport=t},SET_MY_SERVERS_CLOUD(e,t){We.debug("[SET_MY_SERVERS_CLOUD]: %o",t),e.cloud=t},SET_REPLACE_KEY(e,t){We.debug("[SET_REPLACE_KEY]: %o",t),e.license=t.license,e.keyfile=t.newkey,e.keyServerAction="replace"},SET_PIRATE_KEY(e,t){We.debug("[SET_PIRATE_KEY]: %s",t),e.pirateKey=!!t,e.pirateKey?sessionStorage.setItem("upc_yargMatey",t):sessionStorage.removeItem("upc_yargMatey")}};var Ye=r("0e49"),qe=r.n(Ye),Qe=function(){return(Qe=Object.assign||function(e){for(var t,r=1,n=arguments.length;r1&&void 0!==arguments[1]?arguments[1]:e.prototype.toString;e.prototype.toJSON=t,e.prototype.inspect=t,Je.a&&(e.prototype[Je.a]=t)}function et(e){return(et="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function tt(e,t){for(var r,n=/\r\n|[\n\r]/g,i=1,o=t+1;(r=n.exec(e.body))&&r.index120){for(var d=Math.floor(c/80),f=c%80,h=[],m=0;m0||Xe(0,"line in locationOffset is 1-indexed and must be positive"),this.locationOffset.column>0||Xe(0,"column in locationOffset is 1-indexed and must be positive")};!function(e){"function"==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e.prototype,Symbol.toStringTag,{get:function(){return this.constructor.name}})}(lt);var ut=r("04b4"),pt=Object.freeze({SOF:"",EOF:"",BANG:"!",DOLLAR:"$",AMP:"&",PAREN_L:"(",PAREN_R:")",SPREAD:"...",COLON:":",EQUALS:"=",AT:"@",BRACKET_L:"[",BRACKET_R:"]",BRACE_L:"{",PIPE:"|",BRACE_R:"}",NAME:"Name",INT:"Int",FLOAT:"Float",STRING:"String",BLOCK_STRING:"BlockString",COMMENT:"Comment"});function dt(){return this.lastToken=this.token,this.token=this.lookahead()}function ft(){var e=this.token;if(e.kind!==pt.EOF)do{e=e.next||(e.next=gt(this,e))}while(e.kind===pt.COMMENT);return e}function ht(e,t,r,n,i,o,a){this.kind=e,this.start=t,this.end=r,this.line=n,this.column=i,this.value=a,this.prev=o,this.next=null}function mt(e){return isNaN(e)?pt.EOF:e<127?JSON.stringify(String.fromCharCode(e)):'"\\u'.concat(("00"+e.toString(16).toUpperCase()).slice(-4),'"')}function gt(e,t){var r=e.source,n=r.body,i=n.length,o=function(e,t,r){var n=e.length,i=t;for(;i=i)return new ht(pt.EOF,i,i,a,s,t);var c=n.charCodeAt(o);switch(c){case 33:return new ht(pt.BANG,o,o+1,a,s,t);case 35:return function(e,t,r,n,i){var o,a=e.body,s=t;do{o=a.charCodeAt(++s)}while(!isNaN(o)&&(o>31||9===o));return new ht(pt.COMMENT,t,s,r,n,i,a.slice(t+1,s))}(r,o,a,s,t);case 36:return new ht(pt.DOLLAR,o,o+1,a,s,t);case 38:return new ht(pt.AMP,o,o+1,a,s,t);case 40:return new ht(pt.PAREN_L,o,o+1,a,s,t);case 41:return new ht(pt.PAREN_R,o,o+1,a,s,t);case 46:if(46===n.charCodeAt(o+1)&&46===n.charCodeAt(o+2))return new ht(pt.SPREAD,o,o+3,a,s,t);break;case 58:return new ht(pt.COLON,o,o+1,a,s,t);case 61:return new ht(pt.EQUALS,o,o+1,a,s,t);case 64:return new ht(pt.AT,o,o+1,a,s,t);case 91:return new ht(pt.BRACKET_L,o,o+1,a,s,t);case 93:return new ht(pt.BRACKET_R,o,o+1,a,s,t);case 123:return new ht(pt.BRACE_L,o,o+1,a,s,t);case 124:return new ht(pt.PIPE,o,o+1,a,s,t);case 125:return new ht(pt.BRACE_R,o,o+1,a,s,t);case 65:case 66:case 67:case 68:case 69:case 70:case 71:case 72:case 73:case 74:case 75:case 76:case 77:case 78:case 79:case 80:case 81:case 82:case 83:case 84:case 85:case 86:case 87:case 88:case 89:case 90:case 95:case 97:case 98:case 99:case 100:case 101:case 102:case 103:case 104:case 105:case 106:case 107:case 108:case 109:case 110:case 111:case 112:case 113:case 114:case 115:case 116:case 117:case 118:case 119:case 120:case 121:case 122:return function(e,t,r,n,i){var o=e.body,a=o.length,s=t+1,c=0;for(;s!==a&&!isNaN(c=o.charCodeAt(s))&&(95===c||c>=48&&c<=57||c>=65&&c<=90||c>=97&&c<=122);)++s;return new ht(pt.NAME,t,s,r,n,i,o.slice(t,s))}(r,o,a,s,t);case 45:case 48:case 49:case 50:case 51:case 52:case 53:case 54:case 55:case 56:case 57:return function(e,t,r,n,i,o){var a=e.body,s=r,c=t,l=!1;if(45===s&&(s=a.charCodeAt(++c)),48===s){if((s=a.charCodeAt(++c))>=48&&s<=57)throw st(e,c,"Invalid number, unexpected digit after 0: ".concat(mt(s),"."))}else c=vt(e,c,s),s=a.charCodeAt(c);if(46===s&&(l=!0,s=a.charCodeAt(++c),c=vt(e,c,s),s=a.charCodeAt(c)),69!==s&&101!==s||(l=!0,43!==(s=a.charCodeAt(++c))&&45!==s||(s=a.charCodeAt(++c)),c=vt(e,c,s),s=a.charCodeAt(c)),46===s||69===s||101===s)throw st(e,c,"Invalid number, expected digit but got: ".concat(mt(s),"."));return new ht(l?pt.FLOAT:pt.INT,t,c,n,i,o,a.slice(t,c))}(r,o,c,a,s,t);case 34:return 34===n.charCodeAt(o+1)&&34===n.charCodeAt(o+2)?function(e,t,r,n,i,o){var a=e.body,s=t+3,c=s,l=0,u="";for(;s=48&&o<=57){do{o=n.charCodeAt(++i)}while(o>=48&&o<=57);return i}throw st(e,i,"Invalid number, expected digit but got: ".concat(mt(o),"."))}function bt(e,t,r,n){return yt(e)<<12|yt(t)<<8|yt(r)<<4|yt(n)}function yt(e){return e>=48&&e<=57?e-48:e>=65&&e<=70?e-55:e>=97&&e<=102?e-87:-1}Ze(ht,(function(){return{kind:this.kind,value:this.value,line:this.line,column:this.column}}));var wt=Object.freeze({QUERY:"QUERY",MUTATION:"MUTATION",SUBSCRIPTION:"SUBSCRIPTION",FIELD:"FIELD",FRAGMENT_DEFINITION:"FRAGMENT_DEFINITION",FRAGMENT_SPREAD:"FRAGMENT_SPREAD",INLINE_FRAGMENT:"INLINE_FRAGMENT",VARIABLE_DEFINITION:"VARIABLE_DEFINITION",SCHEMA:"SCHEMA",SCALAR:"SCALAR",OBJECT:"OBJECT",FIELD_DEFINITION:"FIELD_DEFINITION",ARGUMENT_DEFINITION:"ARGUMENT_DEFINITION",INTERFACE:"INTERFACE",UNION:"UNION",ENUM:"ENUM",ENUM_VALUE:"ENUM_VALUE",INPUT_OBJECT:"INPUT_OBJECT",INPUT_FIELD_DEFINITION:"INPUT_FIELD_DEFINITION"});var xt=function(){function e(e,t){var r="string"==typeof e?new lt(e):e;r instanceof lt||Xe(0,"Must provide Source. Received: ".concat(Object(Ke.a)(r))),this._lexer=function(e,t){var r=new ht(pt.SOF,0,0,0,0,null);return{source:e,options:t,lastToken:r,token:r,line:1,lineStart:0,advance:dt,lookahead:ft}}(r),this._options=t||{}}var t=e.prototype;return t.parseName=function(){var e=this.expectToken(pt.NAME);return{kind:ct.a.NAME,value:e.value,loc:this.loc(e)}},t.parseDocument=function(){var e=this._lexer.token;return{kind:ct.a.DOCUMENT,definitions:this.many(pt.SOF,this.parseDefinition,pt.EOF),loc:this.loc(e)}},t.parseDefinition=function(){if(this.peek(pt.NAME))switch(this._lexer.token.value){case"query":case"mutation":case"subscription":return this.parseOperationDefinition();case"fragment":return this.parseFragmentDefinition();case"schema":case"scalar":case"type":case"interface":case"union":case"enum":case"input":case"directive":return this.parseTypeSystemDefinition();case"extend":return this.parseTypeSystemExtension()}else{if(this.peek(pt.BRACE_L))return this.parseOperationDefinition();if(this.peekDescription())return this.parseTypeSystemDefinition()}throw this.unexpected()},t.parseOperationDefinition=function(){var e=this._lexer.token;if(this.peek(pt.BRACE_L))return{kind:ct.a.OPERATION_DEFINITION,operation:"query",name:void 0,variableDefinitions:[],directives:[],selectionSet:this.parseSelectionSet(),loc:this.loc(e)};var t,r=this.parseOperationType();return this.peek(pt.NAME)&&(t=this.parseName()),{kind:ct.a.OPERATION_DEFINITION,operation:r,name:t,variableDefinitions:this.parseVariableDefinitions(),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet(),loc:this.loc(e)}},t.parseOperationType=function(){var e=this.expectToken(pt.NAME);switch(e.value){case"query":return"query";case"mutation":return"mutation";case"subscription":return"subscription"}throw this.unexpected(e)},t.parseVariableDefinitions=function(){return this.optionalMany(pt.PAREN_L,this.parseVariableDefinition,pt.PAREN_R)},t.parseVariableDefinition=function(){var e=this._lexer.token;return{kind:ct.a.VARIABLE_DEFINITION,variable:this.parseVariable(),type:(this.expectToken(pt.COLON),this.parseTypeReference()),defaultValue:this.expectOptionalToken(pt.EQUALS)?this.parseValueLiteral(!0):void 0,directives:this.parseDirectives(!0),loc:this.loc(e)}},t.parseVariable=function(){var e=this._lexer.token;return this.expectToken(pt.DOLLAR),{kind:ct.a.VARIABLE,name:this.parseName(),loc:this.loc(e)}},t.parseSelectionSet=function(){var e=this._lexer.token;return{kind:ct.a.SELECTION_SET,selections:this.many(pt.BRACE_L,this.parseSelection,pt.BRACE_R),loc:this.loc(e)}},t.parseSelection=function(){return this.peek(pt.SPREAD)?this.parseFragment():this.parseField()},t.parseField=function(){var e,t,r=this._lexer.token,n=this.parseName();return this.expectOptionalToken(pt.COLON)?(e=n,t=this.parseName()):t=n,{kind:ct.a.FIELD,alias:e,name:t,arguments:this.parseArguments(!1),directives:this.parseDirectives(!1),selectionSet:this.peek(pt.BRACE_L)?this.parseSelectionSet():void 0,loc:this.loc(r)}},t.parseArguments=function(e){var t=e?this.parseConstArgument:this.parseArgument;return this.optionalMany(pt.PAREN_L,t,pt.PAREN_R)},t.parseArgument=function(){var e=this._lexer.token,t=this.parseName();return this.expectToken(pt.COLON),{kind:ct.a.ARGUMENT,name:t,value:this.parseValueLiteral(!1),loc:this.loc(e)}},t.parseConstArgument=function(){var e=this._lexer.token;return{kind:ct.a.ARGUMENT,name:this.parseName(),value:(this.expectToken(pt.COLON),this.parseValueLiteral(!0)),loc:this.loc(e)}},t.parseFragment=function(){var e=this._lexer.token;this.expectToken(pt.SPREAD);var t=this.expectOptionalKeyword("on");return!t&&this.peek(pt.NAME)?{kind:ct.a.FRAGMENT_SPREAD,name:this.parseFragmentName(),directives:this.parseDirectives(!1),loc:this.loc(e)}:{kind:ct.a.INLINE_FRAGMENT,typeCondition:t?this.parseNamedType():void 0,directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet(),loc:this.loc(e)}},t.parseFragmentDefinition=function(){var e=this._lexer.token;return this.expectKeyword("fragment"),this._options.experimentalFragmentVariables?{kind:ct.a.FRAGMENT_DEFINITION,name:this.parseFragmentName(),variableDefinitions:this.parseVariableDefinitions(),typeCondition:(this.expectKeyword("on"),this.parseNamedType()),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet(),loc:this.loc(e)}:{kind:ct.a.FRAGMENT_DEFINITION,name:this.parseFragmentName(),typeCondition:(this.expectKeyword("on"),this.parseNamedType()),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet(),loc:this.loc(e)}},t.parseFragmentName=function(){if("on"===this._lexer.token.value)throw this.unexpected();return this.parseName()},t.parseValueLiteral=function(e){var t=this._lexer.token;switch(t.kind){case pt.BRACKET_L:return this.parseList(e);case pt.BRACE_L:return this.parseObject(e);case pt.INT:return this._lexer.advance(),{kind:ct.a.INT,value:t.value,loc:this.loc(t)};case pt.FLOAT:return this._lexer.advance(),{kind:ct.a.FLOAT,value:t.value,loc:this.loc(t)};case pt.STRING:case pt.BLOCK_STRING:return this.parseStringLiteral();case pt.NAME:return"true"===t.value||"false"===t.value?(this._lexer.advance(),{kind:ct.a.BOOLEAN,value:"true"===t.value,loc:this.loc(t)}):"null"===t.value?(this._lexer.advance(),{kind:ct.a.NULL,loc:this.loc(t)}):(this._lexer.advance(),{kind:ct.a.ENUM,value:t.value,loc:this.loc(t)});case pt.DOLLAR:if(!e)return this.parseVariable()}throw this.unexpected()},t.parseStringLiteral=function(){var e=this._lexer.token;return this._lexer.advance(),{kind:ct.a.STRING,value:e.value,block:e.kind===pt.BLOCK_STRING,loc:this.loc(e)}},t.parseList=function(e){var t=this,r=this._lexer.token;return{kind:ct.a.LIST,values:this.any(pt.BRACKET_L,(function(){return t.parseValueLiteral(e)}),pt.BRACKET_R),loc:this.loc(r)}},t.parseObject=function(e){var t=this,r=this._lexer.token;return{kind:ct.a.OBJECT,fields:this.any(pt.BRACE_L,(function(){return t.parseObjectField(e)}),pt.BRACE_R),loc:this.loc(r)}},t.parseObjectField=function(e){var t=this._lexer.token,r=this.parseName();return this.expectToken(pt.COLON),{kind:ct.a.OBJECT_FIELD,name:r,value:this.parseValueLiteral(e),loc:this.loc(t)}},t.parseDirectives=function(e){for(var t=[];this.peek(pt.AT);)t.push(this.parseDirective(e));return t},t.parseDirective=function(e){var t=this._lexer.token;return this.expectToken(pt.AT),{kind:ct.a.DIRECTIVE,name:this.parseName(),arguments:this.parseArguments(e),loc:this.loc(t)}},t.parseTypeReference=function(){var e,t=this._lexer.token;return this.expectOptionalToken(pt.BRACKET_L)?(e=this.parseTypeReference(),this.expectToken(pt.BRACKET_R),e={kind:ct.a.LIST_TYPE,type:e,loc:this.loc(t)}):e=this.parseNamedType(),this.expectOptionalToken(pt.BANG)?{kind:ct.a.NON_NULL_TYPE,type:e,loc:this.loc(t)}:e},t.parseNamedType=function(){var e=this._lexer.token;return{kind:ct.a.NAMED_TYPE,name:this.parseName(),loc:this.loc(e)}},t.parseTypeSystemDefinition=function(){var e=this.peekDescription()?this._lexer.lookahead():this._lexer.token;if(e.kind===pt.NAME)switch(e.value){case"schema":return this.parseSchemaDefinition();case"scalar":return this.parseScalarTypeDefinition();case"type":return this.parseObjectTypeDefinition();case"interface":return this.parseInterfaceTypeDefinition();case"union":return this.parseUnionTypeDefinition();case"enum":return this.parseEnumTypeDefinition();case"input":return this.parseInputObjectTypeDefinition();case"directive":return this.parseDirectiveDefinition()}throw this.unexpected(e)},t.peekDescription=function(){return this.peek(pt.STRING)||this.peek(pt.BLOCK_STRING)},t.parseDescription=function(){if(this.peekDescription())return this.parseStringLiteral()},t.parseSchemaDefinition=function(){var e=this._lexer.token;this.expectKeyword("schema");var t=this.parseDirectives(!0),r=this.many(pt.BRACE_L,this.parseOperationTypeDefinition,pt.BRACE_R);return{kind:ct.a.SCHEMA_DEFINITION,directives:t,operationTypes:r,loc:this.loc(e)}},t.parseOperationTypeDefinition=function(){var e=this._lexer.token,t=this.parseOperationType();this.expectToken(pt.COLON);var r=this.parseNamedType();return{kind:ct.a.OPERATION_TYPE_DEFINITION,operation:t,type:r,loc:this.loc(e)}},t.parseScalarTypeDefinition=function(){var e=this._lexer.token,t=this.parseDescription();this.expectKeyword("scalar");var r=this.parseName(),n=this.parseDirectives(!0);return{kind:ct.a.SCALAR_TYPE_DEFINITION,description:t,name:r,directives:n,loc:this.loc(e)}},t.parseObjectTypeDefinition=function(){var e=this._lexer.token,t=this.parseDescription();this.expectKeyword("type");var r=this.parseName(),n=this.parseImplementsInterfaces(),i=this.parseDirectives(!0),o=this.parseFieldsDefinition();return{kind:ct.a.OBJECT_TYPE_DEFINITION,description:t,name:r,interfaces:n,directives:i,fields:o,loc:this.loc(e)}},t.parseImplementsInterfaces=function(){var e=[];if(this.expectOptionalKeyword("implements")){this.expectOptionalToken(pt.AMP);do{e.push(this.parseNamedType())}while(this.expectOptionalToken(pt.AMP)||this._options.allowLegacySDLImplementsInterfaces&&this.peek(pt.NAME))}return e},t.parseFieldsDefinition=function(){return this._options.allowLegacySDLEmptyFields&&this.peek(pt.BRACE_L)&&this._lexer.lookahead().kind===pt.BRACE_R?(this._lexer.advance(),this._lexer.advance(),[]):this.optionalMany(pt.BRACE_L,this.parseFieldDefinition,pt.BRACE_R)},t.parseFieldDefinition=function(){var e=this._lexer.token,t=this.parseDescription(),r=this.parseName(),n=this.parseArgumentDefs();this.expectToken(pt.COLON);var i=this.parseTypeReference(),o=this.parseDirectives(!0);return{kind:ct.a.FIELD_DEFINITION,description:t,name:r,arguments:n,type:i,directives:o,loc:this.loc(e)}},t.parseArgumentDefs=function(){return this.optionalMany(pt.PAREN_L,this.parseInputValueDef,pt.PAREN_R)},t.parseInputValueDef=function(){var e=this._lexer.token,t=this.parseDescription(),r=this.parseName();this.expectToken(pt.COLON);var n,i=this.parseTypeReference();this.expectOptionalToken(pt.EQUALS)&&(n=this.parseValueLiteral(!0));var o=this.parseDirectives(!0);return{kind:ct.a.INPUT_VALUE_DEFINITION,description:t,name:r,type:i,defaultValue:n,directives:o,loc:this.loc(e)}},t.parseInterfaceTypeDefinition=function(){var e=this._lexer.token,t=this.parseDescription();this.expectKeyword("interface");var r=this.parseName(),n=this.parseDirectives(!0),i=this.parseFieldsDefinition();return{kind:ct.a.INTERFACE_TYPE_DEFINITION,description:t,name:r,directives:n,fields:i,loc:this.loc(e)}},t.parseUnionTypeDefinition=function(){var e=this._lexer.token,t=this.parseDescription();this.expectKeyword("union");var r=this.parseName(),n=this.parseDirectives(!0),i=this.parseUnionMemberTypes();return{kind:ct.a.UNION_TYPE_DEFINITION,description:t,name:r,directives:n,types:i,loc:this.loc(e)}},t.parseUnionMemberTypes=function(){var e=[];if(this.expectOptionalToken(pt.EQUALS)){this.expectOptionalToken(pt.PIPE);do{e.push(this.parseNamedType())}while(this.expectOptionalToken(pt.PIPE))}return e},t.parseEnumTypeDefinition=function(){var e=this._lexer.token,t=this.parseDescription();this.expectKeyword("enum");var r=this.parseName(),n=this.parseDirectives(!0),i=this.parseEnumValuesDefinition();return{kind:ct.a.ENUM_TYPE_DEFINITION,description:t,name:r,directives:n,values:i,loc:this.loc(e)}},t.parseEnumValuesDefinition=function(){return this.optionalMany(pt.BRACE_L,this.parseEnumValueDefinition,pt.BRACE_R)},t.parseEnumValueDefinition=function(){var e=this._lexer.token,t=this.parseDescription(),r=this.parseName(),n=this.parseDirectives(!0);return{kind:ct.a.ENUM_VALUE_DEFINITION,description:t,name:r,directives:n,loc:this.loc(e)}},t.parseInputObjectTypeDefinition=function(){var e=this._lexer.token,t=this.parseDescription();this.expectKeyword("input");var r=this.parseName(),n=this.parseDirectives(!0),i=this.parseInputFieldsDefinition();return{kind:ct.a.INPUT_OBJECT_TYPE_DEFINITION,description:t,name:r,directives:n,fields:i,loc:this.loc(e)}},t.parseInputFieldsDefinition=function(){return this.optionalMany(pt.BRACE_L,this.parseInputValueDef,pt.BRACE_R)},t.parseTypeSystemExtension=function(){var e=this._lexer.lookahead();if(e.kind===pt.NAME)switch(e.value){case"schema":return this.parseSchemaExtension();case"scalar":return this.parseScalarTypeExtension();case"type":return this.parseObjectTypeExtension();case"interface":return this.parseInterfaceTypeExtension();case"union":return this.parseUnionTypeExtension();case"enum":return this.parseEnumTypeExtension();case"input":return this.parseInputObjectTypeExtension()}throw this.unexpected(e)},t.parseSchemaExtension=function(){var e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("schema");var t=this.parseDirectives(!0),r=this.optionalMany(pt.BRACE_L,this.parseOperationTypeDefinition,pt.BRACE_R);if(0===t.length&&0===r.length)throw this.unexpected();return{kind:ct.a.SCHEMA_EXTENSION,directives:t,operationTypes:r,loc:this.loc(e)}},t.parseScalarTypeExtension=function(){var e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("scalar");var t=this.parseName(),r=this.parseDirectives(!0);if(0===r.length)throw this.unexpected();return{kind:ct.a.SCALAR_TYPE_EXTENSION,name:t,directives:r,loc:this.loc(e)}},t.parseObjectTypeExtension=function(){var e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("type");var t=this.parseName(),r=this.parseImplementsInterfaces(),n=this.parseDirectives(!0),i=this.parseFieldsDefinition();if(0===r.length&&0===n.length&&0===i.length)throw this.unexpected();return{kind:ct.a.OBJECT_TYPE_EXTENSION,name:t,interfaces:r,directives:n,fields:i,loc:this.loc(e)}},t.parseInterfaceTypeExtension=function(){var e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("interface");var t=this.parseName(),r=this.parseDirectives(!0),n=this.parseFieldsDefinition();if(0===r.length&&0===n.length)throw this.unexpected();return{kind:ct.a.INTERFACE_TYPE_EXTENSION,name:t,directives:r,fields:n,loc:this.loc(e)}},t.parseUnionTypeExtension=function(){var e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("union");var t=this.parseName(),r=this.parseDirectives(!0),n=this.parseUnionMemberTypes();if(0===r.length&&0===n.length)throw this.unexpected();return{kind:ct.a.UNION_TYPE_EXTENSION,name:t,directives:r,types:n,loc:this.loc(e)}},t.parseEnumTypeExtension=function(){var e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("enum");var t=this.parseName(),r=this.parseDirectives(!0),n=this.parseEnumValuesDefinition();if(0===r.length&&0===n.length)throw this.unexpected();return{kind:ct.a.ENUM_TYPE_EXTENSION,name:t,directives:r,values:n,loc:this.loc(e)}},t.parseInputObjectTypeExtension=function(){var e=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("input");var t=this.parseName(),r=this.parseDirectives(!0),n=this.parseInputFieldsDefinition();if(0===r.length&&0===n.length)throw this.unexpected();return{kind:ct.a.INPUT_OBJECT_TYPE_EXTENSION,name:t,directives:r,fields:n,loc:this.loc(e)}},t.parseDirectiveDefinition=function(){var e=this._lexer.token,t=this.parseDescription();this.expectKeyword("directive"),this.expectToken(pt.AT);var r=this.parseName(),n=this.parseArgumentDefs(),i=this.expectOptionalKeyword("repeatable");this.expectKeyword("on");var o=this.parseDirectiveLocations();return{kind:ct.a.DIRECTIVE_DEFINITION,description:t,name:r,arguments:n,repeatable:i,locations:o,loc:this.loc(e)}},t.parseDirectiveLocations=function(){this.expectOptionalToken(pt.PIPE);var e=[];do{e.push(this.parseDirectiveLocation())}while(this.expectOptionalToken(pt.PIPE));return e},t.parseDirectiveLocation=function(){var e=this._lexer.token,t=this.parseName();if(void 0!==wt[t.value])return t;throw this.unexpected(e)},t.loc=function(e){if(!this._options.noLocation)return new _t(e,this._lexer.lastToken,this._lexer.source)},t.peek=function(e){return this._lexer.token.kind===e},t.expectToken=function(e){var t=this._lexer.token;if(t.kind===e)return this._lexer.advance(),t;throw st(this._lexer.source,t.start,"Expected ".concat(e,", found ").concat(Et(t)))},t.expectOptionalToken=function(e){var t=this._lexer.token;if(t.kind===e)return this._lexer.advance(),t},t.expectKeyword=function(e){var t=this._lexer.token;if(t.kind!==pt.NAME||t.value!==e)throw st(this._lexer.source,t.start,'Expected "'.concat(e,'", found ').concat(Et(t)));this._lexer.advance()},t.expectOptionalKeyword=function(e){var t=this._lexer.token;return t.kind===pt.NAME&&t.value===e&&(this._lexer.advance(),!0)},t.unexpected=function(e){var t=e||this._lexer.token;return st(this._lexer.source,t.start,"Unexpected ".concat(Et(t)))},t.any=function(e,t,r){this.expectToken(e);for(var n=[];!this.expectOptionalToken(r);)n.push(t.call(this));return n},t.optionalMany=function(e,t,r){if(this.expectOptionalToken(e)){var n=[];do{n.push(t.call(this))}while(!this.expectOptionalToken(r));return n}return[]},t.many=function(e,t,r){this.expectToken(e);var n=[];do{n.push(t.call(this))}while(!this.expectOptionalToken(r));return n},e}();function _t(e,t,r){this.start=e.start,this.end=t.end,this.startToken=e,this.endToken=t,this.source=r}function Et(e){var t=e.value;return t?"".concat(e.kind,' "').concat(t,'"'):e.kind}Ze(_t,(function(){return{start:this.start,end:this.end}}));var St=new Map,kt=new Map,Ot=!0,Tt=!1;function It(e){return e.replace(/[\s,]+/g," ").trim()}function At(e){var t=new Set,r=[];return e.definitions.forEach((function(e){if("FragmentDefinition"===e.kind){var n=e.name.value,i=function(e){return It(e.source.body.substring(e.start,e.end))}(e.loc),o=kt.get(n);o&&!o.has(i)?Ot&&console.warn("Warning: fragment with name "+n+" already exists.\ngraphql-tag enforces all fragment names across your application to be unique; read more about\nthis in the docs: http://dev.apollodata.com/core/fragments.html#unique-names"):o||kt.set(n,o=new Set),o.add(i),t.has(i)||(t.add(i),r.push(e))}else r.push(e)})),Qe(Qe({},e),{definitions:r})}function Rt(e){var t=It(e);if(!St.has(t)){var r=function(e,t){return new xt(e,t).parseDocument()}(e,{experimentalFragmentVariables:Tt});if(!r||"Document"!==r.kind)throw new Error("Not a valid GraphQL document.");St.set(t,function(e){var t=new Set(e.definitions);t.forEach((function(e){e.loc&&delete e.loc,Object.keys(e).forEach((function(r){var n=e[r];n&&"object"==typeof n&&t.add(n)}))}));var r=e.loc;return r&&(delete r.startToken,delete r.endToken),e}(At(r)))}return St.get(t)}function Ct(e){for(var t=[],r=1;r0}var ar,sr=function(e){function t(r){var n=r.graphQLErrors,i=r.networkError,o=r.errorMessage,a=r.extraInfo,s=e.call(this,o)||this;return s.graphQLErrors=n||[],s.networkError=i||null,s.message=o||function(e){var t="";return or(e.graphQLErrors)&&e.graphQLErrors.forEach((function(e){var r=e?e.message:"Error message not found.";t+="GraphQL error: "+r+"\n"})),e.networkError&&(t+="Network error: "+e.networkError.message+"\n"),t=t.replace(/\n$/,"")}(s),s.extraInfo=a,s.__proto__=t.prototype,s}return Object(jt.c)(t,e),t}(Error);!function(e){e[e.normal=1]="normal",e[e.refetch=2]="refetch",e[e.poll=3]="poll"}(ar||(ar={}));var cr=function(e){function t(t){var r=t.queryManager,n=t.options,i=t.shouldSubscribe,o=void 0===i||i,a=e.call(this,(function(e){return a.onSubscribe(e)}))||this;a.observers=new Set,a.subscriptions=new Set,a.isTornDown=!1,a.options=n,a.variables=n.variables||{},a.queryId=r.generateQueryId(),a.shouldSubscribe=o;var s=Object(Ft.m)(n.query);return a.queryName=s&&s.name&&s.name.value,a.queryManager=r,a}return Object(jt.c)(t,e),t.prototype.result=function(){var e=this;return new Promise((function(t,r){var n={next:function(r){t(r),e.observers.delete(n),e.observers.size||e.queryManager.removeQuery(e.queryId),setTimeout((function(){i.unsubscribe()}),0)},error:r},i=e.subscribe(n)}))},t.prototype.currentResult=function(){var e=this.getCurrentResult();return void 0===e.data&&(e.data={}),e},t.prototype.getCurrentResult=function(){if(this.isTornDown){var e=this.lastResult;return{data:!this.lastError&&e&&e.data||void 0,error:this.lastError,loading:!1,networkStatus:er.error}}var t,r=this.queryManager.getCurrentQueryResult(this),n=r.data,i=r.partial,o=this.queryManager.queryStore.get(this.queryId),a=this.options.fetchPolicy,s="network-only"===a||"no-cache"===a;if(o){var c=o.networkStatus;if(function(e,t){return void 0===t&&(t="none"),e&&(e.networkError||"none"===t&&or(e.graphQLErrors))}(o,this.options.errorPolicy))return{data:void 0,loading:!1,networkStatus:c,error:new sr({graphQLErrors:o.graphQLErrors,networkError:o.networkError})};o.variables&&(this.options.variables=Object(jt.a)(Object(jt.a)({},this.options.variables),o.variables),this.variables=this.options.variables),t={data:n,loading:nr(c),networkStatus:c},o.graphQLErrors&&"all"===this.options.errorPolicy&&(t.errors=o.graphQLErrors)}else{var l=s||i&&"cache-only"!==a;t={data:n,loading:l,networkStatus:l?er.loading:er.ready}}return i||this.updateLastResult(Object(jt.a)(Object(jt.a)({},t),{stale:!1})),Object(jt.a)(Object(jt.a)({},t),{partial:i})},t.prototype.isDifferentFromLastResult=function(e){var t=this.lastResultSnapshot;return!(t&&e&&t.networkStatus===e.networkStatus&&t.stale===e.stale&&Object($t.a)(t.data,e.data))},t.prototype.getLastResult=function(){return this.lastResult},t.prototype.getLastError=function(){return this.lastError},t.prototype.resetLastResults=function(){delete this.lastResult,delete this.lastResultSnapshot,delete this.lastError,this.isTornDown=!1},t.prototype.resetQueryStoreErrors=function(){var e=this.queryManager.queryStore.get(this.queryId);e&&(e.networkError=null,e.graphQLErrors=[])},t.prototype.refetch=function(e){var t=this.options.fetchPolicy;return"cache-only"===t?Promise.reject(new zt.a(1)):("no-cache"!==t&&"cache-and-network"!==t&&(t="network-only"),Object($t.a)(this.variables,e)||(this.variables=Object(jt.a)(Object(jt.a)({},this.variables),e)),Object($t.a)(this.options.variables,this.variables)||(this.options.variables=Object(jt.a)(Object(jt.a)({},this.options.variables),this.variables)),this.queryManager.fetchQuery(this.queryId,Object(jt.a)(Object(jt.a)({},this.options),{fetchPolicy:t}),ar.refetch))},t.prototype.fetchMore=function(e){var t=this;Object(zt.b)(e.updateQuery,2);var r=Object(jt.a)(Object(jt.a)({},e.query?e:Object(jt.a)(Object(jt.a)(Object(jt.a)({},this.options),e),{variables:Object(jt.a)(Object(jt.a)({},this.variables),e.variables)})),{fetchPolicy:"network-only"}),n=this.queryManager.generateQueryId();return this.queryManager.fetchQuery(n,r,ar.normal,this.queryId).then((function(i){return t.updateQuery((function(t){return e.updateQuery(t,{fetchMoreResult:i.data,variables:r.variables})})),t.queryManager.stopQuery(n),i}),(function(e){throw t.queryManager.stopQuery(n),e}))},t.prototype.subscribeToMore=function(e){var t=this,r=this.queryManager.startGraphQLSubscription({query:e.document,variables:e.variables}).subscribe({next:function(r){var n=e.updateQuery;n&&t.updateQuery((function(e,t){var i=t.variables;return n(e,{subscriptionData:r,variables:i})}))},error:function(t){e.onError&&e.onError(t)}});return this.subscriptions.add(r),function(){t.subscriptions.delete(r)&&r.unsubscribe()}},t.prototype.setOptions=function(e){var t=this.options.fetchPolicy;this.options=Object(jt.a)(Object(jt.a)({},this.options),e),e.pollInterval?this.startPolling(e.pollInterval):0===e.pollInterval&&this.stopPolling();var r=e.fetchPolicy;return this.setVariables(this.options.variables,t!==r&&("cache-only"===t||"standby"===t||"network-only"===r),e.fetchResults)},t.prototype.setVariables=function(e,t,r){return void 0===t&&(t=!1),void 0===r&&(r=!0),this.isTornDown=!1,e=e||this.variables,!t&&Object($t.a)(e,this.variables)?this.observers.size&&r?this.result():Promise.resolve():(this.variables=this.options.variables=e,this.observers.size?this.queryManager.fetchQuery(this.queryId,this.options):Promise.resolve())},t.prototype.updateQuery=function(e){var t=this.queryManager,r=t.getQueryWithPreviousResult(this.queryId),n=r.previousResult,i=r.variables,o=r.document,a=Object(Ft.I)((function(){return e(n,{variables:i})}));a&&(t.dataStore.markUpdateQueryResult(o,i,a),t.broadcastQueries())},t.prototype.stopPolling=function(){this.queryManager.stopPollingQuery(this.queryId),this.options.pollInterval=void 0},t.prototype.startPolling=function(e){pr(this),this.options.pollInterval=e,this.queryManager.startPollingQuery(this.options,this.queryId)},t.prototype.updateLastResult=function(e){var t=this.lastResult;return this.lastResult=e,this.lastResultSnapshot=this.queryManager.assumeImmutableResults?e:Object(Ft.f)(e),t},t.prototype.onSubscribe=function(e){var t=this;try{var r=e._subscription._observer;r&&!r.error&&(r.error=lr)}catch(e){}var n=!this.observers.size;return this.observers.add(e),e.next&&this.lastResult&&e.next(this.lastResult),e.error&&this.lastError&&e.error(this.lastError),n&&this.setUpQuery(),function(){t.observers.delete(e)&&!t.observers.size&&t.tearDownQuery()}},t.prototype.setUpQuery=function(){var e=this,t=this.queryManager,r=this.queryId;this.shouldSubscribe&&t.addObservableQuery(r,this),this.options.pollInterval&&(pr(this),t.startPollingQuery(this.options,r));var n=function(t){e.updateLastResult(Object(jt.a)(Object(jt.a)({},e.lastResult),{errors:t.graphQLErrors,networkStatus:er.error,loading:!1})),ur(e.observers,"error",e.lastError=t)};t.observeQuery(r,this.options,{next:function(r){if(e.lastError||e.isDifferentFromLastResult(r)){var n=e.updateLastResult(r),i=e.options,o=i.query,a=i.variables,s=i.fetchPolicy;t.transform(o).hasClientExports?t.getLocalState().addExportedVariables(o,a).then((function(i){var a=e.variables;e.variables=e.options.variables=i,!r.loading&&n&&"cache-only"!==s&&t.transform(o).serverQuery&&!Object($t.a)(a,i)?e.refetch():ur(e.observers,"next",r)})):ur(e.observers,"next",r)}},error:n}).catch(n)},t.prototype.tearDownQuery=function(){var e=this.queryManager;this.isTornDown=!0,e.stopPollingQuery(this.queryId),this.subscriptions.forEach((function(e){return e.unsubscribe()})),this.subscriptions.clear(),e.removeObservableQuery(this.queryId),e.stopQuery(this.queryId),this.observers.clear()},t}(ir);function lr(e){}function ur(e,t,r){var n=[];e.forEach((function(e){return e[t]&&n.push(e)})),n.forEach((function(e){return e[t](r)}))}function pr(e){var t=e.options.fetchPolicy;Object(zt.b)("cache-first"!==t&&"cache-only"!==t,3)}var dr=function(){function e(){this.store={}}return e.prototype.getStore=function(){return this.store},e.prototype.get=function(e){return this.store[e]},e.prototype.initMutation=function(e,t,r){this.store[e]={mutation:t,variables:r||{},loading:!0,error:null}},e.prototype.markMutationError=function(e,t){var r=this.store[e];r&&(r.loading=!1,r.error=t)},e.prototype.markMutationResult=function(e){var t=this.store[e];t&&(t.loading=!1,t.error=null)},e.prototype.reset=function(){this.store={}},e}(),fr=function(){function e(){this.store={}}return e.prototype.getStore=function(){return this.store},e.prototype.get=function(e){return this.store[e]},e.prototype.initQuery=function(e){var t=this.store[e.queryId];Object(zt.b)(!t||t.document===e.document||Object($t.a)(t.document,e.document),19);var r,n=!1,i=null;e.storePreviousVariables&&t&&t.networkStatus!==er.loading&&(Object($t.a)(t.variables,e.variables)||(n=!0,i=t.variables)),r=n?er.setVariables:e.isPoll?er.poll:e.isRefetch?er.refetch:er.loading;var o=[];t&&t.graphQLErrors&&(o=t.graphQLErrors),this.store[e.queryId]={document:e.document,variables:e.variables,previousVariables:i,networkError:null,graphQLErrors:o,networkStatus:r,metadata:e.metadata},"string"==typeof e.fetchMoreForQueryId&&this.store[e.fetchMoreForQueryId]&&(this.store[e.fetchMoreForQueryId].networkStatus=er.fetchMore)},e.prototype.markQueryResult=function(e,t,r){this.store&&this.store[e]&&(this.store[e].networkError=null,this.store[e].graphQLErrors=or(t.errors)?t.errors:[],this.store[e].previousVariables=null,this.store[e].networkStatus=er.ready,"string"==typeof r&&this.store[r]&&(this.store[r].networkStatus=er.ready))},e.prototype.markQueryError=function(e,t,r){this.store&&this.store[e]&&(this.store[e].networkError=t,this.store[e].networkStatus=er.error,"string"==typeof r&&this.markQueryResultClient(r,!0))},e.prototype.markQueryResultClient=function(e,t){var r=this.store&&this.store[e];r&&(r.networkError=null,r.previousVariables=null,t&&(r.networkStatus=er.ready))},e.prototype.stopQuery=function(e){delete this.store[e]},e.prototype.reset=function(e){var t=this;Object.keys(this.store).forEach((function(r){e.indexOf(r)<0?t.stopQuery(r):t.store[r].networkStatus=er.loading}))},e}();var hr=function(){function e(e){var t=e.cache,r=e.client,n=e.resolvers,i=e.fragmentMatcher;this.cache=t,r&&(this.client=r),n&&this.addResolvers(n),i&&this.setFragmentMatcher(i)}return e.prototype.addResolvers=function(e){var t=this;this.resolvers=this.resolvers||{},Array.isArray(e)?e.forEach((function(e){t.resolvers=Object(Ft.A)(t.resolvers,e)})):this.resolvers=Object(Ft.A)(this.resolvers,e)},e.prototype.setResolvers=function(e){this.resolvers={},this.addResolvers(e)},e.prototype.getResolvers=function(){return this.resolvers||{}},e.prototype.runResolvers=function(e){var t=e.document,r=e.remoteResult,n=e.context,i=e.variables,o=e.onlyRunForcedResolvers,a=void 0!==o&&o;return Object(jt.b)(this,void 0,void 0,(function(){return Object(jt.d)(this,(function(e){return t?[2,this.resolveDocument(t,r.data,n,i,this.fragmentMatcher,a).then((function(e){return Object(jt.a)(Object(jt.a)({},r),{data:e.result})}))]:[2,r]}))}))},e.prototype.setFragmentMatcher=function(e){this.fragmentMatcher=e},e.prototype.getFragmentMatcher=function(){return this.fragmentMatcher},e.prototype.clientQuery=function(e){return Object(Ft.s)(["client"],e)&&this.resolvers?e:null},e.prototype.serverQuery=function(e){return this.resolvers?Object(Ft.C)(e):e},e.prototype.prepareContext=function(e){void 0===e&&(e={});var t=this.cache;return Object(jt.a)(Object(jt.a)({},e),{cache:t,getCacheKey:function(e){if(t.config)return t.config.dataIdFromObject(e);Object(zt.b)(!1,6)}})},e.prototype.addExportedVariables=function(e,t,r){return void 0===t&&(t={}),void 0===r&&(r={}),Object(jt.b)(this,void 0,void 0,(function(){return Object(jt.d)(this,(function(n){return e?[2,this.resolveDocument(e,this.buildRootValueFromCache(e,t)||{},this.prepareContext(r),t).then((function(e){return Object(jt.a)(Object(jt.a)({},t),e.exportedVariables)}))]:[2,Object(jt.a)({},t)]}))}))},e.prototype.shouldForceResolvers=function(e){var t=!1;return Object(rr.b)(e,{Directive:{enter:function(e){if("client"===e.name.value&&e.arguments&&(t=e.arguments.some((function(e){return"always"===e.name.value&&"BooleanValue"===e.value.kind&&!0===e.value.value}))))return rr.a}}}),t},e.prototype.buildRootValueFromCache=function(e,t){return this.cache.diff({query:Object(Ft.d)(e),variables:t,returnPartialData:!0,optimistic:!1}).result},e.prototype.resolveDocument=function(e,t,r,n,i,o){return void 0===r&&(r={}),void 0===n&&(n={}),void 0===i&&(i=function(){return!0}),void 0===o&&(o=!1),Object(jt.b)(this,void 0,void 0,(function(){var a,s,c,l,u,p,d,f,h;return Object(jt.d)(this,(function(m){return a=Object(Ft.l)(e),s=Object(Ft.j)(e),c=Object(Ft.g)(s),l=a.operation,u=l?function(e){return e.charAt(0).toUpperCase()+e.slice(1)}(l):"Query",d=(p=this).cache,f=p.client,h={fragmentMap:c,context:Object(jt.a)(Object(jt.a)({},r),{cache:d,client:f}),variables:n,fragmentMatcher:i,defaultOperationType:u,exportedVariables:{},onlyRunForcedResolvers:o},[2,this.resolveSelectionSet(a.selectionSet,t,h).then((function(e){return{result:e,exportedVariables:h.exportedVariables}}))]}))}))},e.prototype.resolveSelectionSet=function(e,t,r){return Object(jt.b)(this,void 0,void 0,(function(){var n,i,o,a,s,c=this;return Object(jt.d)(this,(function(l){return n=r.fragmentMap,i=r.context,o=r.variables,a=[t],s=function(e){return Object(jt.b)(c,void 0,void 0,(function(){var s,c;return Object(jt.d)(this,(function(l){return Object(Ft.F)(e,o)?Object(Ft.t)(e)?[2,this.resolveField(e,t,r).then((function(t){var r;void 0!==t&&a.push(((r={})[Object(Ft.E)(e)]=t,r))}))]:(Object(Ft.v)(e)?s=e:(s=n[e.name.value],Object(zt.b)(s,7)),s&&s.typeCondition&&(c=s.typeCondition.name.value,r.fragmentMatcher(t,c,i))?[2,this.resolveSelectionSet(s.selectionSet,t,r).then((function(e){a.push(e)}))]:[2]):[2]}))}))},[2,Promise.all(e.selections.map(s)).then((function(){return Object(Ft.B)(a)}))]}))}))},e.prototype.resolveField=function(e,t,r){return Object(jt.b)(this,void 0,void 0,(function(){var n,i,o,a,s,c,l,u,p,d=this;return Object(jt.d)(this,(function(f){return n=r.variables,i=e.name.value,o=Object(Ft.E)(e),a=i!==o,s=t[o]||t[i],c=Promise.resolve(s),r.onlyRunForcedResolvers&&!this.shouldForceResolvers(e)||(l=t.__typename||r.defaultOperationType,(u=this.resolvers&&this.resolvers[l])&&((p=u[a?i:o])&&(c=Promise.resolve(p(t,Object(Ft.b)(e,n),r.context,{field:e,fragmentMap:r.fragmentMap}))))),[2,c.then((function(t){return void 0===t&&(t=s),e.directives&&e.directives.forEach((function(e){"export"===e.name.value&&e.arguments&&e.arguments.forEach((function(e){"as"===e.name.value&&"StringValue"===e.value.kind&&(r.exportedVariables[e.value.value]=t)}))})),e.selectionSet?null==t?t:Array.isArray(t)?d.resolveSubSelectedArray(e,t,r):e.selectionSet?d.resolveSelectionSet(e.selectionSet,t,r):void 0:t}))]}))}))},e.prototype.resolveSubSelectedArray=function(e,t,r){var n=this;return Promise.all(t.map((function(t){return null===t?null:Array.isArray(t)?n.resolveSubSelectedArray(e,t,r):e.selectionSet?n.resolveSelectionSet(e.selectionSet,t,r):void 0})))},e}();function mr(e){var t=new Set,r=null;return new ir((function(n){return t.add(n),r=r||e.subscribe({next:function(e){t.forEach((function(t){return t.next&&t.next(e)}))},error:function(e){t.forEach((function(t){return t.error&&t.error(e)}))},complete:function(){t.forEach((function(e){return e.complete&&e.complete()}))}}),function(){t.delete(n)&&!t.size&&r&&(r.unsubscribe(),r=null)}}))}var gr=Object.prototype.hasOwnProperty,vr=function(){function e(e){var t=e.link,r=e.queryDeduplication,n=void 0!==r&&r,i=e.store,o=e.onBroadcast,a=void 0===o?function(){}:o,s=e.ssrMode,c=void 0!==s&&s,l=e.clientAwareness,u=void 0===l?{}:l,p=e.localState,d=e.assumeImmutableResults;this.mutationStore=new dr,this.queryStore=new fr,this.clientAwareness={},this.idCounter=1,this.queries=new Map,this.fetchQueryRejectFns=new Map,this.transformCache=new(Ft.e?WeakMap:Map),this.inFlightLinkObservables=new Map,this.pollingInfoByQueryId=new Map,this.link=t,this.queryDeduplication=n,this.dataStore=i,this.onBroadcast=a,this.clientAwareness=u,this.localState=p||new hr({cache:i.getCache()}),this.ssrMode=c,this.assumeImmutableResults=!!d}return e.prototype.stop=function(){var e=this;this.queries.forEach((function(t,r){e.stopQueryNoBroadcast(r)})),this.fetchQueryRejectFns.forEach((function(e){e(new zt.a(8))}))},e.prototype.mutate=function(e){var t=e.mutation,r=e.variables,n=e.optimisticResponse,i=e.updateQueries,o=e.refetchQueries,a=void 0===o?[]:o,s=e.awaitRefetchQueries,c=void 0!==s&&s,l=e.update,u=e.errorPolicy,p=void 0===u?"none":u,d=e.fetchPolicy,f=e.context,h=void 0===f?{}:f;return Object(jt.b)(this,void 0,void 0,(function(){var e,o,s,u=this;return Object(jt.d)(this,(function(f){switch(f.label){case 0:return Object(zt.b)(t,9),Object(zt.b)(!d||"no-cache"===d,10),e=this.generateQueryId(),t=this.transform(t).document,this.setQuery(e,(function(){return{document:t}})),r=this.getVariables(t,r),this.transform(t).hasClientExports?[4,this.localState.addExportedVariables(t,r,h)]:[3,2];case 1:r=f.sent(),f.label=2;case 2:return o=function(){var e={};return i&&u.queries.forEach((function(t,r){var n=t.observableQuery;if(n){var o=n.queryName;o&&gr.call(i,o)&&(e[r]={updater:i[o],query:u.queryStore.get(r)})}})),e},this.mutationStore.initMutation(e,t,r),this.dataStore.markMutationInit({mutationId:e,document:t,variables:r,updateQueries:o(),update:l,optimisticResponse:n}),this.broadcastQueries(),s=this,[2,new Promise((function(i,u){var f,m;s.getObservableFromLink(t,Object(jt.a)(Object(jt.a)({},h),{optimisticResponse:n}),r,!1).subscribe({next:function(n){Object(Ft.q)(n)&&"none"===p?m=new sr({graphQLErrors:n.errors}):(s.mutationStore.markMutationResult(e),"no-cache"!==d&&s.dataStore.markMutationResult({mutationId:e,result:n,document:t,variables:r,updateQueries:o(),update:l}),f=n)},error:function(t){s.mutationStore.markMutationError(e,t),s.dataStore.markMutationComplete({mutationId:e,optimisticResponse:n}),s.broadcastQueries(),s.setQuery(e,(function(){return{document:null}})),u(new sr({networkError:t}))},complete:function(){if(m&&s.mutationStore.markMutationError(e,m),s.dataStore.markMutationComplete({mutationId:e,optimisticResponse:n}),s.broadcastQueries(),m)u(m);else{"function"==typeof a&&(a=a(f));var t=[];or(a)&&a.forEach((function(e){if("string"==typeof e)s.queries.forEach((function(r){var n=r.observableQuery;n&&n.queryName===e&&t.push(n.refetch())}));else{var r={query:e.query,variables:e.variables,fetchPolicy:"network-only"};e.context&&(r.context=e.context),t.push(s.query(r))}})),Promise.all(c?t:[]).then((function(){s.setQuery(e,(function(){return{document:null}})),"ignore"===p&&f&&Object(Ft.q)(f)&&delete f.errors,i(f)}))}}})}))]}}))}))},e.prototype.fetchQuery=function(e,t,r,n){return Object(jt.b)(this,void 0,void 0,(function(){var i,o,a,s,c,l,u,p,d,f,h,m,g,v,b,y,w,x,_=this;return Object(jt.d)(this,(function(E){switch(E.label){case 0:return i=t.metadata,o=void 0===i?null:i,a=t.fetchPolicy,s=void 0===a?"cache-first":a,c=t.context,l=void 0===c?{}:c,u=this.transform(t.query).document,p=this.getVariables(u,t.variables),this.transform(u).hasClientExports?[4,this.localState.addExportedVariables(u,p,l)]:[3,2];case 1:p=E.sent(),E.label=2;case 2:if(t=Object(jt.a)(Object(jt.a)({},t),{variables:p}),h=f="network-only"===s||"no-cache"===s,f||(m=this.dataStore.getCache().diff({query:u,variables:p,returnPartialData:!0,optimistic:!1}),g=m.complete,v=m.result,h=!g||"cache-and-network"===s,d=v),b=h&&"cache-only"!==s&&"standby"!==s,Object(Ft.s)(["live"],u)&&(b=!0),y=this.idCounter++,w="no-cache"!==s?this.updateQueryWatch(e,u,t):void 0,this.setQuery(e,(function(){return{document:u,lastRequestId:y,invalidated:!0,cancel:w}})),this.invalidate(n),this.queryStore.initQuery({queryId:e,document:u,storePreviousVariables:b,variables:p,isPoll:r===ar.poll,isRefetch:r===ar.refetch,metadata:o,fetchMoreForQueryId:n}),this.broadcastQueries(),b){if(x=this.fetchRequest({requestId:y,queryId:e,document:u,options:t,fetchMoreForQueryId:n}).catch((function(t){throw function(e){return e.hasOwnProperty("graphQLErrors")}(t)?t:(y>=_.getQuery(e).lastRequestId&&(_.queryStore.markQueryError(e,t,n),_.invalidate(e),_.invalidate(n),_.broadcastQueries()),new sr({networkError:t}))})),"cache-and-network"!==s)return[2,x];x.catch((function(){}))}return this.queryStore.markQueryResultClient(e,!b),this.invalidate(e),this.invalidate(n),this.transform(u).hasForcedResolvers?[2,this.localState.runResolvers({document:u,remoteResult:{data:d},context:l,variables:p,onlyRunForcedResolvers:!0}).then((function(r){return _.markQueryResult(e,r,t,n),_.broadcastQueries(),r}))]:(this.broadcastQueries(),[2,{data:d}])}}))}))},e.prototype.markQueryResult=function(e,t,r,n){var i=r.fetchPolicy,o=r.variables,a=r.errorPolicy;"no-cache"===i?this.setQuery(e,(function(){return{newData:{result:t.data,complete:!0}}})):this.dataStore.markQueryResult(t,this.getQuery(e).document,o,n,"ignore"===a||"all"===a)},e.prototype.queryListenerForObserver=function(e,t,r){var n=this;function i(e,t){if(r[e])try{r[e](t)}catch(e){}}return function(r,o){if(n.invalidate(e,!1),r){var a=n.getQuery(e),s=a.observableQuery,c=a.document,l=s?s.options.fetchPolicy:t.fetchPolicy;if("standby"!==l){var u=nr(r.networkStatus),p=s&&s.getLastResult(),d=!(!p||p.networkStatus===r.networkStatus),f=t.returnPartialData||!o&&r.previousVariables||d&&t.notifyOnNetworkStatusChange||"cache-only"===l||"cache-and-network"===l;if(!u||f){var h=or(r.graphQLErrors),m=s&&s.options.errorPolicy||t.errorPolicy||"none";if("none"===m&&h||r.networkError)return i("error",new sr({graphQLErrors:r.graphQLErrors,networkError:r.networkError}));try{var g=void 0,v=void 0;if(o)"no-cache"!==l&&"network-only"!==l&&n.setQuery(e,(function(){return{newData:null}})),g=o.result,v=!o.complete;else{var b=s&&s.getLastError(),y="none"!==m&&(b&&b.graphQLErrors)!==r.graphQLErrors;if(p&&p.data&&!y)g=p.data,v=!1;else{var w=n.dataStore.getCache().diff({query:c,variables:r.previousVariables||r.variables,returnPartialData:!0,optimistic:!0});g=w.result,v=!w.complete}}var x=v&&!(t.returnPartialData||"cache-only"===l),_={data:x?p&&p.data:g,loading:u,networkStatus:r.networkStatus,stale:x};"all"===m&&h&&(_.errors=r.graphQLErrors),i("next",_)}catch(e){i("error",new sr({networkError:e}))}}}}}},e.prototype.transform=function(e){var t=this.transformCache;if(!t.has(e)){var r=this.dataStore.getCache(),n=r.transformDocument(e),i=Object(Ft.D)(r.transformForLink(n)),o=this.localState.clientQuery(n),a=this.localState.serverQuery(i),s={document:n,hasClientExports:Object(Ft.r)(n),hasForcedResolvers:this.localState.shouldForceResolvers(n),clientQuery:o,serverQuery:a,defaultVars:Object(Ft.h)(Object(Ft.m)(n))},c=function(e){e&&!t.has(e)&&t.set(e,s)};c(e),c(n),c(o),c(a)}return t.get(e)},e.prototype.getVariables=function(e,t){return Object(jt.a)(Object(jt.a)({},this.transform(e).defaultVars),t)},e.prototype.watchQuery=function(e,t){void 0===t&&(t=!0),Object(zt.b)("standby"!==e.fetchPolicy,11),e.variables=this.getVariables(e.query,e.variables),void 0===e.notifyOnNetworkStatusChange&&(e.notifyOnNetworkStatusChange=!1);var r=Object(jt.a)({},e);return new cr({queryManager:this,options:r,shouldSubscribe:t})},e.prototype.query=function(e){var t=this;return Object(zt.b)(e.query,12),Object(zt.b)("Document"===e.query.kind,13),Object(zt.b)(!e.returnPartialData,14),Object(zt.b)(!e.pollInterval,15),new Promise((function(r,n){var i=t.watchQuery(e,!1);t.fetchQueryRejectFns.set("query:"+i.queryId,n),i.result().then(r,n).then((function(){return t.fetchQueryRejectFns.delete("query:"+i.queryId)}))}))},e.prototype.generateQueryId=function(){return String(this.idCounter++)},e.prototype.stopQueryInStore=function(e){this.stopQueryInStoreNoBroadcast(e),this.broadcastQueries()},e.prototype.stopQueryInStoreNoBroadcast=function(e){this.stopPollingQuery(e),this.queryStore.stopQuery(e),this.invalidate(e)},e.prototype.addQueryListener=function(e,t){this.setQuery(e,(function(e){return e.listeners.add(t),{invalidated:!1}}))},e.prototype.updateQueryWatch=function(e,t,r){var n=this,i=this.getQuery(e).cancel;i&&i();return this.dataStore.getCache().watch({query:t,variables:r.variables,optimistic:!0,previousResult:function(){var t=null,r=n.getQuery(e).observableQuery;if(r){var i=r.getLastResult();i&&(t=i.data)}return t},callback:function(t){n.setQuery(e,(function(){return{invalidated:!0,newData:t}}))}})},e.prototype.addObservableQuery=function(e,t){this.setQuery(e,(function(){return{observableQuery:t}}))},e.prototype.removeObservableQuery=function(e){var t=this.getQuery(e).cancel;this.setQuery(e,(function(){return{observableQuery:null}})),t&&t()},e.prototype.clearStore=function(){this.fetchQueryRejectFns.forEach((function(e){e(new zt.a(16))}));var e=[];return this.queries.forEach((function(t,r){t.observableQuery&&e.push(r)})),this.queryStore.reset(e),this.mutationStore.reset(),this.dataStore.reset()},e.prototype.resetStore=function(){var e=this;return this.clearStore().then((function(){return e.reFetchObservableQueries()}))},e.prototype.reFetchObservableQueries=function(e){var t=this;void 0===e&&(e=!1);var r=[];return this.queries.forEach((function(n,i){var o=n.observableQuery;if(o){var a=o.options.fetchPolicy;o.resetLastResults(),"cache-only"===a||!e&&"standby"===a||r.push(o.refetch()),t.setQuery(i,(function(){return{newData:null}})),t.invalidate(i)}})),this.broadcastQueries(),Promise.all(r)},e.prototype.observeQuery=function(e,t,r){return this.addQueryListener(e,this.queryListenerForObserver(e,t,r)),this.fetchQuery(e,t)},e.prototype.startQuery=function(e,t,r){return this.addQueryListener(e,r),this.fetchQuery(e,t).catch((function(){})),e},e.prototype.startGraphQLSubscription=function(e){var t=this,r=e.query,n=e.fetchPolicy,i=e.variables;r=this.transform(r).document,i=this.getVariables(r,i);var o=function(e){return t.getObservableFromLink(r,{},e,!1).map((function(i){if(n&&"no-cache"===n||(t.dataStore.markSubscriptionResult(i,r,e),t.broadcastQueries()),Object(Ft.q)(i))throw new sr({graphQLErrors:i.errors});return i}))};if(this.transform(r).hasClientExports){var a=this.localState.addExportedVariables(r,i).then(o);return new ir((function(e){var t=null;return a.then((function(r){return t=r.subscribe(e)}),e.error),function(){return t&&t.unsubscribe()}}))}return o(i)},e.prototype.stopQuery=function(e){this.stopQueryNoBroadcast(e),this.broadcastQueries()},e.prototype.stopQueryNoBroadcast=function(e){this.stopQueryInStoreNoBroadcast(e),this.removeQuery(e)},e.prototype.removeQuery=function(e){this.fetchQueryRejectFns.delete("query:"+e),this.fetchQueryRejectFns.delete("fetchRequest:"+e),this.getQuery(e).subscriptions.forEach((function(e){return e.unsubscribe()})),this.queries.delete(e)},e.prototype.getCurrentQueryResult=function(e,t){void 0===t&&(t=!0);var r=e.options,n=r.variables,i=r.query,o=r.fetchPolicy,a=r.returnPartialData,s=e.getLastResult(),c=this.getQuery(e.queryId).newData;if(c&&c.complete)return{data:c.result,partial:!1};if("no-cache"===o||"network-only"===o)return{data:void 0,partial:!1};var l=this.dataStore.getCache().diff({query:i,variables:n,previousResult:s?s.data:void 0,returnPartialData:!0,optimistic:t}),u=l.result,p=l.complete;return{data:p||a?u:void 0,partial:!p}},e.prototype.getQueryWithPreviousResult=function(e){var t;if("string"==typeof e){var r=this.getQuery(e).observableQuery;Object(zt.b)(r,17),t=r}else t=e;var n=t.options,i=n.variables,o=n.query;return{previousResult:this.getCurrentQueryResult(t,!1).data,variables:i,document:o}},e.prototype.broadcastQueries=function(){var e=this;this.onBroadcast(),this.queries.forEach((function(t,r){t.invalidated&&t.listeners.forEach((function(n){n&&n(e.queryStore.get(r),t.newData)}))}))},e.prototype.getLocalState=function(){return this.localState},e.prototype.getObservableFromLink=function(e,t,r,n){var i,o=this;void 0===n&&(n=this.queryDeduplication);var a=this.transform(e).serverQuery;if(a){var s=this.inFlightLinkObservables,c=this.link,l={query:a,variables:r,operationName:Object(Ft.n)(a)||void 0,context:this.prepareContext(Object(jt.a)(Object(jt.a)({},t),{forceFetch:!n}))};if(t=l.context,n){var u=s.get(a)||new Map;s.set(a,u);var p=JSON.stringify(r);if(!(i=u.get(p))){u.set(p,i=mr(Zt(c,l)));var d=function(){u.delete(p),u.size||s.delete(a),f.unsubscribe()},f=i.subscribe({next:d,error:d,complete:d})}}else i=mr(Zt(c,l))}else i=ir.of({data:{}}),t=this.prepareContext(t);var h=this.transform(e).clientQuery;return h&&(i=function(e,t){return new ir((function(r){var n=r.next,i=r.error,o=r.complete,a=0,s=!1,c={next:function(e){++a,new Promise((function(r){r(t(e))})).then((function(e){--a,n&&n.call(r,e),s&&c.complete()}),(function(e){--a,i&&i.call(r,e)}))},error:function(e){i&&i.call(r,e)},complete:function(){s=!0,a||o&&o.call(r)}},l=e.subscribe(c);return function(){return l.unsubscribe()}}))}(i,(function(e){return o.localState.runResolvers({document:h,remoteResult:e,context:t,variables:r})}))),i},e.prototype.fetchRequest=function(e){var t,r,n=this,i=e.requestId,o=e.queryId,a=e.document,s=e.options,c=e.fetchMoreForQueryId,l=s.variables,u=s.errorPolicy,p=void 0===u?"none":u,d=s.fetchPolicy;return new Promise((function(e,u){var f=n.getObservableFromLink(a,s.context,l),h="fetchRequest:"+o;n.fetchQueryRejectFns.set(h,u);var m=function(){n.fetchQueryRejectFns.delete(h),n.setQuery(o,(function(e){e.subscriptions.delete(g)}))},g=f.map((function(e){if(i>=n.getQuery(o).lastRequestId&&(n.markQueryResult(o,e,s,c),n.queryStore.markQueryResult(o,e,c),n.invalidate(o),n.invalidate(c),n.broadcastQueries()),"none"===p&&or(e.errors))return u(new sr({graphQLErrors:e.errors}));if("all"===p&&(r=e.errors),c||"no-cache"===d)t=e.data;else{var f=n.dataStore.getCache().diff({variables:l,query:a,optimistic:!1,returnPartialData:!0}),h=f.result;(f.complete||s.returnPartialData)&&(t=h)}})).subscribe({error:function(e){m(),u(e)},complete:function(){m(),e({data:t,errors:r,loading:!1,networkStatus:er.ready,stale:!1})}});n.setQuery(o,(function(e){e.subscriptions.add(g)}))}))},e.prototype.getQuery=function(e){return this.queries.get(e)||{listeners:new Set,invalidated:!1,document:null,newData:null,lastRequestId:1,observableQuery:null,subscriptions:new Set}},e.prototype.setQuery=function(e,t){var r=this.getQuery(e),n=Object(jt.a)(Object(jt.a)({},r),t(r));this.queries.set(e,n)},e.prototype.invalidate=function(e,t){void 0===t&&(t=!0),e&&this.setQuery(e,(function(){return{invalidated:t}}))},e.prototype.prepareContext=function(e){void 0===e&&(e={});var t=this.localState.prepareContext(e);return Object(jt.a)(Object(jt.a)({},t),{clientAwareness:this.clientAwareness})},e.prototype.checkInFlight=function(e){var t=this.queryStore.get(e);return t&&t.networkStatus!==er.ready&&t.networkStatus!==er.error},e.prototype.startPollingQuery=function(e,t,r){var n=this,i=e.pollInterval;if(Object(zt.b)(i,18),!this.ssrMode){var o=this.pollingInfoByQueryId.get(t);o||this.pollingInfoByQueryId.set(t,o={}),o.interval=i,o.options=Object(jt.a)(Object(jt.a)({},e),{fetchPolicy:"network-only"});var a=function(){var e=n.pollingInfoByQueryId.get(t);e&&(n.checkInFlight(t)?s():n.fetchQuery(t,e.options,ar.poll).then(s,s))},s=function(){var e=n.pollingInfoByQueryId.get(t);e&&(clearTimeout(e.timeout),e.timeout=setTimeout(a,e.interval))};r&&this.addQueryListener(t,r),s()}return t},e.prototype.stopPollingQuery=function(e){this.pollingInfoByQueryId.delete(e)},e}(),br=function(){function e(e){this.cache=e}return e.prototype.getCache=function(){return this.cache},e.prototype.markQueryResult=function(e,t,r,n,i){void 0===i&&(i=!1);var o=!Object(Ft.q)(e);i&&Object(Ft.q)(e)&&e.data&&(o=!0),!n&&o&&this.cache.write({result:e.data,dataId:"ROOT_QUERY",query:t,variables:r})},e.prototype.markSubscriptionResult=function(e,t,r){Object(Ft.q)(e)||this.cache.write({result:e.data,dataId:"ROOT_SUBSCRIPTION",query:t,variables:r})},e.prototype.markMutationInit=function(e){var t,r=this;e.optimisticResponse&&(t="function"==typeof e.optimisticResponse?e.optimisticResponse(e.variables):e.optimisticResponse,this.cache.recordOptimisticTransaction((function(n){var i=r.cache;r.cache=n;try{r.markMutationResult({mutationId:e.mutationId,result:{data:t},document:e.document,variables:e.variables,updateQueries:e.updateQueries,update:e.update})}finally{r.cache=i}}),e.mutationId))},e.prototype.markMutationResult=function(e){var t=this;if(!Object(Ft.q)(e.result)){var r=[{result:e.result.data,dataId:"ROOT_MUTATION",query:e.document,variables:e.variables}],n=e.updateQueries;n&&Object.keys(n).forEach((function(i){var o=n[i],a=o.query,s=o.updater,c=t.cache.diff({query:a.document,variables:a.variables,returnPartialData:!0,optimistic:!1}),l=c.result;if(c.complete){var u=Object(Ft.I)((function(){return s(l,{mutationResult:e.result,queryName:Object(Ft.n)(a.document)||void 0,queryVariables:a.variables})}));u&&r.push({result:u,dataId:"ROOT_QUERY",query:a.document,variables:a.variables})}})),this.cache.performTransaction((function(t){r.forEach((function(e){return t.write(e)}));var n=e.update;n&&Object(Ft.I)((function(){return n(t,e.result)}))}))}},e.prototype.markMutationComplete=function(e){var t=e.mutationId;e.optimisticResponse&&this.cache.removeOptimistic(t)},e.prototype.markUpdateQueryResult=function(e,t,r){this.cache.write({result:r,dataId:"ROOT_QUERY",variables:t,query:e})},e.prototype.reset=function(){return this.cache.reset()},e}(),yr=function(){function e(e){var t=this;this.defaultOptions={},this.resetStoreCallbacks=[],this.clearStoreCallbacks=[];var r=e.cache,n=e.ssrMode,i=void 0!==n&&n,o=e.ssrForceFetchDelay,a=void 0===o?0:o,s=e.connectToDevTools,c=e.queryDeduplication,l=void 0===c||c,u=e.defaultOptions,p=e.assumeImmutableResults,d=void 0!==p&&p,f=e.resolvers,h=e.typeDefs,m=e.fragmentMatcher,g=e.name,v=e.version,b=e.link;if(!b&&f&&(b=Jt.empty()),!b||!r)throw new zt.a(4);this.link=b,this.cache=r,this.store=new br(r),this.disableNetworkFetches=i||a>0,this.queryDeduplication=l,this.defaultOptions=u||{},this.typeDefs=h,a&&setTimeout((function(){return t.disableNetworkFetches=!1}),a),this.watchQuery=this.watchQuery.bind(this),this.query=this.query.bind(this),this.mutate=this.mutate.bind(this),this.resetStore=this.resetStore.bind(this),this.reFetchObservableQueries=this.reFetchObservableQueries.bind(this);void 0!==s&&(s&&"undefined"!=typeof window)&&(window.__APOLLO_CLIENT__=this),this.version="2.6.10",this.localState=new hr({cache:r,client:this,resolvers:f,fragmentMatcher:m}),this.queryManager=new vr({link:this.link,store:this.store,queryDeduplication:l,ssrMode:i,clientAwareness:{name:g,version:v},localState:this.localState,assumeImmutableResults:d,onBroadcast:function(){t.devToolsHookCb&&t.devToolsHookCb({action:{},state:{queries:t.queryManager.queryStore.getStore(),mutations:t.queryManager.mutationStore.getStore()},dataWithOptimisticResults:t.cache.extract(!0)})}})}return e.prototype.stop=function(){this.queryManager.stop()},e.prototype.watchQuery=function(e){return this.defaultOptions.watchQuery&&(e=Object(jt.a)(Object(jt.a)({},this.defaultOptions.watchQuery),e)),!this.disableNetworkFetches||"network-only"!==e.fetchPolicy&&"cache-and-network"!==e.fetchPolicy||(e=Object(jt.a)(Object(jt.a)({},e),{fetchPolicy:"cache-first"})),this.queryManager.watchQuery(e)},e.prototype.query=function(e){return this.defaultOptions.query&&(e=Object(jt.a)(Object(jt.a)({},this.defaultOptions.query),e)),Object(zt.b)("cache-and-network"!==e.fetchPolicy,5),this.disableNetworkFetches&&"network-only"===e.fetchPolicy&&(e=Object(jt.a)(Object(jt.a)({},e),{fetchPolicy:"cache-first"})),this.queryManager.query(e)},e.prototype.mutate=function(e){return this.defaultOptions.mutate&&(e=Object(jt.a)(Object(jt.a)({},this.defaultOptions.mutate),e)),this.queryManager.mutate(e)},e.prototype.subscribe=function(e){return this.queryManager.startGraphQLSubscription(e)},e.prototype.readQuery=function(e,t){return void 0===t&&(t=!1),this.cache.readQuery(e,t)},e.prototype.readFragment=function(e,t){return void 0===t&&(t=!1),this.cache.readFragment(e,t)},e.prototype.writeQuery=function(e){var t=this.cache.writeQuery(e);return this.queryManager.broadcastQueries(),t},e.prototype.writeFragment=function(e){var t=this.cache.writeFragment(e);return this.queryManager.broadcastQueries(),t},e.prototype.writeData=function(e){var t=this.cache.writeData(e);return this.queryManager.broadcastQueries(),t},e.prototype.__actionHookForDevTools=function(e){this.devToolsHookCb=e},e.prototype.__requestRaw=function(e){return Zt(this.link,e)},e.prototype.initQueryManager=function(){return this.queryManager},e.prototype.resetStore=function(){var e=this;return Promise.resolve().then((function(){return e.queryManager.clearStore()})).then((function(){return Promise.all(e.resetStoreCallbacks.map((function(e){return e()})))})).then((function(){return e.reFetchObservableQueries()}))},e.prototype.clearStore=function(){var e=this;return Promise.resolve().then((function(){return e.queryManager.clearStore()})).then((function(){return Promise.all(e.clearStoreCallbacks.map((function(e){return e()})))}))},e.prototype.onResetStore=function(e){var t=this;return this.resetStoreCallbacks.push(e),function(){t.resetStoreCallbacks=t.resetStoreCallbacks.filter((function(t){return t!==e}))}},e.prototype.onClearStore=function(e){var t=this;return this.clearStoreCallbacks.push(e),function(){t.clearStoreCallbacks=t.clearStoreCallbacks.filter((function(t){return t!==e}))}},e.prototype.reFetchObservableQueries=function(e){return this.queryManager.reFetchObservableQueries(e)},e.prototype.extract=function(e){return this.cache.extract(e)},e.prototype.restore=function(e){return this.cache.restore(e)},e.prototype.addResolvers=function(e){this.localState.addResolvers(e)},e.prototype.setResolvers=function(e){this.localState.setResolvers(e)},e.prototype.getResolvers=function(){return this.localState.getResolvers()},e.prototype.setLocalStateFragmentMatcher=function(e){this.localState.setFragmentMatcher(e)},e}();var wr=r("7506"),xr={http:{includeQuery:!0,includeExtensions:!1},headers:{accept:"*/*","content-type":"application/json"},options:{method:"POST"}},_r=function(e,t,r){var n=new Error(r);throw n.name="ServerError",n.response=e,n.statusCode=e.status,n.result=t,n},Er=function(e,t){var r;try{r=JSON.stringify(e)}catch(e){var n=new zt.a(2);throw n.parseError=e,n}return r},Sr=function(e){void 0===e&&(e={});var t=e.uri,r=void 0===t?"/graphql":t,n=e.fetch,i=e.includeExtensions,o=e.useGETForQueries,a=Object(jt.e)(e,["uri","fetch","includeExtensions","useGETForQueries"]);(function(e){if(!e&&"undefined"==typeof fetch)throw new zt.a(1)})(n),n||(n=fetch);var s={http:{includeExtensions:i},options:a.fetchOptions,credentials:a.credentials,headers:a.headers};return new Jt((function(e){var t=function(e,t){return e.getContext().uri||("function"==typeof t?t(e):t||"/graphql")}(e,r),i=e.getContext(),a={};if(i.clientAwareness){var c=i.clientAwareness,l=c.name,u=c.version;l&&(a["apollographql-client-name"]=l),u&&(a["apollographql-client-version"]=u)}var p,d=Object(jt.a)({},a,i.headers),f={http:i.http,options:i.fetchOptions,credentials:i.credentials,headers:d},h=function(e,t){for(var r=[],n=2;n=300&&_r(t,r,"Response not successful: Received status code "+t.status),Array.isArray(r)||r.hasOwnProperty("data")||r.hasOwnProperty("errors")||_r(t,r,"Server response was missing for query '"+(Array.isArray(e)?e.map((function(e){return e.operationName})):e.operationName)+"'."),r}))}}(e)).then((function(e){return r.next(e),r.complete(),e})).catch((function(e){"AbortError"!==e.name&&(e.result&&e.result.errors&&e.result.data&&r.next(e.result),r.error(e))})),function(){p&&p.abort()}}))}))};var kr=function(e){function t(t){return e.call(this,Sr(t).request)||this}return Object(jt.c)(t,e),t}(Jt);function Or(e){return{kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"GeneratedClientQuery"},selectionSet:Ir(e)}]}}function Tr(e,t){return{kind:"Document",definitions:[{kind:"FragmentDefinition",typeCondition:{kind:"NamedType",name:{kind:"Name",value:t||"__FakeType"}},name:{kind:"Name",value:"GeneratedClientQuery"},selectionSet:Ir(e)}]}}function Ir(e){if("number"==typeof e||"boolean"==typeof e||"string"==typeof e||null==e)return null;if(Array.isArray(e))return Ir(e[0]);var t=[];return Object.keys(e).forEach((function(r){var n={kind:"Field",name:{kind:"Name",value:r},selectionSet:Ir(e[r])||void 0};t.push(n)})),{kind:"SelectionSet",selections:t}}var Ar,Rr={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:null,variableDefinitions:null,directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",alias:null,name:{kind:"Name",value:"__typename"},arguments:[],directives:[],selectionSet:null}]}}]},Cr=function(){function e(){}return e.prototype.transformDocument=function(e){return e},e.prototype.transformForLink=function(e){return e},e.prototype.readQuery=function(e,t){return void 0===t&&(t=!1),this.read({query:e.query,variables:e.variables,optimistic:t})},e.prototype.readFragment=function(e,t){return void 0===t&&(t=!1),this.read({query:Object(Ft.k)(e.fragment,e.fragmentName),variables:e.variables,rootId:e.id,optimistic:t})},e.prototype.writeQuery=function(e){this.write({dataId:"ROOT_QUERY",result:e.data,query:e.query,variables:e.variables})},e.prototype.writeFragment=function(e){this.write({dataId:e.id,result:e.data,variables:e.variables,query:Object(Ft.k)(e.fragment,e.fragmentName)})},e.prototype.writeData=function(e){var t=e.id,r=e.data;if(void 0!==t){var n=null;try{n=this.read({rootId:t,optimistic:!1,query:Rr})}catch(e){}var i=n&&n.__typename||"__ClientData",o=Object.assign({__typename:i},r);this.writeFragment({id:t,fragment:Tr(o,i),data:o})}else this.writeQuery({query:Or(r),data:r})},e}();Ar||(Ar={});var Pr=null,Nr={},Mr=1,Dr="@wry/context:Slot",Ur=Array,Lr=Ur[Dr]||function(){var e=function(){function e(){this.id=["slot",Mr++,Date.now(),Math.random().toString(36).slice(2)].join(":")}return e.prototype.hasValue=function(){for(var e=Pr;e;e=e.parent)if(this.id in e.slots){var t=e.slots[this.id];if(t===Nr)break;return e!==Pr&&(Pr.slots[this.id]=t),!0}return Pr&&(Pr.slots[this.id]=Nr),!1},e.prototype.getValue=function(){if(this.hasValue())return Pr.slots[this.id]},e.prototype.withValue=function(e,t,r,n){var i,o=((i={__proto__:null})[this.id]=e,i),a=Pr;Pr={parent:a,slots:o};try{return t.apply(n,r)}finally{Pr=a}},e.bind=function(e){var t=Pr;return function(){var r=Pr;try{return Pr=t,e.apply(this,arguments)}finally{Pr=r}}},e.noContext=function(e,t,r){if(!Pr)return e.apply(r,t);var n=Pr;try{return Pr=null,e.apply(r,t)}finally{Pr=n}},e}();try{Object.defineProperty(Ur,Dr,{value:Ur[Dr]=e,enumerable:!1,writable:!1,configurable:!1})}finally{return e}}();function jr(){}Lr.bind,Lr.noContext;var Fr=function(){function e(e,t){void 0===e&&(e=1/0),void 0===t&&(t=jr),this.max=e,this.dispose=t,this.map=new Map,this.newest=null,this.oldest=null}return e.prototype.has=function(e){return this.map.has(e)},e.prototype.get=function(e){var t=this.getEntry(e);return t&&t.value},e.prototype.getEntry=function(e){var t=this.map.get(e);if(t&&t!==this.newest){var r=t.older,n=t.newer;n&&(n.older=r),r&&(r.newer=n),t.older=this.newest,t.older.newer=t,t.newer=null,this.newest=t,t===this.oldest&&(this.oldest=n)}return t},e.prototype.set=function(e,t){var r=this.getEntry(e);return r?r.value=t:(r={key:e,value:t,newer:null,older:this.newest},this.newest&&(this.newest.newer=r),this.newest=r,this.oldest=this.oldest||r,this.map.set(e,r),r.value)},e.prototype.clean=function(){for(;this.oldest&&this.map.size>this.max;)this.delete(this.oldest.key)},e.prototype.delete=function(e){var t=this.map.get(e);return!!t&&(t===this.newest&&(this.newest=t.older),t===this.oldest&&(this.oldest=t.newer),t.newer&&(t.newer.older=t.older),t.older&&(t.older.newer=t.newer),this.map.delete(e),this.dispose(t.value,e),!0)},e}(),$r=new Lr,Vr=[],Gr=[];function zr(e,t){if(!e)throw new Error(t||"assertion failure")}function Br(e){switch(e.length){case 0:throw new Error("unknown value");case 1:return e[0];case 2:throw e[1]}}var Wr=function(){function e(t,r){this.fn=t,this.args=r,this.parents=new Set,this.childValues=new Map,this.dirtyChildren=null,this.dirty=!0,this.recomputing=!1,this.value=[],++e.count}return e.prototype.recompute=function(){if(zr(!this.recomputing,"already recomputing"),function(e){var t=$r.getValue();if(t)return e.parents.add(t),t.childValues.has(e)||t.childValues.set(e,[]),Yr(e)?Kr(t,e):Xr(t,e),t}(this)||!Zr(this))return Yr(this)?function(e){var t=en(e);return $r.withValue(e,Hr,[e]),function(e){if("function"==typeof e.subscribe)try{rn(e),e.unsubscribe=e.subscribe.apply(null,e.args)}catch(t){return e.setDirty(),!1}return!0}(e)&&function(e){e.dirty=!1,Yr(e)||Qr(e)}(e),t.forEach(Zr),Br(e.value)}(this):Br(this.value)},e.prototype.setDirty=function(){this.dirty||(this.dirty=!0,this.value.length=0,qr(this),rn(this))},e.prototype.dispose=function(){var e=this;en(this).forEach(Zr),rn(this),this.parents.forEach((function(t){t.setDirty(),tn(t,e)}))},e.count=0,e}();function Hr(e){e.recomputing=!0,e.value.length=0;try{e.value[0]=e.fn.apply(null,e.args)}catch(t){e.value[1]=t}e.recomputing=!1}function Yr(e){return e.dirty||!(!e.dirtyChildren||!e.dirtyChildren.size)}function qr(e){e.parents.forEach((function(t){return Kr(t,e)}))}function Qr(e){e.parents.forEach((function(t){return Xr(t,e)}))}function Kr(e,t){if(zr(e.childValues.has(t)),zr(Yr(t)),e.dirtyChildren){if(e.dirtyChildren.has(t))return}else e.dirtyChildren=Gr.pop()||new Set;e.dirtyChildren.add(t),qr(e)}function Xr(e,t){zr(e.childValues.has(t)),zr(!Yr(t));var r=e.childValues.get(t);0===r.length?e.childValues.set(t,function(e){return e.slice(0)}(t.value)):function(e,t){var r=e.length;return r>0&&r===t.length&&e[r-1]===t[r-1]}(r,t.value)||e.setDirty(),Jr(e,t),Yr(e)||Qr(e)}function Jr(e,t){var r=e.dirtyChildren;r&&(r.delete(t),0===r.size&&(Gr.length<100&&Gr.push(r),e.dirtyChildren=null))}function Zr(e){return 0===e.parents.size&&"function"==typeof e.reportOrphan&&!0===e.reportOrphan()}function en(e){var t=Vr;return e.childValues.size>0&&(t=[],e.childValues.forEach((function(r,n){tn(e,n),t.push(n)}))),zr(null===e.dirtyChildren),t}function tn(e,t){t.parents.delete(e),e.childValues.delete(t),Jr(e,t)}function rn(e){var t=e.unsubscribe;"function"==typeof t&&(e.unsubscribe=void 0,t())}var nn=function(){function e(e){this.weakness=e}return e.prototype.lookup=function(){for(var e=[],t=0;t-1)},e.prototype.parseIntrospectionResult=function(e){var t={};return e.__schema.types.forEach((function(e){"UNION"!==e.kind&&"INTERFACE"!==e.kind||(t[e.name]=e.possibleTypes.map((function(e){return e.name})))})),t}}(),Object.prototype.hasOwnProperty),dn=function(){function e(e){var t=this;void 0===e&&(e=Object.create(null)),this.data=e,this.depend=cn((function(e){return t.data[e]}),{disposable:!0,makeCacheKey:function(e){return e}})}return e.prototype.toObject=function(){return this.data},e.prototype.get=function(e){return this.depend(e),this.data[e]},e.prototype.set=function(e,t){t!==this.data[e]&&(this.data[e]=t,this.depend.dirty(e))},e.prototype.delete=function(e){pn.call(this.data,e)&&(delete this.data[e],this.depend.dirty(e))},e.prototype.clear=function(){this.replace(null)},e.prototype.replace=function(e){var t=this;e?(Object.keys(e).forEach((function(r){t.set(r,e[r])})),Object.keys(this.data).forEach((function(r){pn.call(e,r)||t.delete(r)}))):Object.keys(this.data).forEach((function(e){t.delete(e)}))},e}();function fn(e){return new dn(e)}var hn=function(){function e(e){var t=this,r=void 0===e?{}:e,n=r.cacheKeyRoot,i=void 0===n?new nn(Ft.e):n,o=r.freezeResults,a=void 0!==o&&o,s=this,c=s.executeStoreQuery,l=s.executeSelectionSet,u=s.executeSubSelectedArray;this.freezeResults=a,this.executeStoreQuery=cn((function(e){return c.call(t,e)}),{makeCacheKey:function(e){var t=e.query,r=e.rootValue,n=e.contextValue,o=e.variableValues,a=e.fragmentMatcher;if(n.store instanceof dn)return i.lookup(n.store,t,a,JSON.stringify(o),r.id)}}),this.executeSelectionSet=cn((function(e){return l.call(t,e)}),{makeCacheKey:function(e){var t=e.selectionSet,r=e.rootValue,n=e.execContext;if(n.contextValue.store instanceof dn)return i.lookup(n.contextValue.store,t,n.fragmentMatcher,JSON.stringify(n.variableValues),r.id)}}),this.executeSubSelectedArray=cn((function(e){return u.call(t,e)}),{makeCacheKey:function(e){var t=e.field,r=e.array,n=e.execContext;if(n.contextValue.store instanceof dn)return i.lookup(n.contextValue.store,t,r,JSON.stringify(n.variableValues))}})}return e.prototype.readQueryFromStore=function(e){return this.diffQueryAgainstStore(Object(jt.a)(Object(jt.a)({},e),{returnPartialData:!1})).result},e.prototype.diffQueryAgainstStore=function(e){var t=e.store,r=e.query,n=e.variables,i=e.previousResult,o=e.returnPartialData,a=void 0===o||o,s=e.rootId,c=void 0===s?"ROOT_QUERY":s,l=e.fragmentMatcherFunction,u=e.config,p=Object(Ft.o)(r);n=Object(Ft.c)({},Object(Ft.h)(p),n);var d={store:t,dataIdFromObject:u&&u.dataIdFromObject,cacheRedirects:u&&u.cacheRedirects||{}},f=this.executeStoreQuery({query:r,rootValue:{type:"id",id:c,generated:!0,typename:"Query"},contextValue:d,variableValues:n,fragmentMatcher:l}),h=f.missing&&f.missing.length>0;return h&&!a&&f.missing.forEach((function(e){if(!e.tolerable)throw new zt.a(8)})),i&&Object($t.a)(i,f.result)&&(f.result=i),{result:f.result,complete:!h}},e.prototype.executeStoreQuery=function(e){var t=e.query,r=e.rootValue,n=e.contextValue,i=e.variableValues,o=e.fragmentMatcher,a=void 0===o?gn:o,s=Object(Ft.l)(t),c=Object(Ft.j)(t),l={query:t,fragmentMap:Object(Ft.g)(c),contextValue:n,variableValues:i,fragmentMatcher:a};return this.executeSelectionSet({selectionSet:s.selectionSet,rootValue:r,execContext:l})},e.prototype.executeSelectionSet=function(e){var t=this,r=e.selectionSet,n=e.rootValue,i=e.execContext,o=i.fragmentMap,a=i.contextValue,s=i.variableValues,c={result:null},l=[],u=a.store.get(n.id),p=u&&u.__typename||"ROOT_QUERY"===n.id&&"Query"||void 0;function d(e){var t;return e.missing&&(c.missing=c.missing||[],(t=c.missing).push.apply(t,e.missing)),e.result}return r.selections.forEach((function(e){var r;if(Object(Ft.F)(e,s))if(Object(Ft.t)(e)){var c=d(t.executeField(u,p,e,i));void 0!==c&&l.push(((r={})[Object(Ft.E)(e)]=c,r))}else{var f=void 0;if(Object(Ft.v)(e))f=e;else if(!(f=o[e.name.value]))throw new zt.a(9);var h=f.typeCondition&&f.typeCondition.name.value,m=!h||i.fragmentMatcher(n,h,a);if(m){var g=t.executeSelectionSet({selectionSet:f.selectionSet,rootValue:n,execContext:i});"heuristic"===m&&g.missing&&(g=Object(jt.a)(Object(jt.a)({},g),{missing:g.missing.map((function(e){return Object(jt.a)(Object(jt.a)({},e),{tolerable:!0})}))})),l.push(d(g))}}})),c.result=Object(Ft.B)(l),this.freezeResults,c},e.prototype.executeField=function(e,t,r,n){var i=n.variableValues,o=n.contextValue,a=function(e,t,r,n,i,o){o.resultKey;var a=o.directives,s=r;(n||a)&&(s=Object(Ft.p)(s,n,a));var c=void 0;if(e&&void 0===(c=e[s])&&i.cacheRedirects&&"string"==typeof t){var l=i.cacheRedirects[t];if(l){var u=l[r];u&&(c=u(e,n,{getCacheKey:function(e){var t=i.dataIdFromObject(e);return t&&Object(Ft.H)({id:t,typename:e.__typename})}}))}}return void 0===c?{result:c,missing:[{object:e,fieldName:s,tolerable:!1}]}:(Object(Ft.w)(c)&&(c=c.json),{result:c})}(e,t,r.name.value,Object(Ft.b)(r,i),o,{resultKey:Object(Ft.E)(r),directives:Object(Ft.i)(r,i)});return Array.isArray(a.result)?this.combineExecResults(a,this.executeSubSelectedArray({field:r,array:a.result,execContext:n})):r.selectionSet?null==a.result?a:this.combineExecResults(a,this.executeSelectionSet({selectionSet:r.selectionSet,rootValue:a.result,execContext:n})):(mn(r,a.result),this.freezeResults,a)},e.prototype.combineExecResults=function(){for(var e,t=[],r=0;r=0)return!0;r[e].push(t)}else r[e]=[t];return!1}var _n={fragmentMatcher:new un,dataIdFromObject:function(e){if(e.__typename){if(void 0!==e.id)return e.__typename+":"+e.id;if(void 0!==e._id)return e.__typename+":"+e._id}return null},addTypename:!0,resultCaching:!0,freezeResults:!1};var En=Object.prototype.hasOwnProperty,Sn=function(e){function t(t,r,n){var i=e.call(this,Object.create(null))||this;return i.optimisticId=t,i.parent=r,i.transaction=n,i}return Object(jt.c)(t,e),t.prototype.toObject=function(){return Object(jt.a)(Object(jt.a)({},this.parent.toObject()),this.data)},t.prototype.get=function(e){return En.call(this.data,e)?this.data[e]:this.parent.get(e)},t}(vn),kn=function(e){function t(t){void 0===t&&(t={});var r=e.call(this)||this;r.watches=new Set,r.typenameDocumentCache=new Map,r.cacheKeyRoot=new nn(Ft.e),r.silenceBroadcast=!1,r.config=Object(jt.a)(Object(jt.a)({},_n),t),r.config.customResolvers&&(r.config.cacheRedirects=r.config.customResolvers),r.config.cacheResolvers&&(r.config.cacheRedirects=r.config.cacheResolvers),r.addTypename=!!r.config.addTypename,r.data=r.config.resultCaching?new dn:new vn,r.optimisticData=r.data,r.storeWriter=new yn,r.storeReader=new hn({cacheKeyRoot:r.cacheKeyRoot,freezeResults:t.freezeResults});var n=r,i=n.maybeBroadcastWatch;return r.maybeBroadcastWatch=cn((function(e){return i.call(r,e)}),{makeCacheKey:function(e){if(!e.optimistic&&!e.previousResult)return n.data instanceof dn?n.cacheKeyRoot.lookup(e.query,JSON.stringify(e.variables)):void 0}}),r}return Object(jt.c)(t,e),t.prototype.restore=function(e){return e&&this.data.replace(e),this},t.prototype.extract=function(e){return void 0===e&&(e=!1),(e?this.optimisticData:this.data).toObject()},t.prototype.read=function(e){if("string"==typeof e.rootId&&void 0===this.data.get(e.rootId))return null;var t=this.config.fragmentMatcher,r=t&&t.match;return this.storeReader.readQueryFromStore({store:e.optimistic?this.optimisticData:this.data,query:this.transformDocument(e.query),variables:e.variables,rootId:e.rootId,fragmentMatcherFunction:r,previousResult:e.previousResult,config:this.config})||null},t.prototype.write=function(e){var t=this.config.fragmentMatcher,r=t&&t.match;this.storeWriter.writeResultToStore({dataId:e.dataId,result:e.result,variables:e.variables,document:this.transformDocument(e.query),store:this.data,dataIdFromObject:this.config.dataIdFromObject,fragmentMatcherFunction:r}),this.broadcastWatches()},t.prototype.diff=function(e){var t=this.config.fragmentMatcher,r=t&&t.match;return this.storeReader.diffQueryAgainstStore({store:e.optimistic?this.optimisticData:this.data,query:this.transformDocument(e.query),variables:e.variables,returnPartialData:e.returnPartialData,previousResult:e.previousResult,fragmentMatcherFunction:r,config:this.config})},t.prototype.watch=function(e){var t=this;return this.watches.add(e),function(){t.watches.delete(e)}},t.prototype.evict=function(e){throw new zt.a(7)},t.prototype.reset=function(){return this.data.clear(),this.broadcastWatches(),Promise.resolve()},t.prototype.removeOptimistic=function(e){for(var t=[],r=0,n=this.optimisticData;n instanceof Sn;)n.optimisticId===e?++r:t.push(n),n=n.parent;if(r>0){for(this.optimisticData=n;t.length>0;){var i=t.pop();this.performTransaction(i.transaction,i.optimisticId)}this.broadcastWatches()}},t.prototype.performTransaction=function(e,t){var r=this.data,n=this.silenceBroadcast;this.silenceBroadcast=!0,"string"==typeof t&&(this.data=this.optimisticData=new Sn(t,this.optimisticData,e));try{e(this)}finally{this.silenceBroadcast=n,this.data=r}this.broadcastWatches()},t.prototype.recordOptimisticTransaction=function(e,t){return this.performTransaction(e,t)},t.prototype.transformDocument=function(e){if(this.addTypename){var t=this.typenameDocumentCache.get(e);return t||(t=Object(Ft.a)(e),this.typenameDocumentCache.set(e,t),this.typenameDocumentCache.set(t,t)),t}return e},t.prototype.broadcastWatches=function(){var e=this;this.silenceBroadcast||this.watches.forEach((function(t){return e.maybeBroadcastWatch(t)}))},t.prototype.maybeBroadcastWatch=function(e){e.callback(this.diff({query:e.query,variables:e.variables,previousResult:e.previousResult&&e.previousResult(),optimistic:e.optimistic}))},t}(Cr),On=r("633a"),Tn=function(e){function t(t){var r=e.call(this)||this;return t instanceof On.SubscriptionClient?r.subscriptionClient=t:r.subscriptionClient=new On.SubscriptionClient(t.uri,t.options,t.webSocketImpl),r}return Object(jt.c)(t,e),t.prototype.request=function(e){return this.subscriptionClient.request(e)},t}(Jt);function In(e){return new Jt((function(t,r){return new Gt((function(n){var i,o,a;try{i=r(t).subscribe({next:function(i){i.errors&&(a=e({graphQLErrors:i.errors,response:i,operation:t,forward:r}))?o=a.subscribe({next:n.next.bind(n),error:n.error.bind(n),complete:n.complete.bind(n)}):n.next(i)},error:function(i){(a=e({operation:t,networkError:i,graphQLErrors:i&&i.result&&i.result.errors,forward:r}))?o=a.subscribe({next:n.next.bind(n),error:n.error.bind(n),complete:n.complete.bind(n)}):n.error(i)},complete:function(){a||n.complete.bind(n)()}})}catch(i){e({networkError:i,operation:t,forward:r}),n.error(i)}return function(){i&&i.unsubscribe(),o&&i.unsubscribe()}}))}))}!function(e){function t(t){var r=e.call(this)||this;return r.link=In(t),r}Object(jt.c)(t,e),t.prototype.request=function(e,t){return this.link.request(e,t)}}(Jt);var An=function(){function e(e,t,r,n){var i=this;this.operation=e,this.nextLink=t,this.delayFor=r,this.retryIf=n,this.retryCount=0,this.values=[],this.complete=!1,this.canceled=!1,this.observers=[],this.currentSubscription=null,this.onNext=function(e){i.values.push(e);for(var t=0,r=i.observers;t=i)&&(r?r(n,t):!!n)}}(i),r}return Object(jt.c)(t,e),t.prototype.request=function(e,t){var r=new An(e,t,this.delayFor,this.retryIf);return r.start(),new Gt((function(e){return r.subscribe(e),function(){r.unsubscribe(e)}}))},t}(Jt);const Cn=new URL(ye||window.location.origin),Pn={},Nn=e=>{We.debug("[createGraphqlClient]");const t=new Jt((t,r)=>r(t).map(r=>{const{response:{headers:n}}=t.getContext();if(n){const t=n.get("x-environment")||null,r=n.get("x-unraid-api-version")||null;t&&e.commit("SET_MY_SERVERS_ENV",t),r&&e.commit("SET_MY_SERVERS_API_VERSION",r)}return r})).concat(new kr({uri:`${Cn.protocol}//${Cn.host}/graphql`})),r=`${Cn.protocol.includes("https")?"wss://":"ws://"}${Cn.host}/graphql`,n=new Tn({uri:r,options:{timeout:65e3,reconnect:!0,connectionParams:{"x-api-key":e.state.apikey}}});let i;n.subscriptionClient.maxConnectTimeGenerator.setMin(3e3),n.subscriptionClient.onConnected(()=>{We.debug("[🚀 wslink.onConnected 🚀]"),e.commit("SET_GRAPH_ONLINE",!0),e.state.myServersError&&e.commit("SET_MY_SERVERS_ERROR",null)}),n.subscriptionClient.onReconnected(()=>{We.debug("[🚀 wslink.onReconnected 🚀]"),e.commit("SET_GRAPH_ONLINE",!0),e.commit("SET_GRAPH_RECONNECTED",!0),e.state.myServersError&&e.commit("SET_MY_SERVERS_ERROR",null)}),n.subscriptionClient.onDisconnected(()=>{We.debug("[🚀 wslink.onDisconnected 🚀] 01"),e.state.graphOnline&&(clearTimeout(i),i=setTimeout(()=>{We.debug("[🚀 wslink.onDisconnected 🚀] 02"),e.commit("SET_GRAPH_ONLINE",!1),e.state.myServersError||e.commit("SET_MY_SERVERS_ERROR","Disconnected from Unraid API")},150))});const o=Xt(({query:e})=>{const t=Object(Ft.l)(e);return"OperationDefinition"===t.kind&&"subscription"===t.operation},n,t),a=function(e){return new Jt((function(t,r){var n=Object(jt.e)(t,[]);return new Gt((function(i){var o;return Promise.resolve(n).then((function(r){return e(r,t.getContext())})).then(t.setContext).then((function(){o=r(t).subscribe({next:i.next.bind(i),error:i.error.bind(i),complete:i.complete.bind(i)})})).catch(i.error.bind(i)),function(){o&&o.unsubscribe()}}))}))}((t,{headers:r})=>({headers:{...r,"x-api-key":e.state.apikey}})),s=In(({graphQLErrors:t,networkError:r})=>{if(t){We.error("[GraphQL error] %o",t);const r=t[0].message||t[0].error.message||"No error object - [UNRAID]";e.commit("SET_MY_SERVERS_ERROR",r)}if(r){We.error("[Network error]",r);const t=r.message?r.message:r;e.commit("SET_MY_SERVERS_ERROR",t.includes("Unexpected token < in JSON at position 0")?"Unraid API • CORS Error":t)}e.commit("SET_MY_SERVERS_LOADING",!1)}),c=new Rn({delay:{initial:300,max:1/0,jitter:!0},attempts:{max:1/0,retryIf:(t,r)=>(We.debug("[retryLink - retryIf]",{error:t,_operation:r}),e.commit("SET_GRAPH_ONLINE",!1),!!t)}});return new yr({link:Jt.from([c,s,a,o]),connectToDevTools:!1,cache:new kn,defaultOptions:{watchQuery:{fetchPolicy:"no-cache"},query:{fetchPolicy:"no-cache"},mutate:{fetchPolicy:"no-cache"},subscribe:{fetchPolicy:"no-cache",shouldResubscribe:!1}}})},Mn=e=>{if(!e.state.apikey)return We.debug("[getGraphqlClient] NO API KEY");if(Object.keys(Pn).includes(e.state.apikey))return We.debug("[getGraphqlClient] found existing client %o",Pn[e.state.apikey]),Pn[e.state.apikey];const t=Nn(e);return Pn[e.state.apikey]=t,We.debug("[getGraphqlClient] new client inbound %o",t),t},Dn=(e,t)=>(We.debug("[detectOwnersResponseError]",{"context.state.registered":e.state.registered,"context.state.signOutTriggered":e.state.signOutTriggered,"response.data.owner":t.data.owner,"context.state.myServersError":e.state.myServersError}),e.state.signOutTriggered?We.debug("[detectOwnersResponseError] signed out; ignoring"):!t.data.owner||t.data.owner&&"root"===t.data.owner.username?(We.error(Pe,t.data.owner),e.commit("SET_MY_SERVERS_ERROR",`${Pe} ${ke()(e.state.apiVersion,"2.43.3")?"Please update your My Servers plugin to potentially fix this error. Thanks for working with us as we try to solve this bug.":"Please sign out and then sign back in to potentially fix this error. If you have already tried this please contact support. Thanks for working with us as we try to solve this bug."}`),e.commit("SET_MY_SERVERS_ERROR_SHOW_SUPPORT_BTN",!0)):t.data.owner&&"root"!==t.data.owner.username&&e.state.myServersError&&e.state.myServersError.includes(Pe)?(e.commit("SET_MY_SERVERS_ERROR",""),e.commit("SET_MY_SERVERS_ERROR_SHOW_SUPPORT_BTN",!1)):We.debug("[detectOwnersResponseError] PASSED"));var Un=function(){return(Un=Object.assign||function(e){for(var t,r=1,n=arguments.length;r0)&&(r(i.reverse()[0]),n.clearMeasures&&n.clearMeasures(t),Vn.callbacks.delete(t),Vn.callbacks.size<1&&(Vn.observer.disconnect(),n.clearResourceTimings&&n.clearResourceTimings()),!0)},Vn={callbacks:new Map,observer:null,observe:function(e,t){if(e&&t){var r=Fn.a.polyfill("performance",{doThrow:!1});(function(e,t){return!Vn.observer&&e&&t&&(Vn.observer=new t((function(t){Vn.callbacks.forEach((function(r,n){$n(t,n,r,e)}))})),e.clearResourceTimings&&e.clearResourceTimings()),Vn.observer})(r,Fn.a.polyfill("PerformanceObserver",{doThrow:!1}))&&($n(r,e,t,r)||(Vn.callbacks.size<1&&Vn.observer.observe({entryTypes:["resource","measure"]}),Vn.callbacks.set(e,t)))}}},Gn=Vn,zn=function(e){this.error=e},Bn=function(){return(Bn=Object.assign||function(e){for(var t,r=1,n=arguments.length;r1?r[0]+e+"?"+r[1]:this._url+e})},e.prototype.options=function(e,t){return void 0===t&&(t=!0),this.selfFactory({options:t?jn(this._options,e):e})},e.prototype.query=function(e,t){return void 0===t&&(t=!1),this.selfFactory({url:Qn(this._url,e,t)})},e.prototype.headers=function(e){return this.selfFactory({options:jn(this._options,{headers:e||{}})})},e.prototype.accept=function(e){return this.headers({Accept:e})},e.prototype.content=function(e){var t;return this.headers(((t={})[Yn]=e,t))},e.prototype.auth=function(e){return this.headers({Authorization:e})},e.prototype.catcher=function(e,t){var r=new Map(this._catchers);return r.set(e,t),this.selfFactory({catchers:r})},e.prototype.signal=function(e){return this.selfFactory({options:Bn(Bn({},this._options),{signal:e.signal})})},e.prototype.resolve=function(e,t){return void 0===t&&(t=!1),this.selfFactory({resolvers:t?[e]:Wn(Wn([],this._resolvers),[e])})},e.prototype.defer=function(e,t){return void 0===t&&(t=!1),this.selfFactory({deferredChain:t?[e]:Wn(Wn([],this._deferredChain),[e])})},e.prototype.middlewares=function(e,t){return void 0===t&&(t=!1),this.selfFactory({middlewares:t?e:Wn(Wn([],this._middlewares),e)})},e.prototype.method=function(e,t,r){void 0===t&&(t={}),void 0===r&&(r=null);var n=this.options(Bn(Bn({},t),{method:e})),i=n._options.headers;return function(e){var t=e._url,r=e._catchers,n=e._resolvers,i=e._middlewares,o=e._options,a=new Map(r),s=jn(Fn.a.defaults,o),c=Fn.a.polyfill("AbortController",{doThrow:!1,instance:!0});!s.signal&&c&&(s.signal=c.signal);var l={ref:null,clear:function(){l.ref&&(clearTimeout(l.ref),l.ref=null)}},u=function(e){return function(t){return 0===e.length?t:1===e.length?e[0](t):e.reduceRight((function(r,n,i){return i===e.length-2?n(r(t)):n(r)}))}}(i)(Fn.a.polyfill("fetch"))(t,s),p=u.catch((function(e){throw new zn(e)})).then((function(e){return l.clear(),e.ok?e:e[Fn.a.errorType||"text"]().then((function(t){var r=new Error(t);throw r[Fn.a.errorType||"text"]=t,r.status=e.status,r.response=e,r}))})),d=function(t){return t.catch((function(t){l.clear();var r=t instanceof zn?t.error:t;if(t instanceof zn&&a.has("__fromFetch"))return a.get("__fromFetch")(r,e);if(a.has(r.status))return a.get(r.status)(r,e);if(a.has(r.name))return a.get(r.name)(r,e);throw r}))},f=function(e){return function(t){return d(e?p.then((function(t){return t&&t[e]()})).then((function(e){return t?t(e):e})):p.then((function(e){return t?t(e):e})))}},h={res:f(null),json:f("json"),blob:f("blob"),formData:f("formData"),arrayBuffer:f("arrayBuffer"),text:f("text"),perfs:function(e){return u.then((function(t){return Gn.observe(t.url,e)})),h},setTimeout:function(e,t){return void 0===t&&(t=c),l.clear(),l.ref=setTimeout((function(){return t.abort()}),e),h},controller:function(){return[c,h]},error:function(e,t){return a.set(e,t),h},badRequest:function(e){return h.error(400,e)},unauthorized:function(e){return h.error(401,e)},forbidden:function(e){return h.error(403,e)},notFound:function(e){return h.error(404,e)},timeout:function(e){return h.error(408,e)},internalError:function(e){return h.error(500,e)},fetchError:function(e){return h.error("__fromFetch",e)},onAbort:function(e){return h.error("AbortError",e)}};return n.reduce((function(t,r){return r(t,e)}),h)}((n=r?"object"!=typeof r||i&&!Object.entries(i).every((function(e){var t=e[0],r=e[1];return t.toLowerCase()!==Yn.toLowerCase()||r.startsWith(Hn)}))?n.body(r):n.json(r):n)._deferredChain.reduce((function(e,t){return t(e,e._url,e._options)}),n))},e.prototype.get=function(e){return this.method("GET",e)},e.prototype.delete=function(e){return this.method("DELETE",e)},e.prototype.put=function(e,t){return this.method("PUT",t,e)},e.prototype.post=function(e,t){return this.method("POST",t,e)},e.prototype.patch=function(e,t){return this.method("PATCH",t,e)},e.prototype.head=function(e){return this.method("HEAD",e)},e.prototype.opts=function(e){return this.method("OPTIONS",e)},e.prototype.replay=function(e){return this.method(this._options.method,e)},e.prototype.body=function(e){return this.selfFactory({options:Bn(Bn({},this._options),{body:e})})},e.prototype.json=function(e){var t,r=null===(t=Object.entries(this._options.headers||{}).find((function(e){var t=e[0],r=e[1];return t.toLowerCase()===Yn.toLowerCase()&&r.startsWith(Hn)})))||void 0===t?void 0:t[1];return this.content(r||Hn).body(JSON.stringify(e))},e.prototype.formData=function(e,t){return void 0===t&&(t=!1),this.body(function e(t,r,n,i){return void 0===r&&(r=!1),void 0===n&&(n=Fn.a.polyfill("FormData",{instance:!0})),void 0===i&&(i=[]),Object.entries(t).forEach((function(t){var o=t[0],a=t[1],s=i.reduce((function(e,t){return e?e+"["+t+"]":t}),null);if(s=s?s+"["+o+"]":o,a instanceof Array)for(var c=0,l=a;cWe.error(e));const Zn=Jn("https://keys.lime-technology.com").catcher(e=>We.error(e)),ei=Jn("https://wanip4.unraid.net/").catcher(e=>We.error(e)),ti=Jn("/webGui/include/InstallKey.php").catcher(e=>We.error(e)),ri=Jn().catcher(e=>We.error(e)),ni=Jn("/update.php").catcher(e=>We.error(e)),ii=Jn("/webGui/include/UpdateDNS.php").catcher(e=>We.error(e)),oi=Jn("/plugins/dynamix.my.servers/include/unraid-api.php").catcher(e=>We.error(e)),ai=e=>Zn.url("/ips/newaccount").formUrl(e).post(),si=(e,t)=>Zn.url(e).formUrl(t).post(),ci=e=>Zn.url("/ips/validate").formUrl(e).post(),li=e=>Zn.url("/ips/troubleshoot").formUrl(e).post(),ui=e=>Zn.url("/account/server/unregister").formUrl(e).post(),pi=e=>Zn.url("/account/trial").formUrl(e).post(),di=e=>Zn.url("/ips/updateaccount").formUrl(e).post(),fi=e=>Zn.url("/account/license/transfer").formUrl(e).post();let hi=0;const mi=e=>{setTimeout(()=>{ii.formUrl({csrf_token:e}).post().res(e=>We.debug("[WebguiUpdateDns] %o",e)).catch(e=>We.error("[WebguiUpdateDns] %o",e))},500)},gi=e=>{e.preventDefault(),e.returnValue="",alert((void 0).$t("regWizPopUp.closingPopUpMayLeadToErrors"))},vi={openPopUp({commit:e,dispatch:t,state:r},n){if(We.debug("[openPopUp] %o",n||"focus existing pop-up"),r.popUpWindow)return r.popUpWindow.focus();const i=((e,t,r,n)=>{const i=void 0!==window.screenLeft?window.screenLeft:window.screenX,o=void 0!==window.screenTop?window.screenTop:window.screenY,a=window.innerWidth?window.innerWidth:document.documentElement.clientWidth?document.documentElement.clientWidth:window.screen.width,s=window.innerHeight?window.innerHeight:document.documentElement.clientHeight?document.documentElement.clientHeight:window.screen.height,c=a/window.screen.availWidth>1?a/window.screen.availWidth:1,l=(a-r)/2/c+i,u=(s-n)/2/c+o,p=Object.entries({toolbar:"no",location:"yes",status:"no",menubar:"no",scrollbars:"yes",resizable:"yes",width:r/c,height:n/c,top:u,left:l}).reduce((e,t)=>e+`${t[0]}=${t[1]},`,"");return window.open(e,t,p)})(n.url,n.name,n.width,n.height),o=window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches,a=n.url.toString().includes("/preflight")?"#fff":"linear-gradient(to right, #E22828 0%, #ff8c2f 100%)";i.document.body.style.background=o?"#222":a;try{i.focus(),e("CHANGE_POP_UP_WINDOW",i),e("STATE_AT_OPEN",r.registered);const n=setInterval(()=>{r.popUpWindow||clearInterval(n),r.popUpWindow&&r.popUpWindow.closed&&(clearInterval(n),t("resetPopUp",{reloadWebGUI:!1}))},250);return window.onunload=()=>{r.popUpWindow&&!r.popUpWindow.closed&&r.popUpWindow.close()},!0}catch(e){return alert("Pop-up blocker detected.\nTo continue successfully please add this website to your browser's exeception list then refresh.")}},resetPopUp({commit:e,dispatch:t},r={reloadWebGUI:!0}){We.debug("[resetPopUp] %o",r),e("CHANGE_POP_UP_WINDOW",null),t("updateServerState"),r.reloadWebGUI&&t("reloadWebGUI")},closePopUp({dispatch:e,state:t},r={reloadWebGUI:!1}){We.debug("[closePopUp] %o",r),t.popUpWindow&&(t.popUpWindow.close(),e("resetPopUp",{reloadWebGUI:r.reloadWebGUI}))},reloadWebGUI(){We.debug("[reloadWebGUI] %s","✨"),window.location.reload()},closePopUpFromPopUp({dispatch:e}){We.debug("[closePopUpFromPopUp] %o"),e("resetPopUp"),window.close()},sendDataPostMessageToServer({state:e}){const t="SignOut"===e.submissionFrom?{event:"MYSERVERS_UNREGISTER"}:{event:"REG_WIZARD",keyfile:e.keyfile,license:e.license,email:e.userEmail,apikey:e.apikey,avatar:e.avatar,username:e.username,guid:e.guid};We.debug("[sendDataPostMessageToServer] %o",t);try{return Re.postMessage(JSON.stringify(t),e.osGui?"*":e.site)}catch(e){return Ae||We.warn("[sendDataPostMessageToServer] !CAN_POST_MESSAGE",t),We.error("[sendDataPostMessageToServer] %o",e)}},requestUpdatedServerStateFromUpc({state:e}){We.debug("[requestUpdatedServerStateFromUpc]");try{return Re.postMessage(JSON.stringify({event:"SUCCESS_NEW_STATE"}),e.osGui?"*":e.site)}catch(e){return Ae||We.warn("[requestUpdatedServerStateFromUpc] !CAN_POST_MESSAGE",Ae),We.error("[requestUpdatedServerStateFromUpc] %o",e)}},receivePostMessage({commit:e,dispatch:t,getters:r,state:n},i={event:null}){if(!i.event)return void We.error("postMessage no event");We.debug("[receivePostMessage] payload.event %o",i.event);const[o,a]=Ne(i.event.data);if(o)return;We.log("[receivePostMessage] payload.event.data.event %o",a.event);const s=a&&a.event&&["REQUEST_API_REPORT","API_EXECUTE_PINGBACK"].includes(a.event),c=i.event.origin;if(c.includes("extension://"))return void We.log("Skipping postMessage from browser extension",c);const l=c===ge,u=ve.includes(c),p=!!(a&&a.server&&a.server.site)&&c===a.server.site,d=c===n.site,f=!!(a&&a.server&&a.server.extraOrigins)&&a.server.extraOrigins.includes(c),h="SESSION"===a.event?p||f:d,m=s||l||u||h,g={"data.server.extraOrigins":a&&a.server?a.server.extraOrigins:"","data.server.site":a&&a.server?a.server.site:"","payload.event.origin":c,"state.site":n.site,pmOriginMatchesDataServerUrl:p,pmOriginMatchesStateSite:d,pmOriginIncludedInExtraOrigins:f,fromRegWiz:l,fromPurchase:u,fromWebGui:h,acceptDebugEvents:s,originAllowed:m};if(!m)return We.error("[receivePostMessage] ❌ postMessage origin not allowed ❌ %o",g),e("SET_POST_MESSAGE_ERROR",g),void e("SET_RAW_SERVER_STATE",a.server);We.debug("[receivePostMessage] originAllowed %o",g);const v=e=>{try{return We.log("[receivePostMessage.sendBackPostMessage] %o",e.event),i.event.source.postMessage(JSON.stringify(e),n.osGui?"*":c)}catch(t){return We.error("[sendBackPostMessage.catch] %o",{error:t,message:e})}},b=async t=>{if(!t)return We.error("[installKey] missing license data: %s",t);let r=t.split("/");if(r=r[r.length-1].slice(0,-4).toUpperCase(),r===n.state)return v({event:"LICENSE_PINGBACK",message:"Failed to license new key – duplicate install detected",license:t,success:!1}),We.error("[installKey] duplicate install detected",{state:n.state,keyType:r});We.debug("[receivePostMessage.installKey] %o",t);return await ti.query({url:t}).get().res(r=>{We.debug("[receivePostMessage.installKey] SUCCESS %o",r),setTimeout(()=>{mi(n.csrf)},1e3),v({event:"LICENSE_PINGBACK",message:"New license key installed",license:t,success:!0}),e("SET_PIRATE_KEY",!1)}).catch(e=>{We.error("[receivePostMessage.installKey] FAILED: "+t,e),v({event:"LICENSE_PINGBACK",message:"Failed to license new key",license:t,success:!1})})},y=async()=>{We.debug("[receivePostMessage.signOutUnraidNet] 👋");return await ni.formUrl({csrf_token:n.csrf,"#file":r.myServersCfgPath,"#section":"remote",apikey:"",avatar:"",email:"",username:"",wanaccess:"no",...!n.hideMyServers&&{"#command":"/plugins/dynamix.my.servers/scripts/.nginx_reload"}}).post().res(t=>{We.debug("[receivePostMessage.signOutUnraidNet] WebguiUpdate.res %o",t),e("SET_SIGN_OUT_TRIGGERED",!0),v({event:"ACCOUNT_PINGBACK",success:!0,type:"signOut",webGuiPathname:window.location.pathname})}).catch(e=>{We.error(`[receivePostMessage.signOutUnraidNet] WebguiUpdate.catch Sign out ${n.servername} from Unraid.net failed 😢 %o`,e),v({event:"ACCOUNT_PINGBACK",success:!1,type:"signOut",webGuiPathname:window.location.pathname})})};switch(a.event){case"SESSION":We.debug("[receivePostMessage] SESSION"),e("SET_FULL_SERVER_STATE",a.server),e("SET_RAW_SERVER_STATE",a.server),he.mergeLocaleMessage(a.locale,a.messages),he.locale=a.locale,We.debug(`[receivePostMessage] SESSION ${he.locale} locale & messages set`,he.messages);break;case"PREFLIGHT_REQUEST":if(We.debug("[receivePostMessage] PREFLIGHT_REQUEST"),!r.allowedOrigins.includes(c)){We.error("[🙅‍♂️ ACCESS DENIED]");break}try{t("updateServerState").then(e=>{We.debug("[receivePostMessage] PREFLIGHT_REQUEST.updateServerState.then %o",{res:e,"getters.server":r.server}),v({event:"SESSION",server:{...r.server},locale:he.locale,messages:{...he.messages[he.locale]}})}).catch(e=>{We.error("[receivePostMessage] PREFLIGHT_REQUEST.updateServerState.catch %o",e),v({event:"DELIVER_NEW_STATE",success:!1})})}catch(e){We.error("[receivePostMessage] PREFLIGHT_REQUEST.updateServerState.trycatch %o",e),v({event:"DELIVER_NEW_STATE",success:!1})}break;case"LICENSE_PINGBACK":We.debug("[receivePostMessage] LICENSE_PINGBACK"),e("LICENSE_PINGBACK",a);break;case"ACCOUNT_PINGBACK":We.debug("[receivePostMessage] ACCOUNT_PINGBACK"),e("ACCOUNT_PINGBACK",a);break;case"DELIVER_NEW_STATE":We.debug("[receivePostMessage] DELIVER_NEW_STATE %o",a);const i=!!n.license,o=n.licenseAction&&!n.licenseAction.success,s=n.state,l=a&&a.state?a.state:null,u=s===l;if(We.debug("[receivePostMessage] DELIVER_NEW_STATE %o",{keyToInstall:i,failedKeyInstall:o,oldState:s,newState:l,potentiallyStaleState:u,deliverNewStateRetryCounter:hi}),o){e("RECEIVED_SUCCESS_NEW_SERVERSTATE",Date.now());break}if(i&&u&&hi<6){setTimeout(()=>{We.debug("[potentiallyStaleState] %o",{potentiallyStaleState:u}),We.debug("[deliverNewStateRetryCounter] %o",{deliverNewStateRetryCounter:hi}),t("requestUpdatedServerStateFromUpc"),hi+=1},350*hi);break}if(i&&u&&hi>=6){e("SET_APP_ERROR_MESSAGE",`Failed to receive latest server info${n.licenseAction&&n.licenseAction.success?" after successful key install":""}. Please close this pop-up and refresh the webGUI.`),e("RECEIVED_SUCCESS_NEW_SERVERSTATE",Date.now());break}e("SET_FULL_SERVER_STATE",a),e("SET_RAW_SERVER_STATE",a),e("RECEIVED_SUCCESS_NEW_SERVERSTATE",Date.now()),hi=0;break;case"KEY_PURCHASE":We.debug("[receivePostMessage] KEY_PURCHASE"),b(a.license),a.oem&&y();break;case"MYSERVERS_UNREGISTER":We.debug("[receivePostMessage] MYSERVERS_UNREGISTER WebguiUpdate"),y();break;case"REG_WIZARD":We.debug("[receivePostMessage] REG_WIZARD %o",a),a.license&&b(a.license),We.debug("[receivePostMessage] REG_WIZARD WebguiUpdate %o",a),ni.formUrl({csrf_token:n.csrf,"#file":r.myServersCfgPath,"#section":"remote",regWizTime:`${Date.now()}_${a.guid}`,...a.apikey&&{apikey:a.apikey},...a.email&&{email:a.email},...a.username&&{username:a.username},...a.avatar&&{avatar:a.avatar}}).post().res(r=>{We.debug("[receivePostMessage] REG_WIZARD WebguiUpdate.res %o",r),a.license||mi(n.csrf),e("SET_SIGN_OUT_TRIGGERED",!1);let i=0;const o=setInterval(()=>{We.debug("[receivePostMessage] REG_WIZARD WebguiUpdate.res intervalForUpdatedState"),i+=1;try{t("updateServerState").then(e=>{We.debug("[receivePostMessage] REG_WIZARD WebguiUpdate.res intervalForUpdatedState updatedState %o",{updatedState:e,countIntervalRuns:i}),(!n.hideMyServers&&e.avatar&&e.username&&"root"!==e.username||n.hideMyServers&&i>=4)&&(clearInterval(o),v({event:"ACCOUNT_PINGBACK",success:!0,type:"signIn",webGuiPathname:window.location.pathname,res:e}))}).catch(e=>{We.error("[receivePostMessage] REG_WIZARD WebguiUpdate.re intervalForUpdatedState error %o",{error:e,countIntervalRuns:i}),clearInterval(o),v({event:"ACCOUNT_PINGBACK",success:!1,type:"signIn",webGuiPathname:window.location.pathname})})}catch(e){We.error("[receivePostMessage] REG_WIZARD WebguiUpdate catchError %o",{catchError:e,countIntervalRuns:i}),clearInterval(o),v({event:"ACCOUNT_PINGBACK",success:!1,type:"signIn",webGuiPathname:window.location.pathname})}},250)}).catch(e=>{We.error("[WebguiUpdate] %o",e),v({event:"ACCOUNT_PINGBACK",success:!1,type:"signIn",webGuiPathname:window.location.pathname})});break;case"RELOAD":We.debug("[receivePostMessage] RELOAD"),window.location.reload();break;case"SUCCESS_NEW_STATE":We.debug("[receivePostMessage] SUCCESS_NEW_STATE");try{t("updateServerState").then(e=>{We.debug("[receivePostMessage] SUCCESS_NEW_STATE.updateServerState.then"),v({...e,event:"DELIVER_NEW_STATE",success:!0})}).catch(e=>{We.error("[receivePostMessage] SUCCESS_NEW_STATE.updateServerState.catch %o",e),v({event:"DELIVER_NEW_STATE",success:!1})})}catch(e){We.error("[receivePostMessage] SUCCESS_NEW_STATE.updateServerState.trycatch %o",e),v({event:"DELIVER_NEW_STATE",success:!1})}break;case"REDIRECT_MAIN":We.debug("[receivePostMessage] REDIRECT_MAIN"),window.location.href="/Main";break;case"REQUEST_API_REPORT":const p=n.apiVersion&&qe()(n.apiVersion,"2.43.3")?"-vv":"-v";We.debug("[receivePostMessage] REQUEST_API_REPORT %o",{apiVersion:n.apiVersion,param1:p});try{oi.formUrl({csrf_token:n.csrf,command:"report",param1:p}).post().json(t=>{We.debug("👼 [receivePostMessage] REQUEST_API_REPORT WebguiUnraidApiCommand.json %o",t),e("SET_API_EXECUTE_RESPONSE",t.result),v({event:"API_EXECUTE_PINGBACK",result:t.result})}).catch(e=>{We.error("[receivePostMessage] REQUEST_API_REPORT WebguiUnraidApiCommand.catch failed to execute `unraid-api` report 😢 %o",e),v({event:"API_EXECUTE_PINGBACK",error:e})})}catch(e){We.error("[receivePostMessage] REQUEST_API_REPORT WebguiUnraidApiCommand.catch failed to execute `unraid-api` report 😢 %o",e),v({event:"API_EXECUTE_PINGBACK",error:e})}break;case"API_EXECUTE_PINGBACK":We.debug("[receivePostMessage] API_EXECUTE_PINGBACK"),a&&a.result&&e("SET_API_EXECUTE_RESPONSE",a.result);break;case"YARG_MATEY":We.debug("[receivePostMessage] YARG_MATEY"),e("SET_PIRATE_KEY",a.ts);break;default:We.debug("[receivePostMessage] UNHANDLED_MESSAGE")}},setStateFromWebComponentProp({commit:e},t){We.debug("[setStateFromWebComponentProp]");const[r,n]=Ne(decodeURIComponent(t));return r?We.error("[setStateFromWebComponentProp] %o",t):e("SET_FULL_SERVER_STATE",n)},async updateServerState({commit:e,dispatch:t,getters:r,state:n}){if(We.debug("[updateServerState]"),ge===window.location.origin)return We.debug("[SKIPPED] updateServerState()");We.debug("[updateServerState]",{"state.signOutTriggered":n.signOutTriggered,"state.hideMyServers":n.hideMyServers,"!state.graphOnline":!n.graphOnline,"!getters.validApiKeyLength":!r.validApiKeyLength,"!getters.validApiKeyForUpc":!r.validApiKeyForUpc}),!n.signOutTriggered&&!n.hideMyServers&&n.graphOnline&&r.validApiKeyLength&&r.validApiKeyForUpc?(We.debug("[updateServerState] via serverStateFromApi"),await t("serverStateFromApi")):(We.debug("[updateServerState] via ",r.statePhpPath),await ri.url(r.statePhpPath).get().json().then(t=>t?e("SET_FULL_SERVER_STATE",t):We.error("[updateUpcFromStatePhp] no `res` skipping `SET_FULL_SERVER_STATE`")).catch(e=>{We.error("[updateUpcFromStatePhp WebguiState.catch] %o",e),(e.toString().includes("Unexpected token")||e.toString().includes("503"))&&(window.location.href="/")}));const i=r.server;return We.debug("[updateServerState] newState %o",i),i},async validateGuid({commit:e,getters:t,state:r}){await new Promise((n,i)=>{if(r.guidValidationRunning)return We.debug("[validateGuid] already validating");e("CHANGE_GUID_VALIDATION_RUNNING",!0);const o=r.regWizTime?r.regWizTime.split("_")[1]:null,a=!!o&&o===r.guid;We.debug("[validateGuid] %o",{guid:r.guid,regGuid:r.regGuid,regWizTimeGuid:o,previouslyRegistered:a});let s="GUID Invalid";if(!r.guid||r.guid===Ie)return We.debug(`[validateGuid] ${s} %o`,{"!state.guid":!r.guid,GUID_NOT_RECEIVED:Ie}),s+=": not present",e("CHANGE_GUID_VALID",!1),e("CHANGE_REPLACEABLE",!1),e("SET_STATE","EBLACKLISTED1"),e("SET_APP_ERROR_MESSAGE",s),e("CHANGE_GUID_VALIDATION_RUNNING",!1),e("SET_LOADING_STATE",!1),n(!1);if(a&&!t.stateData.error)return We.debug("[validateGuid] previouslyRegistered %s",r.guid),e("CHANGE_GUID_REGISTERED",!0),e("CHANGE_GUID_VALID",!0),e("CHANGE_GUID_FORUMACCOUNT",!0),e("CHANGE_GUID_VALIDATION_RUNNING",!1),e("SET_LOADING_STATE",!1),n(!0);const c=r.guid.includes("000000000000");if(r.guid&&r.guid!==Ie&&(c||27!==r.guid.length))return c?(s+=": Too many consecutive zeros",e("SET_STATE","EBLACKLISTED2")):(s+=": Not long enough",e("SET_STATE","EBLACKLISTED1")),e("CHANGE_GUID_VALID",!1),e("CHANGE_REPLACEABLE",!1),e("SET_APP_ERROR_MESSAGE",s),e("CHANGE_GUID_VALIDATION_RUNNING",!1),e("SET_LOADING_STATE",!1),i(new Error(s));r.regGuid||We.warn("[validateGuid] state.regGuid empty. Getting regGuid from state.regWizTime.");const l=r.regGuid||o||"";e("CHANGE_GUID_FOR_VALIDATION","EGUID"===r.state?l:r.guid),e("CHANGE_GUID_BLACKLISTED",null);try{const t=Zn.url("/validate/guid").formUrl({guid:r.guidForValidation}).post().forbidden(t=>{let n;const[i,o]=Ne(t.message);o&&!i||!t.message||(n=t.message),o&&o.error&&(n=o.error),We.error("[validateGuid] POST.forbidden %o",n),n.includes("blacklisted")?(e("CHANGE_GUID_BLACKLISTED",!0),"EGUID"!==r.state?(e("SET_STATE","EBLACKLISTED"),e("SET_APP_ERROR_MESSAGE",n)):We.warn("[validateGuid] skip EBLACKLISTED state overwrite")):n.includes("invalid GUID")&&("EGUID"!==r.state?(e("SET_STATE","EBLACKLISTED1"),e("SET_APP_ERROR_MESSAGE",n)):We.warn("[validateGuid] skip EBLACKLISTED state overwrite")),e("CHANGE_GUID_VALID",!1),e("CHANGE_REPLACEABLE",!1)}).json(t=>{We.debug("[validateGuid] POST.json %o",t),t.registered&&e("CHANGE_GUID_REGISTERED",t.registered),e("CHANGE_GUID_FORUMACCOUNT",t.forumaccount||!1),e("CHANGE_GUID_VALID",!0),e("CHANGE_REPLACEABLE",t.replaceable)}).catch(t=>{We.error("[validateGuid] POST.catch %o",t),e("SET_APP_ERROR_MESSAGE",t.message),i(new Error(t))}).finally(()=>{We.debug("[validateGuid] POST.finally"),e("CHANGE_GUID_VALIDATION_RUNNING",!1),e("SET_LOADING_STATE",!1)});return n(t)}catch(t){return We.error("[validateGuid] try/catch %o",t),e("SET_APP_ERROR_MESSAGE",t),e("CHANGE_GUID_VALIDATION_RUNNING",!1),i(new Error(t))}})},async startTrial({commit:e,dispatch:t,state:r}){We.debug("[startTrial]"),e("SET_LOADING_STATE","Fetching trial…"),window.addEventListener("beforeunload",gi),r.isLaunchpadOpen||e("SET_IS_LAUNCHPAD_OPEN",!1),await i.startTrial({timestamp:Math.floor((new Date).getTime()/1e3),guid:r.guid}).json().then(n=>{e("SET_LOADING_STATE","Installing trial…"),ti.query({url:n.license}).get().res(n=>{We.debug("[KeyServer.startTrial.WebguiInstallKey] SUCCESS %o",n),setTimeout(()=>{e("SET_LOADING_STATE","Verifying trial install…"),t("openPopUp",r.trialWindow),r.popUpWindow&&r.popUpWindow.blur(),window.focus(),setTimeout(()=>{e("SET_LOADING_STATE","Reloading webgui…"),sessionStorage.setItem("showPromoPostTrialInstall",Date.now()),e("SET_PIRATE_KEY",!1),window.removeEventListener("beforeunload",gi),window.location.reload()},4e3)},1500)}).catch(t=>{We.error("[KeyServer.startTrial.WebguiInstallKey.catch] FAILED: "+n,t);const[r,i]=Ne(t.message);e("SET_APP_ERROR_MESSAGE",i?i.errorMessage?i.errorMessage:i.error:t),e("SET_LOADING_STATE",!1)})}).catch(t=>{We.error("[KeyServer.startTrial.catch] FAILED",t);const[r,n]=Ne(t.message);e("SET_APP_ERROR_MESSAGE",n?n.errorMessage?n.errorMessage:n.error:t),e("SET_LOADING_STATE",!1)})},togglePromo({commit:e,state:t}){We.debug("[togglePromo]");const r="unraid-promo";if(!document.getElementsByTagName(r).length){const e=document.getElementsByTagName("body")[0],t=document.createElement(r);e.appendChild(t)}e("SET_IS_LAUNCHPAD_OPEN",!1),e("SET_IS_PROMO_OPEN",!t.isPromoOpen)},jumpToUpc({commit:e}){window.scrollTo({top:0,behavior:"smooth"}),e("TRIGGER_UPC",!0),setTimeout(()=>{e("TRIGGER_UPC",!1)},500)},async getWanIp({commit:e,state:t}){if(We.debug("[getWanIp]"),t.wanip)return We.debug("[getWanIp] SKIPPED",t.wanip);try{return e("SET_WANIP",await ei.get().text())}catch(e){return We.error("[getWanIp] Unable to get WAN IP")}},async executeUnraidApi({commit:e,state:t},r={command:"",param1:null}){We.debug("[executeUnraidApi]",r);const{command:n,param1:i}=r;"start"===n&&e("SET_MY_SERVERS_LOADING",!0);return await oi.formUrl({csrf_token:t.csrf,command:n,param1:i}).post().json(e=>{We.debug("👼 [executeUnraidApi] json %o",e)}).catch(e=>{We.error(`[executeUnraidApi] catch failed to execute unraid-api ${n} 😢 %o`,e)})},fetchServers:async e=>{We.debug("[fetchServers]"),e.commit("SET_MY_SERVERS_LOADING",!0);const t=await Mn(e).query({query:Nt`query initialGetServers { servers { name guid @@ -41,7 +41,7 @@ function(e){if(Number(e.version.split(".")[0])>=2)e.mixin({beforeCreate:r});else username } } - }`});Be.debug("[fetchServers] response %o",t);const{data:r}=t;r&&(r.servers.length>1&&e.dispatch("getWanIp"),e.commit("SET_GRAPH_ONLINE",!0),e.commit("SET_MY_SERVERS",r.servers),e.commit("SET_MY_SERVERS_LOADING",!1)),Be.debug("[fetchServers] getServers subscription %o",{skip:e.state.graphReconnected}),e.state.graphReconnected||Nn(e).subscribe({query:Pt`subscription getServers { + }`});We.debug("[fetchServers] response %o",t);const{data:r}=t;r&&(r.servers.length>1&&e.dispatch("getWanIp"),e.commit("SET_GRAPH_ONLINE",!0),e.commit("SET_MY_SERVERS",r.servers),e.commit("SET_MY_SERVERS_LOADING",!1)),We.debug("[fetchServers] getServers subscription %o",{skip:e.state.graphReconnected}),e.state.graphReconnected||Mn(e).subscribe({query:Nt`subscription getServers { servers { name guid @@ -56,7 +56,7 @@ function(e){if(Number(e.version.split(".")[0])>=2)e.mixin({beforeCreate:r});else username } } - }`}).subscribe({next(t){Be.debug("[new subscription data] %o",t),e.state.graphOnline||e.commit("SET_GRAPH_ONLINE",!0),e.commit("SET_MY_SERVERS",t.data.servers),e.commit("SET_MY_SERVERS_LOADING",!1)},error:t=>(e.commit("SET_MY_SERVERS_ERROR",t),e.state.myServersError)})},serverStateFromApi:async e=>{Be.debug("[serverStateFromApi] %o",{apiVersion:e.state.apiVersion,">=2.41.1":Ye()(e.state.apiVersion,"2.41.1"),">=2.35.0":Ye()(e.state.apiVersion,"2.35.0"),">2.27.0":Mt()(e.state.apiVersion,"2.27.0"),"<=2.27.0":Ut()(e.state.apiVersion,"2.27.0")});const t=Pt`query serverState { + }`}).subscribe({next(t){We.debug("[new subscription data] %o",t),e.state.graphOnline||e.commit("SET_GRAPH_ONLINE",!0),e.commit("SET_MY_SERVERS",t.data.servers),e.commit("SET_MY_SERVERS_LOADING",!1)},error:t=>(e.commit("SET_MY_SERVERS_ERROR",t),e.state.myServersError)})},serverStateFromApi:async e=>{We.debug("[serverStateFromApi] %o",{apiVersion:e.state.apiVersion,">=2.41.1":qe()(e.state.apiVersion,"2.41.1"),">=2.35.0":qe()(e.state.apiVersion,"2.35.0"),">2.27.0":Dt()(e.state.apiVersion,"2.27.0"),"<=2.27.0":Lt()(e.state.apiVersion,"2.27.0")});const t=Nt`query serverState { owner { username avatar @@ -72,7 +72,7 @@ function(e){if(Number(e.version.split(".")[0])>=2)e.mixin({beforeCreate:r});else product } registration { - ${Ye()(e.state.apiVersion,"2.35.0")?"expiration":""} + ${qe()(e.state.apiVersion,"2.35.0")?"expiration":""} keyFile { contents } @@ -81,36 +81,36 @@ function(e){if(Number(e.version.split(".")[0])>=2)e.mixin({beforeCreate:r});else vars { regGen regState - ${Ut()(e.state.apiVersion,"2.27.0")?"configError":""} - ${Ut()(e.state.apiVersion,"2.27.0")?"configValid":""} + ${Lt()(e.state.apiVersion,"2.27.0")?"configError":""} + ${Lt()(e.state.apiVersion,"2.27.0")?"configValid":""} } - ${Mt()(e.state.apiVersion,"2.27.0")?"config { error valid }":""} - ${Ye()(e.state.apiVersion,"2.41.1")?`\n cloud {\n error\n apiKey {\n valid\n error\n }\n relay {\n status\n error\n }\n ${Ye()(e.state.apiVersion,"2.48.0")?"cloud { status error }":"mothership { status error }"}\n }`:""} - }`,r=await Nn(e).query({errorPolicy:"all",query:t});return Be.debug("[🪐 serverStateFromApi] response %o",r,e),Ye()(e.state.apiVersion,"2.41.1")&&e.state.cloud&&e.state.cloud.error&&e.commit("SET_MY_SERVERS_ERROR_SHOW_SUPPORT_BTN",!0),e.commit("SET_MY_SERVERS_LOADING",!1),e.commit("SET_FULL_SERVER_STATE",((e,t)=>{const{data:r}=t;if(!r)return Be.error("[🪐 serverStateFromApi] response %o",t);const n={...r.owner&&"root"!==r.owner.username&&{avatar:r.owner.avatar,username:r.owner.username,registered:!0},...e.state.signOutTriggered&&{username:"",avatar:"",registered:!1},servername:r.info&&r.info.os?r.info.os.hostname:null,guid:r.flash?r.flash.guid:null,keyfile:r.registration&&r.registration.keyFile?r.registration.keyFile.contents:null,flashProduct:r.flash?r.flash.product:null,flashvendor:r.flash?r.flash.vendor:null,sendCrashInfo:r.crashReportingEnabled,reggen:r.vars?r.vars.regGen:null,state:r.vars?r.vars.regState:null,config:r.config?r.config:{error:r.vars?r.vars.configError:null,valid:!r.vars||r.vars.configValid},expiretime:r.registration&&r.registration.expiration?r.registration.expiration:0,...r.cloud&&{cloud:r.cloud}};return Be.debug("[🪐 serverStateFromApi] mutated response %o",n),n})(e,r)),Mn(e,r),Be.debug("[🪐 serverStateFromApi] subscriptions %o",{skip:e.state.graphReconnected}),e.state.graphReconnected||(Be.debug("[🪐 serverStateFromApi] serverVarsSub"),Nn(e).subscribe({query:Pt`subscription serverVarsSub { + ${Dt()(e.state.apiVersion,"2.27.0")?"config { error valid }":""} + ${qe()(e.state.apiVersion,"2.41.1")?`\n cloud {\n error\n apiKey {\n valid\n error\n }\n relay {\n status\n error\n }\n ${qe()(e.state.apiVersion,"2.48.0")?"cloud { status error }":"mothership { status error }"}\n }`:""} + }`,r=await Mn(e).query({errorPolicy:"all",query:t});return We.debug("[🪐 serverStateFromApi] response %o",r,e),qe()(e.state.apiVersion,"2.41.1")&&e.state.cloud&&e.state.cloud.error&&e.commit("SET_MY_SERVERS_ERROR_SHOW_SUPPORT_BTN",!0),e.commit("SET_MY_SERVERS_LOADING",!1),e.commit("SET_FULL_SERVER_STATE",((e,t)=>{const{data:r}=t;if(!r)return We.error("[🪐 serverStateFromApi] response %o",t);const n={...r.owner&&"root"!==r.owner.username&&{avatar:r.owner.avatar,username:r.owner.username,registered:!0},...e.state.signOutTriggered&&{username:"",avatar:"",registered:!1},servername:r.info&&r.info.os?r.info.os.hostname:null,guid:r.flash?r.flash.guid:null,keyfile:r.registration&&r.registration.keyFile?r.registration.keyFile.contents:null,flashProduct:r.flash?r.flash.product:null,flashvendor:r.flash?r.flash.vendor:null,sendCrashInfo:r.crashReportingEnabled,reggen:r.vars?r.vars.regGen:null,state:r.vars?r.vars.regState:null,config:r.config?r.config:{error:r.vars?r.vars.configError:null,valid:!r.vars||r.vars.configValid},expiretime:r.registration&&r.registration.expiration?r.registration.expiration:0,...r.cloud&&{cloud:r.cloud}};return We.debug("[🪐 serverStateFromApi] mutated response %o",n),n})(e,r)),Dn(e,r),We.debug("[🪐 serverStateFromApi] subscriptions %o",{skip:e.state.graphReconnected}),e.state.graphReconnected||(We.debug("[🪐 serverStateFromApi] serverVarsSub"),Mn(e).subscribe({query:Nt`subscription serverVarsSub { vars { regGen regState - ${Ut()(e.state.apiVersion,"2.27.0")?"configError":""} - ${Ut()(e.state.apiVersion,"2.27.0")?"configValid":""} + ${Lt()(e.state.apiVersion,"2.27.0")?"configError":""} + ${Lt()(e.state.apiVersion,"2.27.0")?"configValid":""} } - }`}).subscribe({next(t){Be.debug("[🪐 serverStateFromApi] serverVarsSub res %o",t),e.commit("SET_STATE",t.data.vars.regState)},error:t=>(e.commit("SET_MY_SERVERS_ERROR",t),e.state.myServersError)}),Be.debug("[🪐 serverStateFromApi] serverOwnerSub"),Nn(e).subscribe({query:Pt`subscription serverOwnerSub { + }`}).subscribe({next(t){We.debug("[🪐 serverStateFromApi] serverVarsSub res %o",t),e.commit("SET_STATE",t.data.vars.regState)},error:t=>(e.commit("SET_MY_SERVERS_ERROR",t),e.state.myServersError)}),We.debug("[🪐 serverStateFromApi] serverOwnerSub"),Mn(e).subscribe({query:Nt`subscription serverOwnerSub { owner { username avatar } - }`}).subscribe({next(t){Be.debug("[🪐 serverStateFromApi] serverOwnerSub res %o",t),Mn(e,t),t&&t.data&&t.data.owner&&"root"!==t.data.owner.username&&e.commit("SET_OWNER",t.data.owner)},error:t=>(e.commit("SET_MY_SERVERS_ERROR",t),e.state.myServersError)}),Mt()(e.state.apiVersion,"2.27.0")&&(Be.debug("[🪐 serverStateFromApi] serverConfigSub"),Nn(e).subscribe({query:Pt`subscription serverConfigSub { + }`}).subscribe({next(t){We.debug("[🪐 serverStateFromApi] serverOwnerSub res %o",t),Dn(e,t),t&&t.data&&t.data.owner&&"root"!==t.data.owner.username&&e.commit("SET_OWNER",t.data.owner)},error:t=>(e.commit("SET_MY_SERVERS_ERROR",t),e.state.myServersError)}),Dt()(e.state.apiVersion,"2.27.0")&&(We.debug("[🪐 serverStateFromApi] serverConfigSub"),Mn(e).subscribe({query:Nt`subscription serverConfigSub { config { error valid } - }`}).subscribe({next(t){Be.debug("[🪐 serverStateFromApi] serverConfigSub res %o",t),e.commit("SET_CONFIG",t.data.config)},error:t=>(e.commit("SET_MY_SERVERS_ERROR",t),e.state.myServersError)}),Be.debug("[🪐 serverStateFromApi] serverRegistrationSub"),Nn(e).subscribe({query:Pt`subscription serverRegistrationSub { + }`}).subscribe({next(t){We.debug("[🪐 serverStateFromApi] serverConfigSub res %o",t),e.commit("SET_CONFIG",t.data.config)},error:t=>(e.commit("SET_MY_SERVERS_ERROR",t),e.state.myServersError)}),We.debug("[🪐 serverStateFromApi] serverRegistrationSub"),Mn(e).subscribe({query:Nt`subscription serverRegistrationSub { registration { - ${Ye()(e.state.apiVersion,"2.35.0")?"expiration":""} + ${qe()(e.state.apiVersion,"2.35.0")?"expiration":""} keyFile { contents } } - }`}).subscribe({next(t){Be.debug("[🪐 serverStateFromApi] serverRegistrationSub res %o",t),e.commit("SET_REGISTRATION_SUB",t.data.registration)},error:t=>(e.commit("SET_MY_SERVERS_ERROR",t),e.state.myServersError)}))),Be.debug("[🪐 serverStateFromApi] DONE %o",r.data),r.data},stopGraphqlClient:(e,t)=>(Be.debug("[stopGraphqlClient] clients %o",{clients:Cn,apikey:t}),Object.keys(Cn).includes(t)?(Be.debug("[stopGraphqlClient] found existing client & stopping it %o",Cn[t]),Cn[t].stop()):Be.debug("[stopGraphqlClient] client does not exist for apikey %o",t))};o.default.use(b.a),o.default.config.devtools=!0;var vi=new b.a.Store({state:_e,getters:Fe,mutations:We,actions:gi});var bi=v({i18n:he,store:vi,name:"Authed",props:["propRegistered"],data:()=>({regChanged:!1,popUpClosedTimer:null}),computed:{...Object(b.e)(["state","registered","isPopUpOpen","signOutPayload","wizardWindow"]),...Object(b.c)(["stateData"]),computedReg(){return null===this.registered?!!this.propRegistered:this.registered},buttonPayload(){return this.stateData.error?this.wizardWindow:this.computedReg?this.signOutPayload:this.wizardWindow},buttonText(){return this.stateData.error?this.$t("fixError"):this.isPopUpOpen?this.$t("backToPopUp"):"ENOKEYFILE"===this.state?this.$t("getStarted"):this.computedReg?this.$t("signOut"):this.$t("signIn")},buttonTitle(){return this.$t("upc.opensNewHttpsWindow.base",[this.buttonText])}},watch:{isPopUpOpen(e){!e&&this.regChanged&&(Be.debug("[REGISTERED CHANGED] 🔥 reload webGUI settings"),window.location.reload())},registered(e,t){null!==t&&e!==this.propRegistered&&(Be.debug("[REGISTERED CHANGED]",{newVal:e,oldVal:t}),this.regChanged=!0,this.isPopUpOpen||(Be.debug("[REGISTERED CHANGED] 🔥🔥 reload webGUI settings"),window.location.reload()))}},methods:{...Object(b.b)(["closePopUp","openPopUp"])}},(function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("transition",{attrs:{appear:"",name:"fade",mode:"out-in"}},[r("div",[r("button",{attrs:{type:"button",title:e.buttonTitle},on:{click:function(t){return e.openPopUp(e.buttonPayload)}}},[e._v(e._s(e.buttonText))]),r("transition",{attrs:{name:"fade",mode:"out-in"}},[e.isPopUpOpen?r("button",{staticClass:"ml-8px",attrs:{type:"button"},on:{click:function(t){return e.closePopUp()}}},[e._v(e._s(e.$t("closePopUp")))]):e._e()])],1)])}),[],!1,(function(e){var t=r("dfd4");t.__inject__&&t.__inject__(e)}),"5e5ba4da",null,!0).exports,yi=(v({name:"keyline",props:{color:{type:String,default:"grey"}},computed:{computedClass(){return"gradient"===this.color?"h-2px bg-gradient-r-red-orange":"h-1px bg-grey"}}},(function(){var e=this,t=e.$createElement;return(e._self._c||t)("hr",{staticClass:"w-full shadow-none border-none rounded-none",class:e.computedClass})}),[],!1,null,null,null,!0).exports,function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("svg",{staticClass:"unraid_sc_loader",style:e.styles,attrs:{xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink",viewBox:"0 0 133.52 76.97",height:e.height+"px",role:"img"}},[r("title",[e._v(e._s(e.title))]),r("desc",[e._v("Unraid logo animating with a wave like effect")]),r("defs",[r("linearGradient",{attrs:{id:e.random,x1:"23.76",y1:"81.49",x2:"109.76",y2:"-4.51",gradientUnits:"userSpaceOnUse"}},[r("stop",{attrs:{offset:"0","stop-color":e.gradientStart}}),r("stop",{attrs:{offset:"1","stop-color":e.gradientStop}})],1)],1),r("path",{staticClass:"unraid_sc_loader_9",attrs:{d:"m70,19.24zm57,0l6.54,0l0,38.49l-6.54,0l0,-38.49z",fill:"url(#"+e.random+")"}}),r("path",{staticClass:"unraid_sc_loader_8",attrs:{d:"m70,19.24zm47.65,11.9l-6.55,0l0,-23.79l6.55,0l0,23.79z",fill:"url(#"+e.random+")"}}),r("path",{staticClass:"unraid_sc_loader_7",attrs:{d:"m70,19.24zm31.77,-4.54l-6.54,0l0,-14.7l6.54,0l0,14.7z",fill:"url(#"+e.random+")"}}),r("path",{staticClass:"unraid_sc_loader_6",attrs:{d:"m70,19.24zm15.9,11.9l-6.54,0l0,-23.79l6.54,0l0,23.79z",fill:"url(#"+e.random+")"}}),r("path",{staticClass:"unraid_sc_loader_5",attrs:{d:"m63.49,19.24l6.51,0l0,38.49l-6.51,0l0,-38.49z",fill:"url(#"+e.random+")"}}),r("path",{staticClass:"unraid_sc_loader_4",attrs:{d:"m70,19.24zm-22.38,26.6l6.54,0l0,23.78l-6.54,0l0,-23.78z",fill:"url(#"+e.random+")"}}),r("path",{staticClass:"unraid_sc_loader_3",attrs:{d:"m70,19.24zm-38.26,43.03l6.55,0l0,14.73l-6.55,0l0,-14.73z",fill:"url(#"+e.random+")"}}),r("path",{staticClass:"unraid_sc_loader_2",attrs:{d:"m70,19.24zm-54.13,26.6l6.54,0l0,23.78l-6.54,0l0,-23.78z",fill:"url(#"+e.random+")"}}),r("path",{staticClass:"unraid_sc_loader_1",attrs:{d:"m70,19.24zm-63.46,38.49l-6.54,0l0,-38.49l6.54,0l0,38.49z",fill:"url(#"+e.random+")"}})])});var wi=v({name:"loading",props:{height:{type:Number,default:64},styles:{type:Object,default:()=>({})},gradientStart:{type:String,default:"#e32929"},gradientStop:{type:String,default:"#ff8d30"},title:{type:String,default:"Loading"}},data:()=>({random:Math.random().toString(36).substring(7)})},yi,[],!1,(function(e){var t=r("ef7a");t.__inject__&&t.__inject__(e)}),null,null,!0).exports,xi=(v({name:"logo",props:{gradientStart:{type:String,default:"#e32929"},gradientStop:{type:String,default:"#ff8d30"}},data:()=>({random:Math.random().toString(36).substring(7)})},(function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("svg",{attrs:{xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink",viewBox:"0 0 222.36 39.04"}},[r("defs",[r("linearGradient",{attrs:{id:e.random,x1:"47.53",y1:"79.1",x2:"170.71",y2:"-44.08",gradientUnits:"userSpaceOnUse"}},[r("stop",{attrs:{offset:"0","stop-color":e.gradientStart}}),r("stop",{attrs:{offset:"1","stop-color":e.gradientStop}})],1)],1),r("title",[e._v("Unraid Logo")]),r("path",{attrs:{d:"M146.7,29.47H135l-3,9h-6.49L138.93,0h8l13.41,38.49h-7.09L142.62,6.93l-5.83,16.88h8ZM29.69,0V25.4c0,8.91-5.77,13.64-14.9,13.64S0,34.31,0,25.4V0H6.54V25.4c0,5.17,3.19,7.92,8.25,7.92s8.36-2.75,8.36-7.92V0ZM50.86,12v26.5H44.31V0h6.11l17,26.5V0H74V38.49H67.9ZM171.29,0h6.54V38.49h-6.54Zm51.07,24.69c0,9-5.88,13.8-15.17,13.8H192.67V0H207.3c9.18,0,15.06,4.78,15.06,13.8ZM215.82,13.8c0-5.28-3.3-8.14-8.52-8.14h-8.08V32.77h8c5.33,0,8.63-2.8,8.63-8.08ZM108.31,23.92c4.34-1.6,6.93-5.28,6.93-11.55C115.24,3.68,110.18,0,102.48,0H88.84V38.49h6.55V5.66h6.87c3.8,0,6.21,1.82,6.21,6.71s-2.41,6.76-6.21,6.76H98.88l9.21,19.36h7.53Z",fill:"url(#"+e.random+")"}})])}),[],!1,null,null,null,!0).exports,function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("svg",{attrs:{xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink",viewBox:"0 0 133.52 76.97"}},[r("title",[e._v("unraid-mark")]),r("defs",[r("linearGradient",{attrs:{id:e.random,x1:"23.76",y1:"81.49",x2:"109.76",y2:"-4.51",gradientUnits:"userSpaceOnUse"}},[r("stop",{attrs:{offset:"0","stop-color":e.gradientStart}}),r("stop",{attrs:{offset:"1","stop-color":e.gradientStop}})],1)],1),r("path",{attrs:{fill:"url(#"+e.random+")",d:"M63.49,19.24H70V57.73H63.49ZM6.54,57.73H0V19.24H6.54Zm25.2,4.54h6.55V77H31.74ZM15.87,45.84h6.54V69.62H15.87Zm31.75,0h6.54V69.62H47.62ZM127,19.24h6.54V57.73H127ZM101.77,14.7H95.23V0h6.54Zm15.88,16.44H111.1V7.35h6.55Zm-31.75,0H79.36V7.35H85.9Z"}})])}),_i=v({name:"logo",props:{gradientStart:{type:String,default:"#e32929"},gradientStop:{type:String,default:"#ff8d30"}},data:()=>({random:Math.random().toString(36).substring(7)})},xi,[],!1,null,null,null,!0).exports,Ei=r("5d74"),Si=r.n(Ei);o.default.use(Si.a,{url:(Object({VUE_APP_REGWIZ_URL:"https://registration.unraid.net",VUE_APP_PURCHASE_URL:"https://unraid.net/preflight",VUE_APP_MIN_API_VER:"2.49.2",VUE_APP_REC_API_VER:"2.52.1",VUE_APP_MIN_OS_VER:"6.10.0",VUE_APP_REC_OS_VER:"6.11.0",NODE_ENV:"production",BASE_URL:"/"}).VUE_APP_SPRITE_URL_PREFIX?Object({VUE_APP_REGWIZ_URL:"https://registration.unraid.net",VUE_APP_PURCHASE_URL:"https://unraid.net/preflight",VUE_APP_MIN_API_VER:"2.49.2",VUE_APP_REC_API_VER:"2.52.1",VUE_APP_MIN_OS_VER:"6.10.0",VUE_APP_REC_OS_VER:"6.11.0",NODE_ENV:"production",BASE_URL:"/"}).VUE_APP_SPRITE_URL_PREFIX:"")+"/assets/svg/sprite.svg",class:"svg-icon"});var ki=(v({name:"svg-icon",props:{symbol:{type:String,required:!0},symbolClass:String}},(function(){var e=this,t=e.$createElement;return(e._self._c||t)("svg",{directives:[{name:"svg",rawName:"v-svg"}],staticClass:"unraid-svg-icon",class:e.symbolClass,attrs:{symbol:e.symbol,title:e.symbol,role:"presentation"}})}),[],!1,(function(e){var t=r("39a1");t.__inject__&&t.__inject__(e)}),"3b60bb54",null,!0).exports,function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("div",{staticClass:"text-center w-full"},[r("header",[r("h2",{staticClass:"text-24px md:text-30px"},[r("span",{domProps:{innerHTML:e._s(e.computedHeading)}}),e.showTrialWelcome?r("ui-beta",{staticClass:"title-beta relative ml-4px"}):e._e()],1),r("div",{staticClass:"text-14px opacity-90 mt-12px mx-auto prose",class:{"text-center":e.stateData.messageCenter||e.showTrialWelcome,"text-left":!e.stateData.messageCenter}},[r("div",{domProps:{innerHTML:e._s(e.computedSubheading)}}),e.showExpiretime?r("HelperTimeConvert",{staticClass:"italic text-center font-semibold mt-16px"}):e._e()],1)]),r("div",{staticClass:"ActionRequired flex flex-col justify-center mt-16px"},[e.isPopUpOpen?[r("UiButton",{staticClass:"button button-alt w-full mt-8px",attrs:{text:e.$t("backToPopUp")},on:{"btn-click":function(t){return e.openPopUp(e.signInPayload)}}}),r("UiButton",{staticClass:"button-fine-error text-grey-mid w-full mt-8px",attrs:{text:e.$t("closePopUp")},on:{"btn-click":function(t){return e.closePopUp()}}})]:[(!e.hideMyServers||e.apiVersion&&"0.0.0"!==e.apiVersion)&&e.stateData.actions.includes("register")?[r("UiButton",{staticClass:"button button-alt w-full mt-8px",attrs:{routeName:e.CAN_POST_MESSAGE?"SignIn":null,text:e.$t("signIn")},on:{"btn-click":function(t){return e.openPopUp(e.signInPayload)}}}),e.guidRegistered||e.forumaccount?e._e():r("UiButton",{staticClass:"button button-alt w-full mt-8px",attrs:{routeName:e.CAN_POST_MESSAGE?"SignUp":null,text:e.$t("signUp")},on:{"btn-click":function(t){return e.openPopUp(e.signUpPayload)}}})]:e._e(),"TRIAL"===e.state&&e.hideMyServers&&!e.CAN_POST_MESSAGE?r("UiButton",{staticClass:"button button-alt w-full mt-8px",attrs:{text:e.$t("upc.enhanceYourExperienceWithMyServers")},on:{"btn-click":function(t){return e.togglePromo()}}}):e._e(),e.stateData.actions.includes("startTrial")&&!e.CAN_POST_MESSAGE?r("UiButton",{staticClass:"button button-alt w-full mt-8px",attrs:{text:e.$t("actions.startTrial")},on:{"btn-click":function(t){return e.startTrial()}}}):e._e(),e.stateData.actions.includes("purchase")?r("UiButton",{staticClass:"button button-alt w-full mt-8px",attrs:{hrefUrl:e.CAN_POST_MESSAGE?e.purchaseWindow.url:null,text:e.$t("actions.purchase")},on:{"btn-click":function(t){return e.openPopUp(e.purchaseWindow)}}}):e._e(),e.stateData.actions.includes("purchase")?r("UiButton",{staticClass:"button button-alt w-full mt-8px",attrs:{hrefUrl:e.CAN_POST_MESSAGE?e.redeemWindow.url:null,text:"Redeem Activation Code"},on:{"btn-click":function(t){return e.openPopUp(e.redeemWindow)}}}):e._e(),e.stateData.actions.includes("upgrade")?r("UiButton",{staticClass:"button button-alt w-full mt-8px",attrs:{hrefUrl:e.CAN_POST_MESSAGE?e.purchaseWindow.url:null,text:e.$t("actions.upgrade")},on:{"btn-click":function(t){return e.openPopUp(e.purchaseWindow)}}}):e._e(),e.stateData.actions.includes("replace")&&e.replaceable?r("UiButton",{staticClass:"button w-full mt-8px",attrs:{routeName:e.CAN_POST_MESSAGE?"ReplaceKey":null,text:e.$t("actions.replace")},on:{"btn-click":function(t){return e.openPopUp(e.replaceKeyPayload)}}}):e._e(),e.stateData.actions.includes("replace")&&!e.replaceable?r("UiButton",{staticClass:"button w-full mt-8px",attrs:{text:e.$t("actions.replaceIneligible"),title:e.$t("stateData.EGUID.error.message.replacementIneligible"),disabled:""},on:{"btn-click":function(t){return e.niceTry()}}}):e._e(),e.stateData.actions.includes("recover")?r("UiButton",{staticClass:"button w-full mt-8px",attrs:{routeName:e.CAN_POST_MESSAGE?"RecoverKey":null,text:e.$t("actions.recover")},on:{"btn-click":function(t){return e.openPopUp(e.recoverKeyPayload)}}}):e._e(),e.stateData.actions.includes("continueTrial")?r("UiButton",{staticClass:"button w-full mt-8px",attrs:{text:e.$t("regWizPopUp.continueTrial")},on:{"btn-click":function(t){e.CAN_POST_MESSAGE?e.closePopUpFromPopUp():e.SET_IS_LAUNCHPAD_OPEN(!1)}}}):e._e(),e.stateData.actions.includes("extend")?r("UiButton",{staticClass:"button w-full mt-8px",attrs:{routeName:e.CAN_POST_MESSAGE?"ExtendTrial":null,text:e.$t("actions.extend")},on:{"btn-click":function(t){return e.openPopUp(e.extendTrialPayload)}}}):e._e(),e.stateData.actions.includes("close")?r("UiButton",{staticClass:"button w-full mt-8px",attrs:{text:e.$t("continueToUnraid")},on:{"btn-click":function(t){e.CAN_POST_MESSAGE?e.closePopUpFromPopUp():e.SET_IS_LAUNCHPAD_OPEN(!1)}}}):e._e(),e.stateData.actions.includes("signOut")&&e.CAN_POST_MESSAGE?r("UiButton",{staticClass:"button-fine-error text-grey-mid w-full mt-8px",attrs:{routeName:e.CAN_POST_MESSAGE?"SignOut":null,text:e.$t("signOut")},on:{"btn-click":function(t){return e.openPopUp(e.signOutPayload)}}}):e._e()]],2)])}),Oi=r("5a0c"),Ti=r.n(Oi);const Ii=(e,t,r,n,i,o,a)=>({years:e,months:t,days:r,hours:n,minutes:i,seconds:o,firstDateWasLater:a});var Ai=(e,t,r)=>{let n,i=Ti()(e),o=Ti()(t);if(i.isSame(o))return r?Ii(0,0,0,0,0,0,!1):"";if(i.isAfter(o)){const e=i;i=o,o=e,n=!0}else n=!1;let a=o.year()-i.year(),s=o.month()-i.month(),c=o.date()-i.date(),l=o.hour()-i.hour(),u=o.minute()-i.minute(),p=o.second()-i.second();if(p<0&&(p=60+p,u-=1),u<0&&(u=60+u,l-=1),l<0&&(l=24+l,c-=1),c<0){const e=Ti()(`${o.year()}-${o.month()+1}`).subtract(1,"M").daysInMonth();c=e{const r=e?Ti()(parseInt(e,10)):Ti()(),n=t?Ti()(parseInt(t,10)):Ti()();return Ai(r,n,!0)};var Ci=(e,t)=>t?Ri(e,""):Ri("",e),Pi=r("23ad"),Ni=r.n(Pi);r("e072"),r("6210"),r("e5b7");const Mi=document.getElementsByTagName("unraid-user-profile")[0];if(Mi){const e=Mi.getAttribute("locale").slice(0,2);Ti.a.locale(e),Be.debug("[formatDate] dayjs.locale()",Ti.a.locale())}Ti.a.extend(Ni.a);var Di=e=>Ti()(parseInt(e,10)).format("llll"),Ui=v({data:()=>({parsedUptime:"",parsedExpireTime:""}),computed:{...Object(b.c)(["showExpiretime"]),...Object(b.e)(["state","expiretime","uptime"]),formattedUptime(){return Di(this.uptime)},formattedExpireTime(){return Di(this.expiretime)},timeCopy(){return this.showExpiretime?{title:"EEXPIRED"===this.state?this.$t("upc.meta.trial.expired.date",{date:this.formattedExpireTime}):this.$t("upc.meta.trial.active.date",{date:this.formattedExpireTime}),text:"EEXPIRED"===this.state?this.$t("upc.meta.trial.expired.timeDiff",{timeDiff:this.parsedExpireTime}):this.$t("upc.meta.trial.active.timeDiff",{timeDiff:this.parsedExpireTime})}:{title:this.$t("upc.meta.uptime.date",{date:this.formattedUptime}),text:this.$t("upc.meta.uptime.readable",{timeDiff:this.parsedUptime})}}},methods:{buildStringFromValues({years:e,months:t,days:r,hours:n,minutes:i,seconds:o,firstDateWasLater:a,displaySecondsInStringReturn:s}){const c=[],l={year:this.$t("year"),years:this.$t("years"),month:this.$t("month"),months:this.$t("months"),day:this.$t("day"),days:this.$t("days"),hour:this.$t("hour"),hours:this.$t("hours"),minute:this.$t("minute"),minutes:this.$t("minutes"),second:this.$t("second"),seconds:this.$t("seconds"),firstDateWasLater:this.$t("ago"),delimiter:" "},u=(e,t)=>`${e} ${l[t+(1===e?"":"s")]}`;return e&&c.push(u(e,"year")),t&&c.push(u(t,"month")),r&&c.push(u(r,"day")),n&&c.push(u(n,"hour")),i&&c.push(u(i,"minute")),!o||(e||t||r||n||i)&&!s||c.push(u(o,"second")),a&&c.push(l.firstDateWasLater),c.join(l.delimiter)},runTimeDiff(){this.uptime&&(this.parsedUptime=this.buildStringFromValues(Ci(this.uptime,!0))),this.expiretime&&(this.parsedExpireTime=this.buildStringFromValues(Ci(this.expiretime,!1)))},letsGo(){this.runTimeDiff(),this.interval=setInterval(()=>{this.runTimeDiff()},1e3)}},created(){this.letsGo()},beforeDestroy(){clearInterval(this.interval)}},(function(){var e=this,t=e.$createElement;return(e._self._c||t)("p",{staticClass:"select-all",attrs:{title:e.timeCopy.title}},[e._v(e._s(e.timeCopy.text))])}),[],!1,null,null,null,!0).exports,Li=v({props:{hrefUrl:{type:[Boolean,URL],default:!1},routeName:{type:String},text:{type:String,required:!0}},computed:{}},(function(){var e=this,t=e.$createElement,r=e._self._c||t;return e.routeName?r("router-link",{attrs:{to:{name:e.routeName}}},[e._v(e._s(e.text))]):e.hrefUrl?r("a",{attrs:{href:e.hrefUrl}},[e._v(e._s(e.text))]):r("button",{on:{click:function(t){return e.$emit("btn-click")}}},[e._v(e._s(e.text))])}),[],!1,null,null,null,!0).exports,ji=v({props:{colorClasses:{type:String,default:"text-grey-mid border-grey-mid"}}},(function(){var e=this,t=e.$createElement;return(e._self._c||t)("span",{staticClass:"text-10px uppercase py-4px px-6px border-2 rounded-full",class:e.colorClasses},[e._v(e._s(e.$t("upc.myServers.beta")))])}),[],!1,null,null,null,!0).exports;var Fi=v({components:{HelperTimeConvert:Ui,UiButton:Li,UiBeta:ji},props:{hidePurchaseButtons:{type:Boolean,default:!1}},data:()=>({CAN_POST_MESSAGE:Ie}),computed:{...Object(b.c)(["stateData","showExpiretime"]),...Object(b.e)(["apiVersion","extendTrialPayload","forumaccount","guidBlacklisted","guidRegistered","hideMyServers","isPopUpOpen","messages","purchaseWindow","recoverKeyPayload","redeemWindow","registered","replaceable","replaceKeyPayload","signInPayload","signOutPayload","signUpPayload","state","wizardWindow"]),showTrialWelcome(){return"ENOKEYFILE"!==this.state&&!this.state.error&&!this.hideMyServers&&!this.registered},computedHeading(){return this.showTrialWelcome?this.$t("upc.thankYouForInstallingMyServers"):this.stateData.heading?this.stateData.heading:this.stateData.error.heading},computedSubheading(){return this.showTrialWelcome?this.$t("upc.connectYourUnraidnetAccountToGetStarted"):this.stateData.message?this.stateData.message:this.stateData.error.message}},methods:{...Object(b.b)(["openPopUp","closePopUp","closePopUpFromPopUp","startTrial","togglePromo"]),...Object(b.d)(["SET_IS_LAUNCHPAD_OPEN"]),niceTry(){alert("❌ Nice try you little sneak ❌")}}},ki,[],!1,(function(e){var t=r("2251");t.__inject__&&t.__inject__(e)}),null,null,!0).exports;var $i=v({i18n:he,store:vi,name:"Launchpad",props:["serverstate","webguiTranslations"],components:{UnraidLoading:wi,LaunchpadActionRequired:Fi},computed:{...Object(b.e)(["errorMessage","guid","hideMyServers","isLaunchpadOpen","isPopUpOpen","loading","registered"]),...Object(b.c)(["server"])},methods:{...Object(b.b)(["closePopUp","setStateFromWebComponentProp","validateGuid"]),...Object(b.d)(["SET_IS_LAUNCHPAD_OPEN"])},watch:{signedOutWithKey(e,t){e&&!t&&this.validateGuid()},isPopUpOpen(e,t){!e&&t&&this.registered&&this.SET_IS_LAUNCHPAD_OPEN(!1)}},created(){if(this.serverstate&&this.setStateFromWebComponentProp(this.serverstate),this.guid)this.validateGuid();else{const e=setInterval(()=>{this.guid&&(clearInterval(e),this.validateGuid())},250)}}},(function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("transition",{attrs:{appear:"",name:"fade",mode:"in-out"}},[r("div",{directives:[{name:"show",rawName:"v-show",value:e.isLaunchpadOpen,expression:"isLaunchpadOpen"}],staticClass:"fixed inset-0 z-10 flex flex-col justify-start items-end mt-90px"},[r("transition",{attrs:{appear:"",name:"fade",mode:"in-out"}},[r("div",{directives:[{name:"show",rawName:"v-show",value:e.isLaunchpadOpen,expression:"isLaunchpadOpen"}],staticClass:"absolute inset-0 z-0 bg-beta opacity-70 cursor-pointer",attrs:{title:e.$t("closeLaunchpad")},on:{click:function(t){return e.SET_IS_LAUNCHPAD_OPEN(!1)}}})]),r("transition",{attrs:{appear:"",name:"slideVerticalFade",mode:"in-out"}},[r("main",{directives:[{name:"show",rawName:"v-show",value:e.isLaunchpadOpen,expression:"isLaunchpadOpen"}],staticClass:"TopBlip text-beta bg-alpha border-grey-darkest text-center relative z-10 w-full max-w-4xl mr-8px p-24px md:p-32px lg:px-40px shadow-md rounded-lg"},[e.loading?[r("UnraidLoading",{staticClass:"mx-auto",attrs:{height:64}}),"string"==typeof e.loading?r("h3",{staticClass:"text-20px italic mt-8px mb-0"},[e._v(e._s(e.loading))]):e._e()]:[r("LaunchpadActionRequired",{attrs:{hidePurchaseButtons:!e.hideMyServers&&!e.registered}}),e.errorMessage?r("p",{staticClass:"text-red font-semibold italic mt-16px mb-0",domProps:{innerHTML:e._s(e.errorMessage)}}):e._e()]],2)])],1)])}),[],!1,(function(e){var t=r("f153");t.__inject__&&t.__inject__(e)}),null,null,!0).exports,Vi=r("99c0"),Gi=r.n(Vi),zi=r("9f96"),Bi=r.n(zi),Wi=r("56c3"),Hi=r.n(Wi),Yi=r("381c"),qi=r.n(Yi),Qi=r("6788"),Ki=r.n(Qi),Xi=v({name:"Feature",props:["title","copy","svg","center"]},(function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("div",{staticClass:"text-left relative flex overflow-hidden p-8px",class:{"w-full sm:w-1/2":!e.center,"max-w-640px":e.center}},[e.center?e._e():r("span",{staticClass:"flex-shrink-0"},[e._t("default")],2),r("div",{staticClass:"inline-flex flex-col pl-4 mr-4",class:{"text-center":e.center}},[r("h3",{staticClass:"font-semibold",class:{"mt-0 mb-4px":e.copy,"my-0":!e.copy,"flex flex-row justify-center items-center":e.center}},[e.center?r("span",{staticClass:"flex-shrink-0 mr-8px"},[e._t("default")],2):e._e(),e._v(" "+e._s(e.title)+" ")]),e.copy?r("p",{staticClass:"opacity-90 py-0",class:{"px-8px":e.center},domProps:{innerHTML:e._s(e.copy)}}):e._e()])])}),[],!1,null,null,null,!0).exports;var Ji=v({i18n:he,store:vi,name:"Promo",components:{Feature:Xi,UnraidSvgUiRemoteAccess:Gi.a,UnraidSvgUiDiagnostics:Bi.a,UnraidSvgUiUsb:Hi.a,UnraidSvgUiKey:qi.a,UnraidSvgUtilStar:Ki.a},computed:{...Object(b.e)(["isPromoOpen","devEnv"]),...Object(b.c)(["features"]),heading(){return this.$t("promoHeading").replace("(BETA)",`${he.tc("upc.myServers.beta")}`)}},methods:{...Object(b.d)(["SET_IS_PROMO_OPEN"]),installMyServers(e=""){try{const t="https://sfo2.digitaloceanspaces.com/unraid-dl/unraid-api/"+(e||"dynamix.unraid.net.plg");Be.debug("[installMyServers] %s",t),sessionStorage.setItem("clickedInstallMyServers",Date.now()),this.SET_IS_PROMO_OPEN(!1),"function"==typeof openPlugin?(Be.debug("[installMyServers] using openPlugin %s",t),openPlugin("plugin install "+t,this.$t("upc.installingMyServers"),"","refresh")):(Be.debug("[installMyServers] using openBox %s",t),openBox("/plugins/dynamix.plugin.manager/scripts/plugin&arg1=install&arg2="+t,this.$t("upc.installingMyServers"),600,900,!0))}catch(e){Be.error(e)}}},watch:{isPromoOpen(e,t){t&&!e&&sessionStorage.removeItem("showPromoPostTrialInstall")},isLaunchpadOpen(e,t){t&&!e&&sessionStorage.getItem("showPromoPostTrialInstall")&&this.SET_IS_PROMO_OPEN(!1)}}},(function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("transition",{attrs:{appear:"",name:"fade",mode:"in-out"}},[r("div",{directives:[{name:"show",rawName:"v-show",value:e.isPromoOpen,expression:"isPromoOpen"}],staticClass:"fixed inset-0 z-10 flex flex-col justify-start items-end mt-90px"},[r("transition",{attrs:{appear:"",name:"fade",mode:"in-out"}},[r("div",{directives:[{name:"show",rawName:"v-show",value:e.isPromoOpen,expression:"isPromoOpen"}],staticClass:"fixed inset-0 z-0 bg-beta opacity-70 cursor-pointer",attrs:{title:e.$t("closePromo")},on:{click:function(t){return e.SET_IS_PROMO_OPEN(!1)}}})]),r("transition",{attrs:{appear:"",name:"slideVerticalFade",mode:"in-out"}},[r("div",{directives:[{name:"show",rawName:"v-show",value:e.isPromoOpen,expression:"isPromoOpen"}],staticClass:"Promo TopBlip text-beta bg-alpha border-grey-darkest text-center relative z-10 w-full max-w-800px mr-8px p-24px sm:p-32px lg:px-40px shadow-md rounded-lg"},[r("h2",{staticClass:"text-24px my-0",domProps:{innerHTML:e._s(e.heading)}}),r("div",{staticClass:"text-14px flex flex-wrap justify-center my-16px"},e._l(e.features,(function(t,n){return r("feature",{key:n,attrs:{title:t.title,copy:t.copy,center:t.center||!1}},["ui--remote-access"===t.svg?r("UnraidSvgUiRemoteAccess",{staticClass:"fill-current mt-1 w-28px h-28px"}):e._e(),"ui--diagnostics"===t.svg?r("UnraidSvgUiDiagnostics",{staticClass:"fill-current mt-1 w-28px h-28px"}):e._e(),"ui--usb"===t.svg?r("UnraidSvgUiUsb",{staticClass:"fill-current mt-1 w-28px h-28px"}):e._e(),"ui--key"===t.svg?r("UnraidSvgUiKey",{staticClass:"fill-current mt-1 w-28px h-28px"}):e._e(),"util--star"===t.svg?r("UnraidSvgUtilStar",{staticClass:"fill-current mt-1 w-28px h-28px"}):e._e()],1)})),1),r("div",{staticClass:"w-full max-w-xs flex flex-col mx-auto"},[e.devEnv?r("button",{staticClass:"button mb-8px",on:{click:function(t){return e.installMyServers("dynamix.unraid.net.staging.plg")}}},[e._v("Install Staging")]):e._e(),r("button",{staticClass:"button",on:{click:function(t){return e.installMyServers()}}},[e._v(e._s(e.$t("installPlugin")))]),r("div",[r("a",{staticClass:"text-12px tracking-wide inline-block mx-8px opacity-60 hover:opacity-100 focus:opacity-100 underline mt-16px transition",attrs:{href:"https://wiki.unraid.net/My_Servers",target:"_blank",rel:"noopener noreferrer",title:e.$t("checkoutTheMyServersDocs")}},[e._v(e._s(e.$t("learnMore")))]),r("button",{staticClass:"text-12px tracking-wide inline-block mx-8px opacity-60 hover:opacity-100 focus:opacity-100 underline mt-16px transition",attrs:{title:e.$t("closePromo")},on:{click:function(t){return e.SET_IS_PROMO_OPEN(!1)}}},[e._v(" "+e._s(e.$t("noThanks"))+" ")])])])])])],1)])}),[],!1,(function(e){var t=r("5b71");t.__inject__&&t.__inject__(e)}),null,null,!0).exports;var Zi=v({i18n:he,store:vi,name:"UpcTrigger",props:[],data:()=>({}),computed:{...Object(b.c)(["stateData","stateDataKeyActions"]),...Object(b.e)(["isPopUpOpen","state","triggerUPC","wizardWindow"]),copy(){return"BASIC"===this.state||"PLUS"===this.state?this.$t("upcTrigger.upgrade"):this.stateDataKeyActions?this.$t("upcTrigger.default"):""},buttonText(){return this.stateData.error?this.$t("fixError"):this.isPopUpOpen?this.$t("backToPopUp"):"ENOKEYFILE"===this.state?this.$t("getStarted"):this.stateDataKeyActions?this.$t("upcTrigger.open"):""},buttonTitle(){return this.stateDataKeyActions?this.$t("upcTrigger.open"):this.$t("upc.opensNewHttpsWindow.base",[this.buttonText])}},methods:{...Object(b.b)(["jumpToUpc","closePopUp","openPopUp"]),btnClick(){return this.isPopUpOpen?this.openPopUp(this.wizardWindow):this.jumpToUpc()}}},(function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("transition",{attrs:{appear:"",name:"fade",mode:"out-in"}},[e.buttonText?r("div",{staticClass:"flex flex-wrap pl-12px"},[r("p",{staticClass:"w-7/20 pr-12px",domProps:{innerHTML:e._s(e.copy)}}),r("div",{staticClass:"w-13/20 inline-flex flex-row"},[r("button",{attrs:{type:"button",title:e.buttonTitle,disabled:e.triggerUPC},on:{click:function(t){return e.btnClick()}}},[e._v(e._s(e.buttonText))]),r("transition",{attrs:{name:"fade",mode:"out-in"}},[e.isPopUpOpen?r("button",{staticClass:"ml-8px",attrs:{type:"button"},on:{click:function(t){return e.closePopUp()}}},[e._v(e._s(e.$t("closePopUp")))]):e._e()])],1)]):e._e()])}),[],!1,(function(e){var t=r("22c9");t.__inject__&&t.__inject__(e)}),null,null,!0).exports,eo=r("ab14"),to=r.n(eo),ro=r("c7db"),no=r("4eb5"),io=r.n(no),oo=r("b692"),ao=r.n(oo),so=r("a3b3"),co=r.n(so),lo=r("8a86"),uo=r.n(lo),po=r("b2a0"),fo=r.n(po),ho=r("b045"),mo=r.n(ho),go=r("45b7"),vo=r.n(go),bo=r("73c6"),yo=r.n(bo),wo=r("94d0"),xo=r.n(wo),_o=r("607e"),Eo=r.n(_o),So=v({props:{payload:{type:Object},text:{type:String},emphasize:{type:Boolean,default:!1},external:{type:Boolean,default:!0}},components:{UnraidSvgUiKey:qi.a,UnraidSvgUtilNewWindow:co.a}},(function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("li",[r("button",{staticClass:"group flex flex-row items-center justify-between",class:{"btn-emphasize":e.emphasize},attrs:{title:e.external?""+e.$t("upc.opensNewHttpsWindow.base",[e.text]):null},on:{click:function(t){return e.$emit("click")}}},[r("span",{staticClass:"inline-flex flex-row items-center"},[r("UnraidSvgUiKey",{staticClass:"fill-current w-12px h-12px mr-8px"}),e._v(" "+e._s(e.text)+" ")],1),e.external?r("UnraidSvgUtilNewWindow",{staticClass:"text-white opacity-0 group-hover:opacity-100 transition-opacity duration-200 ease-in-out fill-current w-12px h-12px ml-8px"}):e._e()],1)])}),[],!1,null,null,null,!0).exports,ko=r("a190"),Oo=r.n(ko),To=r("a313"),Io=r.n(To),Ao=r("973e"),Ro=r.n(Ao),Co=r("44f2"),Po=r.n(Co);var No=v({components:{UnraidLoading:wi,UnraidSvgUiWarningFill:Oo.a,UnraidSvgUtilCheck:Io.a,UnraidSvgUtilDelete:xo.a,UnraidSvgUtilHelp:Ro.a,UnraidSvgUtilInfo:mo.a,UnraidSvgUtilNewWindow:co.a,UnraidSvgUtilTerminal:Po.a,UnraidSvgUtilEdit:fo.a},props:["errorStateMessageVisible","hideotherservers","hideMyServers"],data:()=>({offlineTimer:sessionStorage.getItem("offlineTimer")||!1,restartTriggered:!1}),watch:{apikey(e,t){t||!e||this.hideMyServers||(Be.debug("[watch.apikey] connect to unraid-api",{newVal:e,oldVal:t}),this.serversPlz()),!t||e||this.hideMyServers||(Be.debug("[apikey removed] disconnect from unraid-api",{newVal:e,oldVal:t}),this.stopGraphqlClient(t))},noRemoteApikeyRegisteredWithPlg(e,t){t||!e||this.hideMyServers||(Be.debug("[watch.noRemoteApikeyRegisteredWithPlg] connect to unraid-api",{newVal:e,oldVal:t}),this.serversPlz())},registered(e,t){t||!e||this.hideMyServers||(Be.debug("[watch.apikey] connect to unraid-api",{newVal:e,oldVal:t}),this.serversPlz())},myServersError(e,t){!t||e||this.myServers.length||(Be.debug("[watch.myServersError] connect to unraid-api",{newVal:e,oldVal:t}),this.serversPlz())},graphOnline(e,t){t&&!1===e&&this.timer("watch.graphOnline")}},computed:{...Object(b.c)(["errorTooManyDisks","hasRemoteApikey","keyTypeForPurchase","myServersOutOfDate","noRemoteApikeyRegisteredWithPlg","plgInstallFailed","stateData","validApiKeyLength"]),...Object(b.e)(["apikey","apiVersion","cloud","deviceCount","graphOnline","guid","locale","myServers","myServersError","myServersErrorShowSupportBtn","myServersLoading","pirateKey","registered","servername","signInPayload","state","wanip"]),currentServer(){return this.myServers?this.myServers.filter(e=>e.guid===this.guid?e:null)[0]:{name:this.servername,status:"offline"}},currentServerStatus(){return this.currentServer?this.currentServer.status:"offline"},filteredServers(){return this.myServers?this.hideotherservers?[]:this.myServers.filter(e=>e.guid!==this.guid?e:null).sort((e,t)=>e.name.localeCompare(t.name,"en",{numeric:!0,sensitivity:"base"})):[]},errorToggleText(){return this.stateData.error.message?"EEXPIRED"===this.state?this.stateData.error.heading:this.$t("fixError"):this.pirateKey||this.myServersError||this.noRemoteApikeyRegisteredWithPlg||this.errorTooManyDisks||this.myServersOutOfDate&&this.myServersOutOfDate.enabled||this.cloud&&this.cloud.error||this.plgInstallFailed?this.computedErrorHeading:""},errorToggleTitle(){if(this.stateData.error||this.stateData.message||this.myServersError||this.myServersOutOfDate&&this.myServersOutOfDate.enabled||this.cloud&&this.cloud.error||this.plgInstallFailed){return`${!this.stateData.error.message&&!this.stateData.message||this.noRemoteApikeyRegisteredWithPlg||this.errorTooManyDisks||!this.cloud||this.cloud.error?this.computedErrorHeading:this.stateData.humanReadable} • ${this.errorStateMessageVisible?this.$t("upc.myServers.closeDetails"):this.$t("learnMore")}`}return""},computedErrorHeading(){return this.noRemoteApikeyRegisteredWithPlg?this.$t("upc.noRemoteApikeyRegisteredWithPlg.heading"):this.stateData.error.heading?this.stateData.error.heading:this.pirateKey?this.$t("keyFileNotValid"):this.myServersLoading&&this.restartTriggered?"Unraid API":this.myServersError?this.myServersError.includes("Network error")?this.$t("upc.myServers.errors.unraidApi.heading"):this.$t("upc.myServers.errors.myServers.heading"):this.errorTooManyDisks?this.$t("upc.errorTooManyDisks.heading"):this.plgInstallFailed?this.$t("installFailed.heading"):this.myServersOutOfDate.enabled?this.myServersOutOfDate.heading:this.cloud&&this.cloud.error?this.$t("upc.myServers.errors.unraidApi.heading"):""},computedError(){if(this.noRemoteApikeyRegisteredWithPlg)return this.$t("upc.noRemoteApikeyRegisteredWithPlg.msg");if(this.stateData.error.message)return this.stateData.error.message;if(this.pirateKey)return this.$t("yargYePirate");if(this.myServersLoading&&this.restartTriggered)return this.$t("upc.myServers.restarting");if(this.myServersError)return this.myServersError.includes("Network error")?this.$t("upc.myServers.errors.unraidApi.message"):this.myServersError;if(this.errorTooManyDisks){const e=this.$t("upc.errorTooManyDisks.msg.base");return"Basic"===this.keyTypeForPurchase?`${this.$t("upc.errorTooManyDisks.msg.basic")} ${e}`:"Plus"===this.keyTypeForPurchase?`${this.$t("upc.errorTooManyDisks.msg.plus")} ${e}`:e}return this.plgInstallFailed?"The My Servers plugin installation failed. Rebooting will likely solve this.":this.myServersOutOfDate.enabled?this.myServersOutOfDate.message:this.cloud&&this.cloud.error?this.cloud.error:""},myServersOverflow(){return this.filteredServers.length>8},apiEnableRestartButton(){return!!this.apiVersion&&Ye()(this.apiVersion,"2.42.5")&&this.offlineTimer&&!this.hideMyServers&&!this.graphOnline&&!this.myServersLoading&&!this.stateData.error&&this.myServersError&&(this.myServersError.includes("unraid-api is stopped")||this.myServersError.includes("Disconnected from Unraid API"))},forumSupportLink(){return this.plgInstallFailed?"https://forums.unraid.net/topic/112073-my-servers-releases/#comment-1154449":this.myServersError&&this.myServersError.includes("OK")||this.myServersError&&this.myServersError.includes("SERVER_OVERLOAD")||this.cloud&&this.cloud.error&&(this.cloud.error.includes("OK")||this.cloud.error.includes("SERVER_OVERLOAD"))?"https://forums.unraid.net/topic/112073-my-servers-releases/#comment-1121459":"https://forums.unraid.net/forum/94-my-servers-plugin-support/"}},methods:{...Object(b.b)(["executeUnraidApi","fetchServers","openPopUp","stopGraphqlClient"]),serversPlz(){return Be.debug("[serversPlz]",{apikey:this.apikey,noRemoteApikeyRegisteredWithPlg:this.noRemoteApikeyRegisteredWithPlg,validApiKeyLength:this.validApiKeyLength,myServersOutOfDate:this.myServersOutOfDate}),this.plgInstallFailed?Be.error("[MyServers] plugin failed to install correctly"):this.myServersOutOfDate&&this.myServersOutOfDate.enabled&&(this.myServersOutOfDate.error||Be.warn(this.myServersOutOfDate.message),this.myServersOutOfDate.error)?Be.error(this.myServersOutOfDate.message):this.noRemoteApikeyRegisteredWithPlg?Be.error("[MyServers] remote apikey does not exist"):this.validApiKeyLength?(this.fetchServers(),this.timer("serversPlz()")):Be.error("[MyServers] invalid apikey")},timer(e=""){Be.debug("[timer] %s",e),setTimeout(()=>{!this.graphOnline&&this.registered&&(this.offlineTimer=!0,sessionStorage.setItem("offlineTimer",Date.now()))},3e4)},triggerRestart(){this.executeUnraidApi({command:"start"}),this.offlineTimer=!1,this.restartTriggered=!0,sessionStorage.removeItem("offlineTimer")}},created(){!this.hideMyServers&&this.registered&&this.serversPlz()}},(function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("div",{staticClass:"relative"},[r("ul",{staticClass:"relative"},[e.filteredServers.length&&e.myServersError&&!e.stateData.error?r("li",{staticClass:"text-red text-12px font-semibold px-16px pb-4px"},[r("em",[e._v(e._s(e.$t("upc.myServers.displayingLastKnown")))])]):e._e(),e.computedError?r("li",{key:"current-server-error",staticClass:"w-full"},[r("button",{staticClass:"btn-error group py-8px px-16px flex flex-col",attrs:{title:e.errorToggleTitle},on:{click:function(t){return e.$emit("toggle-error")}}},[r("div",{staticClass:"w-full flex flex-row justify-between items-center"},[r("span",{staticClass:"inline-flex flex-row items-center"},[e.myServersOutOfDate&&e.myServersOutOfDate.enabled&&!e.myServersOutOfDate.error?r("UnraidSvgUtilInfo",{staticClass:"fill-current w-12px h-12px"}):r("UnraidSvgUiWarningFill",{staticClass:"fill-current w-12px h-12px"}),r("span",{staticClass:"font-semibold mx-8px"},[e._v(" "+e._s(e.servername)+" ")])],1),e.computedError&&e.errorStateMessageVisible?r("UnraidSvgUtilDelete",{staticClass:"text-current opacity-100 group-hover:opacity-100 transition-opacity duration-200 ease-in-out fill-current w-12px h-12px ml-8px"}):r("UnraidSvgUtilInfo",{staticClass:"text-current opacity-100 group-hover:opacity-100 transition-opacity duration-200 ease-in-out fill-current w-12px h-12px ml-8px"})],1),r("transition",{attrs:{name:"fade",mode:"out-in"}},[e.computedError&&e.errorStateMessageVisible?r("div",{staticClass:"UnraidUPC-serverError"},[r("div",{staticClass:"text-14px font-semibold pt-4px"},[r("h3",{staticClass:"text-16px mb-4px"},[e._v(e._s(e.errorToggleText))]),r("p",{domProps:{innerHTML:e._s(e.computedError)}})])]):e._e()])],1)]):e._e(),r("transition",{attrs:{name:"fade",mode:"out-in"}},[e.pirateKey&&e.errorStateMessageVisible?r("li",[r("a",{staticClass:"link-error group flex flex-row items-center justify-between",attrs:{href:"zh_CN"===e.locale?"https://unraid.net/zh/%E8%B4%AD%E4%B9%B0-%E6%AD%A3%E7%89%88-unraid-%E8%AE%B8%E5%8F%AF%E8%AF%81":"https://unraid.net/buy-genuine-license",title:e.$t("upc.opensNewHttpsWindow.base",[e.$t("learnMore")]),target:"_blank"}},[r("span",{staticClass:"inline-flex flex-row items-center"},[r("UnraidSvgUtilHelp",{staticClass:"fill-current w-12px h-12px mr-8px"}),e._v(" "+e._s(e.$t("learnMore"))+" ")],1),r("UnraidSvgUtilNewWindow",{staticClass:"opacity-0 group-hover:opacity-100 transition-opacity duration-200 ease-in-out fill-current w-12px h-12px ml-8px"})],1)]):e._e()]),r("transition",{attrs:{name:"fade",mode:"out-in"}},[e.computedError&&!e.stateData.error&&e.errorStateMessageVisible&&e.myServersOutOfDate&&e.myServersOutOfDate.enabled&&e.myServersOutOfDate.link?r("li",[r("a",{staticClass:"link-error group flex flex-row items-center justify-between",attrs:{href:e.myServersOutOfDate.link,title:e.myServersOutOfDate.linkSameTab?"":e.$t("upc.opensNewHttpsWindow.base",[this.myServersOutOfDate.heading]),target:e.myServersOutOfDate.linkSameTab?"":"_blank",rel:"noopener"}},[r("span",{staticClass:"inline-flex flex-row items-center"},[r("UnraidSvgUtilEdit",{staticClass:"fill-current w-12px h-12px mr-8px"}),e._v(" "+e._s(e.myServersOutOfDate.linkText)+" ")],1),e.myServersOutOfDate.linkSameTab?e._e():r("UnraidSvgUtilNewWindow",{staticClass:"opacity-0 group-hover:opacity-100 transition-opacity duration-200 ease-in-out fill-current w-12px h-12px ml-8px"})],1)]):e._e()]),r("transition",{attrs:{name:"fade",mode:"out-in"}},[(e.plgInstallFailed||e.myServersError||e.cloud&&e.cloud.error)&&!e.stateData.error&&e.errorStateMessageVisible?r("li",[r("a",{staticClass:"link-error group flex flex-row items-center justify-between",attrs:{href:e.forumSupportLink,title:e.$t("upc.opensNewHttpsWindow.base",["My Servers Support"]),target:"_blank",rel:"noopener"}},[r("span",{staticClass:"inline-flex flex-row items-center"},[r("UnraidSvgUtilHelp",{staticClass:"fill-current w-12px h-12px mr-8px"}),e._v(" "+e._s(e.plgInstallFailed?e.$t("learnMore"):"My Servers Support")+" ")],1),r("UnraidSvgUtilNewWindow",{staticClass:"opacity-0 group-hover:opacity-100 transition-opacity duration-200 ease-in-out fill-current w-12px h-12px ml-8px"})],1)]):e._e()]),r("transition",{attrs:{name:"fade",mode:"out-in"}},[("EEXPIRED"!==e.state&&e.stateData.error||e.pirateKey)&&e.errorStateMessageVisible?r("li",[r("a",{staticClass:"link-error group flex flex-row items-center justify-between",attrs:{title:e.$t("upc.opensNewHttpsWindow.base",[e.$t("contactSupport")])},on:{click:function(t){return e.$emit("contact-support")}}},[r("span",{staticClass:"inline-flex flex-row items-center"},[r("UnraidSvgUtilHelp",{staticClass:"fill-current w-12px h-12px mr-8px"}),e._v(" "+e._s(e.$t("contactSupport"))+" ")],1),r("UnraidSvgUtilNewWindow",{staticClass:"opacity-0 group-hover:opacity-100 transition-opacity duration-200 ease-in-out fill-current w-12px h-12px ml-8px"})],1)]):e._e()]),r("transition",{attrs:{name:"fade",mode:"out-in"}},[e.noRemoteApikeyRegisteredWithPlg&&e.errorStateMessageVisible?r("li",[r("a",{staticClass:"link-error group flex flex-row items-center justify-between",attrs:{title:e.$t("upc.opensNewHttpsWindow.base",[e.$t("signIn")])},on:{click:function(t){return e.openPopUp(e.signInPayload)}}},[r("span",{staticClass:"inline-flex flex-row items-center"},[r("UnraidSvgUiWarningFill",{staticClass:"fill-current w-12px h-12px mr-8px"}),e._v(" "+e._s(e.$t("upc.signInActions.resolve"))+" ")],1),r("UnraidSvgUtilNewWindow",{staticClass:"opacity-0 group-hover:opacity-100 transition-opacity duration-200 ease-in-out fill-current w-12px h-12px ml-8px"})],1)]):e._e()]),r("transition",{attrs:{name:"fade",mode:"out-in"}},[e.apiEnableRestartButton?r("li",[r("button",{staticClass:"group flex flex-row items-center justify-between",attrs:{title:e.$t("upc.myServers.api.startTitle")},on:{click:function(t){return e.triggerRestart()}}},[r("span",{staticClass:"inline-flex flex-row items-center"},[r("UnraidSvgUtilTerminal",{staticClass:"fill-current w-12px h-12px mr-8px"}),e._v(" "+e._s(e.$t("upc.myServers.api.start"))+" ")],1)])]):e._e()]),e.registered?r("div",{staticClass:"relative z-0",class:{"custom-scrollbar":e.myServersOverflow}},[r("div",{class:{"overflow-y-scroll max-h-310px":e.myServersOverflow}},[r("transition-group",{attrs:{name:"fade",mode:"out-in"}},[e.myServersLoading?r("UnraidLoading",{key:"gql-loading",staticClass:"w-36px my-8px mx-auto",attrs:{height:21,title:e.$t("upc.myServers.loading")}}):e._e(),e.filteredServers?r("div",{key:"filteredServers"},[r("transition",{attrs:{name:"fade",mode:"out-in"}},[e.computedError?e._e():r("li",{key:"current-server",staticClass:"w-full py-8px px-16px flex flex-row items-center",class:{"text-beta":"online"===e.currentServerStatus,"text-orange cursor-not-allowed":"online"!==e.currentServerStatus},attrs:{title:e.$t("upc.myServers.accessLabels.current")+" • "+("online"!==e.currentServerStatus?e.$t("upc.myServers.mothership.notConnected"):e.$t("upc.myServers.mothership.connected"))}},["online"!==e.currentServerStatus?r("UnraidSvgUiWarningFill",{staticClass:"fill-current w-12px h-12px"}):r("UnraidSvgUtilCheck",{staticClass:"fill-current w-12px h-12px"}),r("span",{staticClass:"ml-8px select-all"},[e._v(e._s(e.currentServer?e.currentServer.name:e.servername))])],1)]),e._l(e.filteredServers,(function(t,n){return r("li",{key:"filteredServer_"+n},["online"===t.status&&e.wanip!==t.wanip&&t.remoteurl?r("a",{staticClass:"w-full flex flex-row items-center",attrs:{href:t.remoteurl,tabindex:"0",title:e.$t("upc.myServers.accessLabels.remote")}},[r("span",{staticClass:"block w-12px h-12px mr-8px bg-green rounded-full"}),r("span",{staticClass:"select-all"},[e._v(e._s(t.name))])]):"online"===t.status&&t.localurl?r("a",{staticClass:"w-full flex flex-row items-center",attrs:{href:t.localurl,tabindex:"0",title:e.$t("upc.myServers.accessLabels.local")}},[r("span",{staticClass:"block w-12px h-12px mr-8px bg-green rounded-full"}),r("span",{staticClass:"select-all"},[e._v(e._s(t.name))])]):"never_connected"!==t.status?r("span",{staticClass:"w-full flex flex-row items-center px-16px py-8px opacity-50 cursor-not-allowed",attrs:{title:"online"===t.status?e.$t("upc.myServers.accessLabels.unavailable"):e.$t("upc.myServers.accessLabels.offline")}},[r("span",{staticClass:"text-red text-14px w-12px mr-8px"},[e._v("×")]),r("span",{staticClass:"select-all"},[e._v(e._s(t.name))])]):e._e()])}))],2):e._e()],1)],1)]):e._e()],1)])}),[],!1,(function(e){var t=r("dce8");t.__inject__&&t.__inject__(e)}),null,null,!0).exports,Mo=v({components:{HelperTimeConvert:Ui},computed:{...Object(b.e)(["state"]),...Object(b.c)(["stateData"])}},(function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("div",{staticClass:"text-gamma text-12px text-right font-semibold leading-normal flex flex-row items-baseline justify-end pr-16px pt-4px"},[r("HelperTimeConvert"),r("span",{staticClass:"px-12px"},[e._v("•")]),e.stateData.actions.includes("upgrade")?r("button",{staticClass:"text-12px text-gamma hover:text-alpha focus:text-alpha font-semibold transition-colors duration-150 ease-in-out border-t-0 border-l-0 border-r-0 border-b-2 border-transparent hover:border-orange-dark focus:border-orange-dark focus:outline-none",attrs:{title:e.$t("upc.opensNewHttpsWindow.upgrade")},on:{click:function(t){return e.$emit("upgrade")}}},[r("h5",[e._v("Unraid OS "),r("em",[r("strong",[e._v(e._s(e.stateData.humanReadable))])])])]):r("h5",[e._v("Unraid OS "),r("em",{class:{"text-red":e.stateData.error||"EEXPIRED"===e.state}},[r("strong",[e._v(e._s(e.stateData.humanReadable))])])]),e.stateData.actions.includes("purchase")?r("button",{staticClass:"text-12px text-orange-dark font-semibold hover:text-alpha focus:text-alpha ml-12px transition-colors duration-150 ease-in-out border-t-0 border-l-0 border-r-0 border-b-2 border-transparent hover:border-orange-dark focus:border-orange-dark focus:outline-none",attrs:{title:e.$t("upc.opensNewHttpsWindow.purchase")},on:{click:function(t){return e.$emit("purchase")}}},[e._v(e._s(e.$t("actions.purchase")))]):e._e()],1)}),[],!1,null,null,null,!0).exports;o.default.use(io.a);var Do=v({i18n:he,store:vi,name:"UserProfile",mixins:[ro.mixin],components:{UnraidLoading:wi,UnraidLogoMark:_i,KeyAction:So,MetaInfo:Mo,MyServers:No,UnraidSvgUtilLogout:ao.a,UnraidSvgUtilNewWindow:co.a,UnraidSvgUtilSelect:uo.a,UnraidSvgUtilEdit:fo.a,UnraidSvgUtilInfo:mo.a,UnraidSvgUiWarning:vo.a,UnraidSvgUtilGlobe:yo.a,UnraidSvgUtilDelete:xo.a,UnraidSvgUtilThumbsUp:Eo.a,UiBeta:ji},props:{serverstate:String,banner:{type:String,default:""},showBannerGradient:{type:String,default:"yes"},bgcolor:[String,Number],displaydesc:{type:String,default:""},locale:String,localeMessages:String,metacolor:String,textcolor:String,theme:{type:String,default:"black"},hideotherservers:{type:String,default:""},apikey:String,apiVersion:String,csrf:String,expiretime:[Number,String],hideMyServers:{type:String,default:null},plgPath:String,regWizTime:String,sendCrashInfo:String,serverdesc:String,servermodel:String,serverupdate:Boolean,uptime:[Number,String]},data:()=>({NODE_ENV:me,avatarFail:!1,copyingIp:!1,copyingIpFailed:!1,dropdownTimeout:"",dropdownVisible:!1,errorStateMessageVisible:!0,showRemoveBtns:!1,removingPlg:!1,hoverImage:!1}),computed:{...Object(b.e)(["avatar","isLaunchpadOpen","isPromoOpen","isPopUpOpen","guid","guidRegistered","popUpWindow","regAtOpen","purchaseWindow","redeemWindow","registered","servername","internalip","state","username","darkTheme","lightTheme","extendTrialPayload","recoverKeyPayload","replaceKeyPayload","signInPayload","signUpPayload","signOutPayload","troubleshootPayload","wizardWindow","messages","myServersEnv","triggerUPC","graphOnline","myServersError","cloud","plgInstalled","signOutTriggered","pirateKey"]),...Object(b.c)(["errorTooManyDisks","noRemoteApikeyRegisteredWithPlg","signedOutWithKey","stateData","myServersOutOfDate","allowedOrigins","server","plgInstallFailed"]),darkMode(){return"black"===this.theme||"azure"===this.theme},usernameButtonText(){return this.stateData.error&&!this.stateData.error.signInToFix&&"EEXPIRED"===!this.state?this.$t("fixError"):this.registered?this.username:""},usernameButtonTitle(){return"ENOKEYFILE"===this.state?this.$t("getStarted"):"EEXPIRED"===this.state?this.$t("upc.trialHasExpiredSeeOptions"):this.stateData.error?this.$t("learnMore"):this.isPopUpOpen&&this.isLaunchpadOpen?this.$t("upc.confirmClosure"):this.cloud&&this.cloud.error?`${this.$t("upc.myServers.errors.unraidApi.heading")}: ${this.cloud.error}`:this.myServersError&&this.registered?`${this.$t("upc.myServers.errors.unraidApi.heading")}: ${this.myServersError}`:this.errorTooManyDisks?this.$t("upc.errorTooManyDisks.heading"):this.isLaunchpadOpen?this.$t("closeLaunchpad"):this.dropdownVisible?this.$t("upc.closeDropdown"):this.$t("upc.openDropdown")},displayKeylineBelowActions(){return!!(this.stateData.actions.includes("startTrial")||this.stateData.actions.includes("purchase")||this.stateData.actions.includes("upgrade")||this.stateData.actions.includes("recover")||this.stateData.actions.includes("replace")||this.stateData.actions.includes("extend"))},extraLinks(){return[...!this.hideMyServers&&this.registered||this.stateData.error.message||this.errorTooManyDisks?[{url:"",text:"",external:!1}]:[],...this.hideMyServers||!this.registered||this.plgInstallFailed?[]:[{url:this.myServersEnv?"https://forums.unraid.net/my-servers-staging/":"https://forums.unraid.net/my-servers/",text:this.$t("upc.extraLinks.myServers"),external:!0,title:this.$t("upc.extraLinks.newTab",[this.$t("upc.extraLinks.myServers")])},{url:"/Settings/ManagementAccess#"+(this.plgPath?"MyServersSettings":"UnraidNetSettings"),text:this.$t("upc.extraLinks.settings.text"),settings:!0,title:this.$t("upc.extraLinks.settings.title")}]]},devEnv(){let e=me;const t="UPC_ENV=",r=document.cookie.split(";");for(let n=0;n{this.showRemoveBtns&&(this.showRemoveBtns=!1)},300),this.dropdownVisible)},...Object(b.b)(["closePopUp","openPopUp","receivePostMessage","setStateFromWebComponentProp","startTrial","stopGraphqlClient","togglePromo","updateServerState","validateGuid"]),...Object(b.d)(["SET_IS_LAUNCHPAD_OPEN","SET_IS_PROMO_OPEN","SET_LOCALE","SET_API_KEY","SET_CSRF","SET_DARK_MODE","SET_EXPIRE_TIME","SET_HIDE_MY_SERVERS","SET_MY_SERVERS_API_VERSION","SET_PLG_PATH","SET_REGWIZ_TIME","SET_SERVERDESC","SET_UPTIME","SET_DEV_MODE","SET_MY_SERVERS_ERROR","SET_MY_SERVERS_ERROR_SHOW_SUPPORT_BTN"]),closeDropdown(){setTimeout(()=>{this.showRemoveBtns&&(this.showRemoveBtns=!1)},300),this.dropdownVisible=!1},dropdownMouseEnter(){return"ENOKEYFILE"!==this.state&&!this.isLaunchpadOpen&&(clearTimeout(this.dropdownTimeout),!0)},dropdownMouseLeave(){return this.dropdownTimeout=setTimeout(()=>"ENOKEYFILE"!==this.state&&(this.dropdownVisible=!1,setTimeout(()=>{this.showRemoveBtns&&(this.showRemoveBtns=!1)},300)),1e3),!0},autoTriggerLaunchpad(){setTimeout(()=>{const e=`${this.servername}_${this.guid?this.guid.slice(-12):"NO_GUID"}`;sessionStorage.getItem(e)||"ENOKEYFILE"!==this.state||(sessionStorage.setItem(e,"またね"),this.isLaunchpadOpen||this.toggleLaunchpad())},100)},toggleLaunchpad(){const e="unraid-launchpad";if(!document.getElementsByTagName(e).length){const t=document.getElementsByTagName("body")[0],r=document.createElement(e);t.appendChild(r)}const t=()=>{this.dropdownVisible&&(this.dropdownVisible=!1),this.isPopUpOpen&&this.closePopUp(),this.SET_IS_LAUNCHPAD_OPEN(!this.isLaunchpadOpen)};this.isPopUpOpen&&this.isLaunchpadOpen?window.confirm(this.$t("upc.pleaseConfirmClosureYouHaveOpenPopUp"))&&t():t()},onAvatarError(){Be.error("Avatar failed to load %s",this.avatar),this.avatarFail=!0},async initUserProfile(){if(Be.debug("[initUserProfile]"),this.setStateFromWebComponentProp(this.serverstate),this.apikey&&this.SET_API_KEY(this.apikey),this.apiVersion&&this.SET_MY_SERVERS_API_VERSION(this.apiVersion),this.csrf&&this.SET_CSRF(this.csrf),this.expiretime&&this.SET_EXPIRE_TIME(this.expiretime),this.hideMyServers&&this.SET_HIDE_MY_SERVERS(this.hideMyServers),this.plgPath&&this.SET_PLG_PATH(this.plgPath),this.regWizTime&&this.SET_REGWIZ_TIME(this.regWizTime),this.serverdesc&&this.SET_SERVERDESC(this.serverdesc),this.uptime&&this.SET_UPTIME(this.uptime),this.devEnv&&this.SET_DEV_MODE(this.devEnv),this.hideMyServers){const e=["color: white","background: linear-gradient(to right, #E22828 0%, #FF8C2F 100%)","font-size: 10px","padding: 4px"].join(";");Be.log(`%c${this.$t("upc.enhanceYourExperienceWithMyServers")} • https://wiki.unraid.net/My_Servers`,e)}if(this.localeMessages){Be.debug("[this.locale] %o",this.locale);const[e,t]=Pe(decodeURIComponent(this.localeMessages));e&&Be.error("[initUserProfile.localeMessages] %s","Unable to set locale and locale messages"),this.$i18n.locale=this.locale,this.$i18n.setLocaleMessage(this.locale,t[this.locale]),Be.debug(`[initUserProfile.$i18n] ${this.$i18n.locale} locale & messages set %o`,t[this.locale]),this.SET_LOCALE(this.locale)}this.signedOutWithKey&&this.regWizTime?(Be.debug("[initUserProfile] %o",{signedOutWithKey:this.signedOutWithKey,regWizTime:this.regWizTime}),await this.validateGuid()):this.autoTriggerLaunchpad(),sessionStorage.getItem("clickedInstallMyServers")&&(Be.debug("[initUserProfile] sessionStorage clickedInstallMyServers"),this.toggleLaunchpad()),sessionStorage.getItem("showPromoPostTrialInstall")&&(Be.debug("[initUserProfile] sessionStorage showPromoPostTrialInstall"),this.togglePromo()),window.addEventListener("message",e=>{this.receivePostMessage({inject:!1,event:e})},!1)},copyIpSuccess(){Be.debug("[copyIpSuccess] %s",this.internalip),this.copyingIp=!this.copyingIp,setTimeout(()=>{this.copyingIp=!this.copyingIp},750)},copyIpError(){return this.copyingIpFailed=!0,clearTimeout(this.copyingFailedTimeout),this.copyingFailedTimeout=setTimeout(()=>{this.copyingIpFailed=!this.copyingIpFailed},2e3),Be.error("Unable to copy IP: %s",this.internalip)},hoverCopyFailed(){Be.debug("[hoverCopyFailed] %s",this.internalip),clearTimeout(this.copyingFailedTimeout)},leaveCopyFailed(){Be.debug("[leaveCopyFailed] %s",this.internalip),clearTimeout(this.copyingFailedTimeout),this.copyingFailedTimeout=setTimeout(()=>{this.copyingIpFailed=!this.copyingIpFailed},1500)},copyFailedClickaway(){Be.debug("[copyFailedClickaway] %s",this.internalip),clearTimeout(this.copyingFailedTimeout),this.copyingIpFailed=!1},toggleRemovePlgBtns(){Be.debug("[toggleRemovePlgBtns]"),this.showRemoveBtns=!this.showRemoveBtns},removePlugin(){try{if(Be.debug("[removePlugin] %s",this.plgInstalled),"function"==typeof openPlugin)Be.debug("[removePlugin] using openPlugin %s",this.plgInstalled),openPlugin("plugin remove "+this.plgInstalled.replace("_installFailed",""),this.$t("upc.removeMyServersPlugin"),this.plgInstalled.replace("_installFailed","")+":remove","refresh");else{Be.debug("[removePlugin] using openBox %s",this.plgInstalled),openBox("/plugins/dynamix.plugin.manager/scripts/plugin&arg1=remove&arg2="+this.plgInstalled.replace("_installFailed",""),this.$t("upc.removeMyServersPlugin"),600,900,!0,"loadlist",this.plgInstalled.replace("_installFailed","")+":remove"),this.removingPlg=!0,window.addEventListener("beforeunload",this.preventClose);const e=setInterval(()=>"none"!==document.getElementById("sb-container").style.display?Be.debug("⏳ still removing My Servers…⏳"):(Be.debug("❌ My Servers removed ❌"),window.removeEventListener("beforeunload",this.preventClose),clearInterval(e),window.location.reload()),100)}}catch(e){Be.error(e)}},preventClose(e){this.removingPlg&&(e.preventDefault(),e.returnValue="",alert(this.$t("regWizPopUp.closingPopUpMayLeadToErrors")))}},watch:{signedOutWithKey(e,t){Be.debug("[signedOutWithKey]",{newVal:e,oldVal:t,regWizTime:this.regWizTime}),e&&!t&&this.regWizTime&&this.validateGuid()},isPopUpOpen(e,t){this.isLaunchpadOpen&&!e&&t&&!this.regAtOpen&&this.registered&&this.SET_IS_LAUNCHPAD_OPEN(!1)},triggerUPC(e){e&&setTimeout(()=>{this.dropdownVisible=!0},150)},graphOnline(e,t){e&&!t&&this.updateServerState()},isPromoOpen(e,t){e&&!t&&(this.dropdownVisible=!1)},signOutTriggered(e,t){e&&this.graphOnline&&(Be.debug("[watch.signOutTriggered] disconnect from unraid-api",{newVal:e,oldVal:t,apikey:this.apikey}),this.stopGraphqlClient(this.apikey),this.myServersError&&(this.SET_MY_SERVERS_ERROR(""),this.SET_MY_SERVERS_ERROR_SHOW_SUPPORT_BTN(!1)))}},created(){this.initUserProfile()},beforeMount(){const e=document.getElementsByTagName("body")[0],t={darkTheme:{alpha:"#1c1b1b",beta:"#f2f2f2",gamma:"#999999"},lightTheme:{alpha:"#f2f2f2",beta:"#1c1b1b",gamma:"#999999"}};let{alpha:r,beta:n,gamma:i}=this.darkMode?t.darkTheme:t.lightTheme;this.textcolor&&(r=this.textcolor),this.bgcolor&&(n=this.bgcolor,e.style.setProperty("--color-customgradient-start",to()(n,0)),e.style.setProperty("--color-customgradient-end",to()(n,.9))),this.metacolor&&(i=this.metacolor),e.style.setProperty("--color-alpha",r),e.style.setProperty("--color-beta",n),e.style.setProperty("--color-gamma",i),e.style.setProperty("--shadow-beta","0 25px 50px -12px "+to()(n,.15)),e.style.setProperty("--ring-offset-shadow","0 0 "+n),e.style.setProperty("--ring-shadow","0 0 "+n)}},(function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("div",{staticClass:"UnraidUPC",class:{"--hasBanner-default":e.banner&&"no"!==e.showBannerGradient&&!e.bgcolor,"--hasBanner-custom":e.banner&&"no"!==e.showBannerGradient&&e.bgcolor},attrs:{id:"UnraidUPC"}},[e.isPopUpOpen&&!e.isLaunchpadOpen?r("div",{staticClass:"absolute z-10 inset-0 flex flex-col items-end justify-center pr-6"},[r("div",{staticClass:"text-center inline-flex flex-col items-center justify-center"},[r("button",{staticClass:"text-14px button button-alt",on:{click:function(t){return e.openPopUp()}}},[e._v(e._s(e.$t("backToPopUp")))]),r("button",{staticClass:"hover:underline text-12px mt-4px",on:{click:function(t){return e.closePopUp()}}},[e._v(e._s(e.$t("closePopUp")))])])]):e._e(),r("MetaInfo",{class:{"blur opacity-30 pointer-events-none transition-all duration-150 ease-in-out":e.isPopUpOpen&&!e.isLaunchpadOpen},on:{purchase:function(t){return e.openPopUp(e.purchaseWindow)},upgrade:function(t){return e.openPopUp(e.purchaseWindow)},signin:function(t){return e.openPopUp(e.signInPayload)}}}),r("div",{staticClass:"relative z-0 flex flex-row items-center justify-end h-full",class:{"blur opacity-30 pointer-events-none transition-all duration-150 ease-in-out":e.isPopUpOpen&&!e.isLaunchpadOpen}},[r("h1",{staticClass:"relative text-18px border-t-0 border-r-0 border-l-0 border-b-2 border-transparent"},[e.displaydesc?[r("span",{attrs:{title:e.servermodel}},[e._v(e._s(e.serverdesc))]),r("span",{staticClass:"text-grey-mid px-8px"},[e._v("•")])]:e._e(),r("span",{directives:[{name:"clipboard",rawName:"v-clipboard:copy",value:e.internalip,expression:"internalip",arg:"copy"},{name:"clipboard",rawName:"v-clipboard:success",value:e.copyIpSuccess,expression:"copyIpSuccess",arg:"success"},{name:"clipboard",rawName:"v-clipboard:error",value:e.copyIpError,expression:"copyIpError",arg:"error"}],staticClass:"cursor-pointer",attrs:{title:e.$t("lanIp",[e.internalip])}},[e._v(e._s(e.servername))]),r("transition",{attrs:{name:"fade",mode:"out-in"}},[e.copyingIp?r("span",{staticClass:"text-12px absolute right-0 bg-gradient-to-r from-red to-orange text-center block w-100px rounded"},[e._v(e._s(e.$t("upc.lanIpCopied")))]):e._e(),e.copyingIpFailed?r("span",{directives:[{name:"on-clickaway",rawName:"v-on-clickaway",value:e.copyFailedClickaway,expression:"copyFailedClickaway"}],staticClass:"text-12px font-semibold px-4px absolute right-0 bg-gradient-to-r from-red to-orange text-center block rounded",on:{mouseenter:e.hoverCopyFailed,mouseleave:e.leaveCopyFailed}},[e._v("LAN IP: "),r("span",{staticClass:"select-all"},[e._v(e._s(e.internalip))])]):e._e()])],2),r("div",{staticClass:"block w-2px h-24px ml-16px bg-grey-mid"}),r("div",{directives:[{name:"on-clickaway",rawName:"v-on-clickaway",value:e.closeDropdown,expression:"closeDropdown"}],staticClass:"relative flex items-center justify-end h-full",on:{mouseenter:function(t){return e.dropdownMouseEnter()},mouseleave:function(t){return e.dropdownMouseLeave()}}},[r("button",{staticClass:"UnraidUPC-username group text-18px hover:text-alpha focus:text-alpha border border-transparent flex flex-row justify-end items-center h-full px-16px outline-none focus:outline-none",class:{"text-orange-dark":e.isLaunchpadOpen||!e.username&&!e.stateData.error,"text-alpha":e.username&&!e.isLaunchpadOpen,"text-red":e.stateData.error},attrs:{title:e.usernameButtonTitle},on:{click:function(t){return e.usernameAvatarButton()}}},[e.myServersOutOfDate&&e.myServersOutOfDate.enabled&&!e.myServersOutOfDate.error?r("UnraidSvgUtilInfo",{staticClass:"text-red fill-current relative w-14px h-14px mr-8px"}):e.showWarningIcon?r("UnraidSvgUiWarning",{staticClass:"text-red fill-current relative w-24px h-24px mr-8px"}):e._e(),e.usernameButtonText?r("span",{staticClass:"inline-flex items-center bg-transparent border-t-0 border-l-0 border-r-0 border-b-2 border-transparent group-hover:border-orange-dark group-focus:border-orange-dark transition-colors duration-150 ease-in-out"},[e._v(" "+e._s(e.usernameButtonText)+" "),e.registered&&!e.isLaunchpadOpen?r("UnraidSvgUtilSelect",{staticClass:"fill-current w-8px h-8px ml-8px"}):e._e()],1):e._e(),r("span",{staticClass:"relative z-0 flex items-center justify-center w-36px h-36px rounded-full",class:{"ml-8px":e.usernameButtonText,"bg-transparent":e.registered&&!e.avatarFail,"bg-gradient-to-r from-red to-orange":!e.registered||e.avatarFail},on:{mouseenter:function(t){e.hoverImage=!0},mouseleave:function(t){e.hoverImage=!1}}},[e.registered&&!e.avatarFail?r("img",{staticClass:"absolute z-10 inset-0 w-36px h-36px rounded-full overflow-hidden",attrs:{src:e.avatar,alt:""+e.$t("upc.avatarAlt",[e.username])},on:{error:e.onAvatarError}}):[e.hoverImage?r("UnraidLoading",{staticClass:"relative z-0 w-28px",attrs:{title:e.usernameButtonTitle,"gradient-start":"#fff","gradient-stop":"#fff",height:28}}):r("UnraidLogoMark",{staticClass:"relative z-0 w-28px",attrs:{title:e.usernameButtonTitle,"gradient-start":"#fff","gradient-stop":"#fff"}})]],2),e.usernameButtonText?e._e():r("UnraidSvgUtilSelect",{staticClass:"fill-current w-8px h-8px ml-8px"})],1),r("transition",{attrs:{name:"slideVerticalFade",mode:"out-in"}},[r("div",{directives:[{name:"show",rawName:"v-show",value:e.dropdownVisible,expression:"dropdownVisible"}],staticClass:"UnraidUPC-dropdown",class:{"border-grey-darkest":e.darkMode,"border-grey-light":!e.darkMode}},[e.hideMyServers?e._e():r("header",{staticClass:"text-14px pt-16px px-16px rounded-t"},[r("h5",{staticClass:"text-18px leading-none inline-flex flex-row items-center"},[r("span",{staticClass:"font-semibold"},[e._v(e._s(e.$t("upc.myServers.heading")))]),r("ui-beta",{staticClass:"ml-8px"}),e.myServersEnv?r("span",{staticClass:"ml-8px",attrs:{title:"API • "+e.myServersEnv}},[e._v("⚙️")]):e._e(),e.devEnv?r("span",{staticClass:"ml-8px",attrs:{title:e.devEnv}},[e._v("⚠️")]):e._e()],1)]),r("ul",{staticClass:"list-reset my-8px p-0"},["development"===e.NODE_ENV?[r("li",[r("KeyAction",{attrs:{text:"[DEV] Launchpad",external:!1},on:{click:function(t){return e.toggleLaunchpad()}}})],1),r("li",[r("KeyAction",{attrs:{text:"[DEV] Pop-up"},on:{click:function(t){return e.openPopUp(e.wizardWindow)}}})],1),r("li",{staticClass:"my-8px mx-12px"},[r("hr",{staticClass:"w-full h-2px bg-gradient-to-r from-red to-orange shadow-none border-none rounded-none"})])]:e._e(),e.hideMyServers||e.registered?e._e():[r("li",[r("button",{staticClass:"group flex flex-row items-center justify-between",attrs:{title:e.$t("upc.opensNewHttpsWindow.base",[e.$t("signInUp")])},on:{click:function(t){return e.openPopUp(e.wizardWindow)}}},[r("span",{staticClass:"inline-flex flex-row items-center"},[r("UnraidSvgUtilGlobe",{staticClass:"fill-current w-12px h-12px mr-8px"}),e._v(" "+e._s(e.$t("signInUp"))+" ")],1),r("UnraidSvgUtilNewWindow",{staticClass:"text-white opacity-0 group-hover:opacity-100 transition-opacity duration-200 ease-in-out fill-current w-12px h-12px ml-8px"})],1)]),r("li",{staticClass:"my-8px mx-12px"},[r("hr",{staticClass:"w-full h-2px bg-gradient-to-r from-red to-orange shadow-none border-none rounded-none"})])],e.displayKeylineBelowActions?[e.stateData.actions.includes("startTrial")?r("KeyAction",{attrs:{text:e.$t("actions.startTrial")},on:{click:function(t){return e.startTrial()}}}):e._e(),e.stateData.actions.includes("purchase")?[r("KeyAction",{attrs:{text:e.$t("actions.purchase")},on:{click:function(t){return e.openPopUp(e.purchaseWindow)}}}),r("KeyAction",{attrs:{text:e.$t("actions.redeemActivationCode")},on:{click:function(t){return e.openPopUp(e.redeemWindow)}}})]:e._e(),e.stateData.actions.includes("upgrade")?r("KeyAction",{attrs:{text:e.$t("actions.upgrade")},on:{click:function(t){return e.openPopUp(e.purchaseWindow)}}}):e._e(),e.stateData.actions.includes("recover")?r("KeyAction",{attrs:{text:e.$t("actions.recover")},on:{click:function(t){return e.openPopUp(e.recoverKeyPayload)}}}):e._e(),e.stateData.actions.includes("replace")?r("KeyAction",{attrs:{text:e.$t("actions.replace")},on:{click:function(t){return e.openPopUp(e.replaceKeyPayload)}}}):e._e(),e.stateData.actions.includes("extend")?r("KeyAction",{attrs:{text:e.$t("actions.extend")},on:{click:function(t){return e.openPopUp(e.extendTrialPayload)}}}):e._e(),r("li",{staticClass:"my-8px mx-12px"},[r("hr",{staticClass:"w-full h-2px bg-gradient-to-r from-red to-orange shadow-none border-none rounded-none"})])]:e._e(),!e.hideMyServers&&e.registered||e.pirateKey||e.stateData.error.message||e.errorTooManyDisks||e.myServersOutOfDate.enabled||e.plgInstallFailed?r("MyServers",{attrs:{hideMyServers:e.hideMyServers,errorStateMessageVisible:e.errorStateMessageVisible,hideotherservers:e.hideotherservers},on:{"contact-support":function(t){return e.openPopUp(e.troubleshootPayload)},"toggle-error":function(t){e.errorStateMessageVisible=!e.errorStateMessageVisible}}}):e._e(),e._l(e.extraLinks,(function(t,n){return[t.url?r("li",{key:n},[r("a",{staticClass:"flex flex-row items-center",attrs:{href:t.url,target:t.external?"_blank":"",rel:t.external?"noopener noreferrer":"",title:t.title}},[t.external?r("UnraidSvgUtilNewWindow",{staticClass:"flex-shrink-0 fill-current w-12px h-12px mr-8px"}):e._e(),t.settings?r("UnraidSvgUtilEdit",{staticClass:"flex-shrink-0 fill-current w-12px h-12px mr-8px"}):e._e(),t.info?r("UnraidSvgUtilInfo",{staticClass:"flex-shrink-0 fill-current w-12px h-12px mr-8px"}):e._e(),e._v(" "+e._s(t.text)+" ")],1)]):r("div",{key:n+"_else",staticClass:"mx-12px"},[r("hr",{staticClass:"w-full h-2px my-8px bg-gradient-to-r from-red to-orange shadow-none border-none rounded-none"})])]})),e.hideMyServers?r("li",[r("button",{staticClass:"group flex flex-row items-center justify-between",attrs:{title:e.$t("upc.enhanceYourExperienceWithMyServers")},on:{click:function(t){return e.togglePromo()}}},[r("span",{staticClass:"inline-flex flex-row items-center"},[r("UnraidSvgUtilInfo",{staticClass:"flex-shrink-0 fill-current w-12px h-12px mr-8px"}),r("span",[e._v(" "+e._s(e.$t("upc.enhanceYourExperienceWithMyServers"))+" "),r("ui-beta",{staticClass:"inline-block transform scale-90 opacity-70",attrs:{colorClasses:"text-beta border-beta group-hover:text-white group-focus:text-white group-hover:border-white group-focus:border-white"}})],1)],1)])]):[e.registered&&!e.plgInstallFailed?r("li",[r("button",{staticClass:"group flex flex-row items-center justify-between",attrs:{title:e.$t("upc.opensNewHttpsWindow.base",[e.$t("actions.signOutUnraidNet")])},on:{click:function(t){return e.openPopUp(e.signOutPayload)}}},[r("span",{staticClass:"inline-flex flex-row items-center"},[r("UnraidSvgUtilLogout",{staticClass:"fill-current w-12px h-12px mr-8px"}),e._v(" "+e._s(e.$t("actions.signOutUnraidNet"))+" ")],1),r("UnraidSvgUtilNewWindow",{staticClass:"text-white opacity-0 group-hover:opacity-100 transition-opacity duration-200 ease-in-out fill-current w-12px h-12px ml-8px"})],1)]):r("li",{staticClass:"relative"},[e.showRemoveBtns?e.showRemoveBtns&&!e.removingPlg?r("div",{staticClass:"flex flex-col bg-alpha"},[r("p",{staticClass:"text-12px text-center font-semibold px-16px pb-8px"},[r("em",[e._v(e._s(e.$t("upc.confirmMyServersPluginRemoval")))])]),r("div",{staticClass:"flex flex-row"},[r("button",{staticClass:"group relative bg-transparent flex flex-row justify-between items-center",attrs:{title:e.$t("upc.continueUsingMyServers")},on:{click:function(t){return e.toggleRemovePlgBtns()}}},[e._v(" "+e._s(e.$t("regWizPopUp.forms.cancel"))+" "),r("UnraidSvgUtilThumbsUp",{staticClass:"text-white opacity-0 group-hover:opacity-100 group-focus:opacity-100 transition-opacity duration-200 ease-in-out fill-current w-12px h-12px"})],1),r("button",{staticClass:"btn-remove group relative flex flex-row justify-between items-center",attrs:{title:e.$t("upc.confirmMyServersPluginRemoval")},on:{click:function(t){return e.removePlugin()}}},[e._v(" "+e._s(e.$t("regWizPopUp.forms.confirm"))+" "),r("UnraidSvgUtilDelete",{staticClass:"text-white opacity-0 group-hover:opacity-100 group-focus:opacity-100 transition-opacity duration-200 ease-in-out fill-current w-12px h-12px"})],1)])]):r("button",{attrs:{disabled:""}},[e._v(" "+e._s(e.$t("upc.removingMyServersPlugin"))+" ")]):r("button",{staticClass:"text-black flex flex-row items-center justify-between",attrs:{title:e.$t("upc.removeMyServersPlugin")},on:{click:function(t){return e.toggleRemovePlgBtns()}}},[r("span",{staticClass:"inline-flex flex-row items-center"},[r("UnraidSvgUtilDelete",{staticClass:"fill-current w-12px h-12px mr-8px"}),e._v(" "+e._s(e.$t("upc.removeMyServersPlugin"))+" ")],1)])])]],2)])])],1)])],1)}),[],!1,(function(e){var t=r("e519");t.__inject__&&t.__inject__(e)}),null,null,!0).exports;var Uo=v({i18n:he,store:vi,name:"WanIpCheck",props:{phpWanIp:{type:String,default:""}},computed:{...Object(b.e)(["wanip","site"]),...Object(b.c)(["isRemoteAccess"]),loading(){return!this.wanip}},methods:{...Object(b.b)(["getWanIp"])},created(){Be.debug("[🍣 WanIpCheck 🍣]"),this.wanip||this.getWanIp()}},(function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("transition",{attrs:{appear:"",name:"fade",mode:"out-in"}},[e.loading?r("span",{domProps:{innerHTML:e._s(e.$t("wanIpCheck.checking")+"…")}}):[e.phpWanIp?[e.isRemoteAccess?r("span",{domProps:{innerHTML:e._s(e.$t("wanIpCheck.match",[e.phpWanIp]))}}):e.phpWanIp!==e.wanip||e.isRemoteAccess?r("span",{staticClass:"mismatch",domProps:{innerHTML:e._s(e.$t("wanIpCheck.mismatch",[e.phpWanIp,e.wanip]))}}):r("span",{domProps:{innerHTML:e._s(e.$t("wanIpCheck.match",[e.wanip]))}})]:r("span",{staticClass:"error",domProps:{innerHTML:e._s(e.$t("wanIpCheck.resolveError"))}})]],2)}),[],!1,(function(e){var t=r("6e03");t.__inject__&&t.__inject__(e)}),"4ca8352c",null,!0).exports;window.customElements.define("unraid-authed",g(o.default,bi)),window.customElements.define("unraid-launchpad",g(o.default,$i)),window.customElements.define("unraid-promo",g(o.default,Ji)),window.customElements.define("unraid-upc-trigger",g(o.default,Zi)),window.customElements.define("unraid-user-profile",g(o.default,Do)),window.customElements.define("unraid-wan-ip-check",g(o.default,Uo))},"5b71":function(e,t,r){"use strict";r.r(t);var n=r("c725");for(var i in n)["default"].indexOf(i)<0&&function(e){r.d(t,e,(function(){return n[e]}))}(i)},"5d74":function(e,t,r){e.exports={options:{},ssr:function(e,t){var r=e.data,n=r.attrs,i=n.symbol,o=n.size,a=this.getAttributes(o);a&&(r.attrs=Object.assign({},r.attrs,a)),o&&delete r.attrs.size,i&&delete r.attrs.symbol;var s=r.class,c=r.staticClass||"";c+=s?Object.keys(s).join(" "):"",this.hasClass(c)||(r.staticClass=r.staticClass?r.staticClass+" "+this.options.class:this.options.class);var l=e.context.$createElement("use",{attrs:{href:this.getHref(i)}});Array.isArray(e.children)?e.children.push(l):e.children=[l]},install:function(e,t){void 0===t&&(t={}),this.options.class=t.class||"icon",this.options.url=void 0===t.url?"/assets/svg/sprite.svg":t.url;var r=this;e.directive("svg",{bind:function(e,t,n){var i=t.value||n.data.attrs.symbol,o=n.data.attrs&&n.data.attrs.size,a=r.getAttributes(o);a&&(e.setAttribute("viewBox",a.viewBox),e.setAttribute("width",a.width),e.setAttribute("height",a.height)),i&&e.removeAttribute("symbol"),o&&e.removeAttribute("size");var s=e.getAttribute("class");if(r.hasClass(s)||e.setAttribute("class",s?s+" "+r.options.class:r.options.class),!e||null===e.querySelector("use")){var c=document.createElementNS("http://www.w3.org/2000/svg","use"),l=r.getHref(i);c.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",l),c.setAttribute("href",l),e.appendChild(c)}},update:function(e,t,n){var i=r.getHref(t.value||n.data.attrs.symbol),o=e&&e.querySelector("use");if(o){if(o.getAttribute("href")===i)return!1;var a=document.createElementNS("http://www.w3.org/2000/svg","use");a.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",i),a.setAttribute("href",i),e.replaceChild(a,o)}}})},getAttributes:function(e){if(!e)return null;var t=e.toString().replace(/( |, |,)/g," ").split(" "),r=t.length;if(3===r||r>4)return console.warn('[vue-svg-sprite] size: "'+e+'" is not valid'),null;var n=[];n[0]=r<4?0:t[0],n[1]=r<4?0:t[1];var i=n[2]=r<4?t[0]:t[2];return{height:n[3]=t[r-1],viewBox:n.join(" "),width:i}},hasClass:function(e){var t=this.options.class;return!!e&&e.split(" ").some((function(e){var r=e.split(/(-|_)/)[0];return-1!==r.indexOf(t)&&r.length===t.length}))},getHref:function(e){return""===this.options.url?"#"+e:this.options.url+"#"+e}}},"607e":function(e,t){e.exports={functional:!0,render(e,t){const{_c:r,_v:n,data:i,children:o=[]}=t,{class:a,staticClass:s,style:c,staticStyle:l,attrs:u={},...p}=i;return r("svg",{class:[a,s],style:[c,l],attrs:Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 16 16"},u),...p},o.concat([r("path",{attrs:{"fill-rule":"evenodd",d:"M0 7h2v8l-2 1V7zm3.5 7V7C5 6.7 6.365 4.915 7.595 1.646A1.767 1.767 0 019.25.5c.69 0 1.25.56 1.25 1.25V6h3.09a2 2 0 011.966 2.369l-.75 4A2 2 0 0112.84 14H3.5z"}})]))}}},"61bb":function(e,t,r){const{MAX_LENGTH:n}=r("fe45"),{re:i,t:o}=r("22c0"),a=r("df02"),s=r("e12f");e.exports=(e,t)=>{if(t=s(t),e instanceof a)return e;if("string"!=typeof e)return null;if(e.length>n)return null;if(!(t.loose?i[o.LOOSE]:i[o.FULL]).test(e))return null;try{return new a(e,t)}catch(e){return null}}},6210:function(e,t,r){e.exports=function(e){"use strict";var t=function(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}(e),r={s:"ein paar Sekunden",m:["eine Minute","einer Minute"],mm:"%d Minuten",h:["eine Stunde","einer Stunde"],hh:"%d Stunden",d:["ein Tag","einem Tag"],dd:["%d Tage","%d Tagen"],M:["ein Monat","einem Monat"],MM:["%d Monate","%d Monaten"],y:["ein Jahr","einem Jahr"],yy:["%d Jahre","%d Jahren"]};function n(e,t,n){var i=r[n];return Array.isArray(i)&&(i=i[t?0:1]),i.replace("%d",e)}var i={name:"de",weekdays:"Sonntag_Montag_Dienstag_Mittwoch_Donnerstag_Freitag_Samstag".split("_"),weekdaysShort:"So._Mo._Di._Mi._Do._Fr._Sa.".split("_"),weekdaysMin:"So_Mo_Di_Mi_Do_Fr_Sa".split("_"),months:"Januar_Februar_März_April_Mai_Juni_Juli_August_September_Oktober_November_Dezember".split("_"),monthsShort:"Jan_Feb_März_Apr_Mai_Juni_Juli_Aug_Sept_Okt_Nov_Dez".split("_"),ordinal:function(e){return e+"."},weekStart:1,yearStart:4,formats:{LTS:"HH:mm:ss",LT:"HH:mm",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY HH:mm",LLLL:"dddd, D. MMMM YYYY HH:mm"},relativeTime:{future:"in %s",past:"vor %s",s:n,m:n,mm:n,h:n,hh:n,d:n,dd:n,M:n,MM:n,y:n,yy:n}};return t.default.locale(i,null,!0),i}(r("5a0c"))},"626e":function(e,t,r){"use strict";var n=[/passw(or)?d/i,/^pw$/,/^pass$/i,/secret/i,/token/i,/api[-._]?key/i,/session[-._]?id/i,/^connect\.sid$/],i=[/^\d{4}[- ]?\d{4}[- ]?\d{4}[- ]?\d{4}$/];t.key=function(e){return n.some((function(t){return t.test(e)}))},t.value=function(e){return i.some((function(t){return t.test(e)}))}},"633a":function(e,t,r){"use strict";(function(e){var n=this&&this.__assign||function(){return(n=Object.assign||function(e){for(var t,r=1,n=arguments.length;r0&&i[i.length-1])&&(6===o[0]||2===o[0])){a=0;continue}if(3===o[0]&&(!i||o[1]>i[0]&&o[1]0){var s=t.shift();s&&s.applyMiddleware.apply(i,[e,o])}else r(e)};o()}(a(t.middlewares),t)}))},e.prototype.use=function(e){var t=this;return e.map((function(e){if("function"!=typeof e.applyMiddleware)throw new Error("Middleware must implement the applyMiddleware function.");t.middlewares.push(e)})),this},e.prototype.getConnectionParams=function(e){return function(){return new Promise((function(t,r){if("function"==typeof e)try{return t(e.call(null))}catch(e){return r(e)}t(e)}))}},e.prototype.executeOperation=function(e,t){var r=this;null===this.client&&this.connect();var n=this.generateOperationId();return this.operations[n]={options:e,handler:t},this.applyMiddlewares(e).then((function(e){r.checkOperationOptions(e,t),r.operations[n]&&(r.operations[n]={options:e,handler:t},r.sendMessage(n,b.default.GQL_START,e))})).catch((function(e){r.unsubscribe(n),t(r.formatErrors(e))})),n},e.prototype.getObserver=function(e,t,r){return"function"==typeof e?{next:function(t){return e(t)},error:function(e){return t&&t(e)},complete:function(){return r&&r()}}:e},e.prototype.createMaxConnectTimeGenerator=function(){var e=this.minWsTimeout,t=this.wsTimeout;return new l({min:e,max:t,factor:1.2})},e.prototype.clearCheckConnectionInterval=function(){this.checkConnectionIntervalId&&(clearInterval(this.checkConnectionIntervalId),this.checkConnectionIntervalId=null)},e.prototype.clearMaxConnectTimeout=function(){this.maxConnectTimeoutId&&(clearTimeout(this.maxConnectTimeoutId),this.maxConnectTimeoutId=null)},e.prototype.clearTryReconnectTimeout=function(){this.tryReconnectTimeoutId&&(clearTimeout(this.tryReconnectTimeoutId),this.tryReconnectTimeoutId=null)},e.prototype.clearInactivityTimeout=function(){this.inactivityTimeoutId&&(clearTimeout(this.inactivityTimeoutId),this.inactivityTimeoutId=null)},e.prototype.setInactivityTimeout=function(){var e=this;this.inactivityTimeout>0&&0===Object.keys(this.operations).length&&(this.inactivityTimeoutId=setTimeout((function(){0===Object.keys(e.operations).length&&e.close()}),this.inactivityTimeout))},e.prototype.checkOperationOptions=function(e,t){var r=e.query,n=e.variables,i=e.operationName;if(!r)throw new Error("Must provide a query.");if(!t)throw new Error("Must provide an handler.");if(!p.default(r)&&!h.getOperationAST(r,i)||i&&!p.default(i)||n&&!d.default(n))throw new Error("Incorrect option types. query must be a string or a document,`operationName` must be a string, and `variables` must be an object.")},e.prototype.buildMessage=function(e,t,r){return{id:e,type:t,payload:r&&r.query?n(n({},r),{query:"string"==typeof r.query?r.query:f.print(r.query)}):r}},e.prototype.formatErrors=function(e){return Array.isArray(e)?e:e&&e.errors?this.formatErrors(e.errors):e&&e.message?[e]:[{name:"FormatedError",message:"Unknown error",originalError:e}]},e.prototype.sendMessage=function(e,t,r){this.sendMessageRaw(this.buildMessage(e,t,r))},e.prototype.sendMessageRaw=function(e){switch(this.status){case this.wsImpl.OPEN:var t=JSON.stringify(e);try{JSON.parse(t)}catch(t){this.eventEmitter.emit("error",new Error("Message must be JSON-serializable. Got: "+e))}this.client.send(t);break;case this.wsImpl.CONNECTING:this.unsentMessagesQueue.push(e);break;default:this.reconnecting||this.eventEmitter.emit("error",new Error("A message was not sent because socket is not connected, is closing or is already closed. Message was: "+JSON.stringify(e)))}},e.prototype.generateOperationId=function(){return String(++this.nextOperationId)},e.prototype.tryReconnect=function(){var e=this;if(this.reconnect&&!(this.backoff.attempts>=this.reconnectionAttempts)){this.reconnecting||(Object.keys(this.operations).forEach((function(t){e.unsentMessagesQueue.push(e.buildMessage(t,b.default.GQL_START,e.operations[t].options))})),this.reconnecting=!0),this.clearTryReconnectTimeout();var t=this.backoff.duration();this.tryReconnectTimeoutId=setTimeout((function(){e.connect()}),t)}},e.prototype.flushUnsentMessagesQueue=function(){var e=this;this.unsentMessagesQueue.forEach((function(t){e.sendMessageRaw(t)})),this.unsentMessagesQueue=[]},e.prototype.checkConnection=function(){this.wasKeepAliveReceived?this.wasKeepAliveReceived=!1:this.reconnecting||this.close(!1,!0)},e.prototype.checkMaxConnectTimeout=function(){var e=this;this.clearMaxConnectTimeout(),this.maxConnectTimeoutId=setTimeout((function(){e.status!==e.wsImpl.OPEN&&(e.reconnecting=!0,e.close(!1,!0))}),this.maxConnectTimeGenerator.duration())},e.prototype.connect=function(){var e,t=this;this.client=new((e=this.wsImpl).bind.apply(e,a([void 0,this.url,this.wsProtocols],this.wsOptionArguments))),this.checkMaxConnectTimeout(),this.client.onopen=function(){return i(t,void 0,void 0,(function(){var e,t;return o(this,(function(r){switch(r.label){case 0:if(this.status!==this.wsImpl.OPEN)return[3,4];this.clearMaxConnectTimeout(),this.closedByUser=!1,this.eventEmitter.emit(this.reconnecting?"reconnecting":"connecting"),r.label=1;case 1:return r.trys.push([1,3,,4]),[4,this.connectionParams()];case 2:return e=r.sent(),this.sendMessage(void 0,b.default.GQL_CONNECTION_INIT,e),this.flushUnsentMessagesQueue(),[3,4];case 3:return t=r.sent(),this.sendMessage(void 0,b.default.GQL_CONNECTION_ERROR,t),this.flushUnsentMessagesQueue(),[3,4];case 4:return[2]}}))}))},this.client.onclose=function(){t.closedByUser||t.close(!1,!1)},this.client.onerror=function(e){t.eventEmitter.emit("error",e)},this.client.onmessage=function(e){var r=e.data;t.processReceivedData(r)}},e.prototype.processReceivedData=function(e){var t,r;try{r=(t=JSON.parse(e)).id}catch(t){throw new Error("Message must be JSON-parseable. Got: "+e)}if(-1===[b.default.GQL_DATA,b.default.GQL_COMPLETE,b.default.GQL_ERROR].indexOf(t.type)||this.operations[r])switch(t.type){case b.default.GQL_CONNECTION_ERROR:this.connectionCallback&&this.connectionCallback(t.payload);break;case b.default.GQL_CONNECTION_ACK:this.eventEmitter.emit(this.reconnecting?"reconnected":"connected",t.payload),this.reconnecting=!1,this.backoff.reset(),this.maxConnectTimeGenerator.reset(),this.connectionCallback&&this.connectionCallback();break;case b.default.GQL_COMPLETE:var i=this.operations[r].handler;delete this.operations[r],i.call(this,null,null);break;case b.default.GQL_ERROR:this.operations[r].handler(this.formatErrors(t.payload),null),delete this.operations[r];break;case b.default.GQL_DATA:var o=t.payload.errors?n(n({},t.payload),{errors:this.formatErrors(t.payload.errors)}):t.payload;this.operations[r].handler(null,o);break;case b.default.GQL_CONNECTION_KEEP_ALIVE:var a=void 0===this.wasKeepAliveReceived;this.wasKeepAliveReceived=!0,a&&this.checkConnection(),this.checkConnectionIntervalId&&(clearInterval(this.checkConnectionIntervalId),this.checkConnection()),this.checkConnectionIntervalId=setInterval(this.checkConnection.bind(this),this.wsTimeout);break;default:throw new Error("Invalid message type!")}else this.unsubscribe(r)},e.prototype.unsubscribe=function(e){this.operations[e]&&(delete this.operations[e],this.setInactivityTimeout(),this.sendMessage(e,b.default.GQL_STOP,void 0))},e}();t.SubscriptionClient=y}).call(this,r("c8ba"))},6788:function(e,t){e.exports={functional:!0,render(e,t){const{_c:r,_v:n,data:i,children:o=[]}=t,{class:a,staticClass:s,style:c,staticStyle:l,attrs:u={},...p}=i;return r("svg",{class:[a,s],style:[c,l],attrs:Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 16 16"},u),...p},o.concat([r("path",{attrs:{"fill-rule":"evenodd",d:"M0 6l5.584-.5L8 0l2.5 5.5L16 6l-4 4 1 6-5-3.5L3 16l1-6z"}})]))}}},6981:function(e,t,r){ + }`}).subscribe({next(t){We.debug("[🪐 serverStateFromApi] serverRegistrationSub res %o",t),e.commit("SET_REGISTRATION_SUB",t.data.registration)},error:t=>(e.commit("SET_MY_SERVERS_ERROR",t),e.state.myServersError)}))),We.debug("[🪐 serverStateFromApi] DONE %o",r.data),r.data},stopGraphqlClient:(e,t)=>(We.debug("[stopGraphqlClient] clients %o",{clients:Pn,apikey:t}),Object.keys(Pn).includes(t)?(We.debug("[stopGraphqlClient] found existing client & stopping it %o",Pn[t]),Pn[t].stop()):We.debug("[stopGraphqlClient] client does not exist for apikey %o",t))};o.default.use(b.a),o.default.config.devtools=!0;var bi=new b.a.Store({state:Ee,getters:$e,mutations:He,actions:vi});var yi=v({i18n:he,store:bi,name:"Authed",props:["propRegistered"],data:()=>({regChanged:!1,popUpClosedTimer:null}),computed:{...Object(b.e)(["state","registered","isPopUpOpen","signOutPayload","wizardWindow"]),...Object(b.c)(["stateData"]),computedReg(){return null===this.registered?!!this.propRegistered:this.registered},buttonPayload(){return this.stateData.error?this.wizardWindow:this.computedReg?this.signOutPayload:this.wizardWindow},buttonText(){return this.stateData.error?this.$t("fixError"):this.isPopUpOpen?this.$t("backToPopUp"):"ENOKEYFILE"===this.state?this.$t("getStarted"):this.computedReg?this.$t("signOut"):this.$t("signIn")},buttonTitle(){return this.$t("upc.opensNewHttpsWindow.base",[this.buttonText])}},watch:{isPopUpOpen(e){!e&&this.regChanged&&(We.debug("[REGISTERED CHANGED] 🔥 reload webGUI settings"),window.location.reload())},registered(e,t){null!==t&&e!==this.propRegistered&&(We.debug("[REGISTERED CHANGED]",{newVal:e,oldVal:t}),this.regChanged=!0,this.isPopUpOpen||(We.debug("[REGISTERED CHANGED] 🔥🔥 reload webGUI settings"),window.location.reload()))}},methods:{...Object(b.b)(["closePopUp","openPopUp"])}},(function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("transition",{attrs:{appear:"",name:"fade",mode:"out-in"}},[r("div",[r("button",{attrs:{type:"button",title:e.buttonTitle},on:{click:function(t){return e.openPopUp(e.buttonPayload)}}},[e._v(e._s(e.buttonText))]),r("transition",{attrs:{name:"fade",mode:"out-in"}},[e.isPopUpOpen?r("button",{staticClass:"ml-8px",attrs:{type:"button"},on:{click:function(t){return e.closePopUp()}}},[e._v(e._s(e.$t("closePopUp")))]):e._e()])],1)])}),[],!1,(function(e){var t=r("dfd4");t.__inject__&&t.__inject__(e)}),"5e5ba4da",null,!0).exports,wi=(v({name:"keyline",props:{color:{type:String,default:"grey"}},computed:{computedClass(){return"gradient"===this.color?"h-2px bg-gradient-r-red-orange":"h-1px bg-grey"}}},(function(){var e=this,t=e.$createElement;return(e._self._c||t)("hr",{staticClass:"w-full shadow-none border-none rounded-none",class:e.computedClass})}),[],!1,null,null,null,!0).exports,function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("svg",{staticClass:"unraid_sc_loader",style:e.styles,attrs:{xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink",viewBox:"0 0 133.52 76.97",height:e.height+"px",role:"img"}},[r("title",[e._v(e._s(e.title))]),r("desc",[e._v("Unraid logo animating with a wave like effect")]),r("defs",[r("linearGradient",{attrs:{id:e.random,x1:"23.76",y1:"81.49",x2:"109.76",y2:"-4.51",gradientUnits:"userSpaceOnUse"}},[r("stop",{attrs:{offset:"0","stop-color":e.gradientStart}}),r("stop",{attrs:{offset:"1","stop-color":e.gradientStop}})],1)],1),r("path",{staticClass:"unraid_sc_loader_9",attrs:{d:"m70,19.24zm57,0l6.54,0l0,38.49l-6.54,0l0,-38.49z",fill:"url(#"+e.random+")"}}),r("path",{staticClass:"unraid_sc_loader_8",attrs:{d:"m70,19.24zm47.65,11.9l-6.55,0l0,-23.79l6.55,0l0,23.79z",fill:"url(#"+e.random+")"}}),r("path",{staticClass:"unraid_sc_loader_7",attrs:{d:"m70,19.24zm31.77,-4.54l-6.54,0l0,-14.7l6.54,0l0,14.7z",fill:"url(#"+e.random+")"}}),r("path",{staticClass:"unraid_sc_loader_6",attrs:{d:"m70,19.24zm15.9,11.9l-6.54,0l0,-23.79l6.54,0l0,23.79z",fill:"url(#"+e.random+")"}}),r("path",{staticClass:"unraid_sc_loader_5",attrs:{d:"m63.49,19.24l6.51,0l0,38.49l-6.51,0l0,-38.49z",fill:"url(#"+e.random+")"}}),r("path",{staticClass:"unraid_sc_loader_4",attrs:{d:"m70,19.24zm-22.38,26.6l6.54,0l0,23.78l-6.54,0l0,-23.78z",fill:"url(#"+e.random+")"}}),r("path",{staticClass:"unraid_sc_loader_3",attrs:{d:"m70,19.24zm-38.26,43.03l6.55,0l0,14.73l-6.55,0l0,-14.73z",fill:"url(#"+e.random+")"}}),r("path",{staticClass:"unraid_sc_loader_2",attrs:{d:"m70,19.24zm-54.13,26.6l6.54,0l0,23.78l-6.54,0l0,-23.78z",fill:"url(#"+e.random+")"}}),r("path",{staticClass:"unraid_sc_loader_1",attrs:{d:"m70,19.24zm-63.46,38.49l-6.54,0l0,-38.49l6.54,0l0,38.49z",fill:"url(#"+e.random+")"}})])});var xi=v({name:"loading",props:{height:{type:Number,default:64},styles:{type:Object,default:()=>({})},gradientStart:{type:String,default:"#e32929"},gradientStop:{type:String,default:"#ff8d30"},title:{type:String,default:"Loading"}},data:()=>({random:Math.random().toString(36).substring(7)})},wi,[],!1,(function(e){var t=r("ef7a");t.__inject__&&t.__inject__(e)}),null,null,!0).exports,_i=(v({name:"logo",props:{gradientStart:{type:String,default:"#e32929"},gradientStop:{type:String,default:"#ff8d30"}},data:()=>({random:Math.random().toString(36).substring(7)})},(function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("svg",{attrs:{xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink",viewBox:"0 0 222.36 39.04"}},[r("defs",[r("linearGradient",{attrs:{id:e.random,x1:"47.53",y1:"79.1",x2:"170.71",y2:"-44.08",gradientUnits:"userSpaceOnUse"}},[r("stop",{attrs:{offset:"0","stop-color":e.gradientStart}}),r("stop",{attrs:{offset:"1","stop-color":e.gradientStop}})],1)],1),r("title",[e._v("Unraid Logo")]),r("path",{attrs:{d:"M146.7,29.47H135l-3,9h-6.49L138.93,0h8l13.41,38.49h-7.09L142.62,6.93l-5.83,16.88h8ZM29.69,0V25.4c0,8.91-5.77,13.64-14.9,13.64S0,34.31,0,25.4V0H6.54V25.4c0,5.17,3.19,7.92,8.25,7.92s8.36-2.75,8.36-7.92V0ZM50.86,12v26.5H44.31V0h6.11l17,26.5V0H74V38.49H67.9ZM171.29,0h6.54V38.49h-6.54Zm51.07,24.69c0,9-5.88,13.8-15.17,13.8H192.67V0H207.3c9.18,0,15.06,4.78,15.06,13.8ZM215.82,13.8c0-5.28-3.3-8.14-8.52-8.14h-8.08V32.77h8c5.33,0,8.63-2.8,8.63-8.08ZM108.31,23.92c4.34-1.6,6.93-5.28,6.93-11.55C115.24,3.68,110.18,0,102.48,0H88.84V38.49h6.55V5.66h6.87c3.8,0,6.21,1.82,6.21,6.71s-2.41,6.76-6.21,6.76H98.88l9.21,19.36h7.53Z",fill:"url(#"+e.random+")"}})])}),[],!1,null,null,null,!0).exports,function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("svg",{attrs:{xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink",viewBox:"0 0 133.52 76.97"}},[r("title",[e._v("unraid-mark")]),r("defs",[r("linearGradient",{attrs:{id:e.random,x1:"23.76",y1:"81.49",x2:"109.76",y2:"-4.51",gradientUnits:"userSpaceOnUse"}},[r("stop",{attrs:{offset:"0","stop-color":e.gradientStart}}),r("stop",{attrs:{offset:"1","stop-color":e.gradientStop}})],1)],1),r("path",{attrs:{fill:"url(#"+e.random+")",d:"M63.49,19.24H70V57.73H63.49ZM6.54,57.73H0V19.24H6.54Zm25.2,4.54h6.55V77H31.74ZM15.87,45.84h6.54V69.62H15.87Zm31.75,0h6.54V69.62H47.62ZM127,19.24h6.54V57.73H127ZM101.77,14.7H95.23V0h6.54Zm15.88,16.44H111.1V7.35h6.55Zm-31.75,0H79.36V7.35H85.9Z"}})])}),Ei=v({name:"logo",props:{gradientStart:{type:String,default:"#e32929"},gradientStop:{type:String,default:"#ff8d30"}},data:()=>({random:Math.random().toString(36).substring(7)})},_i,[],!1,null,null,null,!0).exports,Si=r("5d74"),ki=r.n(Si);o.default.use(ki.a,{url:(Object({VUE_APP_REGWIZ_URL:"https://registration.unraid.net",VUE_APP_PURCHASE_URL:"https://unraid.net/preflight",VUE_APP_MIN_API_VER:"2.49.2",VUE_APP_REC_API_VER:"2.52.1",VUE_APP_MIN_OS_VER:"6.10.0",VUE_APP_REC_OS_VER:"6.11.0",NODE_ENV:"production",BASE_URL:"/"}).VUE_APP_SPRITE_URL_PREFIX?Object({VUE_APP_REGWIZ_URL:"https://registration.unraid.net",VUE_APP_PURCHASE_URL:"https://unraid.net/preflight",VUE_APP_MIN_API_VER:"2.49.2",VUE_APP_REC_API_VER:"2.52.1",VUE_APP_MIN_OS_VER:"6.10.0",VUE_APP_REC_OS_VER:"6.11.0",NODE_ENV:"production",BASE_URL:"/"}).VUE_APP_SPRITE_URL_PREFIX:"")+"/assets/svg/sprite.svg",class:"svg-icon"});var Oi=(v({name:"svg-icon",props:{symbol:{type:String,required:!0},symbolClass:String}},(function(){var e=this,t=e.$createElement;return(e._self._c||t)("svg",{directives:[{name:"svg",rawName:"v-svg"}],staticClass:"unraid-svg-icon",class:e.symbolClass,attrs:{symbol:e.symbol,title:e.symbol,role:"presentation"}})}),[],!1,(function(e){var t=r("39a1");t.__inject__&&t.__inject__(e)}),"3b60bb54",null,!0).exports,function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("div",{staticClass:"text-center w-full"},[r("header",[r("h2",{staticClass:"text-24px md:text-30px"},[r("span",{domProps:{innerHTML:e._s(e.computedHeading)}}),e.showTrialWelcome?r("ui-beta",{staticClass:"title-beta relative ml-4px"}):e._e()],1),r("div",{staticClass:"text-14px opacity-90 mt-12px mx-auto prose",class:{"text-center":e.stateData.messageCenter||e.showTrialWelcome,"text-left":!e.stateData.messageCenter}},[r("div",{domProps:{innerHTML:e._s(e.computedSubheading)}}),e.showExpiretime?r("HelperTimeConvert",{staticClass:"italic text-center font-semibold mt-16px"}):e._e()],1)]),r("div",{staticClass:"ActionRequired flex flex-col justify-center mt-16px"},[e.isPopUpOpen?[r("UiButton",{staticClass:"button button-alt w-full mt-8px",attrs:{text:e.$t("backToPopUp")},on:{"btn-click":function(t){return e.openPopUp(e.signInPayload)}}}),r("UiButton",{staticClass:"button-fine-error text-grey-mid w-full mt-8px",attrs:{text:e.$t("closePopUp")},on:{"btn-click":function(t){return e.closePopUp()}}})]:[(!e.hideMyServers||e.apiVersion&&"0.0.0"!==e.apiVersion)&&e.stateData.actions.includes("register")?[r("UiButton",{staticClass:"button button-alt w-full mt-8px",attrs:{routeName:e.CAN_POST_MESSAGE?"SignIn":null,text:e.$t("signIn")},on:{"btn-click":function(t){return e.openPopUp(e.signInPayload)}}}),e.guidRegistered||e.forumaccount?e._e():r("UiButton",{staticClass:"button button-alt w-full mt-8px",attrs:{routeName:e.CAN_POST_MESSAGE?"SignUp":null,text:e.$t("signUp")},on:{"btn-click":function(t){return e.openPopUp(e.signUpPayload)}}})]:e._e(),"TRIAL"===e.state&&e.hideMyServers&&!e.CAN_POST_MESSAGE?r("UiButton",{staticClass:"button button-alt w-full mt-8px",attrs:{text:e.$t("upc.enhanceYourExperienceWithMyServers")},on:{"btn-click":function(t){return e.togglePromo()}}}):e._e(),e.stateData.actions.includes("startTrial")&&!e.CAN_POST_MESSAGE||"development"===e.NODE_ENV?r("UiButton",{staticClass:"button button-alt w-full mt-8px",attrs:{text:e.$t("actions.startTrial")},on:{"btn-click":function(t){return e.startTrial()}}}):e._e(),e.stateData.actions.includes("purchase")?r("UiButton",{staticClass:"button button-alt w-full mt-8px",attrs:{hrefUrl:e.CAN_POST_MESSAGE?e.purchaseWindow.url:null,text:e.$t("actions.purchase")},on:{"btn-click":function(t){return e.openPopUp(e.purchaseWindow)}}}):e._e(),e.stateData.actions.includes("purchase")?r("UiButton",{staticClass:"button button-alt w-full mt-8px",attrs:{hrefUrl:e.CAN_POST_MESSAGE?e.redeemWindow.url:null,text:"Redeem Activation Code"},on:{"btn-click":function(t){return e.openPopUp(e.redeemWindow)}}}):e._e(),e.stateData.actions.includes("upgrade")?r("UiButton",{staticClass:"button button-alt w-full mt-8px",attrs:{hrefUrl:e.CAN_POST_MESSAGE?e.purchaseWindow.url:null,text:e.$t("actions.upgrade")},on:{"btn-click":function(t){return e.openPopUp(e.purchaseWindow)}}}):e._e(),e.stateData.actions.includes("replace")&&e.replaceable?r("UiButton",{staticClass:"button w-full mt-8px",attrs:{routeName:e.CAN_POST_MESSAGE?"ReplaceKey":null,text:e.$t("actions.replace")},on:{"btn-click":function(t){return e.openPopUp(e.replaceKeyPayload)}}}):e._e(),e.stateData.actions.includes("replace")&&!e.replaceable?r("UiButton",{staticClass:"button w-full mt-8px",attrs:{text:e.$t("actions.replaceIneligible"),title:e.$t("stateData.EGUID.error.message.replacementIneligible"),disabled:""},on:{"btn-click":function(t){return e.niceTry()}}}):e._e(),e.stateData.actions.includes("recover")?r("UiButton",{staticClass:"button w-full mt-8px",attrs:{routeName:e.CAN_POST_MESSAGE?"RecoverKey":null,text:e.$t("actions.recover")},on:{"btn-click":function(t){return e.openPopUp(e.recoverKeyPayload)}}}):e._e(),e.stateData.actions.includes("continueTrial")?r("UiButton",{staticClass:"button w-full mt-8px",attrs:{text:e.$t("regWizPopUp.continueTrial")},on:{"btn-click":function(t){e.CAN_POST_MESSAGE?e.closePopUpFromPopUp():e.SET_IS_LAUNCHPAD_OPEN(!1)}}}):e._e(),e.stateData.actions.includes("extend")?r("UiButton",{staticClass:"button w-full mt-8px",attrs:{routeName:e.CAN_POST_MESSAGE?"ExtendTrial":null,text:e.$t("actions.extend")},on:{"btn-click":function(t){return e.openPopUp(e.extendTrialPayload)}}}):e._e(),e.stateData.actions.includes("close")?r("UiButton",{staticClass:"button w-full mt-8px",attrs:{text:e.$t("continueToUnraid")},on:{"btn-click":function(t){e.CAN_POST_MESSAGE?e.closePopUpFromPopUp():e.SET_IS_LAUNCHPAD_OPEN(!1)}}}):e._e(),e.stateData.actions.includes("signOut")&&e.CAN_POST_MESSAGE?r("UiButton",{staticClass:"button-fine-error text-grey-mid w-full mt-8px",attrs:{routeName:e.CAN_POST_MESSAGE?"SignOut":null,text:e.$t("signOut")},on:{"btn-click":function(t){return e.openPopUp(e.signOutPayload)}}}):e._e()]],2)])}),Ti=r("5a0c"),Ii=r.n(Ti);const Ai=(e,t,r,n,i,o,a)=>({years:e,months:t,days:r,hours:n,minutes:i,seconds:o,firstDateWasLater:a});var Ri=(e,t,r)=>{let n,i=Ii()(e),o=Ii()(t);if(i.isSame(o))return r?Ai(0,0,0,0,0,0,!1):"";if(i.isAfter(o)){const e=i;i=o,o=e,n=!0}else n=!1;let a=o.year()-i.year(),s=o.month()-i.month(),c=o.date()-i.date(),l=o.hour()-i.hour(),u=o.minute()-i.minute(),p=o.second()-i.second();if(p<0&&(p=60+p,u-=1),u<0&&(u=60+u,l-=1),l<0&&(l=24+l,c-=1),c<0){const e=Ii()(`${o.year()}-${o.month()+1}`).subtract(1,"M").daysInMonth();c=e{const r=e?Ii()(parseInt(e,10)):Ii()(),n=t?Ii()(parseInt(t,10)):Ii()();return Ri(r,n,!0)};var Pi=(e,t)=>t?Ci(e,""):Ci("",e),Ni=r("23ad"),Mi=r.n(Ni);r("e072"),r("6210"),r("e5b7");const Di=document.getElementsByTagName("unraid-user-profile")[0];if(Di){const e=Di.getAttribute("locale").slice(0,2);Ii.a.locale(e),We.debug("[formatDate] dayjs.locale()",Ii.a.locale())}Ii.a.extend(Mi.a);var Ui=e=>Ii()(parseInt(e,10)).format("llll"),Li=v({data:()=>({parsedUptime:"",parsedExpireTime:""}),computed:{...Object(b.c)(["showExpiretime"]),...Object(b.e)(["state","expiretime","uptime"]),formattedUptime(){return Ui(this.uptime)},formattedExpireTime(){return Ui(this.expiretime)},timeCopy(){return this.showExpiretime?{title:"EEXPIRED"===this.state?this.$t("upc.meta.trial.expired.date",{date:this.formattedExpireTime}):this.$t("upc.meta.trial.active.date",{date:this.formattedExpireTime}),text:"EEXPIRED"===this.state?this.$t("upc.meta.trial.expired.timeDiff",{timeDiff:this.parsedExpireTime}):this.$t("upc.meta.trial.active.timeDiff",{timeDiff:this.parsedExpireTime})}:{title:this.$t("upc.meta.uptime.date",{date:this.formattedUptime}),text:this.$t("upc.meta.uptime.readable",{timeDiff:this.parsedUptime})}}},methods:{buildStringFromValues({years:e,months:t,days:r,hours:n,minutes:i,seconds:o,firstDateWasLater:a,displaySecondsInStringReturn:s}){const c=[],l={year:this.$t("year"),years:this.$t("years"),month:this.$t("month"),months:this.$t("months"),day:this.$t("day"),days:this.$t("days"),hour:this.$t("hour"),hours:this.$t("hours"),minute:this.$t("minute"),minutes:this.$t("minutes"),second:this.$t("second"),seconds:this.$t("seconds"),firstDateWasLater:this.$t("ago"),delimiter:" "},u=(e,t)=>`${e} ${l[t+(1===e?"":"s")]}`;return e&&c.push(u(e,"year")),t&&c.push(u(t,"month")),r&&c.push(u(r,"day")),n&&c.push(u(n,"hour")),i&&c.push(u(i,"minute")),!o||(e||t||r||n||i)&&!s||c.push(u(o,"second")),a&&c.push(l.firstDateWasLater),c.join(l.delimiter)},runTimeDiff(){this.uptime&&(this.parsedUptime=this.buildStringFromValues(Pi(this.uptime,!0))),this.expiretime&&(this.parsedExpireTime=this.buildStringFromValues(Pi(this.expiretime,!1)))},letsGo(){this.runTimeDiff(),this.interval=setInterval(()=>{this.runTimeDiff()},1e3)}},created(){this.letsGo()},beforeDestroy(){clearInterval(this.interval)}},(function(){var e=this,t=e.$createElement;return(e._self._c||t)("p",{staticClass:"select-all",attrs:{title:e.timeCopy.title}},[e._v(e._s(e.timeCopy.text))])}),[],!1,null,null,null,!0).exports,ji=v({props:{hrefUrl:{type:[Boolean,URL],default:!1},routeName:{type:String},text:{type:String,required:!0}},computed:{}},(function(){var e=this,t=e.$createElement,r=e._self._c||t;return e.routeName?r("router-link",{attrs:{to:{name:e.routeName}}},[e._v(e._s(e.text))]):e.hrefUrl?r("a",{attrs:{href:e.hrefUrl}},[e._v(e._s(e.text))]):r("button",{on:{click:function(t){return e.$emit("btn-click")}}},[e._v(e._s(e.text))])}),[],!1,null,null,null,!0).exports,Fi=v({props:{colorClasses:{type:String,default:"text-grey-mid border-grey-mid"}}},(function(){var e=this,t=e.$createElement;return(e._self._c||t)("span",{staticClass:"text-10px uppercase py-4px px-6px border-2 rounded-full",class:e.colorClasses},[e._v(e._s(e.$t("upc.myServers.beta")))])}),[],!1,null,null,null,!0).exports;var $i=v({components:{HelperTimeConvert:Li,UiButton:ji,UiBeta:Fi},props:{hidePurchaseButtons:{type:Boolean,default:!1}},data:()=>({CAN_POST_MESSAGE:Ae,NODE_ENV:me}),computed:{...Object(b.c)(["stateData","showExpiretime"]),...Object(b.e)(["apiVersion","extendTrialPayload","forumaccount","guidBlacklisted","guidRegistered","hideMyServers","isPopUpOpen","messages","purchaseWindow","recoverKeyPayload","redeemWindow","registered","replaceable","replaceKeyPayload","signInPayload","signOutPayload","signUpPayload","state","wizardWindow"]),showTrialWelcome(){return"ENOKEYFILE"!==this.state&&!this.state.error&&!this.hideMyServers&&!this.registered},computedHeading(){return this.showTrialWelcome?this.$t("upc.thankYouForInstallingMyServers"):this.stateData.heading?this.stateData.heading:this.stateData.error.heading},computedSubheading(){return this.showTrialWelcome?this.$t("upc.connectYourUnraidnetAccountToGetStarted"):this.stateData.message?this.stateData.message:this.stateData.error.message}},methods:{...Object(b.b)(["openPopUp","closePopUp","closePopUpFromPopUp","startTrial","togglePromo"]),...Object(b.d)(["SET_IS_LAUNCHPAD_OPEN"]),niceTry(){alert("❌ Nice try you little sneak ❌")}}},Oi,[],!1,(function(e){var t=r("2251");t.__inject__&&t.__inject__(e)}),null,null,!0).exports;var Vi=v({i18n:he,store:bi,name:"Launchpad",props:["serverstate","webguiTranslations"],components:{UnraidLoading:xi,LaunchpadActionRequired:$i},computed:{...Object(b.e)(["errorMessage","guid","hideMyServers","isLaunchpadOpen","isPopUpOpen","loading","registered"]),...Object(b.c)(["server"])},methods:{...Object(b.b)(["closePopUp","setStateFromWebComponentProp","validateGuid"]),...Object(b.d)(["SET_IS_LAUNCHPAD_OPEN"])},watch:{signedOutWithKey(e,t){e&&!t&&this.validateGuid()},isPopUpOpen(e,t){!e&&t&&this.registered&&this.SET_IS_LAUNCHPAD_OPEN(!1)}},created(){if(this.serverstate&&this.setStateFromWebComponentProp(this.serverstate),this.guid)this.validateGuid();else{const e=setInterval(()=>{this.guid&&(clearInterval(e),this.validateGuid())},250)}}},(function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("transition",{attrs:{appear:"",name:"fade",mode:"in-out"}},[r("div",{directives:[{name:"show",rawName:"v-show",value:e.isLaunchpadOpen,expression:"isLaunchpadOpen"}],staticClass:"fixed inset-0 z-10 flex flex-col justify-start items-end mt-90px"},[r("transition",{attrs:{appear:"",name:"fade",mode:"in-out"}},[r("div",{directives:[{name:"show",rawName:"v-show",value:e.isLaunchpadOpen,expression:"isLaunchpadOpen"}],staticClass:"absolute inset-0 z-0 bg-beta opacity-70 cursor-pointer",attrs:{title:e.$t("closeLaunchpad")},on:{click:function(t){return e.SET_IS_LAUNCHPAD_OPEN(!1)}}})]),r("transition",{attrs:{appear:"",name:"slideVerticalFade",mode:"in-out"}},[r("main",{directives:[{name:"show",rawName:"v-show",value:e.isLaunchpadOpen,expression:"isLaunchpadOpen"}],staticClass:"TopBlip text-beta bg-alpha border-grey-darkest text-center relative z-10 w-full max-w-4xl mr-8px p-24px md:p-32px lg:px-40px shadow-md rounded-lg"},[e.loading?[r("UnraidLoading",{staticClass:"mx-auto",attrs:{height:64}}),"string"==typeof e.loading?r("h3",{staticClass:"text-20px italic mt-8px mb-0"},[e._v(e._s(e.loading))]):e._e()]:[r("LaunchpadActionRequired",{attrs:{hidePurchaseButtons:!e.hideMyServers&&!e.registered}}),e.errorMessage?r("p",{staticClass:"text-red font-semibold italic mt-16px mb-0",domProps:{innerHTML:e._s(e.errorMessage)}}):e._e()]],2)])],1)])}),[],!1,(function(e){var t=r("f153");t.__inject__&&t.__inject__(e)}),null,null,!0).exports,Gi=r("99c0"),zi=r.n(Gi),Bi=r("9f96"),Wi=r.n(Bi),Hi=r("56c3"),Yi=r.n(Hi),qi=r("381c"),Qi=r.n(qi),Ki=r("6788"),Xi=r.n(Ki),Ji=v({name:"Feature",props:["title","copy","svg","center"]},(function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("div",{staticClass:"text-left relative flex overflow-hidden p-8px",class:{"w-full sm:w-1/2":!e.center,"max-w-640px":e.center}},[e.center?e._e():r("span",{staticClass:"flex-shrink-0"},[e._t("default")],2),r("div",{staticClass:"inline-flex flex-col pl-4 mr-4",class:{"text-center":e.center}},[r("h3",{staticClass:"font-semibold",class:{"mt-0 mb-4px":e.copy,"my-0":!e.copy,"flex flex-row justify-center items-center":e.center}},[e.center?r("span",{staticClass:"flex-shrink-0 mr-8px"},[e._t("default")],2):e._e(),e._v(" "+e._s(e.title)+" ")]),e.copy?r("p",{staticClass:"opacity-90 py-0",class:{"px-8px":e.center},domProps:{innerHTML:e._s(e.copy)}}):e._e()])])}),[],!1,null,null,null,!0).exports;var Zi=v({i18n:he,store:bi,name:"Promo",components:{Feature:Ji,UnraidSvgUiRemoteAccess:zi.a,UnraidSvgUiDiagnostics:Wi.a,UnraidSvgUiUsb:Yi.a,UnraidSvgUiKey:Qi.a,UnraidSvgUtilStar:Xi.a},computed:{...Object(b.e)(["isPromoOpen","devEnv"]),...Object(b.c)(["features"]),heading(){return this.$t("promoHeading").replace("(BETA)",`${he.tc("upc.myServers.beta")}`)}},methods:{...Object(b.d)(["SET_IS_PROMO_OPEN"]),installMyServers(e=""){try{const t="https://sfo2.digitaloceanspaces.com/unraid-dl/unraid-api/"+(e||"dynamix.unraid.net.plg");We.debug("[installMyServers] %s",t),sessionStorage.setItem("clickedInstallMyServers",Date.now()),this.SET_IS_PROMO_OPEN(!1),"function"==typeof openPlugin?(We.debug("[installMyServers] using openPlugin %s",t),openPlugin("plugin install "+t,this.$t("upc.installingMyServers"),"","refresh")):(We.debug("[installMyServers] using openBox %s",t),openBox("/plugins/dynamix.plugin.manager/scripts/plugin&arg1=install&arg2="+t,this.$t("upc.installingMyServers"),600,900,!0))}catch(e){We.error(e)}}},watch:{isPromoOpen(e,t){t&&!e&&sessionStorage.removeItem("showPromoPostTrialInstall")},isLaunchpadOpen(e,t){t&&!e&&sessionStorage.getItem("showPromoPostTrialInstall")&&this.SET_IS_PROMO_OPEN(!1)}}},(function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("transition",{attrs:{appear:"",name:"fade",mode:"in-out"}},[r("div",{directives:[{name:"show",rawName:"v-show",value:e.isPromoOpen,expression:"isPromoOpen"}],staticClass:"fixed inset-0 z-10 flex flex-col justify-start items-end mt-90px"},[r("transition",{attrs:{appear:"",name:"fade",mode:"in-out"}},[r("div",{directives:[{name:"show",rawName:"v-show",value:e.isPromoOpen,expression:"isPromoOpen"}],staticClass:"fixed inset-0 z-0 bg-beta opacity-70 cursor-pointer",attrs:{title:e.$t("closePromo")},on:{click:function(t){return e.SET_IS_PROMO_OPEN(!1)}}})]),r("transition",{attrs:{appear:"",name:"slideVerticalFade",mode:"in-out"}},[r("div",{directives:[{name:"show",rawName:"v-show",value:e.isPromoOpen,expression:"isPromoOpen"}],staticClass:"Promo TopBlip text-beta bg-alpha border-grey-darkest text-center relative z-10 w-full max-w-800px mr-8px p-24px sm:p-32px lg:px-40px shadow-md rounded-lg"},[r("h2",{staticClass:"text-24px my-0",domProps:{innerHTML:e._s(e.heading)}}),r("div",{staticClass:"text-14px flex flex-wrap justify-center my-16px"},e._l(e.features,(function(t,n){return r("feature",{key:n,attrs:{title:t.title,copy:t.copy,center:t.center||!1}},["ui--remote-access"===t.svg?r("UnraidSvgUiRemoteAccess",{staticClass:"fill-current mt-1 w-28px h-28px"}):e._e(),"ui--diagnostics"===t.svg?r("UnraidSvgUiDiagnostics",{staticClass:"fill-current mt-1 w-28px h-28px"}):e._e(),"ui--usb"===t.svg?r("UnraidSvgUiUsb",{staticClass:"fill-current mt-1 w-28px h-28px"}):e._e(),"ui--key"===t.svg?r("UnraidSvgUiKey",{staticClass:"fill-current mt-1 w-28px h-28px"}):e._e(),"util--star"===t.svg?r("UnraidSvgUtilStar",{staticClass:"fill-current mt-1 w-28px h-28px"}):e._e()],1)})),1),r("div",{staticClass:"w-full max-w-xs flex flex-col mx-auto"},[e.devEnv?r("button",{staticClass:"button mb-8px",on:{click:function(t){return e.installMyServers("dynamix.unraid.net.staging.plg")}}},[e._v("Install Staging")]):e._e(),r("button",{staticClass:"button",on:{click:function(t){return e.installMyServers()}}},[e._v(e._s(e.$t("installPlugin")))]),r("div",[r("a",{staticClass:"text-12px tracking-wide inline-block mx-8px opacity-60 hover:opacity-100 focus:opacity-100 underline mt-16px transition",attrs:{href:"https://wiki.unraid.net/My_Servers",target:"_blank",rel:"noopener noreferrer",title:e.$t("checkoutTheMyServersDocs")}},[e._v(e._s(e.$t("learnMore")))]),r("button",{staticClass:"text-12px tracking-wide inline-block mx-8px opacity-60 hover:opacity-100 focus:opacity-100 underline mt-16px transition",attrs:{title:e.$t("closePromo")},on:{click:function(t){return e.SET_IS_PROMO_OPEN(!1)}}},[e._v(" "+e._s(e.$t("noThanks"))+" ")])])])])])],1)])}),[],!1,(function(e){var t=r("5b71");t.__inject__&&t.__inject__(e)}),null,null,!0).exports;var eo=v({i18n:he,store:bi,name:"UpcTrigger",props:[],data:()=>({}),computed:{...Object(b.c)(["stateData","stateDataKeyActions"]),...Object(b.e)(["isPopUpOpen","state","triggerUPC","wizardWindow"]),copy(){return"BASIC"===this.state||"PLUS"===this.state?this.$t("upcTrigger.upgrade"):this.stateDataKeyActions?this.$t("upcTrigger.default"):""},buttonText(){return this.stateData.error?this.$t("fixError"):this.isPopUpOpen?this.$t("backToPopUp"):"ENOKEYFILE"===this.state?this.$t("getStarted"):this.stateDataKeyActions?this.$t("upcTrigger.open"):""},buttonTitle(){return this.stateDataKeyActions?this.$t("upcTrigger.open"):this.$t("upc.opensNewHttpsWindow.base",[this.buttonText])}},methods:{...Object(b.b)(["jumpToUpc","closePopUp","openPopUp"]),btnClick(){return this.isPopUpOpen?this.openPopUp(this.wizardWindow):this.jumpToUpc()}}},(function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("transition",{attrs:{appear:"",name:"fade",mode:"out-in"}},[e.buttonText?r("div",{staticClass:"flex flex-wrap pl-12px"},[r("p",{staticClass:"w-7/20 pr-12px",domProps:{innerHTML:e._s(e.copy)}}),r("div",{staticClass:"w-13/20 inline-flex flex-row"},[r("button",{attrs:{type:"button",title:e.buttonTitle,disabled:e.triggerUPC},on:{click:function(t){return e.btnClick()}}},[e._v(e._s(e.buttonText))]),r("transition",{attrs:{name:"fade",mode:"out-in"}},[e.isPopUpOpen?r("button",{staticClass:"ml-8px",attrs:{type:"button"},on:{click:function(t){return e.closePopUp()}}},[e._v(e._s(e.$t("closePopUp")))]):e._e()])],1)]):e._e()])}),[],!1,(function(e){var t=r("22c9");t.__inject__&&t.__inject__(e)}),null,null,!0).exports,to=r("ab14"),ro=r.n(to),no=r("c7db"),io=r("4eb5"),oo=r.n(io),ao=r("b692"),so=r.n(ao),co=r("a3b3"),lo=r.n(co),uo=r("8a86"),po=r.n(uo),fo=r("b2a0"),ho=r.n(fo),mo=r("b045"),go=r.n(mo),vo=r("45b7"),bo=r.n(vo),yo=r("73c6"),wo=r.n(yo),xo=r("94d0"),_o=r.n(xo),Eo=r("607e"),So=r.n(Eo),ko=v({props:{payload:{type:Object},text:{type:String},emphasize:{type:Boolean,default:!1},external:{type:Boolean,default:!0}},components:{UnraidSvgUiKey:Qi.a,UnraidSvgUtilNewWindow:lo.a}},(function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("li",[r("button",{staticClass:"group flex flex-row items-center justify-between",class:{"btn-emphasize":e.emphasize},attrs:{title:e.external?""+e.$t("upc.opensNewHttpsWindow.base",[e.text]):null},on:{click:function(t){return e.$emit("click")}}},[r("span",{staticClass:"inline-flex flex-row items-center"},[r("UnraidSvgUiKey",{staticClass:"fill-current w-12px h-12px mr-8px"}),e._v(" "+e._s(e.text)+" ")],1),e.external?r("UnraidSvgUtilNewWindow",{staticClass:"text-white opacity-0 group-hover:opacity-100 transition-opacity duration-200 ease-in-out fill-current w-12px h-12px ml-8px"}):e._e()],1)])}),[],!1,null,null,null,!0).exports,Oo=r("a190"),To=r.n(Oo),Io=r("a313"),Ao=r.n(Io),Ro=r("973e"),Co=r.n(Ro),Po=r("44f2"),No=r.n(Po);var Mo=v({components:{UnraidLoading:xi,UnraidSvgUiWarningFill:To.a,UnraidSvgUtilCheck:Ao.a,UnraidSvgUtilDelete:_o.a,UnraidSvgUtilHelp:Co.a,UnraidSvgUtilInfo:go.a,UnraidSvgUtilNewWindow:lo.a,UnraidSvgUtilTerminal:No.a,UnraidSvgUtilEdit:ho.a},props:["errorStateMessageVisible","hideotherservers","hideMyServers"],data:()=>({offlineTimer:sessionStorage.getItem("offlineTimer")||!1,restartTriggered:!1}),watch:{apikey(e,t){t||!e||this.hideMyServers||(We.debug("[watch.apikey] connect to unraid-api",{newVal:e,oldVal:t}),this.serversPlz()),!t||e||this.hideMyServers||(We.debug("[apikey removed] disconnect from unraid-api",{newVal:e,oldVal:t}),this.stopGraphqlClient(t))},noRemoteApikeyRegisteredWithPlg(e,t){t||!e||this.hideMyServers||(We.debug("[watch.noRemoteApikeyRegisteredWithPlg] connect to unraid-api",{newVal:e,oldVal:t}),this.serversPlz())},registered(e,t){t||!e||this.hideMyServers||(We.debug("[watch.apikey] connect to unraid-api",{newVal:e,oldVal:t}),this.serversPlz())},myServersError(e,t){!t||e||this.myServers.length||(We.debug("[watch.myServersError] connect to unraid-api",{newVal:e,oldVal:t}),this.serversPlz())},graphOnline(e,t){t&&!1===e&&this.timer("watch.graphOnline")}},computed:{...Object(b.c)(["errorTooManyDisks","hasRemoteApikey","keyTypeForPurchase","myServersOutOfDate","noRemoteApikeyRegisteredWithPlg","plgInstallFailed","stateData","validApiKeyLength"]),...Object(b.e)(["apikey","apiVersion","cloud","deviceCount","graphOnline","guid","locale","myServers","myServersError","myServersErrorShowSupportBtn","myServersLoading","pirateKey","registered","servername","signInPayload","state","wanip"]),currentServer(){return this.myServers?this.myServers.filter(e=>e.guid===this.guid?e:null)[0]:{name:this.servername,status:"offline"}},currentServerStatus(){return this.currentServer?this.currentServer.status:"offline"},filteredServers(){return this.myServers?this.hideotherservers?[]:this.myServers.filter(e=>e.guid!==this.guid?e:null).sort((e,t)=>e.name.localeCompare(t.name,"en",{numeric:!0,sensitivity:"base"})):[]},errorToggleText(){return this.stateData.error.message?"EEXPIRED"===this.state?this.stateData.error.heading:this.$t("fixError"):this.pirateKey||this.myServersError||this.noRemoteApikeyRegisteredWithPlg||this.errorTooManyDisks||this.myServersOutOfDate&&this.myServersOutOfDate.enabled||this.cloud&&this.cloud.error||this.plgInstallFailed?this.computedErrorHeading:""},errorToggleTitle(){if(this.stateData.error||this.stateData.message||this.myServersError||this.myServersOutOfDate&&this.myServersOutOfDate.enabled||this.cloud&&this.cloud.error||this.plgInstallFailed){return`${!this.stateData.error.message&&!this.stateData.message||this.noRemoteApikeyRegisteredWithPlg||this.errorTooManyDisks||!this.cloud||this.cloud.error?this.computedErrorHeading:this.stateData.humanReadable} • ${this.errorStateMessageVisible?this.$t("upc.myServers.closeDetails"):this.$t("learnMore")}`}return""},computedErrorHeading(){return this.noRemoteApikeyRegisteredWithPlg?this.$t("upc.noRemoteApikeyRegisteredWithPlg.heading"):this.stateData.error.heading?this.stateData.error.heading:this.pirateKey?this.$t("keyFileNotValid"):this.myServersLoading&&this.restartTriggered?"Unraid API":this.myServersError?this.myServersError.includes("Network error")?this.$t("upc.myServers.errors.unraidApi.heading"):this.$t("upc.myServers.errors.myServers.heading"):this.errorTooManyDisks?this.$t("upc.errorTooManyDisks.heading"):this.plgInstallFailed?this.$t("installFailed.heading"):this.myServersOutOfDate.enabled?this.myServersOutOfDate.heading:this.cloud&&this.cloud.error?this.$t("upc.myServers.errors.unraidApi.heading"):""},computedError(){if(this.noRemoteApikeyRegisteredWithPlg)return this.$t("upc.noRemoteApikeyRegisteredWithPlg.msg");if(this.stateData.error.message)return this.stateData.error.message;if(this.pirateKey)return this.$t("yargYePirate");if(this.myServersLoading&&this.restartTriggered)return this.$t("upc.myServers.restarting");if(this.myServersError)return this.myServersError.includes("Network error")?this.$t("upc.myServers.errors.unraidApi.message"):this.myServersError;if(this.errorTooManyDisks){const e=this.$t("upc.errorTooManyDisks.msg.base");return"Basic"===this.keyTypeForPurchase?`${this.$t("upc.errorTooManyDisks.msg.basic")} ${e}`:"Plus"===this.keyTypeForPurchase?`${this.$t("upc.errorTooManyDisks.msg.plus")} ${e}`:e}return this.plgInstallFailed?"The My Servers plugin installation failed. Rebooting will likely solve this.":this.myServersOutOfDate.enabled?this.myServersOutOfDate.message:this.cloud&&this.cloud.error?this.cloud.error:""},myServersOverflow(){return this.filteredServers.length>8},apiEnableRestartButton(){return!!this.apiVersion&&qe()(this.apiVersion,"2.42.5")&&this.offlineTimer&&!this.hideMyServers&&!this.graphOnline&&!this.myServersLoading&&!this.stateData.error&&this.myServersError&&(this.myServersError.includes("unraid-api is stopped")||this.myServersError.includes("Disconnected from Unraid API"))},forumSupportLink(){return this.plgInstallFailed?"https://forums.unraid.net/topic/112073-my-servers-releases/#comment-1154449":this.myServersError&&this.myServersError.includes("OK")||this.myServersError&&this.myServersError.includes("SERVER_OVERLOAD")||this.cloud&&this.cloud.error&&(this.cloud.error.includes("OK")||this.cloud.error.includes("SERVER_OVERLOAD"))?"https://forums.unraid.net/topic/112073-my-servers-releases/#comment-1121459":"https://forums.unraid.net/forum/94-my-servers-plugin-support/"}},methods:{...Object(b.b)(["executeUnraidApi","fetchServers","openPopUp","stopGraphqlClient"]),serversPlz(){return We.debug("[serversPlz]",{apikey:this.apikey,noRemoteApikeyRegisteredWithPlg:this.noRemoteApikeyRegisteredWithPlg,validApiKeyLength:this.validApiKeyLength,myServersOutOfDate:this.myServersOutOfDate}),this.plgInstallFailed?We.error("[MyServers] plugin failed to install correctly"):this.myServersOutOfDate&&this.myServersOutOfDate.enabled&&(this.myServersOutOfDate.error||We.warn(this.myServersOutOfDate.message),this.myServersOutOfDate.error)?We.error(this.myServersOutOfDate.message):this.noRemoteApikeyRegisteredWithPlg?We.error("[MyServers] remote apikey does not exist"):this.validApiKeyLength?(this.fetchServers(),this.timer("serversPlz()")):We.error("[MyServers] invalid apikey")},timer(e=""){We.debug("[timer] %s",e),setTimeout(()=>{!this.graphOnline&&this.registered&&(this.offlineTimer=!0,sessionStorage.setItem("offlineTimer",Date.now()))},3e4)},triggerRestart(){this.executeUnraidApi({command:"start"}),this.offlineTimer=!1,this.restartTriggered=!0,sessionStorage.removeItem("offlineTimer")}},created(){!this.hideMyServers&&this.registered&&this.serversPlz()}},(function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("div",{staticClass:"relative"},[r("ul",{staticClass:"relative"},[e.filteredServers.length&&e.myServersError&&!e.stateData.error?r("li",{staticClass:"text-red text-12px font-semibold px-16px pb-4px"},[r("em",[e._v(e._s(e.$t("upc.myServers.displayingLastKnown")))])]):e._e(),e.computedError?r("li",{key:"current-server-error",staticClass:"w-full"},[r("button",{staticClass:"btn-error group py-8px px-16px flex flex-col",attrs:{title:e.errorToggleTitle},on:{click:function(t){return e.$emit("toggle-error")}}},[r("div",{staticClass:"w-full flex flex-row justify-between items-center"},[r("span",{staticClass:"inline-flex flex-row items-center"},[e.myServersOutOfDate&&e.myServersOutOfDate.enabled&&!e.myServersOutOfDate.error?r("UnraidSvgUtilInfo",{staticClass:"fill-current w-12px h-12px"}):r("UnraidSvgUiWarningFill",{staticClass:"fill-current w-12px h-12px"}),r("span",{staticClass:"font-semibold mx-8px"},[e._v(" "+e._s(e.servername)+" ")])],1),e.computedError&&e.errorStateMessageVisible?r("UnraidSvgUtilDelete",{staticClass:"text-current opacity-100 group-hover:opacity-100 transition-opacity duration-200 ease-in-out fill-current w-12px h-12px ml-8px"}):r("UnraidSvgUtilInfo",{staticClass:"text-current opacity-100 group-hover:opacity-100 transition-opacity duration-200 ease-in-out fill-current w-12px h-12px ml-8px"})],1),r("transition",{attrs:{name:"fade",mode:"out-in"}},[e.computedError&&e.errorStateMessageVisible?r("div",{staticClass:"UnraidUPC-serverError"},[r("div",{staticClass:"text-14px font-semibold pt-4px"},[r("h3",{staticClass:"text-16px mb-4px"},[e._v(e._s(e.errorToggleText))]),r("p",{domProps:{innerHTML:e._s(e.computedError)}})])]):e._e()])],1)]):e._e(),r("transition",{attrs:{name:"fade",mode:"out-in"}},[e.pirateKey&&e.errorStateMessageVisible?r("li",[r("a",{staticClass:"link-error group flex flex-row items-center justify-between",attrs:{href:"zh_CN"===e.locale?"https://unraid.net/zh/%E8%B4%AD%E4%B9%B0-%E6%AD%A3%E7%89%88-unraid-%E8%AE%B8%E5%8F%AF%E8%AF%81":"https://unraid.net/buy-genuine-license",title:e.$t("upc.opensNewHttpsWindow.base",[e.$t("learnMore")]),target:"_blank"}},[r("span",{staticClass:"inline-flex flex-row items-center"},[r("UnraidSvgUtilHelp",{staticClass:"fill-current w-12px h-12px mr-8px"}),e._v(" "+e._s(e.$t("learnMore"))+" ")],1),r("UnraidSvgUtilNewWindow",{staticClass:"opacity-0 group-hover:opacity-100 transition-opacity duration-200 ease-in-out fill-current w-12px h-12px ml-8px"})],1)]):e._e()]),r("transition",{attrs:{name:"fade",mode:"out-in"}},[e.computedError&&!e.stateData.error&&e.errorStateMessageVisible&&e.myServersOutOfDate&&e.myServersOutOfDate.enabled&&e.myServersOutOfDate.link?r("li",[r("a",{staticClass:"link-error group flex flex-row items-center justify-between",attrs:{href:e.myServersOutOfDate.link,title:e.myServersOutOfDate.linkSameTab?"":e.$t("upc.opensNewHttpsWindow.base",[this.myServersOutOfDate.heading]),target:e.myServersOutOfDate.linkSameTab?"":"_blank",rel:"noopener"}},[r("span",{staticClass:"inline-flex flex-row items-center"},[r("UnraidSvgUtilEdit",{staticClass:"fill-current w-12px h-12px mr-8px"}),e._v(" "+e._s(e.myServersOutOfDate.linkText)+" ")],1),e.myServersOutOfDate.linkSameTab?e._e():r("UnraidSvgUtilNewWindow",{staticClass:"opacity-0 group-hover:opacity-100 transition-opacity duration-200 ease-in-out fill-current w-12px h-12px ml-8px"})],1)]):e._e()]),r("transition",{attrs:{name:"fade",mode:"out-in"}},[(e.plgInstallFailed||e.myServersError||e.cloud&&e.cloud.error)&&!e.stateData.error&&e.errorStateMessageVisible?r("li",[r("a",{staticClass:"link-error group flex flex-row items-center justify-between",attrs:{href:e.forumSupportLink,title:e.$t("upc.opensNewHttpsWindow.base",["My Servers Support"]),target:"_blank",rel:"noopener"}},[r("span",{staticClass:"inline-flex flex-row items-center"},[r("UnraidSvgUtilHelp",{staticClass:"fill-current w-12px h-12px mr-8px"}),e._v(" "+e._s(e.plgInstallFailed?e.$t("learnMore"):"My Servers Support")+" ")],1),r("UnraidSvgUtilNewWindow",{staticClass:"opacity-0 group-hover:opacity-100 transition-opacity duration-200 ease-in-out fill-current w-12px h-12px ml-8px"})],1)]):e._e()]),r("transition",{attrs:{name:"fade",mode:"out-in"}},[("EEXPIRED"!==e.state&&e.stateData.error||e.pirateKey)&&e.errorStateMessageVisible?r("li",[r("a",{staticClass:"link-error group flex flex-row items-center justify-between",attrs:{title:e.$t("upc.opensNewHttpsWindow.base",[e.$t("contactSupport")])},on:{click:function(t){return e.$emit("contact-support")}}},[r("span",{staticClass:"inline-flex flex-row items-center"},[r("UnraidSvgUtilHelp",{staticClass:"fill-current w-12px h-12px mr-8px"}),e._v(" "+e._s(e.$t("contactSupport"))+" ")],1),r("UnraidSvgUtilNewWindow",{staticClass:"opacity-0 group-hover:opacity-100 transition-opacity duration-200 ease-in-out fill-current w-12px h-12px ml-8px"})],1)]):e._e()]),r("transition",{attrs:{name:"fade",mode:"out-in"}},[e.noRemoteApikeyRegisteredWithPlg&&e.errorStateMessageVisible?r("li",[r("a",{staticClass:"link-error group flex flex-row items-center justify-between",attrs:{title:e.$t("upc.opensNewHttpsWindow.base",[e.$t("signIn")])},on:{click:function(t){return e.openPopUp(e.signInPayload)}}},[r("span",{staticClass:"inline-flex flex-row items-center"},[r("UnraidSvgUiWarningFill",{staticClass:"fill-current w-12px h-12px mr-8px"}),e._v(" "+e._s(e.$t("upc.signInActions.resolve"))+" ")],1),r("UnraidSvgUtilNewWindow",{staticClass:"opacity-0 group-hover:opacity-100 transition-opacity duration-200 ease-in-out fill-current w-12px h-12px ml-8px"})],1)]):e._e()]),r("transition",{attrs:{name:"fade",mode:"out-in"}},[e.apiEnableRestartButton?r("li",[r("button",{staticClass:"group flex flex-row items-center justify-between",attrs:{title:e.$t("upc.myServers.api.startTitle")},on:{click:function(t){return e.triggerRestart()}}},[r("span",{staticClass:"inline-flex flex-row items-center"},[r("UnraidSvgUtilTerminal",{staticClass:"fill-current w-12px h-12px mr-8px"}),e._v(" "+e._s(e.$t("upc.myServers.api.start"))+" ")],1)])]):e._e()]),e.registered?r("div",{staticClass:"relative z-0",class:{"custom-scrollbar":e.myServersOverflow}},[r("div",{class:{"overflow-y-scroll max-h-310px":e.myServersOverflow}},[r("transition-group",{attrs:{name:"fade",mode:"out-in"}},[e.myServersLoading?r("UnraidLoading",{key:"gql-loading",staticClass:"w-36px my-8px mx-auto",attrs:{height:21,title:e.$t("upc.myServers.loading")}}):e._e(),e.filteredServers?r("div",{key:"filteredServers"},[r("transition",{attrs:{name:"fade",mode:"out-in"}},[e.computedError?e._e():r("li",{key:"current-server",staticClass:"w-full py-8px px-16px flex flex-row items-center",class:{"text-beta":"online"===e.currentServerStatus,"text-orange cursor-not-allowed":"online"!==e.currentServerStatus},attrs:{title:e.$t("upc.myServers.accessLabels.current")+" • "+("online"!==e.currentServerStatus?e.$t("upc.myServers.mothership.notConnected"):e.$t("upc.myServers.mothership.connected"))}},["online"!==e.currentServerStatus?r("UnraidSvgUiWarningFill",{staticClass:"fill-current w-12px h-12px"}):r("UnraidSvgUtilCheck",{staticClass:"fill-current w-12px h-12px"}),r("span",{staticClass:"ml-8px select-all"},[e._v(e._s(e.currentServer?e.currentServer.name:e.servername))])],1)]),e._l(e.filteredServers,(function(t,n){return r("li",{key:"filteredServer_"+n},["online"===t.status&&e.wanip!==t.wanip&&t.remoteurl?r("a",{staticClass:"w-full flex flex-row items-center",attrs:{href:t.remoteurl,tabindex:"0",title:e.$t("upc.myServers.accessLabels.remote")}},[r("span",{staticClass:"block w-12px h-12px mr-8px bg-green rounded-full"}),r("span",{staticClass:"select-all"},[e._v(e._s(t.name))])]):"online"===t.status&&t.localurl?r("a",{staticClass:"w-full flex flex-row items-center",attrs:{href:t.localurl,tabindex:"0",title:e.$t("upc.myServers.accessLabels.local")}},[r("span",{staticClass:"block w-12px h-12px mr-8px bg-green rounded-full"}),r("span",{staticClass:"select-all"},[e._v(e._s(t.name))])]):"never_connected"!==t.status?r("span",{staticClass:"w-full flex flex-row items-center px-16px py-8px opacity-50 cursor-not-allowed",attrs:{title:"online"===t.status?e.$t("upc.myServers.accessLabels.unavailable"):e.$t("upc.myServers.accessLabels.offline")}},[r("span",{staticClass:"text-red text-14px w-12px mr-8px"},[e._v("×")]),r("span",{staticClass:"select-all"},[e._v(e._s(t.name))])]):e._e()])}))],2):e._e()],1)],1)]):e._e()],1)])}),[],!1,(function(e){var t=r("dce8");t.__inject__&&t.__inject__(e)}),null,null,!0).exports,Do=v({components:{HelperTimeConvert:Li},computed:{...Object(b.e)(["state"]),...Object(b.c)(["stateData"])}},(function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("div",{staticClass:"text-gamma text-12px text-right font-semibold leading-normal flex flex-row items-baseline justify-end pr-16px pt-4px"},[r("HelperTimeConvert"),r("span",{staticClass:"px-12px"},[e._v("•")]),e.stateData.actions.includes("upgrade")?r("button",{staticClass:"text-12px text-gamma hover:text-alpha focus:text-alpha font-semibold transition-colors duration-150 ease-in-out border-t-0 border-l-0 border-r-0 border-b-2 border-transparent hover:border-orange-dark focus:border-orange-dark focus:outline-none",attrs:{title:e.$t("upc.opensNewHttpsWindow.upgrade")},on:{click:function(t){return e.$emit("upgrade")}}},[r("h5",[e._v("Unraid OS "),r("em",[r("strong",[e._v(e._s(e.stateData.humanReadable))])])])]):r("h5",[e._v("Unraid OS "),r("em",{class:{"text-red":e.stateData.error||"EEXPIRED"===e.state}},[r("strong",[e._v(e._s(e.stateData.humanReadable))])])]),e.stateData.actions.includes("purchase")?r("button",{staticClass:"text-12px text-orange-dark font-semibold hover:text-alpha focus:text-alpha ml-12px transition-colors duration-150 ease-in-out border-t-0 border-l-0 border-r-0 border-b-2 border-transparent hover:border-orange-dark focus:border-orange-dark focus:outline-none",attrs:{title:e.$t("upc.opensNewHttpsWindow.purchase")},on:{click:function(t){return e.$emit("purchase")}}},[e._v(e._s(e.$t("actions.purchase")))]):e._e()],1)}),[],!1,null,null,null,!0).exports;o.default.use(oo.a);var Uo=v({i18n:he,store:bi,name:"UserProfile",mixins:[no.mixin],components:{UnraidLoading:xi,UnraidLogoMark:Ei,KeyAction:ko,MetaInfo:Do,MyServers:Mo,UnraidSvgUtilLogout:so.a,UnraidSvgUtilNewWindow:lo.a,UnraidSvgUtilSelect:po.a,UnraidSvgUtilEdit:ho.a,UnraidSvgUtilInfo:go.a,UnraidSvgUiWarning:bo.a,UnraidSvgUtilGlobe:wo.a,UnraidSvgUtilDelete:_o.a,UnraidSvgUtilThumbsUp:So.a,UiBeta:Fi},props:{serverstate:String,banner:{type:String,default:""},showBannerGradient:{type:String,default:"yes"},bgcolor:[String,Number],displaydesc:{type:String,default:""},locale:String,localeMessages:String,metacolor:String,textcolor:String,theme:{type:String,default:"black"},hideotherservers:{type:String,default:""},apikey:String,apiVersion:String,csrf:String,expiretime:[Number,String],hideMyServers:{type:String,default:null},plgPath:String,regWizTime:String,sendCrashInfo:String,serverdesc:String,servermodel:String,serverupdate:Boolean,uptime:[Number,String]},data:()=>({NODE_ENV:me,avatarFail:!1,copyingIp:!1,copyingIpFailed:!1,dropdownTimeout:"",dropdownVisible:!1,errorStateMessageVisible:!0,showRemoveBtns:!1,removingPlg:!1,hoverImage:!1}),computed:{...Object(b.e)(["avatar","isLaunchpadOpen","isPromoOpen","isPopUpOpen","guid","guidRegistered","popUpWindow","regAtOpen","purchaseWindow","redeemWindow","registered","servername","internalip","state","username","darkTheme","lightTheme","extendTrialPayload","recoverKeyPayload","replaceKeyPayload","signInPayload","signUpPayload","signOutPayload","troubleshootPayload","wizardWindow","messages","myServersEnv","triggerUPC","graphOnline","myServersError","cloud","plgInstalled","signOutTriggered","pirateKey"]),...Object(b.c)(["errorTooManyDisks","noRemoteApikeyRegisteredWithPlg","signedOutWithKey","stateData","myServersOutOfDate","allowedOrigins","server","plgInstallFailed"]),darkMode(){return"black"===this.theme||"azure"===this.theme},usernameButtonText(){return this.stateData.error&&!this.stateData.error.signInToFix&&"EEXPIRED"===!this.state?this.$t("fixError"):this.registered?this.username:""},usernameButtonTitle(){return"ENOKEYFILE"===this.state?this.$t("getStarted"):"EEXPIRED"===this.state?this.$t("upc.trialHasExpiredSeeOptions"):this.stateData.error?this.$t("learnMore"):this.isPopUpOpen&&this.isLaunchpadOpen?this.$t("upc.confirmClosure"):this.cloud&&this.cloud.error?`${this.$t("upc.myServers.errors.unraidApi.heading")}: ${this.cloud.error}`:this.myServersError&&this.registered?`${this.$t("upc.myServers.errors.unraidApi.heading")}: ${this.myServersError}`:this.errorTooManyDisks?this.$t("upc.errorTooManyDisks.heading"):this.isLaunchpadOpen?this.$t("closeLaunchpad"):this.dropdownVisible?this.$t("upc.closeDropdown"):this.$t("upc.openDropdown")},displayKeylineBelowActions(){return!!(this.stateData.actions.includes("startTrial")||this.stateData.actions.includes("purchase")||this.stateData.actions.includes("upgrade")||this.stateData.actions.includes("recover")||this.stateData.actions.includes("replace")||this.stateData.actions.includes("extend"))},extraLinks(){return[...!this.hideMyServers&&this.registered||this.stateData.error.message||this.errorTooManyDisks?[{url:"",text:"",external:!1}]:[],...this.hideMyServers||!this.registered||this.plgInstallFailed?[]:[{url:this.myServersEnv?"https://forums.unraid.net/my-servers-staging/":"https://forums.unraid.net/my-servers/",text:this.$t("upc.extraLinks.myServers"),external:!0,title:this.$t("upc.extraLinks.newTab",[this.$t("upc.extraLinks.myServers")])},{url:"/Settings/ManagementAccess#"+(this.plgPath?"MyServersSettings":"UnraidNetSettings"),text:this.$t("upc.extraLinks.settings.text"),settings:!0,title:this.$t("upc.extraLinks.settings.title")}]]},devEnv(){let e=me;const t="UPC_ENV=",r=document.cookie.split(";");for(let n=0;n{this.showRemoveBtns&&(this.showRemoveBtns=!1)},300),this.dropdownVisible)},...Object(b.b)(["closePopUp","openPopUp","receivePostMessage","setStateFromWebComponentProp","startTrial","stopGraphqlClient","togglePromo","updateServerState","validateGuid"]),...Object(b.d)(["SET_IS_LAUNCHPAD_OPEN","SET_IS_PROMO_OPEN","SET_LOCALE","SET_API_KEY","SET_CSRF","SET_DARK_MODE","SET_EXPIRE_TIME","SET_HIDE_MY_SERVERS","SET_MY_SERVERS_API_VERSION","SET_PLG_PATH","SET_REGWIZ_TIME","SET_SERVERDESC","SET_UPTIME","SET_DEV_MODE","SET_MY_SERVERS_ERROR","SET_MY_SERVERS_ERROR_SHOW_SUPPORT_BTN"]),closeDropdown(){setTimeout(()=>{this.showRemoveBtns&&(this.showRemoveBtns=!1)},300),this.dropdownVisible=!1},dropdownMouseEnter(){return"ENOKEYFILE"!==this.state&&!this.isLaunchpadOpen&&(clearTimeout(this.dropdownTimeout),!0)},dropdownMouseLeave(){return this.dropdownTimeout=setTimeout(()=>"ENOKEYFILE"!==this.state&&(this.dropdownVisible=!1,setTimeout(()=>{this.showRemoveBtns&&(this.showRemoveBtns=!1)},300)),1e3),!0},autoTriggerLaunchpad(){setTimeout(()=>{const e=`${this.servername}_${this.guid?this.guid.slice(-12):"NO_GUID"}`;sessionStorage.getItem(e)||"ENOKEYFILE"!==this.state||(sessionStorage.setItem(e,"またね"),this.isLaunchpadOpen||this.toggleLaunchpad())},100)},toggleLaunchpad(){const e="unraid-launchpad";if(!document.getElementsByTagName(e).length){const t=document.getElementsByTagName("body")[0],r=document.createElement(e);t.appendChild(r)}const t=()=>{this.dropdownVisible&&(this.dropdownVisible=!1),this.isPopUpOpen&&this.closePopUp(),this.SET_IS_LAUNCHPAD_OPEN(!this.isLaunchpadOpen)};this.isPopUpOpen&&this.isLaunchpadOpen?window.confirm(this.$t("upc.pleaseConfirmClosureYouHaveOpenPopUp"))&&t():t()},onAvatarError(){We.error("Avatar failed to load %s",this.avatar),this.avatarFail=!0},async initUserProfile(){if(We.debug("[initUserProfile]"),this.setStateFromWebComponentProp(this.serverstate),this.apikey&&this.SET_API_KEY(this.apikey),this.apiVersion&&this.SET_MY_SERVERS_API_VERSION(this.apiVersion),this.csrf&&this.SET_CSRF(this.csrf),this.expiretime&&this.SET_EXPIRE_TIME(this.expiretime),this.hideMyServers&&this.SET_HIDE_MY_SERVERS(this.hideMyServers),this.plgPath&&this.SET_PLG_PATH(this.plgPath),this.regWizTime&&this.SET_REGWIZ_TIME(this.regWizTime),this.serverdesc&&this.SET_SERVERDESC(this.serverdesc),this.uptime&&this.SET_UPTIME(this.uptime),this.devEnv&&this.SET_DEV_MODE(this.devEnv),this.hideMyServers){const e=["color: white","background: linear-gradient(to right, #E22828 0%, #FF8C2F 100%)","font-size: 10px","padding: 4px"].join(";");We.log(`%c${this.$t("upc.enhanceYourExperienceWithMyServers")} • https://wiki.unraid.net/My_Servers`,e)}if(this.localeMessages){We.debug("[this.locale] %o",this.locale);const[e,t]=Ne(decodeURIComponent(this.localeMessages));e&&We.error("[initUserProfile.localeMessages] %s","Unable to set locale and locale messages"),this.$i18n.locale=this.locale,this.$i18n.setLocaleMessage(this.locale,t[this.locale]),We.debug(`[initUserProfile.$i18n] ${this.$i18n.locale} locale & messages set %o`,t[this.locale]),this.SET_LOCALE(this.locale)}this.signedOutWithKey&&this.regWizTime?(We.debug("[initUserProfile] %o",{signedOutWithKey:this.signedOutWithKey,regWizTime:this.regWizTime}),await this.validateGuid()):this.autoTriggerLaunchpad(),sessionStorage.getItem("clickedInstallMyServers")&&(We.debug("[initUserProfile] sessionStorage clickedInstallMyServers"),this.toggleLaunchpad()),sessionStorage.getItem("showPromoPostTrialInstall")&&(We.debug("[initUserProfile] sessionStorage showPromoPostTrialInstall"),this.togglePromo()),window.addEventListener("message",e=>{this.receivePostMessage({inject:!1,event:e})},!1)},copyIpSuccess(){We.debug("[copyIpSuccess] %s",this.internalip),this.copyingIp=!this.copyingIp,setTimeout(()=>{this.copyingIp=!this.copyingIp},750)},copyIpError(){return this.copyingIpFailed=!0,clearTimeout(this.copyingFailedTimeout),this.copyingFailedTimeout=setTimeout(()=>{this.copyingIpFailed=!this.copyingIpFailed},2e3),We.error("Unable to copy IP: %s",this.internalip)},hoverCopyFailed(){We.debug("[hoverCopyFailed] %s",this.internalip),clearTimeout(this.copyingFailedTimeout)},leaveCopyFailed(){We.debug("[leaveCopyFailed] %s",this.internalip),clearTimeout(this.copyingFailedTimeout),this.copyingFailedTimeout=setTimeout(()=>{this.copyingIpFailed=!this.copyingIpFailed},1500)},copyFailedClickaway(){We.debug("[copyFailedClickaway] %s",this.internalip),clearTimeout(this.copyingFailedTimeout),this.copyingIpFailed=!1},toggleRemovePlgBtns(){We.debug("[toggleRemovePlgBtns]"),this.showRemoveBtns=!this.showRemoveBtns},removePlugin(){try{if(We.debug("[removePlugin] %s",this.plgInstalled),"function"==typeof openPlugin)We.debug("[removePlugin] using openPlugin %s",this.plgInstalled),openPlugin("plugin remove "+this.plgInstalled.replace("_installFailed",""),this.$t("upc.removeMyServersPlugin"),this.plgInstalled.replace("_installFailed","")+":remove","refresh");else{We.debug("[removePlugin] using openBox %s",this.plgInstalled),openBox("/plugins/dynamix.plugin.manager/scripts/plugin&arg1=remove&arg2="+this.plgInstalled.replace("_installFailed",""),this.$t("upc.removeMyServersPlugin"),600,900,!0,"loadlist",this.plgInstalled.replace("_installFailed","")+":remove"),this.removingPlg=!0,window.addEventListener("beforeunload",this.preventClose);const e=setInterval(()=>"none"!==document.getElementById("sb-container").style.display?We.debug("⏳ still removing My Servers…⏳"):(We.debug("❌ My Servers removed ❌"),window.removeEventListener("beforeunload",this.preventClose),clearInterval(e),window.location.reload()),100)}}catch(e){We.error(e)}},preventClose(e){this.removingPlg&&(e.preventDefault(),e.returnValue="",alert(this.$t("regWizPopUp.closingPopUpMayLeadToErrors")))}},watch:{signedOutWithKey(e,t){We.debug("[signedOutWithKey]",{newVal:e,oldVal:t,regWizTime:this.regWizTime}),e&&!t&&this.regWizTime&&this.validateGuid()},isPopUpOpen(e,t){this.isLaunchpadOpen&&!e&&t&&!this.regAtOpen&&this.registered&&this.SET_IS_LAUNCHPAD_OPEN(!1)},triggerUPC(e){e&&setTimeout(()=>{this.dropdownVisible=!0},150)},graphOnline(e,t){e&&!t&&this.updateServerState()},isPromoOpen(e,t){e&&!t&&(this.dropdownVisible=!1)},signOutTriggered(e,t){e&&this.graphOnline&&(We.debug("[watch.signOutTriggered] disconnect from unraid-api",{newVal:e,oldVal:t,apikey:this.apikey}),this.stopGraphqlClient(this.apikey),this.myServersError&&(this.SET_MY_SERVERS_ERROR(""),this.SET_MY_SERVERS_ERROR_SHOW_SUPPORT_BTN(!1)))}},created(){this.initUserProfile()},beforeMount(){const e=document.getElementsByTagName("body")[0],t={darkTheme:{alpha:"#1c1b1b",beta:"#f2f2f2",gamma:"#999999"},lightTheme:{alpha:"#f2f2f2",beta:"#1c1b1b",gamma:"#999999"}};let{alpha:r,beta:n,gamma:i}=this.darkMode?t.darkTheme:t.lightTheme;this.textcolor&&(r=this.textcolor),this.bgcolor&&(n=this.bgcolor,e.style.setProperty("--color-customgradient-start",ro()(n,0)),e.style.setProperty("--color-customgradient-end",ro()(n,.9))),this.metacolor&&(i=this.metacolor),e.style.setProperty("--color-alpha",r),e.style.setProperty("--color-beta",n),e.style.setProperty("--color-gamma",i),e.style.setProperty("--shadow-beta","0 25px 50px -12px "+ro()(n,.15)),e.style.setProperty("--ring-offset-shadow","0 0 "+n),e.style.setProperty("--ring-shadow","0 0 "+n)}},(function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("div",{staticClass:"UnraidUPC",class:{"--hasBanner-default":e.banner&&"no"!==e.showBannerGradient&&!e.bgcolor,"--hasBanner-custom":e.banner&&"no"!==e.showBannerGradient&&e.bgcolor},attrs:{id:"UnraidUPC"}},[e.isPopUpOpen&&!e.isLaunchpadOpen?r("div",{staticClass:"absolute z-10 inset-0 flex flex-col items-end justify-center pr-6"},[r("div",{staticClass:"text-center inline-flex flex-col items-center justify-center"},[r("button",{staticClass:"text-14px button button-alt",on:{click:function(t){return e.openPopUp()}}},[e._v(e._s(e.$t("backToPopUp")))]),r("button",{staticClass:"hover:underline text-12px mt-4px",on:{click:function(t){return e.closePopUp()}}},[e._v(e._s(e.$t("closePopUp")))])])]):e._e(),r("MetaInfo",{class:{"blur opacity-30 pointer-events-none transition-all duration-150 ease-in-out":e.isPopUpOpen&&!e.isLaunchpadOpen},on:{purchase:function(t){return e.openPopUp(e.purchaseWindow)},upgrade:function(t){return e.openPopUp(e.purchaseWindow)},signin:function(t){return e.openPopUp(e.signInPayload)}}}),r("div",{staticClass:"relative z-0 flex flex-row items-center justify-end h-full",class:{"blur opacity-30 pointer-events-none transition-all duration-150 ease-in-out":e.isPopUpOpen&&!e.isLaunchpadOpen}},[r("h1",{staticClass:"relative text-18px border-t-0 border-r-0 border-l-0 border-b-2 border-transparent"},[e.displaydesc?[r("span",{attrs:{title:e.servermodel}},[e._v(e._s(e.serverdesc))]),r("span",{staticClass:"text-grey-mid px-8px"},[e._v("•")])]:e._e(),r("span",{directives:[{name:"clipboard",rawName:"v-clipboard:copy",value:e.internalip,expression:"internalip",arg:"copy"},{name:"clipboard",rawName:"v-clipboard:success",value:e.copyIpSuccess,expression:"copyIpSuccess",arg:"success"},{name:"clipboard",rawName:"v-clipboard:error",value:e.copyIpError,expression:"copyIpError",arg:"error"}],staticClass:"cursor-pointer",attrs:{title:e.$t("lanIp",[e.internalip])}},[e._v(e._s(e.servername))]),r("transition",{attrs:{name:"fade",mode:"out-in"}},[e.copyingIp?r("span",{staticClass:"text-12px absolute right-0 bg-gradient-to-r from-red to-orange text-center block w-100px rounded"},[e._v(e._s(e.$t("upc.lanIpCopied")))]):e._e(),e.copyingIpFailed?r("span",{directives:[{name:"on-clickaway",rawName:"v-on-clickaway",value:e.copyFailedClickaway,expression:"copyFailedClickaway"}],staticClass:"text-12px font-semibold px-4px absolute right-0 bg-gradient-to-r from-red to-orange text-center block rounded",on:{mouseenter:e.hoverCopyFailed,mouseleave:e.leaveCopyFailed}},[e._v("LAN IP: "),r("span",{staticClass:"select-all"},[e._v(e._s(e.internalip))])]):e._e()])],2),r("div",{staticClass:"block w-2px h-24px ml-16px bg-grey-mid"}),r("div",{directives:[{name:"on-clickaway",rawName:"v-on-clickaway",value:e.closeDropdown,expression:"closeDropdown"}],staticClass:"relative flex items-center justify-end h-full",on:{mouseenter:function(t){return e.dropdownMouseEnter()},mouseleave:function(t){return e.dropdownMouseLeave()}}},[r("button",{staticClass:"UnraidUPC-username group text-18px hover:text-alpha focus:text-alpha border border-transparent flex flex-row justify-end items-center h-full px-16px outline-none focus:outline-none",class:{"text-orange-dark":e.isLaunchpadOpen||!e.username&&!e.stateData.error,"text-alpha":e.username&&!e.isLaunchpadOpen,"text-red":e.stateData.error},attrs:{title:e.usernameButtonTitle},on:{click:function(t){return e.usernameAvatarButton()}}},[e.myServersOutOfDate&&e.myServersOutOfDate.enabled&&!e.myServersOutOfDate.error?r("UnraidSvgUtilInfo",{staticClass:"text-red fill-current relative w-14px h-14px mr-8px"}):e.showWarningIcon?r("UnraidSvgUiWarning",{staticClass:"text-red fill-current relative w-24px h-24px mr-8px"}):e._e(),e.usernameButtonText?r("span",{staticClass:"inline-flex items-center bg-transparent border-t-0 border-l-0 border-r-0 border-b-2 border-transparent group-hover:border-orange-dark group-focus:border-orange-dark transition-colors duration-150 ease-in-out"},[e._v(" "+e._s(e.usernameButtonText)+" "),e.registered&&!e.isLaunchpadOpen?r("UnraidSvgUtilSelect",{staticClass:"fill-current w-8px h-8px ml-8px"}):e._e()],1):e._e(),r("span",{staticClass:"relative z-0 flex items-center justify-center w-36px h-36px rounded-full",class:{"ml-8px":e.usernameButtonText,"bg-transparent":e.registered&&!e.avatarFail,"bg-gradient-to-r from-red to-orange":!e.registered||e.avatarFail},on:{mouseenter:function(t){e.hoverImage=!0},mouseleave:function(t){e.hoverImage=!1}}},[e.registered&&!e.avatarFail?r("img",{staticClass:"absolute z-10 inset-0 w-36px h-36px rounded-full overflow-hidden",attrs:{src:e.avatar,alt:""+e.$t("upc.avatarAlt",[e.username])},on:{error:e.onAvatarError}}):[e.hoverImage?r("UnraidLoading",{staticClass:"relative z-0 w-28px",attrs:{title:e.usernameButtonTitle,"gradient-start":"#fff","gradient-stop":"#fff",height:28}}):r("UnraidLogoMark",{staticClass:"relative z-0 w-28px",attrs:{title:e.usernameButtonTitle,"gradient-start":"#fff","gradient-stop":"#fff"}})]],2),e.usernameButtonText?e._e():r("UnraidSvgUtilSelect",{staticClass:"fill-current w-8px h-8px ml-8px"})],1),r("transition",{attrs:{name:"slideVerticalFade",mode:"out-in"}},[r("div",{directives:[{name:"show",rawName:"v-show",value:e.dropdownVisible,expression:"dropdownVisible"}],staticClass:"UnraidUPC-dropdown",class:{"border-grey-darkest":e.darkMode,"border-grey-light":!e.darkMode}},[e.hideMyServers?e._e():r("header",{staticClass:"text-14px pt-16px px-16px rounded-t"},[r("h5",{staticClass:"text-18px leading-none inline-flex flex-row items-center"},[r("span",{staticClass:"font-semibold"},[e._v(e._s(e.$t("upc.myServers.heading")))]),r("ui-beta",{staticClass:"ml-8px"}),e.myServersEnv?r("span",{staticClass:"ml-8px",attrs:{title:"API • "+e.myServersEnv}},[e._v("⚙️")]):e._e(),e.devEnv?r("span",{staticClass:"ml-8px",attrs:{title:e.devEnv}},[e._v("⚠️")]):e._e()],1)]),r("ul",{staticClass:"list-reset my-8px p-0"},["development"===e.NODE_ENV?[r("li",[r("KeyAction",{attrs:{text:"[DEV] Launchpad",external:!1},on:{click:function(t){return e.toggleLaunchpad()}}})],1),r("li",[r("KeyAction",{attrs:{text:"[DEV] Pop-up"},on:{click:function(t){return e.openPopUp(e.wizardWindow)}}})],1),r("li",{staticClass:"my-8px mx-12px"},[r("hr",{staticClass:"w-full h-2px bg-gradient-to-r from-red to-orange shadow-none border-none rounded-none"})])]:e._e(),e.hideMyServers||e.registered?e._e():[r("li",[r("button",{staticClass:"group flex flex-row items-center justify-between",attrs:{title:e.$t("upc.opensNewHttpsWindow.base",[e.$t("signInUp")])},on:{click:function(t){return e.openPopUp(e.wizardWindow)}}},[r("span",{staticClass:"inline-flex flex-row items-center"},[r("UnraidSvgUtilGlobe",{staticClass:"fill-current w-12px h-12px mr-8px"}),e._v(" "+e._s(e.$t("signInUp"))+" ")],1),r("UnraidSvgUtilNewWindow",{staticClass:"text-white opacity-0 group-hover:opacity-100 transition-opacity duration-200 ease-in-out fill-current w-12px h-12px ml-8px"})],1)]),r("li",{staticClass:"my-8px mx-12px"},[r("hr",{staticClass:"w-full h-2px bg-gradient-to-r from-red to-orange shadow-none border-none rounded-none"})])],e.displayKeylineBelowActions?[e.stateData.actions.includes("startTrial")?r("KeyAction",{attrs:{text:e.$t("actions.startTrial")},on:{click:function(t){return e.startTrial()}}}):e._e(),e.stateData.actions.includes("purchase")?[r("KeyAction",{attrs:{text:e.$t("actions.purchase")},on:{click:function(t){return e.openPopUp(e.purchaseWindow)}}}),r("KeyAction",{attrs:{text:e.$t("actions.redeemActivationCode")},on:{click:function(t){return e.openPopUp(e.redeemWindow)}}})]:e._e(),e.stateData.actions.includes("upgrade")?r("KeyAction",{attrs:{text:e.$t("actions.upgrade")},on:{click:function(t){return e.openPopUp(e.purchaseWindow)}}}):e._e(),e.stateData.actions.includes("recover")?r("KeyAction",{attrs:{text:e.$t("actions.recover")},on:{click:function(t){return e.openPopUp(e.recoverKeyPayload)}}}):e._e(),e.stateData.actions.includes("replace")?r("KeyAction",{attrs:{text:e.$t("actions.replace")},on:{click:function(t){return e.openPopUp(e.replaceKeyPayload)}}}):e._e(),e.stateData.actions.includes("extend")?r("KeyAction",{attrs:{text:e.$t("actions.extend")},on:{click:function(t){return e.openPopUp(e.extendTrialPayload)}}}):e._e(),r("li",{staticClass:"my-8px mx-12px"},[r("hr",{staticClass:"w-full h-2px bg-gradient-to-r from-red to-orange shadow-none border-none rounded-none"})])]:e._e(),!e.hideMyServers&&e.registered||e.pirateKey||e.stateData.error.message||e.errorTooManyDisks||e.myServersOutOfDate.enabled||e.plgInstallFailed?r("MyServers",{attrs:{hideMyServers:e.hideMyServers,errorStateMessageVisible:e.errorStateMessageVisible,hideotherservers:e.hideotherservers},on:{"contact-support":function(t){return e.openPopUp(e.troubleshootPayload)},"toggle-error":function(t){e.errorStateMessageVisible=!e.errorStateMessageVisible}}}):e._e(),e._l(e.extraLinks,(function(t,n){return[t.url?r("li",{key:n},[r("a",{staticClass:"flex flex-row items-center",attrs:{href:t.url,target:t.external?"_blank":"",rel:t.external?"noopener noreferrer":"",title:t.title}},[t.external?r("UnraidSvgUtilNewWindow",{staticClass:"flex-shrink-0 fill-current w-12px h-12px mr-8px"}):e._e(),t.settings?r("UnraidSvgUtilEdit",{staticClass:"flex-shrink-0 fill-current w-12px h-12px mr-8px"}):e._e(),t.info?r("UnraidSvgUtilInfo",{staticClass:"flex-shrink-0 fill-current w-12px h-12px mr-8px"}):e._e(),e._v(" "+e._s(t.text)+" ")],1)]):r("div",{key:n+"_else",staticClass:"mx-12px"},[r("hr",{staticClass:"w-full h-2px my-8px bg-gradient-to-r from-red to-orange shadow-none border-none rounded-none"})])]})),e.hideMyServers?r("li",[r("button",{staticClass:"group flex flex-row items-center justify-between",attrs:{title:e.$t("upc.enhanceYourExperienceWithMyServers")},on:{click:function(t){return e.togglePromo()}}},[r("span",{staticClass:"inline-flex flex-row items-center"},[r("UnraidSvgUtilInfo",{staticClass:"flex-shrink-0 fill-current w-12px h-12px mr-8px"}),r("span",[e._v(" "+e._s(e.$t("upc.enhanceYourExperienceWithMyServers"))+" "),r("ui-beta",{staticClass:"inline-block transform scale-90 opacity-70",attrs:{colorClasses:"text-beta border-beta group-hover:text-white group-focus:text-white group-hover:border-white group-focus:border-white"}})],1)],1)])]):[e.registered&&!e.plgInstallFailed?r("li",[r("button",{staticClass:"group flex flex-row items-center justify-between",attrs:{title:e.$t("upc.opensNewHttpsWindow.base",[e.$t("actions.signOutUnraidNet")])},on:{click:function(t){return e.openPopUp(e.signOutPayload)}}},[r("span",{staticClass:"inline-flex flex-row items-center"},[r("UnraidSvgUtilLogout",{staticClass:"fill-current w-12px h-12px mr-8px"}),e._v(" "+e._s(e.$t("actions.signOutUnraidNet"))+" ")],1),r("UnraidSvgUtilNewWindow",{staticClass:"text-white opacity-0 group-hover:opacity-100 transition-opacity duration-200 ease-in-out fill-current w-12px h-12px ml-8px"})],1)]):r("li",{staticClass:"relative"},[e.showRemoveBtns?e.showRemoveBtns&&!e.removingPlg?r("div",{staticClass:"flex flex-col bg-alpha"},[r("p",{staticClass:"text-12px text-center font-semibold px-16px pb-8px"},[r("em",[e._v(e._s(e.$t("upc.confirmMyServersPluginRemoval")))])]),r("div",{staticClass:"flex flex-row"},[r("button",{staticClass:"group relative bg-transparent flex flex-row justify-between items-center",attrs:{title:e.$t("upc.continueUsingMyServers")},on:{click:function(t){return e.toggleRemovePlgBtns()}}},[e._v(" "+e._s(e.$t("regWizPopUp.forms.cancel"))+" "),r("UnraidSvgUtilThumbsUp",{staticClass:"text-white opacity-0 group-hover:opacity-100 group-focus:opacity-100 transition-opacity duration-200 ease-in-out fill-current w-12px h-12px"})],1),r("button",{staticClass:"btn-remove group relative flex flex-row justify-between items-center",attrs:{title:e.$t("upc.confirmMyServersPluginRemoval")},on:{click:function(t){return e.removePlugin()}}},[e._v(" "+e._s(e.$t("regWizPopUp.forms.confirm"))+" "),r("UnraidSvgUtilDelete",{staticClass:"text-white opacity-0 group-hover:opacity-100 group-focus:opacity-100 transition-opacity duration-200 ease-in-out fill-current w-12px h-12px"})],1)])]):r("button",{attrs:{disabled:""}},[e._v(" "+e._s(e.$t("upc.removingMyServersPlugin"))+" ")]):r("button",{staticClass:"text-black flex flex-row items-center justify-between",attrs:{title:e.$t("upc.removeMyServersPlugin")},on:{click:function(t){return e.toggleRemovePlgBtns()}}},[r("span",{staticClass:"inline-flex flex-row items-center"},[r("UnraidSvgUtilDelete",{staticClass:"fill-current w-12px h-12px mr-8px"}),e._v(" "+e._s(e.$t("upc.removeMyServersPlugin"))+" ")],1)])])]],2)])])],1)])],1)}),[],!1,(function(e){var t=r("e519");t.__inject__&&t.__inject__(e)}),null,null,!0).exports;var Lo=v({i18n:he,store:bi,name:"WanIpCheck",props:{phpWanIp:{type:String,default:""}},computed:{...Object(b.e)(["wanip","site"]),...Object(b.c)(["isRemoteAccess"]),loading(){return!this.wanip}},methods:{...Object(b.b)(["getWanIp"])},created(){We.debug("[🍣 WanIpCheck 🍣]"),this.wanip||this.getWanIp()}},(function(){var e=this,t=e.$createElement,r=e._self._c||t;return r("transition",{attrs:{appear:"",name:"fade",mode:"out-in"}},[e.loading?r("span",{domProps:{innerHTML:e._s(e.$t("wanIpCheck.checking")+"…")}}):[e.phpWanIp?[e.isRemoteAccess?r("span",{domProps:{innerHTML:e._s(e.$t("wanIpCheck.match",[e.phpWanIp]))}}):e.phpWanIp!==e.wanip||e.isRemoteAccess?r("span",{staticClass:"mismatch",domProps:{innerHTML:e._s(e.$t("wanIpCheck.mismatch",[e.phpWanIp,e.wanip]))}}):r("span",{domProps:{innerHTML:e._s(e.$t("wanIpCheck.match",[e.wanip]))}})]:r("span",{staticClass:"error",domProps:{innerHTML:e._s(e.$t("wanIpCheck.resolveError"))}})]],2)}),[],!1,(function(e){var t=r("6e03");t.__inject__&&t.__inject__(e)}),"4ca8352c",null,!0).exports;window.customElements.define("unraid-authed",g(o.default,yi)),window.customElements.define("unraid-launchpad",g(o.default,Vi)),window.customElements.define("unraid-promo",g(o.default,Zi)),window.customElements.define("unraid-upc-trigger",g(o.default,eo)),window.customElements.define("unraid-user-profile",g(o.default,Uo)),window.customElements.define("unraid-wan-ip-check",g(o.default,Lo))},"5b71":function(e,t,r){"use strict";r.r(t);var n=r("c725");for(var i in n)["default"].indexOf(i)<0&&function(e){r.d(t,e,(function(){return n[e]}))}(i)},"5d74":function(e,t,r){e.exports={options:{},ssr:function(e,t){var r=e.data,n=r.attrs,i=n.symbol,o=n.size,a=this.getAttributes(o);a&&(r.attrs=Object.assign({},r.attrs,a)),o&&delete r.attrs.size,i&&delete r.attrs.symbol;var s=r.class,c=r.staticClass||"";c+=s?Object.keys(s).join(" "):"",this.hasClass(c)||(r.staticClass=r.staticClass?r.staticClass+" "+this.options.class:this.options.class);var l=e.context.$createElement("use",{attrs:{href:this.getHref(i)}});Array.isArray(e.children)?e.children.push(l):e.children=[l]},install:function(e,t){void 0===t&&(t={}),this.options.class=t.class||"icon",this.options.url=void 0===t.url?"/assets/svg/sprite.svg":t.url;var r=this;e.directive("svg",{bind:function(e,t,n){var i=t.value||n.data.attrs.symbol,o=n.data.attrs&&n.data.attrs.size,a=r.getAttributes(o);a&&(e.setAttribute("viewBox",a.viewBox),e.setAttribute("width",a.width),e.setAttribute("height",a.height)),i&&e.removeAttribute("symbol"),o&&e.removeAttribute("size");var s=e.getAttribute("class");if(r.hasClass(s)||e.setAttribute("class",s?s+" "+r.options.class:r.options.class),!e||null===e.querySelector("use")){var c=document.createElementNS("http://www.w3.org/2000/svg","use"),l=r.getHref(i);c.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",l),c.setAttribute("href",l),e.appendChild(c)}},update:function(e,t,n){var i=r.getHref(t.value||n.data.attrs.symbol),o=e&&e.querySelector("use");if(o){if(o.getAttribute("href")===i)return!1;var a=document.createElementNS("http://www.w3.org/2000/svg","use");a.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",i),a.setAttribute("href",i),e.replaceChild(a,o)}}})},getAttributes:function(e){if(!e)return null;var t=e.toString().replace(/( |, |,)/g," ").split(" "),r=t.length;if(3===r||r>4)return console.warn('[vue-svg-sprite] size: "'+e+'" is not valid'),null;var n=[];n[0]=r<4?0:t[0],n[1]=r<4?0:t[1];var i=n[2]=r<4?t[0]:t[2];return{height:n[3]=t[r-1],viewBox:n.join(" "),width:i}},hasClass:function(e){var t=this.options.class;return!!e&&e.split(" ").some((function(e){var r=e.split(/(-|_)/)[0];return-1!==r.indexOf(t)&&r.length===t.length}))},getHref:function(e){return""===this.options.url?"#"+e:this.options.url+"#"+e}}},"607e":function(e,t){e.exports={functional:!0,render(e,t){const{_c:r,_v:n,data:i,children:o=[]}=t,{class:a,staticClass:s,style:c,staticStyle:l,attrs:u={},...p}=i;return r("svg",{class:[a,s],style:[c,l],attrs:Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 16 16"},u),...p},o.concat([r("path",{attrs:{"fill-rule":"evenodd",d:"M0 7h2v8l-2 1V7zm3.5 7V7C5 6.7 6.365 4.915 7.595 1.646A1.767 1.767 0 019.25.5c.69 0 1.25.56 1.25 1.25V6h3.09a2 2 0 011.966 2.369l-.75 4A2 2 0 0112.84 14H3.5z"}})]))}}},"61bb":function(e,t,r){const{MAX_LENGTH:n}=r("fe45"),{re:i,t:o}=r("22c0"),a=r("df02"),s=r("e12f");e.exports=(e,t)=>{if(t=s(t),e instanceof a)return e;if("string"!=typeof e)return null;if(e.length>n)return null;if(!(t.loose?i[o.LOOSE]:i[o.FULL]).test(e))return null;try{return new a(e,t)}catch(e){return null}}},6210:function(e,t,r){e.exports=function(e){"use strict";var t=function(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}(e),r={s:"ein paar Sekunden",m:["eine Minute","einer Minute"],mm:"%d Minuten",h:["eine Stunde","einer Stunde"],hh:"%d Stunden",d:["ein Tag","einem Tag"],dd:["%d Tage","%d Tagen"],M:["ein Monat","einem Monat"],MM:["%d Monate","%d Monaten"],y:["ein Jahr","einem Jahr"],yy:["%d Jahre","%d Jahren"]};function n(e,t,n){var i=r[n];return Array.isArray(i)&&(i=i[t?0:1]),i.replace("%d",e)}var i={name:"de",weekdays:"Sonntag_Montag_Dienstag_Mittwoch_Donnerstag_Freitag_Samstag".split("_"),weekdaysShort:"So._Mo._Di._Mi._Do._Fr._Sa.".split("_"),weekdaysMin:"So_Mo_Di_Mi_Do_Fr_Sa".split("_"),months:"Januar_Februar_März_April_Mai_Juni_Juli_August_September_Oktober_November_Dezember".split("_"),monthsShort:"Jan_Feb_März_Apr_Mai_Juni_Juli_Aug_Sept_Okt_Nov_Dez".split("_"),ordinal:function(e){return e+"."},weekStart:1,yearStart:4,formats:{LTS:"HH:mm:ss",LT:"HH:mm",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY HH:mm",LLLL:"dddd, D. MMMM YYYY HH:mm"},relativeTime:{future:"in %s",past:"vor %s",s:n,m:n,mm:n,h:n,hh:n,d:n,dd:n,M:n,MM:n,y:n,yy:n}};return t.default.locale(i,null,!0),i}(r("5a0c"))},"626e":function(e,t,r){"use strict";var n=[/passw(or)?d/i,/^pw$/,/^pass$/i,/secret/i,/token/i,/api[-._]?key/i,/session[-._]?id/i,/^connect\.sid$/],i=[/^\d{4}[- ]?\d{4}[- ]?\d{4}[- ]?\d{4}$/];t.key=function(e){return n.some((function(t){return t.test(e)}))},t.value=function(e){return i.some((function(t){return t.test(e)}))}},"633a":function(e,t,r){"use strict";(function(e){var n=this&&this.__assign||function(){return(n=Object.assign||function(e){for(var t,r=1,n=arguments.length;r0&&i[i.length-1])&&(6===o[0]||2===o[0])){a=0;continue}if(3===o[0]&&(!i||o[1]>i[0]&&o[1]0){var s=t.shift();s&&s.applyMiddleware.apply(i,[e,o])}else r(e)};o()}(a(t.middlewares),t)}))},e.prototype.use=function(e){var t=this;return e.map((function(e){if("function"!=typeof e.applyMiddleware)throw new Error("Middleware must implement the applyMiddleware function.");t.middlewares.push(e)})),this},e.prototype.getConnectionParams=function(e){return function(){return new Promise((function(t,r){if("function"==typeof e)try{return t(e.call(null))}catch(e){return r(e)}t(e)}))}},e.prototype.executeOperation=function(e,t){var r=this;null===this.client&&this.connect();var n=this.generateOperationId();return this.operations[n]={options:e,handler:t},this.applyMiddlewares(e).then((function(e){r.checkOperationOptions(e,t),r.operations[n]&&(r.operations[n]={options:e,handler:t},r.sendMessage(n,b.default.GQL_START,e))})).catch((function(e){r.unsubscribe(n),t(r.formatErrors(e))})),n},e.prototype.getObserver=function(e,t,r){return"function"==typeof e?{next:function(t){return e(t)},error:function(e){return t&&t(e)},complete:function(){return r&&r()}}:e},e.prototype.createMaxConnectTimeGenerator=function(){var e=this.minWsTimeout,t=this.wsTimeout;return new l({min:e,max:t,factor:1.2})},e.prototype.clearCheckConnectionInterval=function(){this.checkConnectionIntervalId&&(clearInterval(this.checkConnectionIntervalId),this.checkConnectionIntervalId=null)},e.prototype.clearMaxConnectTimeout=function(){this.maxConnectTimeoutId&&(clearTimeout(this.maxConnectTimeoutId),this.maxConnectTimeoutId=null)},e.prototype.clearTryReconnectTimeout=function(){this.tryReconnectTimeoutId&&(clearTimeout(this.tryReconnectTimeoutId),this.tryReconnectTimeoutId=null)},e.prototype.clearInactivityTimeout=function(){this.inactivityTimeoutId&&(clearTimeout(this.inactivityTimeoutId),this.inactivityTimeoutId=null)},e.prototype.setInactivityTimeout=function(){var e=this;this.inactivityTimeout>0&&0===Object.keys(this.operations).length&&(this.inactivityTimeoutId=setTimeout((function(){0===Object.keys(e.operations).length&&e.close()}),this.inactivityTimeout))},e.prototype.checkOperationOptions=function(e,t){var r=e.query,n=e.variables,i=e.operationName;if(!r)throw new Error("Must provide a query.");if(!t)throw new Error("Must provide an handler.");if(!p.default(r)&&!h.getOperationAST(r,i)||i&&!p.default(i)||n&&!d.default(n))throw new Error("Incorrect option types. query must be a string or a document,`operationName` must be a string, and `variables` must be an object.")},e.prototype.buildMessage=function(e,t,r){return{id:e,type:t,payload:r&&r.query?n(n({},r),{query:"string"==typeof r.query?r.query:f.print(r.query)}):r}},e.prototype.formatErrors=function(e){return Array.isArray(e)?e:e&&e.errors?this.formatErrors(e.errors):e&&e.message?[e]:[{name:"FormatedError",message:"Unknown error",originalError:e}]},e.prototype.sendMessage=function(e,t,r){this.sendMessageRaw(this.buildMessage(e,t,r))},e.prototype.sendMessageRaw=function(e){switch(this.status){case this.wsImpl.OPEN:var t=JSON.stringify(e);try{JSON.parse(t)}catch(t){this.eventEmitter.emit("error",new Error("Message must be JSON-serializable. Got: "+e))}this.client.send(t);break;case this.wsImpl.CONNECTING:this.unsentMessagesQueue.push(e);break;default:this.reconnecting||this.eventEmitter.emit("error",new Error("A message was not sent because socket is not connected, is closing or is already closed. Message was: "+JSON.stringify(e)))}},e.prototype.generateOperationId=function(){return String(++this.nextOperationId)},e.prototype.tryReconnect=function(){var e=this;if(this.reconnect&&!(this.backoff.attempts>=this.reconnectionAttempts)){this.reconnecting||(Object.keys(this.operations).forEach((function(t){e.unsentMessagesQueue.push(e.buildMessage(t,b.default.GQL_START,e.operations[t].options))})),this.reconnecting=!0),this.clearTryReconnectTimeout();var t=this.backoff.duration();this.tryReconnectTimeoutId=setTimeout((function(){e.connect()}),t)}},e.prototype.flushUnsentMessagesQueue=function(){var e=this;this.unsentMessagesQueue.forEach((function(t){e.sendMessageRaw(t)})),this.unsentMessagesQueue=[]},e.prototype.checkConnection=function(){this.wasKeepAliveReceived?this.wasKeepAliveReceived=!1:this.reconnecting||this.close(!1,!0)},e.prototype.checkMaxConnectTimeout=function(){var e=this;this.clearMaxConnectTimeout(),this.maxConnectTimeoutId=setTimeout((function(){e.status!==e.wsImpl.OPEN&&(e.reconnecting=!0,e.close(!1,!0))}),this.maxConnectTimeGenerator.duration())},e.prototype.connect=function(){var e,t=this;this.client=new((e=this.wsImpl).bind.apply(e,a([void 0,this.url,this.wsProtocols],this.wsOptionArguments))),this.checkMaxConnectTimeout(),this.client.onopen=function(){return i(t,void 0,void 0,(function(){var e,t;return o(this,(function(r){switch(r.label){case 0:if(this.status!==this.wsImpl.OPEN)return[3,4];this.clearMaxConnectTimeout(),this.closedByUser=!1,this.eventEmitter.emit(this.reconnecting?"reconnecting":"connecting"),r.label=1;case 1:return r.trys.push([1,3,,4]),[4,this.connectionParams()];case 2:return e=r.sent(),this.sendMessage(void 0,b.default.GQL_CONNECTION_INIT,e),this.flushUnsentMessagesQueue(),[3,4];case 3:return t=r.sent(),this.sendMessage(void 0,b.default.GQL_CONNECTION_ERROR,t),this.flushUnsentMessagesQueue(),[3,4];case 4:return[2]}}))}))},this.client.onclose=function(){t.closedByUser||t.close(!1,!1)},this.client.onerror=function(e){t.eventEmitter.emit("error",e)},this.client.onmessage=function(e){var r=e.data;t.processReceivedData(r)}},e.prototype.processReceivedData=function(e){var t,r;try{r=(t=JSON.parse(e)).id}catch(t){throw new Error("Message must be JSON-parseable. Got: "+e)}if(-1===[b.default.GQL_DATA,b.default.GQL_COMPLETE,b.default.GQL_ERROR].indexOf(t.type)||this.operations[r])switch(t.type){case b.default.GQL_CONNECTION_ERROR:this.connectionCallback&&this.connectionCallback(t.payload);break;case b.default.GQL_CONNECTION_ACK:this.eventEmitter.emit(this.reconnecting?"reconnected":"connected",t.payload),this.reconnecting=!1,this.backoff.reset(),this.maxConnectTimeGenerator.reset(),this.connectionCallback&&this.connectionCallback();break;case b.default.GQL_COMPLETE:var i=this.operations[r].handler;delete this.operations[r],i.call(this,null,null);break;case b.default.GQL_ERROR:this.operations[r].handler(this.formatErrors(t.payload),null),delete this.operations[r];break;case b.default.GQL_DATA:var o=t.payload.errors?n(n({},t.payload),{errors:this.formatErrors(t.payload.errors)}):t.payload;this.operations[r].handler(null,o);break;case b.default.GQL_CONNECTION_KEEP_ALIVE:var a=void 0===this.wasKeepAliveReceived;this.wasKeepAliveReceived=!0,a&&this.checkConnection(),this.checkConnectionIntervalId&&(clearInterval(this.checkConnectionIntervalId),this.checkConnection()),this.checkConnectionIntervalId=setInterval(this.checkConnection.bind(this),this.wsTimeout);break;default:throw new Error("Invalid message type!")}else this.unsubscribe(r)},e.prototype.unsubscribe=function(e){this.operations[e]&&(delete this.operations[e],this.setInactivityTimeout(),this.sendMessage(e,b.default.GQL_STOP,void 0))},e}();t.SubscriptionClient=y}).call(this,r("c8ba"))},6788:function(e,t){e.exports={functional:!0,render(e,t){const{_c:r,_v:n,data:i,children:o=[]}=t,{class:a,staticClass:s,style:c,staticStyle:l,attrs:u={},...p}=i;return r("svg",{class:[a,s],style:[c,l],attrs:Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 16 16"},u),...p},o.concat([r("path",{attrs:{"fill-rule":"evenodd",d:"M0 6l5.584-.5L8 0l2.5 5.5L16 6l-4 4 1 6-5-3.5L3 16l1-6z"}})]))}}},6981:function(e,t,r){ /*! * clipboard.js v2.0.8 * https://clipboardjs.com/