@touchtech/web-auth 2.0.5 → 3.0.0-alpha.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1,15 +1,21 @@
|
|
|
1
1
|
import React from "react";
|
|
2
|
-
declare type
|
|
3
|
-
children: React.ReactNode;
|
|
2
|
+
export declare type TenantAuthorization = {
|
|
4
3
|
tenantId: string;
|
|
5
4
|
privilege: string;
|
|
5
|
+
};
|
|
6
|
+
export declare type ModeAuthorization = {
|
|
7
|
+
mode: string;
|
|
8
|
+
};
|
|
9
|
+
export declare type Authorization = TenantAuthorization | ModeAuthorization;
|
|
10
|
+
declare type Props = {
|
|
11
|
+
children: React.ReactNode;
|
|
12
|
+
authorization: Authorization;
|
|
6
13
|
unauthorizedUrl: string;
|
|
7
14
|
};
|
|
8
15
|
declare type ProviderValue = {
|
|
9
|
-
|
|
10
|
-
privilege: string;
|
|
16
|
+
authorization: Authorization;
|
|
11
17
|
unauthorizedUrl: string;
|
|
12
18
|
};
|
|
13
19
|
export declare const ProtectedContentContext: React.Context<ProviderValue>;
|
|
14
|
-
export declare const ProtectedContentProvider: ({ children,
|
|
20
|
+
export declare const ProtectedContentProvider: ({ children, authorization, unauthorizedUrl, }: Props) => JSX.Element;
|
|
15
21
|
export {};
|
package/dist/index.js
CHANGED
|
@@ -1,2 +1 @@
|
|
|
1
|
-
/*! For license information please see index.js.LICENSE.txt */
|
|
2
|
-
(()=>{var e={438:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AuthorizationRequest=void 0;var n=r(537),o=r(96),i=function(){function e(t,r,o){void 0===r&&(r=new n.DefaultCrypto),void 0===o&&(o=!0),this.crypto=r,this.usePkce=o,this.clientId=t.client_id,this.redirectUri=t.redirect_uri,this.scope=t.scope,this.responseType=t.response_type||e.RESPONSE_TYPE_CODE,this.state=t.state||function(e){return e.generateRandom(10)}(r),this.extras=t.extras,this.internal=t.internal}return e.prototype.setupCodeVerifier=function(){var e=this;if(this.usePkce){var t=this.crypto.generateRandom(128);return this.crypto.deriveChallenge(t).catch((function(e){o.log("Unable to generate PKCE challenge. Not using PKCE",e)})).then((function(r){r&&(e.internal=e.internal||{},e.internal.code_verifier=t,e.extras=e.extras||{},e.extras.code_challenge=r,e.extras.code_challenge_method="S256")}))}return Promise.resolve()},e.prototype.toJson=function(){var e=this;return this.setupCodeVerifier().then((function(){return{response_type:e.responseType,client_id:e.clientId,redirect_uri:e.redirectUri,scope:e.scope,state:e.state,extras:e.extras,internal:e.internal}}))},e.RESPONSE_TYPE_TOKEN="token",e.RESPONSE_TYPE_CODE="code",e}();t.AuthorizationRequest=i},960:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AuthorizationRequestHandler=t.BUILT_IN_PARAMETERS=t.AuthorizationNotifier=void 0;var n=r(96),o=function(){function e(){this.listener=null}return e.prototype.setAuthorizationListener=function(e){this.listener=e},e.prototype.onAuthorizationComplete=function(e,t,r){this.listener&&this.listener(e,t,r)},e}();t.AuthorizationNotifier=o,t.BUILT_IN_PARAMETERS=["redirect_uri","client_id","response_type","state","scope"];var i=function(){function e(e,t){this.utils=e,this.crypto=t,this.notifier=null}return e.prototype.buildRequestUrl=function(e,r){var n={redirect_uri:r.redirectUri,client_id:r.clientId,response_type:r.responseType,state:r.state,scope:r.scope};if(r.extras)for(var o in r.extras)r.extras.hasOwnProperty(o)&&t.BUILT_IN_PARAMETERS.indexOf(o)<0&&(n[o]=r.extras[o]);var i=this.utils.stringify(n);return e.authorizationEndpoint+"?"+i},e.prototype.completeAuthorizationRequestIfPossible=function(){var e=this;return n.log("Checking to see if there is an authorization response to be delivered."),this.notifier||n.log("Notifier is not present on AuthorizationRequest handler.\n No delivery of result will be possible"),this.completeAuthorizationRequest().then((function(t){t||n.log("No result is available yet."),t&&e.notifier&&e.notifier.onAuthorizationComplete(t.request,t.response,t.error)}))},e.prototype.setAuthorizationNotifier=function(e){return this.notifier=e,this},e}();t.AuthorizationRequestHandler=i},208:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AuthorizationError=t.AuthorizationResponse=void 0;var r=function(){function e(e){this.code=e.code,this.state=e.state}return e.prototype.toJson=function(){return{code:this.code,state:this.state}},e}();t.AuthorizationResponse=r;var n=function(){function e(e){this.error=e.error,this.errorDescription=e.error_description,this.errorUri=e.error_uri,this.state=e.state}return e.prototype.toJson=function(){return{error:this.error,error_description:this.errorDescription,error_uri:this.errorUri,state:this.state}},e}();t.AuthorizationError=n},373:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AuthorizationServiceConfiguration=void 0;var n=r(157),o=function(){function e(e){this.authorizationEndpoint=e.authorization_endpoint,this.tokenEndpoint=e.token_endpoint,this.revocationEndpoint=e.revocation_endpoint,this.userInfoEndpoint=e.userinfo_endpoint,this.endSessionEndpoint=e.end_session_endpoint}return e.prototype.toJson=function(){return{authorization_endpoint:this.authorizationEndpoint,token_endpoint:this.tokenEndpoint,revocation_endpoint:this.revocationEndpoint,end_session_endpoint:this.endSessionEndpoint,userinfo_endpoint:this.userInfoEndpoint}},e.fetchFromIssuer=function(t,r){var o=t+"/.well-known/openid-configuration";return(r||new n.JQueryRequestor).xhr({url:o,dataType:"json",method:"GET"}).then((function(t){return new e(t)}))},e}();t.AuthorizationServiceConfiguration=o},537:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.DefaultCrypto=t.textEncodeLite=t.urlSafe=t.bufferToString=void 0;var n=r(742),o=r(3),i="undefined"!=typeof window&&!!window.crypto,a=i&&!!window.crypto.subtle,u="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";function s(e){for(var t=[],r=0;r<e.byteLength;r+=1){var n=e[r]%u.length;t.push(u[n])}return t.join("")}function l(e){return n.fromByteArray(new Uint8Array(e)).replace(/\+/g,"-").replace(/\//g,"_").replace(/=/g,"")}function c(e){for(var t=new ArrayBuffer(e.length),r=new Uint8Array(t),n=0;n<e.length;n++)r[n]=e.charCodeAt(n);return r}t.bufferToString=s,t.urlSafe=l,t.textEncodeLite=c;var f=function(){function e(){}return e.prototype.generateRandom=function(e){var t=new Uint8Array(e);if(i)window.crypto.getRandomValues(t);else for(var r=0;r<e;r+=1)t[r]=Math.random()*u.length|0;return s(t)},e.prototype.deriveChallenge=function(e){return e.length<43||e.length>128?Promise.reject(new o.AppAuthError("Invalid code length.")):a?new Promise((function(t,r){crypto.subtle.digest("SHA-256",c(e)).then((function(e){return t(l(new Uint8Array(e)))}),(function(e){return r(e)}))})):Promise.reject(new o.AppAuthError("window.crypto.subtle is unavailable."))},e}();t.DefaultCrypto=f},3:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AppAuthError=void 0;t.AppAuthError=function(e,t){this.message=e,this.extras=t}},577:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.IS_PROFILE=t.IS_LOG=void 0,t.IS_LOG=!0,t.IS_PROFILE=!1},865:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r),Object.defineProperty(e,n,{enumerable:!0,get:function(){return t[r]}})}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),o=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),o(r(438),t),o(r(960),t),o(r(208),t),o(r(373),t),o(r(537),t),o(r(3),t),o(r(577),t),o(r(96),t),o(r(629),t),o(r(417),t),o(r(33),t),o(r(480),t),o(r(892),t),o(r(551),t),o(r(298),t),o(r(53),t),o(r(157),t)},96:function(e,t,r){"use strict";var n=this&&this.__spreadArray||function(e,t){for(var r=0,n=t.length,o=e.length;r<n;r++,o++)e[o]=t[r];return e};Object.defineProperty(t,"__esModule",{value:!0}),t.profile=t.log=void 0;var o=r(577);function i(e){for(var t=[],r=1;r<arguments.length;r++)t[r-1]=arguments[r];if(o.IS_LOG){var i=t?t.length:0;i>0?console.log.apply(console,n([e],t)):console.log(e)}}t.log=i;var a="undefined"!=typeof window&&!!window.performance&&!!console.profile;t.profile=function(e,t,r){return o.IS_PROFILE?function(e,t,r){var o=r.value,u=o.name;return u||(u="anonymous function"),r.value=a?function(e){console.profile(u);var t=window.performance.now(),r=o.call.apply(o,n([this||window],e)),i=window.performance.now()-t;return console.log(u+" took "+i+" ms"),console.profileEnd(),r}:function(e){i("Profile start "+u);var t=Date.now(),r=o.call.apply(o,n([this||window],e)),a=Date.now()-t;return i("Profile end "+u+" took "+a+" ms."),r},r}(0,0,r):r}},629:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.BasicQueryStringUtils=void 0;var r=function(){function e(){}return e.prototype.parse=function(e,t){return t?this.parseQueryString(e.hash):this.parseQueryString(e.search)},e.prototype.parseQueryString=function(e){for(var t={},r=(e=e.trim().replace(/^(\?|#|&)/,"")).split("&"),n=0;n<r.length;n+=1){var o=r[n].split("=");if(o.length>=2){var i=decodeURIComponent(o.shift()),a=o.length>0?o.join("="):null;a&&(t[i]=decodeURIComponent(a))}}return t},e.prototype.stringify=function(e){var t=[];for(var r in e)e.hasOwnProperty(r)&&e[r]&&t.push(encodeURIComponent(r)+"="+encodeURIComponent(e[r]));return t.join("&")},e}();t.BasicQueryStringUtils=r},417:function(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])},n(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0}),t.RedirectRequestHandler=void 0;var i=r(438),a=r(960),u=r(208),s=r(537),l=r(96),c=r(629),f=r(480),d=function(e){return e+"_appauth_authorization_request"},p=function(e){return e+"_appauth_authorization_service_configuration"},h="appauth_current_authorization_request",y=function(e){function t(t,r,n,o){void 0===t&&(t=new f.LocalStorageBackend),void 0===r&&(r=new c.BasicQueryStringUtils),void 0===n&&(n=window.location),void 0===o&&(o=new s.DefaultCrypto);var i=e.call(this,r,o)||this;return i.storageBackend=t,i.locationLike=n,i}return o(t,e),t.prototype.performAuthorizationRequest=function(e,t){var r=this,n=this.crypto.generateRandom(10);Promise.all([this.storageBackend.setItem(h,n),t.toJson().then((function(e){return r.storageBackend.setItem(d(n),JSON.stringify(e))})),this.storageBackend.setItem(p(n),JSON.stringify(e.toJson()))]).then((function(){var n=r.buildRequestUrl(e,t);l.log("Making a request to ",t,n),r.locationLike.assign(n)}))},t.prototype.completeAuthorizationRequest=function(){var e=this;return this.storageBackend.getItem(h).then((function(t){return t?e.storageBackend.getItem(d(t)).then((function(e){return JSON.parse(e)})).then((function(e){return new i.AuthorizationRequest(e)})).then((function(r){var n=""+e.locationLike.origin+e.locationLike.pathname,o=e.utils.parse(e.locationLike,!0),i=o.state,a=o.code,s=o.error;l.log("Potential authorization request ",n,o,i,a,s);var c=i===r.state,f=null,y=null;if(c){if(s){var v=o.error_uri,g=o.error_description;y=new u.AuthorizationError({error:s,error_description:g,error_uri:v,state:i})}else f=new u.AuthorizationResponse({code:a,state:i});return Promise.all([e.storageBackend.removeItem(h),e.storageBackend.removeItem(d(t)),e.storageBackend.removeItem(p(t))]).then((function(){return l.log("Delivering authorization response"),{request:r,response:f,error:y}}))}return l.log("Mismatched request (state and request_uri) dont match."),Promise.resolve(null)})):null}))},t}(a.AuthorizationRequestHandler);t.RedirectRequestHandler=y},33:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.RevokeTokenRequest=void 0;var r=function(){function e(e){this.token=e.token,this.tokenTypeHint=e.token_type_hint,this.clientId=e.client_id,this.clientSecret=e.client_secret}return e.prototype.toJson=function(){var e={token:this.token};return this.tokenTypeHint&&(e.token_type_hint=this.tokenTypeHint),this.clientId&&(e.client_id=this.clientId),this.clientSecret&&(e.client_secret=this.clientSecret),e},e.prototype.toStringMap=function(){return this.toJson()},e}();t.RevokeTokenRequest=r},480:function(e,t){"use strict";var r,n=this&&this.__extends||(r=function(e,t){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])},r(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0}),t.LocalStorageBackend=t.StorageBackend=void 0;var o=function(){};t.StorageBackend=o;var i=function(e){function t(t){var r=e.call(this)||this;return r.storage=t||window.localStorage,r}return n(t,e),t.prototype.getItem=function(e){var t=this;return new Promise((function(r,n){r(t.storage.getItem(e)||null)}))},t.prototype.removeItem=function(e){var t=this;return new Promise((function(r,n){t.storage.removeItem(e),r()}))},t.prototype.clear=function(){var e=this;return new Promise((function(t,r){e.storage.clear(),t()}))},t.prototype.setItem=function(e,t){var r=this;return new Promise((function(n,o){r.storage.setItem(e,t),n()}))},t}(o);t.LocalStorageBackend=i},892:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TokenRequest=t.GRANT_TYPE_REFRESH_TOKEN=t.GRANT_TYPE_AUTHORIZATION_CODE=void 0,t.GRANT_TYPE_AUTHORIZATION_CODE="authorization_code",t.GRANT_TYPE_REFRESH_TOKEN="refresh_token";var r=function(){function e(e){this.clientId=e.client_id,this.redirectUri=e.redirect_uri,this.grantType=e.grant_type,this.code=e.code,this.refreshToken=e.refresh_token,this.extras=e.extras}return e.prototype.toJson=function(){return{grant_type:this.grantType,code:this.code,refresh_token:this.refreshToken,redirect_uri:this.redirectUri,client_id:this.clientId,extras:this.extras}},e.prototype.toStringMap=function(){var e={grant_type:this.grantType,client_id:this.clientId,redirect_uri:this.redirectUri};if(this.code&&(e.code=this.code),this.refreshToken&&(e.refresh_token=this.refreshToken),this.extras)for(var t in this.extras)this.extras.hasOwnProperty(t)&&!e.hasOwnProperty(t)&&(e[t]=this.extras[t]);return e},e}();t.TokenRequest=r},551:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.BaseTokenRequestHandler=void 0;var n=r(3),o=r(629),i=r(298),a=r(157),u=function(){function e(e,t){void 0===e&&(e=new a.JQueryRequestor),void 0===t&&(t=new o.BasicQueryStringUtils),this.requestor=e,this.utils=t}return e.prototype.isTokenResponse=function(e){return void 0===e.error},e.prototype.performRevokeTokenRequest=function(e,t){return this.requestor.xhr({url:e.revocationEndpoint,method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded"},data:this.utils.stringify(t.toStringMap())}).then((function(e){return!0}))},e.prototype.performTokenRequest=function(e,t){var r=this;return this.requestor.xhr({url:e.tokenEndpoint,method:"POST",dataType:"json",headers:{"Content-Type":"application/x-www-form-urlencoded"},data:this.utils.stringify(t.toStringMap())}).then((function(e){return r.isTokenResponse(e)?new i.TokenResponse(e):Promise.reject(new n.AppAuthError(e.error,new i.TokenError(e)))}))},e}();t.BaseTokenRequestHandler=u},298:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TokenError=t.TokenResponse=t.nowInSeconds=void 0,t.nowInSeconds=function(){return Math.round((new Date).getTime()/1e3)};var r=function(){function e(e){this.accessToken=e.access_token,this.tokenType=e.token_type||"bearer",e.expires_in&&(this.expiresIn=parseInt(e.expires_in,10)),this.refreshToken=e.refresh_token,this.scope=e.scope,this.idToken=e.id_token,this.issuedAt=e.issued_at||t.nowInSeconds()}return e.prototype.toJson=function(){var e;return{access_token:this.accessToken,id_token:this.idToken,refresh_token:this.refreshToken,scope:this.scope,token_type:this.tokenType,issued_at:this.issuedAt,expires_in:null===(e=this.expiresIn)||void 0===e?void 0:e.toString()}},e.prototype.isValid=function(e){return void 0===e&&(e=-600),!this.expiresIn||t.nowInSeconds()<this.issuedAt+this.expiresIn+e},e}();t.TokenResponse=r;var n=function(){function e(e){this.error=e.error,this.errorDescription=e.error_description,this.errorUri=e.error_uri}return e.prototype.toJson=function(){return{error:this.error,error_description:this.errorDescription,error_uri:this.errorUri}},e}();t.TokenError=n},53:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0})},157:function(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])},n(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0}),t.TestRequestor=t.FetchRequestor=t.JQueryRequestor=t.Requestor=void 0;var i=r(3),a=function(){};t.Requestor=a;var u=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return o(t,e),t.prototype.xhr=function(e){var t=$.ajax(e);return new Promise((function(e,r){t.then((function(t,r,n){e(t)}),(function(e,t,n){r(new i.AppAuthError(n))}))}))},t}(a);t.JQueryRequestor=u;var s=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return o(t,e),t.prototype.xhr=function(e){if(!e.url)return Promise.reject(new i.AppAuthError("A URL must be provided."));var t=new URL(e.url),r={};if(r.method=e.method,r.mode="cors",e.data&&(e.method&&"POST"===e.method.toUpperCase()?r.body=e.data:new URLSearchParams(e.data).forEach((function(e,r){t.searchParams.append(r,e)}))),r.headers={},e.headers)for(var n in e.headers)e.headers.hasOwnProperty(n)&&(r.headers[n]=e.headers[n]);var o=e.dataType&&"json"===e.dataType.toLowerCase();return o&&(r.headers.Accept="application/json, text/javascript, */*; q=0.01"),fetch(t.toString(),r).then((function(e){if(e.status>=200&&e.status<300){var t=e.headers.get("content-type");return o||t&&-1!==t.indexOf("application/json")?e.json():e.text()}return Promise.reject(new i.AppAuthError(e.status.toString(),e.statusText))}))},t}(a);t.FetchRequestor=s;var l=function(e){function t(t){var r=e.call(this)||this;return r.promise=t,r}return o(t,e),t.prototype.xhr=function(e){return this.promise},t}(a);t.TestRequestor=l},20:(e,t,r)=>{!function(e,t){for(var r in t)e[r]=t[r]}(t,function(e){var t={};function r(n){if(t[n])return t[n].exports;var o=t[n]={i:n,l:!1,exports:{}};return e[n].call(o.exports,o,o.exports,r),o.l=!0,o.exports}return r.m=e,r.c=t,r.d=function(e,t,n){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(r.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)r.d(n,o,function(t){return e[t]}.bind(null,o));return n},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s=11)}([function(e,t){e.exports=r(136)},function(e,t,r){"use strict";r.r(t),r.d(t,"default",(function(){return o}));var n=Array.isArray;function o(e){var t="";if("string"==typeof e||"number"==typeof e)return e||"";if(n(e))for(var r,i=0;i<e.length;i++)""!==(r=o(e[i]))&&(t+=(t&&" ")+r);else for(var i in e)e.hasOwnProperty(i)&&e[i]&&(t+=(t&&" ")+i);return t}},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.Icon=void 0;var o=r(36);Object.defineProperty(t,"Icon",{enumerable:!0,get:function(){return n(o).default}})},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.Button=void 0;var o=r(12);Object.defineProperty(t,"Button",{enumerable:!0,get:function(){return n(o).default}})},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.Label=void 0;var o=r(21);Object.defineProperty(t,"Label",{enumerable:!0,get:function(){return n(o).default}})},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.ButtonLink=void 0;var o=r(17);Object.defineProperty(t,"ButtonLink",{enumerable:!0,get:function(){return n(o).default}})},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.ColorSwatch=void 0;var o=r(26);Object.defineProperty(t,"ColorSwatch",{enumerable:!0,get:function(){return n(o).default}})},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.Modal=void 0;var o=r(31);Object.defineProperty(t,"Modal",{enumerable:!0,get:function(){return n(o).default}})},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.Clickable=void 0;var o=n(r(0)),i=r(3),a=r(2),u=n(r(38)),s=n(r(39));t.Clickable=function(e){var t=e.display,r=e.isDisabled,n=e.onClick;return o.default.createElement(i.Button,{align:"left",disabled:r,onClick:n,size:"medium",stretchHorizontally:!0},o.default.createElement("div",{className:u.default.container},t,o.default.createElement(a.Icon,{alt:"Dropdown",src:s.default})))}},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.MenuLinkItem=t.MenuItem=t.MenuContainer=t.Menu=void 0;var o=r(40);Object.defineProperty(t,"Menu",{enumerable:!0,get:function(){return n(o).default}});var i=r(42);Object.defineProperty(t,"MenuContainer",{enumerable:!0,get:function(){return n(i).default}});var a=r(44);Object.defineProperty(t,"MenuItem",{enumerable:!0,get:function(){return n(a).default}});var u=r(46);Object.defineProperty(t,"MenuLinkItem",{enumerable:!0,get:function(){return n(u).default}})},function(e,t,r){"use strict";r.r(t),t.default={listViewItem:"VKYoNtWTZui2AO1IlyJMTw=="}},function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var o=Object.getOwnPropertyDescriptor(t,r);o&&!("get"in o?!t.__esModule:o.writable||o.configurable)||(o={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,o)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),o=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),o(r(3),t),o(r(14),t),o(r(5),t),o(r(19),t),o(r(24),t),o(r(6),t),o(r(29),t),o(r(34),t),o(r(48),t),o(r(51),t),o(r(2),t),o(r(54),t),o(r(57),t),o(r(60),t),o(r(4),t),o(r(63),t),o(r(9),t),o(r(7),t),o(r(68),t),o(r(71),t),o(r(74),t),o(r(79),t),o(r(82),t)},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var o=n(r(0)),i=n(r(1)),a=n(r(13));t.default=function(e){var t,r=e.children,n=e.className,u=e.onClick,s=e.onPointerDown,l=e.containerRef,c=e.disabled,f=void 0!==c&&c,d=e.inverted,p=void 0!==d&&d,h=e.rounded,y=void 0!==h&&h,v=e.noShadow,g=void 0!==v&&v,m=e.noPadding,_=void 0!==m&&m,b=e.noBorder,O=void 0!==b&&b,w=e.transparent,S=void 0!==w&&w,P=e.stretchHorizontally,E=void 0!==P&&P,j=e.stretchVertically,k=void 0!==j&&j,A=e.autoFocus,x=void 0!==A&&A,R=e.offsetSides,I=void 0===R?[]:R,C=e.align,M=void 0===C?"center":C,N=e.size,T=void 0===N?"medium":N,L=e.type;return o.default.createElement("button",{ref:l,className:(0,i.default)([a.default.container,a.default[T],a.default[M],(t={},t[a.default.inverted]=p,t[a.default.rounded]=y,t[a.default.noShadow]=g,t[a.default.noPadding]=_,t[a.default.noBorder]=O,t[a.default.transparent]=S,t[a.default.stretchHorizontally]=E,t[a.default.stretchVertically]=k,t[a.default.leftOffset]=y&&I.includes("left"),t[a.default.rightOffset]=y&&I.includes("right"),t),n]),disabled:f,autoFocus:x,type:L,role:"button",onClick:u,onPointerDown:s},"string"!=typeof r&&Array.isArray(r)&&r.length?o.default.createElement("div",{className:a.default.content},r):r)}},function(e,t,r){"use strict";r.r(t),t.default={container:"xynuMu8XZSsonDuksl6AQg==",left:"Pkp0HhNHttoWIb2dwpGntw==",small:"wDOeeJGCZm0k2ZpNzFbeHg==",large:"_5QjBWtl7YXy4em4X3GPbRA==",xlarge:"kN0Lga4fBOgcigDqtODRdg==",inverted:"+5nsTnLlNOX8KFQiUhT1kQ==",rounded:"BjP-JNWJjoBfNMMztnyWOQ==",rightOffset:"lGJwNcol8CAknqxY+8Dfqg==",leftOffset:"EV+g6hUA1qv8LQ9RqgrQRQ==",noShadow:"Z3uPLrryqINfRjZppwU6NQ==",noBorder:"eEghG6GXB9IzyD3jrNZfAA==",transparent:"ss7DhVgF5JGspCASdZUYBg==",stretchHorizontally:"i8QPSr4cHYhJ7Aiue+cx0g==",stretchVertically:"WSximUM9kxYGc5VRc0iZlA==",noPadding:"SgXchjz4dJr+tc8ykLnE1A==",content:"xn8yfjN6mexRXIgyNhmkiw=="}},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.ButtonBadge=void 0;var o=r(15);Object.defineProperty(t,"ButtonBadge",{enumerable:!0,get:function(){return n(o).default}})},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var o=n(r(0)),i=n(r(1)),a=n(r(16));t.default=function(e){var t,r=e.children,n=e.inverted,u=void 0!==n&&n,s=e.className;return o.default.createElement("div",{className:(0,i.default)([a.default.buttonBadge,(t={},t[a.default.inverted]=u,t),s])},r)}},function(e,t,r){"use strict";r.r(t),t.default={buttonBadge:"RSjbRiXFWAfBzcCoaMpXeA==",inverted:"X4o4OKsS1T4miIs0Cq5x-g=="}},function(e,t,r){"use strict";var n=this&&this.__assign||function(){return(n=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var o in t=arguments[r])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)},o=this&&this.__rest||function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]])}return r},i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var a=i(r(0)),u=i(r(1)),s=i(r(18));t.default=function(e){var t,r=e.as,i=e.children,l=e.className,c=e.size,f=e.containerRef,d=e.inverted,p=void 0!==d&&d,h=e.rounded,y=void 0!==h&&h,v=e.transparent,g=void 0!==v&&v,m=e.noShadow,_=void 0!==m&&m,b=e.noPadding,O=void 0!==b&&b,w=e.noBorder,S=void 0!==w&&w,P=e.stretchHorizontally,E=void 0!==P&&P,j=e.stretchVertically,k=void 0!==j&&j,A=e.disabled,x=void 0!==A&&A,R=e.offsetSides,I=void 0===R?[]:R,C=e.align,M=void 0===C?"center":C,N=o(e,["as","children","className","size","containerRef","inverted","rounded","transparent","noShadow","noPadding","noBorder","stretchHorizontally","stretchVertically","disabled","offsetSides","align"]);return void 0===r&&(r="a"),a.default.createElement(r,n({ref:f,"data-testid":"button-link",className:(0,u.default)([s.default.container,s.default[c],s.default[M],(t={},t[s.default.inverted]=p,t[s.default.rounded]=y,t[s.default.noShadow]=_,t[s.default.noPadding]=O,t[s.default.noBorder]=S,t[s.default.disabled]=x,t[s.default.transparent]=g,t[s.default.stretchHorizontally]=E,t[s.default.stretchVertically]=k,t[s.default.leftOffset]=y&&I.includes("left"),t[s.default.rightOffset]=y&&I.includes("right"),t),l])},N),"string"!=typeof i&&Array.isArray(i)&&i.length?a.default.createElement("div",{className:s.default.content},i):i)}},function(e,t,r){"use strict";r.r(t),t.default={container:"ZIr9w--fSivqWVGoSp14tA==",left:"rRyu9AVGwX+-xjTOMTSE1w==",small:"_0DBhGJvcbjEMlSqEofF-rw==",medium:"a6+zcUY6XKy94zAqUYaE6w==",large:"W+v4vFebQkxw1cdiKY-Kvg==",xlarge:"dY91DQRYUaWT4EzOJJ+GBg==",inverted:"yplCpylL4Ides+cOrqSimQ==",rounded:"MREY09+d69vV84hZnJuLYw==",rightOffset:"Hsao7mFW3lYTrNhfWvfxWw==",leftOffset:"MXlL3O8KUYeVAYcSsnNs9w==",noShadow:"Hqz4CqQcO4s0MTawrDr0oA==",transparent:"h1hNwc2UlM0C5F-xdga5dw==",stretchHorizontally:"Tmyq4+uHU+JJeYNdBH8L2Q==",stretchVertically:"JzzGnTt4aM3+9rVlNQWi0A==",noPadding:"UvI8Unjc9X0zN2l5W+tmrQ==",noBorder:"Qp5uBnQgJFoZHgYShzAPcw==",disabled:"ZXljkYpPWjDJLC4BEGMprw==",content:"_0n2MnOfJPm2wxs4M2nbGHA=="}},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.Checkbox=void 0;var o=r(20);Object.defineProperty(t,"Checkbox",{enumerable:!0,get:function(){return n(o).default}})},function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var o=Object.getOwnPropertyDescriptor(t,r);o&&!("get"in o?!t.__esModule:o.writable||o.configurable)||(o={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,o)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),o=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),i=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)"default"!==r&&Object.prototype.hasOwnProperty.call(e,r)&&n(t,e,r);return o(t,e),t},a=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var u=i(r(0)),s=a(r(1)),l=r(4),c=a(r(23));t.default=function(e){var t=e.label,r=e.onChange,n=e.placeholder,o=e.checked,i=e.disabled,a=e.name,f=e.className,d=e.indeterminate,p=e.size,h=void 0===p?"medium":p,y=e.autoFocus,v=void 0!==y&&y,g=(0,u.useCallback)((function(e){return r(e.target.checked)}),[r]);return u.default.createElement(l.Label,{value:t},u.default.createElement("input",{"data-testid":"checkbox",ref:function(e){e&&(e.indeterminate=d)},checked:o,disabled:i,className:(0,s.default)([c.default.checkbox,f,c.default[h]]),onChange:g,placeholder:n,name:a,type:"checkbox",autoFocus:v}))}},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var o=n(r(0)),i=n(r(1)),a=n(r(22));t.default=function(e){var t=e.className,r=e.children,n=e.value,u=e.containerRef;return o.default.createElement("label",{ref:u,className:(0,i.default)([a.default.container,t])},n,r)}},function(e,t,r){"use strict";r.r(t),t.default={container:"bR7PO8yRFtUlN1vsP7ecRQ=="}},function(e,t,r){"use strict";r.r(t),t.default={checkbox:"CBQZ4Pp1clb+5R8IlCO4gQ==",small:"_5jbjut7Ggt7gxenjyf9LbQ==",medium:"iPAOw2ZsNJA0nWDXqWC37g==",large:"LEykXs9mEESdwo6iZoMdUw==",xlarge:"uqpACEJ1obA4bRlaeAT27g=="}},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.ColorPicker=void 0;var o=r(25);Object.defineProperty(t,"ColorPicker",{enumerable:!0,get:function(){return n(o).default}})},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var o=n(r(0)),i=n(r(1)),a=r(6),u=n(r(28));t.default=function(e){var t=e.colors,r=e.containerRef,n=e.onSelect,s=e.selectedColor,l=e.direction,c=void 0===l?"vertical":l,f=e.canToggle,d=void 0!==f&&f;return o.default.createElement("div",{ref:r,className:(0,i.default)([u.default.colorPicker,u.default[c]])},t.map((function(e){return o.default.createElement(a.ColorSwatch,{key:e.key,color:e,isSelected:e.key===(null==s?void 0:s.key),onClick:function(){d&&e.key===(null==s?void 0:s.key)?n(null):n(e)}})})))}},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var o=n(r(0)),i=n(r(1)),a=n(r(27));t.default=function(e){var t,r=e.color,n=e.containerRef,u=e.isSelected,s=void 0!==u&&u,l=e.size,c=void 0===l?"medium":l,f=e.onClick;return o.default.createElement("button",{ref:n,className:(0,i.default)([a.default.colorSwatch,a.default[c],(t={},t[a.default.selected]=s,t)]),"data-testid":"color-swatch",onClick:f,style:{backgroundColor:r.hexCode}},r.label&&o.default.createElement("span",{className:a.default.srOnly},"Select ".concat(r.label," color")))}},function(e,t,r){"use strict";r.r(t),t.default={colorSwatch:"uTf7mYfXeNT7Gn0znnR8DQ==",small:"aAbezjOmw2NyT9RU7PuyOA==",large:"Qc6SCvqbnnhJ3ztgzPZOFA==",xlarge:"_6oBBZDkRkzf7tF4bhyDtAA==",selected:"nicZfgMk+uQFPypJIkQubw==",srOnly:"GHpHEB1QXDyjeR9VnEd1Tg=="}},function(e,t,r){"use strict";r.r(t),t.default={colorPicker:"DKtP55bOfUTB1kDa-iUHqQ==",horizontal:"_34Lj8-b-13C8L09RsMineg==",vertical:"_1yugGQs4Ek0t3T8tgoKxVQ=="}},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.ConfirmationModal=void 0;var o=r(30);Object.defineProperty(t,"ConfirmationModal",{enumerable:!0,get:function(){return n(o).default}})},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var o=n(r(0)),i=n(r(1)),a=r(7),u=n(r(33));function s(e){var t,r=e.children,n=e.containerRef,s=e.header,l=e.isOpen,c=e.buttonsLeft,f=void 0===c?[]:c,d=e.buttonsRight,p=void 0===d?[]:d,h=e.onClose,y=void 0===h?function(){}:h,v=e.noPadding,g=void 0!==v&&v,m=e.noOverlay,_=void 0!==m&&m,b=e.noShadow,O=void 0!==b&&b,w=e.baseZIndex,S=void 0===w?1019:w;return o.default.createElement(a.Modal,{containerRef:n,isOpen:l,onClose:y,noOverlay:_,noShadow:O,baseZIndex:S},o.default.createElement("div",{className:u.default.container},!!s&&o.default.createElement("h1",{className:u.default.modalHeader},s),o.default.createElement("div",{className:(0,i.default)([u.default.modalContent,(t={},t[u.default.noPadding]=g,t)])},r),o.default.createElement("div",{className:u.default.modalButtonsContainer},o.default.createElement("div",{className:u.default.modalButtons},f),o.default.createElement("div",{className:u.default.modalButtons},p))))}s.displayName="ConfirmationModal",t.default=s},function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var o=Object.getOwnPropertyDescriptor(t,r);o&&!("get"in o?!t.__esModule:o.writable||o.configurable)||(o={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,o)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),o=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),i=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)"default"!==r&&Object.prototype.hasOwnProperty.call(e,r)&&n(t,e,r);return o(t,e),t},a=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var u=i(r(0)),s=r(87),l=a(r(1)),c=a(r(32));t.default=function(e){var t,r,n=e.children,o=e.containerRef,i=e.isOpen,a=e.button,f=e.transparent,d=void 0!==f&&f,p=e.noShadow,h=void 0!==p&&p,y=e.noOverlay,v=void 0!==y&&y,g=e.onClose,m=void 0===g?function(){}:g,_=e.baseZIndex,b=void 0===_?1009:_;(0,s.useHotkeys)("Escape",m);var O=(0,u.useCallback)((function(){m()}),[m]);return i&&u.default.createElement("div",{ref:o},u.default.createElement("div",{style:{zIndex:b},className:(0,l.default)([c.default.overlay,(t={},t[c.default.noOverlay]=v,t)]),"data-testid":"modal-overlay",onClick:O}),u.default.createElement("div",{style:{zIndex:b+1},className:(0,l.default)([c.default.modal,(r={},r[c.default.transparent]=d,r[c.default.noShadow]=h,r)]),"data-testid":"modal"},n),a&&u.default.createElement("div",{style:{zIndex:b+2},className:c.default.modalButton},a))}},function(e,t,r){"use strict";r.r(t),t.default={overlay:"pU6IB2r0LpCFPXgTvOr2gA==",noOverlay:"_5SUR9Fh-fHTy4Xr6mQC+pA==",modal:"LCAT83muXsAGrPUHQ1y+hQ==",transparent:"WHU8Qbpz+AvT-YpuQeUK-Q==",noShadow:"Gi1VTmg3GPNxnX91-m0-5g==",modalButton:"lfnfHu+xyeEjcQbAQwjITg=="}},function(e,t,r){"use strict";r.r(t),t.default={container:"jvKSi-fKufcpK9eBWWFCLg==",modalHeader:"cx1RoQdgAbenvVXU8B7fSw==",modalContent:"ZD4v3HE-AYZXV0ITWDF7Gg==",noPadding:"_1zFF8xqyo77UxG2v549BeA==",modalButtonsContainer:"_4hQhCe5U7YByhnhO+-Gqiw==",modalButtons:"JoILbW5FnZixaJ7ETvo8+w=="}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.DropdownClickable=t.Dropdown=void 0;var n=r(35);Object.defineProperty(t,"Dropdown",{enumerable:!0,get:function(){return n.Dropdown}});var o=r(8);Object.defineProperty(t,"DropdownClickable",{enumerable:!0,get:function(){return o.Clickable}})},function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var o=Object.getOwnPropertyDescriptor(t,r);o&&!("get"in o?!t.__esModule:o.writable||o.configurable)||(o={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,o)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),o=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),i=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)"default"!==r&&Object.prototype.hasOwnProperty.call(e,r)&&n(t,e,r);return o(t,e),t};Object.defineProperty(t,"__esModule",{value:!0}),t.Dropdown=void 0;var a=i(r(0)),u=r(86),s=r(8),l=r(9);t.Dropdown=function(e){var t=e.itemBodyRenderer,r=e.items,n=e.onSelect,o=e.display,i=e.renderClickable,c=e.selectedItem,f=e.placement,d=void 0===f?{vertical:"bottom",horizontal:"left"}:f,p=(0,a.useState)(!1),h=p[0],y=p[1],v=(0,u.useOutsideClick)((function(){return y(!1)})),g=!r||0===r.length,m=function(){return y(!h)};return a.default.createElement(l.MenuContainer,{button:"function"==typeof i?i({display:o,isDisabled:g,selectedItem:c,toggleIsOpen:m}):a.default.createElement(s.Clickable,{display:o,isDisabled:g,onClick:m}),placement:d,ref:v},a.default.createElement(l.Menu,{isOpen:h},r&&r.map((function(e){return a.default.createElement(l.MenuItem,{isActive:e.id===(null==c?void 0:c.id),key:e.id,onClick:function(){return function(e){n(e),y(!1)}(e)}},t?t({item:e,isSelected:e.id===(null==c?void 0:c.id)}):e.name)}))))}},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var o=n(r(0)),i=n(r(1)),a=n(r(37));t.default=function(e){var t,r=e.src,n=e.alt,u=e.containerRef,s=e.size,l=void 0===s?"medium":s,c=e.inverted,f=void 0!==c&&c;return o.default.createElement("img",{ref:u,className:(0,i.default)([a.default.icon,a.default[l],(t={},t[a.default.inverted]=f,t)]),crossOrigin:"anonymous","data-testid":"icon",alt:n,src:r})}},function(e,t,r){"use strict";r.r(t),t.default={icon:"YA2IHQD4oppOioZICHwzww==",small:"qdzs2EMmBdb0MzNS0iDhMA==",medium:"I6eEGIBK59OkdpwUouaauQ==",large:"_2bi6IEYhdMbPgPJfwoPjuA==",xlarge:"ckkr4ZFOVGuCN4EjPMqeGA==",inverted:"em5rL4nAH1Iwf3MHeIePmg=="}},function(e,t,r){"use strict";r.r(t),t.default={container:"w0CpasjYyLR-i2PNIn9Esg=="}},function(e,t,r){"use strict";r.r(t),t.default="data:image/svg+xml,%3csvg width='15' height='15' viewBox='0 0 15 15' fill='none' xmlns='http://www.w3.org/2000/svg'%3e %3cpath d='M14 5L7.5 12L1 5' stroke='black' stroke-linecap='square'/%3e %3c/svg%3e"},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var o=n(r(0)),i=n(r(1)),a=n(r(41));t.default=function(e){var t,r,n=e.children,u=e.containerRef,s=e.className,l=e.isOpen,c=void 0===l||l,f=e.header,d=e.footer;return c?o.default.createElement(o.default.Fragment,null,o.default.createElement("div",{ref:u,className:(0,i.default)([a.default.menu,(t={},t[a.default.open]=c,t),s])},o.default.createElement("div",{className:a.default.scrollContainer},f&&c&&o.default.createElement("h3",{className:a.default.header},f),o.default.createElement("ul",null,c&&n)),d&&c&&o.default.createElement("div",{className:(0,i.default)([a.default.footer,(r={},r[a.default.noBorder]=!n,r)])},d))):null}},function(e,t,r){"use strict";r.r(t),t.default={menu:"rSBfsFNjjooJsDH-X+YXbw==",open:"vX7vgA9ZlF7T9ER9VJodbQ==",entrance:"GpB2LsadhuGJZvKoNOdozA==",header:"oATlBFgepZ5gAZAr-CxnAA==",footer:"wKeE73zYfb-7cRN-F8OY1g==",noBorder:"LD6LDvs-ylMrPgslj4x3hg==",scrollContainer:"T+bIpal+WHUH-hA0Gw5rVg=="}},function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var o=Object.getOwnPropertyDescriptor(t,r);o&&!("get"in o?!t.__esModule:o.writable||o.configurable)||(o={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,o)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),o=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),i=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)"default"!==r&&Object.prototype.hasOwnProperty.call(e,r)&&n(t,e,r);return o(t,e),t},a=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var u=i(r(0)),s=a(r(1)),l=a(r(43));t.default=(0,u.forwardRef)((function(e,t){var r=e.children,n=e.button,o=e.className,i=e.placement,a=void 0===i?{horizontal:"left",vertical:"bottom"}:i;return u.default.createElement("div",{ref:t,className:(0,s.default)([l.default.container,o])},n,u.default.createElement("div",{className:(0,s.default)([l.default.menuContainer,l.default[a.horizontal],l.default[a.vertical]])},r))}))},function(e,t,r){"use strict";r.r(t),t.default={container:"qcvDSfFt+w0ja2fqPc0S5w==",menuContainer:"Lwr1a3bP-95aezzmacoJfw==",top:"bBHbs+FWi6-zwWMZImF+NA==",right:"B8M42NwoZ8pUVm5R4JJv1g==",left:"pOG7tXfTFk8qqXtNC0E-Ow==",bottom:"ucvN0EFMns8bfVvsi9j9yQ=="}},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var o=n(r(0)),i=n(r(1)),a=n(r(45));t.default=function(e){var t,r,n=e.children,u=e.className,s=e.onClick,l=e.noPadding,c=void 0!==l&&l,f=e.isActive,d=void 0!==f&&f;return o.default.createElement("li",{className:(0,i.default)([a.default.menuItem,(t={},t[a.default.active]=d,t),(r={},r[a.default.noPadding]=c,r),u]),onClick:s},n)}},function(e,t,r){"use strict";r.r(t),t.default={menuItem:"mJd7dRZNOwYe8I9CqFlzrg==",noPadding:"xckDOdnPPYKTkym2awtrjA==",active:"x+yrCq5Bu+jgX7SRUr9few=="}},function(e,t,r){"use strict";var n=this&&this.__assign||function(){return(n=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var o in t=arguments[r])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)},o=this&&this.__rest||function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]])}return r},i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var a=i(r(0)),u=i(r(1)),s=i(r(47));t.default=function(e){var t,r=e.as,i=e.children,l=e.className,c=e.noPadding,f=void 0!==c&&c,d=o(e,["as","children","className","noPadding"]);return void 0===r&&(r="a"),a.default.createElement(r,n({"data-testid":"menu-link-item",className:(0,u.default)([s.default.menuLinkItem,l,(t={},t[s.default.noPadding]=f,t)])},d),i)}},function(e,t,r){"use strict";r.r(t),t.default={menuLinkItem:"oEr8ZJXLnZyDJBORZtIV4w==",noPadding:"_3TNIJAetASyzbI+KlLTHCw==",active:"ghauCTPTBEJAuAo632z5fQ==",menuItem:"n1xn4EYuxEqOc3fCEamz3Q=="}},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.FileInput=void 0;var o=r(49);Object.defineProperty(t,"FileInput",{enumerable:!0,get:function(){return n(o).default}})},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var o=n(r(0)),i=n(r(1)),a=n(r(50));t.default=function(e){var t,r=e.children,n=e.accept,u=e.onChange,s=e.inputRef,l=e.multiple,c=void 0!==l&&l,f=e.disabled,d=void 0!==f&&f,p=e.inverted,h=void 0!==p&&p,y=e.noShadow,v=void 0!==y&&y,g=e.noBorder,m=void 0!==g&&g,_=e.noPadding,b=void 0!==_&&_,O=e.transparent,w=void 0!==O&&O,S=e.stretchHorizontally,P=void 0!==S&&S,E=e.stretchVertically,j=void 0!==E&&E,k=e.rounded,A=void 0!==k&&k,x=e.size,R=void 0===x?"medium":x;return o.default.createElement("label",{className:(0,i.default)([a.default.label,a.default[R],(t={},t[a.default.inverted]=h,t[a.default.rounded]=A,t[a.default.noShadow]=v,t[a.default.noBorder]=m,t[a.default.noPadding]=b,t[a.default.transparent]=w,t[a.default.stretchHorizontally]=P,t[a.default.stretchVertically]=j,t)])},o.default.createElement("input",{className:a.default.input,type:"file",id:"file",accept:n,multiple:c,ref:s,disabled:d,onChange:u}),r)}},function(e,t,r){"use strict";r.r(t),t.default={input:"eUqa35+Em2Lch26Nxjbu+Q==",label:"nxW21h8UI0MNtwo2kcAdIw==",small:"Nda1pAcGJcyDDES5EVJsow==",large:"zqLS3YHXtjlMBsFOzrvEZg==",xlarge:"VZl5WyAkv301-hCCze5MnQ==",inverted:"vlSaJQJhzt6INvWi8NtUwg==",rounded:"b-x5TrySNGCF9HY8J3HtAA==",noShadow:"_5wl14Jjf1yxHwALxmEw6MQ==",noBorder:"dlXWQOlNe+aFkVbPxDLm4A==",noPadding:"iPxUG-ON1XLOkfVPzt7NYQ==",transparent:"BPXI9u3hgAydAc5BzzkCNg==",stretchHorizontally:"JM3JVXt77nH9ur+aL+RYDg==",stretchVertically:"MXaskffWz2k-hqtHRt2vOQ=="}},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.FloatingPanel=void 0;var o=r(52);Object.defineProperty(t,"FloatingPanel",{enumerable:!0,get:function(){return n(o).default}})},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var o=n(r(0)),i=n(r(1)),a=n(r(53));t.default=function(e){var t,r=e.children,n=e.containerRef,u=e.layout,s=void 0===u?"column":u,l=e.placement,c=void 0===l?{horizontal:"center",vertical:"bottom",parent:"viewport"}:l,f="center"===c.horizontal?"horizontalCenter":c.horizontal,d="center"===c.vertical?"verticalCenter":c.vertical;return o.default.createElement("div",{ref:n,"data-testid":"floating-panel",className:(0,i.default)([a.default.container,a.default[f],a.default[d],a.default[s],(t={},t[a.default.fixed]="container"!==c.parent,t)])},r)}},function(e,t,r){"use strict";r.r(t),t.default={container:"kUTCq7sO5cQHrn20PJUCmw==",row:"tdnc1bDHDmGbgAc7SJr69Q==",column:"Mmt076N6AxyH4NRDpCO7WA==",fixed:"_92ebQvJ5xNKJS8zakK7S2A==",plain:"y+idDxZ+5Mpp7OI3GPLAEg==",transparent:"CDqoiK0gCTJpnJgVoYgJDQ==",top:"GPsHlNPDbD6KdNQEGj8zQQ==",topEdge:"xRg0oANrxsxXNByIpnNJvw==",topOnEdge:"QAyeFFGRonxXS9FgJ2d+Ww==",right:"I8EDCJzo0ZwTtgbVTMmzdg==",rightEdge:"W2Ahm3xua2veC3ICT2KQNA==",rightOnEdge:"yjBCQYEA8mWiI98CFX5Lsw==",bottom:"WJxzXQL-5NPvDgneVgkVwA==",bottomEdge:"GVJs--pLDjWvu9C-y34ycw==",bottomOnEdge:"DDVd-PplxnLpSLFlGtFhnw==",left:"oUTMvjL0HxGenU7kJdSxHA==",leftEdge:"BiNsAkMZui+5i-KzYxq0cQ==",leftOnEdge:"_1v8imH0MTj-rMZ0rC-ihQg==",horizontalCenter:"D4p5Aa063Tnm7m0uaGhLkw==",verticalCenter:"_2deG-Y2A3zw6kF+WBnEmjw=="}},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.IconButton=void 0;var o=r(55);Object.defineProperty(t,"IconButton",{enumerable:!0,get:function(){return n(o).default}})},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var o=n(r(0)),i=n(r(1)),a=r(2),u=n(r(56));t.default=function(e){var t,r=e.className,n=e.containerRef,s=e.children,l=e.src,c=e.alt,f=e.offsetSides,d=void 0===f?[]:f,p=e.onClick,h=void 0===p?function(){}:p,y=e.disabled,v=void 0!==y&&y,g=e.inverted,m=void 0!==g&&g,_=e.noShadow,b=void 0!==_&&_,O=e.noBorder,w=void 0!==O&&O,S=e.transparent,P=void 0!==S&&S,E=e.rounded,j=void 0!==E&&E,k=e.size,A=void 0===k?"medium":k,x=e.type,R=void 0===x?"button":x;return o.default.createElement("button",{ref:n,className:(0,i.default)([u.default.container,u.default[A],(t={},t[u.default.inverted]=m,t[u.default.rounded]=j,t[u.default.noShadow]=b,t[u.default.noBorder]=w,t[u.default.transparent]=P,t[u.default.topOffset]=j&&d.includes("top"),t[u.default.rightOffset]=j&&d.includes("right"),t[u.default.bottomOffset]=j&&d.includes("bottom"),t[u.default.leftOffset]=j&&d.includes("left"),t),r]),disabled:v,onClick:h,type:R,role:"button"},o.default.createElement(a.Icon,{src:l,alt:c,size:A,inverted:m}),s)}},function(e,t,r){"use strict";r.r(t),t.default={container:"BvQtsUAa-fQPmXbvVSVCNQ==",small:"_8Zf4LzceiIoer7PIVR8BYA==",medium:"_7PF2dnJgZxIE+tS33xK4KA==",large:"EbOYvGKXiAabohi4Oy1CMw==",xlarge:"uOfZ9LiGznaBGIux40pFGg==",rounded:"vAj0xmjXJTfDbWICVKBo2g==",topOffset:"_8YSs-khIDzIefRRh5zH3+Q==",rightOffset:"q4jIl2XFObvsDM-4Qxvtuw==",bottomOffset:"_82KbEcEZzcR5VqHlx862PQ==",leftOffset:"xnc1+ODFmBPiif5JoqTndA==",inverted:"bhVUTdkQltctmrZe0T72kw==",noShadow:"nsgh2c6cHtzxaRrLkv6Fzw==",noBorder:"Vzy6C4djtpfL2pV5oYcOPw==",transparent:"FvdPS-+1tlsTZ1ciElsvxQ=="}},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.IconButtonLink=void 0;var o=r(58);Object.defineProperty(t,"IconButtonLink",{enumerable:!0,get:function(){return n(o).default}})},function(e,t,r){"use strict";var n=this&&this.__assign||function(){return(n=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var o in t=arguments[r])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)},o=this&&this.__rest||function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]])}return r},i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var a=i(r(0)),u=i(r(1)),s=r(2),l=i(r(59));t.default=function(e){var t,r=e.as,i=e.containerRef,c=e.children,f=e.className,d=e.src,p=e.alt,h=e.inverted,y=void 0!==h&&h,v=e.noShadow,g=void 0!==v&&v,m=e.noBorder,_=void 0!==m&&m,b=e.transparent,O=void 0!==b&&b,w=e.rounded,S=void 0!==w&&w,P=e.offsetSides,E=void 0===P?[]:P,j=e.disabled,k=void 0!==j&&j,A=e.size,x=void 0===A?"medium":A,R=o(e,["as","containerRef","children","className","src","alt","inverted","noShadow","noBorder","transparent","rounded","offsetSides","disabled","size"]);return void 0===r&&(r="a"),a.default.createElement(r,n({ref:i,"data-testid":"icon-button-link",className:(0,u.default)([l.default.container,l.default[x],(t={},t[l.default.inverted]=y,t[l.default.rounded]=S,t[l.default.noShadow]=g,t[l.default.noBorder]=_,t[l.default.disabled]=k,t[l.default.transparent]=O,t[l.default.topOffset]=S&&E.includes("top"),t[l.default.rightOffset]=S&&E.includes("right"),t[l.default.bottomOffset]=S&&E.includes("bottom"),t[l.default.leftOffset]=S&&E.includes("left"),t),f])},R),a.default.createElement(s.Icon,{src:d,alt:p,size:x,inverted:y}),c)}},function(e,t,r){"use strict";r.r(t),t.default={container:"mUhC7XBYehNl1f+N5hRO4A==",small:"sMS1FgM3wwLg+LguvcXDwg==",medium:"_1jU85mEP5iaWyncLLb8lSA==",large:"cIgggS2f5PaBCITfts0rAg==",xlarge:"T2zaomwLYHQx-YF-vDtwHw==",rounded:"FMAh6gsFRrUfF-C+hxFJSA==",topOffset:"yYvrImQZypKtJ0cb+hEdWQ==",rightOffset:"EiLQUe+BD8ubxdj+JQuHzw==",bottomOffset:"_0qHNIRsm+MR9ryXpJmENQQ==",leftOffset:"LmIMlxvqkRjiIgYLHxaZBg==",inverted:"Bc+Rh6B97+74jkeMdCtrzg==",noShadow:"iGGCGif2yScMISDk-2mkFQ==",noBorder:"dnjn1oFtNVFN2fRWmKkZ3A==",transparent:"ZwiF0u6KTJDgwRC4WSL3rA==",disabled:"mcZLJzT7Vs7blQ9Rxw7RUw=="}},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.Image=void 0;var o=r(61);Object.defineProperty(t,"Image",{enumerable:!0,get:function(){return n(o).default}})},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var o=n(r(0)),i=n(r(1)),a=n(r(62));t.default=function(e){var t=e.src,r=e.alt,n=e.srcWidth,u=e.srcHeight,s=e.children,l=e.containerRef,c=e.layout,f=void 0===c?"contain":c,d=e.decoding,p=void 0===d?"auto":d,h=e.loading,y=void 0===h?"eager":h,v=o.default.createElement("img",{className:(0,i.default)([a.default.image,a.default[f]]),crossOrigin:"anonymous","data-testid":"image",alt:r,src:t,width:n,height:u,decoding:p,loading:y});return s?o.default.createElement("div",{ref:l,className:(0,i.default)([a.default.container,a.default.hasOverlay])},v,s&&o.default.createElement("div",{className:a.default.overlay},s)):v}},function(e,t,r){"use strict";r.r(t),t.default={container:"_9gQSR-+gqo5rDvWPmQoAeQ==",hasOverlay:"ii3+6K+FW4YjeQFm-IN3sA==",overlay:"_00ExNc3Kw+HOfTCFa34GIw==",image:"rwD5rHcZFRNa4dHo6j3JyQ==",cover:"_6AaN1T6SY6Eej+FaQta42g==",contain:"EQDkP0F5zzJitF8uO6H+mA==",stretchHorizontally:"GBKPkc8rsyjUVuCp1OlBoQ==",stretchVertically:"_5SzwSJ+6Z4R-Ya11gwLrSQ=="}},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.ListViewLinkItem=t.ListViewItem=t.ListView=void 0;var o=r(64);Object.defineProperty(t,"ListView",{enumerable:!0,get:function(){return n(o).default}});var i=r(66);Object.defineProperty(t,"ListViewItem",{enumerable:!0,get:function(){return n(i).default}});var a=r(67);Object.defineProperty(t,"ListViewLinkItem",{enumerable:!0,get:function(){return n(a).default}})},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var o=n(r(0)),i=n(r(1)),a=n(r(65));t.default=function(e){var t=e.children,r=e.className,n=e.containerRef,u=e.header,s=e.headerActions;return o.default.createElement("div",{ref:n,className:(0,i.default)([a.default.container,r])},(u||s)&&o.default.createElement("div",{className:a.default.header},u&&o.default.createElement("h3",{className:a.default.headerLabel,id:u.id},u.text),s),o.default.createElement("ul",{"aria-labelledby":null==u?void 0:u.id,className:a.default.list},t))}},function(e,t,r){"use strict";r.r(t),t.default={container:"lJzdP0mnfpglFSYtKKYzJw==",header:"_82vCQ7xr0NkY4UlySPkpkw==",headerLabel:"unWePdIKn4XawRuL7CPD0g==",list:"_5BX+ZZ-AaQutczbDS2e5-w=="}},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var o=n(r(0)),i=n(r(1)),a=r(3),u=n(r(10));t.default=function(e){var t=e.children,r=e.active,n=void 0!==r&&r,s=e.disabled,l=void 0!==s&&s,c=e.transparent,f=void 0!==c&&c,d=e.noPadding,p=void 0!==d&&d,h=e.size,y=void 0===h?"medium":h,v=e.align,g=void 0===v?"center":v,m=e.onClick,_=void 0===m?function(){}:m;return o.default.createElement("li",{className:(0,i.default)([u.default.listViewItem])},o.default.createElement(a.Button,{onClick:_,disabled:l,inverted:n,transparent:f,noPadding:p,align:g,size:y,stretchHorizontally:!0,noShadow:!0,noBorder:!0},t))}},function(e,t,r){"use strict";var n=this&&this.__assign||function(){return(n=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var o in t=arguments[r])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)},o=this&&this.__rest||function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]])}return r},i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var a=i(r(0)),u=i(r(1)),s=r(5),l=i(r(10));t.default=function(e){var t=e.children,r=e.as,i=e.active,c=void 0!==i&&i,f=e.transparent,d=void 0!==f&&f,p=e.noPadding,h=void 0!==p&&p,y=e.align,v=void 0===y?"center":y,g=e.size,m=void 0===g?"medium":g,_=o(e,["children","as","active","transparent","noPadding","align","size"]);return void 0===r&&(r="a"),a.default.createElement("li",{className:(0,u.default)([l.default.listViewItem])},a.default.createElement(s.ButtonLink,n({as:r,inverted:c,transparent:d,noPadding:h,align:v,size:m,stretchHorizontally:!0,noShadow:!0,noBorder:!0},_),t))}},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.Overlay=void 0;var o=r(69);Object.defineProperty(t,"Overlay",{enumerable:!0,get:function(){return n(o).default}})},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var o=n(r(0)),i=n(r(1)),a=n(r(70));t.default=function(e){var t,r=e.children,n=e.containerRef,u=e.transparent,s=void 0!==u&&u,l=e.isFixed,c=void 0!==l&&l,f=e.onClick,d=void 0===f?function(){}:f;return o.default.createElement("div",{ref:n,"data-testid":"overlay",className:(0,i.default)([a.default.overlay,(t={},t[a.default.transparent]=s,t[a.default.fixed]=c,t)]),onClick:d},r)}},function(e,t,r){"use strict";r.r(t),t.default={overlay:"EIB9-l58gC3ZvtW8vtUALA==",transparent:"CM1-n3sG8YNd73qJVXM22g==",fixed:"oO1iTNlPjda1fjrYeyLuUA=="}},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.TextInput=void 0;var o=r(72);Object.defineProperty(t,"TextInput",{enumerable:!0,get:function(){return n(o).default}})},function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r);var o=Object.getOwnPropertyDescriptor(t,r);o&&!("get"in o?!t.__esModule:o.writable||o.configurable)||(o={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,o)}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),o=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),i=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)"default"!==r&&Object.prototype.hasOwnProperty.call(e,r)&&n(t,e,r);return o(t,e),t},a=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var u=i(r(0)),s=a(r(1)),l=r(4),c=a(r(73));t.default=function(e){var t,r=e.label,n=e.onChange,o=e.onBlur,i=e.onKeyDown,a=e.placeholder,f=e.value,d=e.name,p=e.pattern,h=e.inputRef,y=e.size,v=void 0===y?"medium":y,g=e.type,m=void 0===g?"text":g,_=e.autoFocus,b=void 0!==_&&_,O=e.noBorder,w=void 0!==O&&O,S=(0,u.useCallback)((function(e){n&&n(e.target.value)}),[n]),P=u.default.createElement("input",{"data-testid":"input",ref:h,className:(0,s.default)([c.default.textInput,c.default[v],(t={},t[c.default.noBorder]=w,t)]),onChange:S,onBlur:o,onKeyDown:i,pattern:p,placeholder:a,name:d,type:m,value:f,autoFocus:b});return r?u.default.createElement(l.Label,{value:r},P):u.default.createElement(u.default.Fragment,null,P)}},function(e,t,r){"use strict";r.r(t),t.default={textInput:"h6PYJAzytVOk9BeK5Z0+kg==",small:"UXn-BCVg81yMd8FoUfxKSA==",medium:"_4aiP6gxNHhrWbac4k1grUw==",large:"MlnPXYOUyQ7hgI7sw1o0xA==",xlarge:"HGBuKJa9XjxB8uVhKop03A==",noBorder:"sPnSCGUNZXroElSQR193GQ=="}},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.ToastContainer=t.Toast=void 0;var o=r(75);Object.defineProperty(t,"Toast",{enumerable:!0,get:function(){return n(o).default}});var i=r(77);Object.defineProperty(t,"ToastContainer",{enumerable:!0,get:function(){return n(i).default}})},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var o=n(r(0)),i=n(r(76));t.default=function(e){var t=e.children,r=e.containerRef,n=e.onClick,a=void 0===n?function(){}:n;return o.default.createElement("div",{ref:r,className:i.default.toast,onClick:a,"data-testid":"toast"},t)}},function(e,t,r){"use strict";r.r(t),t.default={toast:"vWa2-1mOFU+iV14jq7QPsQ==",entrance:"fTsWsKrAKlwT+GOE4wAySQ=="}},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var o=n(r(0)),i=n(r(1)),a=n(r(78));t.default=function(e){var t=e.children,r=e.baseZIndex;return o.default.createElement("div",{className:(0,i.default)([a.default.toastContainer]),style:{zIndex:r},"data-testid":"toast-container"},t)}},function(e,t,r){"use strict";r.r(t),t.default={toastContainer:"_2-Xu2sZMvN9tgDs+iyLc9Q=="}},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.Video=void 0;var o=r(80);Object.defineProperty(t,"Video",{enumerable:!0,get:function(){return n(o).default}})},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var o=n(r(0)),i=n(r(1)),a=n(r(81));t.default=function(e){var t=e.src,r=e.type,n=e.children,u=e.containerRef,s=e.poster,l=e.muted,c=void 0===l||l,f=e.loop,d=void 0===f||f,p=e.autoPlay,h=void 0===p||p,y=e.layout,v=void 0===y?"contain":y;return n?o.default.createElement("div",{ref:u,className:(0,i.default)([a.default.container,a.default.hasOverlay])},o.default.createElement("video",{"data-testid":"video",crossOrigin:"anonymous",className:(0,i.default)([a.default.video,a.default[v]]),muted:c,loop:d,autoPlay:h,poster:s,playsInline:!0},o.default.createElement("source",{"data-testid":"source",src:t,type:r})),n&&o.default.createElement("div",{className:a.default.overlay},n)):o.default.createElement("video",{"data-testid":"video",crossOrigin:"anonymous",className:(0,i.default)([a.default.video,a.default[v]]),muted:c,loop:d,autoPlay:h,poster:s,playsInline:!0},o.default.createElement("source",{"data-testid":"source",src:t,type:r}))}},function(e,t,r){"use strict";r.r(t),t.default={container:"ulWE-Epr85F0mUt7O1gUTQ==",hasOverlay:"zK7u1nkjc8x7YDAfYQCTpw==",video:"fR4D56LfduoBW-fimfbT0w==",cover:"VXQs4PUnWGyw56g60ZtfWg==",contain:"gxflUzO4rqCBAGuzsYEIew==",stretchHorizontally:"I-63Km4NY1W4QgMhfgU5Mg==",stretchVertically:"vNNhJlgITM+onf7zdzaufg==",overlay:"wxul7UUZlmarF86SGrd-tw=="}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Numpad=void 0;var n=r(83);Object.defineProperty(t,"Numpad",{enumerable:!0,get:function(){return n.Numpad}})},function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.Numpad=void 0;var o=n(r(0)),i=r(3),a=r(2),u=n(r(84)),s=n(r(85)),l=function(e,t){return 10*e+t},c=function(e){return Math.floor(e/10)},f=["0","1","2","3","4","5","6","7","8","9"];t.Numpad=o.default.forwardRef((function(e,t){var r=e.number,n=e.onChange,d=e.disabled,p=void 0!==d&&d,h=function(e){return function(t){t.stopPropagation(),n(e)}},y=Array(10).fill(0).map((function(e,t){var n=(t+1)%10;return o.default.createElement(i.Button,{key:t,disabled:p,noBorder:!0,noShadow:!0,onPointerDown:h(l(r,n))},n)}));return o.default.createElement("div",{className:u.default.numpad,ref:t,tabIndex:-1,onKeyDown:function(e){if("Backspace"===e.key)e.stopPropagation(),n(c(r));else if(f.includes(e.key)){e.stopPropagation();var t=parseInt(e.key,10);n(l(r,t))}},"data-testid":"numpad"},o.default.createElement("div",{className:u.default.numbers},y,o.default.createElement(i.Button,{disabled:p,noBorder:!0,noShadow:!0,transparent:!0,onPointerDown:h(c(r))},o.default.createElement(a.Icon,{alt:"Backspace",src:s.default}))))}))},function(e,t,r){"use strict";r.r(t),t.default={numpad:"PeO+2pBILmGhuXf+mQPJCg==",numbers:"_3+Y8DdO4vBJJtOOqRBhtqg=="}},function(e,t,r){"use strict";r.r(t),t.default="data:image/svg+xml,%3csvg width='69' height='27' viewBox='0 0 69 27' fill='none' xmlns='http://www.w3.org/2000/svg'%3e %3cpath d='M14.1333 26L13.7886 26.3622C13.8816 26.4507 14.005 26.5 14.1333 26.5V26ZM1 13.5L0.655287 13.1378C0.556127 13.2322 0.5 13.3631 0.5 13.5C0.5 13.6369 0.556127 13.7678 0.655287 13.8622L1 13.5ZM14.1333 1V0.5C14.005 0.5 13.8816 0.549345 13.7886 0.637822L14.1333 1ZM67.5 2V25H68.5V2H67.5ZM63.4667 25.5H14.1333V26.5H63.4667V25.5ZM14.478 25.6378L1.34471 13.1378L0.655287 13.8622L13.7886 26.3622L14.478 25.6378ZM1.34471 13.8622L14.478 1.36218L13.7886 0.637822L0.655287 13.1378L1.34471 13.8622ZM14.1333 1.5H63.4667V0.5H14.1333V1.5ZM67 25.5H63.4667V26.5H67V25.5ZM67 0.5H63.4667V1.5H67V0.5ZM67.5 25C67.5 25.2761 67.2761 25.5 67 25.5V26.5C67.8284 26.5 68.5 25.8284 68.5 25H67.5ZM68.5 2C68.5 1.17157 67.8284 0.5 67 0.5V1.5C67.2761 1.5 67.5 1.72386 67.5 2H68.5Z' fill='%23262626'/%3e %3cpath d='M32.6464 6.35355L46.6464 20.3536L47.3536 19.6464L33.3536 5.64645L32.6464 6.35355ZM46.6464 5.64645L32.6464 19.6464L33.3536 20.3536L47.3536 6.35355L46.6464 5.64645Z' fill='%23262626'/%3e %3c/svg%3e"},function(e,t,r){"use strict";r.r(t),r.d(t,"useOutsideClick",(function(){return i})),r.d(t,"usePromise",(function(){return u})),r.d(t,"useSWRHooksConfig",(function(){return J})),r.d(t,"useToggle",(function(){return G}));var n=r(0),o={capture:!0};function i(e){var t=Object(n.useRef)();return Object(n.useEffect)((function(){var r=function(r){t.current&&!t.current.contains(r.target)&&e(r)};return document.addEventListener("mouseup",r,o),document.addEventListener("touchend",r,o),function(){document.removeEventListener("mouseup",r,o),document.removeEventListener("touchend",r,o)}}),[e]),t}function a(e,t){var r="function"==typeof Symbol&&e[Symbol.iterator];if(!r)return e;var n,o,i=r.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(n=i.next()).done;)a.push(n.value)}catch(e){o={error:e}}finally{try{n&&!n.done&&(r=i.return)&&r.call(i)}finally{if(o)throw o.error}}return a}function u(){var e=this,t=a(Object(n.useState)({data:void 0,error:void 0,isPending:!1,isResolved:!1,isRejected:!1,isSettled:!1}),2),r=t[0],o=t[1],i=Object(n.useRef)(!1);return Object(n.useEffect)((function(){return function(){i.current=!0}}),[]),[r,Object(n.useCallback)((function(t){return function(e,t,r,n){return new(r||(r=Promise))((function(t,o){function i(e){try{u(n.next(e))}catch(e){o(e)}}function a(e){try{u(n.throw(e))}catch(e){o(e)}}function u(e){var n;e.done?t(e.value):(n=e.value,n instanceof r?n:new r((function(e){e(n)}))).then(i,a)}u((n=n.apply(e,[])).next())}))}(e,0,void 0,(function(){var e,r;return function(e,t){var r,n,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:u(0),throw:u(1),return:u(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function u(i){return function(u){return function(i){if(r)throw new TypeError("Generator is already executing.");for(;a;)try{if(r=1,n&&(o=2&i[0]?n.return:i[0]?n.throw||((o=n.return)&&o.call(n),0):n.next)&&!(o=o.call(n,i[1])).done)return o;switch(n=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,n=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!((o=(o=a.trys).length>0&&o[o.length-1])||6!==i[0]&&2!==i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){a.label=i[1];break}if(6===i[0]&&a.label<o[1]){a.label=o[1],o=i;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(i);break}o[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(e){i=[6,e],n=0}finally{r=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,u])}}}(this,(function(n){switch(n.label){case 0:return n.trys.push([0,2,,3]),o({data:void 0,error:void 0,isPending:!0,isResolved:!1,isRejected:!1,isSettled:!1}),[4,t];case 1:return e=n.sent(),!1===i.current&&o({data:e,error:void 0,isPending:!1,isResolved:!0,isRejected:!1,isSettled:!0}),[2,e];case 2:return r=n.sent(),!1===i.current&&o({error:r,data:void 0,isPending:!1,isResolved:!1,isRejected:!0,isSettled:!0}),[3,3];case 3:return[2]}}))}))}),[i])]}function s(e,t,r,n){return new(r||(r=Promise))((function(o,i){function a(e){try{s(n.next(e))}catch(e){i(e)}}function u(e){try{s(n.throw(e))}catch(e){i(e)}}function s(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,u)}s((n=n.apply(e,t||[])).next())}))}function l(e,t){var r,n,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:u(0),throw:u(1),return:u(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function u(i){return function(u){return function(i){if(r)throw new TypeError("Generator is already executing.");for(;a;)try{if(r=1,n&&(o=2&i[0]?n.return:i[0]?n.throw||((o=n.return)&&o.call(n),0):n.next)&&!(o=o.call(n,i[1])).done)return o;switch(n=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,n=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!((o=(o=a.trys).length>0&&o[o.length-1])||6!==i[0]&&2!==i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){a.label=i[1];break}if(6===i[0]&&a.label<o[1]){a.label=o[1],o=i;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(i);break}o[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(e){i=[6,e],n=0}finally{r=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,u])}}}Object.create,Object.create;var c=function(){},f=void 0,d=Object,p=function(e){return e===f},h=function(e){return"function"==typeof e},y=function(e,t){return d.assign({},e,t)},v=function(){return"undefined"!=typeof window},g=new WeakMap,m=0,_=function(e){var t,r,n=typeof e,o=e&&e.constructor,i=o==Date;if(d(e)!==e||i||o==RegExp)t=i?e.toJSON():"symbol"==n?e.toString():"string"==n?JSON.stringify(e):""+e;else{if(t=g.get(e))return t;if(t=++m+"~",g.set(e,t),o==Array){for(t="@",r=0;r<e.length;r++)t+=_(e[r])+",";g.set(e,t)}if(o==d){t="#";for(var a=d.keys(e).sort();!p(r=a.pop());)p(e[r])||(t+=r+":"+_(e[r])+",");g.set(e,t)}}return t},b=!0,O=v(),w="undefined"!=typeof document,S=O&&window.addEventListener?window.addEventListener.bind(window):c,P=w?document.addEventListener.bind(document):c,E=O&&window.removeEventListener?window.removeEventListener.bind(window):c,j=w?document.removeEventListener.bind(document):c,k={isOnline:function(){return b},isVisible:function(){var e=w&&document.visibilityState;return p(e)||"hidden"!==e}},A={initFocus:function(e){return P("visibilitychange",e),S("focus",e),function(){j("visibilitychange",e),E("focus",e)}},initReconnect:function(e){var t=function(){b=!0,e()},r=function(){b=!1};return S("online",t),S("offline",r),function(){E("online",t),E("offline",r)}}},x=!v()||"Deno"in window,R=x?n.useEffect:n.useLayoutEffect,I="undefined"!=typeof navigator&&navigator.connection,C=!x&&I&&(["slow-2g","2g"].includes(I.effectiveType)||I.saveData),M=function(e){if(h(e))try{e=e()}catch(t){e=""}var t=[].concat(e);return[e="string"==typeof e?e:(Array.isArray(e)?e.length:e)?_(e):"",t,e?"$swr$"+e:""]},N=new WeakMap,T=function(e,t,r,n,o,i,a){void 0===a&&(a=!0);var u=N.get(e),s=u[0],l=u[1],c=u[3],f=s[t],d=l[t];if(a&&d)for(var p=0;p<d.length;++p)d[p](r,n,o);return i&&(delete c[t],f&&f[0])?f[0](2).then((function(){return e.get(t)})):e.get(t)},L=0,D=function(){return++L},z=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return s(void 0,void 0,void 0,(function(){var t,r,n,o,i,a,u,s,c,d,v,g,m,_,b,O,w,S,P,E,j;return l(this,(function(l){switch(l.label){case 0:if(t=e[0],r=e[1],n=e[2],o=e[3],a=!!p((i="boolean"==typeof o?{revalidate:o}:o||{}).populateCache)||i.populateCache,u=!1!==i.revalidate,s=!1!==i.rollbackOnError,c=i.optimisticData,d=M(r),v=d[0],g=d[2],!v)return[2];if(m=N.get(t),_=m[2],e.length<3)return[2,T(t,v,t.get(v),f,f,u,!0)];if(b=n,w=D(),_[v]=[w,0],S=!p(c),P=t.get(v),S&&(E=h(c)?c(P):c,t.set(v,E),T(t,v,E)),h(b))try{b=b(t.get(v))}catch(e){O=e}return b&&h(b.then)?[4,b.catch((function(e){O=e}))]:[3,2];case 1:if(b=l.sent(),w!==_[v][0]){if(O)throw O;return[2,b]}O&&S&&s&&(a=!0,b=P,t.set(v,P)),l.label=2;case 2:return a&&(O||(h(a)&&(b=a(b,P)),t.set(v,b)),t.set(g,y(t.get(g),{error:O}))),_[v][1]=D(),[4,T(t,v,b,O,f,u,!!a)];case 3:if(j=l.sent(),O)throw O;return[2,a?j:b]}}))}))},B=function(e,t){for(var r in e)e[r][0]&&e[r][0](t)},F=function(e,t){if(!N.has(e)){var r=y(A,t),n={},o=z.bind(f,e),i=c;if(N.set(e,[n,{},{},{},o]),!x){var a=r.initFocus(setTimeout.bind(f,B.bind(f,n,0))),u=r.initReconnect(setTimeout.bind(f,B.bind(f,n,1)));i=function(){a&&a(),u&&u(),N.delete(e)}}return[e,o,i]}return[e,N.get(e)[4]]},U=F(new Map),H=U[0],q=U[1],Q=y({onLoadingSlow:c,onSuccess:c,onError:c,onErrorRetry:function(e,t,r,n,o){var i=r.errorRetryCount,a=o.retryCount,u=~~((Math.random()+.5)*(1<<(a<8?a:8)))*r.errorRetryInterval;!p(i)&&a>i||setTimeout(n,u,o)},onDiscarded:c,revalidateOnFocus:!0,revalidateOnReconnect:!0,revalidateIfStale:!0,shouldRetryOnError:!0,errorRetryInterval:C?1e4:5e3,focusThrottleInterval:5e3,dedupingInterval:2e3,loadingTimeout:C?5e3:3e3,compare:function(e,t){return _(e)==_(t)},isPaused:function(){return!1},cache:H,mutate:q,fallback:{}},k),V=Object(n.createContext)({});function J(){var e=y(Q,Object(n.useContext)(V));return Object(n.useMemo)((function(){return{mutate:e.mutate,cache:e.cache}}),[e.mutate,e.cache])}function G(e){void 0===e&&(e=!1);var t=a(Object(n.useState)(e),2),r=t[0],o=t[1];return[r,Object(n.useCallback)((function(e){o("boolean"==typeof e?e:function(e){return!e})}),[])]}d.defineProperty((function(e){var t=e.value,r=function(e,t){var r=y(e,t);if(t){var n=e.use,o=e.fallback,i=t.use,a=t.fallback;n&&i&&(r.use=n.concat(i)),o&&a&&(r.fallback=y(o,a))}return r}(Object(n.useContext)(V),t),o=t&&t.provider,i=Object(n.useState)((function(){return o?F(o(r.cache||H),t):f}))[0];return i&&(r.cache=i[0],r.mutate=i[1]),R((function(){return i?i[2]:f}),[]),Object(n.createElement)(V.Provider,y(e,{value:r}))}),"default",{value:Q})},function(e,t,r){"use strict";r.r(t),r.d(t,"isHotkeyPressed",(function(){return I})),r.d(t,"useHotkeys",(function(){return R})),r.d(t,"useIsHotkeyPressed",(function(){return A}));var n="undefined"!=typeof navigator&&navigator.userAgent.toLowerCase().indexOf("firefox")>0;function o(e,t,r,n){e.addEventListener?e.addEventListener(t,r,n):e.attachEvent&&e.attachEvent("on".concat(t),(function(){r(window.event)}))}function i(e,t){for(var r=t.slice(0,t.length-1),n=0;n<r.length;n++)r[n]=e[r[n].toLowerCase()];return r}function a(e){"string"!=typeof e&&(e="");for(var t=(e=e.replace(/\s/g,"")).split(","),r=t.lastIndexOf("");r>=0;)t[r-1]+=",",t.splice(r,1),r=t.lastIndexOf("");return t}for(var u={backspace:8,tab:9,clear:12,enter:13,return:13,esc:27,escape:27,space:32,left:37,up:38,right:39,down:40,del:46,delete:46,ins:45,insert:45,home:36,end:35,pageup:33,pagedown:34,capslock:20,num_0:96,num_1:97,num_2:98,num_3:99,num_4:100,num_5:101,num_6:102,num_7:103,num_8:104,num_9:105,num_multiply:106,num_add:107,num_enter:108,num_subtract:109,num_decimal:110,num_divide:111,"⇪":20,",":188,".":190,"/":191,"`":192,"-":n?173:189,"=":n?61:187,";":n?59:186,"'":222,"[":219,"]":221,"\\":220},s={"⇧":16,shift:16,"⌥":18,alt:18,option:18,"⌃":17,ctrl:17,control:17,"⌘":91,cmd:91,command:91},l={16:"shiftKey",18:"altKey",17:"ctrlKey",91:"metaKey",shiftKey:16,ctrlKey:17,altKey:18,metaKey:91},c={16:!1,18:!1,17:!1,91:!1},f={},d=1;d<20;d++)u["f".concat(d)]=111+d;var p=[],h=!1,y="all",v=[],g=function(e){return u[e.toLowerCase()]||s[e.toLowerCase()]||e.toUpperCase().charCodeAt(0)};function m(e){y=e||"all"}function _(){return y||"all"}var b=function(e){var t=e.key,r=e.scope,n=e.method,o=e.splitKey,u=void 0===o?"+":o;a(t).forEach((function(e){var t=e.split(u),o=t.length,a=t[o-1],l="*"===a?"*":g(a);if(f[l]){r||(r=_());var c=o>1?i(s,t):[];f[l]=f[l].filter((function(e){return!((!n||e.method===n)&&e.scope===r&&function(e,t){for(var r=e.length>=t.length?e:t,n=e.length>=t.length?t:e,o=!0,i=0;i<r.length;i++)-1===n.indexOf(r[i])&&(o=!1);return o}(e.mods,c))}))}}))};function O(e,t,r,n){var o;if(t.element===n&&(t.scope===r||"all"===t.scope)){for(var i in o=t.mods.length>0,c)Object.prototype.hasOwnProperty.call(c,i)&&(!c[i]&&t.mods.indexOf(+i)>-1||c[i]&&-1===t.mods.indexOf(+i))&&(o=!1);(0!==t.mods.length||c[16]||c[18]||c[17]||c[91])&&!o&&"*"!==t.shortcut||!1===t.method(e,t)&&(e.preventDefault?e.preventDefault():e.returnValue=!1,e.stopPropagation&&e.stopPropagation(),e.cancelBubble&&(e.cancelBubble=!0))}}function w(e,t){var r=f["*"],n=e.keyCode||e.which||e.charCode;if(S.filter.call(this,e)){if(93!==n&&224!==n||(n=91),-1===p.indexOf(n)&&229!==n&&p.push(n),["ctrlKey","altKey","shiftKey","metaKey"].forEach((function(t){var r=l[t];e[t]&&-1===p.indexOf(r)?p.push(r):!e[t]&&p.indexOf(r)>-1?p.splice(p.indexOf(r),1):"metaKey"===t&&e[t]&&3===p.length&&(e.ctrlKey||e.shiftKey||e.altKey||(p=p.slice(p.indexOf(r))))})),n in c){for(var o in c[n]=!0,s)s[o]===n&&(S[o]=!0);if(!r)return}for(var i in c)Object.prototype.hasOwnProperty.call(c,i)&&(c[i]=e[l[i]]);e.getModifierState&&(!e.altKey||e.ctrlKey)&&e.getModifierState("AltGraph")&&(-1===p.indexOf(17)&&p.push(17),-1===p.indexOf(18)&&p.push(18),c[17]=!0,c[18]=!0);var a=_();if(r)for(var u=0;u<r.length;u++)r[u].scope===a&&("keydown"===e.type&&r[u].keydown||"keyup"===e.type&&r[u].keyup)&&O(e,r[u],a,t);if(n in f)for(var d=0;d<f[n].length;d++)if(("keydown"===e.type&&f[n][d].keydown||"keyup"===e.type&&f[n][d].keyup)&&f[n][d].key){for(var h=f[n][d],y=h.splitKey,v=h.key.split(y),m=[],b=0;b<v.length;b++)m.push(g(v[b]));m.sort().join("")===p.sort().join("")&&O(e,h,a,t)}}}function S(e,t,r){p=[];var n=a(e),u=[],l="all",d=document,y=0,m=!1,_=!0,b="+",O=!1;for(void 0===r&&"function"==typeof t&&(r=t),"[object Object]"===Object.prototype.toString.call(t)&&(t.scope&&(l=t.scope),t.element&&(d=t.element),t.keyup&&(m=t.keyup),void 0!==t.keydown&&(_=t.keydown),void 0!==t.capture&&(O=t.capture),"string"==typeof t.splitKey&&(b=t.splitKey)),"string"==typeof t&&(l=t);y<n.length;y++)u=[],(e=n[y].split(b)).length>1&&(u=i(s,e)),(e="*"===(e=e[e.length-1])?"*":g(e))in f||(f[e]=[]),f[e].push({keyup:m,keydown:_,scope:l,mods:u,shortcut:n[y],method:r,key:n[y],splitKey:b,element:d});void 0!==d&&!function(e){return v.indexOf(e)>-1}(d)&&window&&(v.push(d),o(d,"keydown",(function(e){w(e,d)}),O),h||(h=!0,o(window,"focus",(function(){p=[]}),O)),o(d,"keyup",(function(e){w(e,d),function(e){var t=e.keyCode||e.which||e.charCode,r=p.indexOf(t);if(r>=0&&p.splice(r,1),e.key&&"meta"===e.key.toLowerCase()&&p.splice(0,p.length),93!==t&&224!==t||(t=91),t in c)for(var n in c[t]=!1,s)s[n]===t&&(S[n]=!1)}(e)}),O))}var P={setScope:m,getScope:_,deleteScope:function(e,t){var r,n;for(var o in e||(e=_()),f)if(Object.prototype.hasOwnProperty.call(f,o))for(r=f[o],n=0;n<r.length;)r[n].scope===e?r.splice(n,1):n++;_()===e&&m(t||"all")},getPressedKeyCodes:function(){return p.slice(0)},isPressed:function(e){return"string"==typeof e&&(e=g(e)),-1!==p.indexOf(e)},filter:function(e){var t=e.target||e.srcElement,r=t.tagName,n=!0;return!t.isContentEditable&&("INPUT"!==r&&"TEXTAREA"!==r&&"SELECT"!==r||t.readOnly)||(n=!1),n},trigger:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"all";Object.keys(f).forEach((function(r){var n=f[r].find((function(r){return r.scope===t&&r.shortcut===e}));n&&n.method&&n.method()}))},unbind:function(e){if(e){if(Array.isArray(e))e.forEach((function(e){e.key&&b(e)}));else if("object"==typeof e)e.key&&b(e);else if("string"==typeof e){for(var t=arguments.length,r=new Array(t>1?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];var o=r[0],i=r[1];"function"==typeof o&&(i=o,o=""),b({key:e,scope:o,method:i,splitKey:"+"})}}else Object.keys(f).forEach((function(e){return delete f[e]}))},keyMap:u,modifier:s,modifierMap:l};for(var E in P)Object.prototype.hasOwnProperty.call(P,E)&&(S[E]=P[E]);if("undefined"!=typeof window){var j=window.hotkeys;S.noConflict=function(e){return e&&window.hotkeys===S&&(window.hotkeys=j),S},window.hotkeys=S}var k=r(0);function A(){return S.isPressed}S.filter=function(){return!0};var x=function(e,t){var r=e.target,n=r&&r.tagName;return Boolean(n&&t&&t.includes(n))};function R(e,t,r,n){r instanceof Array&&(n=r,r=void 0);var o=r||{},i=o.enableOnTags,a=o.filter,u=o.keyup,s=o.keydown,l=o.filterPreventDefault,c=void 0===l||l,f=o.enabled,d=void 0===f||f,p=o.enableOnContentEditable,h=void 0!==p&&p,y=Object(k.useRef)(null),v=Object(k.useCallback)((function(e,r){var n;return a&&!a(e)?!c:!!(x(e,["INPUT","TEXTAREA","SELECT"])&&!x(e,i)||null!=(n=e.target)&&n.isContentEditable&&!h)||(null===y.current||document.activeElement===y.current)&&(t(e,r),!0)}),n?[y,i,a].concat(n):[y,i,a]);return Object(k.useEffect)((function(){if(d)return u&&!0!==s&&(r.keydown=!1),S(e,r||{},v),function(){return S.unbind(e,v)};S.unbind(e,v)}),[v,e,d]),y}var I=S.isPressed}]))},742:(e,t)=>{"use strict";t.byteLength=function(e){var t=s(e),r=t[0],n=t[1];return 3*(r+n)/4-n},t.toByteArray=function(e){var t,r,i=s(e),a=i[0],u=i[1],l=new o(function(e,t,r){return 3*(t+r)/4-r}(0,a,u)),c=0,f=u>0?a-4:a;for(r=0;r<f;r+=4)t=n[e.charCodeAt(r)]<<18|n[e.charCodeAt(r+1)]<<12|n[e.charCodeAt(r+2)]<<6|n[e.charCodeAt(r+3)],l[c++]=t>>16&255,l[c++]=t>>8&255,l[c++]=255&t;return 2===u&&(t=n[e.charCodeAt(r)]<<2|n[e.charCodeAt(r+1)]>>4,l[c++]=255&t),1===u&&(t=n[e.charCodeAt(r)]<<10|n[e.charCodeAt(r+1)]<<4|n[e.charCodeAt(r+2)]>>2,l[c++]=t>>8&255,l[c++]=255&t),l},t.fromByteArray=function(e){for(var t,n=e.length,o=n%3,i=[],a=16383,u=0,s=n-o;u<s;u+=a)i.push(l(e,u,u+a>s?s:u+a));return 1===o?(t=e[n-1],i.push(r[t>>2]+r[t<<4&63]+"==")):2===o&&(t=(e[n-2]<<8)+e[n-1],i.push(r[t>>10]+r[t>>4&63]+r[t<<2&63]+"=")),i.join("")};for(var r=[],n=[],o="undefined"!=typeof Uint8Array?Uint8Array:Array,i="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",a=0,u=i.length;a<u;++a)r[a]=i[a],n[i.charCodeAt(a)]=a;function s(e){var t=e.length;if(t%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var r=e.indexOf("=");return-1===r&&(r=t),[r,r===t?0:4-r%4]}function l(e,t,n){for(var o,i,a=[],u=t;u<n;u+=3)o=(e[u]<<16&16711680)+(e[u+1]<<8&65280)+(255&e[u+2]),a.push(r[(i=o)>>18&63]+r[i>>12&63]+r[i>>6&63]+r[63&i]);return a.join("")}n["-".charCodeAt(0)]=62,n["_".charCodeAt(0)]=63},924:(e,t,r)=>{"use strict";var n=r(210),o=r(559),i=o(n("String.prototype.indexOf"));e.exports=function(e,t){var r=n(e,!!t);return"function"==typeof r&&i(e,".prototype.")>-1?o(r):r}},559:(e,t,r)=>{"use strict";var n=r(612),o=r(210),i=o("%Function.prototype.apply%"),a=o("%Function.prototype.call%"),u=o("%Reflect.apply%",!0)||n.call(a,i),s=o("%Object.getOwnPropertyDescriptor%",!0),l=o("%Object.defineProperty%",!0),c=o("%Math.max%");if(l)try{l({},"a",{value:1})}catch(e){l=null}e.exports=function(e){var t=u(n,a,arguments);if(s&&l){var r=s(t,"length");r.configurable&&l(t,"length",{value:1+c(0,e.length-(arguments.length-1))})}return t};var f=function(){return u(n,i,arguments)};l?l(e.exports,"apply",{value:f}):e.exports.apply=f},187:e=>{"use strict";var t,r="object"==typeof Reflect?Reflect:null,n=r&&"function"==typeof r.apply?r.apply:function(e,t,r){return Function.prototype.apply.call(e,t,r)};t=r&&"function"==typeof r.ownKeys?r.ownKeys:Object.getOwnPropertySymbols?function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:function(e){return Object.getOwnPropertyNames(e)};var o=Number.isNaN||function(e){return e!=e};function i(){i.init.call(this)}e.exports=i,e.exports.once=function(e,t){return new Promise((function(r,n){function o(r){e.removeListener(t,i),n(r)}function i(){"function"==typeof e.removeListener&&e.removeListener("error",o),r([].slice.call(arguments))}y(e,t,i,{once:!0}),"error"!==t&&function(e,t,r){"function"==typeof e.on&&y(e,"error",t,{once:!0})}(e,o)}))},i.EventEmitter=i,i.prototype._events=void 0,i.prototype._eventsCount=0,i.prototype._maxListeners=void 0;var a=10;function u(e){if("function"!=typeof e)throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof e)}function s(e){return void 0===e._maxListeners?i.defaultMaxListeners:e._maxListeners}function l(e,t,r,n){var o,i,a,l;if(u(r),void 0===(i=e._events)?(i=e._events=Object.create(null),e._eventsCount=0):(void 0!==i.newListener&&(e.emit("newListener",t,r.listener?r.listener:r),i=e._events),a=i[t]),void 0===a)a=i[t]=r,++e._eventsCount;else if("function"==typeof a?a=i[t]=n?[r,a]:[a,r]:n?a.unshift(r):a.push(r),(o=s(e))>0&&a.length>o&&!a.warned){a.warned=!0;var c=new Error("Possible EventEmitter memory leak detected. "+a.length+" "+String(t)+" listeners added. Use emitter.setMaxListeners() to increase limit");c.name="MaxListenersExceededWarning",c.emitter=e,c.type=t,c.count=a.length,l=c,console&&console.warn&&console.warn(l)}return e}function c(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,0===arguments.length?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function f(e,t,r){var n={fired:!1,wrapFn:void 0,target:e,type:t,listener:r},o=c.bind(n);return o.listener=r,n.wrapFn=o,o}function d(e,t,r){var n=e._events;if(void 0===n)return[];var o=n[t];return void 0===o?[]:"function"==typeof o?r?[o.listener||o]:[o]:r?function(e){for(var t=new Array(e.length),r=0;r<t.length;++r)t[r]=e[r].listener||e[r];return t}(o):h(o,o.length)}function p(e){var t=this._events;if(void 0!==t){var r=t[e];if("function"==typeof r)return 1;if(void 0!==r)return r.length}return 0}function h(e,t){for(var r=new Array(t),n=0;n<t;++n)r[n]=e[n];return r}function y(e,t,r,n){if("function"==typeof e.on)n.once?e.once(t,r):e.on(t,r);else{if("function"!=typeof e.addEventListener)throw new TypeError('The "emitter" argument must be of type EventEmitter. Received type '+typeof e);e.addEventListener(t,(function o(i){n.once&&e.removeEventListener(t,o),r(i)}))}}Object.defineProperty(i,"defaultMaxListeners",{enumerable:!0,get:function(){return a},set:function(e){if("number"!=typeof e||e<0||o(e))throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+e+".");a=e}}),i.init=function(){void 0!==this._events&&this._events!==Object.getPrototypeOf(this)._events||(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0},i.prototype.setMaxListeners=function(e){if("number"!=typeof e||e<0||o(e))throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+e+".");return this._maxListeners=e,this},i.prototype.getMaxListeners=function(){return s(this)},i.prototype.emit=function(e){for(var t=[],r=1;r<arguments.length;r++)t.push(arguments[r]);var o="error"===e,i=this._events;if(void 0!==i)o=o&&void 0===i.error;else if(!o)return!1;if(o){var a;if(t.length>0&&(a=t[0]),a instanceof Error)throw a;var u=new Error("Unhandled error."+(a?" ("+a.message+")":""));throw u.context=a,u}var s=i[e];if(void 0===s)return!1;if("function"==typeof s)n(s,this,t);else{var l=s.length,c=h(s,l);for(r=0;r<l;++r)n(c[r],this,t)}return!0},i.prototype.addListener=function(e,t){return l(this,e,t,!1)},i.prototype.on=i.prototype.addListener,i.prototype.prependListener=function(e,t){return l(this,e,t,!0)},i.prototype.once=function(e,t){return u(t),this.on(e,f(this,e,t)),this},i.prototype.prependOnceListener=function(e,t){return u(t),this.prependListener(e,f(this,e,t)),this},i.prototype.removeListener=function(e,t){var r,n,o,i,a;if(u(t),void 0===(n=this._events))return this;if(void 0===(r=n[e]))return this;if(r===t||r.listener===t)0==--this._eventsCount?this._events=Object.create(null):(delete n[e],n.removeListener&&this.emit("removeListener",e,r.listener||t));else if("function"!=typeof r){for(o=-1,i=r.length-1;i>=0;i--)if(r[i]===t||r[i].listener===t){a=r[i].listener,o=i;break}if(o<0)return this;0===o?r.shift():function(e,t){for(;t+1<e.length;t++)e[t]=e[t+1];e.pop()}(r,o),1===r.length&&(n[e]=r[0]),void 0!==n.removeListener&&this.emit("removeListener",e,a||t)}return this},i.prototype.off=i.prototype.removeListener,i.prototype.removeAllListeners=function(e){var t,r,n;if(void 0===(r=this._events))return this;if(void 0===r.removeListener)return 0===arguments.length?(this._events=Object.create(null),this._eventsCount=0):void 0!==r[e]&&(0==--this._eventsCount?this._events=Object.create(null):delete r[e]),this;if(0===arguments.length){var o,i=Object.keys(r);for(n=0;n<i.length;++n)"removeListener"!==(o=i[n])&&this.removeAllListeners(o);return this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0,this}if("function"==typeof(t=r[e]))this.removeListener(e,t);else if(void 0!==t)for(n=t.length-1;n>=0;n--)this.removeListener(e,t[n]);return this},i.prototype.listeners=function(e){return d(this,e,!0)},i.prototype.rawListeners=function(e){return d(this,e,!1)},i.listenerCount=function(e,t){return"function"==typeof e.listenerCount?e.listenerCount(t):p.call(e,t)},i.prototype.listenerCount=p,i.prototype.eventNames=function(){return this._eventsCount>0?t(this._events):[]}},648:e=>{"use strict";var t="Function.prototype.bind called on incompatible ",r=Array.prototype.slice,n=Object.prototype.toString,o="[object Function]";e.exports=function(e){var i=this;if("function"!=typeof i||n.call(i)!==o)throw new TypeError(t+i);for(var a,u=r.call(arguments,1),s=function(){if(this instanceof a){var t=i.apply(this,u.concat(r.call(arguments)));return Object(t)===t?t:this}return i.apply(e,u.concat(r.call(arguments)))},l=Math.max(0,i.length-u.length),c=[],f=0;f<l;f++)c.push("$"+f);if(a=Function("binder","return function ("+c.join(",")+"){ return binder.apply(this,arguments); }")(s),i.prototype){var d=function(){};d.prototype=i.prototype,a.prototype=new d,d.prototype=null}return a}},612:(e,t,r)=>{"use strict";var n=r(648);e.exports=Function.prototype.bind||n},210:(e,t,r)=>{"use strict";var n,o=SyntaxError,i=Function,a=TypeError,u=function(e){try{return i('"use strict"; return ('+e+").constructor;")()}catch(e){}},s=Object.getOwnPropertyDescriptor;if(s)try{s({},"")}catch(e){s=null}var l=function(){throw new a},c=s?function(){try{return l}catch(e){try{return s(arguments,"callee").get}catch(e){return l}}}():l,f=r(405)(),d=Object.getPrototypeOf||function(e){return e.__proto__},p={},h="undefined"==typeof Uint8Array?n:d(Uint8Array),y={"%AggregateError%":"undefined"==typeof AggregateError?n:AggregateError,"%Array%":Array,"%ArrayBuffer%":"undefined"==typeof ArrayBuffer?n:ArrayBuffer,"%ArrayIteratorPrototype%":f?d([][Symbol.iterator]()):n,"%AsyncFromSyncIteratorPrototype%":n,"%AsyncFunction%":p,"%AsyncGenerator%":p,"%AsyncGeneratorFunction%":p,"%AsyncIteratorPrototype%":p,"%Atomics%":"undefined"==typeof Atomics?n:Atomics,"%BigInt%":"undefined"==typeof BigInt?n:BigInt,"%Boolean%":Boolean,"%DataView%":"undefined"==typeof DataView?n:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":Error,"%eval%":eval,"%EvalError%":EvalError,"%Float32Array%":"undefined"==typeof Float32Array?n:Float32Array,"%Float64Array%":"undefined"==typeof Float64Array?n:Float64Array,"%FinalizationRegistry%":"undefined"==typeof FinalizationRegistry?n:FinalizationRegistry,"%Function%":i,"%GeneratorFunction%":p,"%Int8Array%":"undefined"==typeof Int8Array?n:Int8Array,"%Int16Array%":"undefined"==typeof Int16Array?n:Int16Array,"%Int32Array%":"undefined"==typeof Int32Array?n:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":f?d(d([][Symbol.iterator]())):n,"%JSON%":"object"==typeof JSON?JSON:n,"%Map%":"undefined"==typeof Map?n:Map,"%MapIteratorPrototype%":"undefined"!=typeof Map&&f?d((new Map)[Symbol.iterator]()):n,"%Math%":Math,"%Number%":Number,"%Object%":Object,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":"undefined"==typeof Promise?n:Promise,"%Proxy%":"undefined"==typeof Proxy?n:Proxy,"%RangeError%":RangeError,"%ReferenceError%":ReferenceError,"%Reflect%":"undefined"==typeof Reflect?n:Reflect,"%RegExp%":RegExp,"%Set%":"undefined"==typeof Set?n:Set,"%SetIteratorPrototype%":"undefined"!=typeof Set&&f?d((new Set)[Symbol.iterator]()):n,"%SharedArrayBuffer%":"undefined"==typeof SharedArrayBuffer?n:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":f?d(""[Symbol.iterator]()):n,"%Symbol%":f?Symbol:n,"%SyntaxError%":o,"%ThrowTypeError%":c,"%TypedArray%":h,"%TypeError%":a,"%Uint8Array%":"undefined"==typeof Uint8Array?n:Uint8Array,"%Uint8ClampedArray%":"undefined"==typeof Uint8ClampedArray?n:Uint8ClampedArray,"%Uint16Array%":"undefined"==typeof Uint16Array?n:Uint16Array,"%Uint32Array%":"undefined"==typeof Uint32Array?n:Uint32Array,"%URIError%":URIError,"%WeakMap%":"undefined"==typeof WeakMap?n:WeakMap,"%WeakRef%":"undefined"==typeof WeakRef?n:WeakRef,"%WeakSet%":"undefined"==typeof WeakSet?n:WeakSet},v=function e(t){var r;if("%AsyncFunction%"===t)r=u("async function () {}");else if("%GeneratorFunction%"===t)r=u("function* () {}");else if("%AsyncGeneratorFunction%"===t)r=u("async function* () {}");else if("%AsyncGenerator%"===t){var n=e("%AsyncGeneratorFunction%");n&&(r=n.prototype)}else if("%AsyncIteratorPrototype%"===t){var o=e("%AsyncGenerator%");o&&(r=d(o.prototype))}return y[t]=r,r},g={"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},m=r(612),_=r(642),b=m.call(Function.call,Array.prototype.concat),O=m.call(Function.apply,Array.prototype.splice),w=m.call(Function.call,String.prototype.replace),S=m.call(Function.call,String.prototype.slice),P=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,E=/\\(\\)?/g,j=function(e){var t=S(e,0,1),r=S(e,-1);if("%"===t&&"%"!==r)throw new o("invalid intrinsic syntax, expected closing `%`");if("%"===r&&"%"!==t)throw new o("invalid intrinsic syntax, expected opening `%`");var n=[];return w(e,P,(function(e,t,r,o){n[n.length]=r?w(o,E,"$1"):t||e})),n},k=function(e,t){var r,n=e;if(_(g,n)&&(n="%"+(r=g[n])[0]+"%"),_(y,n)){var i=y[n];if(i===p&&(i=v(n)),void 0===i&&!t)throw new a("intrinsic "+e+" exists, but is not available. Please file an issue!");return{alias:r,name:n,value:i}}throw new o("intrinsic "+e+" does not exist!")};e.exports=function(e,t){if("string"!=typeof e||0===e.length)throw new a("intrinsic name must be a non-empty string");if(arguments.length>1&&"boolean"!=typeof t)throw new a('"allowMissing" argument must be a boolean');var r=j(e),n=r.length>0?r[0]:"",i=k("%"+n+"%",t),u=i.name,l=i.value,c=!1,f=i.alias;f&&(n=f[0],O(r,b([0,1],f)));for(var d=1,p=!0;d<r.length;d+=1){var h=r[d],v=S(h,0,1),g=S(h,-1);if(('"'===v||"'"===v||"`"===v||'"'===g||"'"===g||"`"===g)&&v!==g)throw new o("property names with quotes must have matching quotes");if("constructor"!==h&&p||(c=!0),_(y,u="%"+(n+="."+h)+"%"))l=y[u];else if(null!=l){if(!(h in l)){if(!t)throw new a("base intrinsic for "+e+" exists, but the property is not available.");return}if(s&&d+1>=r.length){var m=s(l,h);l=(p=!!m)&&"get"in m&&!("originalValue"in m.get)?m.get:l[h]}else p=_(l,h),l=l[h];p&&!c&&(y[u]=l)}}return l}},405:(e,t,r)=>{"use strict";var n="undefined"!=typeof Symbol&&Symbol,o=r(419);e.exports=function(){return"function"==typeof n&&"function"==typeof Symbol&&"symbol"==typeof n("foo")&&"symbol"==typeof Symbol("bar")&&o()}},419:e=>{"use strict";e.exports=function(){if("function"!=typeof Symbol||"function"!=typeof Object.getOwnPropertySymbols)return!1;if("symbol"==typeof Symbol.iterator)return!0;var e={},t=Symbol("test"),r=Object(t);if("string"==typeof t)return!1;if("[object Symbol]"!==Object.prototype.toString.call(t))return!1;if("[object Symbol]"!==Object.prototype.toString.call(r))return!1;for(t in e[t]=42,e)return!1;if("function"==typeof Object.keys&&0!==Object.keys(e).length)return!1;if("function"==typeof Object.getOwnPropertyNames&&0!==Object.getOwnPropertyNames(e).length)return!1;var n=Object.getOwnPropertySymbols(e);if(1!==n.length||n[0]!==t)return!1;if(!Object.prototype.propertyIsEnumerable.call(e,t))return!1;if("function"==typeof Object.getOwnPropertyDescriptor){var o=Object.getOwnPropertyDescriptor(e,t);if(42!==o.value||!0!==o.enumerable)return!1}return!0}},642:(e,t,r)=>{"use strict";var n=r(612);e.exports=n.call(Function.call,Object.prototype.hasOwnProperty)},631:(e,t,r)=>{var n="function"==typeof Map&&Map.prototype,o=Object.getOwnPropertyDescriptor&&n?Object.getOwnPropertyDescriptor(Map.prototype,"size"):null,i=n&&o&&"function"==typeof o.get?o.get:null,a=n&&Map.prototype.forEach,u="function"==typeof Set&&Set.prototype,s=Object.getOwnPropertyDescriptor&&u?Object.getOwnPropertyDescriptor(Set.prototype,"size"):null,l=u&&s&&"function"==typeof s.get?s.get:null,c=u&&Set.prototype.forEach,f="function"==typeof WeakMap&&WeakMap.prototype?WeakMap.prototype.has:null,d="function"==typeof WeakSet&&WeakSet.prototype?WeakSet.prototype.has:null,p="function"==typeof WeakRef&&WeakRef.prototype?WeakRef.prototype.deref:null,h=Boolean.prototype.valueOf,y=Object.prototype.toString,v=Function.prototype.toString,g=String.prototype.match,m=String.prototype.slice,_=String.prototype.replace,b=String.prototype.toUpperCase,O=String.prototype.toLowerCase,w=RegExp.prototype.test,S=Array.prototype.concat,P=Array.prototype.join,E=Array.prototype.slice,j=Math.floor,k="function"==typeof BigInt?BigInt.prototype.valueOf:null,A=Object.getOwnPropertySymbols,x="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?Symbol.prototype.toString:null,R="function"==typeof Symbol&&"object"==typeof Symbol.iterator,I="function"==typeof Symbol&&Symbol.toStringTag&&(Symbol.toStringTag,1)?Symbol.toStringTag:null,C=Object.prototype.propertyIsEnumerable,M=("function"==typeof Reflect?Reflect.getPrototypeOf:Object.getPrototypeOf)||([].__proto__===Array.prototype?function(e){return e.__proto__}:null);function N(e,t){if(e===1/0||e===-1/0||e!=e||e&&e>-1e3&&e<1e3||w.call(/e/,t))return t;var r=/[0-9](?=(?:[0-9]{3})+(?![0-9]))/g;if("number"==typeof e){var n=e<0?-j(-e):j(e);if(n!==e){var o=String(n),i=m.call(t,o.length+1);return _.call(o,r,"$&_")+"."+_.call(_.call(i,/([0-9]{3})/g,"$&_"),/_$/,"")}}return _.call(t,r,"$&_")}var T=r(654).custom,L=T&&F(T)?T:null;function D(e,t,r){var n="double"===(r.quoteStyle||t)?'"':"'";return n+e+n}function z(e){return _.call(String(e),/"/g,""")}function B(e){return!("[object Array]"!==q(e)||I&&"object"==typeof e&&I in e)}function F(e){if(R)return e&&"object"==typeof e&&e instanceof Symbol;if("symbol"==typeof e)return!0;if(!e||"object"!=typeof e||!x)return!1;try{return x.call(e),!0}catch(e){}return!1}e.exports=function e(t,r,n,o){var u=r||{};if(H(u,"quoteStyle")&&"single"!==u.quoteStyle&&"double"!==u.quoteStyle)throw new TypeError('option "quoteStyle" must be "single" or "double"');if(H(u,"maxStringLength")&&("number"==typeof u.maxStringLength?u.maxStringLength<0&&u.maxStringLength!==1/0:null!==u.maxStringLength))throw new TypeError('option "maxStringLength", if provided, must be a positive integer, Infinity, or `null`');var s=!H(u,"customInspect")||u.customInspect;if("boolean"!=typeof s&&"symbol"!==s)throw new TypeError("option \"customInspect\", if provided, must be `true`, `false`, or `'symbol'`");if(H(u,"indent")&&null!==u.indent&&"\t"!==u.indent&&!(parseInt(u.indent,10)===u.indent&&u.indent>0))throw new TypeError('option "indent" must be "\\t", an integer > 0, or `null`');if(H(u,"numericSeparator")&&"boolean"!=typeof u.numericSeparator)throw new TypeError('option "numericSeparator", if provided, must be `true` or `false`');var y=u.numericSeparator;if(void 0===t)return"undefined";if(null===t)return"null";if("boolean"==typeof t)return t?"true":"false";if("string"==typeof t)return V(t,u);if("number"==typeof t){if(0===t)return 1/0/t>0?"0":"-0";var b=String(t);return y?N(t,b):b}if("bigint"==typeof t){var w=String(t)+"n";return y?N(t,w):w}var j=void 0===u.depth?5:u.depth;if(void 0===n&&(n=0),n>=j&&j>0&&"object"==typeof t)return B(t)?"[Array]":"[Object]";var A,T=function(e,t){var r;if("\t"===e.indent)r="\t";else{if(!("number"==typeof e.indent&&e.indent>0))return null;r=P.call(Array(e.indent+1)," ")}return{base:r,prev:P.call(Array(t+1),r)}}(u,n);if(void 0===o)o=[];else if(Q(o,t)>=0)return"[Circular]";function U(t,r,i){if(r&&(o=E.call(o)).push(r),i){var a={depth:u.depth};return H(u,"quoteStyle")&&(a.quoteStyle=u.quoteStyle),e(t,a,n+1,o)}return e(t,u,n+1,o)}if("function"==typeof t){var J=function(e){if(e.name)return e.name;var t=g.call(v.call(e),/^function\s*([\w$]+)/);return t?t[1]:null}(t),X=Z(t,U);return"[Function"+(J?": "+J:" (anonymous)")+"]"+(X.length>0?" { "+P.call(X,", ")+" }":"")}if(F(t)){var $=R?_.call(String(t),/^(Symbol\(.*\))_[^)]*$/,"$1"):x.call(t);return"object"!=typeof t||R?$:G($)}if((A=t)&&"object"==typeof A&&("undefined"!=typeof HTMLElement&&A instanceof HTMLElement||"string"==typeof A.nodeName&&"function"==typeof A.getAttribute)){for(var ee="<"+O.call(String(t.nodeName)),te=t.attributes||[],re=0;re<te.length;re++)ee+=" "+te[re].name+"="+D(z(te[re].value),"double",u);return ee+=">",t.childNodes&&t.childNodes.length&&(ee+="..."),ee+"</"+O.call(String(t.nodeName))+">"}if(B(t)){if(0===t.length)return"[]";var ne=Z(t,U);return T&&!function(e){for(var t=0;t<e.length;t++)if(Q(e[t],"\n")>=0)return!1;return!0}(ne)?"["+Y(ne,T)+"]":"[ "+P.call(ne,", ")+" ]"}if(function(e){return!("[object Error]"!==q(e)||I&&"object"==typeof e&&I in e)}(t)){var oe=Z(t,U);return"cause"in t&&!C.call(t,"cause")?"{ ["+String(t)+"] "+P.call(S.call("[cause]: "+U(t.cause),oe),", ")+" }":0===oe.length?"["+String(t)+"]":"{ ["+String(t)+"] "+P.call(oe,", ")+" }"}if("object"==typeof t&&s){if(L&&"function"==typeof t[L])return t[L]();if("symbol"!==s&&"function"==typeof t.inspect)return t.inspect()}if(function(e){if(!i||!e||"object"!=typeof e)return!1;try{i.call(e);try{l.call(e)}catch(e){return!0}return e instanceof Map}catch(e){}return!1}(t)){var ie=[];return a.call(t,(function(e,r){ie.push(U(r,t,!0)+" => "+U(e,t))})),W("Map",i.call(t),ie,T)}if(function(e){if(!l||!e||"object"!=typeof e)return!1;try{l.call(e);try{i.call(e)}catch(e){return!0}return e instanceof Set}catch(e){}return!1}(t)){var ae=[];return c.call(t,(function(e){ae.push(U(e,t))})),W("Set",l.call(t),ae,T)}if(function(e){if(!f||!e||"object"!=typeof e)return!1;try{f.call(e,f);try{d.call(e,d)}catch(e){return!0}return e instanceof WeakMap}catch(e){}return!1}(t))return K("WeakMap");if(function(e){if(!d||!e||"object"!=typeof e)return!1;try{d.call(e,d);try{f.call(e,f)}catch(e){return!0}return e instanceof WeakSet}catch(e){}return!1}(t))return K("WeakSet");if(function(e){if(!p||!e||"object"!=typeof e)return!1;try{return p.call(e),!0}catch(e){}return!1}(t))return K("WeakRef");if(function(e){return!("[object Number]"!==q(e)||I&&"object"==typeof e&&I in e)}(t))return G(U(Number(t)));if(function(e){if(!e||"object"!=typeof e||!k)return!1;try{return k.call(e),!0}catch(e){}return!1}(t))return G(U(k.call(t)));if(function(e){return!("[object Boolean]"!==q(e)||I&&"object"==typeof e&&I in e)}(t))return G(h.call(t));if(function(e){return!("[object String]"!==q(e)||I&&"object"==typeof e&&I in e)}(t))return G(U(String(t)));if(!function(e){return!("[object Date]"!==q(e)||I&&"object"==typeof e&&I in e)}(t)&&!function(e){return!("[object RegExp]"!==q(e)||I&&"object"==typeof e&&I in e)}(t)){var ue=Z(t,U),se=M?M(t)===Object.prototype:t instanceof Object||t.constructor===Object,le=t instanceof Object?"":"null prototype",ce=!se&&I&&Object(t)===t&&I in t?m.call(q(t),8,-1):le?"Object":"",fe=(se||"function"!=typeof t.constructor?"":t.constructor.name?t.constructor.name+" ":"")+(ce||le?"["+P.call(S.call([],ce||[],le||[]),": ")+"] ":"");return 0===ue.length?fe+"{}":T?fe+"{"+Y(ue,T)+"}":fe+"{ "+P.call(ue,", ")+" }"}return String(t)};var U=Object.prototype.hasOwnProperty||function(e){return e in this};function H(e,t){return U.call(e,t)}function q(e){return y.call(e)}function Q(e,t){if(e.indexOf)return e.indexOf(t);for(var r=0,n=e.length;r<n;r++)if(e[r]===t)return r;return-1}function V(e,t){if(e.length>t.maxStringLength){var r=e.length-t.maxStringLength,n="... "+r+" more character"+(r>1?"s":"");return V(m.call(e,0,t.maxStringLength),t)+n}return D(_.call(_.call(e,/(['\\])/g,"\\$1"),/[\x00-\x1f]/g,J),"single",t)}function J(e){var t=e.charCodeAt(0),r={8:"b",9:"t",10:"n",12:"f",13:"r"}[t];return r?"\\"+r:"\\x"+(t<16?"0":"")+b.call(t.toString(16))}function G(e){return"Object("+e+")"}function K(e){return e+" { ? }"}function W(e,t,r,n){return e+" ("+t+") {"+(n?Y(r,n):P.call(r,", "))+"}"}function Y(e,t){if(0===e.length)return"";var r="\n"+t.prev+t.base;return r+P.call(e,","+r)+"\n"+t.prev}function Z(e,t){var r=B(e),n=[];if(r){n.length=e.length;for(var o=0;o<e.length;o++)n[o]=H(e,o)?t(e[o],e):""}var i,a="function"==typeof A?A(e):[];if(R){i={};for(var u=0;u<a.length;u++)i["$"+a[u]]=a[u]}for(var s in e)H(e,s)&&(r&&String(Number(s))===s&&s<e.length||R&&i["$"+s]instanceof Symbol||(w.call(/[^\w$]/,s)?n.push(t(s,e)+": "+t(e[s],e)):n.push(s+": "+t(e[s],e))));if("function"==typeof A)for(var l=0;l<a.length;l++)C.call(e,a[l])&&n.push("["+t(a[l])+"]: "+t(e[a[l]],e));return n}},798:e=>{"use strict";var t=String.prototype.replace,r=/%20/g,n="RFC3986";e.exports={default:n,formatters:{RFC1738:function(e){return t.call(e,r,"+")},RFC3986:function(e){return String(e)}},RFC1738:"RFC1738",RFC3986:n}},129:(e,t,r)=>{"use strict";var n=r(261),o=r(235),i=r(798);e.exports={formats:i,parse:o,stringify:n}},235:(e,t,r)=>{"use strict";var n=r(769),o=Object.prototype.hasOwnProperty,i=Array.isArray,a={allowDots:!1,allowPrototypes:!1,allowSparse:!1,arrayLimit:20,charset:"utf-8",charsetSentinel:!1,comma:!1,decoder:n.decode,delimiter:"&",depth:5,ignoreQueryPrefix:!1,interpretNumericEntities:!1,parameterLimit:1e3,parseArrays:!0,plainObjects:!1,strictNullHandling:!1},u=function(e){return e.replace(/&#(\d+);/g,(function(e,t){return String.fromCharCode(parseInt(t,10))}))},s=function(e,t){return e&&"string"==typeof e&&t.comma&&e.indexOf(",")>-1?e.split(","):e},l=function(e,t,r,n){if(e){var i=r.allowDots?e.replace(/\.([^.[]+)/g,"[$1]"):e,a=/(\[[^[\]]*])/g,u=r.depth>0&&/(\[[^[\]]*])/.exec(i),l=u?i.slice(0,u.index):i,c=[];if(l){if(!r.plainObjects&&o.call(Object.prototype,l)&&!r.allowPrototypes)return;c.push(l)}for(var f=0;r.depth>0&&null!==(u=a.exec(i))&&f<r.depth;){if(f+=1,!r.plainObjects&&o.call(Object.prototype,u[1].slice(1,-1))&&!r.allowPrototypes)return;c.push(u[1])}return u&&c.push("["+i.slice(u.index)+"]"),function(e,t,r,n){for(var o=n?t:s(t,r),i=e.length-1;i>=0;--i){var a,u=e[i];if("[]"===u&&r.parseArrays)a=[].concat(o);else{a=r.plainObjects?Object.create(null):{};var l="["===u.charAt(0)&&"]"===u.charAt(u.length-1)?u.slice(1,-1):u,c=parseInt(l,10);r.parseArrays||""!==l?!isNaN(c)&&u!==l&&String(c)===l&&c>=0&&r.parseArrays&&c<=r.arrayLimit?(a=[])[c]=o:"__proto__"!==l&&(a[l]=o):a={0:o}}o=a}return o}(c,t,r,n)}};e.exports=function(e,t){var r=function(e){if(!e)return a;if(null!==e.decoder&&void 0!==e.decoder&&"function"!=typeof e.decoder)throw new TypeError("Decoder has to be a function.");if(void 0!==e.charset&&"utf-8"!==e.charset&&"iso-8859-1"!==e.charset)throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");var t=void 0===e.charset?a.charset:e.charset;return{allowDots:void 0===e.allowDots?a.allowDots:!!e.allowDots,allowPrototypes:"boolean"==typeof e.allowPrototypes?e.allowPrototypes:a.allowPrototypes,allowSparse:"boolean"==typeof e.allowSparse?e.allowSparse:a.allowSparse,arrayLimit:"number"==typeof e.arrayLimit?e.arrayLimit:a.arrayLimit,charset:t,charsetSentinel:"boolean"==typeof e.charsetSentinel?e.charsetSentinel:a.charsetSentinel,comma:"boolean"==typeof e.comma?e.comma:a.comma,decoder:"function"==typeof e.decoder?e.decoder:a.decoder,delimiter:"string"==typeof e.delimiter||n.isRegExp(e.delimiter)?e.delimiter:a.delimiter,depth:"number"==typeof e.depth||!1===e.depth?+e.depth:a.depth,ignoreQueryPrefix:!0===e.ignoreQueryPrefix,interpretNumericEntities:"boolean"==typeof e.interpretNumericEntities?e.interpretNumericEntities:a.interpretNumericEntities,parameterLimit:"number"==typeof e.parameterLimit?e.parameterLimit:a.parameterLimit,parseArrays:!1!==e.parseArrays,plainObjects:"boolean"==typeof e.plainObjects?e.plainObjects:a.plainObjects,strictNullHandling:"boolean"==typeof e.strictNullHandling?e.strictNullHandling:a.strictNullHandling}}(t);if(""===e||null==e)return r.plainObjects?Object.create(null):{};for(var c="string"==typeof e?function(e,t){var r,l={},c=t.ignoreQueryPrefix?e.replace(/^\?/,""):e,f=t.parameterLimit===1/0?void 0:t.parameterLimit,d=c.split(t.delimiter,f),p=-1,h=t.charset;if(t.charsetSentinel)for(r=0;r<d.length;++r)0===d[r].indexOf("utf8=")&&("utf8=%E2%9C%93"===d[r]?h="utf-8":"utf8=%26%2310003%3B"===d[r]&&(h="iso-8859-1"),p=r,r=d.length);for(r=0;r<d.length;++r)if(r!==p){var y,v,g=d[r],m=g.indexOf("]="),_=-1===m?g.indexOf("="):m+1;-1===_?(y=t.decoder(g,a.decoder,h,"key"),v=t.strictNullHandling?null:""):(y=t.decoder(g.slice(0,_),a.decoder,h,"key"),v=n.maybeMap(s(g.slice(_+1),t),(function(e){return t.decoder(e,a.decoder,h,"value")}))),v&&t.interpretNumericEntities&&"iso-8859-1"===h&&(v=u(v)),g.indexOf("[]=")>-1&&(v=i(v)?[v]:v),o.call(l,y)?l[y]=n.combine(l[y],v):l[y]=v}return l}(e,r):e,f=r.plainObjects?Object.create(null):{},d=Object.keys(c),p=0;p<d.length;++p){var h=d[p],y=l(h,c[h],r,"string"==typeof e);f=n.merge(f,y,r)}return!0===r.allowSparse?f:n.compact(f)}},261:(e,t,r)=>{"use strict";var n=r(478),o=r(769),i=r(798),a=Object.prototype.hasOwnProperty,u={brackets:function(e){return e+"[]"},comma:"comma",indices:function(e,t){return e+"["+t+"]"},repeat:function(e){return e}},s=Array.isArray,l=String.prototype.split,c=Array.prototype.push,f=function(e,t){c.apply(e,s(t)?t:[t])},d=Date.prototype.toISOString,p=i.default,h={addQueryPrefix:!1,allowDots:!1,charset:"utf-8",charsetSentinel:!1,delimiter:"&",encode:!0,encoder:o.encode,encodeValuesOnly:!1,format:p,formatter:i.formatters[p],indices:!1,serializeDate:function(e){return d.call(e)},skipNulls:!1,strictNullHandling:!1},y={},v=function e(t,r,i,a,u,c,d,p,v,g,m,_,b,O,w){for(var S,P=t,E=w,j=0,k=!1;void 0!==(E=E.get(y))&&!k;){var A=E.get(t);if(j+=1,void 0!==A){if(A===j)throw new RangeError("Cyclic object value");k=!0}void 0===E.get(y)&&(j=0)}if("function"==typeof d?P=d(r,P):P instanceof Date?P=g(P):"comma"===i&&s(P)&&(P=o.maybeMap(P,(function(e){return e instanceof Date?g(e):e}))),null===P){if(a)return c&&!b?c(r,h.encoder,O,"key",m):r;P=""}if("string"==typeof(S=P)||"number"==typeof S||"boolean"==typeof S||"symbol"==typeof S||"bigint"==typeof S||o.isBuffer(P)){if(c){var x=b?r:c(r,h.encoder,O,"key",m);if("comma"===i&&b){for(var R=l.call(String(P),","),I="",C=0;C<R.length;++C)I+=(0===C?"":",")+_(c(R[C],h.encoder,O,"value",m));return[_(x)+"="+I]}return[_(x)+"="+_(c(P,h.encoder,O,"value",m))]}return[_(r)+"="+_(String(P))]}var M,N=[];if(void 0===P)return N;if("comma"===i&&s(P))M=[{value:P.length>0?P.join(",")||null:void 0}];else if(s(d))M=d;else{var T=Object.keys(P);M=p?T.sort(p):T}for(var L=0;L<M.length;++L){var D=M[L],z="object"==typeof D&&void 0!==D.value?D.value:P[D];if(!u||null!==z){var B=s(P)?"function"==typeof i?i(r,D):r:r+(v?"."+D:"["+D+"]");w.set(t,j);var F=n();F.set(y,w),f(N,e(z,B,i,a,u,c,d,p,v,g,m,_,b,O,F))}}return N};e.exports=function(e,t){var r,o=e,l=function(e){if(!e)return h;if(null!==e.encoder&&void 0!==e.encoder&&"function"!=typeof e.encoder)throw new TypeError("Encoder has to be a function.");var t=e.charset||h.charset;if(void 0!==e.charset&&"utf-8"!==e.charset&&"iso-8859-1"!==e.charset)throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");var r=i.default;if(void 0!==e.format){if(!a.call(i.formatters,e.format))throw new TypeError("Unknown format option provided.");r=e.format}var n=i.formatters[r],o=h.filter;return("function"==typeof e.filter||s(e.filter))&&(o=e.filter),{addQueryPrefix:"boolean"==typeof e.addQueryPrefix?e.addQueryPrefix:h.addQueryPrefix,allowDots:void 0===e.allowDots?h.allowDots:!!e.allowDots,charset:t,charsetSentinel:"boolean"==typeof e.charsetSentinel?e.charsetSentinel:h.charsetSentinel,delimiter:void 0===e.delimiter?h.delimiter:e.delimiter,encode:"boolean"==typeof e.encode?e.encode:h.encode,encoder:"function"==typeof e.encoder?e.encoder:h.encoder,encodeValuesOnly:"boolean"==typeof e.encodeValuesOnly?e.encodeValuesOnly:h.encodeValuesOnly,filter:o,format:r,formatter:n,serializeDate:"function"==typeof e.serializeDate?e.serializeDate:h.serializeDate,skipNulls:"boolean"==typeof e.skipNulls?e.skipNulls:h.skipNulls,sort:"function"==typeof e.sort?e.sort:null,strictNullHandling:"boolean"==typeof e.strictNullHandling?e.strictNullHandling:h.strictNullHandling}}(t);"function"==typeof l.filter?o=(0,l.filter)("",o):s(l.filter)&&(r=l.filter);var c,d=[];if("object"!=typeof o||null===o)return"";c=t&&t.arrayFormat in u?t.arrayFormat:t&&"indices"in t?t.indices?"indices":"repeat":"indices";var p=u[c];r||(r=Object.keys(o)),l.sort&&r.sort(l.sort);for(var y=n(),g=0;g<r.length;++g){var m=r[g];l.skipNulls&&null===o[m]||f(d,v(o[m],m,p,l.strictNullHandling,l.skipNulls,l.encode?l.encoder:null,l.filter,l.sort,l.allowDots,l.serializeDate,l.format,l.formatter,l.encodeValuesOnly,l.charset,y))}var _=d.join(l.delimiter),b=!0===l.addQueryPrefix?"?":"";return l.charsetSentinel&&("iso-8859-1"===l.charset?b+="utf8=%26%2310003%3B&":b+="utf8=%E2%9C%93&"),_.length>0?b+_:""}},769:(e,t,r)=>{"use strict";var n=r(798),o=Object.prototype.hasOwnProperty,i=Array.isArray,a=function(){for(var e=[],t=0;t<256;++t)e.push("%"+((t<16?"0":"")+t.toString(16)).toUpperCase());return e}(),u=function(e,t){for(var r=t&&t.plainObjects?Object.create(null):{},n=0;n<e.length;++n)void 0!==e[n]&&(r[n]=e[n]);return r};e.exports={arrayToObject:u,assign:function(e,t){return Object.keys(t).reduce((function(e,r){return e[r]=t[r],e}),e)},combine:function(e,t){return[].concat(e,t)},compact:function(e){for(var t=[{obj:{o:e},prop:"o"}],r=[],n=0;n<t.length;++n)for(var o=t[n],a=o.obj[o.prop],u=Object.keys(a),s=0;s<u.length;++s){var l=u[s],c=a[l];"object"==typeof c&&null!==c&&-1===r.indexOf(c)&&(t.push({obj:a,prop:l}),r.push(c))}return function(e){for(;e.length>1;){var t=e.pop(),r=t.obj[t.prop];if(i(r)){for(var n=[],o=0;o<r.length;++o)void 0!==r[o]&&n.push(r[o]);t.obj[t.prop]=n}}}(t),e},decode:function(e,t,r){var n=e.replace(/\+/g," ");if("iso-8859-1"===r)return n.replace(/%[0-9a-f]{2}/gi,unescape);try{return decodeURIComponent(n)}catch(e){return n}},encode:function(e,t,r,o,i){if(0===e.length)return e;var u=e;if("symbol"==typeof e?u=Symbol.prototype.toString.call(e):"string"!=typeof e&&(u=String(e)),"iso-8859-1"===r)return escape(u).replace(/%u[0-9a-f]{4}/gi,(function(e){return"%26%23"+parseInt(e.slice(2),16)+"%3B"}));for(var s="",l=0;l<u.length;++l){var c=u.charCodeAt(l);45===c||46===c||95===c||126===c||c>=48&&c<=57||c>=65&&c<=90||c>=97&&c<=122||i===n.RFC1738&&(40===c||41===c)?s+=u.charAt(l):c<128?s+=a[c]:c<2048?s+=a[192|c>>6]+a[128|63&c]:c<55296||c>=57344?s+=a[224|c>>12]+a[128|c>>6&63]+a[128|63&c]:(l+=1,c=65536+((1023&c)<<10|1023&u.charCodeAt(l)),s+=a[240|c>>18]+a[128|c>>12&63]+a[128|c>>6&63]+a[128|63&c])}return s},isBuffer:function(e){return!(!e||"object"!=typeof e||!(e.constructor&&e.constructor.isBuffer&&e.constructor.isBuffer(e)))},isRegExp:function(e){return"[object RegExp]"===Object.prototype.toString.call(e)},maybeMap:function(e,t){if(i(e)){for(var r=[],n=0;n<e.length;n+=1)r.push(t(e[n]));return r}return t(e)},merge:function e(t,r,n){if(!r)return t;if("object"!=typeof r){if(i(t))t.push(r);else{if(!t||"object"!=typeof t)return[t,r];(n&&(n.plainObjects||n.allowPrototypes)||!o.call(Object.prototype,r))&&(t[r]=!0)}return t}if(!t||"object"!=typeof t)return[t].concat(r);var a=t;return i(t)&&!i(r)&&(a=u(t,n)),i(t)&&i(r)?(r.forEach((function(r,i){if(o.call(t,i)){var a=t[i];a&&"object"==typeof a&&r&&"object"==typeof r?t[i]=e(a,r,n):t.push(r)}else t[i]=r})),t):Object.keys(r).reduce((function(t,i){var a=r[i];return o.call(t,i)?t[i]=e(t[i],a,n):t[i]=a,t}),a)}}},478:(e,t,r)=>{"use strict";var n=r(210),o=r(924),i=r(631),a=n("%TypeError%"),u=n("%WeakMap%",!0),s=n("%Map%",!0),l=o("WeakMap.prototype.get",!0),c=o("WeakMap.prototype.set",!0),f=o("WeakMap.prototype.has",!0),d=o("Map.prototype.get",!0),p=o("Map.prototype.set",!0),h=o("Map.prototype.has",!0),y=function(e,t){for(var r,n=e;null!==(r=n.next);n=r)if(r.key===t)return n.next=r.next,r.next=e.next,e.next=r,r};e.exports=function(){var e,t,r,n={assert:function(e){if(!n.has(e))throw new a("Side channel does not contain "+i(e))},get:function(n){if(u&&n&&("object"==typeof n||"function"==typeof n)){if(e)return l(e,n)}else if(s){if(t)return d(t,n)}else if(r)return function(e,t){var r=y(e,t);return r&&r.value}(r,n)},has:function(n){if(u&&n&&("object"==typeof n||"function"==typeof n)){if(e)return f(e,n)}else if(s){if(t)return h(t,n)}else if(r)return function(e,t){return!!y(e,t)}(r,n);return!1},set:function(n,o){u&&n&&("object"==typeof n||"function"==typeof n)?(e||(e=new u),c(e,n,o)):s?(t||(t=new s),p(t,n,o)):(r||(r={key:{},next:null}),function(e,t,r){var n=y(e,t);n?n.value=r:e.next={key:t,next:e.next,value:r}}(r,n,o))}};return n}},136:e=>{"use strict";e.exports=require("react")},654:()=>{}},t={};function r(n){var o=t[n];if(void 0!==o)return o.exports;var i=t[n]={exports:{}};return e[n].call(i.exports,i,i.exports,r),i.exports}r.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return r.d(t,{a:t}),t},r.d=(e,t)=>{for(var n in t)r.o(t,n)&&!r.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},r.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var n={};(()=>{"use strict";r.r(n),r.d(n,{AuthCallback:()=>q,AuthContext:()=>M,AuthFlow:()=>R,AuthProvider:()=>N,AuthRefreshTokenError:()=>A,AuthService:()=>C,DEFAULT_IDENTITY_PROVIDER:()=>h,Privileges:()=>m,Protected:()=>D,ProtectedContentContext:()=>T,ProtectedContentProvider:()=>L,TenantIds:()=>_,getIdentityProviderFromHostname:()=>g,userHasAccess:()=>b});var e=r(129),t=r.n(e),o=r(136),i=r.n(o);const a=require("react-router-dom");function u(e,t,r,n){return new(r||(r=Promise))((function(o,i){function a(e){try{s(n.next(e))}catch(e){i(e)}}function u(e){try{s(n.throw(e))}catch(e){i(e)}}function s(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,u)}s((n=n.apply(e,t||[])).next())}))}Object.create,Object.create;var s=r(187),l=r.n(s);function c(e){this.message=e}c.prototype=new Error,c.prototype.name="InvalidCharacterError";var f="undefined"!=typeof window&&window.atob&&window.atob.bind(window)||function(e){var t=String(e).replace(/=+$/,"");if(t.length%4==1)throw new c("'atob' failed: The string to be decoded is not correctly encoded.");for(var r,n,o=0,i=0,a="";n=t.charAt(i++);~n&&(r=o%4?64*r+n:n,o++%4)?a+=String.fromCharCode(255&r>>(-2*o&6)):0)n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".indexOf(n);return a};function d(e){var t=e.replace(/-/g,"+").replace(/_/g,"/");switch(t.length%4){case 0:break;case 2:t+="==";break;case 3:t+="=";break;default:throw"Illegal base64url string!"}try{return function(e){return decodeURIComponent(f(e).replace(/(.)/g,(function(e,t){var r=t.charCodeAt(0).toString(16).toUpperCase();return r.length<2&&(r="0"+r),"%"+r})))}(t)}catch(e){return f(t)}}function p(e){this.message=e}p.prototype=new Error,p.prototype.name="InvalidTokenError";const h="default",y=/^(.+)\..+\.touchtech\.com$/,v=/^(.+)\.localhost$/;function g(e){var t;const r=e.toLowerCase(),n=null!==(t=r.match(y))&&void 0!==t?t:r.match(v);return null!==n?n[1]:h}class m{}m.UNIVERSAL="universal",m.SHOWROOM_APP="showroom-app",m.SENDOUTS_APP="sendouts-app",m.SENDOUTS_CMS_APP="sendouts-cms-app",m.MARKETING_ENGINE_APP="marketing-engine-app",m.USER_MANAGEMENT_APP="user-management-app";class _{}function b(e,t,r){for(const n of e.roles)if(n===`${t}:${r}`||n===`${t}:${m.UNIVERSAL}`||n===`${_.UNIVERSAL}:${r}`||n===`${_.UNIVERSAL}:${m.UNIVERSAL}`)return!0;return!1}_.UNIVERSAL="10000001-c001-0001-0001-000000000000";var O=r(865),w=r(438),S=r(960),P=r(373),E=r(892),j=r(551),k=r(298);class A extends Error{constructor(e="Refresh token error"){super(e)}}class x extends O.BasicQueryStringUtils{parse(e){return super.parse(e,!1)}}class R extends s.EventEmitter{constructor(e){super(),this._configuration=e,this._notifier=new S.AuthorizationNotifier,this._authorizationHandler=new O.RedirectRequestHandler(new O.LocalStorageBackend,new x),this._tokenHandler=new j.BaseTokenRequestHandler(R.s_requestor),this._authorizationHandler.setAuthorizationNotifier(this._notifier),this._notifier.setAuthorizationListener(this.authorizationListener.bind(this)),window.addEventListener("storage",this.handleStorage.bind(this))}initialize(){this.loadState(),this.loadSignOutState()}authorizationListener(e,t,r){var n;return u(this,void 0,void 0,(function*(){console.debug("Authorization request complete",e,t,r);const o=null!==(n=null==t?void 0:t.state)&&void 0!==n?n:null==r?void 0:r.state,i=JSON.parse(window.atob(o));if(this.emit("authorizationComplete",{request:e,response:t,error:r,state:i}),t){let r;e.internal&&e.internal.code_verifier&&(r=e.internal.code_verifier),yield this.makeTokenRequest(t.code,r),this.emit("tokenResponse")}}))}signIn({identityProvider:e,force:t=!1,state:r}){return u(this,void 0,void 0,(function*(){this.isSignedIn()?t&&(this.signOutCore(),yield this.makeAuthorizationRequest(e,r)):yield this.makeAuthorizationRequest(e,r)}))}completeSignInIfPossible(){return u(this,void 0,void 0,(function*(){try{yield this._authorizationHandler.completeAuthorizationRequestIfPossible()}finally{window.localStorage.removeItem("appauth_current_authorization_request"),Object.keys(window.localStorage).filter((e=>e.includes("appauth_authorization"))).forEach((e=>{window.localStorage.removeItem(e)}))}}))}isSignedIn(){return!!this._tokenResponse&&this._tokenResponse.isValid(R.AUTH_EXPIRY_BUFFER)}getAccessToken(e=!1,t=0){var r,n;return u(this,void 0,void 0,(function*(){if(!e&&this._tokenResponse&&this._tokenResponse.isValid(R.AUTH_EXPIRY_BUFFER))return this._tokenResponse.accessToken;if(e&&t>0&&void 0!==(null===(r=this._tokenResponse)||void 0===r?void 0:r.issuedAt)&&!((new Date).getTime()/1e3-this._tokenResponse.issuedAt>t))return this._tokenResponse.accessToken;if(this._refreshTokenPromise)return yield this._refreshTokenPromise;{if(void 0===(null===(n=this._tokenResponse)||void 0===n?void 0:n.refreshToken))return null;let e;try{this._refreshTokenPromise=this.refreshToken(this._tokenResponse.refreshToken),e=yield this._refreshTokenPromise}finally{this._refreshTokenPromise=void 0}return e}}))}signOut({state:e}){return u(this,void 0,void 0,(function*(){if(!this._tokenResponse)return;const t=this._tokenResponse.idToken;this.signOutCore();const r=yield this.ensureServiceConfiguration(),n=this._configuration.postLogoutRedirectUri;let o=`${r.endSessionEndpoint}?id_token_hint=${t}&post_logout_redirect_uri=${n}`;e&&(o=`${o}&state=${window.btoa(JSON.stringify(e))}`),console.debug(`[AuthFlow] Signing out using post_logout_redirect_uri '${n}' (full endSession URL: '${o}') ...`),window.location.assign(o)}))}signOutCore(){this._tokenResponse=void 0,window.localStorage.removeItem(R.TOKEN_RESPONSE_KEY)}makeAuthorizationRequest(e,t){return u(this,void 0,void 0,(function*(){const r={idp:e},n={returnUri:`${window.location.pathname}${window.location.search}`,signInState:t},o=window.btoa(JSON.stringify(n)),i=new w.AuthorizationRequest({client_id:this._configuration.clientId,redirect_uri:this._configuration.redirectUri,scope:this._configuration.scope,response_type:w.AuthorizationRequest.RESPONSE_TYPE_CODE,state:o,extras:r});this._authorizationHandler.performAuthorizationRequest(yield this.ensureServiceConfiguration(),i)}))}ensureServiceConfiguration(){return u(this,void 0,void 0,(function*(){if(!this._serviceConfiguration){const e=yield P.AuthorizationServiceConfiguration.fetchFromIssuer(this._configuration.openIdIssuerUrl,R.s_requestor);this._serviceConfiguration=e}return this._serviceConfiguration}))}saveState(){this._tokenResponse&&window.localStorage.setItem(R.TOKEN_RESPONSE_KEY,JSON.stringify(this._tokenResponse.toJson()))}loadState(){const e=window.localStorage.getItem(R.TOKEN_RESPONSE_KEY);if(null!=e){const t=JSON.parse(e),r=new k.TokenResponse(t);return this._tokenResponse=r,void this.emit("tokenResponse")}window.localStorage.getItem(R.IS_REFRESHING_TOKEN_KEY)||this.emit("tokenResponseFail")}loadSignOutState(){const{state:e}=t().parse(window.location.search,{ignoreQueryPrefix:!0});if(!e)return;const r=JSON.parse(window.atob(e));this.emit("signOutStateChanged",{state:r})}makeTokenRequest(e,t){return u(this,void 0,void 0,(function*(){const r={};t&&(r.code_verifier=t);const n=new E.TokenRequest({code:e,extras:r,client_id:this._configuration.clientId,redirect_uri:this._configuration.redirectUri,grant_type:E.GRANT_TYPE_AUTHORIZATION_CODE,refresh_token:void 0}),o=yield this._tokenHandler.performTokenRequest(yield this.ensureServiceConfiguration(),n);this._tokenResponse=o,this.saveState()}))}refreshToken(e){return u(this,void 0,void 0,(function*(){console.debug("Refreshing token ..."),this._tokenResponse=void 0,window.localStorage.removeItem(R.TOKEN_RESPONSE_KEY),window.localStorage.setItem(R.IS_REFRESHING_TOKEN_KEY,"true");const t=new E.TokenRequest({client_id:this._configuration.clientId,redirect_uri:this._configuration.redirectUri,grant_type:E.GRANT_TYPE_REFRESH_TOKEN,refresh_token:e,code:void 0,extras:void 0});let r;try{r=yield this._tokenHandler.performTokenRequest(yield this.ensureServiceConfiguration(),t)}catch(e){throw new A(e instanceof Error?e.message:void 0)}finally{window.localStorage.removeItem(R.IS_REFRESHING_TOKEN_KEY)}return this._tokenResponse=r,this.saveState(),console.debug("Refreshed token --\x3e",r),r.accessToken}))}handleStorage(e){e.key===R.TOKEN_RESPONSE_KEY&&null!==e.newValue&&this.loadState()}}R.TOKEN_RESPONSE_KEY="AuthFlow:tokenResponse",R.AUTH_EXPIRY_BUFFER=-600,R.IS_REFRESHING_TOKEN_KEY="AuthFlow:isRefreshingToken",R.s_requestor=new O.FetchRequestor;class I{}I.EMAIL="email",I.GIVEN_NAME="given_name",I.FAMILY_NAME="family_name",I.ROLE="http://schemas.microsoft.com/ws/2008/06/identity/claims/role";class C extends(l()){constructor(e){super(),this._canSignOut=!0,this._isSigningOut=!1,this._isTokenResponseFailed=!1,this._auth=new R(e),this._auth.on("tokenResponse",this.handleTokenResponse.bind(this)).on("authorizationComplete",this.handleAuthorizationComplete.bind(this)).on("tokenResponseFail",this.handleTokenResponseFail.bind(this)).on("signOutStateChanged",this.handleSignOutStateChanged.bind(this)),this._auth.initialize()}static get instance(){if(!C.s_instance)throw new Error("AuthService has not been initialized");return C.s_instance}static initialize(e){if(C.s_instance)throw new Error("AuthService has already been initialized");C.s_instance=new C(e)}static ensureClaimValue(e,t){const r=e[t];if(void 0===r)throw new Error(`Invalid access token. Missing claim '${t}'.`);return r}setUser(e){this._user!==e&&(this._user=e,this.emit("userChanged"))}setSignInState(e){this._signInState!==e&&(this._signInState=e,this.emit("signInStateChanged"))}setSignOutState(e){this._signOutState!==e&&(this._signOutState=e,this.emit("signOutStateChanged"))}setCanSignOut(e){this._canSignOut!==e&&(this._canSignOut=e,this.emit("canSignOutChanged"))}setIsSigningOut(e){this._isSigningOut!==e&&(this._isSigningOut=e,this.emit("isSigningOutChanged"))}handleTokenResponse(){return u(this,void 0,void 0,(function*(){try{this.setUser(yield this.getUser())}catch(e){this.emit("error",e)}}))}handleAuthorizationComplete(e){this.setSignInState(e.state.signInState),this.emit("authorizationComplete",e)}handleTokenResponseFail(){this._isTokenResponseFailed=!0}handleSignOutStateChanged(e){this.setSignOutState(e.state)}getUser(e=!1,t=0){var r;return u(this,void 0,void 0,(function*(){const n=yield this.getAccessTokenPrivate(e,t);if(null===n)return;let o;try{o=function(e,t){if("string"!=typeof e)throw new p("Invalid token specified");var r=!0===(t=t||{}).header?0:1;try{return JSON.parse(d(e.split(".")[r]))}catch(e){throw new p("Invalid token specified: "+e.message)}}(n)}catch(e){const t=e instanceof Error?e:void 0,r=void 0!==t?t.message:e;throw new Error(`Failed to decode access token: ${r}`,{cause:t})}const i=C.ensureClaimValue(o,I.EMAIL),a=C.ensureClaimValue(o,I.GIVEN_NAME),u=C.ensureClaimValue(o,I.FAMILY_NAME),s=null!==(r=o[I.ROLE])&&void 0!==r?r:[];return{email:i,firstName:a,lastName:u,roles:Array.isArray(s)?s:[s]}}))}get user(){return this._user}get signInState(){return this._signInState}get signOutState(){return this._signOutState}get canSignOut(){return this._canSignOut}get isSigningOut(){return this._isSigningOut}get isTokenResponseFailed(){return this._isTokenResponseFailed}signIn({force:e=!1,state:t}={}){return u(this,void 0,void 0,(function*(){try{const r=g(window.location.hostname);console.debug(`[AuthService] Using identity provider '${r}' ...`),yield this._auth.signIn({identityProvider:r,force:e,state:t})}catch(e){this.emit("error",e)}}))}completeSignInIfPossible(){return u(this,void 0,void 0,(function*(){try{yield this._auth.completeSignInIfPossible()}catch(e){this.emit("error",e)}}))}getAccessToken(){return u(this,void 0,void 0,(function*(){return yield this.getAccessTokenPrivate(!1,0)}))}getAccessTokenPrivate(e,t){return u(this,void 0,void 0,(function*(){try{return yield this._auth.getAccessToken(e,t)}catch(e){return this.emit("error",e),null}}))}signOut({state:e}={}){return u(this,void 0,void 0,(function*(){try{this.setCanSignOut(!1),this.setIsSigningOut(!0),yield this._auth.signOut({state:e})}catch(e){this.emit("error",e)}}))}refreshUser(e){return u(this,void 0,void 0,(function*(){try{this.setUser(yield this.getUser(!0,e))}catch(e){this.emit("error",e)}}))}}const M=i().createContext({}),N=({children:e,authService:t,onError:r,onUserIdentified:n})=>{const[a,s]=(0,o.useState)(),[l,c]=(0,o.useState)(t.canSignOut),[f,d]=(0,o.useState)(t.isSigningOut),[p,h]=(0,o.useState)(t.signInState),[y,v]=(0,o.useState)(t.signOutState);(0,o.useEffect)((()=>{function e(){const e=t.user;e&&(s(e),n(e))}e();const o=()=>{e()},i=()=>{h(t.signInState)},a=()=>{v(t.signOutState)},l=e=>u(void 0,void 0,void 0,(function*(){if(e instanceof A)return yield t.signIn();r(e)})),f=()=>{c(t.canSignOut)},p=()=>{d(t.isSigningOut)};return t.on("userChanged",o).on("signInStateChanged",i).on("signOutStateChanged",a).on("error",l).on("canSignOutChanged",f).on("isSigningOutChanged",p),()=>{t.off("userChanged",o).off("signInStateChanged",i).off("signOutStateChanged",a).off("error",l).off("canSignOutChanged",f).off("isSigningOutChanged",p)}}),[t,r,n]);const g=(0,o.useMemo)((()=>({user:a,authService:t,signInState:p,signOutState:y,canSignOut:l,isSigningOut:f})),[t,l,f,p,y,a]);return i().createElement(M.Provider,{value:g},e)},T=i().createContext({}),L=({children:e,tenantId:t,privilege:r,unauthorizedUrl:n})=>{const a=(0,o.useMemo)((()=>({tenantId:t,privilege:r,unauthorizedUrl:n})),[n,r,t]);return i().createElement(T.Provider,{value:a},e)},D=function({skipAuthorization:e,children:r}){const n=(0,a.useLocation)(),{user:i,authService:u}=(0,o.useContext)(M),{tenantId:s,privilege:l,unauthorizedUrl:c}=(0,o.useContext)(T),{state:f}=(0,o.useMemo)((()=>t().parse(n.search,{ignoreQueryPrefix:!0})),[n.search]);return i?e||b(i,s,l)?r:(console.debug("[Protected] User not authorized to access route; navigating to unauthorized path ..."),window.location.assign(c),null):f?(window.location.assign(f),null):u.isTokenResponseFailed?(u.signIn(),null):null};var z=r(20);const B="access_denied",F={general_error:"General error.",invalid_confirmation:"Invalid confirmation.",idp_not_specified:"IDP not provided.",idp_not_recognized:"IDP not recognized.",federation_not_found:"Federation not found.",external_idp_token_fetch:"External IDP token fetch.",external_idp_token_contents:"External IDP token contents.",external_idp_token_fields:"External IDP token fields.",verificator_not_found:"Verificator not found.",no_user_nor_proto_found:"No user nor proto found.",invite_not_recognized:"Invite not recognized.",user_not_created:"User not created."},U={[B]:"Access denied.",account_selection_required:"Account selection required.",consent_required:"Consent required.",interaction_required:"Interaction required.",login_required:"Login required."},H=function({errorMessage:e,navigateTo:t}){const r=(0,a.useNavigate)();return i().createElement("div",{className:"gJiT0wPP9YyRVDsYxWqk"},i().createElement("h1",null,"Sorry, something went wrong."),i().createElement("h3",null,e),i().createElement(z.Button,{onClick:()=>r(t,{replace:!0}),rounded:!0,inverted:!0},"Continue"))},q=function({basename:e}){const t=(0,a.useNavigate)(),{authService:r,user:n}=(0,o.useContext)(M),[{error:u,state:s},l]=(0,o.useState)({error:null,state:null}),c=(0,o.useMemo)((()=>{const t=null==s?void 0:s.returnUri;if(null==t?void 0:t.startsWith(e)){const r=t.substring(e.length);if("?"===r[0])return`/${r}`;if(r.length)return r}return"/"}),[s,e]),f=(0,o.useMemo)((()=>{var e;if(u){const{error:t,errorDescription:r}=u;if(t===B){const e=r;if(void 0!==e){const t=F[e];if(t)return t}}return null!==(e=null!=r?r:U[t])&&void 0!==e?e:`An unknown error occurred. (Error code: '${t}'.)`}}),[u]);return(0,o.useEffect)((()=>{n&&t(c,{replace:!0})}),[t,c,n]),(0,o.useEffect)((()=>{const e=({error:e,state:t})=>{l({error:e,state:t})};return r.on("authorizationComplete",e),r.completeSignInIfPossible(),()=>{r.off("authorizationComplete",e)}}),[r]),i().createElement("div",{className:"C_297mJYGNkE35qpiNZS"},null!=f?i().createElement(H,{errorMessage:f,navigateTo:c}):i().createElement(z.Icon,{src:"data:image/svg+xml,%3c%3fxml version='1.0' encoding='UTF-8' standalone='no'%3f%3e %3c!DOCTYPE svg PUBLIC '-//W3C//DTD SVG 1.1//EN' 'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd'%3e %3csvg width='100%25' height='100%25' viewBox='0 0 46 46' version='1.1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' xml:space='preserve' xmlns:serif='http://www.serif.com/' style='fill-rule:evenodd%3bclip-rule:evenodd%3bstroke-linejoin:round%3bstroke-miterlimit:2%3b'%3e %3cg transform='matrix(1%2c0%2c0%2c1%2c-27%2c-27)'%3e %3cpath d='M73%2c50C73%2c37.3 62.7%2c27 50%2c27C37.3%2c27 27%2c37.3 27%2c50M30.9%2c50C30.9%2c39.5 39.4%2c30.9 50%2c30.9C60.6%2c30.9 69.1%2c39.5 69.1%2c50' style='fill-rule:nonzero%3b'%3e %3canimateTransform attributeName='transform' attributeType='XML' type='rotate' dur='1s' from='0 50 50' to='360 50 50' repeatCount='indefinite' /%3e %3c/path%3e %3c/g%3e %3c/svg%3e",alt:"Icon",size:"xlarge"}))}})();var o=exports;for(var i in n)o[i]=n[i];n.__esModule&&Object.defineProperty(o,"__esModule",{value:!0})})();
|
|
1
|
+
(()=>{var e={438:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AuthorizationRequest=void 0;var n=r(537),o=r(96),i=function(){function e(t,r,o){void 0===r&&(r=new n.DefaultCrypto),void 0===o&&(o=!0),this.crypto=r,this.usePkce=o,this.clientId=t.client_id,this.redirectUri=t.redirect_uri,this.scope=t.scope,this.responseType=t.response_type||e.RESPONSE_TYPE_CODE,this.state=t.state||function(e){return e.generateRandom(10)}(r),this.extras=t.extras,this.internal=t.internal}return e.prototype.setupCodeVerifier=function(){var e=this;if(this.usePkce){var t=this.crypto.generateRandom(128);return this.crypto.deriveChallenge(t).catch((function(e){o.log("Unable to generate PKCE challenge. Not using PKCE",e)})).then((function(r){r&&(e.internal=e.internal||{},e.internal.code_verifier=t,e.extras=e.extras||{},e.extras.code_challenge=r,e.extras.code_challenge_method="S256")}))}return Promise.resolve()},e.prototype.toJson=function(){var e=this;return this.setupCodeVerifier().then((function(){return{response_type:e.responseType,client_id:e.clientId,redirect_uri:e.redirectUri,scope:e.scope,state:e.state,extras:e.extras,internal:e.internal}}))},e.RESPONSE_TYPE_TOKEN="token",e.RESPONSE_TYPE_CODE="code",e}();t.AuthorizationRequest=i},960:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AuthorizationRequestHandler=t.BUILT_IN_PARAMETERS=t.AuthorizationNotifier=void 0;var n=r(96),o=function(){function e(){this.listener=null}return e.prototype.setAuthorizationListener=function(e){this.listener=e},e.prototype.onAuthorizationComplete=function(e,t,r){this.listener&&this.listener(e,t,r)},e}();t.AuthorizationNotifier=o,t.BUILT_IN_PARAMETERS=["redirect_uri","client_id","response_type","state","scope"];var i=function(){function e(e,t){this.utils=e,this.crypto=t,this.notifier=null}return e.prototype.buildRequestUrl=function(e,r){var n={redirect_uri:r.redirectUri,client_id:r.clientId,response_type:r.responseType,state:r.state,scope:r.scope};if(r.extras)for(var o in r.extras)r.extras.hasOwnProperty(o)&&t.BUILT_IN_PARAMETERS.indexOf(o)<0&&(n[o]=r.extras[o]);var i=this.utils.stringify(n);return e.authorizationEndpoint+"?"+i},e.prototype.completeAuthorizationRequestIfPossible=function(){var e=this;return n.log("Checking to see if there is an authorization response to be delivered."),this.notifier||n.log("Notifier is not present on AuthorizationRequest handler.\n No delivery of result will be possible"),this.completeAuthorizationRequest().then((function(t){t||n.log("No result is available yet."),t&&e.notifier&&e.notifier.onAuthorizationComplete(t.request,t.response,t.error)}))},e.prototype.setAuthorizationNotifier=function(e){return this.notifier=e,this},e}();t.AuthorizationRequestHandler=i},208:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AuthorizationError=t.AuthorizationResponse=void 0;var r=function(){function e(e){this.code=e.code,this.state=e.state}return e.prototype.toJson=function(){return{code:this.code,state:this.state}},e}();t.AuthorizationResponse=r;var n=function(){function e(e){this.error=e.error,this.errorDescription=e.error_description,this.errorUri=e.error_uri,this.state=e.state}return e.prototype.toJson=function(){return{error:this.error,error_description:this.errorDescription,error_uri:this.errorUri,state:this.state}},e}();t.AuthorizationError=n},373:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AuthorizationServiceConfiguration=void 0;var n=r(157),o=function(){function e(e){this.authorizationEndpoint=e.authorization_endpoint,this.tokenEndpoint=e.token_endpoint,this.revocationEndpoint=e.revocation_endpoint,this.userInfoEndpoint=e.userinfo_endpoint,this.endSessionEndpoint=e.end_session_endpoint}return e.prototype.toJson=function(){return{authorization_endpoint:this.authorizationEndpoint,token_endpoint:this.tokenEndpoint,revocation_endpoint:this.revocationEndpoint,end_session_endpoint:this.endSessionEndpoint,userinfo_endpoint:this.userInfoEndpoint}},e.fetchFromIssuer=function(t,r){var o=t+"/.well-known/openid-configuration";return(r||new n.JQueryRequestor).xhr({url:o,dataType:"json",method:"GET"}).then((function(t){return new e(t)}))},e}();t.AuthorizationServiceConfiguration=o},537:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.DefaultCrypto=t.textEncodeLite=t.urlSafe=t.bufferToString=void 0;var n=r(742),o=r(3),i="undefined"!=typeof window&&!!window.crypto,s=i&&!!window.crypto.subtle,a="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";function u(e){for(var t=[],r=0;r<e.byteLength;r+=1){var n=e[r]%a.length;t.push(a[n])}return t.join("")}function c(e){return n.fromByteArray(new Uint8Array(e)).replace(/\+/g,"-").replace(/\//g,"_").replace(/=/g,"")}function l(e){for(var t=new ArrayBuffer(e.length),r=new Uint8Array(t),n=0;n<e.length;n++)r[n]=e.charCodeAt(n);return r}t.bufferToString=u,t.urlSafe=c,t.textEncodeLite=l;var p=function(){function e(){}return e.prototype.generateRandom=function(e){var t=new Uint8Array(e);if(i)window.crypto.getRandomValues(t);else for(var r=0;r<e;r+=1)t[r]=Math.random()*a.length|0;return u(t)},e.prototype.deriveChallenge=function(e){return e.length<43||e.length>128?Promise.reject(new o.AppAuthError("Invalid code length.")):s?new Promise((function(t,r){crypto.subtle.digest("SHA-256",l(e)).then((function(e){return t(c(new Uint8Array(e)))}),(function(e){return r(e)}))})):Promise.reject(new o.AppAuthError("window.crypto.subtle is unavailable."))},e}();t.DefaultCrypto=p},3:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AppAuthError=void 0;t.AppAuthError=function(e,t){this.message=e,this.extras=t}},577:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.IS_PROFILE=t.IS_LOG=void 0,t.IS_LOG=!0,t.IS_PROFILE=!1},865:function(e,t,r){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r),Object.defineProperty(e,n,{enumerable:!0,get:function(){return t[r]}})}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r]}),o=this&&this.__exportStar||function(e,t){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(t,r)||n(t,e,r)};Object.defineProperty(t,"__esModule",{value:!0}),o(r(438),t),o(r(960),t),o(r(208),t),o(r(373),t),o(r(537),t),o(r(3),t),o(r(577),t),o(r(96),t),o(r(629),t),o(r(417),t),o(r(33),t),o(r(480),t),o(r(892),t),o(r(551),t),o(r(298),t),o(r(53),t),o(r(157),t)},96:function(e,t,r){"use strict";var n=this&&this.__spreadArray||function(e,t){for(var r=0,n=t.length,o=e.length;r<n;r++,o++)e[o]=t[r];return e};Object.defineProperty(t,"__esModule",{value:!0}),t.profile=t.log=void 0;var o=r(577);function i(e){for(var t=[],r=1;r<arguments.length;r++)t[r-1]=arguments[r];if(o.IS_LOG){var i=t?t.length:0;i>0?console.log.apply(console,n([e],t)):console.log(e)}}t.log=i;var s="undefined"!=typeof window&&!!window.performance&&!!console.profile;t.profile=function(e,t,r){return o.IS_PROFILE?function(e,t,r){var o=r.value,a=o.name;return a||(a="anonymous function"),r.value=s?function(e){console.profile(a);var t=window.performance.now(),r=o.call.apply(o,n([this||window],e)),i=window.performance.now()-t;return console.log(a+" took "+i+" ms"),console.profileEnd(),r}:function(e){i("Profile start "+a);var t=Date.now(),r=o.call.apply(o,n([this||window],e)),s=Date.now()-t;return i("Profile end "+a+" took "+s+" ms."),r},r}(0,0,r):r}},629:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.BasicQueryStringUtils=void 0;var r=function(){function e(){}return e.prototype.parse=function(e,t){return t?this.parseQueryString(e.hash):this.parseQueryString(e.search)},e.prototype.parseQueryString=function(e){for(var t={},r=(e=e.trim().replace(/^(\?|#|&)/,"")).split("&"),n=0;n<r.length;n+=1){var o=r[n].split("=");if(o.length>=2){var i=decodeURIComponent(o.shift()),s=o.length>0?o.join("="):null;s&&(t[i]=decodeURIComponent(s))}}return t},e.prototype.stringify=function(e){var t=[];for(var r in e)e.hasOwnProperty(r)&&e[r]&&t.push(encodeURIComponent(r)+"="+encodeURIComponent(e[r]));return t.join("&")},e}();t.BasicQueryStringUtils=r},417:function(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])},n(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0}),t.RedirectRequestHandler=void 0;var i=r(438),s=r(960),a=r(208),u=r(537),c=r(96),l=r(629),p=r(480),f=function(e){return e+"_appauth_authorization_request"},d=function(e){return e+"_appauth_authorization_service_configuration"},h="appauth_current_authorization_request",y=function(e){function t(t,r,n,o){void 0===t&&(t=new p.LocalStorageBackend),void 0===r&&(r=new l.BasicQueryStringUtils),void 0===n&&(n=window.location),void 0===o&&(o=new u.DefaultCrypto);var i=e.call(this,r,o)||this;return i.storageBackend=t,i.locationLike=n,i}return o(t,e),t.prototype.performAuthorizationRequest=function(e,t){var r=this,n=this.crypto.generateRandom(10);Promise.all([this.storageBackend.setItem(h,n),t.toJson().then((function(e){return r.storageBackend.setItem(f(n),JSON.stringify(e))})),this.storageBackend.setItem(d(n),JSON.stringify(e.toJson()))]).then((function(){var n=r.buildRequestUrl(e,t);c.log("Making a request to ",t,n),r.locationLike.assign(n)}))},t.prototype.completeAuthorizationRequest=function(){var e=this;return this.storageBackend.getItem(h).then((function(t){return t?e.storageBackend.getItem(f(t)).then((function(e){return JSON.parse(e)})).then((function(e){return new i.AuthorizationRequest(e)})).then((function(r){var n=""+e.locationLike.origin+e.locationLike.pathname,o=e.utils.parse(e.locationLike,!0),i=o.state,s=o.code,u=o.error;c.log("Potential authorization request ",n,o,i,s,u);var l=i===r.state,p=null,y=null;if(l){if(u){var g=o.error_uri,v=o.error_description;y=new a.AuthorizationError({error:u,error_description:v,error_uri:g,state:i})}else p=new a.AuthorizationResponse({code:s,state:i});return Promise.all([e.storageBackend.removeItem(h),e.storageBackend.removeItem(f(t)),e.storageBackend.removeItem(d(t))]).then((function(){return c.log("Delivering authorization response"),{request:r,response:p,error:y}}))}return c.log("Mismatched request (state and request_uri) dont match."),Promise.resolve(null)})):null}))},t}(s.AuthorizationRequestHandler);t.RedirectRequestHandler=y},33:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.RevokeTokenRequest=void 0;var r=function(){function e(e){this.token=e.token,this.tokenTypeHint=e.token_type_hint,this.clientId=e.client_id,this.clientSecret=e.client_secret}return e.prototype.toJson=function(){var e={token:this.token};return this.tokenTypeHint&&(e.token_type_hint=this.tokenTypeHint),this.clientId&&(e.client_id=this.clientId),this.clientSecret&&(e.client_secret=this.clientSecret),e},e.prototype.toStringMap=function(){return this.toJson()},e}();t.RevokeTokenRequest=r},480:function(e,t){"use strict";var r,n=this&&this.__extends||(r=function(e,t){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])},r(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0}),t.LocalStorageBackend=t.StorageBackend=void 0;var o=function(){};t.StorageBackend=o;var i=function(e){function t(t){var r=e.call(this)||this;return r.storage=t||window.localStorage,r}return n(t,e),t.prototype.getItem=function(e){var t=this;return new Promise((function(r,n){r(t.storage.getItem(e)||null)}))},t.prototype.removeItem=function(e){var t=this;return new Promise((function(r,n){t.storage.removeItem(e),r()}))},t.prototype.clear=function(){var e=this;return new Promise((function(t,r){e.storage.clear(),t()}))},t.prototype.setItem=function(e,t){var r=this;return new Promise((function(n,o){r.storage.setItem(e,t),n()}))},t}(o);t.LocalStorageBackend=i},892:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TokenRequest=t.GRANT_TYPE_REFRESH_TOKEN=t.GRANT_TYPE_AUTHORIZATION_CODE=void 0,t.GRANT_TYPE_AUTHORIZATION_CODE="authorization_code",t.GRANT_TYPE_REFRESH_TOKEN="refresh_token";var r=function(){function e(e){this.clientId=e.client_id,this.redirectUri=e.redirect_uri,this.grantType=e.grant_type,this.code=e.code,this.refreshToken=e.refresh_token,this.extras=e.extras}return e.prototype.toJson=function(){return{grant_type:this.grantType,code:this.code,refresh_token:this.refreshToken,redirect_uri:this.redirectUri,client_id:this.clientId,extras:this.extras}},e.prototype.toStringMap=function(){var e={grant_type:this.grantType,client_id:this.clientId,redirect_uri:this.redirectUri};if(this.code&&(e.code=this.code),this.refreshToken&&(e.refresh_token=this.refreshToken),this.extras)for(var t in this.extras)this.extras.hasOwnProperty(t)&&!e.hasOwnProperty(t)&&(e[t]=this.extras[t]);return e},e}();t.TokenRequest=r},551:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.BaseTokenRequestHandler=void 0;var n=r(3),o=r(629),i=r(298),s=r(157),a=function(){function e(e,t){void 0===e&&(e=new s.JQueryRequestor),void 0===t&&(t=new o.BasicQueryStringUtils),this.requestor=e,this.utils=t}return e.prototype.isTokenResponse=function(e){return void 0===e.error},e.prototype.performRevokeTokenRequest=function(e,t){return this.requestor.xhr({url:e.revocationEndpoint,method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded"},data:this.utils.stringify(t.toStringMap())}).then((function(e){return!0}))},e.prototype.performTokenRequest=function(e,t){var r=this;return this.requestor.xhr({url:e.tokenEndpoint,method:"POST",dataType:"json",headers:{"Content-Type":"application/x-www-form-urlencoded"},data:this.utils.stringify(t.toStringMap())}).then((function(e){return r.isTokenResponse(e)?new i.TokenResponse(e):Promise.reject(new n.AppAuthError(e.error,new i.TokenError(e)))}))},e}();t.BaseTokenRequestHandler=a},298:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TokenError=t.TokenResponse=t.nowInSeconds=void 0,t.nowInSeconds=function(){return Math.round((new Date).getTime()/1e3)};var r=function(){function e(e){this.accessToken=e.access_token,this.tokenType=e.token_type||"bearer",e.expires_in&&(this.expiresIn=parseInt(e.expires_in,10)),this.refreshToken=e.refresh_token,this.scope=e.scope,this.idToken=e.id_token,this.issuedAt=e.issued_at||t.nowInSeconds()}return e.prototype.toJson=function(){var e;return{access_token:this.accessToken,id_token:this.idToken,refresh_token:this.refreshToken,scope:this.scope,token_type:this.tokenType,issued_at:this.issuedAt,expires_in:null===(e=this.expiresIn)||void 0===e?void 0:e.toString()}},e.prototype.isValid=function(e){return void 0===e&&(e=-600),!this.expiresIn||t.nowInSeconds()<this.issuedAt+this.expiresIn+e},e}();t.TokenResponse=r;var n=function(){function e(e){this.error=e.error,this.errorDescription=e.error_description,this.errorUri=e.error_uri}return e.prototype.toJson=function(){return{error:this.error,error_description:this.errorDescription,error_uri:this.errorUri}},e}();t.TokenError=n},53:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0})},157:function(e,t,r){"use strict";var n,o=this&&this.__extends||(n=function(e,t){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])},n(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(t,"__esModule",{value:!0}),t.TestRequestor=t.FetchRequestor=t.JQueryRequestor=t.Requestor=void 0;var i=r(3),s=function(){};t.Requestor=s;var a=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return o(t,e),t.prototype.xhr=function(e){var t=$.ajax(e);return new Promise((function(e,r){t.then((function(t,r,n){e(t)}),(function(e,t,n){r(new i.AppAuthError(n))}))}))},t}(s);t.JQueryRequestor=a;var u=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return o(t,e),t.prototype.xhr=function(e){if(!e.url)return Promise.reject(new i.AppAuthError("A URL must be provided."));var t=new URL(e.url),r={};if(r.method=e.method,r.mode="cors",e.data&&(e.method&&"POST"===e.method.toUpperCase()?r.body=e.data:new URLSearchParams(e.data).forEach((function(e,r){t.searchParams.append(r,e)}))),r.headers={},e.headers)for(var n in e.headers)e.headers.hasOwnProperty(n)&&(r.headers[n]=e.headers[n]);var o=e.dataType&&"json"===e.dataType.toLowerCase();return o&&(r.headers.Accept="application/json, text/javascript, */*; q=0.01"),fetch(t.toString(),r).then((function(e){if(e.status>=200&&e.status<300){var t=e.headers.get("content-type");return o||t&&-1!==t.indexOf("application/json")?e.json():e.text()}return Promise.reject(new i.AppAuthError(e.status.toString(),e.statusText))}))},t}(s);t.FetchRequestor=u;var c=function(e){function t(t){var r=e.call(this)||this;return r.promise=t,r}return o(t,e),t.prototype.xhr=function(e){return this.promise},t}(s);t.TestRequestor=c},742:(e,t)=>{"use strict";t.byteLength=function(e){var t=u(e),r=t[0],n=t[1];return 3*(r+n)/4-n},t.toByteArray=function(e){var t,r,i=u(e),s=i[0],a=i[1],c=new o(function(e,t,r){return 3*(t+r)/4-r}(0,s,a)),l=0,p=a>0?s-4:s;for(r=0;r<p;r+=4)t=n[e.charCodeAt(r)]<<18|n[e.charCodeAt(r+1)]<<12|n[e.charCodeAt(r+2)]<<6|n[e.charCodeAt(r+3)],c[l++]=t>>16&255,c[l++]=t>>8&255,c[l++]=255&t;return 2===a&&(t=n[e.charCodeAt(r)]<<2|n[e.charCodeAt(r+1)]>>4,c[l++]=255&t),1===a&&(t=n[e.charCodeAt(r)]<<10|n[e.charCodeAt(r+1)]<<4|n[e.charCodeAt(r+2)]>>2,c[l++]=t>>8&255,c[l++]=255&t),c},t.fromByteArray=function(e){for(var t,n=e.length,o=n%3,i=[],s=16383,a=0,u=n-o;a<u;a+=s)i.push(c(e,a,a+s>u?u:a+s));return 1===o?(t=e[n-1],i.push(r[t>>2]+r[t<<4&63]+"==")):2===o&&(t=(e[n-2]<<8)+e[n-1],i.push(r[t>>10]+r[t>>4&63]+r[t<<2&63]+"=")),i.join("")};for(var r=[],n=[],o="undefined"!=typeof Uint8Array?Uint8Array:Array,i="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",s=0,a=i.length;s<a;++s)r[s]=i[s],n[i.charCodeAt(s)]=s;function u(e){var t=e.length;if(t%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var r=e.indexOf("=");return-1===r&&(r=t),[r,r===t?0:4-r%4]}function c(e,t,n){for(var o,i,s=[],a=t;a<n;a+=3)o=(e[a]<<16&16711680)+(e[a+1]<<8&65280)+(255&e[a+2]),s.push(r[(i=o)>>18&63]+r[i>>12&63]+r[i>>6&63]+r[63&i]);return s.join("")}n["-".charCodeAt(0)]=62,n["_".charCodeAt(0)]=63},924:(e,t,r)=>{"use strict";var n=r(210),o=r(559),i=o(n("String.prototype.indexOf"));e.exports=function(e,t){var r=n(e,!!t);return"function"==typeof r&&i(e,".prototype.")>-1?o(r):r}},559:(e,t,r)=>{"use strict";var n=r(612),o=r(210),i=o("%Function.prototype.apply%"),s=o("%Function.prototype.call%"),a=o("%Reflect.apply%",!0)||n.call(s,i),u=o("%Object.getOwnPropertyDescriptor%",!0),c=o("%Object.defineProperty%",!0),l=o("%Math.max%");if(c)try{c({},"a",{value:1})}catch(e){c=null}e.exports=function(e){var t=a(n,s,arguments);if(u&&c){var r=u(t,"length");r.configurable&&c(t,"length",{value:1+l(0,e.length-(arguments.length-1))})}return t};var p=function(){return a(n,i,arguments)};c?c(e.exports,"apply",{value:p}):e.exports.apply=p},187:e=>{"use strict";var t,r="object"==typeof Reflect?Reflect:null,n=r&&"function"==typeof r.apply?r.apply:function(e,t,r){return Function.prototype.apply.call(e,t,r)};t=r&&"function"==typeof r.ownKeys?r.ownKeys:Object.getOwnPropertySymbols?function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:function(e){return Object.getOwnPropertyNames(e)};var o=Number.isNaN||function(e){return e!=e};function i(){i.init.call(this)}e.exports=i,e.exports.once=function(e,t){return new Promise((function(r,n){function o(r){e.removeListener(t,i),n(r)}function i(){"function"==typeof e.removeListener&&e.removeListener("error",o),r([].slice.call(arguments))}y(e,t,i,{once:!0}),"error"!==t&&function(e,t,r){"function"==typeof e.on&&y(e,"error",t,{once:!0})}(e,o)}))},i.EventEmitter=i,i.prototype._events=void 0,i.prototype._eventsCount=0,i.prototype._maxListeners=void 0;var s=10;function a(e){if("function"!=typeof e)throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof e)}function u(e){return void 0===e._maxListeners?i.defaultMaxListeners:e._maxListeners}function c(e,t,r,n){var o,i,s,c;if(a(r),void 0===(i=e._events)?(i=e._events=Object.create(null),e._eventsCount=0):(void 0!==i.newListener&&(e.emit("newListener",t,r.listener?r.listener:r),i=e._events),s=i[t]),void 0===s)s=i[t]=r,++e._eventsCount;else if("function"==typeof s?s=i[t]=n?[r,s]:[s,r]:n?s.unshift(r):s.push(r),(o=u(e))>0&&s.length>o&&!s.warned){s.warned=!0;var l=new Error("Possible EventEmitter memory leak detected. "+s.length+" "+String(t)+" listeners added. Use emitter.setMaxListeners() to increase limit");l.name="MaxListenersExceededWarning",l.emitter=e,l.type=t,l.count=s.length,c=l,console&&console.warn&&console.warn(c)}return e}function l(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,0===arguments.length?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function p(e,t,r){var n={fired:!1,wrapFn:void 0,target:e,type:t,listener:r},o=l.bind(n);return o.listener=r,n.wrapFn=o,o}function f(e,t,r){var n=e._events;if(void 0===n)return[];var o=n[t];return void 0===o?[]:"function"==typeof o?r?[o.listener||o]:[o]:r?function(e){for(var t=new Array(e.length),r=0;r<t.length;++r)t[r]=e[r].listener||e[r];return t}(o):h(o,o.length)}function d(e){var t=this._events;if(void 0!==t){var r=t[e];if("function"==typeof r)return 1;if(void 0!==r)return r.length}return 0}function h(e,t){for(var r=new Array(t),n=0;n<t;++n)r[n]=e[n];return r}function y(e,t,r,n){if("function"==typeof e.on)n.once?e.once(t,r):e.on(t,r);else{if("function"!=typeof e.addEventListener)throw new TypeError('The "emitter" argument must be of type EventEmitter. Received type '+typeof e);e.addEventListener(t,(function o(i){n.once&&e.removeEventListener(t,o),r(i)}))}}Object.defineProperty(i,"defaultMaxListeners",{enumerable:!0,get:function(){return s},set:function(e){if("number"!=typeof e||e<0||o(e))throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+e+".");s=e}}),i.init=function(){void 0!==this._events&&this._events!==Object.getPrototypeOf(this)._events||(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0},i.prototype.setMaxListeners=function(e){if("number"!=typeof e||e<0||o(e))throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+e+".");return this._maxListeners=e,this},i.prototype.getMaxListeners=function(){return u(this)},i.prototype.emit=function(e){for(var t=[],r=1;r<arguments.length;r++)t.push(arguments[r]);var o="error"===e,i=this._events;if(void 0!==i)o=o&&void 0===i.error;else if(!o)return!1;if(o){var s;if(t.length>0&&(s=t[0]),s instanceof Error)throw s;var a=new Error("Unhandled error."+(s?" ("+s.message+")":""));throw a.context=s,a}var u=i[e];if(void 0===u)return!1;if("function"==typeof u)n(u,this,t);else{var c=u.length,l=h(u,c);for(r=0;r<c;++r)n(l[r],this,t)}return!0},i.prototype.addListener=function(e,t){return c(this,e,t,!1)},i.prototype.on=i.prototype.addListener,i.prototype.prependListener=function(e,t){return c(this,e,t,!0)},i.prototype.once=function(e,t){return a(t),this.on(e,p(this,e,t)),this},i.prototype.prependOnceListener=function(e,t){return a(t),this.prependListener(e,p(this,e,t)),this},i.prototype.removeListener=function(e,t){var r,n,o,i,s;if(a(t),void 0===(n=this._events))return this;if(void 0===(r=n[e]))return this;if(r===t||r.listener===t)0==--this._eventsCount?this._events=Object.create(null):(delete n[e],n.removeListener&&this.emit("removeListener",e,r.listener||t));else if("function"!=typeof r){for(o=-1,i=r.length-1;i>=0;i--)if(r[i]===t||r[i].listener===t){s=r[i].listener,o=i;break}if(o<0)return this;0===o?r.shift():function(e,t){for(;t+1<e.length;t++)e[t]=e[t+1];e.pop()}(r,o),1===r.length&&(n[e]=r[0]),void 0!==n.removeListener&&this.emit("removeListener",e,s||t)}return this},i.prototype.off=i.prototype.removeListener,i.prototype.removeAllListeners=function(e){var t,r,n;if(void 0===(r=this._events))return this;if(void 0===r.removeListener)return 0===arguments.length?(this._events=Object.create(null),this._eventsCount=0):void 0!==r[e]&&(0==--this._eventsCount?this._events=Object.create(null):delete r[e]),this;if(0===arguments.length){var o,i=Object.keys(r);for(n=0;n<i.length;++n)"removeListener"!==(o=i[n])&&this.removeAllListeners(o);return this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0,this}if("function"==typeof(t=r[e]))this.removeListener(e,t);else if(void 0!==t)for(n=t.length-1;n>=0;n--)this.removeListener(e,t[n]);return this},i.prototype.listeners=function(e){return f(this,e,!0)},i.prototype.rawListeners=function(e){return f(this,e,!1)},i.listenerCount=function(e,t){return"function"==typeof e.listenerCount?e.listenerCount(t):d.call(e,t)},i.prototype.listenerCount=d,i.prototype.eventNames=function(){return this._eventsCount>0?t(this._events):[]}},648:e=>{"use strict";var t="Function.prototype.bind called on incompatible ",r=Array.prototype.slice,n=Object.prototype.toString,o="[object Function]";e.exports=function(e){var i=this;if("function"!=typeof i||n.call(i)!==o)throw new TypeError(t+i);for(var s,a=r.call(arguments,1),u=function(){if(this instanceof s){var t=i.apply(this,a.concat(r.call(arguments)));return Object(t)===t?t:this}return i.apply(e,a.concat(r.call(arguments)))},c=Math.max(0,i.length-a.length),l=[],p=0;p<c;p++)l.push("$"+p);if(s=Function("binder","return function ("+l.join(",")+"){ return binder.apply(this,arguments); }")(u),i.prototype){var f=function(){};f.prototype=i.prototype,s.prototype=new f,f.prototype=null}return s}},612:(e,t,r)=>{"use strict";var n=r(648);e.exports=Function.prototype.bind||n},210:(e,t,r)=>{"use strict";var n,o=SyntaxError,i=Function,s=TypeError,a=function(e){try{return i('"use strict"; return ('+e+").constructor;")()}catch(e){}},u=Object.getOwnPropertyDescriptor;if(u)try{u({},"")}catch(e){u=null}var c=function(){throw new s},l=u?function(){try{return c}catch(e){try{return u(arguments,"callee").get}catch(e){return c}}}():c,p=r(405)(),f=Object.getPrototypeOf||function(e){return e.__proto__},d={},h="undefined"==typeof Uint8Array?n:f(Uint8Array),y={"%AggregateError%":"undefined"==typeof AggregateError?n:AggregateError,"%Array%":Array,"%ArrayBuffer%":"undefined"==typeof ArrayBuffer?n:ArrayBuffer,"%ArrayIteratorPrototype%":p?f([][Symbol.iterator]()):n,"%AsyncFromSyncIteratorPrototype%":n,"%AsyncFunction%":d,"%AsyncGenerator%":d,"%AsyncGeneratorFunction%":d,"%AsyncIteratorPrototype%":d,"%Atomics%":"undefined"==typeof Atomics?n:Atomics,"%BigInt%":"undefined"==typeof BigInt?n:BigInt,"%Boolean%":Boolean,"%DataView%":"undefined"==typeof DataView?n:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":Error,"%eval%":eval,"%EvalError%":EvalError,"%Float32Array%":"undefined"==typeof Float32Array?n:Float32Array,"%Float64Array%":"undefined"==typeof Float64Array?n:Float64Array,"%FinalizationRegistry%":"undefined"==typeof FinalizationRegistry?n:FinalizationRegistry,"%Function%":i,"%GeneratorFunction%":d,"%Int8Array%":"undefined"==typeof Int8Array?n:Int8Array,"%Int16Array%":"undefined"==typeof Int16Array?n:Int16Array,"%Int32Array%":"undefined"==typeof Int32Array?n:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":p?f(f([][Symbol.iterator]())):n,"%JSON%":"object"==typeof JSON?JSON:n,"%Map%":"undefined"==typeof Map?n:Map,"%MapIteratorPrototype%":"undefined"!=typeof Map&&p?f((new Map)[Symbol.iterator]()):n,"%Math%":Math,"%Number%":Number,"%Object%":Object,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":"undefined"==typeof Promise?n:Promise,"%Proxy%":"undefined"==typeof Proxy?n:Proxy,"%RangeError%":RangeError,"%ReferenceError%":ReferenceError,"%Reflect%":"undefined"==typeof Reflect?n:Reflect,"%RegExp%":RegExp,"%Set%":"undefined"==typeof Set?n:Set,"%SetIteratorPrototype%":"undefined"!=typeof Set&&p?f((new Set)[Symbol.iterator]()):n,"%SharedArrayBuffer%":"undefined"==typeof SharedArrayBuffer?n:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":p?f(""[Symbol.iterator]()):n,"%Symbol%":p?Symbol:n,"%SyntaxError%":o,"%ThrowTypeError%":l,"%TypedArray%":h,"%TypeError%":s,"%Uint8Array%":"undefined"==typeof Uint8Array?n:Uint8Array,"%Uint8ClampedArray%":"undefined"==typeof Uint8ClampedArray?n:Uint8ClampedArray,"%Uint16Array%":"undefined"==typeof Uint16Array?n:Uint16Array,"%Uint32Array%":"undefined"==typeof Uint32Array?n:Uint32Array,"%URIError%":URIError,"%WeakMap%":"undefined"==typeof WeakMap?n:WeakMap,"%WeakRef%":"undefined"==typeof WeakRef?n:WeakRef,"%WeakSet%":"undefined"==typeof WeakSet?n:WeakSet},g=function e(t){var r;if("%AsyncFunction%"===t)r=a("async function () {}");else if("%GeneratorFunction%"===t)r=a("function* () {}");else if("%AsyncGeneratorFunction%"===t)r=a("async function* () {}");else if("%AsyncGenerator%"===t){var n=e("%AsyncGeneratorFunction%");n&&(r=n.prototype)}else if("%AsyncIteratorPrototype%"===t){var o=e("%AsyncGenerator%");o&&(r=f(o.prototype))}return y[t]=r,r},v={"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},m=r(612),_=r(642),S=m.call(Function.call,Array.prototype.concat),b=m.call(Function.apply,Array.prototype.splice),w=m.call(Function.call,String.prototype.replace),O=m.call(Function.call,String.prototype.slice),A=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,E=/\\(\\)?/g,P=function(e){var t=O(e,0,1),r=O(e,-1);if("%"===t&&"%"!==r)throw new o("invalid intrinsic syntax, expected closing `%`");if("%"===r&&"%"!==t)throw new o("invalid intrinsic syntax, expected opening `%`");var n=[];return w(e,A,(function(e,t,r,o){n[n.length]=r?w(o,E,"$1"):t||e})),n},k=function(e,t){var r,n=e;if(_(v,n)&&(n="%"+(r=v[n])[0]+"%"),_(y,n)){var i=y[n];if(i===d&&(i=g(n)),void 0===i&&!t)throw new s("intrinsic "+e+" exists, but is not available. Please file an issue!");return{alias:r,name:n,value:i}}throw new o("intrinsic "+e+" does not exist!")};e.exports=function(e,t){if("string"!=typeof e||0===e.length)throw new s("intrinsic name must be a non-empty string");if(arguments.length>1&&"boolean"!=typeof t)throw new s('"allowMissing" argument must be a boolean');var r=P(e),n=r.length>0?r[0]:"",i=k("%"+n+"%",t),a=i.name,c=i.value,l=!1,p=i.alias;p&&(n=p[0],b(r,S([0,1],p)));for(var f=1,d=!0;f<r.length;f+=1){var h=r[f],g=O(h,0,1),v=O(h,-1);if(('"'===g||"'"===g||"`"===g||'"'===v||"'"===v||"`"===v)&&g!==v)throw new o("property names with quotes must have matching quotes");if("constructor"!==h&&d||(l=!0),_(y,a="%"+(n+="."+h)+"%"))c=y[a];else if(null!=c){if(!(h in c)){if(!t)throw new s("base intrinsic for "+e+" exists, but the property is not available.");return}if(u&&f+1>=r.length){var m=u(c,h);c=(d=!!m)&&"get"in m&&!("originalValue"in m.get)?m.get:c[h]}else d=_(c,h),c=c[h];d&&!l&&(y[a]=c)}}return c}},405:(e,t,r)=>{"use strict";var n="undefined"!=typeof Symbol&&Symbol,o=r(419);e.exports=function(){return"function"==typeof n&&"function"==typeof Symbol&&"symbol"==typeof n("foo")&&"symbol"==typeof Symbol("bar")&&o()}},419:e=>{"use strict";e.exports=function(){if("function"!=typeof Symbol||"function"!=typeof Object.getOwnPropertySymbols)return!1;if("symbol"==typeof Symbol.iterator)return!0;var e={},t=Symbol("test"),r=Object(t);if("string"==typeof t)return!1;if("[object Symbol]"!==Object.prototype.toString.call(t))return!1;if("[object Symbol]"!==Object.prototype.toString.call(r))return!1;for(t in e[t]=42,e)return!1;if("function"==typeof Object.keys&&0!==Object.keys(e).length)return!1;if("function"==typeof Object.getOwnPropertyNames&&0!==Object.getOwnPropertyNames(e).length)return!1;var n=Object.getOwnPropertySymbols(e);if(1!==n.length||n[0]!==t)return!1;if(!Object.prototype.propertyIsEnumerable.call(e,t))return!1;if("function"==typeof Object.getOwnPropertyDescriptor){var o=Object.getOwnPropertyDescriptor(e,t);if(42!==o.value||!0!==o.enumerable)return!1}return!0}},642:(e,t,r)=>{"use strict";var n=r(612);e.exports=n.call(Function.call,Object.prototype.hasOwnProperty)},631:(e,t,r)=>{var n="function"==typeof Map&&Map.prototype,o=Object.getOwnPropertyDescriptor&&n?Object.getOwnPropertyDescriptor(Map.prototype,"size"):null,i=n&&o&&"function"==typeof o.get?o.get:null,s=n&&Map.prototype.forEach,a="function"==typeof Set&&Set.prototype,u=Object.getOwnPropertyDescriptor&&a?Object.getOwnPropertyDescriptor(Set.prototype,"size"):null,c=a&&u&&"function"==typeof u.get?u.get:null,l=a&&Set.prototype.forEach,p="function"==typeof WeakMap&&WeakMap.prototype?WeakMap.prototype.has:null,f="function"==typeof WeakSet&&WeakSet.prototype?WeakSet.prototype.has:null,d="function"==typeof WeakRef&&WeakRef.prototype?WeakRef.prototype.deref:null,h=Boolean.prototype.valueOf,y=Object.prototype.toString,g=Function.prototype.toString,v=String.prototype.match,m=String.prototype.slice,_=String.prototype.replace,S=String.prototype.toUpperCase,b=String.prototype.toLowerCase,w=RegExp.prototype.test,O=Array.prototype.concat,A=Array.prototype.join,E=Array.prototype.slice,P=Math.floor,k="function"==typeof BigInt?BigInt.prototype.valueOf:null,R=Object.getOwnPropertySymbols,I="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?Symbol.prototype.toString:null,j="function"==typeof Symbol&&"object"==typeof Symbol.iterator,x="function"==typeof Symbol&&Symbol.toStringTag&&(Symbol.toStringTag,1)?Symbol.toStringTag:null,T=Object.prototype.propertyIsEnumerable,C=("function"==typeof Reflect?Reflect.getPrototypeOf:Object.getPrototypeOf)||([].__proto__===Array.prototype?function(e){return e.__proto__}:null);function N(e,t){if(e===1/0||e===-1/0||e!=e||e&&e>-1e3&&e<1e3||w.call(/e/,t))return t;var r=/[0-9](?=(?:[0-9]{3})+(?![0-9]))/g;if("number"==typeof e){var n=e<0?-P(-e):P(e);if(n!==e){var o=String(n),i=m.call(t,o.length+1);return _.call(o,r,"$&_")+"."+_.call(_.call(i,/([0-9]{3})/g,"$&_"),/_$/,"")}}return _.call(t,r,"$&_")}var U=r(654).custom,L=U&&q(U)?U:null;function M(e,t,r){var n="double"===(r.quoteStyle||t)?'"':"'";return n+e+n}function F(e){return _.call(String(e),/"/g,""")}function z(e){return!("[object Array]"!==H(e)||x&&"object"==typeof e&&x in e)}function q(e){if(j)return e&&"object"==typeof e&&e instanceof Symbol;if("symbol"==typeof e)return!0;if(!e||"object"!=typeof e||!I)return!1;try{return I.call(e),!0}catch(e){}return!1}e.exports=function e(t,r,n,o){var a=r||{};if(B(a,"quoteStyle")&&"single"!==a.quoteStyle&&"double"!==a.quoteStyle)throw new TypeError('option "quoteStyle" must be "single" or "double"');if(B(a,"maxStringLength")&&("number"==typeof a.maxStringLength?a.maxStringLength<0&&a.maxStringLength!==1/0:null!==a.maxStringLength))throw new TypeError('option "maxStringLength", if provided, must be a positive integer, Infinity, or `null`');var u=!B(a,"customInspect")||a.customInspect;if("boolean"!=typeof u&&"symbol"!==u)throw new TypeError("option \"customInspect\", if provided, must be `true`, `false`, or `'symbol'`");if(B(a,"indent")&&null!==a.indent&&"\t"!==a.indent&&!(parseInt(a.indent,10)===a.indent&&a.indent>0))throw new TypeError('option "indent" must be "\\t", an integer > 0, or `null`');if(B(a,"numericSeparator")&&"boolean"!=typeof a.numericSeparator)throw new TypeError('option "numericSeparator", if provided, must be `true` or `false`');var y=a.numericSeparator;if(void 0===t)return"undefined";if(null===t)return"null";if("boolean"==typeof t)return t?"true":"false";if("string"==typeof t)return $(t,a);if("number"==typeof t){if(0===t)return 1/0/t>0?"0":"-0";var S=String(t);return y?N(t,S):S}if("bigint"==typeof t){var w=String(t)+"n";return y?N(t,w):w}var P=void 0===a.depth?5:a.depth;if(void 0===n&&(n=0),n>=P&&P>0&&"object"==typeof t)return z(t)?"[Array]":"[Object]";var R,U=function(e,t){var r;if("\t"===e.indent)r="\t";else{if(!("number"==typeof e.indent&&e.indent>0))return null;r=A.call(Array(e.indent+1)," ")}return{base:r,prev:A.call(Array(t+1),r)}}(a,n);if(void 0===o)o=[];else if(G(o,t)>=0)return"[Circular]";function D(t,r,i){if(r&&(o=E.call(o)).push(r),i){var s={depth:a.depth};return B(a,"quoteStyle")&&(s.quoteStyle=a.quoteStyle),e(t,s,n+1,o)}return e(t,a,n+1,o)}if("function"==typeof t){var V=function(e){if(e.name)return e.name;var t=v.call(g.call(e),/^function\s*([\w$]+)/);return t?t[1]:null}(t),X=Q(t,D);return"[Function"+(V?": "+V:" (anonymous)")+"]"+(X.length>0?" { "+A.call(X,", ")+" }":"")}if(q(t)){var Z=j?_.call(String(t),/^(Symbol\(.*\))_[^)]*$/,"$1"):I.call(t);return"object"!=typeof t||j?Z:W(Z)}if((R=t)&&"object"==typeof R&&("undefined"!=typeof HTMLElement&&R instanceof HTMLElement||"string"==typeof R.nodeName&&"function"==typeof R.getAttribute)){for(var ee="<"+b.call(String(t.nodeName)),te=t.attributes||[],re=0;re<te.length;re++)ee+=" "+te[re].name+"="+M(F(te[re].value),"double",a);return ee+=">",t.childNodes&&t.childNodes.length&&(ee+="..."),ee+"</"+b.call(String(t.nodeName))+">"}if(z(t)){if(0===t.length)return"[]";var ne=Q(t,D);return U&&!function(e){for(var t=0;t<e.length;t++)if(G(e[t],"\n")>=0)return!1;return!0}(ne)?"["+K(ne,U)+"]":"[ "+A.call(ne,", ")+" ]"}if(function(e){return!("[object Error]"!==H(e)||x&&"object"==typeof e&&x in e)}(t)){var oe=Q(t,D);return"cause"in t&&!T.call(t,"cause")?"{ ["+String(t)+"] "+A.call(O.call("[cause]: "+D(t.cause),oe),", ")+" }":0===oe.length?"["+String(t)+"]":"{ ["+String(t)+"] "+A.call(oe,", ")+" }"}if("object"==typeof t&&u){if(L&&"function"==typeof t[L])return t[L]();if("symbol"!==u&&"function"==typeof t.inspect)return t.inspect()}if(function(e){if(!i||!e||"object"!=typeof e)return!1;try{i.call(e);try{c.call(e)}catch(e){return!0}return e instanceof Map}catch(e){}return!1}(t)){var ie=[];return s.call(t,(function(e,r){ie.push(D(r,t,!0)+" => "+D(e,t))})),Y("Map",i.call(t),ie,U)}if(function(e){if(!c||!e||"object"!=typeof e)return!1;try{c.call(e);try{i.call(e)}catch(e){return!0}return e instanceof Set}catch(e){}return!1}(t)){var se=[];return l.call(t,(function(e){se.push(D(e,t))})),Y("Set",c.call(t),se,U)}if(function(e){if(!p||!e||"object"!=typeof e)return!1;try{p.call(e,p);try{f.call(e,f)}catch(e){return!0}return e instanceof WeakMap}catch(e){}return!1}(t))return J("WeakMap");if(function(e){if(!f||!e||"object"!=typeof e)return!1;try{f.call(e,f);try{p.call(e,p)}catch(e){return!0}return e instanceof WeakSet}catch(e){}return!1}(t))return J("WeakSet");if(function(e){if(!d||!e||"object"!=typeof e)return!1;try{return d.call(e),!0}catch(e){}return!1}(t))return J("WeakRef");if(function(e){return!("[object Number]"!==H(e)||x&&"object"==typeof e&&x in e)}(t))return W(D(Number(t)));if(function(e){if(!e||"object"!=typeof e||!k)return!1;try{return k.call(e),!0}catch(e){}return!1}(t))return W(D(k.call(t)));if(function(e){return!("[object Boolean]"!==H(e)||x&&"object"==typeof e&&x in e)}(t))return W(h.call(t));if(function(e){return!("[object String]"!==H(e)||x&&"object"==typeof e&&x in e)}(t))return W(D(String(t)));if(!function(e){return!("[object Date]"!==H(e)||x&&"object"==typeof e&&x in e)}(t)&&!function(e){return!("[object RegExp]"!==H(e)||x&&"object"==typeof e&&x in e)}(t)){var ae=Q(t,D),ue=C?C(t)===Object.prototype:t instanceof Object||t.constructor===Object,ce=t instanceof Object?"":"null prototype",le=!ue&&x&&Object(t)===t&&x in t?m.call(H(t),8,-1):ce?"Object":"",pe=(ue||"function"!=typeof t.constructor?"":t.constructor.name?t.constructor.name+" ":"")+(le||ce?"["+A.call(O.call([],le||[],ce||[]),": ")+"] ":"");return 0===ae.length?pe+"{}":U?pe+"{"+K(ae,U)+"}":pe+"{ "+A.call(ae,", ")+" }"}return String(t)};var D=Object.prototype.hasOwnProperty||function(e){return e in this};function B(e,t){return D.call(e,t)}function H(e){return y.call(e)}function G(e,t){if(e.indexOf)return e.indexOf(t);for(var r=0,n=e.length;r<n;r++)if(e[r]===t)return r;return-1}function $(e,t){if(e.length>t.maxStringLength){var r=e.length-t.maxStringLength,n="... "+r+" more character"+(r>1?"s":"");return $(m.call(e,0,t.maxStringLength),t)+n}return M(_.call(_.call(e,/(['\\])/g,"\\$1"),/[\x00-\x1f]/g,V),"single",t)}function V(e){var t=e.charCodeAt(0),r={8:"b",9:"t",10:"n",12:"f",13:"r"}[t];return r?"\\"+r:"\\x"+(t<16?"0":"")+S.call(t.toString(16))}function W(e){return"Object("+e+")"}function J(e){return e+" { ? }"}function Y(e,t,r,n){return e+" ("+t+") {"+(n?K(r,n):A.call(r,", "))+"}"}function K(e,t){if(0===e.length)return"";var r="\n"+t.prev+t.base;return r+A.call(e,","+r)+"\n"+t.prev}function Q(e,t){var r=z(e),n=[];if(r){n.length=e.length;for(var o=0;o<e.length;o++)n[o]=B(e,o)?t(e[o],e):""}var i,s="function"==typeof R?R(e):[];if(j){i={};for(var a=0;a<s.length;a++)i["$"+s[a]]=s[a]}for(var u in e)B(e,u)&&(r&&String(Number(u))===u&&u<e.length||j&&i["$"+u]instanceof Symbol||(w.call(/[^\w$]/,u)?n.push(t(u,e)+": "+t(e[u],e)):n.push(u+": "+t(e[u],e))));if("function"==typeof R)for(var c=0;c<s.length;c++)T.call(e,s[c])&&n.push("["+t(s[c])+"]: "+t(e[s[c]],e));return n}},798:e=>{"use strict";var t=String.prototype.replace,r=/%20/g,n="RFC3986";e.exports={default:n,formatters:{RFC1738:function(e){return t.call(e,r,"+")},RFC3986:function(e){return String(e)}},RFC1738:"RFC1738",RFC3986:n}},129:(e,t,r)=>{"use strict";var n=r(261),o=r(235),i=r(798);e.exports={formats:i,parse:o,stringify:n}},235:(e,t,r)=>{"use strict";var n=r(769),o=Object.prototype.hasOwnProperty,i=Array.isArray,s={allowDots:!1,allowPrototypes:!1,allowSparse:!1,arrayLimit:20,charset:"utf-8",charsetSentinel:!1,comma:!1,decoder:n.decode,delimiter:"&",depth:5,ignoreQueryPrefix:!1,interpretNumericEntities:!1,parameterLimit:1e3,parseArrays:!0,plainObjects:!1,strictNullHandling:!1},a=function(e){return e.replace(/&#(\d+);/g,(function(e,t){return String.fromCharCode(parseInt(t,10))}))},u=function(e,t){return e&&"string"==typeof e&&t.comma&&e.indexOf(",")>-1?e.split(","):e},c=function(e,t,r,n){if(e){var i=r.allowDots?e.replace(/\.([^.[]+)/g,"[$1]"):e,s=/(\[[^[\]]*])/g,a=r.depth>0&&/(\[[^[\]]*])/.exec(i),c=a?i.slice(0,a.index):i,l=[];if(c){if(!r.plainObjects&&o.call(Object.prototype,c)&&!r.allowPrototypes)return;l.push(c)}for(var p=0;r.depth>0&&null!==(a=s.exec(i))&&p<r.depth;){if(p+=1,!r.plainObjects&&o.call(Object.prototype,a[1].slice(1,-1))&&!r.allowPrototypes)return;l.push(a[1])}return a&&l.push("["+i.slice(a.index)+"]"),function(e,t,r,n){for(var o=n?t:u(t,r),i=e.length-1;i>=0;--i){var s,a=e[i];if("[]"===a&&r.parseArrays)s=[].concat(o);else{s=r.plainObjects?Object.create(null):{};var c="["===a.charAt(0)&&"]"===a.charAt(a.length-1)?a.slice(1,-1):a,l=parseInt(c,10);r.parseArrays||""!==c?!isNaN(l)&&a!==c&&String(l)===c&&l>=0&&r.parseArrays&&l<=r.arrayLimit?(s=[])[l]=o:"__proto__"!==c&&(s[c]=o):s={0:o}}o=s}return o}(l,t,r,n)}};e.exports=function(e,t){var r=function(e){if(!e)return s;if(null!==e.decoder&&void 0!==e.decoder&&"function"!=typeof e.decoder)throw new TypeError("Decoder has to be a function.");if(void 0!==e.charset&&"utf-8"!==e.charset&&"iso-8859-1"!==e.charset)throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");var t=void 0===e.charset?s.charset:e.charset;return{allowDots:void 0===e.allowDots?s.allowDots:!!e.allowDots,allowPrototypes:"boolean"==typeof e.allowPrototypes?e.allowPrototypes:s.allowPrototypes,allowSparse:"boolean"==typeof e.allowSparse?e.allowSparse:s.allowSparse,arrayLimit:"number"==typeof e.arrayLimit?e.arrayLimit:s.arrayLimit,charset:t,charsetSentinel:"boolean"==typeof e.charsetSentinel?e.charsetSentinel:s.charsetSentinel,comma:"boolean"==typeof e.comma?e.comma:s.comma,decoder:"function"==typeof e.decoder?e.decoder:s.decoder,delimiter:"string"==typeof e.delimiter||n.isRegExp(e.delimiter)?e.delimiter:s.delimiter,depth:"number"==typeof e.depth||!1===e.depth?+e.depth:s.depth,ignoreQueryPrefix:!0===e.ignoreQueryPrefix,interpretNumericEntities:"boolean"==typeof e.interpretNumericEntities?e.interpretNumericEntities:s.interpretNumericEntities,parameterLimit:"number"==typeof e.parameterLimit?e.parameterLimit:s.parameterLimit,parseArrays:!1!==e.parseArrays,plainObjects:"boolean"==typeof e.plainObjects?e.plainObjects:s.plainObjects,strictNullHandling:"boolean"==typeof e.strictNullHandling?e.strictNullHandling:s.strictNullHandling}}(t);if(""===e||null==e)return r.plainObjects?Object.create(null):{};for(var l="string"==typeof e?function(e,t){var r,c={},l=t.ignoreQueryPrefix?e.replace(/^\?/,""):e,p=t.parameterLimit===1/0?void 0:t.parameterLimit,f=l.split(t.delimiter,p),d=-1,h=t.charset;if(t.charsetSentinel)for(r=0;r<f.length;++r)0===f[r].indexOf("utf8=")&&("utf8=%E2%9C%93"===f[r]?h="utf-8":"utf8=%26%2310003%3B"===f[r]&&(h="iso-8859-1"),d=r,r=f.length);for(r=0;r<f.length;++r)if(r!==d){var y,g,v=f[r],m=v.indexOf("]="),_=-1===m?v.indexOf("="):m+1;-1===_?(y=t.decoder(v,s.decoder,h,"key"),g=t.strictNullHandling?null:""):(y=t.decoder(v.slice(0,_),s.decoder,h,"key"),g=n.maybeMap(u(v.slice(_+1),t),(function(e){return t.decoder(e,s.decoder,h,"value")}))),g&&t.interpretNumericEntities&&"iso-8859-1"===h&&(g=a(g)),v.indexOf("[]=")>-1&&(g=i(g)?[g]:g),o.call(c,y)?c[y]=n.combine(c[y],g):c[y]=g}return c}(e,r):e,p=r.plainObjects?Object.create(null):{},f=Object.keys(l),d=0;d<f.length;++d){var h=f[d],y=c(h,l[h],r,"string"==typeof e);p=n.merge(p,y,r)}return!0===r.allowSparse?p:n.compact(p)}},261:(e,t,r)=>{"use strict";var n=r(478),o=r(769),i=r(798),s=Object.prototype.hasOwnProperty,a={brackets:function(e){return e+"[]"},comma:"comma",indices:function(e,t){return e+"["+t+"]"},repeat:function(e){return e}},u=Array.isArray,c=String.prototype.split,l=Array.prototype.push,p=function(e,t){l.apply(e,u(t)?t:[t])},f=Date.prototype.toISOString,d=i.default,h={addQueryPrefix:!1,allowDots:!1,charset:"utf-8",charsetSentinel:!1,delimiter:"&",encode:!0,encoder:o.encode,encodeValuesOnly:!1,format:d,formatter:i.formatters[d],indices:!1,serializeDate:function(e){return f.call(e)},skipNulls:!1,strictNullHandling:!1},y={},g=function e(t,r,i,s,a,l,f,d,g,v,m,_,S,b,w){for(var O,A=t,E=w,P=0,k=!1;void 0!==(E=E.get(y))&&!k;){var R=E.get(t);if(P+=1,void 0!==R){if(R===P)throw new RangeError("Cyclic object value");k=!0}void 0===E.get(y)&&(P=0)}if("function"==typeof f?A=f(r,A):A instanceof Date?A=v(A):"comma"===i&&u(A)&&(A=o.maybeMap(A,(function(e){return e instanceof Date?v(e):e}))),null===A){if(s)return l&&!S?l(r,h.encoder,b,"key",m):r;A=""}if("string"==typeof(O=A)||"number"==typeof O||"boolean"==typeof O||"symbol"==typeof O||"bigint"==typeof O||o.isBuffer(A)){if(l){var I=S?r:l(r,h.encoder,b,"key",m);if("comma"===i&&S){for(var j=c.call(String(A),","),x="",T=0;T<j.length;++T)x+=(0===T?"":",")+_(l(j[T],h.encoder,b,"value",m));return[_(I)+"="+x]}return[_(I)+"="+_(l(A,h.encoder,b,"value",m))]}return[_(r)+"="+_(String(A))]}var C,N=[];if(void 0===A)return N;if("comma"===i&&u(A))C=[{value:A.length>0?A.join(",")||null:void 0}];else if(u(f))C=f;else{var U=Object.keys(A);C=d?U.sort(d):U}for(var L=0;L<C.length;++L){var M=C[L],F="object"==typeof M&&void 0!==M.value?M.value:A[M];if(!a||null!==F){var z=u(A)?"function"==typeof i?i(r,M):r:r+(g?"."+M:"["+M+"]");w.set(t,P);var q=n();q.set(y,w),p(N,e(F,z,i,s,a,l,f,d,g,v,m,_,S,b,q))}}return N};e.exports=function(e,t){var r,o=e,c=function(e){if(!e)return h;if(null!==e.encoder&&void 0!==e.encoder&&"function"!=typeof e.encoder)throw new TypeError("Encoder has to be a function.");var t=e.charset||h.charset;if(void 0!==e.charset&&"utf-8"!==e.charset&&"iso-8859-1"!==e.charset)throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");var r=i.default;if(void 0!==e.format){if(!s.call(i.formatters,e.format))throw new TypeError("Unknown format option provided.");r=e.format}var n=i.formatters[r],o=h.filter;return("function"==typeof e.filter||u(e.filter))&&(o=e.filter),{addQueryPrefix:"boolean"==typeof e.addQueryPrefix?e.addQueryPrefix:h.addQueryPrefix,allowDots:void 0===e.allowDots?h.allowDots:!!e.allowDots,charset:t,charsetSentinel:"boolean"==typeof e.charsetSentinel?e.charsetSentinel:h.charsetSentinel,delimiter:void 0===e.delimiter?h.delimiter:e.delimiter,encode:"boolean"==typeof e.encode?e.encode:h.encode,encoder:"function"==typeof e.encoder?e.encoder:h.encoder,encodeValuesOnly:"boolean"==typeof e.encodeValuesOnly?e.encodeValuesOnly:h.encodeValuesOnly,filter:o,format:r,formatter:n,serializeDate:"function"==typeof e.serializeDate?e.serializeDate:h.serializeDate,skipNulls:"boolean"==typeof e.skipNulls?e.skipNulls:h.skipNulls,sort:"function"==typeof e.sort?e.sort:null,strictNullHandling:"boolean"==typeof e.strictNullHandling?e.strictNullHandling:h.strictNullHandling}}(t);"function"==typeof c.filter?o=(0,c.filter)("",o):u(c.filter)&&(r=c.filter);var l,f=[];if("object"!=typeof o||null===o)return"";l=t&&t.arrayFormat in a?t.arrayFormat:t&&"indices"in t?t.indices?"indices":"repeat":"indices";var d=a[l];r||(r=Object.keys(o)),c.sort&&r.sort(c.sort);for(var y=n(),v=0;v<r.length;++v){var m=r[v];c.skipNulls&&null===o[m]||p(f,g(o[m],m,d,c.strictNullHandling,c.skipNulls,c.encode?c.encoder:null,c.filter,c.sort,c.allowDots,c.serializeDate,c.format,c.formatter,c.encodeValuesOnly,c.charset,y))}var _=f.join(c.delimiter),S=!0===c.addQueryPrefix?"?":"";return c.charsetSentinel&&("iso-8859-1"===c.charset?S+="utf8=%26%2310003%3B&":S+="utf8=%E2%9C%93&"),_.length>0?S+_:""}},769:(e,t,r)=>{"use strict";var n=r(798),o=Object.prototype.hasOwnProperty,i=Array.isArray,s=function(){for(var e=[],t=0;t<256;++t)e.push("%"+((t<16?"0":"")+t.toString(16)).toUpperCase());return e}(),a=function(e,t){for(var r=t&&t.plainObjects?Object.create(null):{},n=0;n<e.length;++n)void 0!==e[n]&&(r[n]=e[n]);return r};e.exports={arrayToObject:a,assign:function(e,t){return Object.keys(t).reduce((function(e,r){return e[r]=t[r],e}),e)},combine:function(e,t){return[].concat(e,t)},compact:function(e){for(var t=[{obj:{o:e},prop:"o"}],r=[],n=0;n<t.length;++n)for(var o=t[n],s=o.obj[o.prop],a=Object.keys(s),u=0;u<a.length;++u){var c=a[u],l=s[c];"object"==typeof l&&null!==l&&-1===r.indexOf(l)&&(t.push({obj:s,prop:c}),r.push(l))}return function(e){for(;e.length>1;){var t=e.pop(),r=t.obj[t.prop];if(i(r)){for(var n=[],o=0;o<r.length;++o)void 0!==r[o]&&n.push(r[o]);t.obj[t.prop]=n}}}(t),e},decode:function(e,t,r){var n=e.replace(/\+/g," ");if("iso-8859-1"===r)return n.replace(/%[0-9a-f]{2}/gi,unescape);try{return decodeURIComponent(n)}catch(e){return n}},encode:function(e,t,r,o,i){if(0===e.length)return e;var a=e;if("symbol"==typeof e?a=Symbol.prototype.toString.call(e):"string"!=typeof e&&(a=String(e)),"iso-8859-1"===r)return escape(a).replace(/%u[0-9a-f]{4}/gi,(function(e){return"%26%23"+parseInt(e.slice(2),16)+"%3B"}));for(var u="",c=0;c<a.length;++c){var l=a.charCodeAt(c);45===l||46===l||95===l||126===l||l>=48&&l<=57||l>=65&&l<=90||l>=97&&l<=122||i===n.RFC1738&&(40===l||41===l)?u+=a.charAt(c):l<128?u+=s[l]:l<2048?u+=s[192|l>>6]+s[128|63&l]:l<55296||l>=57344?u+=s[224|l>>12]+s[128|l>>6&63]+s[128|63&l]:(c+=1,l=65536+((1023&l)<<10|1023&a.charCodeAt(c)),u+=s[240|l>>18]+s[128|l>>12&63]+s[128|l>>6&63]+s[128|63&l])}return u},isBuffer:function(e){return!(!e||"object"!=typeof e||!(e.constructor&&e.constructor.isBuffer&&e.constructor.isBuffer(e)))},isRegExp:function(e){return"[object RegExp]"===Object.prototype.toString.call(e)},maybeMap:function(e,t){if(i(e)){for(var r=[],n=0;n<e.length;n+=1)r.push(t(e[n]));return r}return t(e)},merge:function e(t,r,n){if(!r)return t;if("object"!=typeof r){if(i(t))t.push(r);else{if(!t||"object"!=typeof t)return[t,r];(n&&(n.plainObjects||n.allowPrototypes)||!o.call(Object.prototype,r))&&(t[r]=!0)}return t}if(!t||"object"!=typeof t)return[t].concat(r);var s=t;return i(t)&&!i(r)&&(s=a(t,n)),i(t)&&i(r)?(r.forEach((function(r,i){if(o.call(t,i)){var s=t[i];s&&"object"==typeof s&&r&&"object"==typeof r?t[i]=e(s,r,n):t.push(r)}else t[i]=r})),t):Object.keys(r).reduce((function(t,i){var s=r[i];return o.call(t,i)?t[i]=e(t[i],s,n):t[i]=s,t}),s)}}},478:(e,t,r)=>{"use strict";var n=r(210),o=r(924),i=r(631),s=n("%TypeError%"),a=n("%WeakMap%",!0),u=n("%Map%",!0),c=o("WeakMap.prototype.get",!0),l=o("WeakMap.prototype.set",!0),p=o("WeakMap.prototype.has",!0),f=o("Map.prototype.get",!0),d=o("Map.prototype.set",!0),h=o("Map.prototype.has",!0),y=function(e,t){for(var r,n=e;null!==(r=n.next);n=r)if(r.key===t)return n.next=r.next,r.next=e.next,e.next=r,r};e.exports=function(){var e,t,r,n={assert:function(e){if(!n.has(e))throw new s("Side channel does not contain "+i(e))},get:function(n){if(a&&n&&("object"==typeof n||"function"==typeof n)){if(e)return c(e,n)}else if(u){if(t)return f(t,n)}else if(r)return function(e,t){var r=y(e,t);return r&&r.value}(r,n)},has:function(n){if(a&&n&&("object"==typeof n||"function"==typeof n)){if(e)return p(e,n)}else if(u){if(t)return h(t,n)}else if(r)return function(e,t){return!!y(e,t)}(r,n);return!1},set:function(n,o){a&&n&&("object"==typeof n||"function"==typeof n)?(e||(e=new a),l(e,n,o)):u?(t||(t=new u),d(t,n,o)):(r||(r={key:{},next:null}),function(e,t,r){var n=y(e,t);n?n.value=r:e.next={key:t,next:e.next,value:r}}(r,n,o))}};return n}},654:()=>{}},t={};function r(n){var o=t[n];if(void 0!==o)return o.exports;var i=t[n]={exports:{}};return e[n].call(i.exports,i,i.exports,r),i.exports}r.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return r.d(t,{a:t}),t},r.d=(e,t)=>{for(var n in t)r.o(t,n)&&!r.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},r.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var n={};(()=>{"use strict";r.r(n),r.d(n,{AuthCallback:()=>$,AuthContext:()=>U,AuthFlow:()=>T,AuthProvider:()=>L,AuthRefreshTokenError:()=>j,AuthService:()=>N,DEFAULT_IDENTITY_PROVIDER:()=>h,Modes:()=>m,Privileges:()=>_,Protected:()=>z,ProtectedContentContext:()=>M,ProtectedContentProvider:()=>F,TenantIds:()=>S,getIdentityProviderFromHostname:()=>v,userHasMode:()=>w,userHasTenantAccess:()=>b});var e=r(129),t=r.n(e);const o=require("react");var i=r.n(o);const s=require("react-router-dom");function a(e,t,r,n){return new(r||(r=Promise))((function(o,i){function s(e){try{u(n.next(e))}catch(e){i(e)}}function a(e){try{u(n.throw(e))}catch(e){i(e)}}function u(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(s,a)}u((n=n.apply(e,t||[])).next())}))}Object.create,Object.create;var u=r(187),c=r.n(u);function l(e){this.message=e}l.prototype=new Error,l.prototype.name="InvalidCharacterError";var p="undefined"!=typeof window&&window.atob&&window.atob.bind(window)||function(e){var t=String(e).replace(/=+$/,"");if(t.length%4==1)throw new l("'atob' failed: The string to be decoded is not correctly encoded.");for(var r,n,o=0,i=0,s="";n=t.charAt(i++);~n&&(r=o%4?64*r+n:n,o++%4)?s+=String.fromCharCode(255&r>>(-2*o&6)):0)n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".indexOf(n);return s};function f(e){var t=e.replace(/-/g,"+").replace(/_/g,"/");switch(t.length%4){case 0:break;case 2:t+="==";break;case 3:t+="=";break;default:throw"Illegal base64url string!"}try{return function(e){return decodeURIComponent(p(e).replace(/(.)/g,(function(e,t){var r=t.charCodeAt(0).toString(16).toUpperCase();return r.length<2&&(r="0"+r),"%"+r})))}(t)}catch(e){return p(t)}}function d(e){this.message=e}d.prototype=new Error,d.prototype.name="InvalidTokenError";const h="default",y=/^(.+)\..+\.touchtech\.com$/,g=/^(.+)\.localhost$/;function v(e){var t;const r=e.toLowerCase(),n=null!==(t=r.match(y))&&void 0!==t?t:r.match(g);return null!==n?n[1]:h}class m{}m.SUPERADMIN="superadmin";class _{}_.UNIVERSAL="universal",_.SHOWROOM_APP="showroom-app",_.SENDOUTS_APP="sendouts-app",_.SENDOUTS_CMS_APP="sendouts-cms-app",_.MARKETING_ENGINE_APP="marketing-engine-app",_.USER_MANAGEMENT_APP="user-management-app";class S{}function b(e,t,r){for(const n of e.roles)if(n===`${t}:${r}`||n===`${t}:${_.UNIVERSAL}`||n===`${S.UNIVERSAL}:${r}`||n===`${S.UNIVERSAL}:${_.UNIVERSAL}`)return!0;return!1}function w(e,t){return e.mode===t}S.UNIVERSAL="10000001-c001-0001-0001-000000000000";var O=r(865),A=r(438),E=r(960),P=r(373),k=r(892),R=r(551),I=r(298);class j extends Error{constructor(e="Refresh token error"){super(e)}}class x extends O.BasicQueryStringUtils{parse(e){return super.parse(e,!1)}}class T extends u.EventEmitter{constructor(e){super(),this._configuration=e,this._notifier=new E.AuthorizationNotifier,this._authorizationHandler=new O.RedirectRequestHandler(new O.LocalStorageBackend,new x),this._tokenHandler=new R.BaseTokenRequestHandler(T.s_requestor),this._authorizationHandler.setAuthorizationNotifier(this._notifier),this._notifier.setAuthorizationListener(this.authorizationListener.bind(this)),window.addEventListener("storage",this.handleStorage.bind(this))}initialize(){this.loadState(),this.loadSignOutState()}authorizationListener(e,t,r){var n;return a(this,void 0,void 0,(function*(){console.debug("Authorization request complete",e,t,r);const o=null!==(n=null==t?void 0:t.state)&&void 0!==n?n:null==r?void 0:r.state,i=JSON.parse(window.atob(o));if(this.emit("authorizationComplete",{request:e,response:t,error:r,state:i}),t){let r;e.internal&&e.internal.code_verifier&&(r=e.internal.code_verifier),yield this.makeTokenRequest(t.code,r),this.emit("tokenResponse")}}))}signIn({identityProvider:e,force:t=!1,state:r}){return a(this,void 0,void 0,(function*(){this.isSignedIn()?t&&(this.signOutCore(),yield this.makeAuthorizationRequest(e,r)):yield this.makeAuthorizationRequest(e,r)}))}completeSignInIfPossible(){return a(this,void 0,void 0,(function*(){try{yield this._authorizationHandler.completeAuthorizationRequestIfPossible()}finally{window.localStorage.removeItem("appauth_current_authorization_request"),Object.keys(window.localStorage).filter((e=>e.includes("appauth_authorization"))).forEach((e=>{window.localStorage.removeItem(e)}))}}))}isSignedIn(){return!!this._tokenResponse&&this._tokenResponse.isValid(T.AUTH_EXPIRY_BUFFER)}getAccessToken(e=!1,t=0){var r,n;return a(this,void 0,void 0,(function*(){if(!e&&this._tokenResponse&&this._tokenResponse.isValid(T.AUTH_EXPIRY_BUFFER))return this._tokenResponse.accessToken;if(e&&t>0&&void 0!==(null===(r=this._tokenResponse)||void 0===r?void 0:r.issuedAt)&&!((new Date).getTime()/1e3-this._tokenResponse.issuedAt>t))return this._tokenResponse.accessToken;if(this._refreshTokenPromise)return yield this._refreshTokenPromise;{if(void 0===(null===(n=this._tokenResponse)||void 0===n?void 0:n.refreshToken))return null;let e;try{this._refreshTokenPromise=this.refreshToken(this._tokenResponse.refreshToken),e=yield this._refreshTokenPromise}finally{this._refreshTokenPromise=void 0}return e}}))}signOut({state:e}){return a(this,void 0,void 0,(function*(){if(!this._tokenResponse)return;const t=this._tokenResponse.idToken;this.signOutCore();const r=yield this.ensureServiceConfiguration(),n=this._configuration.postLogoutRedirectUri;let o=`${r.endSessionEndpoint}?id_token_hint=${t}&post_logout_redirect_uri=${n}`;e&&(o=`${o}&state=${window.btoa(JSON.stringify(e))}`),console.debug(`[AuthFlow] Signing out using post_logout_redirect_uri '${n}' (full endSession URL: '${o}') ...`),window.location.assign(o)}))}signOutCore(){this._tokenResponse=void 0,window.localStorage.removeItem(T.TOKEN_RESPONSE_KEY)}makeAuthorizationRequest(e,t){return a(this,void 0,void 0,(function*(){const r={idp:e},n={returnUri:`${window.location.pathname}${window.location.search}`,signInState:t},o=window.btoa(JSON.stringify(n)),i=new A.AuthorizationRequest({client_id:this._configuration.clientId,redirect_uri:this._configuration.redirectUri,scope:this._configuration.scope,response_type:A.AuthorizationRequest.RESPONSE_TYPE_CODE,state:o,extras:r});this._authorizationHandler.performAuthorizationRequest(yield this.ensureServiceConfiguration(),i)}))}ensureServiceConfiguration(){return a(this,void 0,void 0,(function*(){if(!this._serviceConfiguration){const e=yield P.AuthorizationServiceConfiguration.fetchFromIssuer(this._configuration.openIdIssuerUrl,T.s_requestor);this._serviceConfiguration=e}return this._serviceConfiguration}))}saveState(){this._tokenResponse&&window.localStorage.setItem(T.TOKEN_RESPONSE_KEY,JSON.stringify(this._tokenResponse.toJson()))}loadState(){const e=window.localStorage.getItem(T.TOKEN_RESPONSE_KEY);if(null!=e){const t=JSON.parse(e),r=new I.TokenResponse(t);return this._tokenResponse=r,void this.emit("tokenResponse")}window.localStorage.getItem(T.IS_REFRESHING_TOKEN_KEY)||this.emit("tokenResponseFail")}loadSignOutState(){const{state:e}=t().parse(window.location.search,{ignoreQueryPrefix:!0});if(!e)return;const r=JSON.parse(window.atob(e));this.emit("signOutStateChanged",{state:r})}makeTokenRequest(e,t){return a(this,void 0,void 0,(function*(){const r={};t&&(r.code_verifier=t);const n=new k.TokenRequest({code:e,extras:r,client_id:this._configuration.clientId,redirect_uri:this._configuration.redirectUri,grant_type:k.GRANT_TYPE_AUTHORIZATION_CODE,refresh_token:void 0}),o=yield this._tokenHandler.performTokenRequest(yield this.ensureServiceConfiguration(),n);this._tokenResponse=o,this.saveState()}))}refreshToken(e){return a(this,void 0,void 0,(function*(){console.debug("Refreshing token ..."),this._tokenResponse=void 0,window.localStorage.removeItem(T.TOKEN_RESPONSE_KEY),window.localStorage.setItem(T.IS_REFRESHING_TOKEN_KEY,"true");const t=new k.TokenRequest({client_id:this._configuration.clientId,redirect_uri:this._configuration.redirectUri,grant_type:k.GRANT_TYPE_REFRESH_TOKEN,refresh_token:e,code:void 0,extras:void 0});let r;try{r=yield this._tokenHandler.performTokenRequest(yield this.ensureServiceConfiguration(),t)}catch(e){throw new j(e instanceof Error?e.message:void 0)}finally{window.localStorage.removeItem(T.IS_REFRESHING_TOKEN_KEY)}return this._tokenResponse=r,this.saveState(),console.debug("Refreshed token --\x3e",r),r.accessToken}))}handleStorage(e){e.key===T.TOKEN_RESPONSE_KEY&&null!==e.newValue&&this.loadState()}}T.TOKEN_RESPONSE_KEY="AuthFlow:tokenResponse",T.AUTH_EXPIRY_BUFFER=-600,T.IS_REFRESHING_TOKEN_KEY="AuthFlow:isRefreshingToken",T.s_requestor=new O.FetchRequestor;class C{}C.EMAIL="email",C.GIVEN_NAME="given_name",C.FAMILY_NAME="family_name",C.ROLE="http://schemas.microsoft.com/ws/2008/06/identity/claims/role",C.MODE="mode";class N extends(c()){constructor(e){super(),this._canSignOut=!0,this._isSigningOut=!1,this._isTokenResponseFailed=!1,this._auth=new T(e),this._auth.on("tokenResponse",this.handleTokenResponse.bind(this)).on("authorizationComplete",this.handleAuthorizationComplete.bind(this)).on("tokenResponseFail",this.handleTokenResponseFail.bind(this)).on("signOutStateChanged",this.handleSignOutStateChanged.bind(this)),this._auth.initialize()}static get instance(){if(!N.s_instance)throw new Error("AuthService has not been initialized");return N.s_instance}static initialize(e){if(N.s_instance)throw new Error("AuthService has already been initialized");N.s_instance=new N(e)}static ensureClaimValue(e,t){const r=e[t];if(void 0===r)throw new Error(`Invalid access token. Missing claim '${t}'.`);return r}setUser(e){this._user!==e&&(this._user=e,this.emit("userChanged"))}setSignInState(e){this._signInState!==e&&(this._signInState=e,this.emit("signInStateChanged"))}setSignOutState(e){this._signOutState!==e&&(this._signOutState=e,this.emit("signOutStateChanged"))}setCanSignOut(e){this._canSignOut!==e&&(this._canSignOut=e,this.emit("canSignOutChanged"))}setIsSigningOut(e){this._isSigningOut!==e&&(this._isSigningOut=e,this.emit("isSigningOutChanged"))}handleTokenResponse(){return a(this,void 0,void 0,(function*(){try{this.setUser(yield this.getUser())}catch(e){this.emit("error",e)}}))}handleAuthorizationComplete(e){this.setSignInState(e.state.signInState),this.emit("authorizationComplete",e)}handleTokenResponseFail(){this._isTokenResponseFailed=!0}handleSignOutStateChanged(e){this.setSignOutState(e.state)}getUser(e=!1,t=0){var r;return a(this,void 0,void 0,(function*(){const n=yield this.getAccessTokenPrivate(e,t);if(null===n)return;let o;try{o=function(e,t){if("string"!=typeof e)throw new d("Invalid token specified");var r=!0===(t=t||{}).header?0:1;try{return JSON.parse(f(e.split(".")[r]))}catch(e){throw new d("Invalid token specified: "+e.message)}}(n)}catch(e){const t=e instanceof Error?e:void 0,r=void 0!==t?t.message:e;throw new Error(`Failed to decode access token: ${r}`,{cause:t})}const i=N.ensureClaimValue(o,C.EMAIL),s=N.ensureClaimValue(o,C.GIVEN_NAME),a=N.ensureClaimValue(o,C.FAMILY_NAME),u=null!==(r=o[C.ROLE])&&void 0!==r?r:[];return{email:i,firstName:s,lastName:a,roles:Array.isArray(u)?u:[u],mode:o[C.MODE]}}))}get user(){return this._user}get signInState(){return this._signInState}get signOutState(){return this._signOutState}get canSignOut(){return this._canSignOut}get isSigningOut(){return this._isSigningOut}get isTokenResponseFailed(){return this._isTokenResponseFailed}signIn({force:e=!1,state:t}={}){return a(this,void 0,void 0,(function*(){try{const r=v(window.location.hostname);console.debug(`[AuthService] Using identity provider '${r}' ...`),yield this._auth.signIn({identityProvider:r,force:e,state:t})}catch(e){this.emit("error",e)}}))}completeSignInIfPossible(){return a(this,void 0,void 0,(function*(){try{yield this._auth.completeSignInIfPossible()}catch(e){this.emit("error",e)}}))}getAccessToken(){return a(this,void 0,void 0,(function*(){return yield this.getAccessTokenPrivate(!1,0)}))}getAccessTokenPrivate(e,t){return a(this,void 0,void 0,(function*(){try{return yield this._auth.getAccessToken(e,t)}catch(e){return this.emit("error",e),null}}))}signOut({state:e}={}){return a(this,void 0,void 0,(function*(){try{this.setCanSignOut(!1),this.setIsSigningOut(!0),yield this._auth.signOut({state:e})}catch(e){this.emit("error",e)}}))}refreshUser(e){return a(this,void 0,void 0,(function*(){try{this.setUser(yield this.getUser(!0,e))}catch(e){this.emit("error",e)}}))}}const U=i().createContext({}),L=({children:e,authService:t,onError:r,onUserIdentified:n})=>{const[s,u]=(0,o.useState)(),[c,l]=(0,o.useState)(t.canSignOut),[p,f]=(0,o.useState)(t.isSigningOut),[d,h]=(0,o.useState)(t.signInState),[y,g]=(0,o.useState)(t.signOutState);(0,o.useEffect)((()=>{function e(){const e=t.user;e&&(u(e),n(e))}e();const o=()=>{e()},i=()=>{h(t.signInState)},s=()=>{g(t.signOutState)},c=e=>a(void 0,void 0,void 0,(function*(){if(e instanceof j)return yield t.signIn();r(e)})),p=()=>{l(t.canSignOut)},d=()=>{f(t.isSigningOut)};return t.on("userChanged",o).on("signInStateChanged",i).on("signOutStateChanged",s).on("error",c).on("canSignOutChanged",p).on("isSigningOutChanged",d),()=>{t.off("userChanged",o).off("signInStateChanged",i).off("signOutStateChanged",s).off("error",c).off("canSignOutChanged",p).off("isSigningOutChanged",d)}}),[t,r,n]);const v=(0,o.useMemo)((()=>({user:s,authService:t,signInState:d,signOutState:y,canSignOut:c,isSigningOut:p})),[t,c,p,d,y,s]);return i().createElement(U.Provider,{value:v},e)},M=i().createContext({}),F=({children:e,authorization:t,unauthorizedUrl:r})=>{const n=(0,o.useMemo)((()=>({authorization:t,unauthorizedUrl:r})),[t,r]);return i().createElement(M.Provider,{value:n},e)},z=function({skipAuthorization:e,children:r}){const n=(0,s.useLocation)(),{user:i,authService:a}=(0,o.useContext)(U),{authorization:u,unauthorizedUrl:c}=(0,o.useContext)(M),{state:l}=(0,o.useMemo)((()=>t().parse(n.search,{ignoreQueryPrefix:!0})),[n.search]);return i?e||function(e,t){return function(e){const t=e;return void 0!==t.tenantId&&void 0!==t.privilege}(t)?b(e,t.tenantId,t.privilege):!!function(e){return void 0!==e.mode}(t)&&w(e,t.mode)}(i,u)?r:(console.debug("[Protected] User not authorized to access route; navigating to unauthorized path ..."),window.location.assign(c),null):l?(window.location.assign(l),null):a.isTokenResponseFailed?(a.signIn(),null):null},q=require("@touchtech/baselayer-ui"),D="access_denied",B={general_error:"General error.",invalid_confirmation:"Invalid confirmation.",idp_not_specified:"IDP not provided.",idp_not_recognized:"IDP not recognized.",federation_not_found:"Federation not found.",external_idp_token_fetch:"External IDP token fetch.",external_idp_token_contents:"External IDP token contents.",external_idp_token_fields:"External IDP token fields.",verificator_not_found:"Verificator not found.",no_user_nor_proto_found:"No user nor proto found.",invite_not_recognized:"Invite not recognized.",user_not_created:"User not created."},H={[D]:"Access denied.",account_selection_required:"Account selection required.",consent_required:"Consent required.",interaction_required:"Interaction required.",login_required:"Login required."},G=function({errorMessage:e,navigateTo:t}){const r=(0,s.useNavigate)();return i().createElement("div",{className:"gJiT0wPP9YyRVDsYxWqk"},i().createElement("h1",null,"Sorry, something went wrong."),i().createElement("h3",null,e),i().createElement(q.Button,{onClick:()=>r(t,{replace:!0}),rounded:!0,inverted:!0},"Continue"))},$=function({basename:e}){const t=(0,s.useNavigate)(),{authService:r,user:n}=(0,o.useContext)(U),[{error:a,state:u},c]=(0,o.useState)({error:null,state:null}),l=(0,o.useMemo)((()=>{const t=null==u?void 0:u.returnUri;if(null==t?void 0:t.startsWith(e)){const r=t.substring(e.length);if("?"===r[0])return`/${r}`;if(r.length)return r}return"/"}),[u,e]),p=(0,o.useMemo)((()=>{var e;if(a){const{error:t,errorDescription:r}=a;if(t===D){const e=r;if(void 0!==e){const t=B[e];if(t)return t}}return null!==(e=null!=r?r:H[t])&&void 0!==e?e:`An unknown error occurred. (Error code: '${t}'.)`}}),[a]);return(0,o.useEffect)((()=>{n&&t(l,{replace:!0})}),[t,l,n]),(0,o.useEffect)((()=>{const e=({error:e,state:t})=>{c({error:e,state:t})};return r.on("authorizationComplete",e),r.completeSignInIfPossible(),()=>{r.off("authorizationComplete",e)}}),[r]),i().createElement("div",{className:"C_297mJYGNkE35qpiNZS"},null!=p?i().createElement(G,{errorMessage:p,navigateTo:l}):i().createElement(q.Icon,{src:"data:image/svg+xml,%3c%3fxml version='1.0' encoding='UTF-8' standalone='no'%3f%3e %3c!DOCTYPE svg PUBLIC '-//W3C//DTD SVG 1.1//EN' 'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd'%3e %3csvg width='100%25' height='100%25' viewBox='0 0 46 46' version='1.1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' xml:space='preserve' xmlns:serif='http://www.serif.com/' style='fill-rule:evenodd%3bclip-rule:evenodd%3bstroke-linejoin:round%3bstroke-miterlimit:2%3b'%3e %3cg transform='matrix(1%2c0%2c0%2c1%2c-27%2c-27)'%3e %3cpath d='M73%2c50C73%2c37.3 62.7%2c27 50%2c27C37.3%2c27 27%2c37.3 27%2c50M30.9%2c50C30.9%2c39.5 39.4%2c30.9 50%2c30.9C60.6%2c30.9 69.1%2c39.5 69.1%2c50' style='fill-rule:nonzero%3b'%3e %3canimateTransform attributeName='transform' attributeType='XML' type='rotate' dur='1s' from='0 50 50' to='360 50 50' repeatCount='indefinite' /%3e %3c/path%3e %3c/g%3e %3c/svg%3e",alt:"Icon",size:"xlarge"}))}})();var o=exports;for(var i in n)o[i]=n[i];n.__esModule&&Object.defineProperty(o,"__esModule",{value:!0})})();
|
package/dist/types/index.d.ts
CHANGED
package/dist/types/user.d.ts
CHANGED
package/dist/utils/roles.d.ts
CHANGED
|
@@ -1,2 +1,3 @@
|
|
|
1
1
|
import { User } from "../types";
|
|
2
|
-
export declare function
|
|
2
|
+
export declare function userHasTenantAccess(user: User, tenantId: string, privilege: string): boolean;
|
|
3
|
+
export declare function userHasMode(user: User, mode: string): boolean;
|
package/package.json
CHANGED
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
/*! *****************************************************************************
|
|
2
|
-
Copyright (c) Microsoft Corporation.
|
|
3
|
-
|
|
4
|
-
Permission to use, copy, modify, and/or distribute this software for any
|
|
5
|
-
purpose with or without fee is hereby granted.
|
|
6
|
-
|
|
7
|
-
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
|
8
|
-
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
|
9
|
-
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
|
10
|
-
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
|
11
|
-
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
12
|
-
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
13
|
-
PERFORMANCE OF THIS SOFTWARE.
|
|
14
|
-
***************************************************************************** */
|
|
15
|
-
|
|
16
|
-
/**!
|
|
17
|
-
* hotkeys-js v3.9.3
|
|
18
|
-
* A simple micro-library for defining and dispatching keyboard shortcuts. It has no dependencies.
|
|
19
|
-
*
|
|
20
|
-
* Copyright (c) 2022 kenny wong <wowohoo@qq.com>
|
|
21
|
-
* http://jaywcjlove.github.io/hotkeys
|
|
22
|
-
* Licensed under the MIT license
|
|
23
|
-
*/
|