(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[825],{51247:function(ee,et,en){"use strict";en.d(et,{c:function(){return DynamoDBClient}}),function(ee){ee.HEADER="header",ee.QUERY="query"}(ei||(ei={})),function(ee){ee.HEADER="header",ee.QUERY="query"}(eo||(eo={})),function(ee){ee.HTTP="http",ee.HTTPS="https"}(ea||(ea={})),function(ee){ee.MD5="md5",ee.CRC32="crc32",ee.CRC32C="crc32c",ee.SHA1="sha1",ee.SHA256="sha256"}(es||(es={})),function(ee){ee[ee.HEADER=0]="HEADER",ee[ee.TRAILER=1]="TRAILER"}(eu||(eu={})),function(ee){ee.PROFILE="profile",ee.SSO_SESSION="sso-session",ee.SERVICES="services"}(ec||(ec={})),function(ee){ee.HTTP_0_9="http/0.9",ee.HTTP_1_0="http/1.0",ee.TDS_8_0="tds/8.0"}(ed||(ed={}));var ei,eo,ea,es,eu,ec,ed,ef,ep,eh,ey=en(96675),em=en.n(ey);let EndpointCache=class EndpointCache{constructor(ee){this.cache=new(em())(ee)}getEndpoint(ee){let et=this.get(ee);if(!et||0===et.length)return;let en=et.map(ee=>ee.Address);return en[Math.floor(Math.random()*en.length)]}get(ee){if(!this.has(ee))return;let et=this.cache.get(ee);if(!et)return;let en=Date.now(),ei=et.filter(ee=>en({Address:ee,Expires:en+6e4*et})))}delete(ee){this.cache.set(ee,[])}has(ee){if(!this.cache.has(ee))return!1;let et=this.cache.peek(ee);return!!et&&et.length>0}clear(){this.cache.clear()}};let resolveEndpointDiscoveryConfig=(ee,{endpointDiscoveryCommandCtor:et})=>({...ee,endpointDiscoveryCommandCtor:et,endpointCache:new EndpointCache(ee.endpointCacheSize??1e3),endpointDiscoveryEnabled:void 0!==ee.endpointDiscoveryEnabled?()=>Promise.resolve(ee.endpointDiscoveryEnabled):ee.endpointDiscoveryEnabledProvider,isClientEndpointDiscoveryEnabled:void 0!==ee.endpointDiscoveryEnabled});var eg=en(43979);function resolveHostHeaderConfig(ee){return ee}let hostHeaderMiddleware=ee=>et=>async en=>{if(!eg.aW.isInstance(en.request))return et(en);let{request:ei}=en,{handlerProtocol:eo=""}=ee.requestHandler.metadata||{};if(eo.indexOf("h2")>=0&&!ei.headers[":authority"])delete ei.headers.host,ei.headers[":authority"]=ei.hostname+(ei.port?":"+ei.port:"");else if(!ei.headers.host){let ee=ei.hostname;null!=ei.port&&(ee+=`:${ei.port}`),ei.headers.host=ee}return et(en)},eb={name:"hostHeaderMiddleware",step:"build",priority:"low",tags:["HOST"],override:!0},getHostHeaderPlugin=ee=>({applyToStack:et=>{et.add(hostHeaderMiddleware(ee),eb)}}),loggerMiddleware=()=>(ee,et)=>async en=>{try{let ei=await ee(en),{clientName:eo,commandName:ea,logger:es,dynamoDbDocumentClientOptions:eu={}}=et,{overrideInputFilterSensitiveLog:ec,overrideOutputFilterSensitiveLog:ed}=eu,ef=ec??et.inputFilterSensitiveLog,ep=ed??et.outputFilterSensitiveLog,{$metadata:eh,...ey}=ei.output;return es?.info?.({clientName:eo,commandName:ea,input:ef(en.input),output:ep(ey),metadata:eh}),ei}catch(ec){let{clientName:ee,commandName:ei,logger:eo,dynamoDbDocumentClientOptions:ea={}}=et,{overrideInputFilterSensitiveLog:es}=ea,eu=es??et.inputFilterSensitiveLog;throw eo?.error?.({clientName:ee,commandName:ei,input:eu(en.input),error:ec,metadata:ec.$metadata}),ec}},ev={name:"loggerMiddleware",tags:["LOGGER"],step:"initialize",override:!0},getLoggerPlugin=ee=>({applyToStack:ee=>{ee.add(loggerMiddleware(),ev)}});var e_=en(34155);let ew="X-Amzn-Trace-Id",eS="AWS_LAMBDA_FUNCTION_NAME",eE="_X_AMZN_TRACE_ID",recursionDetectionMiddleware=ee=>et=>async en=>{let{request:ei}=en;if(!eg.aW.isInstance(ei)||"node"!==ee.runtime||ei.headers.hasOwnProperty(ew))return et(en);let eo=e_.env[eS],ea=e_.env[eE],nonEmptyString=ee=>"string"==typeof ee&&ee.length>0;return nonEmptyString(eo)&&nonEmptyString(ea)&&(ei.headers[ew]=ea),et({...en,request:ei})},eA={step:"build",tags:["RECURSION_DETECTION"],name:"recursionDetectionMiddleware",override:!0,priority:"low"},getRecursionDetectionPlugin=ee=>({applyToStack:et=>{et.add(recursionDetectionMiddleware(ee),eA)}});function resolveUserAgentConfig(ee){return{...ee,customUserAgent:"string"==typeof ee.customUserAgent?[[ee.customUserAgent]]:ee.customUserAgent}}let EndpointCache_EndpointCache=class EndpointCache_EndpointCache{constructor({size:ee,params:et}){this.data=new Map,this.parameters=[],this.capacity=ee??50,et&&(this.parameters=et)}get(ee,et){let en=this.hash(ee);if(!1===en)return et();if(!this.data.has(en)){if(this.data.size>this.capacity+10){let ee=this.data.keys(),et=0;for(;;){let{value:en,done:ei}=ee.next();if(this.data.delete(en),ei||++et>10)break}}this.data.set(en,et())}return this.data.get(en)}size(){return this.data.size}hash(ee){let et="",{parameters:en}=this;if(0===en.length)return!1;for(let ei of en){let en=String(ee[ei]??"");if(en.includes("|;"))return!1;et+=en+"|;"}return et}};let e$=RegExp("^(?:25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]\\d|\\d)(?:\\.(?:25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]\\d|\\d)){3}$"),isIpAddress=ee=>e$.test(ee)||ee.startsWith("[")&&ee.endsWith("]"),ex=RegExp("^(?!.*-$)(?!-)[a-zA-Z0-9-]{1,63}$"),isValidHostLabel=(ee,et=!1)=>{if(!et)return ex.test(ee);let en=ee.split(".");for(let ee of en)if(!isValidHostLabel(ee))return!1;return!0},eC={},ek="endpoints";function toDebugString(ee){return"object"!=typeof ee||null==ee?ee:"ref"in ee?`$${toDebugString(ee.ref)}`:"fn"in ee?`${ee.fn}(${(ee.argv||[]).map(toDebugString).join(", ")})`:JSON.stringify(ee,null,2)}let EndpointError=class EndpointError extends Error{constructor(ee){super(ee),this.name="EndpointError"}};let booleanEquals=(ee,et)=>ee===et,getAttrPathList=ee=>{let et=ee.split("."),en=[];for(let ei of et){let et=ei.indexOf("[");if(-1!==et){if(ei.indexOf("]")!==ei.length-1)throw new EndpointError(`Path: '${ee}' does not end with ']'`);let eo=ei.slice(et+1,-1);if(Number.isNaN(parseInt(eo)))throw new EndpointError(`Invalid array index: '${eo}' in path: '${ee}'`);0!==et&&en.push(ei.slice(0,et)),en.push(eo)}else en.push(ei)}return en},getAttr=(ee,et)=>getAttrPathList(et).reduce((en,ei)=>{if("object"!=typeof en)throw new EndpointError(`Index '${ei}' in '${et}' not found in '${JSON.stringify(ee)}'`);return Array.isArray(en)?en[parseInt(ei)]:en[ei]},ee),isSet=ee=>null!=ee,not=ee=>!ee;var eO=en(63518);let eT={[eO.cj.HTTP]:80,[eO.cj.HTTPS]:443},parseURL=ee=>{let et=(()=>{try{if(ee instanceof URL)return ee;if("object"==typeof ee&&"hostname"in ee){let{hostname:et,port:en,protocol:ei="",path:eo="",query:ea={}}=ee,es=new URL(`${ei}//${et}${en?`:${en}`:""}${eo}`);return es.search=Object.entries(ea).map(([ee,et])=>`${ee}=${et}`).join("&"),es}return new URL(ee)}catch(ee){return null}})();if(!et)return console.error(`Unable to parse ${JSON.stringify(ee)} as a whatwg URL.`),null;let en=et.href,{host:ei,hostname:eo,pathname:ea,protocol:es,search:eu}=et;if(eu)return null;let ec=es.slice(0,-1);if(!Object.values(eO.cj).includes(ec))return null;let ed=isIpAddress(eo),ef=en.includes(`${ei}:${eT[ec]}`)||"string"==typeof ee&&ee.includes(`${ei}:${eT[ec]}`),ep=`${ei}${ef?`:${eT[ec]}`:""}`;return{scheme:ec,authority:ep,path:ea,normalizedPath:ea.endsWith("/")?ea:`${ea}/`,isIp:ed}},stringEquals=(ee,et)=>ee===et,substring=(ee,et,en,ei)=>et>=en||ee.lengthencodeURIComponent(ee).replace(/[!*'()]/g,ee=>`%${ee.charCodeAt(0).toString(16).toUpperCase()}`),eP={booleanEquals:booleanEquals,getAttr:getAttr,isSet:isSet,isValidHostLabel:isValidHostLabel,not:not,parseURL:parseURL,stringEquals:stringEquals,substring:substring,uriEncode:uriEncode},evaluateTemplate=(ee,et)=>{let en=[],ei={...et.endpointParams,...et.referenceRecord},eo=0;for(;eo{let en={...et.endpointParams,...et.referenceRecord};return en[ee]},evaluateExpression=(ee,et,en)=>{if("string"==typeof ee)return evaluateTemplate(ee,en);if(ee.fn)return callFunction(ee,en);if(ee.ref)return getReferenceValue(ee,en);throw new EndpointError(`'${et}': ${String(ee)} is not a string, function or reference.`)},callFunction=({fn:ee,argv:et},en)=>{let ei=et.map(ee=>["boolean","number"].includes(typeof ee)?ee:evaluateExpression(ee,"arg",en)),eo=ee.split(".");return eo[0]in eC&&null!=eo[1]?eC[eo[0]][eo[1]](...ei):eP[ee](...ei)},evaluateCondition=({assign:ee,...et},en)=>{if(ee&&ee in en.referenceRecord)throw new EndpointError(`'${ee}' is already defined in Reference Record.`);let ei=callFunction(et,en);return en.logger?.debug?.(`${ek} evaluateCondition: ${toDebugString(et)} = ${toDebugString(ei)}`),{result:""===ei||!!ei,...null!=ee&&{toAssign:{name:ee,value:ei}}}},evaluateConditions=(ee=[],et)=>{let en={};for(let ei of ee){let{result:ee,toAssign:eo}=evaluateCondition(ei,{...et,referenceRecord:{...et.referenceRecord,...en}});if(!ee)return{result:ee};eo&&(en[eo.name]=eo.value,et.logger?.debug?.(`${ek} assign: ${eo.name} := ${toDebugString(eo.value)}`))}return{result:!0,referenceRecord:en}},getEndpointHeaders=(ee,et)=>Object.entries(ee).reduce((ee,[en,ei])=>({...ee,[en]:ei.map(ee=>{let ei=evaluateExpression(ee,"Header value entry",et);if("string"!=typeof ei)throw new EndpointError(`Header '${en}' value '${ei}' is not a string`);return ei})}),{}),getEndpointProperty=(ee,et)=>{if(Array.isArray(ee))return ee.map(ee=>getEndpointProperty(ee,et));switch(typeof ee){case"string":return evaluateTemplate(ee,et);case"object":if(null===ee)throw new EndpointError(`Unexpected endpoint property: ${ee}`);return getEndpointProperties(ee,et);case"boolean":return ee;default:throw new EndpointError(`Unexpected endpoint property type: ${typeof ee}`)}},getEndpointProperties=(ee,et)=>Object.entries(ee).reduce((ee,[en,ei])=>({...ee,[en]:getEndpointProperty(ei,et)}),{}),getEndpointUrl=(ee,et)=>{let en=evaluateExpression(ee,"Endpoint URL",et);if("string"==typeof en)try{return new URL(en)}catch(ee){throw console.error(`Failed to construct URL with ${en}`,ee),ee}throw new EndpointError(`Endpoint URL must be a string, got ${typeof en}`)},evaluateEndpointRule=(ee,et)=>{let{conditions:en,endpoint:ei}=ee,{result:eo,referenceRecord:ea}=evaluateConditions(en,et);if(!eo)return;let es={...et,referenceRecord:{...et.referenceRecord,...ea}},{url:eu,properties:ec,headers:ed}=ei;return et.logger?.debug?.(`${ek} Resolving endpoint from template: ${toDebugString(ei)}`),{...void 0!=ed&&{headers:getEndpointHeaders(ed,es)},...void 0!=ec&&{properties:getEndpointProperties(ec,es)},url:getEndpointUrl(eu,es)}},evaluateErrorRule=(ee,et)=>{let{conditions:en,error:ei}=ee,{result:eo,referenceRecord:ea}=evaluateConditions(en,et);if(eo)throw new EndpointError(evaluateExpression(ei,"Error",{...et,referenceRecord:{...et.referenceRecord,...ea}}))},evaluateTreeRule=(ee,et)=>{let{conditions:en,rules:ei}=ee,{result:eo,referenceRecord:ea}=evaluateConditions(en,et);if(eo)return evaluateRules(ei,{...et,referenceRecord:{...et.referenceRecord,...ea}})},evaluateRules=(ee,et)=>{for(let en of ee)if("endpoint"===en.type){let ee=evaluateEndpointRule(en,et);if(ee)return ee}else if("error"===en.type)evaluateErrorRule(en,et);else if("tree"===en.type){let ee=evaluateTreeRule(en,et);if(ee)return ee}else throw new EndpointError(`Unknown endpoint rule: ${en}`);throw new EndpointError("Rules evaluation failed")},resolveEndpoint=(ee,et)=>{let{endpointParams:en,logger:ei}=et,{parameters:eo,rules:ea}=ee;et.logger?.debug?.(`${ek} Initial EndpointParams: ${toDebugString(en)}`);let es=Object.entries(eo).filter(([,ee])=>null!=ee.default).map(([ee,et])=>[ee,et.default]);if(es.length>0)for(let[ee,et]of es)en[ee]=en[ee]??et;let eu=Object.entries(eo).filter(([,ee])=>ee.required).map(([ee])=>ee);for(let ee of eu)if(null==en[ee])throw new EndpointError(`Missing required parameter: '${ee}'`);let ec=evaluateRules(ea,{endpointParams:en,logger:ei,referenceRecord:{}});return et.logger?.debug?.(`${ek} Resolved endpoint: ${toDebugString(ec)}`),ec},isVirtualHostableS3Bucket=(ee,et=!1)=>{if(et){for(let et of ee.split("."))if(!isVirtualHostableS3Bucket(et))return!1;return!0}return!(!isValidHostLabel(ee)||ee.length<3||ee.length>63||ee!==ee.toLowerCase()||isIpAddress(ee))},eR=":",eI="/",parseArn=ee=>{let et=ee.split(eR);if(et.length<6)return null;let[en,ei,eo,ea,es,...eu]=et;if("arn"!==en||""===ei||""===eo||""===eu.join(eR))return null;let ec=eu.map(ee=>ee.split(eI)).flat();return{partition:ei,service:eo,region:ea,accountId:es,resourceId:ec}},eN=JSON.parse('{"partitions":[{"id":"aws","outputs":{"dnsSuffix":"amazonaws.com","dualStackDnsSuffix":"api.aws","implicitGlobalRegion":"us-east-1","name":"aws","supportsDualStack":true,"supportsFIPS":true},"regionRegex":"^(us|eu|ap|sa|ca|me|af|il|mx)\\\\-\\\\w+\\\\-\\\\d+$","regions":{"af-south-1":{"description":"Africa (Cape Town)"},"ap-east-1":{"description":"Asia Pacific (Hong Kong)"},"ap-northeast-1":{"description":"Asia Pacific (Tokyo)"},"ap-northeast-2":{"description":"Asia Pacific (Seoul)"},"ap-northeast-3":{"description":"Asia Pacific (Osaka)"},"ap-south-1":{"description":"Asia Pacific (Mumbai)"},"ap-south-2":{"description":"Asia Pacific (Hyderabad)"},"ap-southeast-1":{"description":"Asia Pacific (Singapore)"},"ap-southeast-2":{"description":"Asia Pacific (Sydney)"},"ap-southeast-3":{"description":"Asia Pacific (Jakarta)"},"ap-southeast-4":{"description":"Asia Pacific (Melbourne)"},"ap-southeast-5":{"description":"Asia Pacific (Malaysia)"},"aws-global":{"description":"AWS Standard global region"},"ca-central-1":{"description":"Canada (Central)"},"ca-west-1":{"description":"Canada West (Calgary)"},"eu-central-1":{"description":"Europe (Frankfurt)"},"eu-central-2":{"description":"Europe (Zurich)"},"eu-north-1":{"description":"Europe (Stockholm)"},"eu-south-1":{"description":"Europe (Milan)"},"eu-south-2":{"description":"Europe (Spain)"},"eu-west-1":{"description":"Europe (Ireland)"},"eu-west-2":{"description":"Europe (London)"},"eu-west-3":{"description":"Europe (Paris)"},"il-central-1":{"description":"Israel (Tel Aviv)"},"me-central-1":{"description":"Middle East (UAE)"},"me-south-1":{"description":"Middle East (Bahrain)"},"sa-east-1":{"description":"South America (Sao Paulo)"},"us-east-1":{"description":"US East (N. Virginia)"},"us-east-2":{"description":"US East (Ohio)"},"us-west-1":{"description":"US West (N. California)"},"us-west-2":{"description":"US West (Oregon)"}}},{"id":"aws-cn","outputs":{"dnsSuffix":"amazonaws.com.cn","dualStackDnsSuffix":"api.amazonwebservices.com.cn","implicitGlobalRegion":"cn-northwest-1","name":"aws-cn","supportsDualStack":true,"supportsFIPS":true},"regionRegex":"^cn\\\\-\\\\w+\\\\-\\\\d+$","regions":{"aws-cn-global":{"description":"AWS China global region"},"cn-north-1":{"description":"China (Beijing)"},"cn-northwest-1":{"description":"China (Ningxia)"}}},{"id":"aws-us-gov","outputs":{"dnsSuffix":"amazonaws.com","dualStackDnsSuffix":"api.aws","implicitGlobalRegion":"us-gov-west-1","name":"aws-us-gov","supportsDualStack":true,"supportsFIPS":true},"regionRegex":"^us\\\\-gov\\\\-\\\\w+\\\\-\\\\d+$","regions":{"aws-us-gov-global":{"description":"AWS GovCloud (US) global region"},"us-gov-east-1":{"description":"AWS GovCloud (US-East)"},"us-gov-west-1":{"description":"AWS GovCloud (US-West)"}}},{"id":"aws-iso","outputs":{"dnsSuffix":"c2s.ic.gov","dualStackDnsSuffix":"c2s.ic.gov","implicitGlobalRegion":"us-iso-east-1","name":"aws-iso","supportsDualStack":false,"supportsFIPS":true},"regionRegex":"^us\\\\-iso\\\\-\\\\w+\\\\-\\\\d+$","regions":{"aws-iso-global":{"description":"AWS ISO (US) global region"},"us-iso-east-1":{"description":"US ISO East"},"us-iso-west-1":{"description":"US ISO WEST"}}},{"id":"aws-iso-b","outputs":{"dnsSuffix":"sc2s.sgov.gov","dualStackDnsSuffix":"sc2s.sgov.gov","implicitGlobalRegion":"us-isob-east-1","name":"aws-iso-b","supportsDualStack":false,"supportsFIPS":true},"regionRegex":"^us\\\\-isob\\\\-\\\\w+\\\\-\\\\d+$","regions":{"aws-iso-b-global":{"description":"AWS ISOB (US) global region"},"us-isob-east-1":{"description":"US ISOB East (Ohio)"}}},{"id":"aws-iso-e","outputs":{"dnsSuffix":"cloud.adc-e.uk","dualStackDnsSuffix":"cloud.adc-e.uk","implicitGlobalRegion":"eu-isoe-west-1","name":"aws-iso-e","supportsDualStack":false,"supportsFIPS":true},"regionRegex":"^eu\\\\-isoe\\\\-\\\\w+\\\\-\\\\d+$","regions":{"eu-isoe-west-1":{"description":"EU ISOE West"}}},{"id":"aws-iso-f","outputs":{"dnsSuffix":"csp.hci.ic.gov","dualStackDnsSuffix":"csp.hci.ic.gov","implicitGlobalRegion":"us-isof-south-1","name":"aws-iso-f","supportsDualStack":false,"supportsFIPS":true},"regionRegex":"^us\\\\-isof\\\\-\\\\w+\\\\-\\\\d+$","regions":{}}],"version":"1.1"}'),eM="",partition=ee=>{let{partitions:et}=eN;for(let en of et){let{regions:et,outputs:ei}=en;for(let[en,eo]of Object.entries(et))if(en===ee)return{...ei,...eo}}for(let en of et){let{regionRegex:et,outputs:ei}=en;if(new RegExp(et).test(ee))return{...ei}}let en=et.find(ee=>"aws"===ee.id);if(!en)throw Error("Provided region was not found in the partition array or regex, and default partition with id 'aws' doesn't exist.");return{...en.outputs}},getUserAgentPrefix=()=>eM,ej={isVirtualHostableS3Bucket:isVirtualHostableS3Bucket,parseArn:parseArn,partition:partition};eC.aws=ej;let eD="user-agent",eB="x-amz-user-agent",eU=" ",eL="/",eF=/[^\!\$\%\&\'\*\+\-\.\^\_\`\|\~\d\w]/g,eW=/[^\!\$\%\&\'\*\+\-\.\^\_\`\|\~\d\w\#]/g,eH="-",userAgentMiddleware=ee=>(et,en)=>async ei=>{let{request:eo}=ei;if(!eg.aW.isInstance(eo))return et(ei);let{headers:ea}=eo,es=en?.userAgent?.map(escapeUserAgent)||[],eu=(await ee.defaultUserAgentProvider()).map(escapeUserAgent),ec=ee?.customUserAgent?.map(escapeUserAgent)||[],ed=getUserAgentPrefix(),ef=(ed?[ed]:[]).concat([...eu,...es,...ec]).join(eU),ep=[...eu.filter(ee=>ee.startsWith("aws-sdk-")),...ec].join(eU);return"browser"!==ee.runtime?(ep&&(ea[eB]=ea[eB]?`${ea[eD]} ${ep}`:ep),ea[eD]=ef):ea[eB]=ef,et({...ei,request:eo})},escapeUserAgent=ee=>{let et=ee[0].split(eL).map(ee=>ee.replace(eF,eH)).join(eL),en=ee[1]?.replace(eW,eH),ei=et.indexOf(eL),eo=et.substring(0,ei),ea=et.substring(ei+1);return"api"===eo&&(ea=ea.toLowerCase()),[eo,ea,en].filter(ee=>ee&&ee.length>0).reduce((ee,et,en)=>{switch(en){case 0:return et;case 1:return`${ee}/${et}`;default:return`${ee}#${et}`}},"")},eq={name:"getUserAgentMiddleware",step:"build",priority:"low",tags:["SET_USER_AGENT","USER_AGENT"],override:!0},getUserAgentPlugin=ee=>({applyToStack:et=>{et.add(userAgentMiddleware(ee),eq)}});!function(ee){ee.ENV="env",ee.CONFIG="shared config entry"}(ef||(ef={}));let eV=!1,eK=!1;var ez=en(61032);let isFipsRegion=ee=>"string"==typeof ee&&(ee.startsWith("fips-")||ee.endsWith("-fips")),getRealRegion=ee=>isFipsRegion(ee)?["fips-aws-global","aws-fips"].includes(ee)?"us-east-1":ee.replace(/fips-(dkr-|prod-)?|-fips/,""):ee,resolveRegionConfig=ee=>{let{region:et,useFipsEndpoint:en}=ee;if(!et)throw Error("Region is missing");return{...ee,region:async()=>{if("string"==typeof et)return getRealRegion(et);let ee=await et();return getRealRegion(ee)},useFipsEndpoint:async()=>{let ee="string"==typeof et?et:await et();return!!isFipsRegion(ee)||("function"!=typeof en?Promise.resolve(!!en):en())}}};var eJ=en(17605);let eG="content-length";function contentLengthMiddleware(ee){return et=>async en=>{let ei=en.request;if(eg.aW.isInstance(ei)){let{body:et,headers:en}=ei;if(et&&-1===Object.keys(en).map(ee=>ee.toLowerCase()).indexOf(eG))try{let en=ee(et);ei.headers={...ei.headers,[eG]:String(en)}}catch(ee){}}return et({...en,request:ei})}}let eY={step:"build",tags:["SET_CONTENT_LENGTH","CONTENT_LENGTH"],name:"contentLengthMiddleware",override:!0},getContentLengthPlugin=ee=>({applyToStack:et=>{et.add(contentLengthMiddleware(ee.bodyLengthChecker),eY)}});var eZ=en(21093);!function(ee){ee.STANDARD="standard",ee.ADAPTIVE="adaptive"}(ep||(ep={}));let eX=3,eQ=ep.STANDARD,e0=["BandwidthLimitExceeded","EC2ThrottledException","LimitExceededException","PriorRequestNotComplete","ProvisionedThroughputExceededException","RequestLimitExceeded","RequestThrottled","RequestThrottledException","SlowDown","ThrottledException","Throttling","ThrottlingException","TooManyRequestsException","TransactionInProgressException"],e1=["TimeoutError","RequestTimeout","RequestTimeoutException"],e2=[500,502,503,504],e3=["ECONNRESET","ECONNREFUSED","EPIPE","ETIMEDOUT"],isClockSkewCorrectedError=ee=>ee.$metadata?.clockSkewCorrected,dist_es_isThrottlingError=ee=>ee.$metadata?.httpStatusCode===429||e0.includes(ee.name)||ee.$retryable?.throttling==!0,isTransientError=ee=>isClockSkewCorrectedError(ee)||e1.includes(ee.name)||e3.includes(ee?.code||"")||e2.includes(ee.$metadata?.httpStatusCode||0),isServerError=ee=>{if(ee.$metadata?.httpStatusCode!==void 0){let et=ee.$metadata.httpStatusCode;if(500<=et&&et<=599&&!isTransientError(ee))return!0}return!1};let DefaultRateLimiter_DefaultRateLimiter=class DefaultRateLimiter_DefaultRateLimiter{constructor(ee){this.currentCapacity=0,this.enabled=!1,this.lastMaxRate=0,this.measuredTxRate=0,this.requestCount=0,this.lastTimestamp=0,this.timeWindow=0,this.beta=ee?.beta??.7,this.minCapacity=ee?.minCapacity??1,this.minFillRate=ee?.minFillRate??.5,this.scaleConstant=ee?.scaleConstant??.4,this.smooth=ee?.smooth??.8;let et=this.getCurrentTimeInSeconds();this.lastThrottleTime=et,this.lastTxRateBucket=Math.floor(this.getCurrentTimeInSeconds()),this.fillRate=this.minFillRate,this.maxCapacity=this.minCapacity}getCurrentTimeInSeconds(){return Date.now()/1e3}async getSendToken(){return this.acquireTokenBucket(1)}async acquireTokenBucket(ee){if(this.enabled){if(this.refillTokenBucket(),ee>this.currentCapacity){let et=(ee-this.currentCapacity)/this.fillRate*1e3;await new Promise(ee=>setTimeout(ee,et))}this.currentCapacity=this.currentCapacity-ee}}refillTokenBucket(){let ee=this.getCurrentTimeInSeconds();if(!this.lastTimestamp){this.lastTimestamp=ee;return}let et=(ee-this.lastTimestamp)*this.fillRate;this.currentCapacity=Math.min(this.maxCapacity,this.currentCapacity+et),this.lastTimestamp=ee}updateClientSendingRate(ee){let et;if(this.updateMeasuredRate(),dist_es_isThrottlingError(ee)){let ee=this.enabled?Math.min(this.measuredTxRate,this.fillRate):this.measuredTxRate;this.lastMaxRate=ee,this.calculateTimeWindow(),this.lastThrottleTime=this.getCurrentTimeInSeconds(),et=this.cubicThrottle(ee),this.enableTokenBucket()}else this.calculateTimeWindow(),et=this.cubicSuccess(this.getCurrentTimeInSeconds());let en=Math.min(et,2*this.measuredTxRate);this.updateTokenBucketRate(en)}calculateTimeWindow(){this.timeWindow=this.getPrecise(Math.pow(this.lastMaxRate*(1-this.beta)/this.scaleConstant,1/3))}cubicThrottle(ee){return this.getPrecise(ee*this.beta)}cubicSuccess(ee){return this.getPrecise(this.scaleConstant*Math.pow(ee-this.lastThrottleTime-this.timeWindow,3)+this.lastMaxRate)}enableTokenBucket(){this.enabled=!0}updateTokenBucketRate(ee){this.refillTokenBucket(),this.fillRate=Math.max(ee,this.minFillRate),this.maxCapacity=Math.max(ee,this.minCapacity),this.currentCapacity=Math.min(this.currentCapacity,this.maxCapacity)}updateMeasuredRate(){let ee=this.getCurrentTimeInSeconds(),et=Math.floor(2*ee)/2;if(this.requestCount++,et>this.lastTxRateBucket){let ee=this.requestCount/(et-this.lastTxRateBucket);this.measuredTxRate=this.getPrecise(ee*this.smooth+this.measuredTxRate*(1-this.smooth)),this.requestCount=0,this.lastTxRateBucket=et}}getPrecise(ee){return parseFloat(ee.toFixed(8))}};let e4=100,e8=2e4,e6=500,e5=500,e9=5,e7=10,te=1,tt="amz-sdk-invocation-id",tr="amz-sdk-request",getDefaultRetryBackoffStrategy=()=>{let ee=e4,computeNextBackoffDelay=et=>Math.floor(Math.min(e8,Math.random()*2**et*ee)),setDelayBase=et=>{ee=et};return{computeNextBackoffDelay,setDelayBase}},createDefaultRetryToken=({retryDelay:ee,retryCount:et,retryCost:en})=>{let getRetryCount=()=>et,getRetryDelay=()=>Math.min(e8,ee),getRetryCost=()=>en;return{getRetryCount,getRetryDelay,getRetryCost}};let StandardRetryStrategy_StandardRetryStrategy=class StandardRetryStrategy_StandardRetryStrategy{constructor(ee){this.maxAttempts=ee,this.mode=ep.STANDARD,this.capacity=e5,this.retryBackoffStrategy=getDefaultRetryBackoffStrategy(),this.maxAttemptsProvider="function"==typeof ee?ee:async()=>ee}async acquireInitialRetryToken(ee){return createDefaultRetryToken({retryDelay:e4,retryCount:0})}async refreshRetryTokenForRetry(ee,et){let en=await this.getMaxAttempts();if(this.shouldRetry(ee,et,en)){let en=et.errorType;this.retryBackoffStrategy.setDelayBase("THROTTLING"===en?e6:e4);let ei=this.retryBackoffStrategy.computeNextBackoffDelay(ee.getRetryCount()),eo=et.retryAfterHint?Math.max(et.retryAfterHint.getTime()-Date.now()||0,ei):ei,ea=this.getCapacityCost(en);return this.capacity-=ea,createDefaultRetryToken({retryDelay:eo,retryCount:ee.getRetryCount()+1,retryCost:ea})}throw Error("No retry token available")}recordSuccess(ee){this.capacity=Math.max(e5,this.capacity+(ee.getRetryCost()??te))}getCapacity(){return this.capacity}async getMaxAttempts(){try{return await this.maxAttemptsProvider()}catch(ee){return console.warn(`Max attempts provider could not resolve. Using default of ${eX}`),eX}}shouldRetry(ee,et,en){let ei=ee.getRetryCount()+1;return ei=this.getCapacityCost(et.errorType)&&this.isRetryableError(et.errorType)}getCapacityCost(ee){return"TRANSIENT"===ee?e7:e9}isRetryableError(ee){return"THROTTLING"===ee||"TRANSIENT"===ee}};let AdaptiveRetryStrategy=class AdaptiveRetryStrategy{constructor(ee,et){this.maxAttemptsProvider=ee,this.mode=ep.ADAPTIVE;let{rateLimiter:en}=et??{};this.rateLimiter=en??new DefaultRateLimiter_DefaultRateLimiter,this.standardRetryStrategy=new StandardRetryStrategy_StandardRetryStrategy(ee)}async acquireInitialRetryToken(ee){return await this.rateLimiter.getSendToken(),this.standardRetryStrategy.acquireInitialRetryToken(ee)}async refreshRetryTokenForRetry(ee,et){return this.rateLimiter.updateClientSendingRate(et),this.standardRetryStrategy.refreshRetryTokenForRetry(ee,et)}recordSuccess(ee){this.rateLimiter.updateClientSendingRate({}),this.standardRetryStrategy.recordSuccess(ee)}};let resolveRetryConfig=ee=>{let{retryStrategy:et}=ee,en=(0,ez.$)(ee.maxAttempts??eX);return{...ee,maxAttempts:en,retryStrategy:async()=>{if(et)return et;let ei=await (0,ez.$)(ee.retryMode)();return ei===ep.ADAPTIVE?new AdaptiveRetryStrategy(en):new StandardRetryStrategy_StandardRetryStrategy(en)}}};var tn=en(70391),ti=en(46150);let isStreamingPayload=ee=>ee?.body instanceof ReadableStream,util_asSdkError=ee=>ee instanceof Error?ee:ee instanceof Object?Object.assign(Error(),ee):"string"==typeof ee?Error(ee):Error(`AWS SDK error wrapper for ${ee}`),retryMiddleware=ee=>(et,en)=>async ei=>{let eo=await ee.retryStrategy(),ea=await ee.maxAttempts();if(!isRetryStrategyV2(eo))return eo?.mode&&(en.userAgent=[...en.userAgent||[],["cfg/retry-mode",eo.mode]]),eo.retry(et,ei);{let ee=await eo.acquireInitialRetryToken(en.partition_id),es=Error(),eu=0,ec=0,{request:ed}=ei,ef=eg.aW.isInstance(ed);for(ef&&(ed.headers[tt]=(0,ti.Z)());;)try{ef&&(ed.headers[tr]=`attempt=${eu+1}; max=${ea}`);let{response:en,output:es}=await et(ei);return eo.recordSuccess(ee),es.$metadata.attempts=eu+1,es.$metadata.totalRetryDelay=ec,{response:en,output:es}}catch(ea){let et=getRetryErrorInfo(ea);if(es=util_asSdkError(ea),ef&&isStreamingPayload(ed))throw(en.logger instanceof tn.vk?console:en.logger)?.warn("An error was encountered in a non-retryable streaming request."),es;try{ee=await eo.refreshRetryTokenForRetry(ee,et)}catch(ee){throw es.$metadata||(es.$metadata={}),es.$metadata.attempts=eu+1,es.$metadata.totalRetryDelay=ec,es}eu=ee.getRetryCount();let ei=ee.getRetryDelay();ec+=ei,await new Promise(ee=>setTimeout(ee,ei))}}},isRetryStrategyV2=ee=>void 0!==ee.acquireInitialRetryToken&&void 0!==ee.refreshRetryTokenForRetry&&void 0!==ee.recordSuccess,getRetryErrorInfo=ee=>{let et={error:ee,errorType:getRetryErrorType(ee)},en=getRetryAfterHint(ee.$response);return en&&(et.retryAfterHint=en),et},getRetryErrorType=ee=>dist_es_isThrottlingError(ee)?"THROTTLING":isTransientError(ee)?"TRANSIENT":isServerError(ee)?"SERVER_ERROR":"CLIENT_ERROR",ta={name:"retryMiddleware",tags:["RETRY"],step:"finalizeRequest",priority:"high",override:!0},getRetryPlugin=ee=>({applyToStack:et=>{et.add(retryMiddleware(ee),ta)}}),getRetryAfterHint=ee=>{if(!eg.Zn.isInstance(ee))return;let et=Object.keys(ee.headers).find(ee=>"retry-after"===ee.toLowerCase());if(!et)return;let en=ee.headers[et],ei=Number(en);if(!Number.isNaN(ei))return new Date(1e3*ei);let eo=new Date(en);return eo};var ts=en(63645),tu=en(50516),tl=en(45854);let toUint8Array=ee=>"string"==typeof ee?(0,tl.$)(ee):ArrayBuffer.isView(ee)?new Uint8Array(ee.buffer,ee.byteOffset,ee.byteLength/Uint8Array.BYTES_PER_ELEMENT):new Uint8Array(ee),tc="X-Amz-Algorithm",td="X-Amz-Credential",tf="X-Amz-Date",tp="X-Amz-SignedHeaders",th="X-Amz-Expires",ty="X-Amz-Signature",tm="X-Amz-Security-Token",tg="authorization",tb=tf.toLowerCase(),tv="date",t_=[tg,tb,tv],tw=ty.toLowerCase(),tS="x-amz-content-sha256",tE=tm.toLowerCase(),tA={authorization:!0,"cache-control":!0,connection:!0,expect:!0,from:!0,"keep-alive":!0,"max-forwards":!0,pragma:!0,referer:!0,te:!0,trailer:!0,"transfer-encoding":!0,upgrade:!0,"user-agent":!0,"x-amzn-trace-id":!0},t$=/^proxy-/,tx=/^sec-/,tC="AWS4-HMAC-SHA256",tk="AWS4-HMAC-SHA256-PAYLOAD",tO="UNSIGNED-PAYLOAD",tT=50,tP="aws4_request",tR=604800,tI={},tN=[],createScope=(ee,et,en)=>`${ee}/${et}/${en}/${tP}`,getSigningKey=async(ee,et,en,ei,eo)=>{let ea=await hmac(ee,et.secretAccessKey,et.accessKeyId),es=`${en}:${ei}:${eo}:${(0,ts.N)(ea)}:${et.sessionToken}`;if(es in tI)return tI[es];for(tN.push(es);tN.length>tT;)delete tI[tN.shift()];let eu=`AWS4${et.secretAccessKey}`;for(let et of[en,ei,eo,tP])eu=await hmac(ee,eu,et);return tI[es]=eu},hmac=(ee,et,en)=>{let ei=new ee(et);return ei.update(toUint8Array(en)),ei.digest()},getCanonicalHeaders=({headers:ee},et,en)=>{let ei={};for(let eo of Object.keys(ee).sort()){if(void 0==ee[eo])continue;let ea=eo.toLowerCase();(!(ea in tA||et?.has(ea)||t$.test(ea)||tx.test(ea))||en&&(!en||en.has(ea)))&&(ei[ea]=ee[eo].trim().replace(/\s+/g," "))}return ei},getCanonicalQuery=({query:ee={}})=>{let et=[],en={};for(let ei of Object.keys(ee).sort()){if(ei.toLowerCase()===tw)continue;et.push(ei);let eo=ee[ei];"string"==typeof eo?en[ei]=`${(0,tu.i)(ei)}=${(0,tu.i)(eo)}`:Array.isArray(eo)&&(en[ei]=eo.slice(0).reduce((ee,et)=>ee.concat([`${(0,tu.i)(ei)}=${(0,tu.i)(et)}`]),[]).sort().join("&"))}return et.map(ee=>en[ee]).filter(ee=>ee).join("&")},isArrayBuffer=ee=>"function"==typeof ArrayBuffer&&ee instanceof ArrayBuffer||"[object ArrayBuffer]"===Object.prototype.toString.call(ee),getPayloadHash=async({headers:ee,body:et},en)=>{for(let et of Object.keys(ee))if(et.toLowerCase()===tS)return ee[et];if(void 0==et)return"e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855";if("string"==typeof et||ArrayBuffer.isView(et)||isArrayBuffer(et)){let ee=new en;return ee.update(toUint8Array(et)),(0,ts.N)(await ee.digest())}return tO};let HeaderFormatter=class HeaderFormatter{format(ee){let et=[];for(let en of Object.keys(ee)){let ei=(0,tl.$)(en);et.push(Uint8Array.from([ei.byteLength]),ei,this.formatHeaderValue(ee[en]))}let en=new Uint8Array(et.reduce((ee,et)=>ee+et.byteLength,0)),ei=0;for(let ee of et)en.set(ee,ei),ei+=ee.byteLength;return en}formatHeaderValue(ee){switch(ee.type){case"boolean":return Uint8Array.from([ee.value?0:1]);case"byte":return Uint8Array.from([2,ee.value]);case"short":let et=new DataView(new ArrayBuffer(3));return et.setUint8(0,3),et.setInt16(1,ee.value,!1),new Uint8Array(et.buffer);case"integer":let en=new DataView(new ArrayBuffer(5));return en.setUint8(0,4),en.setInt32(1,ee.value,!1),new Uint8Array(en.buffer);case"long":let ei=new Uint8Array(9);return ei[0]=5,ei.set(ee.value.bytes,1),ei;case"binary":let eo=new DataView(new ArrayBuffer(3+ee.value.byteLength));eo.setUint8(0,6),eo.setUint16(1,ee.value.byteLength,!1);let ea=new Uint8Array(eo.buffer);return ea.set(ee.value,3),ea;case"string":let es=(0,tl.$)(ee.value),eu=new DataView(new ArrayBuffer(3+es.byteLength));eu.setUint8(0,7),eu.setUint16(1,es.byteLength,!1);let ec=new Uint8Array(eu.buffer);return ec.set(es,3),ec;case"timestamp":let ed=new Uint8Array(9);return ed[0]=8,ed.set(Int64.fromNumber(ee.value.valueOf()).bytes,1),ed;case"uuid":if(!tM.test(ee.value))throw Error(`Invalid UUID received: ${ee.value}`);let ef=new Uint8Array(17);return ef[0]=9,ef.set((0,ts.H)(ee.value.replace(/\-/g,"")),1),ef}}};!function(ee){ee[ee.boolTrue=0]="boolTrue",ee[ee.boolFalse=1]="boolFalse",ee[ee.byte=2]="byte",ee[ee.short=3]="short",ee[ee.integer=4]="integer",ee[ee.long=5]="long",ee[ee.byteArray=6]="byteArray",ee[ee.string=7]="string",ee[ee.timestamp=8]="timestamp",ee[ee.uuid=9]="uuid"}(eh||(eh={}));let tM=/^[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}$/;let Int64=class Int64{constructor(ee){if(this.bytes=ee,8!==ee.byteLength)throw Error("Int64 buffers must be exactly 8 bytes")}static fromNumber(ee){if(ee>0x7fffffffffffffff||ee<-0x8000000000000000)throw Error(`${ee} is too large (or, if negative, too small) to represent as an Int64`);let et=new Uint8Array(8);for(let en=7,ei=Math.abs(Math.round(ee));en>-1&&ei>0;en--,ei/=256)et[en]=ei;return ee<0&&negate(et),new Int64(et)}valueOf(){let ee=this.bytes.slice(0),et=128&ee[0];return et&&negate(ee),parseInt((0,ts.N)(ee),16)*(et?-1:1)}toString(){return String(this.valueOf())}};function negate(ee){for(let et=0;et<8;et++)ee[et]^=255;for(let et=7;et>-1&&(ee[et]++,0===ee[et]);et--);}let hasHeader=(ee,et)=>{for(let en of(ee=ee.toLowerCase(),Object.keys(et)))if(ee===en.toLowerCase())return!0;return!1},moveHeadersToQuery=(ee,et={})=>{let{headers:en,query:ei={}}=eg.aW.clone(ee);for(let ee of Object.keys(en)){let eo=ee.toLowerCase();"x-amz-"!==eo.slice(0,6)||et.unhoistableHeaders?.has(eo)||(ei[ee]=en[ee],delete en[ee])}return{...ee,headers:en,query:ei}},prepareRequest=ee=>{for(let et of Object.keys((ee=eg.aW.clone(ee)).headers))t_.indexOf(et.toLowerCase())>-1&&delete ee.headers[et];return ee},iso8601=ee=>toDate(ee).toISOString().replace(/\.\d{3}Z$/,"Z"),toDate=ee=>"number"==typeof ee?new Date(1e3*ee):"string"==typeof ee?Number(ee)?new Date(1e3*Number(ee)):new Date(ee):ee;let SignatureV4=class SignatureV4{constructor({applyChecksum:ee,credentials:et,region:en,service:ei,sha256:eo,uriEscapePath:ea=!0}){this.headerFormatter=new HeaderFormatter,this.service=ei,this.sha256=eo,this.uriEscapePath=ea,this.applyChecksum="boolean"!=typeof ee||ee,this.regionProvider=(0,ez.$)(en),this.credentialProvider=(0,ez.$)(et)}async presign(ee,et={}){let{signingDate:en=new Date,expiresIn:ei=3600,unsignableHeaders:eo,unhoistableHeaders:ea,signableHeaders:es,signingRegion:eu,signingService:ec}=et,ed=await this.credentialProvider();this.validateResolvedCredentials(ed);let ef=eu??await this.regionProvider(),{longDate:ep,shortDate:eh}=formatDate(en);if(ei>tR)return Promise.reject("Signature version 4 presigned URLs must have an expiration date less than one week in the future");let ey=createScope(eh,ef,ec??this.service),em=moveHeadersToQuery(prepareRequest(ee),{unhoistableHeaders:ea});ed.sessionToken&&(em.query[tm]=ed.sessionToken),em.query[tc]=tC,em.query[td]=`${ed.accessKeyId}/${ey}`,em.query[tf]=ep,em.query[th]=ei.toString(10);let eg=getCanonicalHeaders(em,eo,es);return em.query[tp]=getCanonicalHeaderList(eg),em.query[ty]=await this.getSignature(ep,ey,this.getSigningKey(ed,ef,eh,ec),this.createCanonicalRequest(em,eg,await getPayloadHash(ee,this.sha256))),em}async sign(ee,et){return"string"==typeof ee?this.signString(ee,et):ee.headers&&ee.payload?this.signEvent(ee,et):ee.message?this.signMessage(ee,et):this.signRequest(ee,et)}async signEvent({headers:ee,payload:et},{signingDate:en=new Date,priorSignature:ei,signingRegion:eo,signingService:ea}){let es=eo??await this.regionProvider(),{shortDate:eu,longDate:ec}=formatDate(en),ed=createScope(eu,es,ea??this.service),ef=await getPayloadHash({headers:{},body:et},this.sha256),ep=new this.sha256;ep.update(ee);let eh=(0,ts.N)(await ep.digest()),ey=[tk,ec,ed,ei,eh,ef].join("\n");return this.signString(ey,{signingDate:en,signingRegion:es,signingService:ea})}async signMessage(ee,{signingDate:et=new Date,signingRegion:en,signingService:ei}){let eo=this.signEvent({headers:this.headerFormatter.format(ee.message.headers),payload:ee.message.body},{signingDate:et,signingRegion:en,signingService:ei,priorSignature:ee.priorSignature});return eo.then(et=>({message:ee.message,signature:et}))}async signString(ee,{signingDate:et=new Date,signingRegion:en,signingService:ei}={}){let eo=await this.credentialProvider();this.validateResolvedCredentials(eo);let ea=en??await this.regionProvider(),{shortDate:es}=formatDate(et),eu=new this.sha256(await this.getSigningKey(eo,ea,es,ei));return eu.update(toUint8Array(ee)),(0,ts.N)(await eu.digest())}async signRequest(ee,{signingDate:et=new Date,signableHeaders:en,unsignableHeaders:ei,signingRegion:eo,signingService:ea}={}){let es=await this.credentialProvider();this.validateResolvedCredentials(es);let eu=eo??await this.regionProvider(),ec=prepareRequest(ee),{longDate:ed,shortDate:ef}=formatDate(et),ep=createScope(ef,eu,ea??this.service);ec.headers[tb]=ed,es.sessionToken&&(ec.headers[tE]=es.sessionToken);let eh=await getPayloadHash(ec,this.sha256);!hasHeader(tS,ec.headers)&&this.applyChecksum&&(ec.headers[tS]=eh);let ey=getCanonicalHeaders(ec,ei,en),em=await this.getSignature(ed,ep,this.getSigningKey(es,eu,ef,ea),this.createCanonicalRequest(ec,ey,eh));return ec.headers[tg]=`${tC} Credential=${es.accessKeyId}/${ep}, SignedHeaders=${getCanonicalHeaderList(ey)}, Signature=${em}`,ec}createCanonicalRequest(ee,et,en){let ei=Object.keys(et).sort();return`${ee.method} ${this.getCanonicalPath(ee)} ${getCanonicalQuery(ee)} ${ei.map(ee=>`${ee}:${et[ee]}`).join("\n")} ${ei.join(";")} ${en}`}async createStringToSign(ee,et,en){let ei=new this.sha256;ei.update(toUint8Array(en));let eo=await ei.digest();return`${tC} ${ee} ${et} ${(0,ts.N)(eo)}`}getCanonicalPath({path:ee}){if(this.uriEscapePath){let et=[];for(let en of ee.split("/"))en?.length!==0&&"."!==en&&(".."===en?et.pop():et.push(en));let en=`${ee?.startsWith("/")?"/":""}${et.join("/")}${et.length>0&&ee?.endsWith("/")?"/":""}`,ei=(0,tu.i)(en);return ei.replace(/%2F/g,"/")}return ee}async getSignature(ee,et,en,ei){let eo=await this.createStringToSign(ee,et,ei),ea=new this.sha256(await en);return ea.update(toUint8Array(eo)),(0,ts.N)(await ea.digest())}getSigningKey(ee,et,en,ei){return getSigningKey(this.sha256,ee,en,et,ei||this.service)}validateResolvedCredentials(ee){if("object"!=typeof ee||"string"!=typeof ee.accessKeyId||"string"!=typeof ee.secretAccessKey)throw Error("Resolved credential object is not valid")}};let formatDate=ee=>{let et=iso8601(ee).replace(/[\-:]/g,"");return{longDate:et,shortDate:et.slice(0,8)}},getCanonicalHeaderList=ee=>Object.keys(ee).sort().join(";"),resolveAwsSdkSigV4Config=ee=>{let et,en;ee.credentials&&(et=(0,eJ.CU)(ee.credentials,eJ.BP,eJ.zV)),et||(et=ee.credentialDefaultProvider?(0,eJ.$E)(ee.credentialDefaultProvider(Object.assign({},ee,{parentClientConfig:ee}))):async()=>{throw Error("`credentials` is missing")});let{signingEscapePath:ei=!0,systemClockOffset:eo=ee.systemClockOffset||0,sha256:ea}=ee;return en=ee.signer?(0,eJ.$E)(ee.signer):ee.regionInfoProvider?()=>(0,eJ.$E)(ee.region)().then(async et=>[await ee.regionInfoProvider(et,{useFipsEndpoint:await ee.useFipsEndpoint(),useDualstackEndpoint:await ee.useDualstackEndpoint()})||{},et]).then(([en,eo])=>{let{signingRegion:es,signingService:eu}=en;ee.signingRegion=ee.signingRegion||es||eo,ee.signingName=ee.signingName||eu||ee.serviceId;let ec={...ee,credentials:et,region:ee.signingRegion,service:ee.signingName,sha256:ea,uriEscapePath:ei},ed=ee.signerConstructor||SignatureV4;return new ed(ec)}):async en=>{en=Object.assign({},{name:"sigv4",signingName:ee.signingName||ee.defaultSigningName,signingRegion:await (0,eJ.$E)(ee.region)(),properties:{}},en);let eo=en.signingRegion,es=en.signingName;ee.signingRegion=ee.signingRegion||eo,ee.signingName=ee.signingName||es||ee.serviceId;let eu={...ee,credentials:et,region:ee.signingRegion,service:ee.signingName,sha256:ea,uriEscapePath:ei},ec=ee.signerConstructor||SignatureV4;return new ec(eu)},{...ee,systemClockOffset:eo,signingEscapePath:ei,credentials:et,signer:en}},defaultDynamoDBHttpAuthSchemeParametersProvider=async(ee,et,en)=>({operation:(0,ez.J)(et).operation,region:await (0,ez.$)(ee.region)()||(()=>{throw Error("expected `region` to be configured for `aws.auth#sigv4`")})()});function createAwsAuthSigv4HttpAuthOption(ee){return{schemeId:"aws.auth#sigv4",signingProperties:{name:"dynamodb",region:ee.region},propertiesExtractor:(ee,et)=>({signingProperties:{config:ee,context:et}})}}let defaultDynamoDBHttpAuthSchemeProvider=ee=>{let et=[];return ee.operation,et.push(createAwsAuthSigv4HttpAuthOption(ee)),et},resolveHttpAuthSchemeConfig=ee=>{let et=resolveAwsSdkSigV4Config(ee);return{...et}};var tj=en(93270),tD=en(95616),tB=en(91221);let DescribeEndpointsCommand=class DescribeEndpointsCommand extends tn.mY.classBuilder().ep(tD.q).m(function(ee,et,en,ei){return[(0,tj.p2)(en,this.serialize,this.deserialize),(0,eZ.a3)(en,ee.getEndpointParameterInstructions())]}).s("DynamoDB_20120810","DescribeEndpoints",{}).n("DynamoDBClient","DescribeEndpointsCommand").f(void 0,void 0).ser(tB.OM).de(tB.k0).build(){};var tU={i8:"3.651.1"};let fromUtf8=ee=>new TextEncoder().encode(ee);var tL=en(48764).Buffer,tF=void 0!==tL&&tL.from?function(ee){return tL.from(ee,"utf8")}:fromUtf8;function convertToBuffer(ee){return ee instanceof Uint8Array?ee:"string"==typeof ee?tF(ee):ArrayBuffer.isView(ee)?new Uint8Array(ee.buffer,ee.byteOffset,ee.byteLength/Uint8Array.BYTES_PER_ELEMENT):new Uint8Array(ee)}function isEmptyData(ee){return"string"==typeof ee?0===ee.length:0===ee.byteLength}var tW={name:"SHA-256"},tH={name:"HMAC",hash:tW},tq=new Uint8Array([227,176,196,66,152,252,28,20,154,251,244,200,153,111,185,36,39,174,65,228,100,155,147,76,164,149,153,27,120,82,184,85]);let tV={};function locateWindow(){return"undefined"!=typeof window?window:"undefined"!=typeof self?self:tV}var tK=function(){function Sha256(ee){this.toHash=new Uint8Array(0),this.secret=ee,this.reset()}return Sha256.prototype.update=function(ee){if(!isEmptyData(ee)){var et=convertToBuffer(ee),en=new Uint8Array(this.toHash.byteLength+et.byteLength);en.set(this.toHash,0),en.set(et,this.toHash.byteLength),this.toHash=en}},Sha256.prototype.digest=function(){var ee=this;return this.key?this.key.then(function(et){return locateWindow().crypto.subtle.sign(tH,et,ee.toHash).then(function(ee){return new Uint8Array(ee)})}):isEmptyData(this.toHash)?Promise.resolve(tq):Promise.resolve().then(function(){return locateWindow().crypto.subtle.digest(tW,ee.toHash)}).then(function(ee){return Promise.resolve(new Uint8Array(ee))})},Sha256.prototype.reset=function(){var ee=this;this.toHash=new Uint8Array(0),this.secret&&void 0!==this.secret&&(this.key=new Promise(function(et,en){locateWindow().crypto.subtle.importKey("raw",convertToBuffer(ee.secret),tH,!1,["sign"]).then(et,en)}),this.key.catch(function(){}))},Sha256}(),tz=en(97582),tJ=64,tG=32,tY=new Uint32Array([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]),tZ=[1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225],tX=9007199254740991,tQ=function(){function RawSha256(){this.state=Int32Array.from(tZ),this.temp=new Int32Array(64),this.buffer=new Uint8Array(64),this.bufferLength=0,this.bytesHashed=0,this.finished=!1}return RawSha256.prototype.update=function(ee){if(this.finished)throw Error("Attempted to update an already finished hash.");var et=0,en=ee.byteLength;if(this.bytesHashed+=en,8*this.bytesHashed>tX)throw Error("Cannot hash more than 2^53 - 1 bits");for(;en>0;)this.buffer[this.bufferLength++]=ee[et++],en--,this.bufferLength===tJ&&(this.hashBuffer(),this.bufferLength=0)},RawSha256.prototype.digest=function(){if(!this.finished){var ee=8*this.bytesHashed,et=new DataView(this.buffer.buffer,this.buffer.byteOffset,this.buffer.byteLength),en=this.bufferLength;if(et.setUint8(this.bufferLength++,128),en%tJ>=tJ-8){for(var ei=this.bufferLength;ei>>24&255,eo[4*ei+1]=this.state[ei]>>>16&255,eo[4*ei+2]=this.state[ei]>>>8&255,eo[4*ei+3]=this.state[ei]>>>0&255;return eo},RawSha256.prototype.hashBuffer=function(){for(var ee=this,et=ee.buffer,en=ee.state,ei=en[0],eo=en[1],ea=en[2],es=en[3],eu=en[4],ec=en[5],ed=en[6],ef=en[7],ep=0;ep>>17|eh<<15)^(eh>>>19|eh<<13)^eh>>>10,em=((eh=this.temp[ep-15])>>>7|eh<<25)^(eh>>>18|eh<<14)^eh>>>3;this.temp[ep]=(ey+this.temp[ep-7]|0)+(em+this.temp[ep-16]|0)}var eg=(((eu>>>6|eu<<26)^(eu>>>11|eu<<21)^(eu>>>25|eu<<7))+(eu&ec^~eu&ed)|0)+(ef+(tY[ep]+this.temp[ep]|0)|0)|0,eb=((ei>>>2|ei<<30)^(ei>>>13|ei<<19)^(ei>>>22|ei<<10))+(ei&eo^ei&ea^eo&ea)|0;ef=ed,ed=ec,ec=eu,eu=es+eg|0,es=ea,ea=eo,eo=ei,ei=eg+eb|0}en[0]+=ei,en[1]+=eo,en[2]+=ea,en[3]+=es,en[4]+=eu,en[5]+=ec,en[6]+=ed,en[7]+=ef},RawSha256}(),t0=function(){function Sha256(ee){this.secret=ee,this.hash=new tQ,this.reset()}return Sha256.prototype.update=function(ee){if(!isEmptyData(ee)&&!this.error)try{this.hash.update(convertToBuffer(ee))}catch(ee){this.error=ee}},Sha256.prototype.digestSync=function(){if(this.error)throw this.error;return this.outer?(this.outer.finished||this.outer.update(this.hash.digest()),this.outer.digest()):this.hash.digest()},Sha256.prototype.digest=function(){return(0,tz.mG)(this,void 0,void 0,function(){return(0,tz.Jh)(this,function(ee){return[2,this.digestSync()]})})},Sha256.prototype.reset=function(){if(this.hash=new tQ,this.secret){this.outer=new tQ;var ee=bufferFromSecret(this.secret),et=new Uint8Array(tJ);et.set(ee);for(var en=0;entJ){var en=new tQ;en.update(et),et=en.digest()}var ei=new Uint8Array(tJ);return ei.set(et),ei}var t4=["decrypt","digest","encrypt","exportKey","generateKey","importKey","sign","verify"];function supportsWebCrypto(ee){return!!supportsSecureRandom(ee)&&"object"==typeof ee.crypto.subtle&&supportsSubtleCrypto(ee.crypto.subtle)}function supportsSecureRandom(ee){return"object"==typeof ee&&"object"==typeof ee.crypto&&"function"==typeof ee.crypto.getRandomValues}function supportsSubtleCrypto(ee){return ee&&t4.every(function(et){return"function"==typeof ee[et]})}var t8=function(){function Sha256(ee){supportsWebCrypto(locateWindow())?this.hash=new tK(ee):this.hash=new t0(ee)}return Sha256.prototype.update=function(ee,et){this.hash.update(convertToBuffer(ee))},Sha256.prototype.digest=function(){return this.hash.digest()},Sha256.prototype.reset=function(){this.hash.reset()},Sha256}(),t6=en(51206),t5=en.n(t6);let defaultUserAgent=({serviceId:ee,clientVersion:et})=>async()=>{let en="undefined"!=typeof window&&window?.navigator?.userAgent?t5().parse(window.navigator.userAgent):void 0,ei=[["aws-sdk-js",et],["ua","2.0"],[`os/${en?.os?.name||"other"}`,en?.os?.version],["lang/js"],["md/browser",`${en?.browser?.name??"unknown"}_${en?.browser?.version??"unknown"}`]];return ee&&ei.push([`api/${ee}`,et]),ei};var t9=en(63087);let invalidProvider=ee=>()=>Promise.reject(ee),t7="function"==typeof TextEncoder?new TextEncoder:null,calculateBodyLength=ee=>{if("string"==typeof ee){if(t7)return t7.encode(ee).byteLength;let et=ee.length;for(let en=et-1;en>=0;en--){let ei=ee.charCodeAt(en);ei>127&&ei<=2047?et++:ei>2047&&ei<=65535&&(et+=2),ei>=56320&&ei<=57343&&en--}return et}if("number"==typeof ee.byteLength)return ee.byteLength;if("number"==typeof ee.size)return ee.size;throw Error(`Body Length computation failed for ${ee}`)},getSkewCorrectedDate=ee=>new Date(Date.now()+ee),getDateHeader=ee=>eg.Zn.isInstance(ee)?ee.headers?.date??ee.headers?.Date:void 0,isClockSkewed=(ee,et)=>Math.abs(getSkewCorrectedDate(et).getTime()-ee)>=3e5,getUpdatedSystemClockOffset=(ee,et)=>{let en=Date.parse(ee);return isClockSkewed(en,et)?en-Date.now():et},throwSigningPropertyError=(ee,et)=>{if(!et)throw Error(`Property \`${ee}\` is not resolved for AWS SDK SigV4Auth`);return et},validateSigningProperties=async ee=>{let et=throwSigningPropertyError("context",ee.context),en=throwSigningPropertyError("config",ee.config),ei=et.endpointV2?.properties?.authSchemes?.[0],eo=throwSigningPropertyError("signer",en.signer),ea=await eo(ei),es=ee?.signingRegion,eu=ee?.signingRegionSet,ec=ee?.signingName;return{config:en,signer:ea,signingRegion:es,signingRegionSet:eu,signingName:ec}};let AwsSdkSigV4Signer=class AwsSdkSigV4Signer{async sign(ee,et,en){if(!eg.aW.isInstance(ee))throw Error("The request is not an instance of `HttpRequest` and cannot be signed");let ei=await validateSigningProperties(en),{config:eo,signer:ea}=ei,{signingRegion:es,signingName:eu}=ei,ec=en.context;if(ec?.authSchemes?.length){let[ee,et]=ec.authSchemes;ee?.name==="sigv4a"&&et?.name==="sigv4"&&(es=et?.signingRegion??es,eu=et?.signingName??eu)}let ed=await ea.sign(ee,{signingDate:getSkewCorrectedDate(eo.systemClockOffset),signingRegion:es,signingService:eu});return ed}errorHandler(ee){return et=>{let en=et.ServerTime??getDateHeader(et.$response);if(en){let ei=throwSigningPropertyError("config",ee.config),eo=ei.systemClockOffset;ei.systemClockOffset=getUpdatedSystemClockOffset(en,ei.systemClockOffset);let ea=ei.systemClockOffset!==eo;ea&&et.$metadata&&(et.$metadata.clockSkewCorrected=!0)}throw et}}successHandler(ee,et){let en=getDateHeader(ee);if(en){let ee=throwSigningPropertyError("config",et.config);ee.systemClockOffset=getUpdatedSystemClockOffset(en,ee.systemClockOffset)}}};var re=en(94317),rr=en(65368),rn=en(88608);let ri="required",ro="fn",ra="argv",rs="ref",ru=!0,rl="isSet",rc="booleanEquals",rd="error",rf="endpoint",rp="tree",rh="PartitionResult",ry="getAttr",rm="stringEquals",rg={[ri]:!1,type:"String"},rb={[ri]:!0,default:!1,type:"Boolean"},rv={[rs]:"Endpoint"},r_={[ro]:rc,[ra]:[{[rs]:"UseFIPS"},!0]},rw={[ro]:rc,[ra]:[{[rs]:"UseDualStack"},!0]},rS={},rE={[rs]:"Region"},rA={[ro]:ry,[ra]:[{[rs]:rh},"supportsFIPS"]},r$={[rs]:rh},rx={[ro]:rc,[ra]:[!0,{[ro]:ry,[ra]:[r$,"supportsDualStack"]}]},rC=[r_],rk=[rw],rO=[rE],rT={version:"1.0",parameters:{Region:rg,UseDualStack:rb,UseFIPS:rb,Endpoint:rg},rules:[{conditions:[{[ro]:rl,[ra]:[rv]}],rules:[{conditions:rC,error:"Invalid Configuration: FIPS and custom endpoint are not supported",type:rd},{conditions:rk,error:"Invalid Configuration: Dualstack and custom endpoint are not supported",type:rd},{endpoint:{url:rv,properties:rS,headers:rS},type:rf}],type:rp},{conditions:[{[ro]:rl,[ra]:rO}],rules:[{conditions:[{[ro]:"aws.partition",[ra]:rO,assign:rh}],rules:[{conditions:[r_,rw],rules:[{conditions:[{[ro]:rc,[ra]:[ru,rA]},rx],rules:[{endpoint:{url:"https://dynamodb-fips.{Region}.{PartitionResult#dualStackDnsSuffix}",properties:rS,headers:rS},type:rf}],type:rp},{error:"FIPS and DualStack are enabled, but this partition does not support one or both",type:rd}],type:rp},{conditions:rC,rules:[{conditions:[{[ro]:rc,[ra]:[rA,ru]}],rules:[{conditions:[{[ro]:rm,[ra]:[{[ro]:ry,[ra]:[r$,"name"]},"aws-us-gov"]}],endpoint:{url:"https://dynamodb.{Region}.amazonaws.com",properties:rS,headers:rS},type:rf},{endpoint:{url:"https://dynamodb-fips.{Region}.{PartitionResult#dnsSuffix}",properties:rS,headers:rS},type:rf}],type:rp},{error:"FIPS is enabled but this partition does not support FIPS",type:rd}],type:rp},{conditions:rk,rules:[{conditions:[rx],rules:[{endpoint:{url:"https://dynamodb.{Region}.{PartitionResult#dualStackDnsSuffix}",properties:rS,headers:rS},type:rf}],type:rp},{error:"DualStack is enabled but this partition does not support DualStack",type:rd}],type:rp},{conditions:[{[ro]:rm,[ra]:[rE,"local"]}],endpoint:{url:"http://localhost:8000",properties:{authSchemes:[{name:"sigv4",signingName:"dynamodb",signingRegion:"us-east-1"}]},headers:rS},type:rf},{endpoint:{url:"https://dynamodb.{Region}.{PartitionResult#dnsSuffix}",properties:rS,headers:rS},type:rf}],type:rp}],type:rp},{error:"Invalid Configuration: Missing Region",type:rd}]},rP=rT,rR=new EndpointCache_EndpointCache({size:50,params:["Endpoint","Region","UseDualStack","UseFIPS"]}),defaultEndpointResolver=(ee,et={})=>rR.get(ee,()=>resolveEndpoint(rP,{endpointParams:ee,logger:et.logger}));eC.aws=ej;let getRuntimeConfig=ee=>({apiVersion:"2012-08-10",base64Decoder:ee?.base64Decoder??rr.G,base64Encoder:ee?.base64Encoder??rr.s,disableHostPrefix:ee?.disableHostPrefix??!1,endpointProvider:ee?.endpointProvider??defaultEndpointResolver,extensions:ee?.extensions??[],httpAuthSchemeProvider:ee?.httpAuthSchemeProvider??defaultDynamoDBHttpAuthSchemeProvider,httpAuthSchemes:ee?.httpAuthSchemes??[{schemeId:"aws.auth#sigv4",identityProvider:ee=>ee.getIdentityProvider("aws.auth#sigv4"),signer:new AwsSdkSigV4Signer}],logger:ee?.logger??new tn.vk,serviceId:ee?.serviceId??"DynamoDB",urlParser:ee?.urlParser??re.e,utf8Decoder:ee?.utf8Decoder??tl.$,utf8Encoder:ee?.utf8Encoder??rn.G}),memoize=(ee,et,en)=>{let ei,eo,ea;let es=!1,coalesceProvider=async()=>{eo||(eo=ee());try{ei=await eo,ea=!0,es=!1}finally{eo=void 0}return ei};return void 0===et?async ee=>((!ea||ee?.forceRefresh)&&(ei=await coalesceProvider()),ei):async ee=>((!ea||ee?.forceRefresh)&&(ei=await coalesceProvider()),es||(en&&!en(ei)?es=!0:et(ei)&&await coalesceProvider()),ei)},rI=["in-region","cross-region","mobile","standard","legacy"],resolveDefaultsModeConfig=({defaultsMode:ee}={})=>memoize(async()=>{let et="function"==typeof ee?await ee():ee;switch(et?.toLowerCase()){case"auto":return Promise.resolve(isMobileBrowser()?"mobile":"standard");case"mobile":case"in-region":case"cross-region":case"standard":case"legacy":return Promise.resolve(et?.toLocaleLowerCase());case void 0:return Promise.resolve("legacy");default:throw Error(`Invalid parameter for "defaultsMode", expect ${rI.join(", ")}, got ${et}`)}}),isMobileBrowser=()=>{let ee="undefined"!=typeof window&&window?.navigator?.userAgent?t5().parse(window.navigator.userAgent):void 0,et=ee?.platform?.type;return"tablet"===et||"mobile"===et},runtimeConfig_browser_getRuntimeConfig=ee=>{let et=resolveDefaultsModeConfig(ee),defaultConfigProvider=()=>et().then(tn.jv),en=getRuntimeConfig(ee);return{...en,...ee,runtime:"browser",defaultsMode:et,bodyLengthChecker:ee?.bodyLengthChecker??calculateBodyLength,credentialDefaultProvider:ee?.credentialDefaultProvider??(ee=>()=>Promise.reject(Error("Credential is missing"))),defaultUserAgentProvider:ee?.defaultUserAgentProvider??defaultUserAgent({serviceId:en.serviceId,clientVersion:tU.i8}),endpointDiscoveryEnabledProvider:ee?.endpointDiscoveryEnabledProvider??(()=>Promise.resolve(void 0)),maxAttempts:ee?.maxAttempts??eX,region:ee?.region??invalidProvider("Region is missing"),requestHandler:t9.BX.create(ee?.requestHandler??defaultConfigProvider),retryMode:ee?.retryMode??(async()=>(await defaultConfigProvider()).retryMode||eQ),sha256:ee?.sha256??t8,streamCollector:ee?.streamCollector??t9.CF,useDualstackEndpoint:ee?.useDualstackEndpoint??(()=>Promise.resolve(eV)),useFipsEndpoint:ee?.useFipsEndpoint??(()=>Promise.resolve(eK))}},getAwsRegionExtensionConfiguration=ee=>{let runtimeConfigRegion=async()=>{if(void 0===ee.region)throw Error("Region is missing from runtimeConfig");let et=ee.region;return"string"==typeof et?et:et()};return{setRegion(ee){runtimeConfigRegion=ee},region:()=>runtimeConfigRegion}},resolveAwsRegionExtensionConfiguration=ee=>({region:ee.region()}),getHttpAuthExtensionConfiguration=ee=>{let et=ee.httpAuthSchemes,en=ee.httpAuthSchemeProvider,ei=ee.credentials;return{setHttpAuthScheme(ee){let en=et.findIndex(et=>et.schemeId===ee.schemeId);-1===en?et.push(ee):et.splice(en,1,ee)},httpAuthSchemes:()=>et,setHttpAuthSchemeProvider(ee){en=ee},httpAuthSchemeProvider:()=>en,setCredentials(ee){ei=ee},credentials:()=>ei}},resolveHttpAuthRuntimeConfig=ee=>({httpAuthSchemes:ee.httpAuthSchemes(),httpAuthSchemeProvider:ee.httpAuthSchemeProvider(),credentials:ee.credentials()}),asPartial=ee=>ee,resolveRuntimeExtensions=(ee,et)=>{let en={...asPartial(getAwsRegionExtensionConfiguration(ee)),...asPartial((0,tn.kE)(ee)),...asPartial((0,eg.cA)(ee)),...asPartial(getHttpAuthExtensionConfiguration(ee))};return et.forEach(ee=>ee.configure(en)),{...ee,...resolveAwsRegionExtensionConfiguration(en),...(0,tn.SQ)(en),...(0,eg.AO)(en),...resolveHttpAuthRuntimeConfig(en)}};let DynamoDBClient=class DynamoDBClient extends tn.KU{constructor(...[ee]){let et=runtimeConfig_browser_getRuntimeConfig(ee||{}),en=(0,tD.z)(et),ei=resolveUserAgentConfig(en),eo=resolveRetryConfig(ei),ea=resolveRegionConfig(eo),es=resolveHostHeaderConfig(ea),eu=(0,eZ.uW)(es),ec=resolveHttpAuthSchemeConfig(eu),ed=resolveEndpointDiscoveryConfig(ec,{endpointDiscoveryCommandCtor:DescribeEndpointsCommand}),ef=resolveRuntimeExtensions(ed,ee?.extensions||[]);super(ef),this.config=ef,this.middlewareStack.use(getUserAgentPlugin(this.config)),this.middlewareStack.use(getRetryPlugin(this.config)),this.middlewareStack.use(getContentLengthPlugin(this.config)),this.middlewareStack.use(getHostHeaderPlugin(this.config)),this.middlewareStack.use(getLoggerPlugin(this.config)),this.middlewareStack.use(getRecursionDetectionPlugin(this.config)),this.middlewareStack.use((0,eJ.tZ)(this.config,{httpAuthSchemeParametersProvider:defaultDynamoDBHttpAuthSchemeParametersProvider,identityProviderConfigProvider:async ee=>new eJ.K5({"aws.auth#sigv4":ee.credentials})})),this.middlewareStack.use((0,eJ.aZ)(this.config))}destroy(){super.destroy()}}},95616:function(ee,et,en){"use strict";en.d(et,{q:function(){return ei},z:function(){return resolveClientEndpointParameters}});let resolveClientEndpointParameters=ee=>({...ee,useDualstackEndpoint:ee.useDualstackEndpoint??!1,useFipsEndpoint:ee.useFipsEndpoint??!1,defaultSigningName:"dynamodb"}),ei={UseFIPS:{type:"builtInParams",name:"useFipsEndpoint"},Endpoint:{type:"builtInParams",name:"endpoint"},Region:{type:"builtInParams",name:"region"},UseDualStack:{type:"builtInParams",name:"useDualstackEndpoint"}}},91221:function(ee,et,en){"use strict";en.d(et,{j7:function(){return de_BatchExecuteStatementCommand},zC:function(){return de_BatchGetItemCommand},vK:function(){return de_BatchWriteItemCommand},QZ:function(){return de_DeleteItemCommand},k0:function(){return de_DescribeEndpointsCommand},uB:function(){return de_ExecuteStatementCommand},Gw:function(){return de_ExecuteTransactionCommand},Qb:function(){return de_GetItemCommand},E6:function(){return de_PutItemCommand},lx:function(){return de_QueryCommand},$t:function(){return de_ScanCommand},Ow:function(){return de_TransactGetItemsCommand},G7:function(){return de_TransactWriteItemsCommand},er:function(){return de_UpdateItemCommand},m1:function(){return se_BatchExecuteStatementCommand},L8:function(){return se_BatchGetItemCommand},de:function(){return se_BatchWriteItemCommand},Zm:function(){return se_DeleteItemCommand},OM:function(){return se_DescribeEndpointsCommand},rG:function(){return se_ExecuteStatementCommand},Di:function(){return se_ExecuteTransactionCommand},Nk:function(){return se_GetItemCommand},IQ:function(){return se_PutItemCommand},I:function(){return se_QueryCommand},Rl:function(){return se_ScanCommand},xN:function(){return se_TransactGetItemsCommand},SZ:function(){return se_TransactWriteItemsCommand},h1:function(){return se_UpdateItemCommand}});var ei,eo=en(70391);let collectBodyString=(ee,et)=>(0,eo.Wg)(ee,et).then(ee=>et.utf8Encoder(ee)),parseJsonBody=(ee,et)=>collectBodyString(ee,et).then(ee=>{if(ee.length)try{return JSON.parse(ee)}catch(et){throw et?.name==="SyntaxError"&&Object.defineProperty(et,"$responseBodyText",{value:ee}),et}return{}}),parseJsonErrorBody=async(ee,et)=>{let en=await parseJsonBody(ee,et);return en.message=en.message??en.Message,en},loadRestJsonErrorCode=(ee,et)=>{let findKey=(ee,et)=>Object.keys(ee).find(ee=>ee.toLowerCase()===et.toLowerCase()),sanitizeErrorCode=ee=>{let et=ee;return"number"==typeof et&&(et=et.toString()),et.indexOf(",")>=0&&(et=et.split(",")[0]),et.indexOf(":")>=0&&(et=et.split(":")[0]),et.indexOf("#")>=0&&(et=et.split("#")[1]),et},en=findKey(ee.headers,"x-amzn-errortype");return void 0!==en?sanitizeErrorCode(ee.headers[en]):void 0!==et.code?sanitizeErrorCode(et.code):void 0!==et.__type?sanitizeErrorCode(et.__type):void 0},awsExpectUnion=ee=>{if(null!=ee)return"object"==typeof ee&&"__type"in ee&&delete ee.__type,(0,eo.$I)(ee)};var ea=en(43979),es=en(46150);let DynamoDBServiceException=class DynamoDBServiceException extends eo.sI{constructor(ee){super(ee),Object.setPrototypeOf(this,DynamoDBServiceException.prototype)}};let BackupInUseException=class BackupInUseException extends DynamoDBServiceException{constructor(ee){super({name:"BackupInUseException",$fault:"client",...ee}),this.name="BackupInUseException",this.$fault="client",Object.setPrototypeOf(this,BackupInUseException.prototype)}};let BackupNotFoundException=class BackupNotFoundException extends DynamoDBServiceException{constructor(ee){super({name:"BackupNotFoundException",$fault:"client",...ee}),this.name="BackupNotFoundException",this.$fault="client",Object.setPrototypeOf(this,BackupNotFoundException.prototype)}};let InternalServerError=class InternalServerError extends DynamoDBServiceException{constructor(ee){super({name:"InternalServerError",$fault:"server",...ee}),this.name="InternalServerError",this.$fault="server",Object.setPrototypeOf(this,InternalServerError.prototype)}};let RequestLimitExceeded=class RequestLimitExceeded extends DynamoDBServiceException{constructor(ee){super({name:"RequestLimitExceeded",$fault:"client",...ee}),this.name="RequestLimitExceeded",this.$fault="client",Object.setPrototypeOf(this,RequestLimitExceeded.prototype)}};let InvalidEndpointException=class InvalidEndpointException extends DynamoDBServiceException{constructor(ee){super({name:"InvalidEndpointException",$fault:"client",...ee}),this.name="InvalidEndpointException",this.$fault="client",Object.setPrototypeOf(this,InvalidEndpointException.prototype),this.Message=ee.Message}};let ProvisionedThroughputExceededException=class ProvisionedThroughputExceededException extends DynamoDBServiceException{constructor(ee){super({name:"ProvisionedThroughputExceededException",$fault:"client",...ee}),this.name="ProvisionedThroughputExceededException",this.$fault="client",Object.setPrototypeOf(this,ProvisionedThroughputExceededException.prototype)}};let ResourceNotFoundException=class ResourceNotFoundException extends DynamoDBServiceException{constructor(ee){super({name:"ResourceNotFoundException",$fault:"client",...ee}),this.name="ResourceNotFoundException",this.$fault="client",Object.setPrototypeOf(this,ResourceNotFoundException.prototype)}};let ItemCollectionSizeLimitExceededException=class ItemCollectionSizeLimitExceededException extends DynamoDBServiceException{constructor(ee){super({name:"ItemCollectionSizeLimitExceededException",$fault:"client",...ee}),this.name="ItemCollectionSizeLimitExceededException",this.$fault="client",Object.setPrototypeOf(this,ItemCollectionSizeLimitExceededException.prototype)}};let ContinuousBackupsUnavailableException=class ContinuousBackupsUnavailableException extends DynamoDBServiceException{constructor(ee){super({name:"ContinuousBackupsUnavailableException",$fault:"client",...ee}),this.name="ContinuousBackupsUnavailableException",this.$fault="client",Object.setPrototypeOf(this,ContinuousBackupsUnavailableException.prototype)}};let LimitExceededException=class LimitExceededException extends DynamoDBServiceException{constructor(ee){super({name:"LimitExceededException",$fault:"client",...ee}),this.name="LimitExceededException",this.$fault="client",Object.setPrototypeOf(this,LimitExceededException.prototype)}};let TableInUseException=class TableInUseException extends DynamoDBServiceException{constructor(ee){super({name:"TableInUseException",$fault:"client",...ee}),this.name="TableInUseException",this.$fault="client",Object.setPrototypeOf(this,TableInUseException.prototype)}};let TableNotFoundException=class TableNotFoundException extends DynamoDBServiceException{constructor(ee){super({name:"TableNotFoundException",$fault:"client",...ee}),this.name="TableNotFoundException",this.$fault="client",Object.setPrototypeOf(this,TableNotFoundException.prototype)}};let GlobalTableAlreadyExistsException=class GlobalTableAlreadyExistsException extends DynamoDBServiceException{constructor(ee){super({name:"GlobalTableAlreadyExistsException",$fault:"client",...ee}),this.name="GlobalTableAlreadyExistsException",this.$fault="client",Object.setPrototypeOf(this,GlobalTableAlreadyExistsException.prototype)}};let ResourceInUseException=class ResourceInUseException extends DynamoDBServiceException{constructor(ee){super({name:"ResourceInUseException",$fault:"client",...ee}),this.name="ResourceInUseException",this.$fault="client",Object.setPrototypeOf(this,ResourceInUseException.prototype)}};let TransactionConflictException=class TransactionConflictException extends DynamoDBServiceException{constructor(ee){super({name:"TransactionConflictException",$fault:"client",...ee}),this.name="TransactionConflictException",this.$fault="client",Object.setPrototypeOf(this,TransactionConflictException.prototype)}};let PolicyNotFoundException=class PolicyNotFoundException extends DynamoDBServiceException{constructor(ee){super({name:"PolicyNotFoundException",$fault:"client",...ee}),this.name="PolicyNotFoundException",this.$fault="client",Object.setPrototypeOf(this,PolicyNotFoundException.prototype)}};let ExportNotFoundException=class ExportNotFoundException extends DynamoDBServiceException{constructor(ee){super({name:"ExportNotFoundException",$fault:"client",...ee}),this.name="ExportNotFoundException",this.$fault="client",Object.setPrototypeOf(this,ExportNotFoundException.prototype)}};let GlobalTableNotFoundException=class GlobalTableNotFoundException extends DynamoDBServiceException{constructor(ee){super({name:"GlobalTableNotFoundException",$fault:"client",...ee}),this.name="GlobalTableNotFoundException",this.$fault="client",Object.setPrototypeOf(this,GlobalTableNotFoundException.prototype)}};let ImportNotFoundException=class ImportNotFoundException extends DynamoDBServiceException{constructor(ee){super({name:"ImportNotFoundException",$fault:"client",...ee}),this.name="ImportNotFoundException",this.$fault="client",Object.setPrototypeOf(this,ImportNotFoundException.prototype)}};let DuplicateItemException=class DuplicateItemException extends DynamoDBServiceException{constructor(ee){super({name:"DuplicateItemException",$fault:"client",...ee}),this.name="DuplicateItemException",this.$fault="client",Object.setPrototypeOf(this,DuplicateItemException.prototype)}};let IdempotentParameterMismatchException=class IdempotentParameterMismatchException extends DynamoDBServiceException{constructor(ee){super({name:"IdempotentParameterMismatchException",$fault:"client",...ee}),this.name="IdempotentParameterMismatchException",this.$fault="client",Object.setPrototypeOf(this,IdempotentParameterMismatchException.prototype),this.Message=ee.Message}};let TransactionInProgressException=class TransactionInProgressException extends DynamoDBServiceException{constructor(ee){super({name:"TransactionInProgressException",$fault:"client",...ee}),this.name="TransactionInProgressException",this.$fault="client",Object.setPrototypeOf(this,TransactionInProgressException.prototype),this.Message=ee.Message}};let ExportConflictException=class ExportConflictException extends DynamoDBServiceException{constructor(ee){super({name:"ExportConflictException",$fault:"client",...ee}),this.name="ExportConflictException",this.$fault="client",Object.setPrototypeOf(this,ExportConflictException.prototype)}};let InvalidExportTimeException=class InvalidExportTimeException extends DynamoDBServiceException{constructor(ee){super({name:"InvalidExportTimeException",$fault:"client",...ee}),this.name="InvalidExportTimeException",this.$fault="client",Object.setPrototypeOf(this,InvalidExportTimeException.prototype)}};let PointInTimeRecoveryUnavailableException=class PointInTimeRecoveryUnavailableException extends DynamoDBServiceException{constructor(ee){super({name:"PointInTimeRecoveryUnavailableException",$fault:"client",...ee}),this.name="PointInTimeRecoveryUnavailableException",this.$fault="client",Object.setPrototypeOf(this,PointInTimeRecoveryUnavailableException.prototype)}};let ImportConflictException=class ImportConflictException extends DynamoDBServiceException{constructor(ee){super({name:"ImportConflictException",$fault:"client",...ee}),this.name="ImportConflictException",this.$fault="client",Object.setPrototypeOf(this,ImportConflictException.prototype)}};let TableAlreadyExistsException=class TableAlreadyExistsException extends DynamoDBServiceException{constructor(ee){super({name:"TableAlreadyExistsException",$fault:"client",...ee}),this.name="TableAlreadyExistsException",this.$fault="client",Object.setPrototypeOf(this,TableAlreadyExistsException.prototype)}};let InvalidRestoreTimeException=class InvalidRestoreTimeException extends DynamoDBServiceException{constructor(ee){super({name:"InvalidRestoreTimeException",$fault:"client",...ee}),this.name="InvalidRestoreTimeException",this.$fault="client",Object.setPrototypeOf(this,InvalidRestoreTimeException.prototype)}};let ReplicaAlreadyExistsException=class ReplicaAlreadyExistsException extends DynamoDBServiceException{constructor(ee){super({name:"ReplicaAlreadyExistsException",$fault:"client",...ee}),this.name="ReplicaAlreadyExistsException",this.$fault="client",Object.setPrototypeOf(this,ReplicaAlreadyExistsException.prototype)}};let ReplicaNotFoundException=class ReplicaNotFoundException extends DynamoDBServiceException{constructor(ee){super({name:"ReplicaNotFoundException",$fault:"client",...ee}),this.name="ReplicaNotFoundException",this.$fault="client",Object.setPrototypeOf(this,ReplicaNotFoundException.prototype)}};let IndexNotFoundException=class IndexNotFoundException extends DynamoDBServiceException{constructor(ee){super({name:"IndexNotFoundException",$fault:"client",...ee}),this.name="IndexNotFoundException",this.$fault="client",Object.setPrototypeOf(this,IndexNotFoundException.prototype)}};!function(ee){ee.visit=(ee,et)=>void 0!==ee.S?et.S(ee.S):void 0!==ee.N?et.N(ee.N):void 0!==ee.B?et.B(ee.B):void 0!==ee.SS?et.SS(ee.SS):void 0!==ee.NS?et.NS(ee.NS):void 0!==ee.BS?et.BS(ee.BS):void 0!==ee.M?et.M(ee.M):void 0!==ee.L?et.L(ee.L):void 0!==ee.NULL?et.NULL(ee.NULL):void 0!==ee.BOOL?et.BOOL(ee.BOOL):et._(ee.$unknown[0],ee.$unknown[1])}(ei||(ei={}));let ConditionalCheckFailedException=class ConditionalCheckFailedException extends DynamoDBServiceException{constructor(ee){super({name:"ConditionalCheckFailedException",$fault:"client",...ee}),this.name="ConditionalCheckFailedException",this.$fault="client",Object.setPrototypeOf(this,ConditionalCheckFailedException.prototype),this.Item=ee.Item}};let TransactionCanceledException=class TransactionCanceledException extends DynamoDBServiceException{constructor(ee){super({name:"TransactionCanceledException",$fault:"client",...ee}),this.name="TransactionCanceledException",this.$fault="client",Object.setPrototypeOf(this,TransactionCanceledException.prototype),this.Message=ee.Message,this.CancellationReasons=ee.CancellationReasons}};let se_BatchExecuteStatementCommand=async(ee,et)=>{let en;let ei=sharedHeaders("BatchExecuteStatement");return en=JSON.stringify(se_BatchExecuteStatementInput(ee,et)),buildHttpRpcRequest(et,ei,"/",void 0,en)},se_BatchGetItemCommand=async(ee,et)=>{let en;let ei=sharedHeaders("BatchGetItem");return en=JSON.stringify(se_BatchGetItemInput(ee,et)),buildHttpRpcRequest(et,ei,"/",void 0,en)},se_BatchWriteItemCommand=async(ee,et)=>{let en;let ei=sharedHeaders("BatchWriteItem");return en=JSON.stringify(se_BatchWriteItemInput(ee,et)),buildHttpRpcRequest(et,ei,"/",void 0,en)},se_DeleteItemCommand=async(ee,et)=>{let en;let ei=sharedHeaders("DeleteItem");return en=JSON.stringify(se_DeleteItemInput(ee,et)),buildHttpRpcRequest(et,ei,"/",void 0,en)},se_DescribeEndpointsCommand=async(ee,et)=>{let en=sharedHeaders("DescribeEndpoints");return buildHttpRpcRequest(et,en,"/",void 0,JSON.stringify((0,eo.F3)(ee)))},se_ExecuteStatementCommand=async(ee,et)=>{let en;let ei=sharedHeaders("ExecuteStatement");return en=JSON.stringify(se_ExecuteStatementInput(ee,et)),buildHttpRpcRequest(et,ei,"/",void 0,en)},se_ExecuteTransactionCommand=async(ee,et)=>{let en;let ei=sharedHeaders("ExecuteTransaction");return en=JSON.stringify(se_ExecuteTransactionInput(ee,et)),buildHttpRpcRequest(et,ei,"/",void 0,en)},se_GetItemCommand=async(ee,et)=>{let en;let ei=sharedHeaders("GetItem");return en=JSON.stringify(se_GetItemInput(ee,et)),buildHttpRpcRequest(et,ei,"/",void 0,en)},se_PutItemCommand=async(ee,et)=>{let en;let ei=sharedHeaders("PutItem");return en=JSON.stringify(se_PutItemInput(ee,et)),buildHttpRpcRequest(et,ei,"/",void 0,en)},se_QueryCommand=async(ee,et)=>{let en;let ei=sharedHeaders("Query");return en=JSON.stringify(se_QueryInput(ee,et)),buildHttpRpcRequest(et,ei,"/",void 0,en)},se_ScanCommand=async(ee,et)=>{let en;let ei=sharedHeaders("Scan");return en=JSON.stringify(se_ScanInput(ee,et)),buildHttpRpcRequest(et,ei,"/",void 0,en)},se_TransactGetItemsCommand=async(ee,et)=>{let en;let ei=sharedHeaders("TransactGetItems");return en=JSON.stringify(se_TransactGetItemsInput(ee,et)),buildHttpRpcRequest(et,ei,"/",void 0,en)},se_TransactWriteItemsCommand=async(ee,et)=>{let en;let ei=sharedHeaders("TransactWriteItems");return en=JSON.stringify(se_TransactWriteItemsInput(ee,et)),buildHttpRpcRequest(et,ei,"/",void 0,en)},se_UpdateItemCommand=async(ee,et)=>{let en;let ei=sharedHeaders("UpdateItem");return en=JSON.stringify(se_UpdateItemInput(ee,et)),buildHttpRpcRequest(et,ei,"/",void 0,en)},de_BatchExecuteStatementCommand=async(ee,et)=>{if(ee.statusCode>=300)return de_CommandError(ee,et);let en=await parseJsonBody(ee.body,et),ei={};ei=de_BatchExecuteStatementOutput(en,et);let eo={$metadata:deserializeMetadata(ee),...ei};return eo},de_BatchGetItemCommand=async(ee,et)=>{if(ee.statusCode>=300)return de_CommandError(ee,et);let en=await parseJsonBody(ee.body,et),ei={};ei=de_BatchGetItemOutput(en,et);let eo={$metadata:deserializeMetadata(ee),...ei};return eo},de_BatchWriteItemCommand=async(ee,et)=>{if(ee.statusCode>=300)return de_CommandError(ee,et);let en=await parseJsonBody(ee.body,et),ei={};ei=de_BatchWriteItemOutput(en,et);let eo={$metadata:deserializeMetadata(ee),...ei};return eo},de_DeleteItemCommand=async(ee,et)=>{if(ee.statusCode>=300)return de_CommandError(ee,et);let en=await parseJsonBody(ee.body,et),ei={};ei=de_DeleteItemOutput(en,et);let eo={$metadata:deserializeMetadata(ee),...ei};return eo},de_DescribeEndpointsCommand=async(ee,et)=>{if(ee.statusCode>=300)return de_CommandError(ee,et);let en=await parseJsonBody(ee.body,et),ei={};ei=(0,eo.F3)(en);let ea={$metadata:deserializeMetadata(ee),...ei};return ea},de_ExecuteStatementCommand=async(ee,et)=>{if(ee.statusCode>=300)return de_CommandError(ee,et);let en=await parseJsonBody(ee.body,et),ei={};ei=de_ExecuteStatementOutput(en,et);let eo={$metadata:deserializeMetadata(ee),...ei};return eo},de_ExecuteTransactionCommand=async(ee,et)=>{if(ee.statusCode>=300)return de_CommandError(ee,et);let en=await parseJsonBody(ee.body,et),ei={};ei=de_ExecuteTransactionOutput(en,et);let eo={$metadata:deserializeMetadata(ee),...ei};return eo},de_GetItemCommand=async(ee,et)=>{if(ee.statusCode>=300)return de_CommandError(ee,et);let en=await parseJsonBody(ee.body,et),ei={};ei=de_GetItemOutput(en,et);let eo={$metadata:deserializeMetadata(ee),...ei};return eo},de_PutItemCommand=async(ee,et)=>{if(ee.statusCode>=300)return de_CommandError(ee,et);let en=await parseJsonBody(ee.body,et),ei={};ei=de_PutItemOutput(en,et);let eo={$metadata:deserializeMetadata(ee),...ei};return eo},de_QueryCommand=async(ee,et)=>{if(ee.statusCode>=300)return de_CommandError(ee,et);let en=await parseJsonBody(ee.body,et),ei={};ei=de_QueryOutput(en,et);let eo={$metadata:deserializeMetadata(ee),...ei};return eo},de_ScanCommand=async(ee,et)=>{if(ee.statusCode>=300)return de_CommandError(ee,et);let en=await parseJsonBody(ee.body,et),ei={};ei=de_ScanOutput(en,et);let eo={$metadata:deserializeMetadata(ee),...ei};return eo},de_TransactGetItemsCommand=async(ee,et)=>{if(ee.statusCode>=300)return de_CommandError(ee,et);let en=await parseJsonBody(ee.body,et),ei={};ei=de_TransactGetItemsOutput(en,et);let eo={$metadata:deserializeMetadata(ee),...ei};return eo},de_TransactWriteItemsCommand=async(ee,et)=>{if(ee.statusCode>=300)return de_CommandError(ee,et);let en=await parseJsonBody(ee.body,et),ei={};ei=de_TransactWriteItemsOutput(en,et);let eo={$metadata:deserializeMetadata(ee),...ei};return eo},de_UpdateItemCommand=async(ee,et)=>{if(ee.statusCode>=300)return de_CommandError(ee,et);let en=await parseJsonBody(ee.body,et),ei={};ei=de_UpdateItemOutput(en,et);let eo={$metadata:deserializeMetadata(ee),...ei};return eo},de_CommandError=async(ee,et)=>{let en={...ee,body:await parseJsonErrorBody(ee.body,et)},ei=loadRestJsonErrorCode(ee,en.body);switch(ei){case"InternalServerError":case"com.amazonaws.dynamodb#InternalServerError":throw await de_InternalServerErrorRes(en,et);case"RequestLimitExceeded":case"com.amazonaws.dynamodb#RequestLimitExceeded":throw await de_RequestLimitExceededRes(en,et);case"InvalidEndpointException":case"com.amazonaws.dynamodb#InvalidEndpointException":throw await de_InvalidEndpointExceptionRes(en,et);case"ProvisionedThroughputExceededException":case"com.amazonaws.dynamodb#ProvisionedThroughputExceededException":throw await de_ProvisionedThroughputExceededExceptionRes(en,et);case"ResourceNotFoundException":case"com.amazonaws.dynamodb#ResourceNotFoundException":throw await de_ResourceNotFoundExceptionRes(en,et);case"ItemCollectionSizeLimitExceededException":case"com.amazonaws.dynamodb#ItemCollectionSizeLimitExceededException":throw await de_ItemCollectionSizeLimitExceededExceptionRes(en,et);case"BackupInUseException":case"com.amazonaws.dynamodb#BackupInUseException":throw await de_BackupInUseExceptionRes(en,et);case"ContinuousBackupsUnavailableException":case"com.amazonaws.dynamodb#ContinuousBackupsUnavailableException":throw await de_ContinuousBackupsUnavailableExceptionRes(en,et);case"LimitExceededException":case"com.amazonaws.dynamodb#LimitExceededException":throw await de_LimitExceededExceptionRes(en,et);case"TableInUseException":case"com.amazonaws.dynamodb#TableInUseException":throw await de_TableInUseExceptionRes(en,et);case"TableNotFoundException":case"com.amazonaws.dynamodb#TableNotFoundException":throw await de_TableNotFoundExceptionRes(en,et);case"GlobalTableAlreadyExistsException":case"com.amazonaws.dynamodb#GlobalTableAlreadyExistsException":throw await de_GlobalTableAlreadyExistsExceptionRes(en,et);case"ResourceInUseException":case"com.amazonaws.dynamodb#ResourceInUseException":throw await de_ResourceInUseExceptionRes(en,et);case"BackupNotFoundException":case"com.amazonaws.dynamodb#BackupNotFoundException":throw await de_BackupNotFoundExceptionRes(en,et);case"ConditionalCheckFailedException":case"com.amazonaws.dynamodb#ConditionalCheckFailedException":throw await de_ConditionalCheckFailedExceptionRes(en,et);case"TransactionConflictException":case"com.amazonaws.dynamodb#TransactionConflictException":throw await de_TransactionConflictExceptionRes(en,et);case"PolicyNotFoundException":case"com.amazonaws.dynamodb#PolicyNotFoundException":throw await de_PolicyNotFoundExceptionRes(en,et);case"ExportNotFoundException":case"com.amazonaws.dynamodb#ExportNotFoundException":throw await de_ExportNotFoundExceptionRes(en,et);case"GlobalTableNotFoundException":case"com.amazonaws.dynamodb#GlobalTableNotFoundException":throw await de_GlobalTableNotFoundExceptionRes(en,et);case"ImportNotFoundException":case"com.amazonaws.dynamodb#ImportNotFoundException":throw await de_ImportNotFoundExceptionRes(en,et);case"DuplicateItemException":case"com.amazonaws.dynamodb#DuplicateItemException":throw await de_DuplicateItemExceptionRes(en,et);case"IdempotentParameterMismatchException":case"com.amazonaws.dynamodb#IdempotentParameterMismatchException":throw await de_IdempotentParameterMismatchExceptionRes(en,et);case"TransactionCanceledException":case"com.amazonaws.dynamodb#TransactionCanceledException":throw await de_TransactionCanceledExceptionRes(en,et);case"TransactionInProgressException":case"com.amazonaws.dynamodb#TransactionInProgressException":throw await de_TransactionInProgressExceptionRes(en,et);case"ExportConflictException":case"com.amazonaws.dynamodb#ExportConflictException":throw await de_ExportConflictExceptionRes(en,et);case"InvalidExportTimeException":case"com.amazonaws.dynamodb#InvalidExportTimeException":throw await de_InvalidExportTimeExceptionRes(en,et);case"PointInTimeRecoveryUnavailableException":case"com.amazonaws.dynamodb#PointInTimeRecoveryUnavailableException":throw await de_PointInTimeRecoveryUnavailableExceptionRes(en,et);case"ImportConflictException":case"com.amazonaws.dynamodb#ImportConflictException":throw await de_ImportConflictExceptionRes(en,et);case"TableAlreadyExistsException":case"com.amazonaws.dynamodb#TableAlreadyExistsException":throw await de_TableAlreadyExistsExceptionRes(en,et);case"InvalidRestoreTimeException":case"com.amazonaws.dynamodb#InvalidRestoreTimeException":throw await de_InvalidRestoreTimeExceptionRes(en,et);case"ReplicaAlreadyExistsException":case"com.amazonaws.dynamodb#ReplicaAlreadyExistsException":throw await de_ReplicaAlreadyExistsExceptionRes(en,et);case"ReplicaNotFoundException":case"com.amazonaws.dynamodb#ReplicaNotFoundException":throw await de_ReplicaNotFoundExceptionRes(en,et);case"IndexNotFoundException":case"com.amazonaws.dynamodb#IndexNotFoundException":throw await de_IndexNotFoundExceptionRes(en,et);default:let eo=en.body;return eu({output:ee,parsedBody:eo,errorCode:ei})}},de_BackupInUseExceptionRes=async(ee,et)=>{let en=ee.body,ei=(0,eo.F3)(en),ea=new BackupInUseException({$metadata:deserializeMetadata(ee),...ei});return(0,eo.to)(ea,en)},de_BackupNotFoundExceptionRes=async(ee,et)=>{let en=ee.body,ei=(0,eo.F3)(en),ea=new BackupNotFoundException({$metadata:deserializeMetadata(ee),...ei});return(0,eo.to)(ea,en)},de_ConditionalCheckFailedExceptionRes=async(ee,et)=>{let en=ee.body,ei=de_ConditionalCheckFailedException(en,et),ea=new ConditionalCheckFailedException({$metadata:deserializeMetadata(ee),...ei});return(0,eo.to)(ea,en)},de_ContinuousBackupsUnavailableExceptionRes=async(ee,et)=>{let en=ee.body,ei=(0,eo.F3)(en),ea=new ContinuousBackupsUnavailableException({$metadata:deserializeMetadata(ee),...ei});return(0,eo.to)(ea,en)},de_DuplicateItemExceptionRes=async(ee,et)=>{let en=ee.body,ei=(0,eo.F3)(en),ea=new DuplicateItemException({$metadata:deserializeMetadata(ee),...ei});return(0,eo.to)(ea,en)},de_ExportConflictExceptionRes=async(ee,et)=>{let en=ee.body,ei=(0,eo.F3)(en),ea=new ExportConflictException({$metadata:deserializeMetadata(ee),...ei});return(0,eo.to)(ea,en)},de_ExportNotFoundExceptionRes=async(ee,et)=>{let en=ee.body,ei=(0,eo.F3)(en),ea=new ExportNotFoundException({$metadata:deserializeMetadata(ee),...ei});return(0,eo.to)(ea,en)},de_GlobalTableAlreadyExistsExceptionRes=async(ee,et)=>{let en=ee.body,ei=(0,eo.F3)(en),ea=new GlobalTableAlreadyExistsException({$metadata:deserializeMetadata(ee),...ei});return(0,eo.to)(ea,en)},de_GlobalTableNotFoundExceptionRes=async(ee,et)=>{let en=ee.body,ei=(0,eo.F3)(en),ea=new GlobalTableNotFoundException({$metadata:deserializeMetadata(ee),...ei});return(0,eo.to)(ea,en)},de_IdempotentParameterMismatchExceptionRes=async(ee,et)=>{let en=ee.body,ei=(0,eo.F3)(en),ea=new IdempotentParameterMismatchException({$metadata:deserializeMetadata(ee),...ei});return(0,eo.to)(ea,en)},de_ImportConflictExceptionRes=async(ee,et)=>{let en=ee.body,ei=(0,eo.F3)(en),ea=new ImportConflictException({$metadata:deserializeMetadata(ee),...ei});return(0,eo.to)(ea,en)},de_ImportNotFoundExceptionRes=async(ee,et)=>{let en=ee.body,ei=(0,eo.F3)(en),ea=new ImportNotFoundException({$metadata:deserializeMetadata(ee),...ei});return(0,eo.to)(ea,en)},de_IndexNotFoundExceptionRes=async(ee,et)=>{let en=ee.body,ei=(0,eo.F3)(en),ea=new IndexNotFoundException({$metadata:deserializeMetadata(ee),...ei});return(0,eo.to)(ea,en)},de_InternalServerErrorRes=async(ee,et)=>{let en=ee.body,ei=(0,eo.F3)(en),ea=new InternalServerError({$metadata:deserializeMetadata(ee),...ei});return(0,eo.to)(ea,en)},de_InvalidEndpointExceptionRes=async(ee,et)=>{let en=ee.body,ei=(0,eo.F3)(en),ea=new InvalidEndpointException({$metadata:deserializeMetadata(ee),...ei});return(0,eo.to)(ea,en)},de_InvalidExportTimeExceptionRes=async(ee,et)=>{let en=ee.body,ei=(0,eo.F3)(en),ea=new InvalidExportTimeException({$metadata:deserializeMetadata(ee),...ei});return(0,eo.to)(ea,en)},de_InvalidRestoreTimeExceptionRes=async(ee,et)=>{let en=ee.body,ei=(0,eo.F3)(en),ea=new InvalidRestoreTimeException({$metadata:deserializeMetadata(ee),...ei});return(0,eo.to)(ea,en)},de_ItemCollectionSizeLimitExceededExceptionRes=async(ee,et)=>{let en=ee.body,ei=(0,eo.F3)(en),ea=new ItemCollectionSizeLimitExceededException({$metadata:deserializeMetadata(ee),...ei});return(0,eo.to)(ea,en)},de_LimitExceededExceptionRes=async(ee,et)=>{let en=ee.body,ei=(0,eo.F3)(en),ea=new LimitExceededException({$metadata:deserializeMetadata(ee),...ei});return(0,eo.to)(ea,en)},de_PointInTimeRecoveryUnavailableExceptionRes=async(ee,et)=>{let en=ee.body,ei=(0,eo.F3)(en),ea=new PointInTimeRecoveryUnavailableException({$metadata:deserializeMetadata(ee),...ei});return(0,eo.to)(ea,en)},de_PolicyNotFoundExceptionRes=async(ee,et)=>{let en=ee.body,ei=(0,eo.F3)(en),ea=new PolicyNotFoundException({$metadata:deserializeMetadata(ee),...ei});return(0,eo.to)(ea,en)},de_ProvisionedThroughputExceededExceptionRes=async(ee,et)=>{let en=ee.body,ei=(0,eo.F3)(en),ea=new ProvisionedThroughputExceededException({$metadata:deserializeMetadata(ee),...ei});return(0,eo.to)(ea,en)},de_ReplicaAlreadyExistsExceptionRes=async(ee,et)=>{let en=ee.body,ei=(0,eo.F3)(en),ea=new ReplicaAlreadyExistsException({$metadata:deserializeMetadata(ee),...ei});return(0,eo.to)(ea,en)},de_ReplicaNotFoundExceptionRes=async(ee,et)=>{let en=ee.body,ei=(0,eo.F3)(en),ea=new ReplicaNotFoundException({$metadata:deserializeMetadata(ee),...ei});return(0,eo.to)(ea,en)},de_RequestLimitExceededRes=async(ee,et)=>{let en=ee.body,ei=(0,eo.F3)(en),ea=new RequestLimitExceeded({$metadata:deserializeMetadata(ee),...ei});return(0,eo.to)(ea,en)},de_ResourceInUseExceptionRes=async(ee,et)=>{let en=ee.body,ei=(0,eo.F3)(en),ea=new ResourceInUseException({$metadata:deserializeMetadata(ee),...ei});return(0,eo.to)(ea,en)},de_ResourceNotFoundExceptionRes=async(ee,et)=>{let en=ee.body,ei=(0,eo.F3)(en),ea=new ResourceNotFoundException({$metadata:deserializeMetadata(ee),...ei});return(0,eo.to)(ea,en)},de_TableAlreadyExistsExceptionRes=async(ee,et)=>{let en=ee.body,ei=(0,eo.F3)(en),ea=new TableAlreadyExistsException({$metadata:deserializeMetadata(ee),...ei});return(0,eo.to)(ea,en)},de_TableInUseExceptionRes=async(ee,et)=>{let en=ee.body,ei=(0,eo.F3)(en),ea=new TableInUseException({$metadata:deserializeMetadata(ee),...ei});return(0,eo.to)(ea,en)},de_TableNotFoundExceptionRes=async(ee,et)=>{let en=ee.body,ei=(0,eo.F3)(en),ea=new TableNotFoundException({$metadata:deserializeMetadata(ee),...ei});return(0,eo.to)(ea,en)},de_TransactionCanceledExceptionRes=async(ee,et)=>{let en=ee.body,ei=de_TransactionCanceledException(en,et),ea=new TransactionCanceledException({$metadata:deserializeMetadata(ee),...ei});return(0,eo.to)(ea,en)},de_TransactionConflictExceptionRes=async(ee,et)=>{let en=ee.body,ei=(0,eo.F3)(en),ea=new TransactionConflictException({$metadata:deserializeMetadata(ee),...ei});return(0,eo.to)(ea,en)},de_TransactionInProgressExceptionRes=async(ee,et)=>{let en=ee.body,ei=(0,eo.F3)(en),ea=new TransactionInProgressException({$metadata:deserializeMetadata(ee),...ei});return(0,eo.to)(ea,en)},se_AttributeUpdates=(ee,et)=>Object.entries(ee).reduce((ee,[en,ei])=>(null===ei||(ee[en]=se_AttributeValueUpdate(ei,et)),ee),{}),se_AttributeValue=(ee,et)=>ei.visit(ee,{B:ee=>({B:et.base64Encoder(ee)}),BOOL:ee=>({BOOL:ee}),BS:ee=>({BS:se_BinarySetAttributeValue(ee,et)}),L:ee=>({L:se_ListAttributeValue(ee,et)}),M:ee=>({M:se_MapAttributeValue(ee,et)}),N:ee=>({N:ee}),NS:ee=>({NS:(0,eo.F3)(ee)}),NULL:ee=>({NULL:ee}),S:ee=>({S:ee}),SS:ee=>({SS:(0,eo.F3)(ee)}),_:(ee,et)=>({name:et})}),se_AttributeValueList=(ee,et)=>ee.filter(ee=>null!=ee).map(ee=>se_AttributeValue(ee,et)),se_AttributeValueUpdate=(ee,et)=>(0,eo.qn)(ee,{Action:[],Value:ee=>se_AttributeValue(ee,et)}),se_BatchExecuteStatementInput=(ee,et)=>(0,eo.qn)(ee,{ReturnConsumedCapacity:[],Statements:ee=>se_PartiQLBatchRequest(ee,et)}),se_BatchGetItemInput=(ee,et)=>(0,eo.qn)(ee,{RequestItems:ee=>se_BatchGetRequestMap(ee,et),ReturnConsumedCapacity:[]}),se_BatchGetRequestMap=(ee,et)=>Object.entries(ee).reduce((ee,[en,ei])=>(null===ei||(ee[en]=se_KeysAndAttributes(ei,et)),ee),{}),se_BatchStatementRequest=(ee,et)=>(0,eo.qn)(ee,{ConsistentRead:[],Parameters:ee=>se_PreparedStatementParameters(ee,et),ReturnValuesOnConditionCheckFailure:[],Statement:[]}),se_BatchWriteItemInput=(ee,et)=>(0,eo.qn)(ee,{RequestItems:ee=>se_BatchWriteItemRequestMap(ee,et),ReturnConsumedCapacity:[],ReturnItemCollectionMetrics:[]}),se_BatchWriteItemRequestMap=(ee,et)=>Object.entries(ee).reduce((ee,[en,ei])=>(null===ei||(ee[en]=se_WriteRequests(ei,et)),ee),{}),se_BinarySetAttributeValue=(ee,et)=>ee.filter(ee=>null!=ee).map(ee=>et.base64Encoder(ee)),se_Condition=(ee,et)=>(0,eo.qn)(ee,{AttributeValueList:ee=>se_AttributeValueList(ee,et),ComparisonOperator:[]}),se_ConditionCheck=(ee,et)=>(0,eo.qn)(ee,{ConditionExpression:[],ExpressionAttributeNames:eo.F3,ExpressionAttributeValues:ee=>se_ExpressionAttributeValueMap(ee,et),Key:ee=>se_Key(ee,et),ReturnValuesOnConditionCheckFailure:[],TableName:[]}),se_Delete=(ee,et)=>(0,eo.qn)(ee,{ConditionExpression:[],ExpressionAttributeNames:eo.F3,ExpressionAttributeValues:ee=>se_ExpressionAttributeValueMap(ee,et),Key:ee=>se_Key(ee,et),ReturnValuesOnConditionCheckFailure:[],TableName:[]}),se_DeleteItemInput=(ee,et)=>(0,eo.qn)(ee,{ConditionExpression:[],ConditionalOperator:[],Expected:ee=>se_ExpectedAttributeMap(ee,et),ExpressionAttributeNames:eo.F3,ExpressionAttributeValues:ee=>se_ExpressionAttributeValueMap(ee,et),Key:ee=>se_Key(ee,et),ReturnConsumedCapacity:[],ReturnItemCollectionMetrics:[],ReturnValues:[],ReturnValuesOnConditionCheckFailure:[],TableName:[]}),se_DeleteRequest=(ee,et)=>(0,eo.qn)(ee,{Key:ee=>se_Key(ee,et)}),se_ExecuteStatementInput=(ee,et)=>(0,eo.qn)(ee,{ConsistentRead:[],Limit:[],NextToken:[],Parameters:ee=>se_PreparedStatementParameters(ee,et),ReturnConsumedCapacity:[],ReturnValuesOnConditionCheckFailure:[],Statement:[]}),se_ExecuteTransactionInput=(ee,et)=>(0,eo.qn)(ee,{ClientRequestToken:[!0,ee=>ee??(0,es.Z)()],ReturnConsumedCapacity:[],TransactStatements:ee=>se_ParameterizedStatements(ee,et)}),se_ExpectedAttributeMap=(ee,et)=>Object.entries(ee).reduce((ee,[en,ei])=>(null===ei||(ee[en]=se_ExpectedAttributeValue(ei,et)),ee),{}),se_ExpectedAttributeValue=(ee,et)=>(0,eo.qn)(ee,{AttributeValueList:ee=>se_AttributeValueList(ee,et),ComparisonOperator:[],Exists:[],Value:ee=>se_AttributeValue(ee,et)}),se_ExpressionAttributeValueMap=(ee,et)=>Object.entries(ee).reduce((ee,[en,ei])=>(null===ei||(ee[en]=se_AttributeValue(ei,et)),ee),{}),se_FilterConditionMap=(ee,et)=>Object.entries(ee).reduce((ee,[en,ei])=>(null===ei||(ee[en]=se_Condition(ei,et)),ee),{}),se_Get=(ee,et)=>(0,eo.qn)(ee,{ExpressionAttributeNames:eo.F3,Key:ee=>se_Key(ee,et),ProjectionExpression:[],TableName:[]}),se_GetItemInput=(ee,et)=>(0,eo.qn)(ee,{AttributesToGet:eo.F3,ConsistentRead:[],ExpressionAttributeNames:eo.F3,Key:ee=>se_Key(ee,et),ProjectionExpression:[],ReturnConsumedCapacity:[],TableName:[]}),se_Key=(ee,et)=>Object.entries(ee).reduce((ee,[en,ei])=>(null===ei||(ee[en]=se_AttributeValue(ei,et)),ee),{}),se_KeyConditions=(ee,et)=>Object.entries(ee).reduce((ee,[en,ei])=>(null===ei||(ee[en]=se_Condition(ei,et)),ee),{}),se_KeyList=(ee,et)=>ee.filter(ee=>null!=ee).map(ee=>se_Key(ee,et)),se_KeysAndAttributes=(ee,et)=>(0,eo.qn)(ee,{AttributesToGet:eo.F3,ConsistentRead:[],ExpressionAttributeNames:eo.F3,Keys:ee=>se_KeyList(ee,et),ProjectionExpression:[]}),se_ListAttributeValue=(ee,et)=>ee.filter(ee=>null!=ee).map(ee=>se_AttributeValue(ee,et)),se_MapAttributeValue=(ee,et)=>Object.entries(ee).reduce((ee,[en,ei])=>(null===ei||(ee[en]=se_AttributeValue(ei,et)),ee),{}),se_ParameterizedStatement=(ee,et)=>(0,eo.qn)(ee,{Parameters:ee=>se_PreparedStatementParameters(ee,et),ReturnValuesOnConditionCheckFailure:[],Statement:[]}),se_ParameterizedStatements=(ee,et)=>ee.filter(ee=>null!=ee).map(ee=>se_ParameterizedStatement(ee,et)),se_PartiQLBatchRequest=(ee,et)=>ee.filter(ee=>null!=ee).map(ee=>se_BatchStatementRequest(ee,et)),se_PreparedStatementParameters=(ee,et)=>ee.filter(ee=>null!=ee).map(ee=>se_AttributeValue(ee,et)),se_Put=(ee,et)=>(0,eo.qn)(ee,{ConditionExpression:[],ExpressionAttributeNames:eo.F3,ExpressionAttributeValues:ee=>se_ExpressionAttributeValueMap(ee,et),Item:ee=>se_PutItemInputAttributeMap(ee,et),ReturnValuesOnConditionCheckFailure:[],TableName:[]}),se_PutItemInput=(ee,et)=>(0,eo.qn)(ee,{ConditionExpression:[],ConditionalOperator:[],Expected:ee=>se_ExpectedAttributeMap(ee,et),ExpressionAttributeNames:eo.F3,ExpressionAttributeValues:ee=>se_ExpressionAttributeValueMap(ee,et),Item:ee=>se_PutItemInputAttributeMap(ee,et),ReturnConsumedCapacity:[],ReturnItemCollectionMetrics:[],ReturnValues:[],ReturnValuesOnConditionCheckFailure:[],TableName:[]}),se_PutItemInputAttributeMap=(ee,et)=>Object.entries(ee).reduce((ee,[en,ei])=>(null===ei||(ee[en]=se_AttributeValue(ei,et)),ee),{}),se_PutRequest=(ee,et)=>(0,eo.qn)(ee,{Item:ee=>se_PutItemInputAttributeMap(ee,et)}),se_QueryInput=(ee,et)=>(0,eo.qn)(ee,{AttributesToGet:eo.F3,ConditionalOperator:[],ConsistentRead:[],ExclusiveStartKey:ee=>se_Key(ee,et),ExpressionAttributeNames:eo.F3,ExpressionAttributeValues:ee=>se_ExpressionAttributeValueMap(ee,et),FilterExpression:[],IndexName:[],KeyConditionExpression:[],KeyConditions:ee=>se_KeyConditions(ee,et),Limit:[],ProjectionExpression:[],QueryFilter:ee=>se_FilterConditionMap(ee,et),ReturnConsumedCapacity:[],ScanIndexForward:[],Select:[],TableName:[]}),se_ScanInput=(ee,et)=>(0,eo.qn)(ee,{AttributesToGet:eo.F3,ConditionalOperator:[],ConsistentRead:[],ExclusiveStartKey:ee=>se_Key(ee,et),ExpressionAttributeNames:eo.F3,ExpressionAttributeValues:ee=>se_ExpressionAttributeValueMap(ee,et),FilterExpression:[],IndexName:[],Limit:[],ProjectionExpression:[],ReturnConsumedCapacity:[],ScanFilter:ee=>se_FilterConditionMap(ee,et),Segment:[],Select:[],TableName:[],TotalSegments:[]}),se_TransactGetItem=(ee,et)=>(0,eo.qn)(ee,{Get:ee=>se_Get(ee,et)}),se_TransactGetItemList=(ee,et)=>ee.filter(ee=>null!=ee).map(ee=>se_TransactGetItem(ee,et)),se_TransactGetItemsInput=(ee,et)=>(0,eo.qn)(ee,{ReturnConsumedCapacity:[],TransactItems:ee=>se_TransactGetItemList(ee,et)}),se_TransactWriteItem=(ee,et)=>(0,eo.qn)(ee,{ConditionCheck:ee=>se_ConditionCheck(ee,et),Delete:ee=>se_Delete(ee,et),Put:ee=>se_Put(ee,et),Update:ee=>se_Update(ee,et)}),se_TransactWriteItemList=(ee,et)=>ee.filter(ee=>null!=ee).map(ee=>se_TransactWriteItem(ee,et)),se_TransactWriteItemsInput=(ee,et)=>(0,eo.qn)(ee,{ClientRequestToken:[!0,ee=>ee??(0,es.Z)()],ReturnConsumedCapacity:[],ReturnItemCollectionMetrics:[],TransactItems:ee=>se_TransactWriteItemList(ee,et)}),se_Update=(ee,et)=>(0,eo.qn)(ee,{ConditionExpression:[],ExpressionAttributeNames:eo.F3,ExpressionAttributeValues:ee=>se_ExpressionAttributeValueMap(ee,et),Key:ee=>se_Key(ee,et),ReturnValuesOnConditionCheckFailure:[],TableName:[],UpdateExpression:[]}),se_UpdateItemInput=(ee,et)=>(0,eo.qn)(ee,{AttributeUpdates:ee=>se_AttributeUpdates(ee,et),ConditionExpression:[],ConditionalOperator:[],Expected:ee=>se_ExpectedAttributeMap(ee,et),ExpressionAttributeNames:eo.F3,ExpressionAttributeValues:ee=>se_ExpressionAttributeValueMap(ee,et),Key:ee=>se_Key(ee,et),ReturnConsumedCapacity:[],ReturnItemCollectionMetrics:[],ReturnValues:[],ReturnValuesOnConditionCheckFailure:[],TableName:[],UpdateExpression:[]}),se_WriteRequest=(ee,et)=>(0,eo.qn)(ee,{DeleteRequest:ee=>se_DeleteRequest(ee,et),PutRequest:ee=>se_PutRequest(ee,et)}),se_WriteRequests=(ee,et)=>ee.filter(ee=>null!=ee).map(ee=>se_WriteRequest(ee,et)),de_AttributeMap=(ee,et)=>Object.entries(ee).reduce((ee,[en,ei])=>(null===ei||(ee[en]=de_AttributeValue(awsExpectUnion(ei),et)),ee),{}),de_AttributeValue=(ee,et)=>null!=ee.B?{B:et.base64Decoder(ee.B)}:void 0!==(0,eo.zE)(ee.BOOL)?{BOOL:(0,eo.zE)(ee.BOOL)}:null!=ee.BS?{BS:de_BinarySetAttributeValue(ee.BS,et)}:null!=ee.L?{L:de_ListAttributeValue(ee.L,et)}:null!=ee.M?{M:de_MapAttributeValue(ee.M,et)}:void 0!==(0,eo.pY)(ee.N)?{N:(0,eo.pY)(ee.N)}:null!=ee.NS?{NS:(0,eo.F3)(ee.NS)}:void 0!==(0,eo.zE)(ee.NULL)?{NULL:(0,eo.zE)(ee.NULL)}:void 0!==(0,eo.pY)(ee.S)?{S:(0,eo.pY)(ee.S)}:null!=ee.SS?{SS:(0,eo.F3)(ee.SS)}:{$unknown:Object.entries(ee)[0]},de_BatchExecuteStatementOutput=(ee,et)=>(0,eo.qn)(ee,{ConsumedCapacity:ee=>de_ConsumedCapacityMultiple(ee,et),Responses:ee=>de_PartiQLBatchResponse(ee,et)}),de_BatchGetItemOutput=(ee,et)=>(0,eo.qn)(ee,{ConsumedCapacity:ee=>de_ConsumedCapacityMultiple(ee,et),Responses:ee=>de_BatchGetResponseMap(ee,et),UnprocessedKeys:ee=>de_BatchGetRequestMap(ee,et)}),de_BatchGetRequestMap=(ee,et)=>Object.entries(ee).reduce((ee,[en,ei])=>(null===ei||(ee[en]=de_KeysAndAttributes(ei,et)),ee),{}),de_BatchGetResponseMap=(ee,et)=>Object.entries(ee).reduce((ee,[en,ei])=>(null===ei||(ee[en]=de_ItemList(ei,et)),ee),{}),de_BatchStatementError=(ee,et)=>(0,eo.qn)(ee,{Code:eo.pY,Item:ee=>de_AttributeMap(ee,et),Message:eo.pY}),de_BatchStatementResponse=(ee,et)=>(0,eo.qn)(ee,{Error:ee=>de_BatchStatementError(ee,et),Item:ee=>de_AttributeMap(ee,et),TableName:eo.pY}),de_BatchWriteItemOutput=(ee,et)=>(0,eo.qn)(ee,{ConsumedCapacity:ee=>de_ConsumedCapacityMultiple(ee,et),ItemCollectionMetrics:ee=>de_ItemCollectionMetricsPerTable(ee,et),UnprocessedItems:ee=>de_BatchWriteItemRequestMap(ee,et)}),de_BatchWriteItemRequestMap=(ee,et)=>Object.entries(ee).reduce((ee,[en,ei])=>(null===ei||(ee[en]=de_WriteRequests(ei,et)),ee),{}),de_BinarySetAttributeValue=(ee,et)=>{let en=(ee||[]).filter(ee=>null!=ee).map(ee=>et.base64Decoder(ee));return en},de_CancellationReason=(ee,et)=>(0,eo.qn)(ee,{Code:eo.pY,Item:ee=>de_AttributeMap(ee,et),Message:eo.pY}),de_CancellationReasonList=(ee,et)=>{let en=(ee||[]).filter(ee=>null!=ee).map(ee=>de_CancellationReason(ee,et));return en},de_Capacity=(ee,et)=>(0,eo.qn)(ee,{CapacityUnits:eo.mr,ReadCapacityUnits:eo.mr,WriteCapacityUnits:eo.mr}),de_ConditionalCheckFailedException=(ee,et)=>(0,eo.qn)(ee,{Item:ee=>de_AttributeMap(ee,et),message:eo.pY}),de_ConsumedCapacity=(ee,et)=>(0,eo.qn)(ee,{CapacityUnits:eo.mr,GlobalSecondaryIndexes:ee=>de_SecondaryIndexesCapacityMap(ee,et),LocalSecondaryIndexes:ee=>de_SecondaryIndexesCapacityMap(ee,et),ReadCapacityUnits:eo.mr,Table:ee=>de_Capacity(ee,et),TableName:eo.pY,WriteCapacityUnits:eo.mr}),de_ConsumedCapacityMultiple=(ee,et)=>{let en=(ee||[]).filter(ee=>null!=ee).map(ee=>de_ConsumedCapacity(ee,et));return en},de_DeleteItemOutput=(ee,et)=>(0,eo.qn)(ee,{Attributes:ee=>de_AttributeMap(ee,et),ConsumedCapacity:ee=>de_ConsumedCapacity(ee,et),ItemCollectionMetrics:ee=>de_ItemCollectionMetrics(ee,et)}),de_DeleteRequest=(ee,et)=>(0,eo.qn)(ee,{Key:ee=>de_Key(ee,et)}),de_ExecuteStatementOutput=(ee,et)=>(0,eo.qn)(ee,{ConsumedCapacity:ee=>de_ConsumedCapacity(ee,et),Items:ee=>de_ItemList(ee,et),LastEvaluatedKey:ee=>de_Key(ee,et),NextToken:eo.pY}),de_ExecuteTransactionOutput=(ee,et)=>(0,eo.qn)(ee,{ConsumedCapacity:ee=>de_ConsumedCapacityMultiple(ee,et),Responses:ee=>de_ItemResponseList(ee,et)}),de_GetItemOutput=(ee,et)=>(0,eo.qn)(ee,{ConsumedCapacity:ee=>de_ConsumedCapacity(ee,et),Item:ee=>de_AttributeMap(ee,et)}),de_ItemCollectionKeyAttributeMap=(ee,et)=>Object.entries(ee).reduce((ee,[en,ei])=>(null===ei||(ee[en]=de_AttributeValue(awsExpectUnion(ei),et)),ee),{}),de_ItemCollectionMetrics=(ee,et)=>(0,eo.qn)(ee,{ItemCollectionKey:ee=>de_ItemCollectionKeyAttributeMap(ee,et),SizeEstimateRangeGB:ee=>de_ItemCollectionSizeEstimateRange(ee,et)}),de_ItemCollectionMetricsMultiple=(ee,et)=>{let en=(ee||[]).filter(ee=>null!=ee).map(ee=>de_ItemCollectionMetrics(ee,et));return en},de_ItemCollectionMetricsPerTable=(ee,et)=>Object.entries(ee).reduce((ee,[en,ei])=>(null===ei||(ee[en]=de_ItemCollectionMetricsMultiple(ei,et)),ee),{}),de_ItemCollectionSizeEstimateRange=(ee,et)=>{let en=(ee||[]).filter(ee=>null!=ee).map(ee=>(0,eo.mr)(ee));return en},de_ItemList=(ee,et)=>{let en=(ee||[]).filter(ee=>null!=ee).map(ee=>de_AttributeMap(ee,et));return en},de_ItemResponse=(ee,et)=>(0,eo.qn)(ee,{Item:ee=>de_AttributeMap(ee,et)}),de_ItemResponseList=(ee,et)=>{let en=(ee||[]).filter(ee=>null!=ee).map(ee=>de_ItemResponse(ee,et));return en},de_Key=(ee,et)=>Object.entries(ee).reduce((ee,[en,ei])=>(null===ei||(ee[en]=de_AttributeValue(awsExpectUnion(ei),et)),ee),{}),de_KeyList=(ee,et)=>{let en=(ee||[]).filter(ee=>null!=ee).map(ee=>de_Key(ee,et));return en},de_KeysAndAttributes=(ee,et)=>(0,eo.qn)(ee,{AttributesToGet:eo.F3,ConsistentRead:eo.zE,ExpressionAttributeNames:eo.F3,Keys:ee=>de_KeyList(ee,et),ProjectionExpression:eo.pY}),de_ListAttributeValue=(ee,et)=>{let en=(ee||[]).filter(ee=>null!=ee).map(ee=>de_AttributeValue(awsExpectUnion(ee),et));return en},de_MapAttributeValue=(ee,et)=>Object.entries(ee).reduce((ee,[en,ei])=>(null===ei||(ee[en]=de_AttributeValue(awsExpectUnion(ei),et)),ee),{}),de_PartiQLBatchResponse=(ee,et)=>{let en=(ee||[]).filter(ee=>null!=ee).map(ee=>de_BatchStatementResponse(ee,et));return en},de_PutItemInputAttributeMap=(ee,et)=>Object.entries(ee).reduce((ee,[en,ei])=>(null===ei||(ee[en]=de_AttributeValue(awsExpectUnion(ei),et)),ee),{}),de_PutItemOutput=(ee,et)=>(0,eo.qn)(ee,{Attributes:ee=>de_AttributeMap(ee,et),ConsumedCapacity:ee=>de_ConsumedCapacity(ee,et),ItemCollectionMetrics:ee=>de_ItemCollectionMetrics(ee,et)}),de_PutRequest=(ee,et)=>(0,eo.qn)(ee,{Item:ee=>de_PutItemInputAttributeMap(ee,et)}),de_QueryOutput=(ee,et)=>(0,eo.qn)(ee,{ConsumedCapacity:ee=>de_ConsumedCapacity(ee,et),Count:eo.u$,Items:ee=>de_ItemList(ee,et),LastEvaluatedKey:ee=>de_Key(ee,et),ScannedCount:eo.u$}),de_ScanOutput=(ee,et)=>(0,eo.qn)(ee,{ConsumedCapacity:ee=>de_ConsumedCapacity(ee,et),Count:eo.u$,Items:ee=>de_ItemList(ee,et),LastEvaluatedKey:ee=>de_Key(ee,et),ScannedCount:eo.u$}),de_SecondaryIndexesCapacityMap=(ee,et)=>Object.entries(ee).reduce((ee,[en,ei])=>(null===ei||(ee[en]=de_Capacity(ei,et)),ee),{}),de_TransactGetItemsOutput=(ee,et)=>(0,eo.qn)(ee,{ConsumedCapacity:ee=>de_ConsumedCapacityMultiple(ee,et),Responses:ee=>de_ItemResponseList(ee,et)}),de_TransactionCanceledException=(ee,et)=>(0,eo.qn)(ee,{CancellationReasons:ee=>de_CancellationReasonList(ee,et),Message:eo.pY}),de_TransactWriteItemsOutput=(ee,et)=>(0,eo.qn)(ee,{ConsumedCapacity:ee=>de_ConsumedCapacityMultiple(ee,et),ItemCollectionMetrics:ee=>de_ItemCollectionMetricsPerTable(ee,et)}),de_UpdateItemOutput=(ee,et)=>(0,eo.qn)(ee,{Attributes:ee=>de_AttributeMap(ee,et),ConsumedCapacity:ee=>de_ConsumedCapacity(ee,et),ItemCollectionMetrics:ee=>de_ItemCollectionMetrics(ee,et)}),de_WriteRequest=(ee,et)=>(0,eo.qn)(ee,{DeleteRequest:ee=>de_DeleteRequest(ee,et),PutRequest:ee=>de_PutRequest(ee,et)}),de_WriteRequests=(ee,et)=>{let en=(ee||[]).filter(ee=>null!=ee).map(ee=>de_WriteRequest(ee,et));return en},deserializeMetadata=ee=>({httpStatusCode:ee.statusCode,requestId:ee.headers["x-amzn-requestid"]??ee.headers["x-amzn-request-id"]??ee.headers["x-amz-request-id"],extendedRequestId:ee.headers["x-amz-id-2"],cfId:ee.headers["x-amz-cf-id"]}),eu=(0,eo.PC)(DynamoDBServiceException),buildHttpRpcRequest=async(ee,et,en,ei,eo)=>{let{hostname:es,protocol:eu="https",port:ec,path:ed}=await ee.endpoint(),ef={protocol:eu,hostname:es,port:ec,method:"POST",path:ed.endsWith("/")?ed.slice(0,-1)+en:ed+en,headers:et};return void 0!==ei&&(ef.hostname=ei),void 0!==eo&&(ef.body=eo),new ea.aW(ef)};function sharedHeaders(ee){return{"content-type":"application/x-amz-json-1.0","x-amz-target":`DynamoDB_20120810.${ee}`}}},63087:function(ee,et,en){"use strict";en.d(et,{BX:function(){return FetchHttpHandler},CF:function(){return streamCollector}});var ei=en(43979),eo=en(50516);function buildQueryString(ee){let et=[];for(let en of Object.keys(ee).sort()){let ei=ee[en];if(en=(0,eo.i)(en),Array.isArray(ei))for(let ee=0,ea=ei.length;ee{ee&&setTimeout(()=>{let et=Error(`Request did not complete within ${ee} ms`);et.name="TimeoutError",en(et)},ee)})}let ea={supported:void 0};let FetchHttpHandler=class FetchHttpHandler{static create(ee){return"function"==typeof ee?.handle?ee:new FetchHttpHandler(ee)}constructor(ee){"function"==typeof ee?this.configProvider=ee().then(ee=>ee||{}):(this.config=ee??{},this.configProvider=Promise.resolve(this.config)),void 0===ea.supported&&(ea.supported=!!("undefined"!=typeof Request&&"keepalive"in new Request("https://[::1]")))}destroy(){}async handle(ee,{abortSignal:et}={}){this.config||(this.config=await this.configProvider);let en=this.config.requestTimeout,eo=!0===this.config.keepAlive,es=this.config.credentials;if(et?.aborted){let ee=Error("Request aborted");return ee.name="AbortError",Promise.reject(ee)}let eu=ee.path,ec=buildQueryString(ee.query||{});ec&&(eu+=`?${ec}`),ee.fragment&&(eu+=`#${ee.fragment}`);let ed="";if(null!=ee.username||null!=ee.password){let et=ee.username??"",en=ee.password??"";ed=`${et}:${en}@`}let{port:ef,method:ep}=ee,eh=`${ee.protocol}//${ed}${ee.hostname}${ef?`:${ef}`:""}${eu}`,ey="GET"===ep||"HEAD"===ep?void 0:ee.body,em={body:ey,headers:new Headers(ee.headers),method:ep,credentials:es,cache:this.config.cache??"default"};ey&&(em.duplex="half"),"undefined"!=typeof AbortController&&(em.signal=et),ea.supported&&(em.keepalive=eo),"function"==typeof this.config.requestInit&&Object.assign(em,this.config.requestInit(ee));let removeSignalEventListener=()=>{},eg=new Request(eh,em),eb=[fetch(eg).then(ee=>{let et=ee.headers,en={};for(let ee of et.entries())en[ee[0]]=ee[1];let eo=void 0!=ee.body;return eo?{response:new ei.Zn({headers:en,reason:ee.statusText,statusCode:ee.status,body:ee.body})}:ee.blob().then(et=>({response:new ei.Zn({headers:en,reason:ee.statusText,statusCode:ee.status,body:et})}))}),requestTimeout(en)];return et&&eb.push(new Promise((ee,en)=>{let onAbort=()=>{let ee=Error("Request aborted");ee.name="AbortError",en(ee)};if("function"==typeof et.addEventListener){let ee=et;ee.addEventListener("abort",onAbort,{once:!0}),removeSignalEventListener=()=>ee.removeEventListener("abort",onAbort)}else et.onabort=onAbort})),Promise.race(eb).finally(removeSignalEventListener)}updateHttpClientConfig(ee,et){this.config=void 0,this.configProvider=this.configProvider.then(en=>(en[ee]=et,en))}httpHandlerConfigs(){return this.config??{}}};var es=en(65368);let streamCollector=ee=>"function"==typeof Blob&&ee instanceof Blob?collectBlob(ee):collectStream(ee);async function collectBlob(ee){let et=await readToBase64(ee),en=(0,es.G)(et);return new Uint8Array(en)}async function collectStream(ee){let et=[],en=ee.getReader(),ei=!1,eo=0;for(;!ei;){let{done:ee,value:ea}=await en.read();ea&&(et.push(ea),eo+=ea.length),ei=ee}let ea=new Uint8Array(eo),es=0;for(let ee of et)ea.set(ee,es),es+=ee.length;return ea}function readToBase64(ee){return new Promise((et,en)=>{let ei=new FileReader;ei.onloadend=()=>{if(2!==ei.readyState)return en(Error("Reader aborted too early"));let ee=ei.result??"",eo=ee.indexOf(","),ea=eo>-1?eo+1:ee.length;et(ee.substring(ea))},ei.onabort=()=>en(Error("Read aborted")),ei.onerror=()=>en(ei.error),ei.readAsDataURL(ee)})}},21093:function(ee,et,en){"use strict";en.d(et,{a3:function(){return getEndpointPlugin},uW:function(){return resolveEndpointConfig}});var ei=en(61032);let resolveParamsForS3=async ee=>{let et=ee?.Bucket||"";if("string"==typeof ee.Bucket&&(ee.Bucket=et.replace(/#/g,encodeURIComponent("#")).replace(/\?/g,encodeURIComponent("?"))),isArnBucketName(et)){if(!0===ee.ForcePathStyle)throw Error("Path-style addressing cannot be used with ARN buckets")}else isDnsCompatibleBucketName(et)&&(-1===et.indexOf(".")||String(ee.Endpoint).startsWith("http:"))&&et.toLowerCase()===et&&!(et.length<3)||(ee.ForcePathStyle=!0);return ee.DisableMultiRegionAccessPoints&&(ee.disableMultiRegionAccessPoints=!0,ee.DisableMRAP=!0),ee},eo=/^[a-z0-9][a-z0-9\.\-]{1,61}[a-z0-9]$/,ea=/(\d+\.){3}\d+/,es=/\.\./,isDnsCompatibleBucketName=ee=>eo.test(ee)&&!ea.test(ee)&&!es.test(ee),isArnBucketName=ee=>{let[et,en,ei,,,eo]=ee.split(":"),ea="arn"===et&&ee.split(":").length>=6,es=!!(ea&&en&&ei&&eo);if(ea&&!es)throw Error(`Invalid ARN: ${ee} was an invalid ARN.`);return es},createConfigValueProvider=(ee,et,en)=>{let configProvider=async()=>{let ei=en[ee]??en[et];return"function"==typeof ei?ei():ei};return"credentialScope"===ee||"CredentialScope"===et?async()=>{let ee="function"==typeof en.credentials?await en.credentials():en.credentials,et=ee?.credentialScope??ee?.CredentialScope;return et}:"accountId"===ee||"AccountId"===et?async()=>{let ee="function"==typeof en.credentials?await en.credentials():en.credentials,et=ee?.accountId??ee?.AccountId;return et}:"endpoint"===ee||"endpoint"===et?async()=>{let ee=await configProvider();if(ee&&"object"==typeof ee){if("url"in ee)return ee.url.href;if("hostname"in ee){let{protocol:et,hostname:en,port:ei,path:eo}=ee;return`${et}//${en}${ei?":"+ei:""}${eo}`}}return ee}:configProvider},getEndpointFromConfig=async ee=>void 0;var eu=en(94317);let toEndpointV1=ee=>"object"==typeof ee?"url"in ee?(0,eu.e)(ee.url):ee:(0,eu.e)(ee),getEndpointFromInstructions=async(ee,et,en,ei)=>{if(!en.endpoint){let ee;(ee=en.serviceConfiguredEndpoint?await en.serviceConfiguredEndpoint():await getEndpointFromConfig(en.serviceId))&&(en.endpoint=()=>Promise.resolve(toEndpointV1(ee)))}let eo=await resolveParams(ee,et,en);if("function"!=typeof en.endpointProvider)throw Error("config.endpointProvider is not set.");let ea=en.endpointProvider(eo,ei);return ea},resolveParams=async(ee,et,en)=>{let ei={},eo=et?.getEndpointParameterInstructions?.()||{};for(let[et,ea]of Object.entries(eo))switch(ea.type){case"staticContextParams":ei[et]=ea.value;break;case"contextParams":ei[et]=ee[ea.name];break;case"clientContextParams":case"builtInParams":ei[et]=await createConfigValueProvider(ea.name,et,en)();break;default:throw Error("Unrecognized endpoint parameter instruction: "+JSON.stringify(ea))}return 0===Object.keys(eo).length&&Object.assign(ei,en),"s3"===String(en.serviceId).toLowerCase()&&await resolveParamsForS3(ei),ei},endpointMiddleware=({config:ee,instructions:et})=>(en,eo)=>async ea=>{let es=await getEndpointFromInstructions(ea.input,{getEndpointParameterInstructions:()=>et},{...ee},eo);eo.endpointV2=es,eo.authSchemes=es.properties?.authSchemes;let eu=eo.authSchemes?.[0];if(eu){eo.signing_region=eu.signingRegion,eo.signing_service=eu.signingName;let ee=(0,ei.J)(eo),et=ee?.selectedHttpAuthScheme?.httpAuthOption;et&&(et.signingProperties=Object.assign(et.signingProperties||{},{signing_region:eu.signingRegion,signingRegion:eu.signingRegion,signing_service:eu.signingName,signingName:eu.signingName,signingRegionSet:eu.signingRegionSet},eu.properties))}return en({...ea})};var ec=en(93270);let ed={step:"serialize",tags:["ENDPOINT_PARAMETERS","ENDPOINT_V2","ENDPOINT"],name:"endpointV2Middleware",override:!0,relation:"before",toMiddleware:ec.JK.name},getEndpointPlugin=(ee,et)=>({applyToStack:en=>{en.addRelativeTo(endpointMiddleware({config:ee,instructions:et}),ed)}}),resolveEndpointConfig=ee=>{let et;let en=ee.tls??!0,{endpoint:eo}=ee,ea=null!=eo?async()=>toEndpointV1(await (0,ei.$)(eo)()):void 0,es=!!eo,eu={...ee,endpoint:ea,tls:en,isCustomEndpoint:es,useDualstackEndpoint:(0,ei.$)(ee.useDualstackEndpoint??!1),useFipsEndpoint:(0,ei.$)(ee.useFipsEndpoint??!1)};return eu.serviceConfiguredEndpoint=async()=>(ee.serviceId&&!et&&(et=getEndpointFromConfig(ee.serviceId)),et),eu}},93270:function(ee,et,en){"use strict";en.d(et,{p2:function(){return getSerdePlugin},JK:function(){return eo}});let deserializerMiddleware=(ee,et)=>en=>async ei=>{let{response:eo}=await en(ei);try{let en=await et(eo,ee);return{response:eo,output:en}}catch(ee){if(Object.defineProperty(ee,"$response",{value:eo}),!("$metadata"in ee)){let et="Deserialization error: to see the raw response, inspect the hidden field {error}.$response on this object.";ee.message+="\n "+et,void 0!==ee.$responseBodyText&&ee.$response&&(ee.$response.body=ee.$responseBodyText)}throw ee}},serializerMiddleware=(ee,et)=>(en,ei)=>async eo=>{let ea=ei.endpointV2?.url&&ee.urlParser?async()=>ee.urlParser(ei.endpointV2.url):ee.endpoint;if(!ea)throw Error("No valid endpoint provider available.");let es=await et(eo.input,{...ee,endpoint:ea});return en({...eo,request:es})},ei={name:"deserializerMiddleware",step:"deserialize",tags:["DESERIALIZER"],override:!0},eo={name:"serializerMiddleware",step:"serialize",tags:["SERIALIZER"],override:!0};function getSerdePlugin(ee,et,en){return{applyToStack:ea=>{ea.add(deserializerMiddleware(ee,en),ei),ea.add(serializerMiddleware(ee,et),eo)}}}},43979:function(ee,et,en){"use strict";en.d(et,{aW:function(){return HttpRequest},Zn:function(){return HttpResponse},cA:function(){return getHttpHandlerExtensionConfiguration},AO:function(){return resolveHttpHandlerRuntimeConfig}});let getHttpHandlerExtensionConfiguration=ee=>{let et=ee.httpHandler;return{setHttpHandler(ee){et=ee},httpHandler:()=>et,updateHttpClientConfig(ee,en){et.updateHttpClientConfig(ee,en)},httpHandlerConfigs:()=>et.httpHandlerConfigs()}},resolveHttpHandlerRuntimeConfig=ee=>({httpHandler:ee.httpHandler()});en(63518);let HttpRequest=class HttpRequest{constructor(ee){this.method=ee.method||"GET",this.hostname=ee.hostname||"localhost",this.port=ee.port,this.query=ee.query||{},this.headers=ee.headers||{},this.body=ee.body,this.protocol=ee.protocol?":"!==ee.protocol.slice(-1)?`${ee.protocol}:`:ee.protocol:"https:",this.path=ee.path?"/"!==ee.path.charAt(0)?`/${ee.path}`:ee.path:"/",this.username=ee.username,this.password=ee.password,this.fragment=ee.fragment}static clone(ee){let et=new HttpRequest({...ee,headers:{...ee.headers}});return et.query&&(et.query=cloneQuery(et.query)),et}static isInstance(ee){if(!ee)return!1;let et=ee;return"method"in et&&"protocol"in et&&"hostname"in et&&"path"in et&&"object"==typeof et.query&&"object"==typeof et.headers}clone(){return HttpRequest.clone(this)}};function cloneQuery(ee){return Object.keys(ee).reduce((et,en)=>{let ei=ee[en];return{...et,[en]:Array.isArray(ei)?[...ei]:ei}},{})}let HttpResponse=class HttpResponse{constructor(ee){this.statusCode=ee.statusCode,this.reason=ee.reason,this.headers=ee.headers||{},this.body=ee.body}static isInstance(ee){if(!ee)return!1;let et=ee;return"number"==typeof et.statusCode&&"object"==typeof et.headers}}},70391:function(ee,et,en){"use strict";en.d(et,{KU:function(){return Client},mY:function(){return Command},vk:function(){return NoOpLogger},sI:function(){return ServiceException},F3:function(){return _json},Wg:function(){return collectBody},to:function(){return decorateServiceException},zE:function(){return expectBoolean},u$:function(){return expectInt32},pY:function(){return expectString},$I:function(){return expectUnion},kE:function(){return getDefaultExtensionConfiguration},mr:function(){return limitedParseDouble},jv:function(){return loadConfigsForDefaultMode},SQ:function(){return resolveDefaultRuntimeConfig},qn:function(){return take},PC:function(){return withBaseException}});let NoOpLogger=class NoOpLogger{trace(){}debug(){}info(){}warn(){}error(){}};let getAllAliases=(ee,et)=>{let en=[];if(ee&&en.push(ee),et)for(let ee of et)en.push(ee);return en},getMiddlewareNameWithAliases=(ee,et)=>`${ee||"anonymous"}${et&&et.length>0?` (a.k.a. ${et.join(",")})`:""}`,constructStack=()=>{let ee=[],et=[],en=!1,ea=new Set,sort=ee=>ee.sort((ee,et)=>ei[et.step]-ei[ee.step]||eo[et.priority||"normal"]-eo[ee.priority||"normal"]),removeByName=en=>{let ei=!1,filterCb=ee=>{let et=getAllAliases(ee.name,ee.aliases);if(et.includes(en)){for(let ee of(ei=!0,et))ea.delete(ee);return!1}return!0};return ee=ee.filter(filterCb),et=et.filter(filterCb),ei},removeByReference=en=>{let ei=!1,filterCb=ee=>{if(ee.middleware===en){for(let et of(ei=!0,getAllAliases(ee.name,ee.aliases)))ea.delete(et);return!1}return!0};return ee=ee.filter(filterCb),et=et.filter(filterCb),ei},cloneTo=en=>(ee.forEach(ee=>{en.add(ee.middleware,{...ee})}),et.forEach(ee=>{en.addRelativeTo(ee.middleware,{...ee})}),en.identifyOnResolve?.(es.identifyOnResolve()),en),expandRelativeMiddlewareList=ee=>{let et=[];return ee.before.forEach(ee=>{0===ee.before.length&&0===ee.after.length?et.push(ee):et.push(...expandRelativeMiddlewareList(ee))}),et.push(ee),ee.after.reverse().forEach(ee=>{0===ee.before.length&&0===ee.after.length?et.push(ee):et.push(...expandRelativeMiddlewareList(ee))}),et},getMiddlewareList=(en=!1)=>{let ei=[],eo=[],ea={};ee.forEach(ee=>{let et={...ee,before:[],after:[]};for(let ee of getAllAliases(et.name,et.aliases))ea[ee]=et;ei.push(et)}),et.forEach(ee=>{let et={...ee,before:[],after:[]};for(let ee of getAllAliases(et.name,et.aliases))ea[ee]=et;eo.push(et)}),eo.forEach(ee=>{if(ee.toMiddleware){let et=ea[ee.toMiddleware];if(void 0===et){if(en)return;throw Error(`${ee.toMiddleware} is not found when adding ${getMiddlewareNameWithAliases(ee.name,ee.aliases)} middleware ${ee.relation} ${ee.toMiddleware}`)}"after"===ee.relation&&et.after.push(ee),"before"===ee.relation&&et.before.push(ee)}});let es=sort(ei).map(expandRelativeMiddlewareList).reduce((ee,et)=>(ee.push(...et),ee),[]);return es},es={add:(et,en={})=>{let{name:ei,override:eo,aliases:es}=en,eu={step:"initialize",priority:"normal",middleware:et,...en},ec=getAllAliases(ei,es);if(ec.length>0){if(ec.some(ee=>ea.has(ee))){if(!eo)throw Error(`Duplicate middleware name '${getMiddlewareNameWithAliases(ei,es)}'`);for(let et of ec){let en=ee.findIndex(ee=>ee.name===et||ee.aliases?.some(ee=>ee===et));if(-1===en)continue;let eo=ee[en];if(eo.step!==eu.step||eu.priority!==eo.priority)throw Error(`"${getMiddlewareNameWithAliases(eo.name,eo.aliases)}" middleware with ${eo.priority} priority in ${eo.step} step cannot be overridden by "${getMiddlewareNameWithAliases(ei,es)}" middleware with ${eu.priority} priority in ${eu.step} step.`);ee.splice(en,1)}}for(let ee of ec)ea.add(ee)}ee.push(eu)},addRelativeTo:(ee,en)=>{let{name:ei,override:eo,aliases:es}=en,eu={middleware:ee,...en},ec=getAllAliases(ei,es);if(ec.length>0){if(ec.some(ee=>ea.has(ee))){if(!eo)throw Error(`Duplicate middleware name '${getMiddlewareNameWithAliases(ei,es)}'`);for(let ee of ec){let en=et.findIndex(et=>et.name===ee||et.aliases?.some(et=>et===ee));if(-1===en)continue;let eo=et[en];if(eo.toMiddleware!==eu.toMiddleware||eo.relation!==eu.relation)throw Error(`"${getMiddlewareNameWithAliases(eo.name,eo.aliases)}" middleware ${eo.relation} "${eo.toMiddleware}" middleware cannot be overridden by "${getMiddlewareNameWithAliases(ei,es)}" middleware ${eu.relation} "${eu.toMiddleware}" middleware.`);et.splice(en,1)}}for(let ee of ec)ea.add(ee)}et.push(eu)},clone:()=>cloneTo(constructStack()),use:ee=>{ee.applyToStack(es)},remove:ee=>"string"==typeof ee?removeByName(ee):removeByReference(ee),removeByTag:en=>{let ei=!1,filterCb=ee=>{let{tags:et,name:eo,aliases:es}=ee;if(et&&et.includes(en)){let ee=getAllAliases(eo,es);for(let et of ee)ea.delete(et);return ei=!0,!1}return!0};return ee=ee.filter(filterCb),et=et.filter(filterCb),ei},concat:ee=>{let et=cloneTo(constructStack());return et.use(ee),et.identifyOnResolve(en||et.identifyOnResolve()||(ee.identifyOnResolve?.()??!1)),et},applyToStack:cloneTo,identify:()=>getMiddlewareList(!0).map(ee=>{let et=ee.step??ee.relation+" "+ee.toMiddleware;return getMiddlewareNameWithAliases(ee.name,ee.aliases)+" - "+et}),identifyOnResolve:ee=>("boolean"==typeof ee&&(en=ee),en),resolve:(ee,et)=>{for(let en of getMiddlewareList().map(ee=>ee.middleware).reverse())ee=en(ee,et);return en&&console.log(es.identify()),ee}};return es},ei={initialize:5,serialize:4,build:3,finalizeRequest:2,deserialize:1},eo={high:3,normal:2,low:1};let Client=class Client{constructor(ee){this.config=ee,this.middlewareStack=constructStack()}send(ee,et,en){let ei;let eo="function"!=typeof et?et:void 0,ea="function"==typeof et?et:en,es=void 0===eo&&!0===this.config.cacheMiddleware;if(es){this.handlers||(this.handlers=new WeakMap);let et=this.handlers;et.has(ee.constructor)?ei=et.get(ee.constructor):(ei=ee.resolveMiddleware(this.middlewareStack,this.config,eo),et.set(ee.constructor,ei))}else delete this.handlers,ei=ee.resolveMiddleware(this.middlewareStack,this.config,eo);if(!ea)return ei(ee).then(ee=>ee.output);ei(ee).then(ee=>ea(null,ee.output),ee=>ea(ee)).catch(()=>{})}destroy(){this.config?.requestHandler?.destroy?.(),delete this.handlers}};var ea=en(65368),es=en(88608),eu=en(45854);function transformToString(ee,et="utf-8"){return"base64"===et?(0,ea.s)(ee):(0,es.G)(ee)}function transformFromString(ee,et){return"base64"===et?Uint8ArrayBlobAdapter.mutate((0,ea.G)(ee)):Uint8ArrayBlobAdapter.mutate((0,eu.$)(ee))}let Uint8ArrayBlobAdapter=class Uint8ArrayBlobAdapter extends Uint8Array{static fromString(ee,et="utf-8"){if("string"==typeof ee)return transformFromString(ee,et);throw Error(`Unsupported conversion from ${typeof ee} to Uint8ArrayBlobAdapter.`)}static mutate(ee){return Object.setPrototypeOf(ee,Uint8ArrayBlobAdapter.prototype),ee}transformToString(ee="utf-8"){return transformToString(this,ee)}};en(63087),en(63645);let collectBody=async(ee=new Uint8Array,et)=>{if(ee instanceof Uint8Array)return Uint8ArrayBlobAdapter.mutate(ee);if(!ee)return Uint8ArrayBlobAdapter.mutate(new Uint8Array);let en=et.streamCollector(ee);return Uint8ArrayBlobAdapter.mutate(await en)};var ec=en(63518);let Command=class Command{constructor(){this.middlewareStack=constructStack()}static classBuilder(){return new ClassBuilder}resolveMiddlewareWithContext(ee,et,en,{middlewareFn:ei,clientName:eo,commandName:ea,inputFilterSensitiveLog:es,outputFilterSensitiveLog:eu,smithyContext:ed,additionalContext:ef,CommandCtor:ep}){for(let eo of ei.bind(this)(ep,ee,et,en))this.middlewareStack.use(eo);let eh=ee.concat(this.middlewareStack),{logger:ey}=et,em={logger:ey,clientName:eo,commandName:ea,inputFilterSensitiveLog:es,outputFilterSensitiveLog:eu,[ec.zK]:{commandInstance:this,...ed},...ef},{requestHandler:eg}=et;return eh.resolve(ee=>eg.handle(ee.request,en||{}),em)}};let ClassBuilder=class ClassBuilder{constructor(){this._init=()=>{},this._ep={},this._middlewareFn=()=>[],this._commandName="",this._clientName="",this._additionalContext={},this._smithyContext={},this._inputFilterSensitiveLog=ee=>ee,this._outputFilterSensitiveLog=ee=>ee,this._serializer=null,this._deserializer=null}init(ee){this._init=ee}ep(ee){return this._ep=ee,this}m(ee){return this._middlewareFn=ee,this}s(ee,et,en={}){return this._smithyContext={service:ee,operation:et,...en},this}c(ee={}){return this._additionalContext=ee,this}n(ee,et){return this._clientName=ee,this._commandName=et,this}f(ee=ee=>ee,et=ee=>ee){return this._inputFilterSensitiveLog=ee,this._outputFilterSensitiveLog=et,this}ser(ee){return this._serializer=ee,this}de(ee){return this._deserializer=ee,this}build(){let ee;let et=this;return ee=class extends Command{static getEndpointParameterInstructions(){return et._ep}constructor(...[ee]){super(),this.serialize=et._serializer,this.deserialize=et._deserializer,this.input=ee??{},et._init(this)}resolveMiddleware(en,ei,eo){return this.resolveMiddlewareWithContext(en,ei,eo,{CommandCtor:ee,middlewareFn:et._middlewareFn,clientName:et._clientName,commandName:et._commandName,inputFilterSensitiveLog:et._inputFilterSensitiveLog,outputFilterSensitiveLog:et._outputFilterSensitiveLog,smithyContext:et._smithyContext,additionalContext:et._additionalContext})}}}};let expectBoolean=ee=>{if(null!=ee){if("number"==typeof ee){if((0===ee||1===ee)&&ed.warn(stackTraceWarning(`Expected boolean, got ${typeof ee}: ${ee}`)),0===ee)return!1;if(1===ee)return!0}if("string"==typeof ee){let et=ee.toLowerCase();if(("false"===et||"true"===et)&&ed.warn(stackTraceWarning(`Expected boolean, got ${typeof ee}: ${ee}`)),"false"===et)return!1;if("true"===et)return!0}if("boolean"==typeof ee)return ee;throw TypeError(`Expected boolean, got ${typeof ee}: ${ee}`)}},expectNumber=ee=>{if(null!=ee){if("string"==typeof ee){let et=parseFloat(ee);if(!Number.isNaN(et))return String(et)!==String(ee)&&ed.warn(stackTraceWarning(`Expected number but observed string: ${ee}`)),et}if("number"==typeof ee)return ee;throw TypeError(`Expected number, got ${typeof ee}: ${ee}`)}},expectLong=ee=>{if(null!=ee){if(Number.isInteger(ee)&&!Number.isNaN(ee))return ee;throw TypeError(`Expected integer, got ${typeof ee}: ${ee}`)}},expectInt32=ee=>expectSizedInt(ee,32),expectSizedInt=(ee,et)=>{let en=expectLong(ee);if(void 0!==en&&castInt(en,et)!==en)throw TypeError(`Expected ${et}-bit integer, got ${ee}`);return en},castInt=(ee,et)=>{switch(et){case 32:return Int32Array.of(ee)[0];case 16:return Int16Array.of(ee)[0];case 8:return Int8Array.of(ee)[0]}},expectObject=ee=>{if(null==ee)return;if("object"==typeof ee&&!Array.isArray(ee))return ee;let et=Array.isArray(ee)?"array":typeof ee;throw TypeError(`Expected object, got ${et}: ${ee}`)},expectString=ee=>{if(null!=ee){if("string"==typeof ee)return ee;if(["boolean","number","bigint"].includes(typeof ee))return ed.warn(stackTraceWarning(`Expected string, got ${typeof ee}: ${ee}`)),String(ee);throw TypeError(`Expected string, got ${typeof ee}: ${ee}`)}},expectUnion=ee=>{if(null==ee)return;let et=expectObject(ee),en=Object.entries(et).filter(([,ee])=>null!=ee).map(([ee])=>ee);if(0===en.length)throw TypeError("Unions must have exactly one non-null member. None were found.");if(en.length>1)throw TypeError(`Unions must have exactly one non-null member. Keys ${en} were not null.`);return et},limitedParseDouble=ee=>"string"==typeof ee?parseFloatString(ee):expectNumber(ee),parseFloatString=ee=>{switch(ee){case"NaN":return NaN;case"Infinity":return 1/0;case"-Infinity":return-1/0;default:throw Error(`Unable to parse float value: ${ee}`)}},stackTraceWarning=ee=>String(TypeError(ee).stack||ee).split("\n").slice(0,5).filter(ee=>!ee.includes("stackTraceWarning")).join("\n"),ed={warn:console.warn};let ServiceException=class ServiceException extends Error{constructor(ee){super(ee.message),Object.setPrototypeOf(this,ServiceException.prototype),this.name=ee.name,this.$fault=ee.$fault,this.$metadata=ee.$metadata}};let decorateServiceException=(ee,et={})=>{Object.entries(et).filter(([,ee])=>void 0!==ee).forEach(([et,en])=>{(void 0==ee[et]||""===ee[et])&&(ee[et]=en)});let en=ee.message||ee.Message||"UnknownError";return ee.message=en,delete ee.Message,ee},throwDefaultError=({output:ee,parsedBody:et,exceptionCtor:en,errorCode:ei})=>{let eo=deserializeMetadata(ee),ea=eo.httpStatusCode?eo.httpStatusCode+"":void 0,es=new en({name:et?.code||et?.Code||ei||ea||"UnknownError",$fault:"client",$metadata:eo});throw decorateServiceException(es,et)},withBaseException=ee=>({output:et,parsedBody:en,errorCode:ei})=>{throwDefaultError({output:et,parsedBody:en,exceptionCtor:ee,errorCode:ei})},deserializeMetadata=ee=>({httpStatusCode:ee.statusCode,requestId:ee.headers["x-amzn-requestid"]??ee.headers["x-amzn-request-id"]??ee.headers["x-amz-request-id"],extendedRequestId:ee.headers["x-amz-id-2"],cfId:ee.headers["x-amz-cf-id"]}),loadConfigsForDefaultMode=ee=>{switch(ee){case"standard":case"cross-region":return{retryMode:"standard",connectionTimeout:3100};case"in-region":return{retryMode:"standard",connectionTimeout:1100};case"mobile":return{retryMode:"standard",connectionTimeout:3e4};default:return{}}},getChecksumConfiguration=ee=>{let et=[];for(let en in ec.f3){let ei=ec.f3[en];void 0!==ee[ei]&&et.push({algorithmId:()=>ei,checksumConstructor:()=>ee[ei]})}return{_checksumAlgorithms:et,addChecksumAlgorithm(ee){this._checksumAlgorithms.push(ee)},checksumAlgorithms(){return this._checksumAlgorithms}}},resolveChecksumRuntimeConfig=ee=>{let et={};return ee.checksumAlgorithms().forEach(ee=>{et[ee.algorithmId()]=ee.checksumConstructor()}),et},getRetryConfiguration=ee=>{let et=ee.retryStrategy;return{setRetryStrategy(ee){et=ee},retryStrategy:()=>et}},resolveRetryRuntimeConfig=ee=>{let et={};return et.retryStrategy=ee.retryStrategy(),et},getDefaultExtensionConfiguration=ee=>({...getChecksumConfiguration(ee),...getRetryConfiguration(ee)}),resolveDefaultRuntimeConfig=ee=>({...resolveChecksumRuntimeConfig(ee),...resolveRetryRuntimeConfig(ee)}),StringWrapper=function(){let ee=Object.getPrototypeOf(this).constructor,et=Function.bind.apply(String,[null,...arguments]),en=new et;return Object.setPrototypeOf(en,ee.prototype),en};function map(ee,et,en){let ei,eo;if(void 0===et&&void 0===en)ei={},eo=ee;else{if(ei=ee,"function"==typeof et)return mapWithFilter(ei,et,eo=en);eo=et}for(let ee of Object.keys(eo)){if(!Array.isArray(eo[ee])){ei[ee]=eo[ee];continue}applyInstruction(ei,null,eo,ee)}return ei}StringWrapper.prototype=Object.create(String.prototype,{constructor:{value:StringWrapper,enumerable:!1,writable:!0,configurable:!0}}),Object.setPrototypeOf(StringWrapper,String);let take=(ee,et)=>{let en={};for(let ei in et)applyInstruction(en,ee,et,ei);return en},mapWithFilter=(ee,et,en)=>map(ee,Object.entries(en).reduce((ee,[en,ei])=>(Array.isArray(ei)?ee[en]=ei:"function"==typeof ei?ee[en]=[et,ei()]:ee[en]=[et,ei],ee),{})),applyInstruction=(ee,et,en,ei)=>{if(null!==et){let eo=en[ei];"function"==typeof eo&&(eo=[,eo]);let[ea=nonNullish,es=pass,eu=ei]=eo;("function"==typeof ea&&ea(et[eu])||"function"!=typeof ea&&ea)&&(ee[ei]=es(et[eu]));return}let[eo,ea]=en[ei];if("function"==typeof ea){let et;let en=void 0===eo&&null!=(et=ea()),es="function"==typeof eo&&!!eo(void 0)||"function"!=typeof eo&&!!eo;en?ee[ei]=et:es&&(ee[ei]=ea())}else{let et=void 0===eo&&null!=ea,en="function"==typeof eo&&!!eo(ea)||"function"!=typeof eo&&!!eo;(et||en)&&(ee[ei]=ea)}},nonNullish=ee=>null!=ee,pass=ee=>ee,_json=ee=>{if(null==ee)return{};if(Array.isArray(ee))return ee.filter(ee=>null!=ee).map(_json);if("object"==typeof ee){let et={};for(let en of Object.keys(ee))null!=ee[en]&&(et[en]=_json(ee[en]));return et}return ee}},63518:function(ee,et,en){"use strict";var ei,eo,ea,es,eu,ec,ed;en.d(et,{f3:function(){return es},cj:function(){return ea},zK:function(){return ef}}),function(ee){ee.HEADER="header",ee.QUERY="query"}(ei||(ei={})),function(ee){ee.HEADER="header",ee.QUERY="query"}(eo||(eo={})),function(ee){ee.HTTP="http",ee.HTTPS="https"}(ea||(ea={})),function(ee){ee.MD5="md5",ee.CRC32="crc32",ee.CRC32C="crc32c",ee.SHA1="sha1",ee.SHA256="sha256"}(es||(es={})),function(ee){ee[ee.HEADER=0]="HEADER",ee[ee.TRAILER=1]="TRAILER"}(eu||(eu={}));let ef="__smithy_context";!function(ee){ee.PROFILE="profile",ee.SSO_SESSION="sso-session",ee.SERVICES="services"}(ec||(ec={})),function(ee){ee.HTTP_0_9="http/0.9",ee.HTTP_1_0="http/1.0",ee.TDS_8_0="tds/8.0"}(ed||(ed={}))},94317:function(ee,et,en){"use strict";function parseQueryString(ee){let et={};if(ee=ee.replace(/^\?/,""))for(let en of ee.split("&")){let[ee,ei=null]=en.split("=");ee=decodeURIComponent(ee),ei&&(ei=decodeURIComponent(ei)),ee in et?Array.isArray(et[ee])?et[ee].push(ei):et[ee]=[et[ee],ei]:et[ee]=ei}return et}en.d(et,{e:function(){return parseUrl}});let parseUrl=ee=>{let et;if("string"==typeof ee)return parseUrl(new URL(ee));let{hostname:en,pathname:ei,port:eo,protocol:ea,search:es}=ee;return es&&(et=parseQueryString(es)),{hostname:en,port:eo?parseInt(eo):void 0,protocol:ea,path:ei,query:et}}},65368:function(ee,et,en){"use strict";en.d(et,{G:function(){return fromBase64},s:function(){return toBase64}});let ei={},eo=Array(64);for(let ee=0,et=65,en=90;ee+et<=en;ee++){let en=String.fromCharCode(ee+et);ei[en]=ee,eo[ee]=en}for(let ee=0,et=97,en=122;ee+et<=en;ee++){let en=String.fromCharCode(ee+et),ea=ee+26;ei[en]=ea,eo[ea]=en}for(let ee=0;ee<10;ee++){ei[ee.toString(10)]=ee+52;let et=ee.toString(10),en=ee+52;ei[et]=en,eo[en]=et}ei["+"]=62,eo[62]="+",ei["/"]=63,eo[63]="/";let ea=6,es=8,eu=63,fromBase64=ee=>{let et=ee.length/4*3;"=="===ee.slice(-2)?et-=2:"="===ee.slice(-1)&&et--;let en=new ArrayBuffer(et),eo=new DataView(en);for(let et=0;et>=ea;let ec=et/4*3;en>>=eu%es;let ed=Math.floor(eu/es);for(let ee=0;ee>et)}}return new Uint8Array(en)};var ec=en(45854);function toBase64(ee){let et;et="string"==typeof ee?(0,ec.$)(ee):ee;let en="object"==typeof et&&"number"==typeof et.length,ei="object"==typeof et&&"number"==typeof et.byteOffset&&"number"==typeof et.byteLength;if(!en&&!ei)throw Error("@smithy/util-base64: toBase64 encoder function only accepts string | Uint8Array.");let ed="";for(let ee=0;ee>et]}ed+="==".slice(0,4-ec)}return ed}},63645:function(ee,et,en){"use strict";en.d(et,{H:function(){return fromHex},N:function(){return toHex}});let ei={},eo={};for(let ee=0;ee<256;ee++){let et=ee.toString(16).toLowerCase();1===et.length&&(et=`0${et}`),ei[ee]=et,eo[et]=ee}function fromHex(ee){if(ee.length%2!=0)throw Error("Hex encoded strings must have an even number length");let et=new Uint8Array(ee.length/2);for(let en=0;enencodeURIComponent(ee).replace(/[!'()*]/g,hexEncode),hexEncode=ee=>`%${ee.charCodeAt(0).toString(16).toUpperCase()}`},45854:function(ee,et,en){"use strict";en.d(et,{$:function(){return fromUtf8}});let fromUtf8=ee=>new TextEncoder().encode(ee)},88608:function(ee,et,en){"use strict";en.d(et,{G:function(){return toUtf8}});let toUtf8=ee=>{if("string"==typeof ee)return ee;if("object"!=typeof ee||"number"!=typeof ee.byteOffset||"number"!=typeof ee.byteLength)throw Error("@smithy/util-utf8: toUtf8 encoder function only accepts string | Uint8Array.");return new TextDecoder("utf-8").decode(ee)}},46150:function(ee,et,en){"use strict";let ei;en.d(et,{Z:function(){return esm_browser_v4}});let eo="undefined"!=typeof crypto&&crypto.randomUUID&&crypto.randomUUID.bind(crypto);var ea={randomUUID:eo};let es=new Uint8Array(16);function rng(){if(!ei&&!(ei="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)))throw Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return ei(es)}let eu=[];for(let ee=0;ee<256;++ee)eu.push((ee+256).toString(16).slice(1));function unsafeStringify(ee,et=0){return eu[ee[et+0]]+eu[ee[et+1]]+eu[ee[et+2]]+eu[ee[et+3]]+"-"+eu[ee[et+4]]+eu[ee[et+5]]+"-"+eu[ee[et+6]]+eu[ee[et+7]]+"-"+eu[ee[et+8]]+eu[ee[et+9]]+"-"+eu[ee[et+10]]+eu[ee[et+11]]+eu[ee[et+12]]+eu[ee[et+13]]+eu[ee[et+14]]+eu[ee[et+15]]}var esm_browser_v4=function(ee,et,en){if(ea.randomUUID&&!et&&!ee)return ea.randomUUID();ee=ee||{};let ei=ee.random||(ee.rng||rng)();if(ei[6]=15&ei[6]|64,ei[8]=63&ei[8]|128,et){en=en||0;for(let ee=0;ee<16;++ee)et[en+ee]=ei[ee];return et}return unsafeStringify(ei)}},62256:function(ee,et,en){"use strict";en.d(et,{MA:function(){return DeleteCommand},QJ:function(){return DynamoDBDocument},m1:function(){return DynamoDBDocumentClient},Bj:function(){return GetCommand},Yi:function(){return PutCommand},zd:function(){return UpdateCommand}});var ei,eo,ea,es,eu,ec,ed,ef=en(21093),ep=en(93270),eh=en(70391),ey=en(95616),em=en(91221);let BatchExecuteStatementCommand_BatchExecuteStatementCommand=class BatchExecuteStatementCommand_BatchExecuteStatementCommand extends eh.mY.classBuilder().ep(ey.q).m(function(ee,et,en,ei){return[(0,ep.p2)(en,this.serialize,this.deserialize),(0,ef.a3)(en,ee.getEndpointParameterInstructions())]}).s("DynamoDB_20120810","BatchExecuteStatement",{}).n("DynamoDBClient","BatchExecuteStatementCommand").f(void 0,void 0).ser(em.m1).de(em.j7).build(){};let getAllAliases=(ee,et)=>{let en=[];if(ee&&en.push(ee),et)for(let ee of et)en.push(ee);return en},getMiddlewareNameWithAliases=(ee,et)=>`${ee||"anonymous"}${et&&et.length>0?` (a.k.a. ${et.join(",")})`:""}`,constructStack=()=>{let ee=[],et=[],en=!1,ei=new Set,sort=ee=>ee.sort((ee,et)=>eg[et.step]-eg[ee.step]||eb[et.priority||"normal"]-eb[ee.priority||"normal"]),removeByName=en=>{let eo=!1,filterCb=ee=>{let et=getAllAliases(ee.name,ee.aliases);if(et.includes(en)){for(let ee of(eo=!0,et))ei.delete(ee);return!1}return!0};return ee=ee.filter(filterCb),et=et.filter(filterCb),eo},removeByReference=en=>{let eo=!1,filterCb=ee=>{if(ee.middleware===en){for(let et of(eo=!0,getAllAliases(ee.name,ee.aliases)))ei.delete(et);return!1}return!0};return ee=ee.filter(filterCb),et=et.filter(filterCb),eo},cloneTo=en=>(ee.forEach(ee=>{en.add(ee.middleware,{...ee})}),et.forEach(ee=>{en.addRelativeTo(ee.middleware,{...ee})}),en.identifyOnResolve?.(eo.identifyOnResolve()),en),expandRelativeMiddlewareList=ee=>{let et=[];return ee.before.forEach(ee=>{0===ee.before.length&&0===ee.after.length?et.push(ee):et.push(...expandRelativeMiddlewareList(ee))}),et.push(ee),ee.after.reverse().forEach(ee=>{0===ee.before.length&&0===ee.after.length?et.push(ee):et.push(...expandRelativeMiddlewareList(ee))}),et},getMiddlewareList=(en=!1)=>{let ei=[],eo=[],ea={};ee.forEach(ee=>{let et={...ee,before:[],after:[]};for(let ee of getAllAliases(et.name,et.aliases))ea[ee]=et;ei.push(et)}),et.forEach(ee=>{let et={...ee,before:[],after:[]};for(let ee of getAllAliases(et.name,et.aliases))ea[ee]=et;eo.push(et)}),eo.forEach(ee=>{if(ee.toMiddleware){let et=ea[ee.toMiddleware];if(void 0===et){if(en)return;throw Error(`${ee.toMiddleware} is not found when adding ${getMiddlewareNameWithAliases(ee.name,ee.aliases)} middleware ${ee.relation} ${ee.toMiddleware}`)}"after"===ee.relation&&et.after.push(ee),"before"===ee.relation&&et.before.push(ee)}});let es=sort(ei).map(expandRelativeMiddlewareList).reduce((ee,et)=>(ee.push(...et),ee),[]);return es},eo={add:(et,en={})=>{let{name:eo,override:ea,aliases:es}=en,eu={step:"initialize",priority:"normal",middleware:et,...en},ec=getAllAliases(eo,es);if(ec.length>0){if(ec.some(ee=>ei.has(ee))){if(!ea)throw Error(`Duplicate middleware name '${getMiddlewareNameWithAliases(eo,es)}'`);for(let et of ec){let en=ee.findIndex(ee=>ee.name===et||ee.aliases?.some(ee=>ee===et));if(-1===en)continue;let ei=ee[en];if(ei.step!==eu.step||eu.priority!==ei.priority)throw Error(`"${getMiddlewareNameWithAliases(ei.name,ei.aliases)}" middleware with ${ei.priority} priority in ${ei.step} step cannot be overridden by "${getMiddlewareNameWithAliases(eo,es)}" middleware with ${eu.priority} priority in ${eu.step} step.`);ee.splice(en,1)}}for(let ee of ec)ei.add(ee)}ee.push(eu)},addRelativeTo:(ee,en)=>{let{name:eo,override:ea,aliases:es}=en,eu={middleware:ee,...en},ec=getAllAliases(eo,es);if(ec.length>0){if(ec.some(ee=>ei.has(ee))){if(!ea)throw Error(`Duplicate middleware name '${getMiddlewareNameWithAliases(eo,es)}'`);for(let ee of ec){let en=et.findIndex(et=>et.name===ee||et.aliases?.some(et=>et===ee));if(-1===en)continue;let ei=et[en];if(ei.toMiddleware!==eu.toMiddleware||ei.relation!==eu.relation)throw Error(`"${getMiddlewareNameWithAliases(ei.name,ei.aliases)}" middleware ${ei.relation} "${ei.toMiddleware}" middleware cannot be overridden by "${getMiddlewareNameWithAliases(eo,es)}" middleware ${eu.relation} "${eu.toMiddleware}" middleware.`);et.splice(en,1)}}for(let ee of ec)ei.add(ee)}et.push(eu)},clone:()=>cloneTo(constructStack()),use:ee=>{ee.applyToStack(eo)},remove:ee=>"string"==typeof ee?removeByName(ee):removeByReference(ee),removeByTag:en=>{let eo=!1,filterCb=ee=>{let{tags:et,name:ea,aliases:es}=ee;if(et&&et.includes(en)){let ee=getAllAliases(ea,es);for(let et of ee)ei.delete(et);return eo=!0,!1}return!0};return ee=ee.filter(filterCb),et=et.filter(filterCb),eo},concat:ee=>{let et=cloneTo(constructStack());return et.use(ee),et.identifyOnResolve(en||et.identifyOnResolve()||(ee.identifyOnResolve?.()??!1)),et},applyToStack:cloneTo,identify:()=>getMiddlewareList(!0).map(ee=>{let et=ee.step??ee.relation+" "+ee.toMiddleware;return getMiddlewareNameWithAliases(ee.name,ee.aliases)+" - "+et}),identifyOnResolve:ee=>("boolean"==typeof ee&&(en=ee),en),resolve:(ee,et)=>{for(let en of getMiddlewareList().map(ee=>ee.middleware).reverse())ee=en(ee,et);return en&&console.log(eo.identify()),ee}};return eo},eg={initialize:5,serialize:4,build:3,finalizeRequest:2,deserialize:1},eb={high:3,normal:2,low:1};let Client=class Client{constructor(ee){this.config=ee,this.middlewareStack=constructStack()}send(ee,et,en){let ei;let eo="function"!=typeof et?et:void 0,ea="function"==typeof et?et:en,es=void 0===eo&&!0===this.config.cacheMiddleware;if(es){this.handlers||(this.handlers=new WeakMap);let et=this.handlers;et.has(ee.constructor)?ei=et.get(ee.constructor):(ei=ee.resolveMiddleware(this.middlewareStack,this.config,eo),et.set(ee.constructor,ei))}else delete this.handlers,ei=ee.resolveMiddleware(this.middlewareStack,this.config,eo);if(!ea)return ei(ee).then(ee=>ee.output);ei(ee).then(ee=>ea(null,ee.output),ee=>ea(ee)).catch(()=>{})}destroy(){this.config?.requestHandler?.destroy?.(),delete this.handlers}};let ev={},e_=Array(64);for(let ee=0,et=65,en=90;ee+et<=en;ee++){let en=String.fromCharCode(ee+et);ev[en]=ee,e_[ee]=en}for(let ee=0,et=97,en=122;ee+et<=en;ee++){let en=String.fromCharCode(ee+et),ei=ee+26;ev[en]=ei,e_[ei]=en}for(let ee=0;ee<10;ee++){ev[ee.toString(10)]=ee+52;let et=ee.toString(10),en=ee+52;ev[et]=en,e_[en]=et}ev["+"]=62,e_[62]="+",ev["/"]=63,e_[63]="/",function(ee){ee.HEADER="header",ee.QUERY="query"}(ei||(ei={})),function(ee){ee.HEADER="header",ee.QUERY="query"}(eo||(eo={})),function(ee){ee.HTTP="http",ee.HTTPS="https"}(ea||(ea={})),function(ee){ee.MD5="md5",ee.CRC32="crc32",ee.CRC32C="crc32c",ee.SHA1="sha1",ee.SHA256="sha256"}(es||(es={})),function(ee){ee[ee.HEADER=0]="HEADER",ee[ee.TRAILER=1]="TRAILER"}(eu||(eu={}));let ew="__smithy_context";!function(ee){ee.PROFILE="profile",ee.SSO_SESSION="sso-session",ee.SERVICES="services"}(ec||(ec={})),function(ee){ee.HTTP_0_9="http/0.9",ee.HTTP_1_0="http/1.0",ee.TDS_8_0="tds/8.0"}(ed||(ed={}));let eS={},eE={};for(let ee=0;ee<256;ee++){let et=ee.toString(16).toLowerCase();1===et.length&&(et=`0${et}`),eS[ee]=et,eE[et]=ee}let Command=class Command{constructor(){this.middlewareStack=constructStack()}static classBuilder(){return new ClassBuilder}resolveMiddlewareWithContext(ee,et,en,{middlewareFn:ei,clientName:eo,commandName:ea,inputFilterSensitiveLog:es,outputFilterSensitiveLog:eu,smithyContext:ec,additionalContext:ed,CommandCtor:ef}){for(let eo of ei.bind(this)(ef,ee,et,en))this.middlewareStack.use(eo);let ep=ee.concat(this.middlewareStack),{logger:eh}=et,ey={logger:eh,clientName:eo,commandName:ea,inputFilterSensitiveLog:es,outputFilterSensitiveLog:eu,[ew]:{commandInstance:this,...ec},...ed},{requestHandler:em}=et;return ep.resolve(ee=>em.handle(ee.request,en||{}),ey)}};let ClassBuilder=class ClassBuilder{constructor(){this._init=()=>{},this._ep={},this._middlewareFn=()=>[],this._commandName="",this._clientName="",this._additionalContext={},this._smithyContext={},this._inputFilterSensitiveLog=ee=>ee,this._outputFilterSensitiveLog=ee=>ee,this._serializer=null,this._deserializer=null}init(ee){this._init=ee}ep(ee){return this._ep=ee,this}m(ee){return this._middlewareFn=ee,this}s(ee,et,en={}){return this._smithyContext={service:ee,operation:et,...en},this}c(ee={}){return this._additionalContext=ee,this}n(ee,et){return this._clientName=ee,this._commandName=et,this}f(ee=ee=>ee,et=ee=>ee){return this._inputFilterSensitiveLog=ee,this._outputFilterSensitiveLog=et,this}ser(ee){return this._serializer=ee,this}de(ee){return this._deserializer=ee,this}build(){let ee;let et=this;return ee=class extends Command{static getEndpointParameterInstructions(){return et._ep}constructor(...[ee]){super(),this.serialize=et._serializer,this.deserialize=et._deserializer,this.input=ee??{},et._init(this)}resolveMiddleware(en,ei,eo){return this.resolveMiddlewareWithContext(en,ei,eo,{CommandCtor:ee,middlewareFn:et._middlewareFn,clientName:et._clientName,commandName:et._commandName,inputFilterSensitiveLog:et._inputFilterSensitiveLog,outputFilterSensitiveLog:et._outputFilterSensitiveLog,smithyContext:et._smithyContext,additionalContext:et._additionalContext})}}}};let StringWrapper=function(){let ee=Object.getPrototypeOf(this).constructor,et=Function.bind.apply(String,[null,...arguments]),en=new et;return Object.setPrototypeOf(en,ee.prototype),en};StringWrapper.prototype=Object.create(String.prototype,{constructor:{value:StringWrapper,enumerable:!1,writable:!0,configurable:!0}}),Object.setPrototypeOf(StringWrapper,String);let NumberValue=class NumberValue{constructor(ee){"object"==typeof ee&&"N"in ee?this.value=String(ee.N):this.value=String(ee);let et="number"==typeof ee.valueOf()?ee.valueOf():0,en=et>Number.MAX_SAFE_INTEGER||et{if(void 0===ee)throw Error("Pass options.removeUndefinedValues=true to remove undefined values from map/array/set.");if(null===ee&&"object"==typeof ee)return convertToNullAttr();if(Array.isArray(ee))return convertToListAttr(ee,et);if(ee?.constructor?.name==="Set")return convertToSetAttr(ee,et);if(ee?.constructor?.name==="Map")return convertToMapAttrFromIterable(ee,et);if(ee?.constructor?.name==="Object"||!ee.constructor&&"object"==typeof ee)return convertToMapAttrFromEnumerableProps(ee,et);if(isBinary(ee))return 0===ee.length&&et?.convertEmptyValues?convertToNullAttr():convertToBinaryAttr(ee);else if("boolean"==typeof ee||ee?.constructor?.name==="Boolean")return{BOOL:ee.valueOf()};else if("number"==typeof ee||ee?.constructor?.name==="Number")return convertToNumberAttr(ee);else if(ee instanceof NumberValue)return ee.toAttributeValue();else if("bigint"==typeof ee)return convertToBigIntAttr(ee);else if("string"==typeof ee||ee?.constructor?.name==="String")return 0===ee.length&&et?.convertEmptyValues?convertToNullAttr():convertToStringAttr(ee);else if(et?.convertClassInstanceToMap&&"object"==typeof ee)return convertToMapAttrFromEnumerableProps(ee,et);throw Error(`Unsupported type passed: ${ee}. Pass options.convertClassInstanceToMap=true to marshall typeof object as map attribute.`)},convertToListAttr=(ee,et)=>({L:ee.filter(ee=>"function"!=typeof ee&&(!et?.removeUndefinedValues||et?.removeUndefinedValues&&void 0!==ee)).map(ee=>convertToAttr(ee,et))}),convertToSetAttr=(ee,et)=>{let en=et?.removeUndefinedValues?new Set([...ee].filter(ee=>void 0!==ee)):ee;if(!et?.removeUndefinedValues&&en.has(void 0))throw Error("Pass options.removeUndefinedValues=true to remove undefined values from map/array/set.");if(0===en.size){if(et?.convertEmptyValues)return convertToNullAttr();throw Error("Pass a non-empty set, or options.convertEmptyValues=true.")}let ei=en.values().next().value;if(ei instanceof NumberValue)return{NS:Array.from(en).map(ee=>ee.toString())};if("number"==typeof ei)return{NS:Array.from(en).map(convertToNumberAttr).map(ee=>ee.N)};if("bigint"==typeof ei)return{NS:Array.from(en).map(convertToBigIntAttr).map(ee=>ee.N)};if("string"==typeof ei)return{SS:Array.from(en).map(convertToStringAttr).map(ee=>ee.S)};if(isBinary(ei))return{BS:Array.from(en).map(convertToBinaryAttr).map(ee=>ee.B)};throw Error("Only Number Set (NS), Binary Set (BS) or String Set (SS) are allowed.")},convertToMapAttrFromIterable=(ee,et)=>({M:(ee=>{let en={};for(let[ei,eo]of ee)"function"==typeof eo||void 0===eo&&et?.removeUndefinedValues||(en[ei]=convertToAttr(eo,et));return en})(ee)}),convertToMapAttrFromEnumerableProps=(ee,et)=>({M:(ee=>{let en={};for(let ei in ee){let eo=ee[ei];"function"==typeof eo||void 0===eo&&et?.removeUndefinedValues||(en[ei]=convertToAttr(eo,et))}return en})(ee)}),convertToNullAttr=()=>({NULL:!0}),convertToBinaryAttr=ee=>({B:ee}),convertToStringAttr=ee=>({S:ee.toString()}),convertToBigIntAttr=ee=>({N:ee.toString()}),validateBigIntAndThrow=ee=>{throw Error(`${ee} ${"function"==typeof BigInt?"Use BigInt.":"Pass string value instead."} `)},convertToNumberAttr=ee=>{if([Number.NaN,Number.POSITIVE_INFINITY,Number.NEGATIVE_INFINITY].map(ee=>ee.toString()).includes(ee.toString()))throw Error(`Special numeric value ${ee.toString()} is not allowed`);return ee>Number.MAX_SAFE_INTEGER?validateBigIntAndThrow(`Number ${ee.toString()} is greater than Number.MAX_SAFE_INTEGER.`):ee{let et=["ArrayBuffer","Blob","Buffer","DataView","File","Int8Array","Uint8Array","Uint8ClampedArray","Int16Array","Uint16Array","Int32Array","Uint32Array","Float32Array","Float64Array","BigInt64Array","BigUint64Array"];return!!ee?.constructor&&et.includes(ee.constructor.name)};function marshall(ee,et){let en=convertToAttr(ee,et),[ei,eo]=Object.entries(en)[0];switch(ei){case"M":case"L":return et?.convertTopLevelContainer?en:eo;default:return en}}let convertToNative=(ee,et)=>{for(let[en,ei]of Object.entries(ee))if(void 0!==ei)switch(en){case"NULL":return null;case"BOOL":return!!ei;case"N":return convertNumber(ei,et);case"B":return convertBinary(ei);case"S":return convertString(ei);case"L":return convertList(ei,et);case"M":return convertMap(ei,et);case"NS":return new Set(ei.map(ee=>convertNumber(ee,et)));case"BS":return new Set(ei.map(convertBinary));case"SS":return new Set(ei.map(convertString));default:throw Error(`Unsupported type passed: ${en}`)}throw Error(`No value defined: ${JSON.stringify(ee)}`)},convertNumber=(ee,et)=>{if(et?.wrapNumbers)return NumberValue.from(ee);let en=Number(ee),ei=[Number.POSITIVE_INFINITY,Number.NEGATIVE_INFINITY],eo=(en>Number.MAX_SAFE_INTEGER||enee,convertBinary=ee=>ee,convertList=(ee,et)=>ee.map(ee=>convertToNative(ee,et)),convertMap=(ee,et)=>Object.entries(ee).reduce((ee,[en,ei])=>(ee[en]=convertToNative(ei,et),ee),{}),unmarshall=(ee,et)=>et?.convertWithoutMapWrapper?convertToNative(ee,et):convertToNative({M:ee},et),eA=null,e$={},ex=[],eC="*",processObj=(ee,et,en)=>{if(void 0!==ee){if(null==en)return et(ee);{let ei=Object.keys(en),eo=1===ei.length&&ei[0]===eC,ea=ei.length>=1&&!eo,es=0===ei.length;if(ea)return processKeysInObj(ee,et,en);if(es)return processAllKeysInObj(ee,et,eA);if(eo)return Object.entries(ee??{}).reduce((ee,[ei,eo])=>("function"!=typeof eo&&(ee[ei]=processObj(eo,et,en[eC])),ee),Array.isArray(ee)?[]:{})}}},processKeysInObj=(ee,et,en)=>{let ei;if(Array.isArray(ee))ei=ee.filter(ee=>"function"!=typeof ee);else for(let[et,en]of(ei={},Object.entries(ee)))"function"!=typeof en&&(ei[et]=en);for(let[eo,ea]of Object.entries(en)){if("function"==typeof ee[eo])continue;let en=processObj(ee[eo],et,ea);void 0!==en&&"function"!=typeof en&&(ei[eo]=en)}return ei},processAllKeysInObj=(ee,et,en)=>Array.isArray(ee)?ee.filter(ee=>"function"!=typeof ee).map(ee=>processObj(ee,et,en)):Object.entries(ee).reduce((ee,[ei,eo])=>{if("function"==typeof eo)return ee;let ea=processObj(eo,et,en);return void 0!==ea&&"function"!=typeof ea&&(ee[ei]=ea),ee},{}),marshallInput=(ee,et,en)=>{let marshallFunc=ee=>marshall(ee,en);return processKeysInObj(ee,marshallFunc,et)},unmarshallOutput=(ee,et,en)=>{let unmarshallFunc=ee=>unmarshall(ee,en);return processKeysInObj(ee,unmarshallFunc,et)};let DynamoDBDocumentClientCommand=class DynamoDBDocumentClientCommand extends Command{addMarshallingMiddleware(ee){let{marshallOptions:et={},unmarshallOptions:en={}}=ee.translateConfig||{};et.convertTopLevelContainer=et.convertTopLevelContainer??!0,en.convertWithoutMapWrapper=en.convertWithoutMapWrapper??!0,this.clientCommand.middlewareStack.addRelativeTo((ee,en)=>async ei=>{ei.input=marshallInput(this.input,this.inputKeyNodes,et),en.dynamoDbDocumentClientOptions=en.dynamoDbDocumentClientOptions||DynamoDBDocumentClientCommand.defaultLogFilterOverrides;let eo=ei.input;return en.dynamoDbDocumentClientOptions.overrideInputFilterSensitiveLog=()=>en.inputFilterSensitiveLog?.(eo),ee(ei)},{name:"DocumentMarshall",relation:"before",toMiddleware:"serializerMiddleware",override:!0}),this.clientCommand.middlewareStack.addRelativeTo((ee,et)=>async ei=>{let eo=await ee(ei),ea=eo.output;return et.dynamoDbDocumentClientOptions=et.dynamoDbDocumentClientOptions||DynamoDBDocumentClientCommand.defaultLogFilterOverrides,et.dynamoDbDocumentClientOptions.overrideOutputFilterSensitiveLog=()=>et.outputFilterSensitiveLog?.(ea),eo.output=unmarshallOutput(eo.output,this.outputKeyNodes,en),eo},{name:"DocumentUnmarshall",relation:"before",toMiddleware:"deserializerMiddleware",override:!0})}};DynamoDBDocumentClientCommand.defaultLogFilterOverrides={overrideInputFilterSensitiveLog(...ee){},overrideOutputFilterSensitiveLog(...ee){}};let BatchExecuteStatementCommand=class BatchExecuteStatementCommand extends DynamoDBDocumentClientCommand{constructor(ee){super(),this.input=ee,this.inputKeyNodes={Statements:{"*":{Parameters:ex}}},this.outputKeyNodes={Responses:{"*":{Error:{Item:e$},Item:e$}}},this.clientCommand=new BatchExecuteStatementCommand_BatchExecuteStatementCommand(this.input),this.middlewareStack=this.clientCommand.middlewareStack}resolveMiddleware(ee,et,en){this.addMarshallingMiddleware(et);let ei=ee.concat(this.middlewareStack),eo=this.clientCommand.resolveMiddleware(ei,et,en);return async()=>eo(this.clientCommand)}};let BatchGetItemCommand=class BatchGetItemCommand extends eh.mY.classBuilder().ep(ey.q).m(function(ee,et,en,ei){return[(0,ep.p2)(en,this.serialize,this.deserialize),(0,ef.a3)(en,ee.getEndpointParameterInstructions())]}).s("DynamoDB_20120810","BatchGetItem",{}).n("DynamoDBClient","BatchGetItemCommand").f(void 0,void 0).ser(em.L8).de(em.zC).build(){};let BatchGetCommand=class BatchGetCommand extends DynamoDBDocumentClientCommand{constructor(ee){super(),this.input=ee,this.inputKeyNodes={RequestItems:{"*":{Keys:{"*":e$}}}},this.outputKeyNodes={Responses:{"*":{"*":e$}},UnprocessedKeys:{"*":{Keys:{"*":e$}}}},this.clientCommand=new BatchGetItemCommand(this.input),this.middlewareStack=this.clientCommand.middlewareStack}resolveMiddleware(ee,et,en){this.addMarshallingMiddleware(et);let ei=ee.concat(this.middlewareStack),eo=this.clientCommand.resolveMiddleware(ei,et,en);return async()=>eo(this.clientCommand)}};let BatchWriteItemCommand=class BatchWriteItemCommand extends eh.mY.classBuilder().ep(ey.q).m(function(ee,et,en,ei){return[(0,ep.p2)(en,this.serialize,this.deserialize),(0,ef.a3)(en,ee.getEndpointParameterInstructions())]}).s("DynamoDB_20120810","BatchWriteItem",{}).n("DynamoDBClient","BatchWriteItemCommand").f(void 0,void 0).ser(em.de).de(em.vK).build(){};let BatchWriteCommand=class BatchWriteCommand extends DynamoDBDocumentClientCommand{constructor(ee){super(),this.input=ee,this.inputKeyNodes={RequestItems:{"*":{"*":{PutRequest:{Item:e$},DeleteRequest:{Key:e$}}}}},this.outputKeyNodes={UnprocessedItems:{"*":{"*":{PutRequest:{Item:e$},DeleteRequest:{Key:e$}}}},ItemCollectionMetrics:{"*":{"*":{ItemCollectionKey:e$}}}},this.clientCommand=new BatchWriteItemCommand(this.input),this.middlewareStack=this.clientCommand.middlewareStack}resolveMiddleware(ee,et,en){this.addMarshallingMiddleware(et);let ei=ee.concat(this.middlewareStack),eo=this.clientCommand.resolveMiddleware(ei,et,en);return async()=>eo(this.clientCommand)}};let DeleteItemCommand=class DeleteItemCommand extends eh.mY.classBuilder().ep(ey.q).m(function(ee,et,en,ei){return[(0,ep.p2)(en,this.serialize,this.deserialize),(0,ef.a3)(en,ee.getEndpointParameterInstructions())]}).s("DynamoDB_20120810","DeleteItem",{}).n("DynamoDBClient","DeleteItemCommand").f(void 0,void 0).ser(em.Zm).de(em.QZ).build(){};let DeleteCommand=class DeleteCommand extends DynamoDBDocumentClientCommand{constructor(ee){super(),this.input=ee,this.inputKeyNodes={Key:e$,Expected:{"*":{Value:eA,AttributeValueList:ex}},ExpressionAttributeValues:e$},this.outputKeyNodes={Attributes:e$,ItemCollectionMetrics:{ItemCollectionKey:e$}},this.clientCommand=new DeleteItemCommand(this.input),this.middlewareStack=this.clientCommand.middlewareStack}resolveMiddleware(ee,et,en){this.addMarshallingMiddleware(et);let ei=ee.concat(this.middlewareStack),eo=this.clientCommand.resolveMiddleware(ei,et,en);return async()=>eo(this.clientCommand)}};let ExecuteStatementCommand_ExecuteStatementCommand=class ExecuteStatementCommand_ExecuteStatementCommand extends eh.mY.classBuilder().ep(ey.q).m(function(ee,et,en,ei){return[(0,ep.p2)(en,this.serialize,this.deserialize),(0,ef.a3)(en,ee.getEndpointParameterInstructions())]}).s("DynamoDB_20120810","ExecuteStatement",{}).n("DynamoDBClient","ExecuteStatementCommand").f(void 0,void 0).ser(em.rG).de(em.uB).build(){};let ExecuteStatementCommand=class ExecuteStatementCommand extends DynamoDBDocumentClientCommand{constructor(ee){super(),this.input=ee,this.inputKeyNodes={Parameters:ex},this.outputKeyNodes={Items:{"*":e$},LastEvaluatedKey:e$},this.clientCommand=new ExecuteStatementCommand_ExecuteStatementCommand(this.input),this.middlewareStack=this.clientCommand.middlewareStack}resolveMiddleware(ee,et,en){this.addMarshallingMiddleware(et);let ei=ee.concat(this.middlewareStack),eo=this.clientCommand.resolveMiddleware(ei,et,en);return async()=>eo(this.clientCommand)}};let ExecuteTransactionCommand_ExecuteTransactionCommand=class ExecuteTransactionCommand_ExecuteTransactionCommand extends eh.mY.classBuilder().ep(ey.q).m(function(ee,et,en,ei){return[(0,ep.p2)(en,this.serialize,this.deserialize),(0,ef.a3)(en,ee.getEndpointParameterInstructions())]}).s("DynamoDB_20120810","ExecuteTransaction",{}).n("DynamoDBClient","ExecuteTransactionCommand").f(void 0,void 0).ser(em.Di).de(em.Gw).build(){};let ExecuteTransactionCommand=class ExecuteTransactionCommand extends DynamoDBDocumentClientCommand{constructor(ee){super(),this.input=ee,this.inputKeyNodes={TransactStatements:{"*":{Parameters:ex}}},this.outputKeyNodes={Responses:{"*":{Item:e$}}},this.clientCommand=new ExecuteTransactionCommand_ExecuteTransactionCommand(this.input),this.middlewareStack=this.clientCommand.middlewareStack}resolveMiddleware(ee,et,en){this.addMarshallingMiddleware(et);let ei=ee.concat(this.middlewareStack),eo=this.clientCommand.resolveMiddleware(ei,et,en);return async()=>eo(this.clientCommand)}};let GetItemCommand=class GetItemCommand extends eh.mY.classBuilder().ep(ey.q).m(function(ee,et,en,ei){return[(0,ep.p2)(en,this.serialize,this.deserialize),(0,ef.a3)(en,ee.getEndpointParameterInstructions())]}).s("DynamoDB_20120810","GetItem",{}).n("DynamoDBClient","GetItemCommand").f(void 0,void 0).ser(em.Nk).de(em.Qb).build(){};let GetCommand=class GetCommand extends DynamoDBDocumentClientCommand{constructor(ee){super(),this.input=ee,this.inputKeyNodes={Key:e$},this.outputKeyNodes={Item:e$},this.clientCommand=new GetItemCommand(this.input),this.middlewareStack=this.clientCommand.middlewareStack}resolveMiddleware(ee,et,en){this.addMarshallingMiddleware(et);let ei=ee.concat(this.middlewareStack),eo=this.clientCommand.resolveMiddleware(ei,et,en);return async()=>eo(this.clientCommand)}};let PutItemCommand=class PutItemCommand extends eh.mY.classBuilder().ep(ey.q).m(function(ee,et,en,ei){return[(0,ep.p2)(en,this.serialize,this.deserialize),(0,ef.a3)(en,ee.getEndpointParameterInstructions())]}).s("DynamoDB_20120810","PutItem",{}).n("DynamoDBClient","PutItemCommand").f(void 0,void 0).ser(em.IQ).de(em.E6).build(){};let PutCommand=class PutCommand extends DynamoDBDocumentClientCommand{constructor(ee){super(),this.input=ee,this.inputKeyNodes={Item:e$,Expected:{"*":{Value:eA,AttributeValueList:ex}},ExpressionAttributeValues:e$},this.outputKeyNodes={Attributes:e$,ItemCollectionMetrics:{ItemCollectionKey:e$}},this.clientCommand=new PutItemCommand(this.input),this.middlewareStack=this.clientCommand.middlewareStack}resolveMiddleware(ee,et,en){this.addMarshallingMiddleware(et);let ei=ee.concat(this.middlewareStack),eo=this.clientCommand.resolveMiddleware(ei,et,en);return async()=>eo(this.clientCommand)}};let QueryCommand_QueryCommand=class QueryCommand_QueryCommand extends eh.mY.classBuilder().ep(ey.q).m(function(ee,et,en,ei){return[(0,ep.p2)(en,this.serialize,this.deserialize),(0,ef.a3)(en,ee.getEndpointParameterInstructions())]}).s("DynamoDB_20120810","Query",{}).n("DynamoDBClient","QueryCommand").f(void 0,void 0).ser(em.I).de(em.lx).build(){};let QueryCommand=class QueryCommand extends DynamoDBDocumentClientCommand{constructor(ee){super(),this.input=ee,this.inputKeyNodes={KeyConditions:{"*":{AttributeValueList:ex}},QueryFilter:{"*":{AttributeValueList:ex}},ExclusiveStartKey:e$,ExpressionAttributeValues:e$},this.outputKeyNodes={Items:{"*":e$},LastEvaluatedKey:e$},this.clientCommand=new QueryCommand_QueryCommand(this.input),this.middlewareStack=this.clientCommand.middlewareStack}resolveMiddleware(ee,et,en){this.addMarshallingMiddleware(et);let ei=ee.concat(this.middlewareStack),eo=this.clientCommand.resolveMiddleware(ei,et,en);return async()=>eo(this.clientCommand)}};let ScanCommand_ScanCommand=class ScanCommand_ScanCommand extends eh.mY.classBuilder().ep(ey.q).m(function(ee,et,en,ei){return[(0,ep.p2)(en,this.serialize,this.deserialize),(0,ef.a3)(en,ee.getEndpointParameterInstructions())]}).s("DynamoDB_20120810","Scan",{}).n("DynamoDBClient","ScanCommand").f(void 0,void 0).ser(em.Rl).de(em.$t).build(){};let ScanCommand=class ScanCommand extends DynamoDBDocumentClientCommand{constructor(ee){super(),this.input=ee,this.inputKeyNodes={ScanFilter:{"*":{AttributeValueList:ex}},ExclusiveStartKey:e$,ExpressionAttributeValues:e$},this.outputKeyNodes={Items:{"*":e$},LastEvaluatedKey:e$},this.clientCommand=new ScanCommand_ScanCommand(this.input),this.middlewareStack=this.clientCommand.middlewareStack}resolveMiddleware(ee,et,en){this.addMarshallingMiddleware(et);let ei=ee.concat(this.middlewareStack),eo=this.clientCommand.resolveMiddleware(ei,et,en);return async()=>eo(this.clientCommand)}};let TransactGetItemsCommand=class TransactGetItemsCommand extends eh.mY.classBuilder().ep(ey.q).m(function(ee,et,en,ei){return[(0,ep.p2)(en,this.serialize,this.deserialize),(0,ef.a3)(en,ee.getEndpointParameterInstructions())]}).s("DynamoDB_20120810","TransactGetItems",{}).n("DynamoDBClient","TransactGetItemsCommand").f(void 0,void 0).ser(em.xN).de(em.Ow).build(){};let TransactGetCommand=class TransactGetCommand extends DynamoDBDocumentClientCommand{constructor(ee){super(),this.input=ee,this.inputKeyNodes={TransactItems:{"*":{Get:{Key:e$}}}},this.outputKeyNodes={Responses:{"*":{Item:e$}}},this.clientCommand=new TransactGetItemsCommand(this.input),this.middlewareStack=this.clientCommand.middlewareStack}resolveMiddleware(ee,et,en){this.addMarshallingMiddleware(et);let ei=ee.concat(this.middlewareStack),eo=this.clientCommand.resolveMiddleware(ei,et,en);return async()=>eo(this.clientCommand)}};let TransactWriteItemsCommand=class TransactWriteItemsCommand extends eh.mY.classBuilder().ep(ey.q).m(function(ee,et,en,ei){return[(0,ep.p2)(en,this.serialize,this.deserialize),(0,ef.a3)(en,ee.getEndpointParameterInstructions())]}).s("DynamoDB_20120810","TransactWriteItems",{}).n("DynamoDBClient","TransactWriteItemsCommand").f(void 0,void 0).ser(em.SZ).de(em.G7).build(){};let TransactWriteCommand=class TransactWriteCommand extends DynamoDBDocumentClientCommand{constructor(ee){super(),this.input=ee,this.inputKeyNodes={TransactItems:{"*":{ConditionCheck:{Key:e$,ExpressionAttributeValues:e$},Put:{Item:e$,ExpressionAttributeValues:e$},Delete:{Key:e$,ExpressionAttributeValues:e$},Update:{Key:e$,ExpressionAttributeValues:e$}}}},this.outputKeyNodes={ItemCollectionMetrics:{"*":{"*":{ItemCollectionKey:e$}}}},this.clientCommand=new TransactWriteItemsCommand(this.input),this.middlewareStack=this.clientCommand.middlewareStack}resolveMiddleware(ee,et,en){this.addMarshallingMiddleware(et);let ei=ee.concat(this.middlewareStack),eo=this.clientCommand.resolveMiddleware(ei,et,en);return async()=>eo(this.clientCommand)}};let UpdateItemCommand=class UpdateItemCommand extends eh.mY.classBuilder().ep(ey.q).m(function(ee,et,en,ei){return[(0,ep.p2)(en,this.serialize,this.deserialize),(0,ef.a3)(en,ee.getEndpointParameterInstructions())]}).s("DynamoDB_20120810","UpdateItem",{}).n("DynamoDBClient","UpdateItemCommand").f(void 0,void 0).ser(em.h1).de(em.er).build(){};let UpdateCommand=class UpdateCommand extends DynamoDBDocumentClientCommand{constructor(ee){super(),this.input=ee,this.inputKeyNodes={Key:e$,AttributeUpdates:{"*":{Value:eA}},Expected:{"*":{Value:eA,AttributeValueList:ex}},ExpressionAttributeValues:e$},this.outputKeyNodes={Attributes:e$,ItemCollectionMetrics:{ItemCollectionKey:e$}},this.clientCommand=new UpdateItemCommand(this.input),this.middlewareStack=this.clientCommand.middlewareStack}resolveMiddleware(ee,et,en){this.addMarshallingMiddleware(et);let ei=ee.concat(this.middlewareStack),eo=this.clientCommand.resolveMiddleware(ei,et,en);return async()=>eo(this.clientCommand)}};let DynamoDBDocumentClient=class DynamoDBDocumentClient extends Client{constructor(ee,et){if(super(ee.config),this.config=ee.config,this.config.translateConfig=et,this.middlewareStack=ee.middlewareStack,this.config?.cacheMiddleware)throw Error("@aws-sdk/lib-dynamodb - cacheMiddleware=true is not compatible with the DynamoDBDocumentClient. This option must be set to false.")}static from(ee,et){return new DynamoDBDocumentClient(ee,et)}destroy(){}};let DynamoDBDocument=class DynamoDBDocument extends DynamoDBDocumentClient{static from(ee,et){return new DynamoDBDocument(ee,et)}batchExecuteStatement(ee,et,en){let ei=new BatchExecuteStatementCommand(ee);if("function"==typeof et)this.send(ei,et);else{if("function"!=typeof en)return this.send(ei,et);if("object"!=typeof et)throw Error(`Expect http options but get ${typeof et}`);this.send(ei,et||{},en)}}batchGet(ee,et,en){let ei=new BatchGetCommand(ee);if("function"==typeof et)this.send(ei,et);else{if("function"!=typeof en)return this.send(ei,et);if("object"!=typeof et)throw Error(`Expect http options but get ${typeof et}`);this.send(ei,et||{},en)}}batchWrite(ee,et,en){let ei=new BatchWriteCommand(ee);if("function"==typeof et)this.send(ei,et);else{if("function"!=typeof en)return this.send(ei,et);if("object"!=typeof et)throw Error(`Expect http options but get ${typeof et}`);this.send(ei,et||{},en)}}delete(ee,et,en){let ei=new DeleteCommand(ee);if("function"==typeof et)this.send(ei,et);else{if("function"!=typeof en)return this.send(ei,et);if("object"!=typeof et)throw Error(`Expect http options but get ${typeof et}`);this.send(ei,et||{},en)}}executeStatement(ee,et,en){let ei=new ExecuteStatementCommand(ee);if("function"==typeof et)this.send(ei,et);else{if("function"!=typeof en)return this.send(ei,et);if("object"!=typeof et)throw Error(`Expect http options but get ${typeof et}`);this.send(ei,et||{},en)}}executeTransaction(ee,et,en){let ei=new ExecuteTransactionCommand(ee);if("function"==typeof et)this.send(ei,et);else{if("function"!=typeof en)return this.send(ei,et);if("object"!=typeof et)throw Error(`Expect http options but get ${typeof et}`);this.send(ei,et||{},en)}}get(ee,et,en){let ei=new GetCommand(ee);if("function"==typeof et)this.send(ei,et);else{if("function"!=typeof en)return this.send(ei,et);if("object"!=typeof et)throw Error(`Expect http options but get ${typeof et}`);this.send(ei,et||{},en)}}put(ee,et,en){let ei=new PutCommand(ee);if("function"==typeof et)this.send(ei,et);else{if("function"!=typeof en)return this.send(ei,et);if("object"!=typeof et)throw Error(`Expect http options but get ${typeof et}`);this.send(ei,et||{},en)}}query(ee,et,en){let ei=new QueryCommand(ee);if("function"==typeof et)this.send(ei,et);else{if("function"!=typeof en)return this.send(ei,et);if("object"!=typeof et)throw Error(`Expect http options but get ${typeof et}`);this.send(ei,et||{},en)}}scan(ee,et,en){let ei=new ScanCommand(ee);if("function"==typeof et)this.send(ei,et);else{if("function"!=typeof en)return this.send(ei,et);if("object"!=typeof et)throw Error(`Expect http options but get ${typeof et}`);this.send(ei,et||{},en)}}transactGet(ee,et,en){let ei=new TransactGetCommand(ee);if("function"==typeof et)this.send(ei,et);else{if("function"!=typeof en)return this.send(ei,et);if("object"!=typeof et)throw Error(`Expect http options but get ${typeof et}`);this.send(ei,et||{},en)}}transactWrite(ee,et,en){let ei=new TransactWriteCommand(ee);if("function"==typeof et)this.send(ei,et);else{if("function"!=typeof en)return this.send(ei,et);if("object"!=typeof et)throw Error(`Expect http options but get ${typeof et}`);this.send(ei,et||{},en)}}update(ee,et,en){let ei=new UpdateCommand(ee);if("function"==typeof et)this.send(ei,et);else{if("function"!=typeof en)return this.send(ei,et);if("object"!=typeof et)throw Error(`Expect http options but get ${typeof et}`);this.send(ei,et||{},en)}}};var ek=en(17605);(0,ek.Mx)(DynamoDBDocumentClient,QueryCommand,"ExclusiveStartKey","LastEvaluatedKey","Limit"),(0,ek.Mx)(DynamoDBDocumentClient,ScanCommand,"ExclusiveStartKey","LastEvaluatedKey","Limit")},32866:function(ee,et,en){"use strict";en.d(et,{B:function(){return s}});var ei=en(67294),eo=en(87536),s=function(ee){var et=ee.as,en=ee.errors,ea=ee.name,es=ee.message,eu=ee.render,ec=function(ee,et){if(null==ee)return{};var en,ei,eo={},ea=Object.keys(ee);for(ei=0;ei=0||(eo[en]=ee[en]);return eo}(ee,["as","errors","name","message","render"]),ed=(0,eo.Gc)(),ef=(0,eo.U2)(en||ed.formState.errors,ea);if(!ef)return null;var ep=ef.message,eh=ef.types,ey=Object.assign({},ec,{children:ep||es});return ei.isValidElement(et)?ei.cloneElement(et,ey):eu?eu({message:ep||es,messages:eh}):ei.createElement(et||ei.Fragment,ey)}},17605:function(ee,et,en){"use strict";en.d(et,{K5:function(){return DefaultIdentityProviderConfig},Mx:function(){return createPaginator},zV:function(){return doesIdentityRequireRefresh},tZ:function(){return getHttpAuthSchemeEndpointRuleSetPlugin},aZ:function(){return getHttpSigningPlugin},BP:function(){return eA},CU:function(){return memoizeIdentityProvider},$E:function(){return normalizeProvider_normalizeProvider}}),function(ee){ee.HEADER="header",ee.QUERY="query"}(ei||(ei={})),function(ee){ee.HEADER="header",ee.QUERY="query"}(eo||(eo={})),function(ee){ee.HTTP="http",ee.HTTPS="https"}(ea||(ea={})),function(ee){ee.MD5="md5",ee.CRC32="crc32",ee.CRC32C="crc32c",ee.SHA1="sha1",ee.SHA256="sha256"}(es||(es={})),function(ee){ee[ee.HEADER=0]="HEADER",ee[ee.TRAILER=1]="TRAILER"}(eu||(eu={})),function(ee){ee.PROFILE="profile",ee.SSO_SESSION="sso-session",ee.SERVICES="services"}(ec||(ec={})),function(ee){ee.HTTP_0_9="http/0.9",ee.HTTP_1_0="http/1.0",ee.TDS_8_0="tds/8.0"}(ed||(ed={}));var ei,eo,ea,es,eu,ec,ed,ef,ep=en(61032);function convertHttpAuthSchemesToMap(ee){let et=new Map;for(let en of ee)et.set(en.schemeId,en);return et}let httpAuthSchemeMiddleware_httpAuthSchemeMiddleware=(ee,et)=>(en,ei)=>async eo=>{let ea=ee.httpAuthSchemeProvider(await et.httpAuthSchemeParametersProvider(ee,ei,eo.input)),es=convertHttpAuthSchemesToMap(ee.httpAuthSchemes),eu=(0,ep.J)(ei),ec=[];for(let en of ea){let eo=es.get(en.schemeId);if(!eo){ec.push(`HttpAuthScheme \`${en.schemeId}\` was not enabled for this service.`);continue}let ea=eo.identityProvider(await et.identityProviderConfigProvider(ee));if(!ea){ec.push(`HttpAuthScheme \`${en.schemeId}\` did not have an IdentityProvider configured.`);continue}let{identityProperties:ed={},signingProperties:ef={}}=en.propertiesExtractor?.(ee,ei)||{};en.identityProperties=Object.assign(en.identityProperties||{},ed),en.signingProperties=Object.assign(en.signingProperties||{},ef),eu.selectedHttpAuthScheme={httpAuthOption:en,identity:await ea(en.identityProperties),signer:eo.signer};break}if(!eu.selectedHttpAuthScheme)throw Error(ec.join("\n"));return en(eo)},eh={name:"serializerMiddleware"},ey={step:"serialize",tags:["ENDPOINT_PARAMETERS","ENDPOINT_V2","ENDPOINT"],name:"endpointV2Middleware",override:!0,relation:"before",toMiddleware:eh.name},em={step:"serialize",tags:["HTTP_AUTH_SCHEME"],name:"httpAuthSchemeMiddleware",override:!0,relation:"before",toMiddleware:ey.name},getHttpAuthSchemeEndpointRuleSetPlugin=(ee,{httpAuthSchemeParametersProvider:et,identityProviderConfigProvider:en})=>({applyToStack:ei=>{ei.addRelativeTo(httpAuthSchemeMiddleware_httpAuthSchemeMiddleware(ee,{httpAuthSchemeParametersProvider:et,identityProviderConfigProvider:en}),em)}});eh.name;let httpRequest_HttpRequest=class httpRequest_HttpRequest{constructor(ee){this.method=ee.method||"GET",this.hostname=ee.hostname||"localhost",this.port=ee.port,this.query=ee.query||{},this.headers=ee.headers||{},this.body=ee.body,this.protocol=ee.protocol?":"!==ee.protocol.slice(-1)?`${ee.protocol}:`:ee.protocol:"https:",this.path=ee.path?"/"!==ee.path.charAt(0)?`/${ee.path}`:ee.path:"/",this.username=ee.username,this.password=ee.password,this.fragment=ee.fragment}static clone(ee){let et=new httpRequest_HttpRequest({...ee,headers:{...ee.headers}});return et.query&&(et.query=cloneQuery(et.query)),et}static isInstance(ee){if(!ee)return!1;let et=ee;return"method"in et&&"protocol"in et&&"hostname"in et&&"path"in et&&"object"==typeof et.query&&"object"==typeof et.headers}clone(){return httpRequest_HttpRequest.clone(this)}};function cloneQuery(ee){return Object.keys(ee).reduce((et,en)=>{let ei=ee[en];return{...et,[en]:Array.isArray(ei)?[...ei]:ei}},{})}let defaultErrorHandler=ee=>ee=>{throw ee},defaultSuccessHandler=(ee,et)=>{},httpSigningMiddleware=ee=>(ee,et)=>async en=>{if(!httpRequest_HttpRequest.isInstance(en.request))return ee(en);let ei=(0,ep.J)(et),eo=ei.selectedHttpAuthScheme;if(!eo)throw Error("No HttpAuthScheme was selected: unable to sign request");let{httpAuthOption:{signingProperties:ea={}},identity:es,signer:eu}=eo,ec=await ee({...en,request:await eu.sign(en.request,es,ea)}).catch((eu.errorHandler||defaultErrorHandler)(ea));return(eu.successHandler||defaultSuccessHandler)(ec.response,ea),ec};!function(ee){ee.STANDARD="standard",ee.ADAPTIVE="adaptive"}(ef||(ef={})),ef.STANDARD;let eg={},eb=Array(64);for(let ee=0,et=65,en=90;ee+et<=en;ee++){let en=String.fromCharCode(ee+et);eg[en]=ee,eb[ee]=en}for(let ee=0,et=97,en=122;ee+et<=en;ee++){let en=String.fromCharCode(ee+et),ei=ee+26;eg[en]=ei,eb[ei]=en}for(let ee=0;ee<10;ee++){eg[ee.toString(10)]=ee+52;let et=ee.toString(10),en=ee+52;eg[et]=en,eb[en]=et}eg["+"]=62,eb[62]="+",eg["/"]=63,eb[63]="/";let ev={},e_={};for(let ee=0;ee<256;ee++){let et=ee.toString(16).toLowerCase();1===et.length&&(et=`0${et}`),ev[ee]=et,e_[et]=ee}let StringWrapper=function(){let ee=Object.getPrototypeOf(this).constructor,et=Function.bind.apply(String,[null,...arguments]),en=new et;return Object.setPrototypeOf(en,ee.prototype),en};StringWrapper.prototype=Object.create(String.prototype,{constructor:{value:StringWrapper,enumerable:!1,writable:!0,configurable:!0}}),Object.setPrototypeOf(StringWrapper,String);let ew={name:"retryMiddleware"},eS={step:"finalizeRequest",tags:["HTTP_SIGNING"],name:"httpSigningMiddleware",aliases:["apiKeyMiddleware","tokenMiddleware","awsAuthMiddleware"],override:!0,relation:"after",toMiddleware:ew.name},getHttpSigningPlugin=ee=>({applyToStack:et=>{et.addRelativeTo(httpSigningMiddleware(ee),eS)}});let DefaultIdentityProviderConfig=class DefaultIdentityProviderConfig{constructor(ee){for(let[et,en]of(this.authSchemes=new Map,Object.entries(ee)))void 0!==en&&this.authSchemes.set(et,en)}getIdentityProvider(ee){return this.authSchemes.get(ee)}};let createIsIdentityExpiredFunction=ee=>et=>doesIdentityRequireRefresh(et)&&et.expiration.getTime()-Date.now()void 0!==ee.expiration,memoizeIdentityProvider=(ee,et,en)=>{let ei,eo,ea;if(void 0===ee)return;let es="function"!=typeof ee?async()=>Promise.resolve(ee):ee,eu=!1,coalesceProvider=async ee=>{eo||(eo=es(ee));try{ei=await eo,ea=!0,eu=!1}finally{eo=void 0}return ei};return void 0===et?async ee=>((!ea||ee?.forceRefresh)&&(ei=await coalesceProvider(ee)),ei):async ee=>((!ea||ee?.forceRefresh)&&(ei=await coalesceProvider(ee)),eu||(en(ei)?et(ei)&&await coalesceProvider(ee):eu=!0),ei)},normalizeProvider_normalizeProvider=ee=>{if("function"==typeof ee)return ee;let et=Promise.resolve(ee);return()=>et},makePagedClientRequest=async(ee,et,en,...ei)=>await et.send(new ee(en),...ei);function createPaginator(ee,et,en,ei,eo){return async function*(ea,es,...eu){let ec,ed=ea.startingToken||void 0,ef=!0;for(;ef;){if(es[en]=ed,eo&&(es[eo]=es[eo]??ea.pageSize),ea.client instanceof ee)ec=await makePagedClientRequest(et,ea.client,es,...eu);else throw Error(`Invalid client, expected instance of ${ee.name}`);yield ec;let ep=ed;ef=!!((ed=get(ec,ei))&&(!ea.stopOnSameToken||ed!==ep))}}}let get=(ee,et)=>{let en=ee,ei=et.split(".");for(let ee of ei){if(!en||"object"!=typeof en)return;en=en[ee]}return en}},61032:function(ee,et,en){"use strict";var ei,eo,ea,es,eu,ec,ed;en.d(et,{J:function(){return getSmithyContext},$:function(){return normalizeProvider}}),function(ee){ee.HEADER="header",ee.QUERY="query"}(ei||(ei={})),function(ee){ee.HEADER="header",ee.QUERY="query"}(eo||(eo={})),function(ee){ee.HTTP="http",ee.HTTPS="https"}(ea||(ea={})),function(ee){ee.MD5="md5",ee.CRC32="crc32",ee.CRC32C="crc32c",ee.SHA1="sha1",ee.SHA256="sha256"}(es||(es={})),function(ee){ee[ee.HEADER=0]="HEADER",ee[ee.TRAILER=1]="TRAILER"}(eu||(eu={}));let ef="__smithy_context";!function(ee){ee.PROFILE="profile",ee.SSO_SESSION="sso-session",ee.SERVICES="services"}(ec||(ec={})),function(ee){ee.HTTP_0_9="http/0.9",ee.HTTP_1_0="http/1.0",ee.TDS_8_0="tds/8.0"}(ed||(ed={}));let getSmithyContext=ee=>ee[ef]||(ee[ef]={}),normalizeProvider=ee=>{if("function"==typeof ee)return ee;let et=Promise.resolve(ee);return()=>et}},94445:function(ee,et,en){"use strict";en.d(et,{eO:function(){return useMachine}});var ei=en(67294),eo=en(61688),ea=en(10195),es=ei.useLayoutEffect;en(52798);let forEachActor=(ee,et)=>{et(ee);let en=ee.getSnapshot().children;en&&Object.values(en).forEach(ee=>{forEachActor(ee,et)})};function stopRootWithRehydration(ee){let et=[];forEachActor(ee,ee=>{et.push([ee,ee.getSnapshot()]),ee.observers=new Set});let en=ee.system.getSnapshot?.();ee.stop(),ee.system._snapshot=en,et.forEach(([ee,et])=>{ee._processingStatus=0,ee._snapshot=et})}function useIdleActorRef(ee,et){let[[en,eo],eu]=(0,ei.useState)(()=>{let en=(0,ea.z)(ee,et);return[ee.config,en]});if(ee.config!==en){let en=(0,ea.z)(ee,{...et,snapshot:eo.getPersistedSnapshot({__unsafeAllowInlineActors:!0})});eu([ee.config,en]),eo=en}return es(()=>{eo.logic.implementations=ee.implementations}),eo}function useActor(ee,et={}){let en=useIdleActorRef(ee,et),ea=(0,ei.useCallback)(()=>en.getSnapshot(),[en]),es=(0,ei.useCallback)(ee=>{let{unsubscribe:et}=en.subscribe(ee);return et},[en]),eu=(0,eo.useSyncExternalStore)(es,ea,ea);return(0,ei.useEffect)(()=>(en.start(),()=>{stopRootWithRehydration(en)}),[en]),[eu,en.send,en]}function useMachine(ee,et={}){return useActor(ee,et)}},79742:function(ee,et){"use strict";et.byteLength=byteLength,et.toByteArray=toByteArray,et.fromByteArray=fromByteArray;for(var en=[],ei=[],eo="undefined"!=typeof Uint8Array?Uint8Array:Array,ea="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",es=0,eu=ea.length;es0)throw Error("Invalid string. Length must be a multiple of 4");var en=ee.indexOf("=");-1===en&&(en=et);var ei=en===et?0:4-en%4;return[en,ei]}function byteLength(ee){var et=getLens(ee),en=et[0],ei=et[1];return(en+ei)*3/4-ei}function _byteLength(ee,et,en){return(et+en)*3/4-en}function toByteArray(ee){var et,en,ea=getLens(ee),es=ea[0],eu=ea[1],ec=new eo(_byteLength(ee,es,eu)),ed=0,ef=eu>0?es-4:es;for(en=0;en>16&255,ec[ed++]=et>>8&255,ec[ed++]=255&et;return 2===eu&&(et=ei[ee.charCodeAt(en)]<<2|ei[ee.charCodeAt(en+1)]>>4,ec[ed++]=255&et),1===eu&&(et=ei[ee.charCodeAt(en)]<<10|ei[ee.charCodeAt(en+1)]<<4|ei[ee.charCodeAt(en+2)]>>2,ec[ed++]=et>>8&255,ec[ed++]=255&et),ec}function tripletToBase64(ee){return en[ee>>18&63]+en[ee>>12&63]+en[ee>>6&63]+en[63&ee]}function encodeChunk(ee,et,en){for(var ei=[],eo=et;eoec?ec:eu+es));return 1===eo?ea.push(en[(et=ee[ei-1])>>2]+en[et<<4&63]+"=="):2===eo&&ea.push(en[(et=(ee[ei-2]<<8)+ee[ei-1])>>10]+en[et>>4&63]+en[et<<2&63]+"="),ea.join("")}ei["-".charCodeAt(0)]=62,ei["_".charCodeAt(0)]=63},51206:function(ee){!function(et,en){ee.exports=en()}(0,function(){return function(ee){var et={};function r(en){if(et[en])return et[en].exports;var ei=et[en]={i:en,l:!1,exports:{}};return ee[en].call(ei.exports,ei,ei.exports,r),ei.l=!0,ei.exports}return r.m=ee,r.c=et,r.d=function(ee,et,en){r.o(ee,et)||Object.defineProperty(ee,et,{enumerable:!0,get:en})},r.r=function(ee){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(ee,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(ee,"__esModule",{value:!0})},r.t=function(ee,et){if(1&et&&(ee=r(ee)),8&et||4&et&&"object"==typeof ee&&ee&&ee.__esModule)return ee;var en=Object.create(null);if(r.r(en),Object.defineProperty(en,"default",{enumerable:!0,value:ee}),2&et&&"string"!=typeof ee)for(var ei in ee)r.d(en,ei,(function(et){return ee[et]}).bind(null,ei));return en},r.n=function(ee){var et=ee&&ee.__esModule?function(){return ee.default}:function(){return ee};return r.d(et,"a",et),et},r.o=function(ee,et){return Object.prototype.hasOwnProperty.call(ee,et)},r.p="",r(r.s=90)}({17:function(ee,et,en){"use strict";et.__esModule=!0,et.default=void 0;var ei=en(18),eo=function(){function e(){}return e.getFirstMatch=function(ee,et){var en=et.match(ee);return en&&en.length>0&&en[1]||""},e.getSecondMatch=function(ee,et){var en=et.match(ee);return en&&en.length>1&&en[2]||""},e.matchAndReturnConst=function(ee,et,en){if(ee.test(et))return en},e.getWindowsVersionName=function(ee){switch(ee){case"NT":return"NT";case"XP":case"NT 5.1":return"XP";case"NT 5.0":return"2000";case"NT 5.2":return"2003";case"NT 6.0":return"Vista";case"NT 6.1":return"7";case"NT 6.2":return"8";case"NT 6.3":return"8.1";case"NT 10.0":return"10";default:return}},e.getMacOSVersionName=function(ee){var et=ee.split(".").splice(0,2).map(function(ee){return parseInt(ee,10)||0});if(et.push(0),10===et[0])switch(et[1]){case 5:return"Leopard";case 6:return"Snow Leopard";case 7:return"Lion";case 8:return"Mountain Lion";case 9:return"Mavericks";case 10:return"Yosemite";case 11:return"El Capitan";case 12:return"Sierra";case 13:return"High Sierra";case 14:return"Mojave";case 15:return"Catalina";default:return}},e.getAndroidVersionName=function(ee){var et=ee.split(".").splice(0,2).map(function(ee){return parseInt(ee,10)||0});if(et.push(0),!(1===et[0]&&et[1]<5))return 1===et[0]&&et[1]<6?"Cupcake":1===et[0]&&et[1]>=6?"Donut":2===et[0]&&et[1]<2?"Eclair":2===et[0]&&2===et[1]?"Froyo":2===et[0]&&et[1]>2?"Gingerbread":3===et[0]?"Honeycomb":4===et[0]&&et[1]<1?"Ice Cream Sandwich":4===et[0]&&et[1]<4?"Jelly Bean":4===et[0]&&et[1]>=4?"KitKat":5===et[0]?"Lollipop":6===et[0]?"Marshmallow":7===et[0]?"Nougat":8===et[0]?"Oreo":9===et[0]?"Pie":void 0},e.getVersionPrecision=function(ee){return ee.split(".").length},e.compareVersions=function(ee,et,en){void 0===en&&(en=!1);var ei=e.getVersionPrecision(ee),eo=e.getVersionPrecision(et),ea=Math.max(ei,eo),es=0,eu=e.map([ee,et],function(ee){var et=ea-e.getVersionPrecision(ee),en=ee+Array(et+1).join(".0");return e.map(en.split("."),function(ee){return Array(20-ee.length).join("0")+ee}).reverse()});for(en&&(es=ea-Math.min(ei,eo)),ea-=1;ea>=es;){if(eu[0][ea]>eu[1][ea])return 1;if(eu[0][ea]===eu[1][ea]){if(ea===es)return 0;ea-=1}else if(eu[0][ea]1?eo-1:0),es=1;es0){var es=Object.keys(en),ec=eu.default.find(es,function(ee){return et.isOS(ee)});if(ec){var ed=this.satisfies(en[ec]);if(void 0!==ed)return ed}var ef=eu.default.find(es,function(ee){return et.isPlatform(ee)});if(ef){var ep=this.satisfies(en[ef]);if(void 0!==ep)return ep}}if(ea>0){var eh=Object.keys(eo),ey=eu.default.find(eh,function(ee){return et.isBrowser(ee,!0)});if(void 0!==ey)return this.compareVersion(eo[ey])}},ee.isBrowser=function(ee,et){void 0===et&&(et=!1);var en=this.getBrowserName().toLowerCase(),ei=ee.toLowerCase(),eo=eu.default.getBrowserTypeByAlias(ei);return et&&eo&&(ei=eo.toLowerCase()),ei===en},ee.compareVersion=function(ee){var et=[0],en=ee,ei=!1,eo=this.getBrowserVersion();if("string"==typeof eo)return">"===ee[0]||"<"===ee[0]?(en=ee.substr(1),"="===ee[1]?(ei=!0,en=ee.substr(2)):et=[],">"===ee[0]?et.push(1):et.push(-1)):"="===ee[0]?en=ee.substr(1):"~"===ee[0]&&(ei=!0,en=ee.substr(1)),et.indexOf(eu.default.compareVersions(eo,en,ei))>-1},ee.isOS=function(ee){return this.getOSName(!0)===String(ee).toLowerCase()},ee.isPlatform=function(ee){return this.getPlatformType(!0)===String(ee).toLowerCase()},ee.isEngine=function(ee){return this.getEngineName(!0)===String(ee).toLowerCase()},ee.is=function(ee,et){return void 0===et&&(et=!1),this.isBrowser(ee,et)||this.isOS(ee)||this.isPlatform(ee)},ee.some=function(ee){var et=this;return void 0===ee&&(ee=[]),ee.some(function(ee){return et.is(ee)})},e}();et.default=ec,ee.exports=et.default},92:function(ee,et,en){"use strict";et.__esModule=!0,et.default=void 0;var ei,eo=(ei=en(17))&&ei.__esModule?ei:{default:ei},ea=/version\/(\d+(\.?_?\d+)+)/i,es=[{test:[/googlebot/i],describe:function(ee){var et={name:"Googlebot"},en=eo.default.getFirstMatch(/googlebot\/(\d+(\.\d+))/i,ee)||eo.default.getFirstMatch(ea,ee);return en&&(et.version=en),et}},{test:[/opera/i],describe:function(ee){var et={name:"Opera"},en=eo.default.getFirstMatch(ea,ee)||eo.default.getFirstMatch(/(?:opera)[\s/](\d+(\.?_?\d+)+)/i,ee);return en&&(et.version=en),et}},{test:[/opr\/|opios/i],describe:function(ee){var et={name:"Opera"},en=eo.default.getFirstMatch(/(?:opr|opios)[\s/](\S+)/i,ee)||eo.default.getFirstMatch(ea,ee);return en&&(et.version=en),et}},{test:[/SamsungBrowser/i],describe:function(ee){var et={name:"Samsung Internet for Android"},en=eo.default.getFirstMatch(ea,ee)||eo.default.getFirstMatch(/(?:SamsungBrowser)[\s/](\d+(\.?_?\d+)+)/i,ee);return en&&(et.version=en),et}},{test:[/Whale/i],describe:function(ee){var et={name:"NAVER Whale Browser"},en=eo.default.getFirstMatch(ea,ee)||eo.default.getFirstMatch(/(?:whale)[\s/](\d+(?:\.\d+)+)/i,ee);return en&&(et.version=en),et}},{test:[/MZBrowser/i],describe:function(ee){var et={name:"MZ Browser"},en=eo.default.getFirstMatch(/(?:MZBrowser)[\s/](\d+(?:\.\d+)+)/i,ee)||eo.default.getFirstMatch(ea,ee);return en&&(et.version=en),et}},{test:[/focus/i],describe:function(ee){var et={name:"Focus"},en=eo.default.getFirstMatch(/(?:focus)[\s/](\d+(?:\.\d+)+)/i,ee)||eo.default.getFirstMatch(ea,ee);return en&&(et.version=en),et}},{test:[/swing/i],describe:function(ee){var et={name:"Swing"},en=eo.default.getFirstMatch(/(?:swing)[\s/](\d+(?:\.\d+)+)/i,ee)||eo.default.getFirstMatch(ea,ee);return en&&(et.version=en),et}},{test:[/coast/i],describe:function(ee){var et={name:"Opera Coast"},en=eo.default.getFirstMatch(ea,ee)||eo.default.getFirstMatch(/(?:coast)[\s/](\d+(\.?_?\d+)+)/i,ee);return en&&(et.version=en),et}},{test:[/opt\/\d+(?:.?_?\d+)+/i],describe:function(ee){var et={name:"Opera Touch"},en=eo.default.getFirstMatch(/(?:opt)[\s/](\d+(\.?_?\d+)+)/i,ee)||eo.default.getFirstMatch(ea,ee);return en&&(et.version=en),et}},{test:[/yabrowser/i],describe:function(ee){var et={name:"Yandex Browser"},en=eo.default.getFirstMatch(/(?:yabrowser)[\s/](\d+(\.?_?\d+)+)/i,ee)||eo.default.getFirstMatch(ea,ee);return en&&(et.version=en),et}},{test:[/ucbrowser/i],describe:function(ee){var et={name:"UC Browser"},en=eo.default.getFirstMatch(ea,ee)||eo.default.getFirstMatch(/(?:ucbrowser)[\s/](\d+(\.?_?\d+)+)/i,ee);return en&&(et.version=en),et}},{test:[/Maxthon|mxios/i],describe:function(ee){var et={name:"Maxthon"},en=eo.default.getFirstMatch(ea,ee)||eo.default.getFirstMatch(/(?:Maxthon|mxios)[\s/](\d+(\.?_?\d+)+)/i,ee);return en&&(et.version=en),et}},{test:[/epiphany/i],describe:function(ee){var et={name:"Epiphany"},en=eo.default.getFirstMatch(ea,ee)||eo.default.getFirstMatch(/(?:epiphany)[\s/](\d+(\.?_?\d+)+)/i,ee);return en&&(et.version=en),et}},{test:[/puffin/i],describe:function(ee){var et={name:"Puffin"},en=eo.default.getFirstMatch(ea,ee)||eo.default.getFirstMatch(/(?:puffin)[\s/](\d+(\.?_?\d+)+)/i,ee);return en&&(et.version=en),et}},{test:[/sleipnir/i],describe:function(ee){var et={name:"Sleipnir"},en=eo.default.getFirstMatch(ea,ee)||eo.default.getFirstMatch(/(?:sleipnir)[\s/](\d+(\.?_?\d+)+)/i,ee);return en&&(et.version=en),et}},{test:[/k-meleon/i],describe:function(ee){var et={name:"K-Meleon"},en=eo.default.getFirstMatch(ea,ee)||eo.default.getFirstMatch(/(?:k-meleon)[\s/](\d+(\.?_?\d+)+)/i,ee);return en&&(et.version=en),et}},{test:[/micromessenger/i],describe:function(ee){var et={name:"WeChat"},en=eo.default.getFirstMatch(/(?:micromessenger)[\s/](\d+(\.?_?\d+)+)/i,ee)||eo.default.getFirstMatch(ea,ee);return en&&(et.version=en),et}},{test:[/qqbrowser/i],describe:function(ee){var et={name:/qqbrowserlite/i.test(ee)?"QQ Browser Lite":"QQ Browser"},en=eo.default.getFirstMatch(/(?:qqbrowserlite|qqbrowser)[/](\d+(\.?_?\d+)+)/i,ee)||eo.default.getFirstMatch(ea,ee);return en&&(et.version=en),et}},{test:[/msie|trident/i],describe:function(ee){var et={name:"Internet Explorer"},en=eo.default.getFirstMatch(/(?:msie |rv:)(\d+(\.?_?\d+)+)/i,ee);return en&&(et.version=en),et}},{test:[/\sedg\//i],describe:function(ee){var et={name:"Microsoft Edge"},en=eo.default.getFirstMatch(/\sedg\/(\d+(\.?_?\d+)+)/i,ee);return en&&(et.version=en),et}},{test:[/edg([ea]|ios)/i],describe:function(ee){var et={name:"Microsoft Edge"},en=eo.default.getSecondMatch(/edg([ea]|ios)\/(\d+(\.?_?\d+)+)/i,ee);return en&&(et.version=en),et}},{test:[/vivaldi/i],describe:function(ee){var et={name:"Vivaldi"},en=eo.default.getFirstMatch(/vivaldi\/(\d+(\.?_?\d+)+)/i,ee);return en&&(et.version=en),et}},{test:[/seamonkey/i],describe:function(ee){var et={name:"SeaMonkey"},en=eo.default.getFirstMatch(/seamonkey\/(\d+(\.?_?\d+)+)/i,ee);return en&&(et.version=en),et}},{test:[/sailfish/i],describe:function(ee){var et={name:"Sailfish"},en=eo.default.getFirstMatch(/sailfish\s?browser\/(\d+(\.\d+)?)/i,ee);return en&&(et.version=en),et}},{test:[/silk/i],describe:function(ee){var et={name:"Amazon Silk"},en=eo.default.getFirstMatch(/silk\/(\d+(\.?_?\d+)+)/i,ee);return en&&(et.version=en),et}},{test:[/phantom/i],describe:function(ee){var et={name:"PhantomJS"},en=eo.default.getFirstMatch(/phantomjs\/(\d+(\.?_?\d+)+)/i,ee);return en&&(et.version=en),et}},{test:[/slimerjs/i],describe:function(ee){var et={name:"SlimerJS"},en=eo.default.getFirstMatch(/slimerjs\/(\d+(\.?_?\d+)+)/i,ee);return en&&(et.version=en),et}},{test:[/blackberry|\bbb\d+/i,/rim\stablet/i],describe:function(ee){var et={name:"BlackBerry"},en=eo.default.getFirstMatch(ea,ee)||eo.default.getFirstMatch(/blackberry[\d]+\/(\d+(\.?_?\d+)+)/i,ee);return en&&(et.version=en),et}},{test:[/(web|hpw)[o0]s/i],describe:function(ee){var et={name:"WebOS Browser"},en=eo.default.getFirstMatch(ea,ee)||eo.default.getFirstMatch(/w(?:eb)?[o0]sbrowser\/(\d+(\.?_?\d+)+)/i,ee);return en&&(et.version=en),et}},{test:[/bada/i],describe:function(ee){var et={name:"Bada"},en=eo.default.getFirstMatch(/dolfin\/(\d+(\.?_?\d+)+)/i,ee);return en&&(et.version=en),et}},{test:[/tizen/i],describe:function(ee){var et={name:"Tizen"},en=eo.default.getFirstMatch(/(?:tizen\s?)?browser\/(\d+(\.?_?\d+)+)/i,ee)||eo.default.getFirstMatch(ea,ee);return en&&(et.version=en),et}},{test:[/qupzilla/i],describe:function(ee){var et={name:"QupZilla"},en=eo.default.getFirstMatch(/(?:qupzilla)[\s/](\d+(\.?_?\d+)+)/i,ee)||eo.default.getFirstMatch(ea,ee);return en&&(et.version=en),et}},{test:[/firefox|iceweasel|fxios/i],describe:function(ee){var et={name:"Firefox"},en=eo.default.getFirstMatch(/(?:firefox|iceweasel|fxios)[\s/](\d+(\.?_?\d+)+)/i,ee);return en&&(et.version=en),et}},{test:[/electron/i],describe:function(ee){var et={name:"Electron"},en=eo.default.getFirstMatch(/(?:electron)\/(\d+(\.?_?\d+)+)/i,ee);return en&&(et.version=en),et}},{test:[/MiuiBrowser/i],describe:function(ee){var et={name:"Miui"},en=eo.default.getFirstMatch(/(?:MiuiBrowser)[\s/](\d+(\.?_?\d+)+)/i,ee);return en&&(et.version=en),et}},{test:[/chromium/i],describe:function(ee){var et={name:"Chromium"},en=eo.default.getFirstMatch(/(?:chromium)[\s/](\d+(\.?_?\d+)+)/i,ee)||eo.default.getFirstMatch(ea,ee);return en&&(et.version=en),et}},{test:[/chrome|crios|crmo/i],describe:function(ee){var et={name:"Chrome"},en=eo.default.getFirstMatch(/(?:chrome|crios|crmo)\/(\d+(\.?_?\d+)+)/i,ee);return en&&(et.version=en),et}},{test:[/GSA/i],describe:function(ee){var et={name:"Google Search"},en=eo.default.getFirstMatch(/(?:GSA)\/(\d+(\.?_?\d+)+)/i,ee);return en&&(et.version=en),et}},{test:function(ee){var et=!ee.test(/like android/i),en=ee.test(/android/i);return et&&en},describe:function(ee){var et={name:"Android Browser"},en=eo.default.getFirstMatch(ea,ee);return en&&(et.version=en),et}},{test:[/playstation 4/i],describe:function(ee){var et={name:"PlayStation 4"},en=eo.default.getFirstMatch(ea,ee);return en&&(et.version=en),et}},{test:[/safari|applewebkit/i],describe:function(ee){var et={name:"Safari"},en=eo.default.getFirstMatch(ea,ee);return en&&(et.version=en),et}},{test:[/.*/i],describe:function(ee){var et=-1!==ee.search("\\(")?/^(.*)\/(.*)[ \t]\((.*)/:/^(.*)\/(.*) /;return{name:eo.default.getFirstMatch(et,ee),version:eo.default.getSecondMatch(et,ee)}}}];et.default=es,ee.exports=et.default},93:function(ee,et,en){"use strict";et.__esModule=!0,et.default=void 0;var ei,eo=(ei=en(17))&&ei.__esModule?ei:{default:ei},ea=en(18),es=[{test:[/Roku\/DVP/],describe:function(ee){var et=eo.default.getFirstMatch(/Roku\/DVP-(\d+\.\d+)/i,ee);return{name:ea.OS_MAP.Roku,version:et}}},{test:[/windows phone/i],describe:function(ee){var et=eo.default.getFirstMatch(/windows phone (?:os)?\s?(\d+(\.\d+)*)/i,ee);return{name:ea.OS_MAP.WindowsPhone,version:et}}},{test:[/windows /i],describe:function(ee){var et=eo.default.getFirstMatch(/Windows ((NT|XP)( \d\d?.\d)?)/i,ee),en=eo.default.getWindowsVersionName(et);return{name:ea.OS_MAP.Windows,version:et,versionName:en}}},{test:[/Macintosh(.*?) FxiOS(.*?)\//],describe:function(ee){var et={name:ea.OS_MAP.iOS},en=eo.default.getSecondMatch(/(Version\/)(\d[\d.]+)/,ee);return en&&(et.version=en),et}},{test:[/macintosh/i],describe:function(ee){var et=eo.default.getFirstMatch(/mac os x (\d+(\.?_?\d+)+)/i,ee).replace(/[_\s]/g,"."),en=eo.default.getMacOSVersionName(et),ei={name:ea.OS_MAP.MacOS,version:et};return en&&(ei.versionName=en),ei}},{test:[/(ipod|iphone|ipad)/i],describe:function(ee){var et=eo.default.getFirstMatch(/os (\d+([_\s]\d+)*) like mac os x/i,ee).replace(/[_\s]/g,".");return{name:ea.OS_MAP.iOS,version:et}}},{test:function(ee){var et=!ee.test(/like android/i),en=ee.test(/android/i);return et&&en},describe:function(ee){var et=eo.default.getFirstMatch(/android[\s/-](\d+(\.\d+)*)/i,ee),en=eo.default.getAndroidVersionName(et),ei={name:ea.OS_MAP.Android,version:et};return en&&(ei.versionName=en),ei}},{test:[/(web|hpw)[o0]s/i],describe:function(ee){var et=eo.default.getFirstMatch(/(?:web|hpw)[o0]s\/(\d+(\.\d+)*)/i,ee),en={name:ea.OS_MAP.WebOS};return et&&et.length&&(en.version=et),en}},{test:[/blackberry|\bbb\d+/i,/rim\stablet/i],describe:function(ee){var et=eo.default.getFirstMatch(/rim\stablet\sos\s(\d+(\.\d+)*)/i,ee)||eo.default.getFirstMatch(/blackberry\d+\/(\d+([_\s]\d+)*)/i,ee)||eo.default.getFirstMatch(/\bbb(\d+)/i,ee);return{name:ea.OS_MAP.BlackBerry,version:et}}},{test:[/bada/i],describe:function(ee){var et=eo.default.getFirstMatch(/bada\/(\d+(\.\d+)*)/i,ee);return{name:ea.OS_MAP.Bada,version:et}}},{test:[/tizen/i],describe:function(ee){var et=eo.default.getFirstMatch(/tizen[/\s](\d+(\.\d+)*)/i,ee);return{name:ea.OS_MAP.Tizen,version:et}}},{test:[/linux/i],describe:function(){return{name:ea.OS_MAP.Linux}}},{test:[/CrOS/],describe:function(){return{name:ea.OS_MAP.ChromeOS}}},{test:[/PlayStation 4/],describe:function(ee){var et=eo.default.getFirstMatch(/PlayStation 4[/\s](\d+(\.\d+)*)/i,ee);return{name:ea.OS_MAP.PlayStation4,version:et}}}];et.default=es,ee.exports=et.default},94:function(ee,et,en){"use strict";et.__esModule=!0,et.default=void 0;var ei,eo=(ei=en(17))&&ei.__esModule?ei:{default:ei},ea=en(18),es=[{test:[/googlebot/i],describe:function(){return{type:"bot",vendor:"Google"}}},{test:[/huawei/i],describe:function(ee){var et=eo.default.getFirstMatch(/(can-l01)/i,ee)&&"Nova",en={type:ea.PLATFORMS_MAP.mobile,vendor:"Huawei"};return et&&(en.model=et),en}},{test:[/nexus\s*(?:7|8|9|10).*/i],describe:function(){return{type:ea.PLATFORMS_MAP.tablet,vendor:"Nexus"}}},{test:[/ipad/i],describe:function(){return{type:ea.PLATFORMS_MAP.tablet,vendor:"Apple",model:"iPad"}}},{test:[/Macintosh(.*?) FxiOS(.*?)\//],describe:function(){return{type:ea.PLATFORMS_MAP.tablet,vendor:"Apple",model:"iPad"}}},{test:[/kftt build/i],describe:function(){return{type:ea.PLATFORMS_MAP.tablet,vendor:"Amazon",model:"Kindle Fire HD 7"}}},{test:[/silk/i],describe:function(){return{type:ea.PLATFORMS_MAP.tablet,vendor:"Amazon"}}},{test:[/tablet(?! pc)/i],describe:function(){return{type:ea.PLATFORMS_MAP.tablet}}},{test:function(ee){var et=ee.test(/ipod|iphone/i),en=ee.test(/like (ipod|iphone)/i);return et&&!en},describe:function(ee){var et=eo.default.getFirstMatch(/(ipod|iphone)/i,ee);return{type:ea.PLATFORMS_MAP.mobile,vendor:"Apple",model:et}}},{test:[/nexus\s*[0-6].*/i,/galaxy nexus/i],describe:function(){return{type:ea.PLATFORMS_MAP.mobile,vendor:"Nexus"}}},{test:[/[^-]mobi/i],describe:function(){return{type:ea.PLATFORMS_MAP.mobile}}},{test:function(ee){return"blackberry"===ee.getBrowserName(!0)},describe:function(){return{type:ea.PLATFORMS_MAP.mobile,vendor:"BlackBerry"}}},{test:function(ee){return"bada"===ee.getBrowserName(!0)},describe:function(){return{type:ea.PLATFORMS_MAP.mobile}}},{test:function(ee){return"windows phone"===ee.getBrowserName()},describe:function(){return{type:ea.PLATFORMS_MAP.mobile,vendor:"Microsoft"}}},{test:function(ee){var et=Number(String(ee.getOSVersion()).split(".")[0]);return"android"===ee.getOSName(!0)&&et>=3},describe:function(){return{type:ea.PLATFORMS_MAP.tablet}}},{test:function(ee){return"android"===ee.getOSName(!0)},describe:function(){return{type:ea.PLATFORMS_MAP.mobile}}},{test:function(ee){return"macos"===ee.getOSName(!0)},describe:function(){return{type:ea.PLATFORMS_MAP.desktop,vendor:"Apple"}}},{test:function(ee){return"windows"===ee.getOSName(!0)},describe:function(){return{type:ea.PLATFORMS_MAP.desktop}}},{test:function(ee){return"linux"===ee.getOSName(!0)},describe:function(){return{type:ea.PLATFORMS_MAP.desktop}}},{test:function(ee){return"playstation 4"===ee.getOSName(!0)},describe:function(){return{type:ea.PLATFORMS_MAP.tv}}},{test:function(ee){return"roku"===ee.getOSName(!0)},describe:function(){return{type:ea.PLATFORMS_MAP.tv}}}];et.default=es,ee.exports=et.default},95:function(ee,et,en){"use strict";et.__esModule=!0,et.default=void 0;var ei,eo=(ei=en(17))&&ei.__esModule?ei:{default:ei},ea=en(18),es=[{test:function(ee){return"microsoft edge"===ee.getBrowserName(!0)},describe:function(ee){if(/\sedg\//i.test(ee))return{name:ea.ENGINE_MAP.Blink};var et=eo.default.getFirstMatch(/edge\/(\d+(\.?_?\d+)+)/i,ee);return{name:ea.ENGINE_MAP.EdgeHTML,version:et}}},{test:[/trident/i],describe:function(ee){var et={name:ea.ENGINE_MAP.Trident},en=eo.default.getFirstMatch(/trident\/(\d+(\.?_?\d+)+)/i,ee);return en&&(et.version=en),et}},{test:function(ee){return ee.test(/presto/i)},describe:function(ee){var et={name:ea.ENGINE_MAP.Presto},en=eo.default.getFirstMatch(/presto\/(\d+(\.?_?\d+)+)/i,ee);return en&&(et.version=en),et}},{test:function(ee){var et=ee.test(/gecko/i),en=ee.test(/like gecko/i);return et&&!en},describe:function(ee){var et={name:ea.ENGINE_MAP.Gecko},en=eo.default.getFirstMatch(/gecko\/(\d+(\.?_?\d+)+)/i,ee);return en&&(et.version=en),et}},{test:[/(apple)?webkit\/537\.36/i],describe:function(){return{name:ea.ENGINE_MAP.Blink}}},{test:[/(apple)?webkit/i],describe:function(ee){var et={name:ea.ENGINE_MAP.WebKit},en=eo.default.getFirstMatch(/webkit\/(\d+(\.?_?\d+)+)/i,ee);return en&&(et.version=en),et}}];et.default=es,ee.exports=et.default}})})},48764:function(ee,et,en){"use strict";/*! * The buffer module from node.js, for the browser. * * @author Feross Aboukhadijeh * @license MIT */var ei=en(79742),eo=en(80645),ea=en(87300);function typedArraySupport(){try{var ee=new Uint8Array(1);return ee.__proto__={__proto__:Uint8Array.prototype,foo:function(){return 42}},42===ee.foo()&&"function"==typeof ee.subarray&&0===ee.subarray(1,1).byteLength}catch(ee){return!1}}function kMaxLength(){return Buffer.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function createBuffer(ee,et){if(kMaxLength()=kMaxLength())throw RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+kMaxLength().toString(16)+" bytes");return 0|ee}function SlowBuffer(ee){return+ee!=ee&&(ee=0),Buffer.alloc(+ee)}function byteLength(ee,et){if(Buffer.isBuffer(ee))return ee.length;if("undefined"!=typeof ArrayBuffer&&"function"==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(ee)||ee instanceof ArrayBuffer))return ee.byteLength;"string"!=typeof ee&&(ee=""+ee);var en=ee.length;if(0===en)return 0;for(var ei=!1;;)switch(et){case"ascii":case"latin1":case"binary":return en;case"utf8":case"utf-8":case void 0:return utf8ToBytes(ee).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*en;case"hex":return en>>>1;case"base64":return base64ToBytes(ee).length;default:if(ei)return utf8ToBytes(ee).length;et=(""+et).toLowerCase(),ei=!0}}function slowToString(ee,et,en){var ei=!1;if((void 0===et||et<0)&&(et=0),et>this.length||((void 0===en||en>this.length)&&(en=this.length),en<=0||(en>>>=0)<=(et>>>=0)))return"";for(ee||(ee="utf8");;)switch(ee){case"hex":return hexSlice(this,et,en);case"utf8":case"utf-8":return utf8Slice(this,et,en);case"ascii":return asciiSlice(this,et,en);case"latin1":case"binary":return latin1Slice(this,et,en);case"base64":return base64Slice(this,et,en);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return utf16leSlice(this,et,en);default:if(ei)throw TypeError("Unknown encoding: "+ee);ee=(ee+"").toLowerCase(),ei=!0}}function swap(ee,et,en){var ei=ee[et];ee[et]=ee[en],ee[en]=ei}function bidirectionalIndexOf(ee,et,en,ei,eo){if(0===ee.length)return -1;if("string"==typeof en?(ei=en,en=0):en>2147483647?en=2147483647:en<-2147483648&&(en=-2147483648),isNaN(en=+en)&&(en=eo?0:ee.length-1),en<0&&(en=ee.length+en),en>=ee.length){if(eo)return -1;en=ee.length-1}else if(en<0){if(!eo)return -1;en=0}if("string"==typeof et&&(et=Buffer.from(et,ei)),Buffer.isBuffer(et))return 0===et.length?-1:arrayIndexOf(ee,et,en,ei,eo);if("number"==typeof et)return(et&=255,Buffer.TYPED_ARRAY_SUPPORT&&"function"==typeof Uint8Array.prototype.indexOf)?eo?Uint8Array.prototype.indexOf.call(ee,et,en):Uint8Array.prototype.lastIndexOf.call(ee,et,en):arrayIndexOf(ee,[et],en,ei,eo);throw TypeError("val must be string, number or Buffer")}function arrayIndexOf(ee,et,en,ei,eo){var ea,es=1,eu=ee.length,ec=et.length;if(void 0!==ei&&("ucs2"===(ei=String(ei).toLowerCase())||"ucs-2"===ei||"utf16le"===ei||"utf-16le"===ei)){if(ee.length<2||et.length<2)return -1;es=2,eu/=2,ec/=2,en/=2}function read(ee,et){return 1===es?ee[et]:ee.readUInt16BE(et*es)}if(eo){var ed=-1;for(ea=en;eaeu&&(en=eu-ec),ea=en;ea>=0;ea--){for(var ef=!0,ep=0;epeo&&(ei=eo):ei=eo;var ea=et.length;if(ea%2!=0)throw TypeError("Invalid hex string");ei>ea/2&&(ei=ea/2);for(var es=0;es239?4:ed>223?3:ed>191?2:1;if(eo+ep<=en)switch(ep){case 1:ed<128&&(ef=ed);break;case 2:(192&(ea=ee[eo+1]))==128&&(ec=(31&ed)<<6|63&ea)>127&&(ef=ec);break;case 3:ea=ee[eo+1],es=ee[eo+2],(192&ea)==128&&(192&es)==128&&(ec=(15&ed)<<12|(63&ea)<<6|63&es)>2047&&(ec<55296||ec>57343)&&(ef=ec);break;case 4:ea=ee[eo+1],es=ee[eo+2],eu=ee[eo+3],(192&ea)==128&&(192&es)==128&&(192&eu)==128&&(ec=(15&ed)<<18|(63&ea)<<12|(63&es)<<6|63&eu)>65535&&ec<1114112&&(ef=ec)}null===ef?(ef=65533,ep=1):ef>65535&&(ef-=65536,ei.push(ef>>>10&1023|55296),ef=56320|1023&ef),ei.push(ef),eo+=ep}return decodeCodePointsArray(ei)}et.Buffer=Buffer,et.SlowBuffer=SlowBuffer,et.INSPECT_MAX_BYTES=50,Buffer.TYPED_ARRAY_SUPPORT=void 0!==en.g.TYPED_ARRAY_SUPPORT?en.g.TYPED_ARRAY_SUPPORT:typedArraySupport(),et.kMaxLength=kMaxLength(),Buffer.poolSize=8192,Buffer._augment=function(ee){return ee.__proto__=Buffer.prototype,ee},Buffer.from=function(ee,et,en){return from(null,ee,et,en)},Buffer.TYPED_ARRAY_SUPPORT&&(Buffer.prototype.__proto__=Uint8Array.prototype,Buffer.__proto__=Uint8Array,"undefined"!=typeof Symbol&&Symbol.species&&Buffer[Symbol.species]===Buffer&&Object.defineProperty(Buffer,Symbol.species,{value:null,configurable:!0})),Buffer.alloc=function(ee,et,en){return alloc(null,ee,et,en)},Buffer.allocUnsafe=function(ee){return allocUnsafe(null,ee)},Buffer.allocUnsafeSlow=function(ee){return allocUnsafe(null,ee)},Buffer.isBuffer=function(ee){return!!(null!=ee&&ee._isBuffer)},Buffer.compare=function(ee,et){if(!Buffer.isBuffer(ee)||!Buffer.isBuffer(et))throw TypeError("Arguments must be Buffers");if(ee===et)return 0;for(var en=ee.length,ei=et.length,eo=0,ea=Math.min(en,ei);eo0&&(ee=this.toString("hex",0,en).match(/.{2}/g).join(" "),this.length>en&&(ee+=" ... ")),""},Buffer.prototype.compare=function(ee,et,en,ei,eo){if(!Buffer.isBuffer(ee))throw TypeError("Argument must be a Buffer");if(void 0===et&&(et=0),void 0===en&&(en=ee?ee.length:0),void 0===ei&&(ei=0),void 0===eo&&(eo=this.length),et<0||en>ee.length||ei<0||eo>this.length)throw RangeError("out of range index");if(ei>=eo&&et>=en)return 0;if(ei>=eo)return -1;if(et>=en)return 1;if(et>>>=0,en>>>=0,ei>>>=0,eo>>>=0,this===ee)return 0;for(var ea=eo-ei,es=en-et,eu=Math.min(ea,es),ec=this.slice(ei,eo),ed=ee.slice(et,en),ef=0;efeo)&&(en=eo),ee.length>0&&(en<0||et<0)||et>this.length)throw RangeError("Attempt to write outside buffer bounds");ei||(ei="utf8");for(var ea=!1;;)switch(ei){case"hex":return hexWrite(this,ee,et,en);case"utf8":case"utf-8":return utf8Write(this,ee,et,en);case"ascii":return asciiWrite(this,ee,et,en);case"latin1":case"binary":return latin1Write(this,ee,et,en);case"base64":return base64Write(this,ee,et,en);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return ucs2Write(this,ee,et,en);default:if(ea)throw TypeError("Unknown encoding: "+ei);ei=(""+ei).toLowerCase(),ea=!0}},Buffer.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var es=4096;function decodeCodePointsArray(ee){var et=ee.length;if(et<=es)return String.fromCharCode.apply(String,ee);for(var en="",ei=0;eiei)&&(en=ei);for(var eo="",ea=et;eaen)throw RangeError("Trying to access beyond buffer length")}function checkInt(ee,et,en,ei,eo,ea){if(!Buffer.isBuffer(ee))throw TypeError('"buffer" argument must be a Buffer instance');if(et>eo||etee.length)throw RangeError("Index out of range")}function objectWriteUInt16(ee,et,en,ei){et<0&&(et=65535+et+1);for(var eo=0,ea=Math.min(ee.length-en,2);eo>>(ei?eo:1-eo)*8}function objectWriteUInt32(ee,et,en,ei){et<0&&(et=4294967295+et+1);for(var eo=0,ea=Math.min(ee.length-en,4);eo>>(ei?eo:3-eo)*8&255}function checkIEEE754(ee,et,en,ei,eo,ea){if(en+ei>ee.length||en<0)throw RangeError("Index out of range")}function writeFloat(ee,et,en,ei,ea){return ea||checkIEEE754(ee,et,en,4,34028234663852886e22,-34028234663852886e22),eo.write(ee,et,en,ei,23,4),en+4}function writeDouble(ee,et,en,ei,ea){return ea||checkIEEE754(ee,et,en,8,17976931348623157e292,-17976931348623157e292),eo.write(ee,et,en,ei,52,8),en+8}Buffer.prototype.slice=function(ee,et){var en,ei=this.length;if(ee=~~ee,et=void 0===et?ei:~~et,ee<0?(ee+=ei)<0&&(ee=0):ee>ei&&(ee=ei),et<0?(et+=ei)<0&&(et=0):et>ei&&(et=ei),et0&&(eo*=256);)ei+=this[ee+--et]*eo;return ei},Buffer.prototype.readUInt8=function(ee,et){return et||checkOffset(ee,1,this.length),this[ee]},Buffer.prototype.readUInt16LE=function(ee,et){return et||checkOffset(ee,2,this.length),this[ee]|this[ee+1]<<8},Buffer.prototype.readUInt16BE=function(ee,et){return et||checkOffset(ee,2,this.length),this[ee]<<8|this[ee+1]},Buffer.prototype.readUInt32LE=function(ee,et){return et||checkOffset(ee,4,this.length),(this[ee]|this[ee+1]<<8|this[ee+2]<<16)+16777216*this[ee+3]},Buffer.prototype.readUInt32BE=function(ee,et){return et||checkOffset(ee,4,this.length),16777216*this[ee]+(this[ee+1]<<16|this[ee+2]<<8|this[ee+3])},Buffer.prototype.readIntLE=function(ee,et,en){ee|=0,et|=0,en||checkOffset(ee,et,this.length);for(var ei=this[ee],eo=1,ea=0;++ea=(eo*=128)&&(ei-=Math.pow(2,8*et)),ei},Buffer.prototype.readIntBE=function(ee,et,en){ee|=0,et|=0,en||checkOffset(ee,et,this.length);for(var ei=et,eo=1,ea=this[ee+--ei];ei>0&&(eo*=256);)ea+=this[ee+--ei]*eo;return ea>=(eo*=128)&&(ea-=Math.pow(2,8*et)),ea},Buffer.prototype.readInt8=function(ee,et){return(et||checkOffset(ee,1,this.length),128&this[ee])?-((255-this[ee]+1)*1):this[ee]},Buffer.prototype.readInt16LE=function(ee,et){et||checkOffset(ee,2,this.length);var en=this[ee]|this[ee+1]<<8;return 32768&en?4294901760|en:en},Buffer.prototype.readInt16BE=function(ee,et){et||checkOffset(ee,2,this.length);var en=this[ee+1]|this[ee]<<8;return 32768&en?4294901760|en:en},Buffer.prototype.readInt32LE=function(ee,et){return et||checkOffset(ee,4,this.length),this[ee]|this[ee+1]<<8|this[ee+2]<<16|this[ee+3]<<24},Buffer.prototype.readInt32BE=function(ee,et){return et||checkOffset(ee,4,this.length),this[ee]<<24|this[ee+1]<<16|this[ee+2]<<8|this[ee+3]},Buffer.prototype.readFloatLE=function(ee,et){return et||checkOffset(ee,4,this.length),eo.read(this,ee,!0,23,4)},Buffer.prototype.readFloatBE=function(ee,et){return et||checkOffset(ee,4,this.length),eo.read(this,ee,!1,23,4)},Buffer.prototype.readDoubleLE=function(ee,et){return et||checkOffset(ee,8,this.length),eo.read(this,ee,!0,52,8)},Buffer.prototype.readDoubleBE=function(ee,et){return et||checkOffset(ee,8,this.length),eo.read(this,ee,!1,52,8)},Buffer.prototype.writeUIntLE=function(ee,et,en,ei){if(ee=+ee,et|=0,en|=0,!ei){var eo=Math.pow(2,8*en)-1;checkInt(this,ee,et,en,eo,0)}var ea=1,es=0;for(this[et]=255ⅇ++es=0&&(es*=256);)this[et+ea]=ee/es&255;return et+en},Buffer.prototype.writeUInt8=function(ee,et,en){return ee=+ee,et|=0,en||checkInt(this,ee,et,1,255,0),Buffer.TYPED_ARRAY_SUPPORT||(ee=Math.floor(ee)),this[et]=255&ee,et+1},Buffer.prototype.writeUInt16LE=function(ee,et,en){return ee=+ee,et|=0,en||checkInt(this,ee,et,2,65535,0),Buffer.TYPED_ARRAY_SUPPORT?(this[et]=255&ee,this[et+1]=ee>>>8):objectWriteUInt16(this,ee,et,!0),et+2},Buffer.prototype.writeUInt16BE=function(ee,et,en){return ee=+ee,et|=0,en||checkInt(this,ee,et,2,65535,0),Buffer.TYPED_ARRAY_SUPPORT?(this[et]=ee>>>8,this[et+1]=255&ee):objectWriteUInt16(this,ee,et,!1),et+2},Buffer.prototype.writeUInt32LE=function(ee,et,en){return ee=+ee,et|=0,en||checkInt(this,ee,et,4,4294967295,0),Buffer.TYPED_ARRAY_SUPPORT?(this[et+3]=ee>>>24,this[et+2]=ee>>>16,this[et+1]=ee>>>8,this[et]=255&ee):objectWriteUInt32(this,ee,et,!0),et+4},Buffer.prototype.writeUInt32BE=function(ee,et,en){return ee=+ee,et|=0,en||checkInt(this,ee,et,4,4294967295,0),Buffer.TYPED_ARRAY_SUPPORT?(this[et]=ee>>>24,this[et+1]=ee>>>16,this[et+2]=ee>>>8,this[et+3]=255&ee):objectWriteUInt32(this,ee,et,!1),et+4},Buffer.prototype.writeIntLE=function(ee,et,en,ei){if(ee=+ee,et|=0,!ei){var eo=Math.pow(2,8*en-1);checkInt(this,ee,et,en,eo-1,-eo)}var ea=0,es=1,eu=0;for(this[et]=255ⅇ++ea>0)-eu&255;return et+en},Buffer.prototype.writeIntBE=function(ee,et,en,ei){if(ee=+ee,et|=0,!ei){var eo=Math.pow(2,8*en-1);checkInt(this,ee,et,en,eo-1,-eo)}var ea=en-1,es=1,eu=0;for(this[et+ea]=255ⅇ--ea>=0&&(es*=256);)ee<0&&0===eu&&0!==this[et+ea+1]&&(eu=1),this[et+ea]=(ee/es>>0)-eu&255;return et+en},Buffer.prototype.writeInt8=function(ee,et,en){return ee=+ee,et|=0,en||checkInt(this,ee,et,1,127,-128),Buffer.TYPED_ARRAY_SUPPORT||(ee=Math.floor(ee)),ee<0&&(ee=255+ee+1),this[et]=255&ee,et+1},Buffer.prototype.writeInt16LE=function(ee,et,en){return ee=+ee,et|=0,en||checkInt(this,ee,et,2,32767,-32768),Buffer.TYPED_ARRAY_SUPPORT?(this[et]=255&ee,this[et+1]=ee>>>8):objectWriteUInt16(this,ee,et,!0),et+2},Buffer.prototype.writeInt16BE=function(ee,et,en){return ee=+ee,et|=0,en||checkInt(this,ee,et,2,32767,-32768),Buffer.TYPED_ARRAY_SUPPORT?(this[et]=ee>>>8,this[et+1]=255&ee):objectWriteUInt16(this,ee,et,!1),et+2},Buffer.prototype.writeInt32LE=function(ee,et,en){return ee=+ee,et|=0,en||checkInt(this,ee,et,4,2147483647,-2147483648),Buffer.TYPED_ARRAY_SUPPORT?(this[et]=255&ee,this[et+1]=ee>>>8,this[et+2]=ee>>>16,this[et+3]=ee>>>24):objectWriteUInt32(this,ee,et,!0),et+4},Buffer.prototype.writeInt32BE=function(ee,et,en){return ee=+ee,et|=0,en||checkInt(this,ee,et,4,2147483647,-2147483648),ee<0&&(ee=4294967295+ee+1),Buffer.TYPED_ARRAY_SUPPORT?(this[et]=ee>>>24,this[et+1]=ee>>>16,this[et+2]=ee>>>8,this[et+3]=255&ee):objectWriteUInt32(this,ee,et,!1),et+4},Buffer.prototype.writeFloatLE=function(ee,et,en){return writeFloat(this,ee,et,!0,en)},Buffer.prototype.writeFloatBE=function(ee,et,en){return writeFloat(this,ee,et,!1,en)},Buffer.prototype.writeDoubleLE=function(ee,et,en){return writeDouble(this,ee,et,!0,en)},Buffer.prototype.writeDoubleBE=function(ee,et,en){return writeDouble(this,ee,et,!1,en)},Buffer.prototype.copy=function(ee,et,en,ei){if(en||(en=0),ei||0===ei||(ei=this.length),et>=ee.length&&(et=ee.length),et||(et=0),ei>0&&ei=this.length)throw RangeError("sourceStart out of bounds");if(ei<0)throw RangeError("sourceEnd out of bounds");ei>this.length&&(ei=this.length),ee.length-et=0;--eo)ee[eo+et]=this[eo+en];else if(ea<1e3||!Buffer.TYPED_ARRAY_SUPPORT)for(eo=0;eo>>=0,en=void 0===en?this.length:en>>>0,ee||(ee=0),"number"==typeof ee)for(eo=et;eo55295&&en<57344){if(!eo){if(en>56319||es+1===ei){(et-=3)>-1&&ea.push(239,191,189);continue}eo=en;continue}if(en<56320){(et-=3)>-1&&ea.push(239,191,189),eo=en;continue}en=(eo-55296<<10|en-56320)+65536}else eo&&(et-=3)>-1&&ea.push(239,191,189);if(eo=null,en<128){if((et-=1)<0)break;ea.push(en)}else if(en<2048){if((et-=2)<0)break;ea.push(en>>6|192,63&en|128)}else if(en<65536){if((et-=3)<0)break;ea.push(en>>12|224,en>>6&63|128,63&en|128)}else if(en<1114112){if((et-=4)<0)break;ea.push(en>>18|240,en>>12&63|128,en>>6&63|128,63&en|128)}else throw Error("Invalid code point")}return ea}function asciiToBytes(ee){for(var et=[],en=0;en>8,eo.push(en%256),eo.push(ei);return eo}function base64ToBytes(ee){return ei.toByteArray(base64clean(ee))}function blitBuffer(ee,et,en,ei){for(var eo=0;eo=et.length)&&!(eo>=ee.length);++eo)et[eo+en]=ee[eo];return eo}function isnan(ee){return ee!=ee}},87300:function(ee){var et={}.toString;ee.exports=Array.isArray||function(ee){return"[object Array]"==et.call(ee)}},76489:function(ee,et){"use strict";/*! * cookie * Copyright(c) 2012-2014 Roman Shtylman * Copyright(c) 2015 Douglas Christopher Wilson * MIT Licensed */et.parse=parse,et.serialize=serialize;var en=Object.prototype.toString,ei=/^[\u0009\u0020-\u007e\u0080-\u00ff]+$/;function parse(ee,et){if("string"!=typeof ee)throw TypeError("argument str must be a string");for(var en={},ei=(et||{}).decode||decode,eo=0;eo1?en-1:0),eo=1;eo2&&void 0!==arguments[2]?arguments[2]:ey;et&&et(ee,null);let ea=ei.length;for(;ea--;){let et=ei[ea];if("string"==typeof et){let ee=eo(et);ee!==et&&(en(ei)||(ei[ea]=ee),et=ee)}ee[et]=!0}return ee}function cleanArray(ee){for(let et=0;et/gm),eD=es(/\${[\w\W]*}/gm),eB=es(/^data-[\-\w.\u00B7-\uFFFF]/),eU=es(/^aria-[\-\w]+$/),eL=es(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),eF=es(/^(?:\w+script|data):/i),eW=es(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),eH=es(/^html$/i),eq=es(/^[a-z][.\w]*(-[.\w]+)+$/i);var eV=Object.freeze({__proto__:null,MUSTACHE_EXPR:eM,ERB_EXPR:ej,TMPLIT_EXPR:eD,DATA_ATTR:eB,ARIA_ATTR:eU,IS_ALLOWED_URI:eL,IS_SCRIPT_OR_DATA:eF,ATTR_WHITESPACE:eW,DOCTYPE_NAME:eH,CUSTOM_ELEMENT:eq});let eK={element:1,text:3,progressingInstruction:7,comment:8,document:9},getGlobal=function(){return"undefined"==typeof window?null:window},_createTrustedTypesPolicy=function(ee,et){if("object"!=typeof ee||"function"!=typeof ee.createPolicy)return null;let en=null,ei="data-tt-policy-suffix";et&&et.hasAttribute(ei)&&(en=et.getAttribute(ei));let eo="dompurify"+(en?"#"+en:"");try{return ee.createPolicy(eo,{createHTML:ee=>ee,createScriptURL:ee=>ee})}catch(ee){return console.warn("TrustedTypes policy "+eo+" could not be created."),null}};function createDOMPurify(){let et,en=arguments.length>0&&void 0!==arguments[0]?arguments[0]:getGlobal(),DOMPurify=ee=>createDOMPurify(ee);if(DOMPurify.version="3.1.6",DOMPurify.removed=[],!en||!en.document||en.document.nodeType!==eK.document)return DOMPurify.isSupported=!1,DOMPurify;let{document:ei}=en,eo=ei,es=eo.currentScript,{DocumentFragment:ec,HTMLTemplateElement:ed,Node:eM,Element:ej,NodeFilter:eD,NamedNodeMap:eB=en.NamedNodeMap||en.MozNamedAttrMap,HTMLFormElement:eU,DOMParser:eF,trustedTypes:eW}=en,eq=ej.prototype,ez=lookupGetter(eq,"cloneNode"),eJ=lookupGetter(eq,"remove"),eG=lookupGetter(eq,"nextSibling"),eY=lookupGetter(eq,"childNodes"),eZ=lookupGetter(eq,"parentNode");if("function"==typeof ed){let ee=ei.createElement("template");ee.content&&ee.content.ownerDocument&&(ei=ee.content.ownerDocument)}let eX="",{implementation:eQ,createNodeIterator:e0,createDocumentFragment:e1,getElementsByTagName:e2}=ei,{importNode:e3}=eo,e4={};DOMPurify.isSupported="function"==typeof ee&&"function"==typeof eZ&&eQ&&void 0!==eQ.createHTMLDocument;let{MUSTACHE_EXPR:e8,ERB_EXPR:e6,TMPLIT_EXPR:e5,DATA_ATTR:e9,ARIA_ATTR:e7,IS_SCRIPT_OR_DATA:te,ATTR_WHITESPACE:tt,CUSTOM_ELEMENT:tr}=eV,{IS_ALLOWED_URI:tn}=eV,ti=null,ta=addToSet({},[...eA,...e$,...ex,...ek,...eT]),ts=null,tu=addToSet({},[...eP,...eR,...eI,...eN]),tl=Object.seal(eu(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),tc=null,td=null,tf=!0,tp=!0,th=!1,ty=!0,tm=!1,tg=!0,tb=!1,tv=!1,t_=!1,tw=!1,tS=!1,tE=!1,tA=!0,t$=!1,tx="user-content-",tC=!0,tk=!1,tO={},tT=null,tP=addToSet({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]),tR=null,tI=addToSet({},["audio","video","img","source","image","track"]),tN=null,tM=addToSet({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),tj="http://www.w3.org/1998/Math/MathML",tD="http://www.w3.org/2000/svg",tB="http://www.w3.org/1999/xhtml",tU=tB,tL=!1,tF=null,tW=addToSet({},[tj,tD,tB],em),tH=null,tq=["application/xhtml+xml","text/html"],tV="text/html",tK=null,tz=null,tJ=ei.createElement("form"),isRegexOrFunction=function(ee){return ee instanceof RegExp||ee instanceof Function},_parseConfig=function(){let ee=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(!tz||tz!==ee){if(ee&&"object"==typeof ee||(ee={}),ee=clone(ee),tK="application/xhtml+xml"===(tH=-1===tq.indexOf(ee.PARSER_MEDIA_TYPE)?tV:ee.PARSER_MEDIA_TYPE)?em:ey,ti=ew(ee,"ALLOWED_TAGS")?addToSet({},ee.ALLOWED_TAGS,tK):ta,ts=ew(ee,"ALLOWED_ATTR")?addToSet({},ee.ALLOWED_ATTR,tK):tu,tF=ew(ee,"ALLOWED_NAMESPACES")?addToSet({},ee.ALLOWED_NAMESPACES,em):tW,tN=ew(ee,"ADD_URI_SAFE_ATTR")?addToSet(clone(tM),ee.ADD_URI_SAFE_ATTR,tK):tM,tR=ew(ee,"ADD_DATA_URI_TAGS")?addToSet(clone(tI),ee.ADD_DATA_URI_TAGS,tK):tI,tT=ew(ee,"FORBID_CONTENTS")?addToSet({},ee.FORBID_CONTENTS,tK):tP,tc=ew(ee,"FORBID_TAGS")?addToSet({},ee.FORBID_TAGS,tK):{},td=ew(ee,"FORBID_ATTR")?addToSet({},ee.FORBID_ATTR,tK):{},tO=!!ew(ee,"USE_PROFILES")&&ee.USE_PROFILES,tf=!1!==ee.ALLOW_ARIA_ATTR,tp=!1!==ee.ALLOW_DATA_ATTR,th=ee.ALLOW_UNKNOWN_PROTOCOLS||!1,ty=!1!==ee.ALLOW_SELF_CLOSE_IN_ATTR,tm=ee.SAFE_FOR_TEMPLATES||!1,tg=!1!==ee.SAFE_FOR_XML,tb=ee.WHOLE_DOCUMENT||!1,tw=ee.RETURN_DOM||!1,tS=ee.RETURN_DOM_FRAGMENT||!1,tE=ee.RETURN_TRUSTED_TYPE||!1,t_=ee.FORCE_BODY||!1,tA=!1!==ee.SANITIZE_DOM,t$=ee.SANITIZE_NAMED_PROPS||!1,tC=!1!==ee.KEEP_CONTENT,tk=ee.IN_PLACE||!1,tn=ee.ALLOWED_URI_REGEXP||eL,tU=ee.NAMESPACE||tB,tl=ee.CUSTOM_ELEMENT_HANDLING||{},ee.CUSTOM_ELEMENT_HANDLING&&isRegexOrFunction(ee.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(tl.tagNameCheck=ee.CUSTOM_ELEMENT_HANDLING.tagNameCheck),ee.CUSTOM_ELEMENT_HANDLING&&isRegexOrFunction(ee.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(tl.attributeNameCheck=ee.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),ee.CUSTOM_ELEMENT_HANDLING&&"boolean"==typeof ee.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements&&(tl.allowCustomizedBuiltInElements=ee.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),tm&&(tp=!1),tS&&(tw=!0),tO&&(ti=addToSet({},eT),ts=[],!0===tO.html&&(addToSet(ti,eA),addToSet(ts,eP)),!0===tO.svg&&(addToSet(ti,e$),addToSet(ts,eR),addToSet(ts,eN)),!0===tO.svgFilters&&(addToSet(ti,ex),addToSet(ts,eR),addToSet(ts,eN)),!0===tO.mathMl&&(addToSet(ti,ek),addToSet(ts,eI),addToSet(ts,eN))),ee.ADD_TAGS&&(ti===ta&&(ti=clone(ti)),addToSet(ti,ee.ADD_TAGS,tK)),ee.ADD_ATTR&&(ts===tu&&(ts=clone(ts)),addToSet(ts,ee.ADD_ATTR,tK)),ee.ADD_URI_SAFE_ATTR&&addToSet(tN,ee.ADD_URI_SAFE_ATTR,tK),ee.FORBID_CONTENTS&&(tT===tP&&(tT=clone(tT)),addToSet(tT,ee.FORBID_CONTENTS,tK)),tC&&(ti["#text"]=!0),tb&&addToSet(ti,["html","head","body"]),ti.table&&(addToSet(ti,["tbody"]),delete tc.tbody),ee.TRUSTED_TYPES_POLICY){if("function"!=typeof ee.TRUSTED_TYPES_POLICY.createHTML)throw eE('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if("function"!=typeof ee.TRUSTED_TYPES_POLICY.createScriptURL)throw eE('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');eX=(et=ee.TRUSTED_TYPES_POLICY).createHTML("")}else void 0===et&&(et=_createTrustedTypesPolicy(eW,es)),null!==et&&"string"==typeof eX&&(eX=et.createHTML(""));ea&&ea(ee),tz=ee}},tG=addToSet({},["mi","mo","mn","ms","mtext"]),tY=addToSet({},["foreignobject","annotation-xml"]),tZ=addToSet({},["title","style","font","a","script"]),tX=addToSet({},[...e$,...ex,...eC]),tQ=addToSet({},[...ek,...eO]),_checkValidNamespace=function(ee){let et=eZ(ee);et&&et.tagName||(et={namespaceURI:tU,tagName:"template"});let en=ey(ee.tagName),ei=ey(et.tagName);return!!tF[ee.namespaceURI]&&(ee.namespaceURI===tD?et.namespaceURI===tB?"svg"===en:et.namespaceURI===tj?"svg"===en&&("annotation-xml"===ei||tG[ei]):!!tX[en]:ee.namespaceURI===tj?et.namespaceURI===tB?"math"===en:et.namespaceURI===tD?"math"===en&&tY[ei]:!!tQ[en]:ee.namespaceURI===tB?(et.namespaceURI!==tD||!!tY[ei])&&(et.namespaceURI!==tj||!!tG[ei])&&!tQ[en]&&(tZ[en]||!tX[en]):"application/xhtml+xml"===tH&&!!tF[ee.namespaceURI])},_forceRemove=function(ee){eh(DOMPurify.removed,{element:ee});try{eZ(ee).removeChild(ee)}catch(et){eJ(ee)}},_removeAttribute=function(ee,et){try{eh(DOMPurify.removed,{attribute:et.getAttributeNode(ee),from:et})}catch(ee){eh(DOMPurify.removed,{attribute:null,from:et})}if(et.removeAttribute(ee),"is"===ee&&!ts[ee]){if(tw||tS)try{_forceRemove(et)}catch(ee){}else try{et.setAttribute(ee,"")}catch(ee){}}},_initDocument=function(ee){let en=null,eo=null;if(t_)ee=""+ee;else{let et=eg(ee,/^[\r\n\t ]+/);eo=et&&et[0]}"application/xhtml+xml"===tH&&tU===tB&&(ee=''+ee+"");let ea=et?et.createHTML(ee):ee;if(tU===tB)try{en=new eF().parseFromString(ea,tH)}catch(ee){}if(!en||!en.documentElement){en=eQ.createDocument(tU,"template",null);try{en.documentElement.innerHTML=tL?eX:ea}catch(ee){}}let es=en.body||en.documentElement;return(ee&&eo&&es.insertBefore(ei.createTextNode(eo),es.childNodes[0]||null),tU===tB)?e2.call(en,tb?"html":"body")[0]:tb?en.documentElement:es},_createNodeIterator=function(ee){return e0.call(ee.ownerDocument||ee,ee,eD.SHOW_ELEMENT|eD.SHOW_COMMENT|eD.SHOW_TEXT|eD.SHOW_PROCESSING_INSTRUCTION|eD.SHOW_CDATA_SECTION,null)},_isClobbered=function(ee){return ee instanceof eU&&("string"!=typeof ee.nodeName||"string"!=typeof ee.textContent||"function"!=typeof ee.removeChild||!(ee.attributes instanceof eB)||"function"!=typeof ee.removeAttribute||"function"!=typeof ee.setAttribute||"string"!=typeof ee.namespaceURI||"function"!=typeof ee.insertBefore||"function"!=typeof ee.hasChildNodes)},_isNode=function(ee){return"function"==typeof eM&&ee instanceof eM},_executeHook=function(ee,et,en){e4[ee]&&ef(e4[ee],ee=>{ee.call(DOMPurify,et,en,tz)})},_sanitizeElements=function(ee){let et=null;if(_executeHook("beforeSanitizeElements",ee,null),_isClobbered(ee))return _forceRemove(ee),!0;let en=tK(ee.nodeName);if(_executeHook("uponSanitizeElement",ee,{tagName:en,allowedTags:ti}),ee.hasChildNodes()&&!_isNode(ee.firstElementChild)&&eS(/<[/\w]/g,ee.innerHTML)&&eS(/<[/\w]/g,ee.textContent)||ee.nodeType===eK.progressingInstruction||tg&&ee.nodeType===eK.comment&&eS(/<[/\w]/g,ee.data))return _forceRemove(ee),!0;if(!ti[en]||tc[en]){if(!tc[en]&&_isBasicCustomElement(en)&&(tl.tagNameCheck instanceof RegExp&&eS(tl.tagNameCheck,en)||tl.tagNameCheck instanceof Function&&tl.tagNameCheck(en)))return!1;if(tC&&!tT[en]){let et=eZ(ee)||ee.parentNode,en=eY(ee)||ee.childNodes;if(en&&et){let ei=en.length;for(let eo=ei-1;eo>=0;--eo){let ei=ez(en[eo],!0);ei.__removalCount=(ee.__removalCount||0)+1,et.insertBefore(ei,eG(ee))}}}return _forceRemove(ee),!0}return ee instanceof ej&&!_checkValidNamespace(ee)||("noscript"===en||"noembed"===en||"noframes"===en)&&eS(/<\/no(script|embed|frames)/i,ee.innerHTML)?(_forceRemove(ee),!0):(tm&&ee.nodeType===eK.text&&(et=ee.textContent,ef([e8,e6,e5],ee=>{et=eb(et,ee," ")}),ee.textContent!==et&&(eh(DOMPurify.removed,{element:ee.cloneNode()}),ee.textContent=et)),_executeHook("afterSanitizeElements",ee,null),!1)},_isValidAttribute=function(ee,et,en){if(tA&&("id"===et||"name"===et)&&(en in ei||en in tJ))return!1;if(tp&&!td[et]&&eS(e9,et));else if(tf&&eS(e7,et));else if(!ts[et]||td[et]){if(!(_isBasicCustomElement(ee)&&(tl.tagNameCheck instanceof RegExp&&eS(tl.tagNameCheck,ee)||tl.tagNameCheck instanceof Function&&tl.tagNameCheck(ee))&&(tl.attributeNameCheck instanceof RegExp&&eS(tl.attributeNameCheck,et)||tl.attributeNameCheck instanceof Function&&tl.attributeNameCheck(et))||"is"===et&&tl.allowCustomizedBuiltInElements&&(tl.tagNameCheck instanceof RegExp&&eS(tl.tagNameCheck,en)||tl.tagNameCheck instanceof Function&&tl.tagNameCheck(en))))return!1}else if(tN[et]);else if(eS(tn,eb(en,tt,"")));else if(("src"===et||"xlink:href"===et||"href"===et)&&"script"!==ee&&0===ev(en,"data:")&&tR[ee]);else if(th&&!eS(te,eb(en,tt,"")));else if(en)return!1;return!0},_isBasicCustomElement=function(ee){return"annotation-xml"!==ee&&eg(ee,tr)},_sanitizeAttributes=function(ee){_executeHook("beforeSanitizeAttributes",ee,null);let{attributes:en}=ee;if(!en)return;let ei={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:ts},eo=en.length;for(;eo--;){let ea=en[eo],{name:es,namespaceURI:eu,value:ec}=ea,ed=tK(es),eh="value"===es?ec:e_(ec);if(ei.attrName=ed,ei.attrValue=eh,ei.keepAttr=!0,ei.forceKeepAttr=void 0,_executeHook("uponSanitizeAttribute",ee,ei),eh=ei.attrValue,tg&&eS(/((--!?|])>)|<\/(style|title)/i,eh)){_removeAttribute(es,ee);continue}if(ei.forceKeepAttr||(_removeAttribute(es,ee),!ei.keepAttr))continue;if(!ty&&eS(/\/>/i,eh)){_removeAttribute(es,ee);continue}tm&&ef([e8,e6,e5],ee=>{eh=eb(eh,ee," ")});let ey=tK(ee.nodeName);if(_isValidAttribute(ey,ed,eh)){if(t$&&("id"===ed||"name"===ed)&&(_removeAttribute(es,ee),eh=tx+eh),et&&"object"==typeof eW&&"function"==typeof eW.getAttributeType){if(eu);else switch(eW.getAttributeType(ey,ed)){case"TrustedHTML":eh=et.createHTML(eh);break;case"TrustedScriptURL":eh=et.createScriptURL(eh)}}try{eu?ee.setAttributeNS(eu,es,eh):ee.setAttribute(es,eh),_isClobbered(ee)?_forceRemove(ee):ep(DOMPurify.removed)}catch(ee){}}}_executeHook("afterSanitizeAttributes",ee,null)},_sanitizeShadowDOM=function _sanitizeShadowDOM(ee){let et=null,en=_createNodeIterator(ee);for(_executeHook("beforeSanitizeShadowDOM",ee,null);et=en.nextNode();)_executeHook("uponSanitizeShadowNode",et,null),_sanitizeElements(et)||(et.content instanceof ec&&_sanitizeShadowDOM(et.content),_sanitizeAttributes(et));_executeHook("afterSanitizeShadowDOM",ee,null)};return DOMPurify.sanitize=function(ee){let en=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},ei=null,ea=null,es=null,eu=null;if((tL=!ee)&&(ee=""),"string"!=typeof ee&&!_isNode(ee)){if("function"==typeof ee.toString){if("string"!=typeof(ee=ee.toString()))throw eE("dirty is not a string, aborting")}else throw eE("toString is not a function")}if(!DOMPurify.isSupported)return ee;if(tv||_parseConfig(en),DOMPurify.removed=[],"string"==typeof ee&&(tk=!1),tk){if(ee.nodeName){let et=tK(ee.nodeName);if(!ti[et]||tc[et])throw eE("root node is forbidden and cannot be sanitized in-place")}}else if(ee instanceof eM)(ea=(ei=_initDocument("")).ownerDocument.importNode(ee,!0)).nodeType===eK.element&&"BODY"===ea.nodeName?ei=ea:"HTML"===ea.nodeName?ei=ea:ei.appendChild(ea);else{if(!tw&&!tm&&!tb&&-1===ee.indexOf("<"))return et&&tE?et.createHTML(ee):ee;if(!(ei=_initDocument(ee)))return tw?null:tE?eX:""}ei&&t_&&_forceRemove(ei.firstChild);let ed=_createNodeIterator(tk?ee:ei);for(;es=ed.nextNode();)_sanitizeElements(es)||(es.content instanceof ec&&_sanitizeShadowDOM(es.content),_sanitizeAttributes(es));if(tk)return ee;if(tw){if(tS)for(eu=e1.call(ei.ownerDocument);ei.firstChild;)eu.appendChild(ei.firstChild);else eu=ei;return(ts.shadowroot||ts.shadowrootmode)&&(eu=e3.call(eo,eu,!0)),eu}let ep=tb?ei.outerHTML:ei.innerHTML;return tb&&ti["!doctype"]&&ei.ownerDocument&&ei.ownerDocument.doctype&&ei.ownerDocument.doctype.name&&eS(eH,ei.ownerDocument.doctype.name)&&(ep="\n"+ep),tm&&ef([e8,e6,e5],ee=>{ep=eb(ep,ee," ")}),et&&tE?et.createHTML(ep):ep},DOMPurify.setConfig=function(){let ee=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};_parseConfig(ee),tv=!0},DOMPurify.clearConfig=function(){tz=null,tv=!1},DOMPurify.isValidAttribute=function(ee,et,en){tz||_parseConfig({});let ei=tK(ee),eo=tK(et);return _isValidAttribute(ei,eo,en)},DOMPurify.addHook=function(ee,et){"function"==typeof et&&(e4[ee]=e4[ee]||[],eh(e4[ee],et))},DOMPurify.removeHook=function(ee){if(e4[ee])return ep(e4[ee])},DOMPurify.removeHooks=function(ee){e4[ee]&&(e4[ee]=[])},DOMPurify.removeAllHooks=function(){e4={}},DOMPurify}return createDOMPurify()})},80645:function(ee,et){/*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh */et.read=function(ee,et,en,ei,eo){var ea,es,eu=8*eo-ei-1,ec=(1<>1,ef=-7,ep=en?eo-1:0,eh=en?-1:1,ey=ee[et+ep];for(ep+=eh,ea=ey&(1<<-ef)-1,ey>>=-ef,ef+=eu;ef>0;ea=256*ea+ee[et+ep],ep+=eh,ef-=8);for(es=ea&(1<<-ef)-1,ea>>=-ef,ef+=ei;ef>0;es=256*es+ee[et+ep],ep+=eh,ef-=8);if(0===ea)ea=1-ed;else{if(ea===ec)return es?NaN:(ey?-1:1)*(1/0);es+=Math.pow(2,ei),ea-=ed}return(ey?-1:1)*es*Math.pow(2,ea-ei)},et.write=function(ee,et,en,ei,eo,ea){var es,eu,ec,ed=8*ea-eo-1,ef=(1<>1,eh=23===eo?5960464477539062e-23:0,ey=ei?0:ea-1,em=ei?1:-1,eg=et<0||0===et&&1/et<0?1:0;for(isNaN(et=Math.abs(et))||et===1/0?(eu=isNaN(et)?1:0,es=ef):(es=Math.floor(Math.log(et)/Math.LN2),et*(ec=Math.pow(2,-es))<1&&(es--,ec*=2),es+ep>=1?et+=eh/ec:et+=eh*Math.pow(2,1-ep),et*ec>=2&&(es++,ec/=2),es+ep>=ef?(eu=0,es=ef):es+ep>=1?(eu=(et*ec-1)*Math.pow(2,eo),es+=ep):(eu=et*Math.pow(2,ep-1)*Math.pow(2,eo),es=0));eo>=8;ee[en+ey]=255&eu,ey+=em,eu/=256,eo-=8);for(es=es<0;ee[en+ey]=255&es,ey+=em,es/=256,ed-=8);ee[en+ey-em]|=128*eg}},39593:function(ee,et,en){"use strict";let ei=en(34411),eo=Symbol("max"),ea=Symbol("length"),es=Symbol("lengthCalculator"),eu=Symbol("allowStale"),ec=Symbol("maxAge"),ed=Symbol("dispose"),ef=Symbol("noDisposeOnSet"),ep=Symbol("lruList"),eh=Symbol("cache"),ey=Symbol("updateAgeOnGet"),naiveLength=()=>1;let LRUCache=class LRUCache{constructor(ee){if("number"==typeof ee&&(ee={max:ee}),ee||(ee={}),ee.max&&("number"!=typeof ee.max||ee.max<0))throw TypeError("max must be a non-negative number");this[eo]=ee.max||1/0;let et=ee.length||naiveLength;if(this[es]="function"!=typeof et?naiveLength:et,this[eu]=ee.stale||!1,ee.maxAge&&"number"!=typeof ee.maxAge)throw TypeError("maxAge must be a number");this[ec]=ee.maxAge||0,this[ed]=ee.dispose,this[ef]=ee.noDisposeOnSet||!1,this[ey]=ee.updateAgeOnGet||!1,this.reset()}set max(ee){if("number"!=typeof ee||ee<0)throw TypeError("max must be a non-negative number");this[eo]=ee||1/0,trim(this)}get max(){return this[eo]}set allowStale(ee){this[eu]=!!ee}get allowStale(){return this[eu]}set maxAge(ee){if("number"!=typeof ee)throw TypeError("maxAge must be a non-negative number");this[ec]=ee,trim(this)}get maxAge(){return this[ec]}set lengthCalculator(ee){"function"!=typeof ee&&(ee=naiveLength),ee!==this[es]&&(this[es]=ee,this[ea]=0,this[ep].forEach(ee=>{ee.length=this[es](ee.value,ee.key),this[ea]+=ee.length})),trim(this)}get lengthCalculator(){return this[es]}get length(){return this[ea]}get itemCount(){return this[ep].length}rforEach(ee,et){et=et||this;for(let en=this[ep].tail;null!==en;){let ei=en.prev;forEachStep(this,ee,en,et),en=ei}}forEach(ee,et){et=et||this;for(let en=this[ep].head;null!==en;){let ei=en.next;forEachStep(this,ee,en,et),en=ei}}keys(){return this[ep].toArray().map(ee=>ee.key)}values(){return this[ep].toArray().map(ee=>ee.value)}reset(){this[ed]&&this[ep]&&this[ep].length&&this[ep].forEach(ee=>this[ed](ee.key,ee.value)),this[eh]=new Map,this[ep]=new ei,this[ea]=0}dump(){return this[ep].map(ee=>!isStale(this,ee)&&{k:ee.key,v:ee.value,e:ee.now+(ee.maxAge||0)}).toArray().filter(ee=>ee)}dumpLru(){return this[ep]}set(ee,et,en){if((en=en||this[ec])&&"number"!=typeof en)throw TypeError("maxAge must be a number");let ei=en?Date.now():0,eu=this[es](et,ee);if(this[eh].has(ee)){if(eu>this[eo])return del(this,this[eh].get(ee)),!1;let es=this[eh].get(ee),ec=es.value;return this[ed]&&!this[ef]&&this[ed](ee,ec.value),ec.now=ei,ec.maxAge=en,ec.value=et,this[ea]+=eu-ec.length,ec.length=eu,this.get(ee),trim(this),!0}let ey=new Entry(ee,et,eu,ei,en);return ey.length>this[eo]?(this[ed]&&this[ed](ee,et),!1):(this[ea]+=ey.length,this[ep].unshift(ey),this[eh].set(ee,this[ep].head),trim(this),!0)}has(ee){if(!this[eh].has(ee))return!1;let et=this[eh].get(ee).value;return!isStale(this,et)}get(ee){return get(this,ee,!0)}peek(ee){return get(this,ee,!1)}pop(){let ee=this[ep].tail;return ee?(del(this,ee),ee.value):null}del(ee){del(this,this[eh].get(ee))}load(ee){this.reset();let et=Date.now();for(let en=ee.length-1;en>=0;en--){let ei=ee[en],eo=ei.e||0;if(0===eo)this.set(ei.k,ei.v);else{let ee=eo-et;ee>0&&this.set(ei.k,ei.v,ee)}}}prune(){this[eh].forEach((ee,et)=>get(this,et,!1))}};let get=(ee,et,en)=>{let ei=ee[eh].get(et);if(ei){let et=ei.value;if(isStale(ee,et)){if(del(ee,ei),!ee[eu])return}else en&&(ee[ey]&&(ei.value.now=Date.now()),ee[ep].unshiftNode(ei));return et.value}},isStale=(ee,et)=>{if(!et||!et.maxAge&&!ee[ec])return!1;let en=Date.now()-et.now;return et.maxAge?en>et.maxAge:ee[ec]&&en>ee[ec]},trim=ee=>{if(ee[ea]>ee[eo])for(let et=ee[ep].tail;ee[ea]>ee[eo]&&null!==et;){let en=et.prev;del(ee,et),et=en}},del=(ee,et)=>{if(et){let en=et.value;ee[ed]&&ee[ed](en.key,en.value),ee[ea]-=en.length,ee[eh].delete(en.key),ee[ep].removeNode(et)}};let Entry=class Entry{constructor(ee,et,en,ei,eo){this.key=ee,this.value=et,this.length=en,this.now=ei,this.maxAge=eo||0}};let forEachStep=(ee,et,en,ei)=>{let eo=en.value;isStale(ee,eo)&&(del(ee,en),ee[eu]||(eo=void 0)),eo&&et.call(ei,eo.value,eo.key,ee)};ee.exports=LRUCache},96675:function(ee,et,en){var ei=en(84993),eo=en(70113),ea=en(83801),es=en(10650);function LRUCache(ee,et,en){if(arguments.length<2&&(en=ee,ee=null,et=null),this.capacity=en,"number"!=typeof this.capacity||this.capacity<=0)throw Error("mnemonist/lru-cache: capacity should be positive number.");var ei=ea.getPointerArray(en);this.forward=new ei(en),this.backward=new ei(en),this.K="function"==typeof ee?new ee(en):Array(en),this.V="function"==typeof et?new et(en):Array(en),this.size=0,this.head=0,this.tail=0,this.items={}}LRUCache.prototype.clear=function(){this.size=0,this.head=0,this.tail=0,this.items={}},LRUCache.prototype.splayOnTop=function(ee){var et=this.head;if(this.head===ee)return this;var en=this.backward[ee],ei=this.forward[ee];return this.tail===ee?this.tail=en:this.backward[ei]=en,this.forward[en]=ei,this.backward[et]=ee,this.head=ee,this.forward[ee]=et,this},LRUCache.prototype.set=function(ee,et){var en=this.items[ee];if(void 0!==en){this.splayOnTop(en),this.V[en]=et;return}this.size1?et:this;for(var en=0,ei=this.size,eo=this.head,ea=this.K,es=this.V,eu=this.forward;en=et)return{done:!0};var ei=eo[en];return++ee=et)return{done:!0};var ei=eo[en];return++ee=et)return{done:!0};var ei=eo[en],eu=ea[en];return++ee=-128?Int8Array:ee<=32767&&ee>=-32768?Int16Array:Int32Array:ee<=255?Uint8Array:ee<=65535?Uint16Array:Uint32Array:Float64Array};var ec={Uint8Array:1,Int8Array:2,Uint16Array:3,Int16Array:4,Uint32Array:5,Int32Array:6,Float32Array:7,Float64Array:8};et.getMinimalRepresentation=function(ee,en){var ei,eo,ea,es,eu,ed=null,ef=0;for(es=0,eu=ee.length;esef&&(ef=ei,ed=eo);return ed},et.isTypedArray=function(ee){return"undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView(ee)},et.concat=function(){var ee,et,en,ei=0;for(ee=0,en=arguments.length;ee{var ee;return null!==(ee=null===eo.randomUUID||void 0===eo.randomUUID?void 0:(0,eo.randomUUID)())&&void 0!==ee?ee:(0,eo.randomBytes)(32).toString("hex")},...ee.session},jwt:{secret:eA,maxAge:eC,encode:ef.encode,decode:ef.decode,...ee.jwt},events:(0,es.eventsErrorHandler)(null!==(eS=ee.events)&&void 0!==eS?eS:{},ea.default),adapter:(0,es.adapterErrorHandler)(ee.adapter,ea.default),callbacks:{...ep.defaultCallbacks,...ee.callbacks},logger:ea.default,callbackUrl:eE.origin},eO=[],{csrfToken:eT,cookie:eP,csrfTokenVerified:eR}=(0,eh.createCSRFToken)({options:ek,cookieValue:null==eg?void 0:eg[ek.cookies.csrfToken.name],isPost:e_,bodyValue:ev});ek.csrfToken=eT,ek.csrfTokenVerified=eR,eP&&eO.push({name:ek.cookies.csrfToken.name,value:eP,options:ek.cookies.csrfToken.options});let{callbackUrl:eI,callbackUrlCookie:eN}=await (0,ey.createCallbackUrl)({options:ek,cookieValue:null==eg?void 0:eg[ek.cookies.callbackUrl.name],paramValue:eb});return ek.callbackUrl=eI,eN&&eO.push({name:ek.cookies.callbackUrl.name,value:eN,options:ek.cookies.callbackUrl.options}),{options:ek,cookies:eO}}},88893:function(ee,et,en){"use strict";var ei=en(36426);Object.defineProperty(et,"__esModule",{value:!0}),et.assertConfig=assertConfig;var eo=en(36925),ea=ei(en(30762)),es=en(46140);let eu=!1;function isValidHttpUrl(ee,et){try{return/^https?:/.test(new URL(ee,ee.startsWith("/")?et:void 0).protocol)}catch(ee){return!1}}function assertConfig(ee){var et,en,ei,ec,ed,ef,ep,eh;let ey,em,eg;let{options:eb,req:ev}=ee,e_=[];if(!eu&&(ev.origin||e_.push("NEXTAUTH_URL"),eb.secret,eb.debug&&e_.push("DEBUG_ENABLED")),!eb.secret)return new eo.MissingSecret("Please define a `secret` in production.");if(!(null!==(et=ev.query)&&void 0!==et&&et.nextauth)&&!ev.action)return new eo.MissingAPIRoute("Cannot find [...nextauth].{js,ts} in `/pages/api/auth`. Make sure the filename is written correctly.");let ew=null===(en=ev.query)||void 0===en?void 0:en.callbackUrl,eS=(0,ea.default)(ev.origin);if(ew&&!isValidHttpUrl(ew,eS.base))return new eo.InvalidCallbackUrl(`Invalid callback URL. Received: ${ew}`);let{callbackUrl:eE}=(0,es.defaultCookies)(null!==(ei=eb.useSecureCookies)&&void 0!==ei?ei:eS.base.startsWith("https://")),eA=null===(ec=ev.cookies)||void 0===ec?void 0:ec[null!==(ed=null===(ef=eb.cookies)||void 0===ef?void 0:null===(ep=ef.callbackUrl)||void 0===ep?void 0:ep.name)&&void 0!==ed?ed:eE.name];if(eA&&!isValidHttpUrl(eA,eS.base))return new eo.InvalidCallbackUrl(`Invalid callback URL. Received: ${eA}`);for(let ee of eb.providers)"credentials"===ee.type?ey=!0:"email"===ee.type?em=!0:"twitter"===ee.id&&"2.0"===ee.version&&(eg=!0);if(ey){let ee=(null===(eh=eb.session)||void 0===eh?void 0:eh.strategy)==="database",et=!eb.providers.some(ee=>"credentials"!==ee.type);if(ee&&et)return new eo.UnsupportedStrategy("Signin in with credentials only supported if JWT strategy is enabled");let en=eb.providers.some(ee=>"credentials"===ee.type&&!ee.authorize);if(en)return new eo.MissingAuthorize("Must define an authorize() handler to use credentials authentication provider")}if(em){let{adapter:ee}=eb;if(!ee)return new eo.MissingAdapter("E-mail login requires an adapter.");let et=["createVerificationToken","useVerificationToken","getUserByEmail"].filter(et=>!ee[et]);if(et.length)return new eo.MissingAdapterMethods(`Required adapter methods were missing: ${et.join(", ")}`)}return eu||(eg&&e_.push("TWITTER_OAUTH_2_BETA"),eu=!0),e_}},98385:function(ee,et,en){"use strict";Object.defineProperty(et,"__esModule",{value:!0}),et.default=callbackHandler;var ei=en(36925),eo=en(15261);async function callbackHandler(ee){var et,en,ea,es,eu,ec;let{sessionToken:ed,profile:ef,account:ep,options:eh}=ee;if(!(null!=ep&&ep.providerAccountId)||!ep.type)throw Error("Missing or invalid provider account");if(!["email","oauth"].includes(ep.type))throw Error("Provider not supported");let{adapter:ey,jwt:em,events:eg,session:{strategy:eb,generateSessionToken:ev}}=eh;if(!ey)return{user:ef,account:ep};let e_=ef,{createUser:ew,updateUser:eS,getUser:eE,getUserByAccount:eA,getUserByEmail:e$,linkAccount:ex,createSession:eC,getSessionAndUser:ek,deleteSession:eO}=ey,eT=null,eP=null,eR=!1,eI="jwt"===eb;if(ed){if(eI)try{(eT=await em.decode({...em,token:ed}))&&"sub"in eT&&eT.sub&&(eP=await eE(eT.sub))}catch(ee){}else{let ee=await ek(ed);ee&&(eT=ee.session,eP=ee.user)}}if("email"===ep.type){let ee=await e$(e_.email);if(ee)(null===(et=eP)||void 0===et?void 0:et.id)!==ee.id&&!eI&&ed&&await eO(ed),eP=await eS({id:ee.id,emailVerified:new Date}),await (null===(en=eg.updateUser)||void 0===en?void 0:en.call(eg,{user:eP}));else{let{id:ee,...et}={...e_,emailVerified:new Date};eP=await ew(et),await (null===(ea=eg.createUser)||void 0===ea?void 0:ea.call(eg,{user:eP})),eR=!0}return{session:eT=eI?{}:await eC({sessionToken:await ev(),userId:eP.id,expires:(0,eo.fromDate)(eh.session.maxAge)}),user:eP,isNewUser:eR}}if("oauth"===ep.type){let ee=await eA({providerAccountId:ep.providerAccountId,provider:ep.provider});if(ee){if(eP){if(ee.id===eP.id)return{session:eT,user:eP,isNewUser:eR};throw new ei.AccountNotLinkedError("The account is already associated with another user")}return{session:eT=eI?{}:await eC({sessionToken:await ev(),userId:ee.id,expires:(0,eo.fromDate)(eh.session.maxAge)}),user:ee,isNewUser:eR}}{if(eP)return await ex({...ep,userId:eP.id}),await (null===(ec=eg.linkAccount)||void 0===ec?void 0:ec.call(eg,{user:eP,account:ep,profile:e_})),{session:eT,user:eP,isNewUser:eR};let ee=e_.email?await e$(e_.email):null;if(ee){let et=eh.provider;if(null!=et&&et.allowDangerousEmailAccountLinking)eP=ee;else throw new ei.AccountNotLinkedError("Another account already exists with the same e-mail address")}else{let{id:ee,...et}={...e_,emailVerified:null};eP=await ew(et)}return await (null===(es=eg.createUser)||void 0===es?void 0:es.call(eg,{user:eP})),await ex({...ep,userId:eP.id}),await (null===(eu=eg.linkAccount)||void 0===eu?void 0:eu.call(eg,{user:eP,account:ep,profile:e_})),{session:eT=eI?{}:await eC({sessionToken:await ev(),userId:eP.id,expires:(0,eo.fromDate)(eh.session.maxAge)}),user:eP,isNewUser:!0}}}throw Error("Unsupported account type")}},75289:function(ee,et){"use strict";async function createCallbackUrl({options:ee,paramValue:et,cookieValue:en}){let{url:ei,callbacks:eo}=ee,ea=ei.origin;return et?ea=await eo.redirect({url:et,baseUrl:ei.origin}):en&&(ea=await eo.redirect({url:en,baseUrl:ei.origin})),{callbackUrl:ea,callbackUrlCookie:ea!==en?ea:void 0}}Object.defineProperty(et,"__esModule",{value:!0}),et.createCallbackUrl=createCallbackUrl},46140:function(ee,et,en){"use strict";var ei=en(36426);Object.defineProperty(et,"__esModule",{value:!0}),et.SessionStore=void 0,et.defaultCookies=defaultCookies;var eo=ei(en(49345)),ea=ei(en(35945));function _classPrivateMethodInitSpec(ee,et){_checkPrivateRedeclaration(ee,et),et.add(ee)}function _classPrivateFieldInitSpec(ee,et,en){_checkPrivateRedeclaration(ee,et),et.set(ee,en)}function _checkPrivateRedeclaration(ee,et){if(et.has(ee))throw TypeError("Cannot initialize the same private elements twice on an object")}function _classPrivateMethodGet(ee,et,en){if(!et.has(ee))throw TypeError("attempted to get private field on non-instance");return en}let es=4096,eu=163,ec=es-eu;function defaultCookies(ee){let et=ee?"__Secure-":"";return{sessionToken:{name:`${et}next-auth.session-token`,options:{httpOnly:!0,sameSite:"lax",path:"/",secure:ee}},callbackUrl:{name:`${et}next-auth.callback-url`,options:{httpOnly:!0,sameSite:"lax",path:"/",secure:ee}},csrfToken:{name:`${ee?"__Host-":""}next-auth.csrf-token`,options:{httpOnly:!0,sameSite:"lax",path:"/",secure:ee}},pkceCodeVerifier:{name:`${et}next-auth.pkce.code_verifier`,options:{httpOnly:!0,sameSite:"lax",path:"/",secure:ee,maxAge:900}},state:{name:`${et}next-auth.state`,options:{httpOnly:!0,sameSite:"lax",path:"/",secure:ee,maxAge:900}},nonce:{name:`${et}next-auth.nonce`,options:{httpOnly:!0,sameSite:"lax",path:"/",secure:ee}}}}var ed=new WeakMap,ef=new WeakMap,ep=new WeakMap,eh=new WeakSet,ey=new WeakSet;let SessionStore=class SessionStore{constructor(ee,et,en){_classPrivateMethodInitSpec(this,ey),_classPrivateMethodInitSpec(this,eh),_classPrivateFieldInitSpec(this,ed,{writable:!0,value:{}}),_classPrivateFieldInitSpec(this,ef,{writable:!0,value:void 0}),_classPrivateFieldInitSpec(this,ep,{writable:!0,value:void 0}),(0,ea.default)(this,ep,en),(0,ea.default)(this,ef,ee);let{cookies:ei}=et,{name:es}=ee;if("function"==typeof(null==ei?void 0:ei.getAll))for(let{name:ee,value:et}of ei.getAll())ee.startsWith(es)&&((0,eo.default)(this,ed)[ee]=et);else if(ei instanceof Map)for(let ee of ei.keys())ee.startsWith(es)&&((0,eo.default)(this,ed)[ee]=ei.get(ee));else for(let ee in ei)ee.startsWith(es)&&((0,eo.default)(this,ed)[ee]=ei[ee])}get value(){let ee=Object.keys((0,eo.default)(this,ed)).sort((ee,et)=>{var en,ei;let eo=parseInt(null!==(en=ee.split(".").pop())&&void 0!==en?en:"0"),ea=parseInt(null!==(ei=et.split(".").pop())&&void 0!==ei?ei:"0");return eo-ea});return ee.map(ee=>(0,eo.default)(this,ed)[ee]).join("")}chunk(ee,et){let en=_classPrivateMethodGet(this,ey,_clean2).call(this),ei=_classPrivateMethodGet(this,eh,_chunk2).call(this,{name:(0,eo.default)(this,ef).name,value:ee,options:{...(0,eo.default)(this,ef).options,...et}});for(let ee of ei)en[ee.name]=ee;return Object.values(en)}clean(){return Object.values(_classPrivateMethodGet(this,ey,_clean2).call(this))}};function _chunk2(ee){let et=Math.ceil(ee.value.length/ec);if(1===et)return(0,eo.default)(this,ed)[ee.name]=ee.value,[ee];let en=[];for(let ei=0;eiee.value.length+eu)}),en}function _clean2(){let ee={};for(let en in(0,eo.default)(this,ed)){var et;null===(et=(0,eo.default)(this,ed))||void 0===et||delete et[en],ee[en]={name:en,value:"",options:{...(0,eo.default)(this,ef).options,maxAge:0}}}return ee}et.SessionStore=SessionStore},53443:function(ee,et,en){"use strict";Object.defineProperty(et,"__esModule",{value:!0}),et.createCSRFToken=createCSRFToken;var ei=en(42474);function createCSRFToken({options:ee,cookieValue:et,isPost:en,bodyValue:eo}){if(et){let[ea,es]=et.split("|"),eu=(0,ei.createHash)("sha256").update(`${ea}${ee.secret}`).digest("hex");if(es===eu){let ee=en&&ea===eo;return{csrfTokenVerified:ee,csrfToken:ea}}}let ea=(0,ei.randomBytes)(32).toString("hex"),es=(0,ei.createHash)("sha256").update(`${ea}${ee.secret}`).digest("hex"),eu=`${ea}|${es}`;return{cookie:eu,csrfToken:ea}}},8244:function(ee,et){"use strict";Object.defineProperty(et,"__esModule",{value:!0}),et.defaultCallbacks=void 0;let en={signIn:()=>!0,redirect:({url:ee,baseUrl:et})=>ee.startsWith("/")?`${et}${ee}`:new URL(ee).origin===et?ee:et,session:({session:ee})=>ee,jwt:({token:ee})=>ee};et.defaultCallbacks=en},33442:function(ee,et){"use strict";async function getAdapterUserFromEmail({email:ee,adapter:et}){let{getUserByEmail:en}=et,ei=ee?await en(ee):null;return ei||{id:ee,email:ee,emailVerified:null}}Object.defineProperty(et,"__esModule",{value:!0}),et.default=getAdapterUserFromEmail},49521:function(ee,et,en){"use strict";Object.defineProperty(et,"__esModule",{value:!0}),et.default=email;var ei=en(42474),eo=en(15261);async function email(ee,et){var en,ea,es,eu;let{url:ec,adapter:ed,provider:ef,callbackUrl:ep,theme:eh}=et,ey=null!==(en=await (null===(ea=ef.generateVerificationToken)||void 0===ea?void 0:ea.call(ef)))&&void 0!==en?en:(0,ei.randomBytes)(32).toString("hex"),em=86400,eg=new Date(Date.now()+(null!==(es=ef.maxAge)&&void 0!==es?es:em)*1e3),eb=new URLSearchParams({callbackUrl:ep,token:ey,email:ee}),ev=`${ec}/callback/${ef.id}?${eb}`;return await Promise.all([ef.sendVerificationRequest({identifier:ee,token:ey,expires:eg,url:ev,provider:ef,theme:eh}),null===(eu=ed.createVerificationToken)||void 0===eu?void 0:eu.call(ed,{identifier:ee,token:(0,eo.hashToken)(ey,et),expires:eg})]),`${ec}/verify-request?${new URLSearchParams({provider:ef.id,type:ef.type})}`}},25680:function(ee,et,en){"use strict";Object.defineProperty(et,"__esModule",{value:!0}),et.default=getAuthorizationUrl;var ei=en(8532),eo=en(44950),ea=_interopRequireWildcard(en(98977));function _getRequireWildcardCache(ee){if("function"!=typeof WeakMap)return null;var et=new WeakMap,en=new WeakMap;return(_getRequireWildcardCache=function(ee){return ee?en:et})(ee)}function _interopRequireWildcard(ee,et){if(!et&&ee&&ee.__esModule)return ee;if(null===ee||"object"!=typeof ee&&"function"!=typeof ee)return{default:ee};var en=_getRequireWildcardCache(et);if(en&&en.has(ee))return en.get(ee);var ei={},eo=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var ea in ee)if("default"!==ea&&Object.prototype.hasOwnProperty.call(ee,ea)){var es=eo?Object.getOwnPropertyDescriptor(ee,ea):null;es&&(es.get||es.set)?Object.defineProperty(ei,ea,es):ei[ea]=ee[ea]}return ei.default=ee,en&&en.set(ee,ei),ei}async function getAuthorizationUrl({options:ee,query:et}){var en,es,eu;let{logger:ec,provider:ed}=ee,ef={};if("string"==typeof ed.authorization){let ee=new URL(ed.authorization),et=Object.fromEntries(ee.searchParams);ef={...ef,...et}}else ef={...ef,...null===(es=ed.authorization)||void 0===es?void 0:es.params};if(ef={...ef,...et},null!==(en=ed.version)&&void 0!==en&&en.startsWith("1.")){let et=(0,eo.oAuth1Client)(ee),en=await et.getOAuthRequestToken(ef),ei=`${null===(eu=ed.authorization)||void 0===eu?void 0:eu.url}?${new URLSearchParams({oauth_token:en.oauth_token,oauth_token_secret:en.oauth_token_secret,...en.params})}`;return eo.oAuth1TokenStore.set(en.oauth_token,en.oauth_token_secret),ec.debug("GET_AUTHORIZATION_URL",{url:ei,provider:ed}),{redirect:ei}}let ep=await (0,ei.openidClient)(ee),eh=ef,ey=[];await ea.state.create(ee,ey,eh),await ea.pkce.create(ee,ey,eh),await ea.nonce.create(ee,ey,eh);let em=ep.authorizationUrl(eh);return ec.debug("GET_AUTHORIZATION_URL",{url:em,cookies:ey,provider:ed}),{redirect:em,cookies:ey}}},97488:function(ee,et,en){"use strict";Object.defineProperty(et,"__esModule",{value:!0}),et.default=oAuthCallback;var ei=en(1831),eo=en(8532),ea=en(44950),es=_interopRequireWildcard(en(98977)),eu=en(36925);function _getRequireWildcardCache(ee){if("function"!=typeof WeakMap)return null;var et=new WeakMap,en=new WeakMap;return(_getRequireWildcardCache=function(ee){return ee?en:et})(ee)}function _interopRequireWildcard(ee,et){if(!et&&ee&&ee.__esModule)return ee;if(null===ee||"object"!=typeof ee&&"function"!=typeof ee)return{default:ee};var en=_getRequireWildcardCache(et);if(en&&en.has(ee))return en.get(ee);var ei={},eo=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var ea in ee)if("default"!==ea&&Object.prototype.hasOwnProperty.call(ee,ea)){var es=eo?Object.getOwnPropertyDescriptor(ee,ea):null;es&&(es.get||es.set)?Object.defineProperty(ei,ea,es):ei[ea]=ee[ea]}return ei.default=ee,en&&en.set(ee,ei),ei}async function oAuthCallback(ee){var et,en,ec,ed,ef,ep;let{options:eh,query:ey,body:em,method:eg,cookies:eb}=ee,{logger:ev,provider:e_}=eh,ew=null!==(et=null==em?void 0:em.error)&&void 0!==et?et:null==ey?void 0:ey.error;if(ew){let ee=Error(ew);throw ev.error("OAUTH_CALLBACK_HANDLER_ERROR",{error:ee,error_description:null==ey?void 0:ey.error_description,providerId:e_.id}),ev.debug("OAUTH_CALLBACK_HANDLER_ERROR",{body:em}),ee}if(null!==(en=e_.version)&&void 0!==en&&en.startsWith("1."))try{let ee=await (0,ea.oAuth1Client)(eh),{oauth_token:et,oauth_verifier:en}=null!=ey?ey:{},ei=await ee.getOAuthAccessToken(et,ea.oAuth1TokenStore.get(et),en),eo=await ee.get(e_.profileUrl,ei.oauth_token,ei.oauth_token_secret);"string"==typeof eo&&(eo=JSON.parse(eo));let es=await getProfile({profile:eo,tokens:ei,provider:e_,logger:ev});return{...es,cookies:[]}}catch(ee){throw ev.error("OAUTH_V1_GET_ACCESS_TOKEN_ERROR",ee),ee}null!=ey&&ey.oauth_token&&ea.oAuth1TokenStore.delete(ey.oauth_token);try{let ee,et;let en=await (0,eo.openidClient)(eh),ea={},eu=[];await es.state.use(eb,eu,eh,ea),await es.pkce.use(eb,eu,eh,ea),await es.nonce.use(eb,eu,eh,ea);let ew={...en.callbackParams({url:`http://n?${new URLSearchParams(ey)}`,body:em,method:eg}),...null===(ec=e_.token)||void 0===ec?void 0:ec.params};if(null!==(ed=e_.token)&&void 0!==ed&&ed.request){let et=await e_.token.request({provider:e_,params:ew,checks:ea,client:en});ee=new ei.TokenSet(et.tokens)}else ee=e_.idToken?await en.callback(e_.callbackUrl,ew,ea):await en.oauthCallback(e_.callbackUrl,ew,ea);Array.isArray(ee.scope)&&(ee.scope=ee.scope.join(" ")),et=null!==(ef=e_.userinfo)&&void 0!==ef&&ef.request?await e_.userinfo.request({provider:e_,tokens:ee,client:en}):e_.idToken?ee.claims():await en.userinfo(ee,{params:null===(ep=e_.userinfo)||void 0===ep?void 0:ep.params});let eS=await getProfile({profile:et,provider:e_,tokens:ee,logger:ev});return{...eS,cookies:eu}}catch(ee){throw new eu.OAuthCallbackError(ee)}}async function getProfile({profile:ee,tokens:et,provider:en,logger:ei}){try{var eo;ei.debug("PROFILE_DATA",{OAuthProfile:ee});let ea=await en.profile(ee,et);if(ea.email=null===(eo=ea.email)||void 0===eo?void 0:eo.toLowerCase(),!ea.id)throw TypeError(`Profile id is missing in ${en.name} OAuth profile response`);return{profile:ea,account:{provider:en.id,type:en.type,providerAccountId:ea.id.toString(),...et},OAuthProfile:ee}}catch(et){ei.error("OAUTH_PARSE_PROFILE_ERROR",{error:et,OAuthProfile:ee})}}},98977:function(ee,et,en){"use strict";Object.defineProperty(et,"__esModule",{value:!0}),et.pkce=et.nonce=et.PKCE_CODE_CHALLENGE_METHOD=void 0,et.signCookie=signCookie,et.state=void 0;var ei=en(1831),eo=_interopRequireWildcard(en(82260));function _getRequireWildcardCache(ee){if("function"!=typeof WeakMap)return null;var et=new WeakMap,en=new WeakMap;return(_getRequireWildcardCache=function(ee){return ee?en:et})(ee)}function _interopRequireWildcard(ee,et){if(!et&&ee&&ee.__esModule)return ee;if(null===ee||"object"!=typeof ee&&"function"!=typeof ee)return{default:ee};var en=_getRequireWildcardCache(et);if(en&&en.has(ee))return en.get(ee);var ei={},eo=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var ea in ee)if("default"!==ea&&Object.prototype.hasOwnProperty.call(ee,ea)){var es=eo?Object.getOwnPropertyDescriptor(ee,ea):null;es&&(es.get||es.set)?Object.defineProperty(ei,ea,es):ei[ea]=ee[ea]}return ei.default=ee,en&&en.set(ee,ei),ei}async function signCookie(ee,et,en,ei){let{cookies:ea,logger:es}=ei;es.debug(`CREATE_${ee.toUpperCase()}`,{value:et,maxAge:en});let{name:eu}=ea[ee],ec=new Date;return ec.setTime(ec.getTime()+1e3*en),{name:eu,value:await eo.encode({...ei.jwt,maxAge:en,token:{value:et},salt:eu}),options:{...ea[ee].options,expires:ec}}}let ea=900,es="S256";et.PKCE_CODE_CHALLENGE_METHOD=es;let eu={async create(ee,et,en){var eo,eu,ec;if(!(null!==(eo=ee.provider)&&void 0!==eo&&null!==(eu=eo.checks)&&void 0!==eu&&eu.includes("pkce")))return;let ed=ei.generators.codeVerifier(),ef=ei.generators.codeChallenge(ed);en.code_challenge=ef,en.code_challenge_method=es;let ep=null!==(ec=ee.cookies.pkceCodeVerifier.options.maxAge)&&void 0!==ec?ec:ea;et.push(await signCookie("pkceCodeVerifier",ed,ep,ee))},async use(ee,et,en,ei){var ea,es;if(!(null!==(ea=en.provider)&&void 0!==ea&&null!==(es=ea.checks)&&void 0!==es&&es.includes("pkce")))return;let eu=null==ee?void 0:ee[en.cookies.pkceCodeVerifier.name];if(!eu)throw TypeError("PKCE code_verifier cookie was missing.");let{name:ec}=en.cookies.pkceCodeVerifier,ed=await eo.decode({...en.jwt,token:eu,salt:ec});if(!(null!=ed&&ed.value))throw TypeError("PKCE code_verifier value could not be parsed.");et.push({name:ec,value:"",options:{...en.cookies.pkceCodeVerifier.options,maxAge:0}}),ei.code_verifier=ed.value}};et.pkce=eu;let ec=900,ed={async create(ee,et,en){var eo,ea;if(!(null!==(eo=ee.provider.checks)&&void 0!==eo&&eo.includes("state")))return;let es=ei.generators.state();en.state=es;let eu=null!==(ea=ee.cookies.state.options.maxAge)&&void 0!==ea?ea:ec;et.push(await signCookie("state",es,eu,ee))},async use(ee,et,en,ei){var ea;if(!(null!==(ea=en.provider.checks)&&void 0!==ea&&ea.includes("state")))return;let es=null==ee?void 0:ee[en.cookies.state.name];if(!es)throw TypeError("State cookie was missing.");let{name:eu}=en.cookies.state,ec=await eo.decode({...en.jwt,token:es,salt:eu});if(!(null!=ec&&ec.value))throw TypeError("State value could not be parsed.");et.push({name:eu,value:"",options:{...en.cookies.state.options,maxAge:0}}),ei.state=ec.value}};et.state=ed;let ef=900,ep={async create(ee,et,en){var eo,ea;if(!(null!==(eo=ee.provider.checks)&&void 0!==eo&&eo.includes("nonce")))return;let es=ei.generators.nonce();en.nonce=es;let eu=null!==(ea=ee.cookies.nonce.options.maxAge)&&void 0!==ea?ea:ef;et.push(await signCookie("nonce",es,eu,ee))},async use(ee,et,en,ei){var ea,es;if(!(null!==(ea=en.provider)&&void 0!==ea&&null!==(es=ea.checks)&&void 0!==es&&es.includes("nonce")))return;let eu=null==ee?void 0:ee[en.cookies.nonce.name];if(!eu)throw TypeError("Nonce cookie was missing.");let{name:ec}=en.cookies.nonce,ed=await eo.decode({...en.jwt,token:eu,salt:ec});if(!(null!=ed&&ed.value))throw TypeError("Nonce value could not be parsed.");et.push({name:ec,value:"",options:{...en.cookies.nonce.options,maxAge:0}}),ei.nonce=ed.value}};et.nonce=ep},44950:function(ee,et,en){"use strict";Object.defineProperty(et,"__esModule",{value:!0}),et.oAuth1Client=oAuth1Client,et.oAuth1TokenStore=void 0;var ei=en(79169);function oAuth1Client(ee){var et,en;let eo=ee.provider,ea=new ei.OAuth(eo.requestTokenUrl,eo.accessTokenUrl,eo.clientId,eo.clientSecret,null!==(et=eo.version)&&void 0!==et?et:"1.0",eo.callbackUrl,null!==(en=eo.encoding)&&void 0!==en?en:"HMAC-SHA1"),es=ea.get.bind(ea);ea.get=async(...ee)=>await new Promise((et,en)=>{es(...ee,(ee,ei)=>{if(ee)return en(ee);et(ei)})});let eu=ea.getOAuthAccessToken.bind(ea);ea.getOAuthAccessToken=async(...ee)=>await new Promise((et,en)=>{eu(...ee,(ee,ei,eo)=>{if(ee)return en(ee);et({oauth_token:ei,oauth_token_secret:eo})})});let ec=ea.getOAuthRequestToken.bind(ea);return ea.getOAuthRequestToken=async(ee={})=>await new Promise((et,en)=>{ec(ee,(ee,ei,eo,ea)=>{if(ee)return en(ee);et({oauth_token:ei,oauth_token_secret:eo,params:ea})})}),ea}let eo=new Map;et.oAuth1TokenStore=eo},8532:function(ee,et,en){"use strict";Object.defineProperty(et,"__esModule",{value:!0}),et.openidClient=openidClient;var ei=en(1831);async function openidClient(ee){let et;let en=ee.provider;if(en.httpOptions&&ei.custom.setHttpOptionsDefaults(en.httpOptions),en.wellKnown)et=await ei.Issuer.discover(en.wellKnown);else{var eo,ea,es;et=new ei.Issuer({issuer:en.issuer,authorization_endpoint:null===(eo=en.authorization)||void 0===eo?void 0:eo.url,token_endpoint:null===(ea=en.token)||void 0===ea?void 0:ea.url,userinfo_endpoint:null===(es=en.userinfo)||void 0===es?void 0:es.url,jwks_uri:en.jwks_endpoint})}let eu=new et.Client({client_id:en.clientId,client_secret:en.clientSecret,redirect_uris:[en.callbackUrl],...en.client},en.jwks);return eu[ei.custom.clock_tolerance]=10,eu}},34443:function(ee,et,en){"use strict";Object.defineProperty(et,"__esModule",{value:!0}),et.default=parseProviders;var ei=en(94848);function parseProviders(ee){let{url:et,providerId:en}=ee,eo=ee.providers.map(({options:ee,...en})=>{var eo,ea;if("oauth"===en.type){let eo=normalizeOAuthOptions(en),es=normalizeOAuthOptions(ee,!0),eu=null!==(ea=null==es?void 0:es.id)&&void 0!==ea?ea:en.id;return(0,ei.merge)(eo,{...es,signinUrl:`${et}/signin/${eu}`,callbackUrl:`${et}/callback/${eu}`})}let es=null!==(eo=null==ee?void 0:ee.id)&&void 0!==eo?eo:en.id;return(0,ei.merge)(en,{...ee,signinUrl:`${et}/signin/${es}`,callbackUrl:`${et}/callback/${es}`})});return{providers:eo,provider:eo.find(({id:ee})=>ee===en)}}function normalizeOAuthOptions(ee,et=!1){var en,ei,eo,ea,es,eu,ec;if(!ee)return;let ed=Object.entries(ee).reduce((ee,[et,en])=>{if(["authorization","token","userinfo"].includes(et)&&"string"==typeof en){var ei;let eo=new URL(en);ee[et]={url:`${eo.origin}${eo.pathname}`,params:Object.fromEntries(null!==(ei=eo.searchParams)&&void 0!==ei?ei:[])}}else ee[et]=en;return ee},{});return et||null!==(en=ed.version)&&void 0!==en&&en.startsWith("1.")||(ed.idToken=!!(null!==(ei=null!==(eo=ed.idToken)&&void 0!==eo?eo:null===(ea=ed.wellKnown)||void 0===ea?void 0:ea.includes("openid-configuration"))&&void 0!==ei?ei:null===(es=ed.authorization)||void 0===es?void 0:null===(eu=es.params)||void 0===eu?void 0:null===(ec=eu.scope)||void 0===ec?void 0:ec.includes("openid")),ed.checks||(ed.checks=["state"])),ed}},15261:function(ee,et,en){"use strict";Object.defineProperty(et,"__esModule",{value:!0}),et.createSecret=createSecret,et.fromDate=fromDate,et.hashToken=hashToken;var ei=en(42474);function fromDate(ee,et=Date.now()){return new Date(et+1e3*ee)}function hashToken(ee,et){var en;let{provider:eo,secret:ea}=et;return(0,ei.createHash)("sha256").update(`${ee}${null!==(en=eo.secret)&&void 0!==en?en:ea}`).digest("hex")}function createSecret(ee){var et;let{authOptions:en,url:eo}=ee;return null!==(et=en.secret)&&void 0!==et?et:(0,ei.createHash)("sha256").update(JSON.stringify({...eo,...en})).digest("hex")}},35131:function(ee,et,en){"use strict";Object.defineProperty(et,"__esModule",{value:!0}),et.default=ErrorPage;var ei=en(6400);function ErrorPage(ee){var et;let{url:en,error:eo="default",theme:ea}=ee,es=`${en}/signin`,eu={default:{status:200,heading:"Error",message:(0,ei.h)("p",null,(0,ei.h)("a",{className:"site",href:null==en?void 0:en.origin},null==en?void 0:en.host))},configuration:{status:500,heading:"Server error",message:(0,ei.h)("div",null,(0,ei.h)("p",null,"There is a problem with the server configuration."),(0,ei.h)("p",null,"Check the server logs for more information."))},accessdenied:{status:403,heading:"Access Denied",message:(0,ei.h)("div",null,(0,ei.h)("p",null,"You do not have permission to sign in."),(0,ei.h)("p",null,(0,ei.h)("a",{className:"button",href:es},"Sign in")))},verification:{status:403,heading:"Unable to sign in",message:(0,ei.h)("div",null,(0,ei.h)("p",null,"The sign in link is no longer valid."),(0,ei.h)("p",null,"It may have been used already or it may have expired.")),signin:(0,ei.h)("a",{className:"button",href:es},"Sign in")}},{status:ec,heading:ed,message:ef,signin:ep}=null!==(et=eu[eo.toLowerCase()])&&void 0!==et?et:eu.default;return{status:ec,html:(0,ei.h)("div",{className:"error"},(null==ea?void 0:ea.brandColor)&&(0,ei.h)("style",{dangerouslySetInnerHTML:{__html:` :root { --brand-color: ${null==ea?void 0:ea.brandColor} } `}}),(0,ei.h)("div",{className:"card"},(null==ea?void 0:ea.logo)&&(0,ei.h)("img",{src:ea.logo,alt:"Logo",className:"logo"}),(0,ei.h)("h1",null,ed),(0,ei.h)("div",{className:"message"},ef),ep))}}},79786:function(ee,et,en){"use strict";var ei=en(36426);Object.defineProperty(et,"__esModule",{value:!0}),et.default=renderPage;var eo=ei(en(57649)),ea=ei(en(8209)),es=ei(en(79422)),eu=ei(en(72189)),ec=ei(en(35131)),ed=ei(en(99394));function renderPage(ee){let{url:et,theme:en,query:ei,cookies:ef}=ee;function send({html:ee,title:et,status:ei}){var ea;return{cookies:ef,status:ei,headers:[{key:"Content-Type",value:"text/html"}],body:`${et}
${(0,eo.default)(ee)}
`}}return{signin:et=>send({html:(0,ea.default)({csrfToken:ee.csrfToken,providers:ee.providers,callbackUrl:ee.callbackUrl,theme:en,...ei,...et}),title:"Sign In"}),signout:ei=>send({html:(0,es.default)({csrfToken:ee.csrfToken,url:et,theme:en,...ei}),title:"Sign Out"}),verifyRequest:ee=>send({html:(0,eu.default)({url:et,theme:en,...ee}),title:"Verify Request"}),error:ee=>send({...(0,ec.default)({url:et,theme:en,...ee}),title:"Error"})}}},8209:function(ee,et,en){"use strict";var ei=en(36426);Object.defineProperty(et,"__esModule",{value:!0}),et.default=SigninPage;var eo=en(6400),ea=ei(en(45425));function hexToRgba(ee,et=1){if(!ee)return;3===(ee=ee.replace(/^#/,"")).length&&(ee=ee[0]+ee[0]+ee[1]+ee[1]+ee[2]+ee[2]);let en=parseInt(ee,16),ei=en>>16&255,eo=en>>8&255,ea=255&en;et=Math.min(Math.max(et,0),1);let es=`rgba(${ei}, ${eo}, ${ea}, ${et})`;return es}function SigninPage(ee){var et;let{csrfToken:en,providers:ei,callbackUrl:es,theme:eu,email:ec,error:ed}=ee,ef=ei.filter(ee=>"oauth"===ee.type||"email"===ee.type||"credentials"===ee.type&&!!ee.credentials);"undefined"!=typeof document&&eu.buttonText&&document.documentElement.style.setProperty("--button-text-color",eu.buttonText),"undefined"!=typeof document&&eu.brandColor&&document.documentElement.style.setProperty("--brand-color",eu.brandColor);let ep={Signin:"Try signing in with a different account.",OAuthSignin:"Try signing in with a different account.",OAuthCallback:"Try signing in with a different account.",OAuthCreateAccount:"Try signing in with a different account.",EmailCreateAccount:"Try signing in with a different account.",Callback:"Try signing in with a different account.",OAuthAccountNotLinked:"To confirm your identity, sign in with the same account you used originally.",EmailSignin:"The e-mail could not be sent.",CredentialsSignin:"Sign in failed. Check the details you provided are correct.",SessionRequired:"Please sign in to access this page.",default:"Unable to sign in."},eh=ed&&(null!==(et=ep[ed])&&void 0!==et?et:ep.default),ey="https://authjs.dev/img/providers";return(0,eo.h)("div",{className:"signin"},eu.brandColor&&(0,eo.h)("style",{dangerouslySetInnerHTML:{__html:` :root { --brand-color: ${eu.brandColor} } `}}),eu.buttonText&&(0,eo.h)("style",{dangerouslySetInnerHTML:{__html:` :root { --button-text-color: ${eu.buttonText} } `}}),(0,eo.h)("div",{className:"card"},eu.logo&&(0,eo.h)("img",{src:eu.logo,alt:"Logo",className:"logo"}),eh&&(0,eo.h)("div",{className:"error"},(0,eo.h)("p",null,eh)),ef.map((ee,et)=>{let ei,eu,ed,ep,eh,em;if("oauth"===ee.type){var eg;({bg:ei="",text:eu="",logo:ed="",bgDark:eh=ei,textDark:em=eu,logoDark:ep=""}=null!==(eg=ee.style)&&void 0!==eg?eg:{}),ed=ed.startsWith("/")?`${ey}${ed}`:ed,(ep=ep.startsWith("/")?`${ey}${ep}`:ep||ed)||(ep=ed)}return(0,eo.h)("div",{key:ee.id,className:"provider"},"oauth"===ee.type&&(0,eo.h)("form",{action:ee.signinUrl,method:"POST"},(0,eo.h)("input",{type:"hidden",name:"csrfToken",value:en}),es&&(0,eo.h)("input",{type:"hidden",name:"callbackUrl",value:es}),(0,eo.h)("button",{type:"submit",className:"button",style:{"--provider-bg":ei,"--provider-dark-bg":eh,"--provider-color":eu,"--provider-dark-color":em,"--provider-bg-hover":hexToRgba(ei,.8),"--provider-dark-bg-hover":hexToRgba(eh,.8)}},ed&&(0,eo.h)("img",{loading:"lazy",height:24,width:24,id:"provider-logo",src:`${ed.startsWith("/")?ey:""}${ed}`}),ep&&(0,eo.h)("img",{loading:"lazy",height:24,width:24,id:"provider-logo-dark",src:`${ed.startsWith("/")?ey:""}${ep}`}),(0,eo.h)("span",null,"Sign in with ",ee.name))),("email"===ee.type||"credentials"===ee.type)&&et>0&&"email"!==ef[et-1].type&&"credentials"!==ef[et-1].type&&(0,eo.h)("hr",null),"email"===ee.type&&(0,eo.h)("form",{action:ee.signinUrl,method:"POST"},(0,eo.h)("input",{type:"hidden",name:"csrfToken",value:en}),(0,eo.h)("label",{className:"section-header",htmlFor:`input-email-for-${ee.id}-provider`},"Email"),(0,eo.h)("input",{id:`input-email-for-${ee.id}-provider`,autoFocus:!0,type:"email",name:"email",value:ec,placeholder:"email@example.com",required:!0}),(0,eo.h)("button",{id:"submitButton",type:"submit"},"Sign in with ",ee.name)),"credentials"===ee.type&&(0,eo.h)("form",{action:ee.callbackUrl,method:"POST"},(0,eo.h)("input",{type:"hidden",name:"csrfToken",value:en}),Object.keys(ee.credentials).map(et=>{var en,ei,es;return(0,eo.h)("div",{key:`input-group-${ee.id}`},(0,eo.h)("label",{className:"section-header",htmlFor:`input-${et}-for-${ee.id}-provider`},null!==(en=ee.credentials[et].label)&&void 0!==en?en:et),(0,eo.h)("input",(0,ea.default)({name:et,id:`input-${et}-for-${ee.id}-provider`,type:null!==(ei=ee.credentials[et].type)&&void 0!==ei?ei:"text",placeholder:null!==(es=ee.credentials[et].placeholder)&&void 0!==es?es:""},ee.credentials[et])))}),(0,eo.h)("button",{type:"submit"},"Sign in with ",ee.name)),("email"===ee.type||"credentials"===ee.type)&&et+1(ee[et]={id:et,name:en,type:ei,signinUrl:eo,callbackUrl:ea},ee),{})}}Object.defineProperty(et,"__esModule",{value:!0}),et.default=providers},65814:function(ee,et,en){"use strict";Object.defineProperty(et,"__esModule",{value:!0}),et.default=session;var ei=en(15261);async function session(ee){var et,en,eo,ea,es,eu;let{options:ec,sessionStore:ed,newSession:ef,isUpdate:ep}=ee,{adapter:eh,jwt:ey,events:em,callbacks:eg,logger:eb,session:{strategy:ev,maxAge:e_}}=ec,ew={body:{},headers:[{key:"Content-Type",value:"application/json"}],cookies:[]},eS=ed.value;if(!eS)return ew;if("jwt"===ev)try{let ee=await ey.decode({...ey,token:eS});if(!ee)throw Error("JWT invalid");let eo=await eg.jwt({token:ee,...ep&&{trigger:"update"},session:ef}),ea=(0,ei.fromDate)(e_),es=await eg.session({session:{user:{name:null==ee?void 0:ee.name,email:null==ee?void 0:ee.email,image:null==ee?void 0:ee.picture},expires:ea.toISOString()},token:eo});ew.body=es;let eu=await ey.encode({...ey,token:eo,maxAge:ec.session.maxAge}),eh=ed.chunk(eu,{expires:ea});null===(et=ew.cookies)||void 0===et||et.push(...eh),await (null===(en=em.session)||void 0===en?void 0:en.call(em,{session:es,token:eo}))}catch(ee){eb.error("JWT_SESSION_ERROR",ee),null===(eo=ew.cookies)||void 0===eo||eo.push(...ed.clean())}else try{let{getSessionAndUser:ee,deleteSession:et,updateSession:en}=eh,eo=await ee(eS);if(eo&&eo.session.expires.valueOf(){let[et,en]=ee.toLowerCase().trim().split("@");return en=en.split(",")[0],`${et}@${en}`};try{ee=en(null==ei?void 0:ei.email)}catch(ee){return ed.error("SIGNIN_EMAIL_ERROR",{error:ee,providerId:ef.id}),{redirect:`${eu}/error?error=EmailSignin`}}let eo=await (0,es.default)({email:ee,adapter:et.adapter}),eh={providerAccountId:ee,userId:ee,type:"email",provider:ef.id};try{let ee=await ec.signIn({user:eo,account:eh,email:{verificationRequest:!0}});if(!ee)return{redirect:`${eu}/error?error=AccessDenied`};if("string"==typeof ee)return{redirect:ee}}catch(ee){return{redirect:`${eu}/error?${new URLSearchParams({error:ee})}`}}try{let en=await (0,ea.default)(ee,et);return{redirect:en}}catch(ee){return ed.error("SIGNIN_EMAIL_ERROR",{error:ee,providerId:ef.id}),{redirect:`${eu}/error?error=EmailSignin`}}}return{redirect:`${eu}/signin`}}},4654:function(ee,et){"use strict";async function signout(ee){var et,en;let{options:ei,sessionStore:eo}=ee,{adapter:ea,events:es,jwt:eu,callbackUrl:ec,logger:ed,session:ef}=ei,ep=null==eo?void 0:eo.value;if(!ep)return{redirect:ec};if("jwt"===ef.strategy)try{let ee=await eu.decode({...eu,token:ep});await (null===(et=es.signOut)||void 0===et?void 0:et.call(es,{token:ee}))}catch(ee){ed.error("SIGNOUT_ERROR",ee)}else try{let ee=await ea.deleteSession(ep);await (null===(en=es.signOut)||void 0===en?void 0:en.call(es,{session:ee}))}catch(ee){ed.error("SIGNOUT_ERROR",ee)}let eh=eo.clean();return{redirect:ec,cookies:eh}}Object.defineProperty(et,"__esModule",{value:!0}),et.default=signout},86049:function(ee,et){"use strict";Object.defineProperty(et,"__esModule",{value:!0})},99394:function(ee){ee.exports=function(){return':root{--border-width:1px;--border-radius:0.5rem;--color-error:#c94b4b;--color-info:#157efb;--color-info-hover:#0f6ddb;--color-info-text:#fff}.__next-auth-theme-auto,.__next-auth-theme-light{--color-background:#ececec;--color-background-hover:hsla(0,0%,93%,.8);--color-background-card:#fff;--color-text:#000;--color-primary:#444;--color-control-border:#bbb;--color-button-active-background:#f9f9f9;--color-button-active-border:#aaa;--color-separator:#ccc}.__next-auth-theme-dark{--color-background:#161b22;--color-background-hover:rgba(22,27,34,.8);--color-background-card:#0d1117;--color-text:#fff;--color-primary:#ccc;--color-control-border:#555;--color-button-active-background:#060606;--color-button-active-border:#666;--color-separator:#444}@media (prefers-color-scheme:dark){.__next-auth-theme-auto{--color-background:#161b22;--color-background-hover:rgba(22,27,34,.8);--color-background-card:#0d1117;--color-text:#fff;--color-primary:#ccc;--color-control-border:#555;--color-button-active-background:#060606;--color-button-active-border:#666;--color-separator:#444}a.button,button{background-color:var(--provider-dark-bg,var(--color-background));color:var(--provider-dark-color,var(--color-primary))}a.button:hover,button:hover{background-color:var(--provider-dark-bg-hover,var(--color-background-hover))!important}#provider-logo{display:none!important}#provider-logo-dark{display:block!important;width:25px}}html{box-sizing:border-box}*,:after,:before{box-sizing:inherit;margin:0;padding:0}body{background-color:var(--color-background);font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;margin:0;padding:0}h1{font-weight:400}h1,p{color:var(--color-text);margin-bottom:1.5rem;padding:0 1rem}form{margin:0;padding:0}label{font-weight:500;margin-bottom:.25rem;text-align:left}input[type],label{color:var(--color-text);display:block}input[type]{background:var(--color-background-card);border:var(--border-width) solid var(--color-control-border);border-radius:var(--border-radius);box-sizing:border-box;font-size:1rem;padding:.5rem 1rem;width:100%}input[type]:focus{box-shadow:none}p{font-size:1.1rem;line-height:2rem}a.button{line-height:1rem;text-decoration:none}a.button:link,a.button:visited{background-color:var(--color-background);color:var(--color-primary)}button span{flex-grow:1}a.button,button{align-items:center;background-color:var(--provider-bg);border-color:rgba(0,0,0,.1);border-radius:var(--border-radius);color:var(--provider-color,var(--color-primary));display:flex;font-size:1.1rem;font-weight:500;justify-content:center;min-height:62px;padding:.75rem 1rem;position:relative;transition:all .1s ease-in-out}a.button:hover,button:hover{background-color:var(--provider-bg-hover,var(--color-background-hover));cursor:pointer}a.button:active,button:active{cursor:pointer}a.button #provider-logo,button #provider-logo{display:block;width:25px}a.button #provider-logo-dark,button #provider-logo-dark{display:none}#submitButton{background-color:var(--brand-color,var(--color-info));color:var(--button-text-color,var(--color-info-text));width:100%}#submitButton:hover{background-color:var(--button-hover-bg,var(--color-info-hover))!important}a.site{color:var(--color-primary);font-size:1rem;line-height:2rem;text-decoration:none}a.site:hover{text-decoration:underline}.page{box-sizing:border-box;display:grid;height:100%;margin:0;padding:0;place-items:center;position:absolute;width:100%}.page>div{text-align:center}.error a.button{margin-top:.5rem;padding-left:2rem;padding-right:2rem}.error .message{margin-bottom:1.5rem}.signin input[type=text]{display:block;margin-left:auto;margin-right:auto}.signin hr{border:0;border-top:1px solid var(--color-separator);display:block;margin:2rem auto 1rem;overflow:visible}.signin hr:before{background:var(--color-background-card);color:#888;content:"or";padding:0 .4rem;position:relative;top:-.7rem}.signin .error{background:#f5f5f5;background:var(--color-error);border-radius:.3rem;font-weight:500}.signin .error p{color:var(--color-info-text);font-size:.9rem;line-height:1.2rem;padding:.5rem 1rem;text-align:left}.signin form,.signin>div{display:block}.signin form input[type],.signin>div input[type]{margin-bottom:.5rem}.signin form button,.signin>div button{width:100%}.signin .provider+.provider{margin-top:1rem}.logo{display:inline-block;margin:1.25rem 0;max-height:70px;max-width:150px}.card{background-color:var(--color-background-card);border-radius:2rem;padding:1.25rem 2rem}.card .header{color:var(--color-primary)}.section-header{color:var(--color-text)}@media screen and (min-width:450px){.card{margin:2rem 0;width:368px}}@media screen and (max-width:450px){.card{margin:1rem 0;width:343px}}'}},62842:function(ee,et,en){"use strict";Object.defineProperty(et,"__esModule",{value:!0});var ei={};Object.defineProperty(et,"default",{enumerable:!0,get:function(){return ea.default}});var eo=en(86049);Object.keys(eo).forEach(function(ee){!("default"===ee||"__esModule"===ee||Object.prototype.hasOwnProperty.call(ei,ee))&&(ee in et&&et[ee]===eo[ee]||Object.defineProperty(et,ee,{enumerable:!0,get:function(){return eo[ee]}}))});var ea=_interopRequireWildcard(en(21379));function _getRequireWildcardCache(ee){if("function"!=typeof WeakMap)return null;var et=new WeakMap,en=new WeakMap;return(_getRequireWildcardCache=function(ee){return ee?en:et})(ee)}function _interopRequireWildcard(ee,et){if(!et&&ee&&ee.__esModule)return ee;if(null===ee||"object"!=typeof ee&&"function"!=typeof ee)return{default:ee};var en=_getRequireWildcardCache(et);if(en&&en.has(ee))return en.get(ee);var ei={},eo=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var ea in ee)if("default"!==ea&&Object.prototype.hasOwnProperty.call(ee,ea)){var es=eo?Object.getOwnPropertyDescriptor(ee,ea):null;es&&(es.get||es.set)?Object.defineProperty(ei,ea,es):ei[ea]=ee[ea]}return ei.default=ee,en&&en.set(ee,ei),ei}Object.keys(ea).forEach(function(ee){!("default"===ee||"__esModule"===ee||Object.prototype.hasOwnProperty.call(ei,ee))&&(ee in et&&et[ee]===ea[ee]||Object.defineProperty(et,ee,{enumerable:!0,get:function(){return ea[ee]}}))})},82260:function(ee,et,en){"use strict";var ei=en(34155),eo=en(36426);Object.defineProperty(et,"__esModule",{value:!0});var ea={encode:!0,decode:!0,getToken:!0};et.decode=decode,et.encode=encode,et.getToken=getToken;var es=en(45595),eu=eo(en(99718)),ec=en(46578),ed=en(46140),ef=en(76444);Object.keys(ef).forEach(function(ee){!("default"===ee||"__esModule"===ee||Object.prototype.hasOwnProperty.call(ea,ee))&&(ee in et&&et[ee]===ef[ee]||Object.defineProperty(et,ee,{enumerable:!0,get:function(){return ef[ee]}}))});let ep=2592e3,now=()=>Date.now()/1e3|0;async function encode(ee){let{token:et={},secret:en,maxAge:ei=ep,salt:eo=""}=ee,ea=await getDerivedEncryptionKey(en,eo);return await new es.EncryptJWT(et).setProtectedHeader({alg:"dir",enc:"A256GCM"}).setIssuedAt().setExpirationTime(now()+ei).setJti((0,ec.v4)()).encrypt(ea)}async function decode(ee){let{token:et,secret:en,salt:ei=""}=ee;if(!et)return null;let eo=await getDerivedEncryptionKey(en,ei),{payload:ea}=await (0,es.jwtDecrypt)(et,eo,{clockTolerance:15});return ea}async function getToken(ee){var et,en,eo;let{req:ea,secureCookie:es=null!==(et=null===(en=ei.env.NEXTAUTH_URL)||void 0===en?void 0:en.startsWith("https://"))&&void 0!==et?et:!!ei.env.VERCEL,cookieName:eu=es?"__Secure-next-auth.session-token":"next-auth.session-token",raw:ec,decode:ef=decode,logger:ep=console,secret:eh=ei.env.NEXTAUTH_SECRET}=ee;if(!ea)throw Error("Must pass `req` to JWT getToken()");let ey=new ed.SessionStore({name:eu,options:{secure:es}},{cookies:ea.cookies,headers:ea.headers},ep),em=ey.value,eg=ea.headers instanceof Headers?ea.headers.get("authorization"):null===(eo=ea.headers)||void 0===eo?void 0:eo.authorization;if(!em&&(null==eg?void 0:eg.split(" ")[0])==="Bearer"){let ee=eg.split(" ")[1];em=decodeURIComponent(ee)}if(!em)return null;if(ec)return em;try{return await ef({token:em,secret:eh})}catch(ee){return null}}async function getDerivedEncryptionKey(ee,et){return await (0,eu.default)("sha256",ee,et,`NextAuth.js Generated Encryption Key${et?` (${et})`:""}`,32)}},76444:function(ee,et){"use strict";Object.defineProperty(et,"__esModule",{value:!0})},21379:function(ee,et,en){"use strict";var ei=en(34155);Object.defineProperty(et,"__esModule",{value:!0}),et.default=void 0,et.getServerSession=getServerSession,et.unstable_getServerSession=unstable_getServerSession;var eo=en(35149),ea=en(23017);async function NextAuthApiHandler(ee,et,en){var es,eu,ec,ed,ef,ep,eh,ey;let{nextauth:em,...eg}=ee.query;null!==(es=en.secret)&&void 0!==es||(en.secret=null!==(eu=null===(ec=en.jwt)||void 0===ec?void 0:ec.secret)&&void 0!==eu?eu:ei.env.NEXTAUTH_SECRET);let eb=await (0,eo.AuthHandler)({req:{body:ee.body,query:eg,cookies:ee.cookies,headers:ee.headers,method:ee.method,action:null==em?void 0:em[0],providerId:null==em?void 0:em[1],error:null!==(ed=ee.query.error)&&void 0!==ed?ed:null==em?void 0:em[1]},options:en});if(et.status(null!==(ef=eb.status)&&void 0!==ef?ef:200),null===(ep=eb.cookies)||void 0===ep||ep.forEach(ee=>(0,ea.setCookie)(et,ee)),null===(eh=eb.headers)||void 0===eh||eh.forEach(ee=>et.setHeader(ee.key,ee.value)),eb.redirect){if((null===(ey=ee.body)||void 0===ey?void 0:ey.json)!=="true"){et.status(302).setHeader("Location",eb.redirect),et.end();return}return et.json({url:eb.redirect})}return et.send(eb.body)}async function NextAuthRouteHandler(ee,et,es){var eu,ec,ed;null!==(eu=es.secret)&&void 0!==eu||(es.secret=ei.env.NEXTAUTH_SECRET);let{headers:ef,cookies:ep}=en(14970),eh=null===(ec=et.params)||void 0===ec?void 0:ec.nextauth,ey=Object.fromEntries(ee.nextUrl.searchParams),em=await (0,ea.getBody)(ee),eg=await (0,eo.AuthHandler)({req:{body:em,query:ey,cookies:Object.fromEntries(ep().getAll().map(ee=>[ee.name,ee.value])),headers:Object.fromEntries(ef()),method:ee.method,action:null==eh?void 0:eh[0],providerId:null==eh?void 0:eh[1],error:null!==(ed=ey.error)&&void 0!==ed?ed:null==eh?void 0:eh[1]},options:es}),eb=(0,ea.toResponse)(eg),ev=eb.headers.get("Location");return(null==em?void 0:em.json)==="true"&&ev?(eb.headers.delete("Location"),eb.headers.set("Content-Type","application/json"),new Response(JSON.stringify({url:ev}),{status:eg.status,headers:eb.headers})):eb}var _default=function(...ee){var et;return 1===ee.length?async(et,en)=>null!=en&&en.params?await NextAuthRouteHandler(et,en,ee[0]):await NextAuthApiHandler(et,en,ee[0]):null!==(et=ee[1])&&void 0!==et&&et.params?NextAuthRouteHandler(...ee):NextAuthApiHandler(...ee)};async function getServerSession(...ee){var et,es;let eu,ec,ed;let ef=0===ee.length||1===ee.length;if(ef){ed=Object.assign({},ee[0],{providers:[]});let{headers:et,cookies:ei}=en(14970);eu={headers:Object.fromEntries(et()),cookies:Object.fromEntries(ei().getAll().map(ee=>[ee.name,ee.value]))},ec={getHeader(){},setCookie(){},setHeader(){}}}else eu=ee[0],ec=ee[1],ed=Object.assign({},ee[2],{providers:[]});null!==(es=(et=ed).secret)&&void 0!==es||(et.secret=ei.env.NEXTAUTH_SECRET);let ep=await (0,eo.AuthHandler)({options:ed,req:{action:"session",method:"GET",cookies:eu.cookies,headers:eu.headers}}),{body:eh,cookies:ey,status:em=200}=ep;if(null==ey||ey.forEach(ee=>(0,ea.setCookie)(ec,ee)),eh&&"string"!=typeof eh&&Object.keys(eh).length){if(200===em)return ef&&delete eh.expires,eh;throw Error(eh.message)}return null}async function unstable_getServerSession(...ee){return await getServerSession(...ee)}et.default=_default},23017:function(ee,et,en){"use strict";Object.defineProperty(et,"__esModule",{value:!0}),et.getBody=getBody,et.setCookie=setCookie,et.toResponse=toResponse;var ei=en(76489);function setCookie(ee,et){var en;let eo=null!==(en=ee.getHeader("Set-Cookie"))&&void 0!==en?en:[];Array.isArray(eo)||(eo=[eo]);let{name:ea,value:es,options:eu}=et,ec=(0,ei.serialize)(ea,es,eu);eo.push(ec),ee.setHeader("Set-Cookie",eo)}async function getBody(ee){if(!("body"in ee)||!ee.body||"POST"!==ee.method)return;let et=ee.headers.get("content-type");if(null!=et&&et.includes("application/json"))return await ee.json();if(null!=et&&et.includes("application/x-www-form-urlencoded")){let et=new URLSearchParams(await ee.text());return Object.fromEntries(et)}}function toResponse(ee){var et,en,eo;let ea=new Headers(null===(et=ee.headers)||void 0===et?void 0:et.reduce((ee,{key:et,value:en})=>(ee[et]=en,ee),{}));null===(en=ee.cookies)||void 0===en||en.forEach(ee=>{let{name:et,value:en,options:eo}=ee,es=(0,ei.serialize)(et,en,eo);ea.has("Set-Cookie")?ea.append("Set-Cookie",es):ea.set("Set-Cookie",es)});let es=ee.body;"application/json"===ea.get("content-type")?es=JSON.stringify(ee.body):"application/x-www-form-urlencoded"===ea.get("content-type")&&(es=new URLSearchParams(ee.body).toString());let eu=ee.redirect?302:null!==(eo=ee.status)&&void 0!==eo?eo:200,ec=new Response(es,{headers:ea,status:eu});return ee.redirect&&ec.headers.set("Location",ee.redirect),ec}},52553:function(ee,et,en){"use strict";var ei=en(34155);function detectOrigin(ee,et){var en;return(null!==(en=ei.env.VERCEL)&&void 0!==en?en:ei.env.AUTH_TRUST_HOST)?`${"http"===et?"http":"https"}://${ee}`:ei.env.NEXTAUTH_URL}Object.defineProperty(et,"__esModule",{value:!0}),et.detectOrigin=detectOrigin},26553:function(ee,et,en){"use strict";var ei=en(36426);Object.defineProperty(et,"__esModule",{value:!0}),et.default=void 0,et.proxyLogger=proxyLogger,et.setLogger=setLogger;var eo=ei(en(55010)),ea=en(36925);function ownKeys(ee,et){var en=Object.keys(ee);if(Object.getOwnPropertySymbols){var ei=Object.getOwnPropertySymbols(ee);et&&(ei=ei.filter(function(et){return Object.getOwnPropertyDescriptor(ee,et).enumerable})),en.push.apply(en,ei)}return en}function _objectSpread(ee){for(var et=1;et0&&void 0!==arguments[0]?arguments[0]:{},et=arguments.length>1?arguments[1]:void 0;et||(es.debug=function(){}),ee.error&&(es.error=ee.error),ee.warn&&(es.warn=ee.warn),ee.debug&&(es.debug=ee.debug)}var eu=es;function proxyLogger(){var ee=arguments.length>0&&void 0!==arguments[0]?arguments[0]:es,et=arguments.length>1?arguments[1]:void 0;try{if("undefined"==typeof window)return ee;var en={},_loop=function(ee){en[ee]=function(en,ei){es[ee](en,ei),"error"===ee&&(ei=formatError(ei)),ei.client=!0;var eo="".concat(et,"/_log"),ea=new URLSearchParams(_objectSpread({level:ee,code:en},ei));return navigator.sendBeacon?navigator.sendBeacon(eo,ea):fetch(eo,{method:"POST",body:ea,keepalive:!0})}};for(var ei in ee)_loop(ei);return en}catch(ee){return es}}et.default=eu},94848:function(ee,et){"use strict";function isObject(ee){return ee&&"object"==typeof ee&&!Array.isArray(ee)}function merge(ee,...et){if(!et.length)return ee;let en=et.shift();if(isObject(ee)&&isObject(en))for(let et in en)isObject(en[et])?(ee[et]||Object.assign(ee,{[et]:{}}),merge(ee[et],en[et])):Object.assign(ee,{[et]:en[et]});return merge(ee,...et)}Object.defineProperty(et,"__esModule",{value:!0}),et.merge=merge},30762:function(ee,et){"use strict";function parseUrl(ee){var et;let en=new URL("http://localhost:3000/api/auth");ee&&!ee.startsWith("http")&&(ee=`https://${ee}`);let ei=new URL(null!==(et=ee)&&void 0!==et?et:en),eo=("/"===ei.pathname?en.pathname:ei.pathname).replace(/\/$/,""),ea=`${ei.origin}${eo}`;return{origin:ei.origin,host:ei.host,path:eo,base:ea,toString:()=>ea}}Object.defineProperty(et,"__esModule",{value:!0}),et.default=parseUrl},49454:function(ee,et,en){"use strict";Object.defineProperty(et,"__esModule",{value:!0}),Object.defineProperty(et,"actionAsyncStorage",{enumerable:!0,get:function(){return eo}});let ei=en(12422),eo=(0,ei.createAsyncLocalStorage)();("function"==typeof et.default||"object"==typeof et.default&&null!==et.default)&&void 0===et.default.__esModule&&(Object.defineProperty(et.default,"__esModule",{value:!0}),Object.assign(et.default,et),ee.exports=et.default)},12422:function(ee,et){"use strict";Object.defineProperty(et,"__esModule",{value:!0}),Object.defineProperty(et,"createAsyncLocalStorage",{enumerable:!0,get:function(){return createAsyncLocalStorage}});let en=Error("Invariant: AsyncLocalStorage accessed in runtime where it is not available");let FakeAsyncLocalStorage=class FakeAsyncLocalStorage{disable(){throw en}getStore(){}run(){throw en}exit(){throw en}enterWith(){throw en}};let ei=globalThis.AsyncLocalStorage;function createAsyncLocalStorage(){return ei?new ei:new FakeAsyncLocalStorage}("function"==typeof et.default||"object"==typeof et.default&&null!==et.default)&&void 0===et.default.__esModule&&(Object.defineProperty(et.default,"__esModule",{value:!0}),Object.assign(et.default,et),ee.exports=et.default)},56695:function(ee,et,en){"use strict";Object.defineProperty(et,"__esModule",{value:!0}),Object.defineProperty(et,"DraftMode",{enumerable:!0,get:function(){return DraftMode}});let ei=en(77395);let DraftMode=class DraftMode{get isEnabled(){return this._provider.isEnabled}enable(){if(!(0,ei.staticGenerationBailout)("draftMode().enable()"))return this._provider.enable()}disable(){if(!(0,ei.staticGenerationBailout)("draftMode().disable()"))return this._provider.disable()}constructor(ee){this._provider=ee}};("function"==typeof et.default||"object"==typeof et.default&&null!==et.default)&&void 0===et.default.__esModule&&(Object.defineProperty(et.default,"__esModule",{value:!0}),Object.assign(et.default,et),ee.exports=et.default)},27439:function(ee,et,en){"use strict";Object.defineProperty(et,"__esModule",{value:!0}),function(ee,et){for(var en in et)Object.defineProperty(ee,en,{enumerable:!0,get:et[en]})}(et,{headers:function(){return headers},cookies:function(){return cookies},draftMode:function(){return draftMode}});let ei=en(9407),eo=en(34042),ea=en(80255),es=en(23743),eu=en(49454),ec=en(77395),ed=en(56695);function headers(){if((0,ec.staticGenerationBailout)("headers",{link:"https://nextjs.org/docs/app/building-your-application/rendering/static-and-dynamic#dynamic-rendering"}))return eo.HeadersAdapter.seal(new Headers({}));let ee=es.requestAsyncStorage.getStore();if(!ee)throw Error("Invariant: headers() expects to have requestAsyncStorage, none available.");return ee.headers}function cookies(){if((0,ec.staticGenerationBailout)("cookies",{link:"https://nextjs.org/docs/app/building-your-application/rendering/static-and-dynamic#dynamic-rendering"}))return ei.RequestCookiesAdapter.seal(new ea.RequestCookies(new Headers({})));let ee=es.requestAsyncStorage.getStore();if(!ee)throw Error("Invariant: cookies() expects to have requestAsyncStorage, none available.");let et=eu.actionAsyncStorage.getStore();return et&&(et.isAction||et.isAppRoute)?ee.mutableCookies:ee.cookies}function draftMode(){let ee=es.requestAsyncStorage.getStore();if(!ee)throw Error("Invariant: draftMode() expects to have requestAsyncStorage, none available.");return new ed.DraftMode(ee.draftMode)}("function"==typeof et.default||"object"==typeof et.default&&null!==et.default)&&void 0===et.default.__esModule&&(Object.defineProperty(et.default,"__esModule",{value:!0}),Object.assign(et.default,et),ee.exports=et.default)},87781:function(ee,et){"use strict";Object.defineProperty(et,"__esModule",{value:!0}),function(ee,et){for(var en in et)Object.defineProperty(ee,en,{enumerable:!0,get:et[en]})}(et,{DYNAMIC_ERROR_CODE:function(){return en},DynamicServerError:function(){return DynamicServerError}});let en="DYNAMIC_SERVER_USAGE";let DynamicServerError=class DynamicServerError extends Error{constructor(ee){super("Dynamic server usage: "+ee),this.digest=en}};("function"==typeof et.default||"object"==typeof et.default&&null!==et.default)&&void 0===et.default.__esModule&&(Object.defineProperty(et.default,"__esModule",{value:!0}),Object.assign(et.default,et),ee.exports=et.default)},42580:function(ee,et,en){"use strict";function maybePostpone(ee,et){if(!ee.isStaticGeneration||!ee.experimental.ppr)return;let ei=en(67294);"function"==typeof ei.unstable_postpone&&ei.unstable_postpone(et)}Object.defineProperty(et,"__esModule",{value:!0}),Object.defineProperty(et,"maybePostpone",{enumerable:!0,get:function(){return maybePostpone}}),("function"==typeof et.default||"object"==typeof et.default&&null!==et.default)&&void 0===et.default.__esModule&&(Object.defineProperty(et.default,"__esModule",{value:!0}),Object.assign(et.default,et),ee.exports=et.default)},23743:function(ee,et,en){"use strict";Object.defineProperty(et,"__esModule",{value:!0}),Object.defineProperty(et,"requestAsyncStorage",{enumerable:!0,get:function(){return eo}});let ei=en(12422),eo=(0,ei.createAsyncLocalStorage)();("function"==typeof et.default||"object"==typeof et.default&&null!==et.default)&&void 0===et.default.__esModule&&(Object.defineProperty(et.default,"__esModule",{value:!0}),Object.assign(et.default,et),ee.exports=et.default)},18898:function(ee,et,en){"use strict";Object.defineProperty(et,"__esModule",{value:!0}),Object.defineProperty(et,"staticGenerationAsyncStorage",{enumerable:!0,get:function(){return eo}});let ei=en(12422),eo=(0,ei.createAsyncLocalStorage)();("function"==typeof et.default||"object"==typeof et.default&&null!==et.default)&&void 0===et.default.__esModule&&(Object.defineProperty(et.default,"__esModule",{value:!0}),Object.assign(et.default,et),ee.exports=et.default)},77395:function(ee,et,en){"use strict";Object.defineProperty(et,"__esModule",{value:!0}),Object.defineProperty(et,"staticGenerationBailout",{enumerable:!0,get:function(){return staticGenerationBailout}});let ei=en(87781),eo=en(42580),ea=en(18898);let StaticGenBailoutError=class StaticGenBailoutError extends Error{constructor(...ee){super(...ee),this.code="NEXT_STATIC_GEN_BAILOUT"}};function formatErrorMessage(ee,et){let{dynamic:en,link:ei}=et||{},eo=ei?" See more info here: "+ei:"";return"Page"+(en?' with `dynamic = "'+en+'"`':"")+" couldn't be rendered statically because it used `"+ee+"`."+eo}let staticGenerationBailout=(ee,et)=>{let en=ea.staticGenerationAsyncStorage.getStore();if(!en)return!1;if(en.forceStatic)return!0;if(en.dynamicShouldError){var es;throw new StaticGenBailoutError(formatErrorMessage(ee,{...et,dynamic:null!=(es=null==et?void 0:et.dynamic)?es:"error"}))}let eu=formatErrorMessage(ee,{...et,link:"https://nextjs.org/docs/messages/dynamic-server-error"});if((0,eo.maybePostpone)(en,eu),en.revalidate=0,(null==et?void 0:et.dynamic)||(en.staticPrefetchBailout=!0),en.isStaticGeneration){let et=new ei.DynamicServerError(eu);throw en.dynamicUsageDescription=ee,en.dynamicUsageStack=et.stack,et}return!1};("function"==typeof et.default||"object"==typeof et.default&&null!==et.default)&&void 0===et.default.__esModule&&(Object.defineProperty(et.default,"__esModule",{value:!0}),Object.assign(et.default,et),ee.exports=et.default)},23271:function(ee,et,en){"use strict";Object.defineProperty(et,"__esModule",{value:!0}),Object.defineProperty(et,"Image",{enumerable:!0,get:function(){return eg}});let ei=en(38754),eo=en(61757),ea=eo._(en(67294)),es=ei._(en(73935)),eu=ei._(en(79201)),ec=en(53914),ed=en(85494),ef=en(30869);en(81905);let ep=en(11823),eh=ei._(en(74545)),ey={deviceSizes:[640,750,828,1080,1200,1920,2048,3840],imageSizes:[16,32,48,64,96,128,256,384],path:"/_next/image",loader:"default",dangerouslyAllowSVG:!1,unoptimized:!1};function handleLoading(ee,et,en,ei,eo,ea){let es=null==ee?void 0:ee.src;if(!ee||ee["data-loaded-src"]===es)return;ee["data-loaded-src"]=es;let eu="decode"in ee?ee.decode():Promise.resolve();eu.catch(()=>{}).then(()=>{if(ee.parentElement&&ee.isConnected){if("empty"!==et&&eo(!0),null==en?void 0:en.current){let et=new Event("load");Object.defineProperty(et,"target",{writable:!1,value:ee});let ei=!1,eo=!1;en.current({...et,nativeEvent:et,currentTarget:ee,target:ee,isDefaultPrevented:()=>ei,isPropagationStopped:()=>eo,persist:()=>{},preventDefault:()=>{ei=!0,et.preventDefault()},stopPropagation:()=>{eo=!0,et.stopPropagation()}})}(null==ei?void 0:ei.current)&&ei.current(ee)}})}function getDynamicProps(ee){let[et,en]=ea.version.split(".",2),ei=parseInt(et,10),eo=parseInt(en,10);return ei>18||18===ei&&eo>=3?{fetchPriority:ee}:{fetchpriority:ee}}let em=(0,ea.forwardRef)((ee,et)=>{let{src:en,srcSet:ei,sizes:eo,height:es,width:eu,decoding:ec,className:ed,style:ef,fetchPriority:ep,placeholder:eh,loading:ey,unoptimized:em,fill:eg,onLoadRef:eb,onLoadingCompleteRef:ev,setBlurComplete:e_,setShowAltText:ew,onLoad:eS,onError:eE,...eA}=ee;return ea.default.createElement("img",{...eA,...getDynamicProps(ep),loading:ey,width:eu,height:es,decoding:ec,"data-nimg":eg?"fill":"1",className:ed,style:ef,sizes:eo,srcSet:ei,src:en,ref:(0,ea.useCallback)(ee=>{et&&("function"==typeof et?et(ee):"object"==typeof et&&(et.current=ee)),ee&&(eE&&(ee.src=ee.src),ee.complete&&handleLoading(ee,eh,eb,ev,e_,em))},[en,eh,eb,ev,e_,eE,em,et]),onLoad:ee=>{let et=ee.currentTarget;handleLoading(et,eh,eb,ev,e_,em)},onError:ee=>{ew(!0),"empty"!==eh&&e_(!0),eE&&eE(ee)}})});function ImagePreload(ee){let{isAppRouter:et,imgAttributes:en}=ee,ei={as:"image",imageSrcSet:en.srcSet,imageSizes:en.sizes,crossOrigin:en.crossOrigin,referrerPolicy:en.referrerPolicy,...getDynamicProps(en.fetchPriority)};return et&&es.default.preload?(es.default.preload(en.src,ei),null):ea.default.createElement(eu.default,null,ea.default.createElement("link",{key:"__nimg-"+en.src+en.srcSet+en.sizes,rel:"preload",href:en.srcSet?void 0:en.src,...ei}))}let eg=(0,ea.forwardRef)((ee,et)=>{let en=(0,ea.useContext)(ep.RouterContext),ei=!en,eo=(0,ea.useContext)(ef.ImageConfigContext),es=(0,ea.useMemo)(()=>{let ee=ey||eo||ed.imageConfigDefault,et=[...ee.deviceSizes,...ee.imageSizes].sort((ee,et)=>ee-et),en=ee.deviceSizes.sort((ee,et)=>ee-et);return{...ee,allSizes:et,deviceSizes:en}},[eo]),{onLoad:eu,onLoadingComplete:eg}=ee,eb=(0,ea.useRef)(eu);(0,ea.useEffect)(()=>{eb.current=eu},[eu]);let ev=(0,ea.useRef)(eg);(0,ea.useEffect)(()=>{ev.current=eg},[eg]);let[e_,ew]=(0,ea.useState)(!1),[eS,eE]=(0,ea.useState)(!1),{props:eA,meta:e$}=(0,ec.getImgProps)(ee,{defaultLoader:eh.default,imgConf:es,blurComplete:e_,showAltText:eS});return ea.default.createElement(ea.default.Fragment,null,ea.default.createElement(em,{...eA,unoptimized:e$.unoptimized,placeholder:e$.placeholder,fill:e$.fill,onLoadRef:eb,onLoadingCompleteRef:ev,setBlurComplete:ew,setShowAltText:eE,ref:et}),e$.priority?ea.default.createElement(ImagePreload,{isAppRouter:ei,imgAttributes:eA}):null)});("function"==typeof et.default||"object"==typeof et.default&&null!==et.default)&&void 0===et.default.__esModule&&(Object.defineProperty(et.default,"__esModule",{value:!0}),Object.assign(et.default,et),ee.exports=et.default)},53914:function(ee,et,en){"use strict";Object.defineProperty(et,"__esModule",{value:!0}),Object.defineProperty(et,"getImgProps",{enumerable:!0,get:function(){return getImgProps}}),en(81905);let ei=en(32393),eo=en(85494);function isStaticRequire(ee){return void 0!==ee.default}function isStaticImageData(ee){return void 0!==ee.src}function isStaticImport(ee){return"object"==typeof ee&&(isStaticRequire(ee)||isStaticImageData(ee))}function getInt(ee){return void 0===ee?ee:"number"==typeof ee?Number.isFinite(ee)?ee:NaN:"string"==typeof ee&&/^[0-9]+$/.test(ee)?parseInt(ee,10):NaN}function getWidths(ee,et,en){let{deviceSizes:ei,allSizes:eo}=ee;if(en){let ee=/(^|\s)(1?\d?\d)vw/g,et=[];for(let ei;ei=ee.exec(en);ei)et.push(parseInt(ei[2]));if(et.length){let ee=.01*Math.min(...et);return{widths:eo.filter(et=>et>=ei[0]*ee),kind:"w"}}return{widths:eo,kind:"w"}}if("number"!=typeof et)return{widths:ei,kind:"w"};let ea=[...new Set([et,2*et].map(ee=>eo.find(et=>et>=ee)||eo[eo.length-1]))];return{widths:ea,kind:"x"}}function generateImgAttrs(ee){let{config:et,src:en,unoptimized:ei,width:eo,quality:ea,sizes:es,loader:eu}=ee;if(ei)return{src:en,srcSet:void 0,sizes:void 0};let{widths:ec,kind:ed}=getWidths(et,eo,es),ef=ec.length-1;return{sizes:es||"w"!==ed?es:"100vw",srcSet:ec.map((ee,ei)=>eu({config:et,src:en,quality:ea,width:ee})+" "+("w"===ed?ee:ei+1)+ed).join(", "),src:eu({config:et,src:en,quality:ea,width:ec[ef]})}}function getImgProps(ee,et){let en,ea,es,{src:eu,sizes:ec,unoptimized:ed=!1,priority:ef=!1,loading:ep,className:eh,quality:ey,width:em,height:eg,fill:eb=!1,style:ev,onLoad:e_,onLoadingComplete:ew,placeholder:eS="empty",blurDataURL:eE,fetchPriority:eA,layout:e$,objectFit:ex,objectPosition:eC,lazyBoundary:ek,lazyRoot:eO,...eT}=ee,{imgConf:eP,showAltText:eR,blurComplete:eI,defaultLoader:eN}=et,eM=eP||eo.imageConfigDefault;if("allSizes"in eM)en=eM;else{let ee=[...eM.deviceSizes,...eM.imageSizes].sort((ee,et)=>ee-et),et=eM.deviceSizes.sort((ee,et)=>ee-et);en={...eM,allSizes:ee,deviceSizes:et}}let ej=eT.loader||eN;delete eT.loader,delete eT.srcSet;let eD="__next_img_default"in ej;if(eD){if("custom"===en.loader)throw Error('Image with src "'+eu+'" is missing "loader" prop.\nRead more: https://nextjs.org/docs/messages/next-image-missing-loader')}else{let ee=ej;ej=et=>{let{config:en,...ei}=et;return ee(ei)}}if(e$){"fill"===e$&&(eb=!0);let ee={intrinsic:{maxWidth:"100%",height:"auto"},responsive:{width:"100%",height:"auto"}},et={responsive:"100vw",fill:"100vw"},en=ee[e$];en&&(ev={...ev,...en});let ei=et[e$];ei&&!ec&&(ec=ei)}let eB="",eU=getInt(em),eL=getInt(eg);if(isStaticImport(eu)){let ee=isStaticRequire(eu)?eu.default:eu;if(!ee.src)throw Error("An object should only be passed to the image component src parameter if it comes from a static image import. It must include src. Received "+JSON.stringify(ee));if(!ee.height||!ee.width)throw Error("An object should only be passed to the image component src parameter if it comes from a static image import. It must include height and width. Received "+JSON.stringify(ee));if(ea=ee.blurWidth,es=ee.blurHeight,eE=eE||ee.blurDataURL,eB=ee.src,!eb){if(eU||eL){if(eU&&!eL){let et=eU/ee.width;eL=Math.round(ee.height*et)}else if(!eU&&eL){let et=eL/ee.height;eU=Math.round(ee.width*et)}}else eU=ee.width,eL=ee.height}}let eF=!ef&&("lazy"===ep||void 0===ep);(!(eu="string"==typeof eu?eu:eB)||eu.startsWith("data:")||eu.startsWith("blob:"))&&(ed=!0,eF=!1),en.unoptimized&&(ed=!0),eD&&eu.endsWith(".svg")&&!en.dangerouslyAllowSVG&&(ed=!0),ef&&(eA="high");let eW=getInt(ey),eH=Object.assign(eb?{position:"absolute",height:"100%",width:"100%",left:0,top:0,right:0,bottom:0,objectFit:ex,objectPosition:eC}:{},eR?{}:{color:"transparent"},ev),eq=eI||"empty"===eS?null:"blur"===eS?'url("data:image/svg+xml;charset=utf-8,'+(0,ei.getImageBlurSvg)({widthInt:eU,heightInt:eL,blurWidth:ea,blurHeight:es,blurDataURL:eE||"",objectFit:eH.objectFit})+'")':'url("'+eS+'")',eV=eq?{backgroundSize:eH.objectFit||"cover",backgroundPosition:eH.objectPosition||"50% 50%",backgroundRepeat:"no-repeat",backgroundImage:eq}:{},eK=generateImgAttrs({config:en,src:eu,unoptimized:ed,width:eU,quality:eW,sizes:ec,loader:ej}),ez={...eT,loading:eF?"lazy":ep,fetchPriority:eA,width:eU,height:eL,decoding:"async",className:eh,style:{...eH,...eV},sizes:eK.sizes,srcSet:eK.srcSet,src:eK.src},eJ={unoptimized:ed,priority:ef,placeholder:eS,fill:eb};return{props:ez,meta:eJ}}},32393:function(ee,et){"use strict";function getImageBlurSvg(ee){let{widthInt:et,heightInt:en,blurWidth:ei,blurHeight:eo,blurDataURL:ea,objectFit:es}=ee,eu=20,ec=ei?40*ei:et,ed=eo?40*eo:en,ef=ec&&ed?"viewBox='0 0 "+ec+" "+ed+"'":"",ep=ef?"none":"contain"===es?"xMidYMid":"cover"===es?"xMidYMid slice":"none";return"%3Csvg xmlns='http://www.w3.org/2000/svg' "+ef+"%3E%3Cfilter id='b' color-interpolation-filters='sRGB'%3E%3CfeGaussianBlur stdDeviation='"+eu+"'/%3E%3CfeColorMatrix values='1 0 0 0 0 0 1 0 0 0 0 0 1 0 0 0 0 0 100 -1' result='s'/%3E%3CfeFlood x='0' y='0' width='100%25' height='100%25'/%3E%3CfeComposite operator='out' in='s'/%3E%3CfeComposite in2='SourceGraphic'/%3E%3CfeGaussianBlur stdDeviation='"+eu+"'/%3E%3C/filter%3E%3Cimage width='100%25' height='100%25' x='0' y='0' preserveAspectRatio='"+ep+"' style='filter: url(%23b);' href='"+ea+"'/%3E%3C/svg%3E"}Object.defineProperty(et,"__esModule",{value:!0}),Object.defineProperty(et,"getImageBlurSvg",{enumerable:!0,get:function(){return getImageBlurSvg}})},645:function(ee,et,en){"use strict";Object.defineProperty(et,"__esModule",{value:!0}),function(ee,et){for(var en in et)Object.defineProperty(ee,en,{enumerable:!0,get:et[en]})}(et,{unstable_getImgProps:function(){return unstable_getImgProps},default:function(){return ec}});let ei=en(38754),eo=en(53914),ea=en(81905),es=en(23271),eu=ei._(en(74545)),unstable_getImgProps=ee=>{(0,ea.warnOnce)("Warning: unstable_getImgProps() is experimental and may change or be removed at any time. Use at your own risk.");let{props:et}=(0,eo.getImgProps)(ee,{defaultLoader:eu.default,imgConf:{deviceSizes:[640,750,828,1080,1200,1920,2048,3840],imageSizes:[16,32,48,64,96,128,256,384],path:"/_next/image",loader:"default",dangerouslyAllowSVG:!1,unoptimized:!1}});for(let[ee,en]of Object.entries(et))void 0===en&&delete et[ee];return{props:et}},ec=es.Image},74545:function(ee,et){"use strict";function defaultLoader(ee){let{config:et,src:en,width:ei,quality:eo}=ee;return et.path+"?url="+encodeURIComponent(en)+"&w="+ei+"&q="+(eo||75)}Object.defineProperty(et,"__esModule",{value:!0}),Object.defineProperty(et,"default",{enumerable:!0,get:function(){return en}}),defaultLoader.__next_img_default=!0;let en=defaultLoader},89079:function(ee){"use strict";var et=Object.defineProperty,en=Object.getOwnPropertyDescriptor,ei=Object.getOwnPropertyNames,eo=Object.prototype.hasOwnProperty,__copyProps=(ee,ea,es,eu)=>{if(ea&&"object"==typeof ea||"function"==typeof ea)for(let ec of ei(ea))eo.call(ee,ec)||ec===es||et(ee,ec,{get:()=>ea[ec],enumerable:!(eu=en(ea,ec))||eu.enumerable});return ee},__toCommonJS=ee=>__copyProps(et({},"__esModule",{value:!0}),ee),ea={};function stringifyCookie(ee){var et;let en=["path"in ee&&ee.path&&`Path=${ee.path}`,"expires"in ee&&(ee.expires||0===ee.expires)&&`Expires=${("number"==typeof ee.expires?new Date(ee.expires):ee.expires).toUTCString()}`,"maxAge"in ee&&"number"==typeof ee.maxAge&&`Max-Age=${ee.maxAge}`,"domain"in ee&&ee.domain&&`Domain=${ee.domain}`,"secure"in ee&&ee.secure&&"Secure","httpOnly"in ee&&ee.httpOnly&&"HttpOnly","sameSite"in ee&&ee.sameSite&&`SameSite=${ee.sameSite}`,"priority"in ee&&ee.priority&&`Priority=${ee.priority}`].filter(Boolean);return`${ee.name}=${encodeURIComponent(null!=(et=ee.value)?et:"")}; ${en.join("; ")}`}function parseCookie(ee){let et=new Map;for(let en of ee.split(/; */)){if(!en)continue;let ee=en.indexOf("=");if(-1===ee){et.set(en,"true");continue}let[ei,eo]=[en.slice(0,ee),en.slice(ee+1)];try{et.set(ei,decodeURIComponent(null!=eo?eo:"true"))}catch{}}return et}function parseSetCookie(ee){if(!ee)return;let[[et,en],...ei]=parseCookie(ee),{domain:eo,expires:ea,httponly:es,maxage:eu,path:ec,samesite:ed,secure:ef,priority:ep}=Object.fromEntries(ei.map(([ee,et])=>[ee.toLowerCase(),et])),eh={name:et,value:decodeURIComponent(en),domain:eo,...ea&&{expires:new Date(ea)},...es&&{httpOnly:!0},..."string"==typeof eu&&{maxAge:Number(eu)},path:ec,...ed&&{sameSite:parseSameSite(ed)},...ef&&{secure:!0},...ep&&{priority:parsePriority(ep)}};return compact(eh)}function compact(ee){let et={};for(let en in ee)ee[en]&&(et[en]=ee[en]);return et}((ee,en)=>{for(var ei in en)et(ee,ei,{get:en[ei],enumerable:!0})})(ea,{RequestCookies:()=>ec,ResponseCookies:()=>ed,parseCookie:()=>parseCookie,parseSetCookie:()=>parseSetCookie,stringifyCookie:()=>stringifyCookie}),ee.exports=__toCommonJS(ea);var es=["strict","lax","none"];function parseSameSite(ee){return ee=ee.toLowerCase(),es.includes(ee)?ee:void 0}var eu=["low","medium","high"];function parsePriority(ee){return ee=ee.toLowerCase(),eu.includes(ee)?ee:void 0}function splitCookiesString(ee){if(!ee)return[];var et,en,ei,eo,ea,es=[],eu=0;function skipWhitespace(){for(;eu=ee.length)&&es.push(ee.substring(et,ee.length))}return es}var ec=class{constructor(ee){this._parsed=new Map,this._headers=ee;let et=ee.get("cookie");if(et){let ee=parseCookie(et);for(let[et,en]of ee)this._parsed.set(et,{name:et,value:en})}}[Symbol.iterator](){return this._parsed[Symbol.iterator]()}get size(){return this._parsed.size}get(...ee){let et="string"==typeof ee[0]?ee[0]:ee[0].name;return this._parsed.get(et)}getAll(...ee){var et;let en=Array.from(this._parsed);if(!ee.length)return en.map(([ee,et])=>et);let ei="string"==typeof ee[0]?ee[0]:null==(et=ee[0])?void 0:et.name;return en.filter(([ee])=>ee===ei).map(([ee,et])=>et)}has(ee){return this._parsed.has(ee)}set(...ee){let[et,en]=1===ee.length?[ee[0].name,ee[0].value]:ee,ei=this._parsed;return ei.set(et,{name:et,value:en}),this._headers.set("cookie",Array.from(ei).map(([ee,et])=>stringifyCookie(et)).join("; ")),this}delete(ee){let et=this._parsed,en=Array.isArray(ee)?ee.map(ee=>et.delete(ee)):et.delete(ee);return this._headers.set("cookie",Array.from(et).map(([ee,et])=>stringifyCookie(et)).join("; ")),en}clear(){return this.delete(Array.from(this._parsed.keys())),this}[Symbol.for("edge-runtime.inspect.custom")](){return`RequestCookies ${JSON.stringify(Object.fromEntries(this._parsed))}`}toString(){return[...this._parsed.values()].map(ee=>`${ee.name}=${encodeURIComponent(ee.value)}`).join("; ")}},ed=class{constructor(ee){var et,en,ei;this._parsed=new Map,this._headers=ee;let eo=null!=(ei=null!=(en=null==(et=ee.getSetCookie)?void 0:et.call(ee))?en:ee.get("set-cookie"))?ei:[],ea=Array.isArray(eo)?eo:splitCookiesString(eo);for(let ee of ea){let et=parseSetCookie(ee);et&&this._parsed.set(et.name,et)}}get(...ee){let et="string"==typeof ee[0]?ee[0]:ee[0].name;return this._parsed.get(et)}getAll(...ee){var et;let en=Array.from(this._parsed.values());if(!ee.length)return en;let ei="string"==typeof ee[0]?ee[0]:null==(et=ee[0])?void 0:et.name;return en.filter(ee=>ee.name===ei)}has(ee){return this._parsed.has(ee)}set(...ee){let[et,en,ei]=1===ee.length?[ee[0].name,ee[0].value,ee[0]]:ee,eo=this._parsed;return eo.set(et,normalizeCookie({name:et,value:en,...ei})),replace(eo,this._headers),this}delete(...ee){let[et,en,ei]="string"==typeof ee[0]?[ee[0]]:[ee[0].name,ee[0].path,ee[0].domain];return this.set({name:et,path:en,domain:ei,value:"",expires:new Date(0)})}[Symbol.for("edge-runtime.inspect.custom")](){return`ResponseCookies ${JSON.stringify(Object.fromEntries(this._parsed))}`}toString(){return[...this._parsed.values()].map(stringifyCookie).join("; ")}};function replace(ee,et){for(let[,en]of(et.delete("set-cookie"),ee)){let ee=stringifyCookie(en);et.append("set-cookie",ee)}}function normalizeCookie(ee={name:"",value:""}){return"number"==typeof ee.expires&&(ee.expires=new Date(ee.expires)),ee.maxAge&&(ee.expires=new Date(Date.now()+1e3*ee.maxAge)),(null===ee.path||void 0===ee.path)&&(ee.path="/"),ee}},27596:function(ee,et,en){var ei="/",eo=en(34155),ea=en(48764).Buffer;!function(){var et={992:function(ee){ee.exports=function(ee,en,ei){if(ee.filter)return ee.filter(en,ei);if(null==ee||"function"!=typeof en)throw TypeError();for(var eo=[],ea=0;ea1?et-1:0),ei=1;ei1?et-1:0),ei=1;ei1?et-1:0),ei=1;ei1?et-1:0),ei=1;eiee.length)&&(en=ee.length),ee.substring(en-et.length,en)===et}function repeat(ee,et){if(et=Math.floor(et),0==ee.length||0==et)return"";var en=ee.length*et;for(et=Math.floor(Math.log(et)/Math.log(2));et;)ee+=ee,et--;return ee+ee.substring(0,en-ee.length)}var es="",eu="",ec="",ed="",ef={deepStrictEqual:"Expected values to be strictly deep-equal:",strictEqual:"Expected values to be strictly equal:",strictEqualObject:'Expected "actual" to be reference-equal to "expected":',deepEqual:"Expected values to be loosely deep-equal:",equal:"Expected values to be loosely equal:",notDeepStrictEqual:'Expected "actual" not to be strictly deep-equal to:',notStrictEqual:'Expected "actual" to be strictly unequal to:',notStrictEqualObject:'Expected "actual" not to be reference-equal to "expected":',notDeepEqual:'Expected "actual" not to be loosely deep-equal to:',notEqual:'Expected "actual" to be loosely unequal to:',notIdentical:"Values identical but not reference-equal:"},ep=10;function copyError(ee){var et=Object.keys(ee),en=Object.create(Object.getPrototypeOf(ee));return et.forEach(function(et){en[et]=ee[et]}),Object.defineProperty(en,"message",{value:ee.message}),en}function inspectValue(ee){return ei(ee,{compact:!1,customInspect:!1,depth:1e3,maxArrayLength:1/0,showHidden:!1,breakLength:1/0,showProxy:!1,sorted:!0,getters:!0})}function createErrDiff(ee,et,en){var ei="",ea="",eh=0,ey="",em=!1,eg=inspectValue(ee),eb=eg.split("\n"),ev=inspectValue(et).split("\n"),e_=0,ew="";if("strictEqual"===en&&"object"===_typeof(ee)&&"object"===_typeof(et)&&null!==ee&&null!==et&&(en="strictEqualObject"),1===eb.length&&1===ev.length&&eb[0]!==ev[0]){var eS=eb[0].length+ev[0].length;if(eS<=ep){if(("object"!==_typeof(ee)||null===ee)&&("object"!==_typeof(et)||null===et)&&(0!==ee||0!==et))return"".concat(ef[en],"\n\n")+"".concat(eb[0]," !== ").concat(ev[0],"\n")}else if("strictEqualObject"!==en&&eS<(eo.stderr&&eo.stderr.isTTY?eo.stderr.columns:80)){for(;eb[0][e_]===ev[0][e_];)e_++;e_>2&&(ew="\n ".concat(repeat(" ",e_),"^"),e_=0)}}for(var eE=eb[eb.length-1],eA=ev[ev.length-1];eE===eA&&(e_++<2?ey="\n ".concat(eE).concat(ey):ei=eE,eb.pop(),ev.pop(),0!==eb.length&&0!==ev.length);)eE=eb[eb.length-1],eA=ev[ev.length-1];var e$=Math.max(eb.length,ev.length);if(0===e$){var ex=eg.split("\n");if(ex.length>30)for(ex[26]="".concat(es,"...").concat(ed);ex.length>27;)ex.pop();return"".concat(ef.notIdentical,"\n\n").concat(ex.join("\n"),"\n")}e_>3&&(ey="\n".concat(es,"...").concat(ed).concat(ey),em=!0),""!==ei&&(ey="\n ".concat(ei).concat(ey),ei="");var eC=0,ek=ef[en]+"\n".concat(eu,"+ actual").concat(ed," ").concat(ec,"- expected").concat(ed),eO=" ".concat(es,"...").concat(ed," Lines skipped");for(e_=0;e_1&&e_>2&&(eT>4?(ea+="\n".concat(es,"...").concat(ed),em=!0):eT>3&&(ea+="\n ".concat(ev[e_-2]),eC++),ea+="\n ".concat(ev[e_-1]),eC++),eh=e_,ei+="\n".concat(ec,"-").concat(ed," ").concat(ev[e_]),eC++;else if(ev.length1&&e_>2&&(eT>4?(ea+="\n".concat(es,"...").concat(ed),em=!0):eT>3&&(ea+="\n ".concat(eb[e_-2]),eC++),ea+="\n ".concat(eb[e_-1]),eC++),eh=e_,ea+="\n".concat(eu,"+").concat(ed," ").concat(eb[e_]),eC++;else{var eP=ev[e_],eR=eb[e_],eI=eR!==eP&&(!endsWith(eR,",")||eR.slice(0,-1)!==eP);eI&&endsWith(eP,",")&&eP.slice(0,-1)===eR&&(eI=!1,eR+=","),eI?(eT>1&&e_>2&&(eT>4?(ea+="\n".concat(es,"...").concat(ed),em=!0):eT>3&&(ea+="\n ".concat(eb[e_-2]),eC++),ea+="\n ".concat(eb[e_-1]),eC++),eh=e_,ea+="\n".concat(eu,"+").concat(ed," ").concat(eR),ei+="\n".concat(ec,"-").concat(ed," ").concat(eP),eC+=2):(ea+=ei,ei="",(1===eT||0===e_)&&(ea+="\n ".concat(eR),eC++))}if(eC>20&&e_30)for(eb[26]="".concat(es,"...").concat(ed);eb.length>27;)eb.pop();et=1===eb.length?_possibleConstructorReturn(this,_getPrototypeOf(AssertionError).call(this,"".concat(eg," ").concat(eb[0]))):_possibleConstructorReturn(this,_getPrototypeOf(AssertionError).call(this,"".concat(eg,"\n\n").concat(eb.join("\n"),"\n")))}else{var ev=inspectValue(eh),e_="",ew=ef[ei];"notDeepEqual"===ei||"notEqual"===ei?(ev="".concat(ef[ei],"\n\n").concat(ev)).length>1024&&(ev="".concat(ev.slice(0,1021),"...")):(e_="".concat(inspectValue(ey)),ev.length>512&&(ev="".concat(ev.slice(0,509),"...")),e_.length>512&&(e_="".concat(e_.slice(0,509),"...")),"deepEqual"===ei||"equal"===ei?ev="".concat(ew,"\n\n").concat(ev,"\n\nshould equal\n\n"):e_=" ".concat(ei," ").concat(e_)),et=_possibleConstructorReturn(this,_getPrototypeOf(AssertionError).call(this,"".concat(ev).concat(e_)))}return Error.stackTraceLimit=em,et.generatedMessage=!en,Object.defineProperty(_assertThisInitialized(et),"name",{value:"AssertionError [ERR_ASSERTION]",enumerable:!1,writable:!0,configurable:!0}),et.code="ERR_ASSERTION",et.actual=eh,et.expected=ey,et.operator=ei,Error.captureStackTrace&&Error.captureStackTrace(_assertThisInitialized(et),ep),et.stack,et.name="AssertionError",_possibleConstructorReturn(et)}return _inherits(AssertionError,ee),_createClass(AssertionError,[{key:"toString",value:function(){return"".concat(this.name," [").concat(this.code,"]: ").concat(this.message)}},{key:ei.custom,value:function(ee,et){return ei(this,_objectSpread({},et,{customInspect:!1,depth:0}))}}]),AssertionError}(_wrapNativeSuper(Error));ee.exports=eh},23:function(ee,et,en){"use strict";function _typeof(ee){return(_typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(ee){return typeof ee}:function(ee){return ee&&"function"==typeof Symbol&&ee.constructor===Symbol&&ee!==Symbol.prototype?"symbol":typeof ee})(ee)}function _classCallCheck(ee,et){if(!(ee instanceof et))throw TypeError("Cannot call a class as a function")}function _possibleConstructorReturn(ee,et){return et&&("object"===_typeof(et)||"function"==typeof et)?et:_assertThisInitialized(ee)}function _assertThisInitialized(ee){if(void 0===ee)throw ReferenceError("this hasn't been initialised - super() hasn't been called");return ee}function _getPrototypeOf(ee){return(_getPrototypeOf=Object.setPrototypeOf?Object.getPrototypeOf:function(ee){return ee.__proto__||Object.getPrototypeOf(ee)})(ee)}function _inherits(ee,et){if("function"!=typeof et&&null!==et)throw TypeError("Super expression must either be null or a function");ee.prototype=Object.create(et&&et.prototype,{constructor:{value:ee,writable:!0,configurable:!0}}),et&&_setPrototypeOf(ee,et)}function _setPrototypeOf(ee,et){return(_setPrototypeOf=Object.setPrototypeOf||function(ee,et){return ee.__proto__=et,ee})(ee,et)}var ei,eo,ea={};function createErrorType(ee,et,en){function getMessage(ee,en,ei){return"string"==typeof et?et:et(ee,en,ei)}en||(en=Error);var ei=function(et){function NodeError(et,en,ei){var eo;return _classCallCheck(this,NodeError),(eo=_possibleConstructorReturn(this,_getPrototypeOf(NodeError).call(this,getMessage(et,en,ei)))).code=ee,eo}return _inherits(NodeError,et),NodeError}(en);ea[ee]=ei}function oneOf(ee,et){if(!Array.isArray(ee))return"of ".concat(et," ").concat(String(ee));var en=ee.length;return(ee=ee.map(function(ee){return String(ee)}),en>2)?"one of ".concat(et," ").concat(ee.slice(0,en-1).join(", "),", or ")+ee[en-1]:2===en?"one of ".concat(et," ").concat(ee[0]," or ").concat(ee[1]):"of ".concat(et," ").concat(ee[0])}function startsWith(ee,et,en){return ee.substr(!en||en<0?0:+en,et.length)===et}function endsWith(ee,et,en){return(void 0===en||en>ee.length)&&(en=ee.length),ee.substring(en-et.length,en)===et}function includes(ee,et,en){return"number"!=typeof en&&(en=0),!(en+et.length>ee.length)&&-1!==ee.indexOf(et,en)}createErrorType("ERR_AMBIGUOUS_ARGUMENT",'The "%s" argument is ambiguous. %s',TypeError),createErrorType("ERR_INVALID_ARG_TYPE",function(ee,et,eo){if(void 0===ei&&(ei=en(167)),ei("string"==typeof ee,"'name' must be a string"),"string"==typeof et&&startsWith(et,"not ")?(ea="must not be",et=et.replace(/^not /,"")):ea="must be",endsWith(ee," argument"))es="The ".concat(ee," ").concat(ea," ").concat(oneOf(et,"type"));else{var ea,es,eu=includes(ee,".")?"property":"argument";es='The "'.concat(ee,'" ').concat(eu," ").concat(ea," ").concat(oneOf(et,"type"))}return es+". Received type ".concat(_typeof(eo))},TypeError),createErrorType("ERR_INVALID_ARG_VALUE",function(ee,et){var ei=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"is invalid";void 0===eo&&(eo=en(177));var ea=eo.inspect(et);return ea.length>128&&(ea="".concat(ea.slice(0,128),"...")),"The argument '".concat(ee,"' ").concat(ei,". Received ").concat(ea)},TypeError,RangeError),createErrorType("ERR_INVALID_RETURN_VALUE",function(ee,et,en){var ei;return ei=en&&en.constructor&&en.constructor.name?"instance of ".concat(en.constructor.name):"type ".concat(_typeof(en)),"Expected ".concat(ee,' to be returned from the "').concat(et,'"')+" function but got ".concat(ei,".")},TypeError),createErrorType("ERR_MISSING_ARGS",function(){for(var ee=arguments.length,et=Array(ee),eo=0;eo0,"At least one arg needs to be specified");var ea="The ",es=et.length;switch(et=et.map(function(ee){return'"'.concat(ee,'"')}),es){case 1:ea+="".concat(et[0]," argument");break;case 2:ea+="".concat(et[0]," and ").concat(et[1]," arguments");break;default:ea+=et.slice(0,es-1).join(", ")+", and ".concat(et[es-1]," arguments")}return"".concat(ea," must be specified")},TypeError),ee.exports.codes=ea},176:function(ee,et,en){"use strict";function _slicedToArray(ee,et){return _arrayWithHoles(ee)||_iterableToArrayLimit(ee,et)||_nonIterableRest()}function _nonIterableRest(){throw TypeError("Invalid attempt to destructure non-iterable instance")}function _iterableToArrayLimit(ee,et){var en=[],ei=!0,eo=!1,ea=void 0;try{for(var es,eu=ee[Symbol.iterator]();!(ei=(es=eu.next()).done)&&(en.push(es.value),!et||en.length!==et);ei=!0);}catch(ee){eo=!0,ea=ee}finally{try{ei||null==eu.return||eu.return()}finally{if(eo)throw ea}}return en}function _arrayWithHoles(ee){if(Array.isArray(ee))return ee}function _typeof(ee){return(_typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(ee){return typeof ee}:function(ee){return ee&&"function"==typeof Symbol&&ee.constructor===Symbol&&ee!==Symbol.prototype?"symbol":typeof ee})(ee)}var ei=void 0!==/a/g.flags,o=function(ee){var et=[];return ee.forEach(function(ee){return et.push(ee)}),et},i=function(ee){var et=[];return ee.forEach(function(ee,en){return et.push([en,ee])}),et},eo=Object.is?Object.is:en(208),ea=Object.getOwnPropertySymbols?Object.getOwnPropertySymbols:function(){return[]},es=Number.isNaN?Number.isNaN:en(718);function uncurryThis(ee){return ee.call.bind(ee)}var eu=uncurryThis(Object.prototype.hasOwnProperty),ec=uncurryThis(Object.prototype.propertyIsEnumerable),ed=uncurryThis(Object.prototype.toString),ef=en(177).types,ep=ef.isAnyArrayBuffer,eh=ef.isArrayBufferView,ey=ef.isDate,em=ef.isMap,eg=ef.isRegExp,eb=ef.isSet,ev=ef.isNativeError,e_=ef.isBoxedPrimitive,ew=ef.isNumberObject,eS=ef.isStringObject,eE=ef.isBooleanObject,eA=ef.isBigIntObject,e$=ef.isSymbolObject,ex=ef.isFloat32Array,eC=ef.isFloat64Array;function isNonIndex(ee){if(0===ee.length||ee.length>10)return!0;for(var et=0;et57)return!0}return 10===ee.length&&ee>=4294967296}function getOwnNonIndexProperties(ee){return Object.keys(ee).filter(isNonIndex).concat(ea(ee).filter(Object.prototype.propertyIsEnumerable.bind(ee)))}/*! * The buffer module from node.js, for the browser. * * @author Feross Aboukhadijeh * @license MIT */function compare(ee,et){if(ee===et)return 0;for(var en=ee.length,ei=et.length,eo=0,ea=Math.min(en,ei);eo-1?eo(en):en}},139:function(ee,et,en){"use strict";var ei=en(174),eo=en(925),ea=eo("%Function.prototype.apply%"),es=eo("%Function.prototype.call%"),eu=eo("%Reflect.apply%",!0)||ei.call(es,ea),ec=eo("%Object.getOwnPropertyDescriptor%",!0),ed=eo("%Object.defineProperty%",!0),ef=eo("%Math.max%");if(ed)try{ed({},"a",{value:1})}catch(ee){ed=null}ee.exports=function(ee){var et=eu(ei,es,arguments);return ec&&ed&&ec(et,"length").configurable&&ed(et,"length",{value:1+ef(0,ee.length-(arguments.length-1))}),et};var l=function(){return eu(ei,ea,arguments)};ed?ed(ee.exports,"apply",{value:l}):ee.exports.apply=l},69:function(ee,et,en){"use strict";var ei=en(935),eo="function"==typeof Symbol&&"symbol"==typeof Symbol("foo"),ea=Object.prototype.toString,es=Array.prototype.concat,eu=Object.defineProperty,isFunction=function(ee){return"function"==typeof ee&&"[object Function]"===ea.call(ee)},arePropertyDescriptorsSupported=function(){var ee={};try{for(var et in eu(ee,"x",{enumerable:!1,value:ee}),ee)return!1;return ee.x===ee}catch(ee){return!1}},ec=eu&&arePropertyDescriptorsSupported(),defineProperty=function(ee,et,en,ei){(!(et in ee)||isFunction(ei)&&ei())&&(ec?eu(ee,et,{configurable:!0,enumerable:!1,value:en,writable:!0}):ee[et]=en)},defineProperties=function(ee,et){var en=arguments.length>2?arguments[2]:{},ea=ei(et);eo&&(ea=es.call(ea,Object.getOwnPropertySymbols(et)));for(var eu=0;eu1&&"boolean"!=typeof et)throw new es('"allowMissing" argument must be a boolean');if(null===eE(/^%?[^%]*%?$/g,ee))throw new eo("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var en=j(ee),ei=en.length>0?en[0]:"",ea=P("%"+ei+"%",et),ec=ea.name,ed=ea.value,ef=!1,ep=ea.alias;ep&&(ei=ep[0],e_(en,ev([0,1],ep)));for(var eh=1,em=!0;eh=en.length){var e$=eu(ed,eg);ed=(em=!!e$)&&"get"in e$&&!("originalValue"in e$.get)?e$.get:ed[eg]}else em=eb(ed,eg),ed=ed[eg];em&&!ef&&(ey[ec]=ed)}}return ed}},925:function(ee,et,en){"use strict";var ei,eo=SyntaxError,ea=Function,es=TypeError,getEvalledConstructor=function(ee){try{return ea('"use strict"; return ('+ee+").constructor;")()}catch(ee){}},eu=Object.getOwnPropertyDescriptor;if(eu)try{eu({},"")}catch(ee){eu=null}var throwTypeError=function(){throw new es},ec=eu?function(){try{return arguments.callee,throwTypeError}catch(ee){try{return eu(arguments,"callee").get}catch(ee){return throwTypeError}}}():throwTypeError,ed=en(115)(),ef=en(504)(),ep=Object.getPrototypeOf||(ef?function(ee){return ee.__proto__}:null),eh={},ey="undefined"!=typeof Uint8Array&&ep?ep(Uint8Array):ei,em={"%AggregateError%":"undefined"==typeof AggregateError?ei:AggregateError,"%Array%":Array,"%ArrayBuffer%":"undefined"==typeof ArrayBuffer?ei:ArrayBuffer,"%ArrayIteratorPrototype%":ed&&ep?ep([][Symbol.iterator]()):ei,"%AsyncFromSyncIteratorPrototype%":ei,"%AsyncFunction%":eh,"%AsyncGenerator%":eh,"%AsyncGeneratorFunction%":eh,"%AsyncIteratorPrototype%":eh,"%Atomics%":"undefined"==typeof Atomics?ei:Atomics,"%BigInt%":"undefined"==typeof BigInt?ei:BigInt,"%BigInt64Array%":"undefined"==typeof BigInt64Array?ei:BigInt64Array,"%BigUint64Array%":"undefined"==typeof BigUint64Array?ei:BigUint64Array,"%Boolean%":Boolean,"%DataView%":"undefined"==typeof DataView?ei:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":Error,"%eval%":eval,"%EvalError%":EvalError,"%Float32Array%":"undefined"==typeof Float32Array?ei:Float32Array,"%Float64Array%":"undefined"==typeof Float64Array?ei:Float64Array,"%FinalizationRegistry%":"undefined"==typeof FinalizationRegistry?ei:FinalizationRegistry,"%Function%":ea,"%GeneratorFunction%":eh,"%Int8Array%":"undefined"==typeof Int8Array?ei:Int8Array,"%Int16Array%":"undefined"==typeof Int16Array?ei:Int16Array,"%Int32Array%":"undefined"==typeof Int32Array?ei:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":ed&&ep?ep(ep([][Symbol.iterator]())):ei,"%JSON%":"object"==typeof JSON?JSON:ei,"%Map%":"undefined"==typeof Map?ei:Map,"%MapIteratorPrototype%":"undefined"!=typeof Map&&ed&&ep?ep((new Map)[Symbol.iterator]()):ei,"%Math%":Math,"%Number%":Number,"%Object%":Object,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":"undefined"==typeof Promise?ei:Promise,"%Proxy%":"undefined"==typeof Proxy?ei:Proxy,"%RangeError%":RangeError,"%ReferenceError%":ReferenceError,"%Reflect%":"undefined"==typeof Reflect?ei:Reflect,"%RegExp%":RegExp,"%Set%":"undefined"==typeof Set?ei:Set,"%SetIteratorPrototype%":"undefined"!=typeof Set&&ed&&ep?ep((new Set)[Symbol.iterator]()):ei,"%SharedArrayBuffer%":"undefined"==typeof SharedArrayBuffer?ei:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":ed&&ep?ep(""[Symbol.iterator]()):ei,"%Symbol%":ed?Symbol:ei,"%SyntaxError%":eo,"%ThrowTypeError%":ec,"%TypedArray%":ey,"%TypeError%":es,"%Uint8Array%":"undefined"==typeof Uint8Array?ei:Uint8Array,"%Uint8ClampedArray%":"undefined"==typeof Uint8ClampedArray?ei:Uint8ClampedArray,"%Uint16Array%":"undefined"==typeof Uint16Array?ei:Uint16Array,"%Uint32Array%":"undefined"==typeof Uint32Array?ei:Uint32Array,"%URIError%":URIError,"%WeakMap%":"undefined"==typeof WeakMap?ei:WeakMap,"%WeakRef%":"undefined"==typeof WeakRef?ei:WeakRef,"%WeakSet%":"undefined"==typeof WeakSet?ei:WeakSet};if(ep)try{null.error}catch(ee){var eg=ep(ep(ee));em["%Error.prototype%"]=eg}var d=function doEval(ee){var et;if("%AsyncFunction%"===ee)et=getEvalledConstructor("async function () {}");else if("%GeneratorFunction%"===ee)et=getEvalledConstructor("function* () {}");else if("%AsyncGeneratorFunction%"===ee)et=getEvalledConstructor("async function* () {}");else if("%AsyncGenerator%"===ee){var en=doEval("%AsyncGeneratorFunction%");en&&(et=en.prototype)}else if("%AsyncIteratorPrototype%"===ee){var ei=doEval("%AsyncGenerator%");ei&&ep&&(et=ep(ei.prototype))}return em[ee]=et,et},eb={"%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"]},ev=en(174),e_=en(101),ew=ev.call(Function.call,Array.prototype.concat),eS=ev.call(Function.apply,Array.prototype.splice),eE=ev.call(Function.call,String.prototype.replace),eA=ev.call(Function.call,String.prototype.slice),e$=ev.call(Function.call,RegExp.prototype.exec),ex=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,eC=/\\(\\)?/g,_=function(ee){var et=eA(ee,0,1),en=eA(ee,-1);if("%"===et&&"%"!==en)throw new eo("invalid intrinsic syntax, expected closing `%`");if("%"===en&&"%"!==et)throw new eo("invalid intrinsic syntax, expected opening `%`");var ei=[];return eE(ee,ex,function(ee,et,en,eo){ei[ei.length]=en?eE(eo,eC,"$1"):et||ee}),ei},x=function(ee,et){var en,ei=ee;if(e_(eb,ei)&&(ei="%"+(en=eb[ei])[0]+"%"),e_(em,ei)){var ea=em[ei];if(ea===eh&&(ea=d(ei)),void 0===ea&&!et)throw new es("intrinsic "+ee+" exists, but is not available. Please file an issue!");return{alias:en,name:ei,value:ea}}throw new eo("intrinsic "+ee+" does not exist!")};ee.exports=function(ee,et){if("string"!=typeof ee||0===ee.length)throw new es("intrinsic name must be a non-empty string");if(arguments.length>1&&"boolean"!=typeof et)throw new es('"allowMissing" argument must be a boolean');if(null===e$(/^%?[^%]*%?$/,ee))throw new eo("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var en=_(ee),ei=en.length>0?en[0]:"",ea=x("%"+ei+"%",et),ec=ea.name,ed=ea.value,ef=!1,ep=ea.alias;ep&&(ei=ep[0],eS(en,ew([0,1],ep)));for(var eh=1,ey=!0;eh=en.length){var eE=eu(ed,eg);ed=(ey=!!eE)&&"get"in eE&&!("originalValue"in eE.get)?eE.get:ed[eg]}else ey=e_(ed,eg),ed=ed[eg];ey&&!ef&&(em[ec]=ed)}}return ed}},504:function(ee){"use strict";var et={foo:{}},en=Object;ee.exports=function(){return({__proto__:et}).foo===et.foo&&!(({__proto__:null})instanceof en)}},942:function(ee,et,en){"use strict";var ei="undefined"!=typeof Symbol&&Symbol,eo=en(773);ee.exports=function(){return"function"==typeof ei&&"function"==typeof Symbol&&"symbol"==typeof ei("foo")&&"symbol"==typeof Symbol("bar")&&eo()}},773:function(ee){"use strict";ee.exports=function(){if("function"!=typeof Symbol||"function"!=typeof Object.getOwnPropertySymbols)return!1;if("symbol"==typeof Symbol.iterator)return!0;var ee={},et=Symbol("test"),en=Object(et);if("string"==typeof et||"[object Symbol]"!==Object.prototype.toString.call(et)||"[object Symbol]"!==Object.prototype.toString.call(en))return!1;var ei=42;for(et in ee[et]=ei,ee)return!1;if("function"==typeof Object.keys&&0!==Object.keys(ee).length||"function"==typeof Object.getOwnPropertyNames&&0!==Object.getOwnPropertyNames(ee).length)return!1;var eo=Object.getOwnPropertySymbols(ee);if(1!==eo.length||eo[0]!==et||!Object.prototype.propertyIsEnumerable.call(ee,et))return!1;if("function"==typeof Object.getOwnPropertyDescriptor){var ea=Object.getOwnPropertyDescriptor(ee,et);if(ea.value!==ei||!0!==ea.enumerable)return!1}return!0}},115:function(ee,et,en){"use strict";var ei="undefined"!=typeof Symbol&&Symbol,eo=en(832);ee.exports=function(){return"function"==typeof ei&&"function"==typeof Symbol&&"symbol"==typeof ei("foo")&&"symbol"==typeof Symbol("bar")&&eo()}},832:function(ee){"use strict";ee.exports=function(){if("function"!=typeof Symbol||"function"!=typeof Object.getOwnPropertySymbols)return!1;if("symbol"==typeof Symbol.iterator)return!0;var ee={},et=Symbol("test"),en=Object(et);if("string"==typeof et||"[object Symbol]"!==Object.prototype.toString.call(et)||"[object Symbol]"!==Object.prototype.toString.call(en))return!1;var ei=42;for(et in ee[et]=ei,ee)return!1;if("function"==typeof Object.keys&&0!==Object.keys(ee).length||"function"==typeof Object.getOwnPropertyNames&&0!==Object.getOwnPropertyNames(ee).length)return!1;var eo=Object.getOwnPropertySymbols(ee);if(1!==eo.length||eo[0]!==et||!Object.prototype.propertyIsEnumerable.call(ee,et))return!1;if("function"==typeof Object.getOwnPropertyDescriptor){var ea=Object.getOwnPropertyDescriptor(ee,et);if(ea.value!==ei||!0!==ea.enumerable)return!1}return!0}},101:function(ee,et,en){"use strict";var ei=en(174);ee.exports=ei.call(Function.call,Object.prototype.hasOwnProperty)},782:function(ee){"function"==typeof Object.create?ee.exports=function(ee,et){et&&(ee.super_=et,ee.prototype=Object.create(et.prototype,{constructor:{value:ee,enumerable:!1,writable:!0,configurable:!0}}))}:ee.exports=function(ee,et){if(et){ee.super_=et;var TempCtor=function(){};TempCtor.prototype=et.prototype,ee.prototype=new TempCtor,ee.prototype.constructor=ee}}},157:function(ee){"use strict";var et="function"==typeof Symbol&&"symbol"==typeof Symbol.toStringTag,en=Object.prototype.toString,n=function(ee){return(!et||!ee||"object"!=typeof ee||!(Symbol.toStringTag in ee))&&"[object Arguments]"===en.call(ee)},o=function(ee){return!!n(ee)||null!==ee&&"object"==typeof ee&&"number"==typeof ee.length&&ee.length>=0&&"[object Array]"!==en.call(ee)&&"[object Function]"===en.call(ee.callee)},ei=function(){return n(arguments)}();n.isLegacyArguments=o,ee.exports=ei?n:o},391:function(ee){"use strict";var et=Object.prototype.toString,en=Function.prototype.toString,ei=/^\s*(?:function)?\*/,eo="function"==typeof Symbol&&"symbol"==typeof Symbol.toStringTag,ea=Object.getPrototypeOf,es=function(){if(!eo)return!1;try{return Function("return function*() {}")()}catch(ee){}}(),eu=es?ea(es):{};ee.exports=function(ee){return"function"==typeof ee&&(!!ei.test(en.call(ee))||(eo?ea(ee)===eu:"[object GeneratorFunction]"===et.call(ee)))}},460:function(ee){"use strict";ee.exports=function(ee){return ee!=ee}},718:function(ee,et,en){"use strict";var ei=en(139),eo=en(69),ea=en(460),es=en(625),eu=en(171),ec=ei(es(),Number);eo(ec,{getPolyfill:es,implementation:ea,shim:eu}),ee.exports=ec},625:function(ee,et,en){"use strict";var ei=en(460);ee.exports=function(){return Number.isNaN&&Number.isNaN(NaN)&&!Number.isNaN("a")?Number.isNaN:ei}},171:function(ee,et,en){"use strict";var ei=en(69),eo=en(625);ee.exports=function(){var ee=eo();return ei(Number,{isNaN:ee},{isNaN:function(){return Number.isNaN!==ee}}),ee}},994:function(ee,et,ei){"use strict";var eo=ei(144),ea=ei(349),es=ei(256),eu=es("Object.prototype.toString"),ec=ei(942)()&&"symbol"==typeof Symbol.toStringTag,ed=ea(),ef=es("Array.prototype.indexOf",!0)||function(ee,et){for(var en=0;en-1)}},208:function(ee){"use strict";var numberIsNaN=function(ee){return ee!=ee};ee.exports=function(ee,et){return 0===ee&&0===et?1/ee==1/et:!!(ee===et||numberIsNaN(ee)&&numberIsNaN(et))}},579:function(ee,et,en){"use strict";var ei;if(!Object.keys){var eo=Object.prototype.hasOwnProperty,ea=Object.prototype.toString,es=en(412),eu=Object.prototype.propertyIsEnumerable,ec=!eu.call({toString:null},"toString"),ed=eu.call(function(){},"prototype"),ef=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"],equalsConstructorPrototype=function(ee){var et=ee.constructor;return et&&et.prototype===ee},ep={$applicationCache:!0,$console:!0,$external:!0,$frame:!0,$frameElement:!0,$frames:!0,$innerHeight:!0,$innerWidth:!0,$onmozfullscreenchange:!0,$onmozfullscreenerror:!0,$outerHeight:!0,$outerWidth:!0,$pageXOffset:!0,$pageYOffset:!0,$parent:!0,$scrollLeft:!0,$scrollTop:!0,$scrollX:!0,$scrollY:!0,$self:!0,$webkitIndexedDB:!0,$webkitStorageInfo:!0,$window:!0},eh=function(){if("undefined"==typeof window)return!1;for(var ee in window)try{if(!ep["$"+ee]&&eo.call(window,ee)&&null!==window[ee]&&"object"==typeof window[ee])try{equalsConstructorPrototype(window[ee])}catch(ee){return!0}}catch(ee){return!0}return!1}(),equalsConstructorPrototypeIfNotBuggy=function(ee){if("undefined"==typeof window||!eh)return equalsConstructorPrototype(ee);try{return equalsConstructorPrototype(ee)}catch(ee){return!1}};ei=function(ee){var et=null!==ee&&"object"==typeof ee,en="[object Function]"===ea.call(ee),ei=es(ee),eu=et&&"[object String]"===ea.call(ee),ep=[];if(!et&&!en&&!ei)throw TypeError("Object.keys called on a non-object");var eh=ed&&en;if(eu&&ee.length>0&&!eo.call(ee,0))for(var ey=0;ey0)for(var em=0;em=0&&"[object Function]"===et.call(ee.callee)),ei}},369:function(ee){ee.exports=function(ee){return ee instanceof ea}},584:function(ee,et,en){"use strict";var ei=en(157),eo=en(391),ea=en(490),es=en(994);function uncurryThis(ee){return ee.call.bind(ee)}var eu="undefined"!=typeof BigInt,ec="undefined"!=typeof Symbol,ed=uncurryThis(Object.prototype.toString),ef=uncurryThis(Number.prototype.valueOf),ep=uncurryThis(String.prototype.valueOf),eh=uncurryThis(Boolean.prototype.valueOf);if(eu)var ey=uncurryThis(BigInt.prototype.valueOf);if(ec)var em=uncurryThis(Symbol.prototype.valueOf);function checkBoxedPrimitive(ee,et){if("object"!=typeof ee)return!1;try{return et(ee),!0}catch(ee){return!1}}function isPromise(ee){return"undefined"!=typeof Promise&&ee instanceof Promise||null!==ee&&"object"==typeof ee&&"function"==typeof ee.then&&"function"==typeof ee.catch}function isArrayBufferView(ee){return"undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(ee):es(ee)||isDataView(ee)}function isUint8Array(ee){return"Uint8Array"===ea(ee)}function isUint8ClampedArray(ee){return"Uint8ClampedArray"===ea(ee)}function isUint16Array(ee){return"Uint16Array"===ea(ee)}function isUint32Array(ee){return"Uint32Array"===ea(ee)}function isInt8Array(ee){return"Int8Array"===ea(ee)}function isInt16Array(ee){return"Int16Array"===ea(ee)}function isInt32Array(ee){return"Int32Array"===ea(ee)}function isFloat32Array(ee){return"Float32Array"===ea(ee)}function isFloat64Array(ee){return"Float64Array"===ea(ee)}function isBigInt64Array(ee){return"BigInt64Array"===ea(ee)}function isBigUint64Array(ee){return"BigUint64Array"===ea(ee)}function isMapToString(ee){return"[object Map]"===ed(ee)}function isMap(ee){return"undefined"!=typeof Map&&(isMapToString.working?isMapToString(ee):ee instanceof Map)}function isSetToString(ee){return"[object Set]"===ed(ee)}function isSet(ee){return"undefined"!=typeof Set&&(isSetToString.working?isSetToString(ee):ee instanceof Set)}function isWeakMapToString(ee){return"[object WeakMap]"===ed(ee)}function isWeakMap(ee){return"undefined"!=typeof WeakMap&&(isWeakMapToString.working?isWeakMapToString(ee):ee instanceof WeakMap)}function isWeakSetToString(ee){return"[object WeakSet]"===ed(ee)}function isWeakSet(ee){return isWeakSetToString(ee)}function isArrayBufferToString(ee){return"[object ArrayBuffer]"===ed(ee)}function isArrayBuffer(ee){return"undefined"!=typeof ArrayBuffer&&(isArrayBufferToString.working?isArrayBufferToString(ee):ee instanceof ArrayBuffer)}function isDataViewToString(ee){return"[object DataView]"===ed(ee)}function isDataView(ee){return"undefined"!=typeof DataView&&(isDataViewToString.working?isDataViewToString(ee):ee instanceof DataView)}et.isArgumentsObject=ei,et.isGeneratorFunction=eo,et.isTypedArray=es,et.isPromise=isPromise,et.isArrayBufferView=isArrayBufferView,et.isUint8Array=isUint8Array,et.isUint8ClampedArray=isUint8ClampedArray,et.isUint16Array=isUint16Array,et.isUint32Array=isUint32Array,et.isInt8Array=isInt8Array,et.isInt16Array=isInt16Array,et.isInt32Array=isInt32Array,et.isFloat32Array=isFloat32Array,et.isFloat64Array=isFloat64Array,et.isBigInt64Array=isBigInt64Array,et.isBigUint64Array=isBigUint64Array,isMapToString.working="undefined"!=typeof Map&&isMapToString(new Map),et.isMap=isMap,isSetToString.working="undefined"!=typeof Set&&isSetToString(new Set),et.isSet=isSet,isWeakMapToString.working="undefined"!=typeof WeakMap&&isWeakMapToString(new WeakMap),et.isWeakMap=isWeakMap,isWeakSetToString.working="undefined"!=typeof WeakSet&&isWeakSetToString(new WeakSet),et.isWeakSet=isWeakSet,isArrayBufferToString.working="undefined"!=typeof ArrayBuffer&&isArrayBufferToString(new ArrayBuffer),et.isArrayBuffer=isArrayBuffer,isDataViewToString.working="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof DataView&&isDataViewToString(new DataView(new ArrayBuffer(1),0,1)),et.isDataView=isDataView;var eg="undefined"!=typeof SharedArrayBuffer?SharedArrayBuffer:void 0;function isSharedArrayBufferToString(ee){return"[object SharedArrayBuffer]"===ed(ee)}function isSharedArrayBuffer(ee){return void 0!==eg&&(void 0===isSharedArrayBufferToString.working&&(isSharedArrayBufferToString.working=isSharedArrayBufferToString(new eg)),isSharedArrayBufferToString.working?isSharedArrayBufferToString(ee):ee instanceof eg)}function isAsyncFunction(ee){return"[object AsyncFunction]"===ed(ee)}function isMapIterator(ee){return"[object Map Iterator]"===ed(ee)}function isSetIterator(ee){return"[object Set Iterator]"===ed(ee)}function isGeneratorObject(ee){return"[object Generator]"===ed(ee)}function isWebAssemblyCompiledModule(ee){return"[object WebAssembly.Module]"===ed(ee)}function isNumberObject(ee){return checkBoxedPrimitive(ee,ef)}function isStringObject(ee){return checkBoxedPrimitive(ee,ep)}function isBooleanObject(ee){return checkBoxedPrimitive(ee,eh)}function isBigIntObject(ee){return eu&&checkBoxedPrimitive(ee,ey)}function isSymbolObject(ee){return ec&&checkBoxedPrimitive(ee,em)}function isBoxedPrimitive(ee){return isNumberObject(ee)||isStringObject(ee)||isBooleanObject(ee)||isBigIntObject(ee)||isSymbolObject(ee)}function isAnyArrayBuffer(ee){return"undefined"!=typeof Uint8Array&&(isArrayBuffer(ee)||isSharedArrayBuffer(ee))}et.isSharedArrayBuffer=isSharedArrayBuffer,et.isAsyncFunction=isAsyncFunction,et.isMapIterator=isMapIterator,et.isSetIterator=isSetIterator,et.isGeneratorObject=isGeneratorObject,et.isWebAssemblyCompiledModule=isWebAssemblyCompiledModule,et.isNumberObject=isNumberObject,et.isStringObject=isStringObject,et.isBooleanObject=isBooleanObject,et.isBigIntObject=isBigIntObject,et.isSymbolObject=isSymbolObject,et.isBoxedPrimitive=isBoxedPrimitive,et.isAnyArrayBuffer=isAnyArrayBuffer,["isProxy","isExternal","isModuleNamespaceObject"].forEach(function(ee){Object.defineProperty(et,ee,{enumerable:!1,value:function(){throw Error(ee+" is not supported in userland")}})})},177:function(ee,et,en){var ei=Object.getOwnPropertyDescriptors||function(ee){for(var et=Object.keys(ee),en={},ei=0;ei=eo)return ee;switch(ee){case"%s":return String(ei[en++]);case"%d":return Number(ei[en++]);case"%j":try{return JSON.stringify(ei[en++])}catch(ee){return"[Circular]"}default:return ee}}),eu=ei[en];en=3&&(ei.depth=arguments[2]),arguments.length>=4&&(ei.colors=arguments[3]),isBoolean(en)?ei.showHidden=en:en&&et._extend(ei,en),isUndefined(ei.showHidden)&&(ei.showHidden=!1),isUndefined(ei.depth)&&(ei.depth=2),isUndefined(ei.colors)&&(ei.colors=!1),isUndefined(ei.customInspect)&&(ei.customInspect=!0),ei.colors&&(ei.stylize=stylizeWithColor),formatValue(ei,ee,ei.depth)}function stylizeWithColor(ee,et){var en=inspect.styles[et];return en?"\x1b["+inspect.colors[en][0]+"m"+ee+"\x1b["+inspect.colors[en][1]+"m":ee}function stylizeNoColor(ee,et){return ee}function arrayToHash(ee){var et={};return ee.forEach(function(ee,en){et[ee]=!0}),et}function formatValue(ee,en,ei){if(ee.customInspect&&en&&isFunction(en.inspect)&&en.inspect!==et.inspect&&!(en.constructor&&en.constructor.prototype===en)){var eo,ea=en.inspect(ei,ee);return isString(ea)||(ea=formatValue(ee,ea,ei)),ea}var es=formatPrimitive(ee,en);if(es)return es;var eu=Object.keys(en),ec=arrayToHash(eu);if(ee.showHidden&&(eu=Object.getOwnPropertyNames(en)),isError(en)&&(eu.indexOf("message")>=0||eu.indexOf("description")>=0))return formatError(en);if(0===eu.length){if(isFunction(en)){var ed=en.name?": "+en.name:"";return ee.stylize("[Function"+ed+"]","special")}if(isRegExp(en))return ee.stylize(RegExp.prototype.toString.call(en),"regexp");if(isDate(en))return ee.stylize(Date.prototype.toString.call(en),"date");if(isError(en))return formatError(en)}var ef="",ep=!1,eh=["{","}"];return(isArray(en)&&(ep=!0,eh=["[","]"]),isFunction(en)&&(ef=" [Function"+(en.name?": "+en.name:"")+"]"),isRegExp(en)&&(ef=" "+RegExp.prototype.toString.call(en)),isDate(en)&&(ef=" "+Date.prototype.toUTCString.call(en)),isError(en)&&(ef=" "+formatError(en)),0!==eu.length||ep&&0!=en.length)?ei<0?isRegExp(en)?ee.stylize(RegExp.prototype.toString.call(en),"regexp"):ee.stylize("[Object]","special"):(ee.seen.push(en),eo=ep?formatArray(ee,en,ei,ec,eu):eu.map(function(et){return formatProperty(ee,en,ei,ec,et,ep)}),ee.seen.pop(),reduceToSingleString(eo,ef,eh)):eh[0]+ef+eh[1]}function formatPrimitive(ee,et){if(isUndefined(et))return ee.stylize("undefined","undefined");if(isString(et)){var en="'"+JSON.stringify(et).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return ee.stylize(en,"string")}return isNumber(et)?ee.stylize(""+et,"number"):isBoolean(et)?ee.stylize(""+et,"boolean"):isNull(et)?ee.stylize("null","null"):void 0}function formatError(ee){return"["+Error.prototype.toString.call(ee)+"]"}function formatArray(ee,et,en,ei,eo){for(var ea=[],es=0,eu=et.length;esee.seen.indexOf(ec.value)?(eu=isNull(en)?formatValue(ee,ec.value,null):formatValue(ee,ec.value,en-1)).indexOf("\n")>-1&&(eu=ea?eu.split("\n").map(function(ee){return" "+ee}).join("\n").substr(2):"\n"+eu.split("\n").map(function(ee){return" "+ee}).join("\n")):eu=ee.stylize("[Circular]","special")),isUndefined(es)){if(ea&&eo.match(/^\d+$/))return eu;(es=JSON.stringify(""+eo)).match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(es=es.substr(1,es.length-2),es=ee.stylize(es,"name")):(es=es.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),es=ee.stylize(es,"string"))}return es+": "+eu}function reduceToSingleString(ee,et,en){var ei=0;return ee.reduce(function(ee,et){return ei++,et.indexOf("\n")>=0&&ei++,ee+et.replace(/\u001b\[\d\d?m/g,"").length+1},0)>60?en[0]+(""===et?"":et+"\n ")+" "+ee.join(",\n ")+" "+en[1]:en[0]+et+" "+ee.join(", ")+" "+en[1]}function isArray(ee){return Array.isArray(ee)}function isBoolean(ee){return"boolean"==typeof ee}function isNull(ee){return null===ee}function isNullOrUndefined(ee){return null==ee}function isNumber(ee){return"number"==typeof ee}function isString(ee){return"string"==typeof ee}function isSymbol(ee){return"symbol"==typeof ee}function isUndefined(ee){return void 0===ee}function isRegExp(ee){return isObject(ee)&&"[object RegExp]"===objectToString(ee)}function isObject(ee){return"object"==typeof ee&&null!==ee}function isDate(ee){return isObject(ee)&&"[object Date]"===objectToString(ee)}function isError(ee){return isObject(ee)&&("[object Error]"===objectToString(ee)||ee instanceof Error)}function isFunction(ee){return"function"==typeof ee}function isPrimitive(ee){return null===ee||"boolean"==typeof ee||"number"==typeof ee||"string"==typeof ee||"symbol"==typeof ee||void 0===ee}function objectToString(ee){return Object.prototype.toString.call(ee)}function pad(ee){return ee<10?"0"+ee.toString(10):ee.toString(10)}et.debuglog=function(ee){if(!es[ee=ee.toUpperCase()]){if(eu.test(ee)){var en=eo.pid;es[ee]=function(){var ei=et.format.apply(et,arguments);console.error("%s %d: %s",ee,en,ei)}}else es[ee]=function(){}}return es[ee]},et.inspect=inspect,inspect.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},inspect.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"},et.types=en(584),et.isArray=isArray,et.isBoolean=isBoolean,et.isNull=isNull,et.isNullOrUndefined=isNullOrUndefined,et.isNumber=isNumber,et.isString=isString,et.isSymbol=isSymbol,et.isUndefined=isUndefined,et.isRegExp=isRegExp,et.types.isRegExp=isRegExp,et.isObject=isObject,et.isDate=isDate,et.types.isDate=isDate,et.isError=isError,et.types.isNativeError=isError,et.isFunction=isFunction,et.isPrimitive=isPrimitive,et.isBuffer=en(369);var ed=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function timestamp(){var ee=new Date,et=[pad(ee.getHours()),pad(ee.getMinutes()),pad(ee.getSeconds())].join(":");return[ee.getDate(),ed[ee.getMonth()],et].join(" ")}function hasOwnProperty(ee,et){return Object.prototype.hasOwnProperty.call(ee,et)}et.log=function(){console.log("%s - %s",timestamp(),et.format.apply(et,arguments))},et.inherits=en(782),et._extend=function(ee,et){if(!et||!isObject(et))return ee;for(var en=Object.keys(et),ei=en.length;ei--;)ee[en[ei]]=et[en[ei]];return ee};var ef="undefined"!=typeof Symbol?Symbol("util.promisify.custom"):void 0;function callbackifyOnRejected(ee,et){if(!ee){var en=Error("Promise was rejected with a falsy value");en.reason=ee,ee=en}return et(ee)}function callbackify(ee){if("function"!=typeof ee)throw TypeError('The "original" argument must be of type Function');function callbackified(){for(var et=[],en=0;en0&&es.length>eo&&!es.warned){es.warned=!0;var eo,ea,es,eu=Error("Possible EventEmitter memory leak detected. "+es.length+" "+String(et)+" listeners added. Use emitter.setMaxListeners() to increase limit");eu.name="MaxListenersExceededWarning",eu.emitter=ee,eu.type=et,eu.count=es.length,ProcessEmitWarning(eu)}return ee}function onceWrapper(){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 _onceWrap(ee,et,en){var ei={fired:!1,wrapFn:void 0,target:ee,type:et,listener:en},eo=onceWrapper.bind(ei);return eo.listener=en,ei.wrapFn=eo,eo}function _listeners(ee,et,en){var ei=ee._events;if(void 0===ei)return[];var eo=ei[et];return void 0===eo?[]:"function"==typeof eo?en?[eo.listener||eo]:[eo]:en?unwrapListeners(eo):arrayClone(eo,eo.length)}function listenerCount(ee){var et=this._events;if(void 0!==et){var en=et[ee];if("function"==typeof en)return 1;if(void 0!==en)return en.length}return 0}function arrayClone(ee,et){for(var en=Array(et),ei=0;ei0&&(es=et[0]),es instanceof Error)throw es;var es,eu=Error("Unhandled error."+(es?" ("+es.message+")":""));throw eu.context=es,eu}var ec=ea[ee];if(void 0===ec)return!1;if("function"==typeof ec)ei(ec,this,et);else for(var ed=ec.length,ef=arrayClone(ec,ed),en=0;en=0;ea--)if(en[ea]===et||en[ea].listener===et){es=en[ea].listener,eo=ea;break}if(eo<0)return this;0===eo?en.shift():spliceOne(en,eo),1===en.length&&(ei[ee]=en[0]),void 0!==ei.removeListener&&this.emit("removeListener",ee,es||et)}return this},EventEmitter.prototype.off=EventEmitter.prototype.removeListener,EventEmitter.prototype.removeAllListeners=function(ee){var et,en,ei;if(void 0===(en=this._events))return this;if(void 0===en.removeListener)return 0==arguments.length?(this._events=Object.create(null),this._eventsCount=0):void 0!==en[ee]&&(0==--this._eventsCount?this._events=Object.create(null):delete en[ee]),this;if(0==arguments.length){var eo,ea=Object.keys(en);for(ei=0;ei=0;ei--)this.removeListener(ee,et[ei]);return this},EventEmitter.prototype.listeners=function(ee){return _listeners(this,ee,!0)},EventEmitter.prototype.rawListeners=function(ee){return _listeners(this,ee,!1)},EventEmitter.listenerCount=function(ee,et){return"function"==typeof ee.listenerCount?ee.listenerCount(et):listenerCount.call(ee,et)},EventEmitter.prototype.listenerCount=listenerCount,EventEmitter.prototype.eventNames=function(){return this._eventsCount>0?et(this._events):[]}}},ei={};function __nccwpck_require__(ee){var et=ei[ee];if(void 0!==et)return et.exports;var eo=ei[ee]={exports:{}},ea=!0;try{en[ee](eo,eo.exports,__nccwpck_require__),ea=!1}finally{ea&&delete ei[ee]}return eo.exports}__nccwpck_require__.ab=et+"/";var eo=__nccwpck_require__(864);ee.exports=eo}()},78428:function(ee,et,en){var ei="/";!function(){var et={528:function(ee,et,en){var ei=en(685),eo=en(310),ea=ee.exports;for(var es in ei)ei.hasOwnProperty(es)&&(ea[es]=ei[es]);function validateParams(ee){if("string"==typeof ee&&(ee=eo.parse(ee)),ee.protocol||(ee.protocol="https:"),"https:"!==ee.protocol)throw Error('Protocol "'+ee.protocol+'" not supported. Expected "https:"');return ee}ea.request=function(ee,et){return ee=validateParams(ee),ei.request.call(this,ee,et)},ea.get=function(ee,et){return ee=validateParams(ee),ei.get.call(this,ee,et)}},685:function(ee){"use strict";ee.exports=en(22321)},310:function(ee){"use strict";ee.exports=en(11987)}},eo={};function __nccwpck_require__(ee){var en=eo[ee];if(void 0!==en)return en.exports;var ei=eo[ee]={exports:{}},ea=!0;try{et[ee](ei,ei.exports,__nccwpck_require__),ea=!1}finally{ea&&delete eo[ee]}return ei.exports}__nccwpck_require__.ab=ei+"/";var ea=__nccwpck_require__(528);ee.exports=ea}()},11987:function(ee,et,en){var ei="/";!function(){var et={452:function(ee){"use strict";ee.exports=en(97334)}},eo={};function __nccwpck_require__(ee){var en=eo[ee];if(void 0!==en)return en.exports;var ei=eo[ee]={exports:{}},ea=!0;try{et[ee](ei,ei.exports,__nccwpck_require__),ea=!1}finally{ea&&delete eo[ee]}return ei.exports}__nccwpck_require__.ab=ei+"/";var ea={};!function(){var ee,et=ea,en=(ee=__nccwpck_require__(452))&&"object"==typeof ee&&"default"in ee?ee.default:ee,ei=/https?|ftp|gopher|file/;function r(ee){"string"==typeof ee&&(ee=d(ee));var et=function(ee,et,en){var ei=ee.auth,eo=ee.hostname,ea=ee.protocol||"",es=ee.pathname||"",eu=ee.hash||"",ec=ee.query||"",ed=!1;ei=ei?encodeURIComponent(ei).replace(/%3A/i,":")+"@":"",ee.host?ed=ei+ee.host:eo&&(ed=ei+(~eo.indexOf(":")?"["+eo+"]":eo),ee.port&&(ed+=":"+ee.port)),ec&&"object"==typeof ec&&(ec=et.encode(ec));var ef=ee.search||ec&&"?"+ec||"";return ea&&":"!==ea.substr(-1)&&(ea+=":"),ee.slashes||(!ea||en.test(ea))&&!1!==ed?(ed="//"+(ed||""),es&&"/"!==es[0]&&(es="/"+es)):ed||(ed=""),eu&&"#"!==eu[0]&&(eu="#"+eu),ef&&"?"!==ef[0]&&(ef="?"+ef),{protocol:ea,host:ed,pathname:es=es.replace(/[?#]/g,encodeURIComponent),search:ef=ef.replace("#","%23"),hash:eu}}(ee,en,ei);return""+et.protocol+et.host+et.pathname+et.search+et.hash}var eo="http://",es="w.w",eu=eo+es,ec=/^([a-z0-9.+-]*:\/\/\/)([a-z0-9.+-]:\/*)?/i,ed=/https?|ftp|gopher|file/;function h(ee,et){var en="string"==typeof ee?d(ee):ee;ee="object"==typeof ee?r(ee):ee;var ei=d(et),ea="";en.protocol&&!en.slashes&&(ea=en.protocol,ee=ee.replace(en.protocol,""),ea+="/"===et[0]||"/"===ee[0]?"/":""),ea&&ei.protocol&&(ea="",ei.slashes||(ea=ei.protocol,et=et.replace(ei.protocol,"")));var es=ee.match(ec);es&&!ei.protocol&&(ee=ee.substr((ea=es[1]+(es[2]||"")).length),/^\/\/[^/]/.test(et)&&(ea=ea.slice(0,-1)));var ef=new URL(ee,eu+"/"),ep=new URL(et,ef).toString().replace(eu,""),eh=ei.protocol||en.protocol;return eh+=en.slashes||ei.slashes?"//":"",!ea&&eh?ep=ep.replace(eo,eh):ea&&(ep=ep.replace(eo,"")),ed.test(ep)||~et.indexOf(".")||"/"===ee.slice(-1)||"/"===et.slice(-1)||"/"!==ep.slice(-1)||(ep=ep.slice(0,-1)),ea&&(ep=ea+("/"===ep[0]?ep.substr(1):ep)),ep}function l(){}l.prototype.parse=d,l.prototype.format=r,l.prototype.resolve=h,l.prototype.resolveObject=h;var ef=/^https?|ftp|gopher|file/,ep=/^(.*?)([#?].*)/,eh=/^([a-z0-9.+-]*:)(\/{0,3})(.*)/i,ey=/^([a-z0-9.+-]*:)?\/\/\/*/i,em=/^([a-z0-9.+-]*:)(\/{0,2})\[(.*)\]$/i;function d(ee,et,ei){if(void 0===et&&(et=!1),void 0===ei&&(ei=!1),ee&&"object"==typeof ee&&ee instanceof l)return ee;var eo=(ee=ee.trim()).match(ep);ee=eo?eo[1].replace(/\\/g,"/")+eo[2]:ee.replace(/\\/g,"/"),em.test(ee)&&"/"!==ee.slice(-1)&&(ee+="/");var ea=!/(^javascript)/.test(ee)&&ee.match(eh),ec=ey.test(ee),ed="";ea&&(ef.test(ea[1])||(ed=ea[1].toLowerCase(),ee=""+ea[2]+ea[3]),ea[2]||(ec=!1,ef.test(ea[1])?(ed=ea[1],ee=""+ea[3]):ee="//"+ea[3]),3!==ea[2].length&&1!==ea[2].length||(ed=ea[1],ee="/"+ea[3]));var eg,eb=(eo?eo[1]:ee).match(/^https?:\/\/[^/]+(:[0-9]+)(?=\/|$)/),ev=eb&&eb[1],e_=new l,ew="",eS="";try{eg=new URL(ee)}catch(et){ew=et,ed||ei||!/^\/\//.test(ee)||/^\/\/.+[@.]/.test(ee)||(eS="/",ee=ee.substr(1));try{eg=new URL(ee,eu)}catch(ee){return e_.protocol=ed,e_.href=ed,e_}}e_.slashes=ec&&!eS,e_.host=eg.host===es?"":eg.host,e_.hostname=eg.hostname===es?"":eg.hostname.replace(/(\[|\])/g,""),e_.protocol=ew?ed||null:eg.protocol,e_.search=eg.search.replace(/\\/g,"%5C"),e_.hash=eg.hash.replace(/\\/g,"%5C");var eE=ee.split("#");!e_.search&&~eE[0].indexOf("?")&&(e_.search="?"),e_.hash||""!==eE[1]||(e_.hash="#"),e_.query=et?en.decode(eg.search.substr(1)):e_.search.substr(1),e_.pathname=eS+(ea?function(ee){return ee.replace(/['^|`]/g,function(ee){return"%"+ee.charCodeAt().toString(16).toUpperCase()}).replace(/((?:%[0-9A-F]{2})+)/g,function(ee,et){try{return decodeURIComponent(et).split("").map(function(ee){var et=ee.charCodeAt();return et>256||/^[a-z0-9]$/i.test(ee)?ee:"%"+et.toString(16).toUpperCase()}).join("")}catch(ee){return et}})}(eg.pathname):eg.pathname),"about:"===e_.protocol&&"blank"===e_.pathname&&(e_.protocol="",e_.pathname=""),ew&&"/"!==ee[0]&&(e_.pathname=e_.pathname.substr(1)),ed&&!ef.test(ed)&&"/"!==ee.slice(-1)&&"/"===e_.pathname&&(e_.pathname=""),e_.path=e_.pathname+e_.search,e_.auth=[eg.username,eg.password].map(decodeURIComponent).filter(Boolean).join(":"),e_.port=eg.port,ev&&!e_.host.endsWith(ev)&&(e_.host+=ev,e_.port=ev.slice(1)),e_.href=eS?""+e_.pathname+e_.search+e_.hash:r(e_);var eA=/^(file)/.test(e_.href)?["host","hostname"]:[];return Object.keys(e_).forEach(function(ee){~eA.indexOf(ee)||(e_[ee]=e_[ee]||null)}),e_}et.parse=d,et.format=r,et.resolve=h,et.resolveObject=function(ee,et){return d(h(ee,et))},et.Url=l}(),ee.exports=ea}()},97334:function(ee){var et="/";!function(){"use strict";var en={815:function(ee){function hasOwnProperty(ee,et){return Object.prototype.hasOwnProperty.call(ee,et)}ee.exports=function(ee,en,ei,eo){en=en||"&",ei=ei||"=";var ea={};if("string"!=typeof ee||0===ee.length)return ea;var es=/\+/g;ee=ee.split(en);var eu=1e3;eo&&"number"==typeof eo.maxKeys&&(eu=eo.maxKeys);var ec=ee.length;eu>0&&ec>eu&&(ec=eu);for(var ed=0;ed=0?(ef=em.substr(0,eg),ep=em.substr(eg+1)):(ef=em,ep=""),eh=decodeURIComponent(ef),ey=decodeURIComponent(ep),hasOwnProperty(ea,eh)?et(ea[eh])?ea[eh].push(ey):ea[eh]=[ea[eh],ey]:ea[eh]=ey}return ea};var et=Array.isArray||function(ee){return"[object Array]"===Object.prototype.toString.call(ee)}},577:function(ee){var stringifyPrimitive=function(ee){switch(typeof ee){case"string":return ee;case"boolean":return ee?"true":"false";case"number":return isFinite(ee)?ee:"";default:return""}};ee.exports=function(ee,ei,eo,ea){return(ei=ei||"&",eo=eo||"=",null===ee&&(ee=void 0),"object"==typeof ee)?map(en(ee),function(en){var ea=encodeURIComponent(stringifyPrimitive(en))+eo;return et(ee[en])?map(ee[en],function(ee){return ea+encodeURIComponent(stringifyPrimitive(ee))}).join(ei):ea+encodeURIComponent(stringifyPrimitive(ee[en]))}).join(ei):ea?encodeURIComponent(stringifyPrimitive(ea))+eo+encodeURIComponent(stringifyPrimitive(ee)):""};var et=Array.isArray||function(ee){return"[object Array]"===Object.prototype.toString.call(ee)};function map(ee,et){if(ee.map)return ee.map(et);for(var en=[],ei=0;eiString(ee)),en>2)?`one of ${et} ${ee.slice(0,en-1).join(", ")}, or `+ee[en-1]:2===en?`one of ${et} ${ee[0]} or ${ee[1]}`:`of ${et} ${ee[0]}`}}function startsWith(ee,et,en){return ee.substr(!en||en<0?0:+en,et.length)===et}function endsWith(ee,et,en){return(void 0===en||en>ee.length)&&(en=ee.length),ee.substring(en-et.length,en)===et}function includes(ee,et,en){return"number"!=typeof en&&(en=0),!(en+et.length>ee.length)&&-1!==ee.indexOf(et,en)}createErrorType("ERR_INVALID_OPT_VALUE",function(ee,et){return'The value "'+et+'" is invalid for option "'+ee+'"'},TypeError),createErrorType("ERR_INVALID_ARG_TYPE",function(ee,et,en){let ei,eo;if("string"==typeof et&&startsWith(et,"not ")?(ei="must not be",et=et.replace(/^not /,"")):ei="must be",endsWith(ee," argument"))eo=`The ${ee} ${ei} ${oneOf(et,"type")}`;else{let en=includes(ee,".")?"property":"argument";eo=`The "${ee}" ${en} ${ei} ${oneOf(et,"type")}`}return eo+`. Received type ${typeof en}`},TypeError),createErrorType("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),createErrorType("ERR_METHOD_NOT_IMPLEMENTED",function(ee){return"The "+ee+" method is not implemented"}),createErrorType("ERR_STREAM_PREMATURE_CLOSE","Premature close"),createErrorType("ERR_STREAM_DESTROYED",function(ee){return"Cannot call "+ee+" after a stream was destroyed"}),createErrorType("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),createErrorType("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),createErrorType("ERR_STREAM_WRITE_AFTER_END","write after end"),createErrorType("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),createErrorType("ERR_UNKNOWN_ENCODING",function(ee){return"Unknown encoding: "+ee},TypeError),createErrorType("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),ee.exports.q=et},403:function(ee,et,en){"use strict";var ei=Object.keys||function(ee){var et=[];for(var en in ee)et.push(en);return et};ee.exports=Duplex;var ea=en(709),es=en(337);en(782)(Duplex,ea);for(var eu=ei(es.prototype),ec=0;ec0){if("string"==typeof et||eu.objectMode||Object.getPrototypeOf(et)===ep.prototype||(et=_uint8ArrayToBuffer(et)),ei)eu.endEmitted?eA(ee,new eE):addChunk(ee,eu,et,!0);else if(eu.ended)eA(ee,new ew);else{if(eu.destroyed)return!1;eu.reading=!1,eu.decoder&&!en?(et=eu.decoder.write(et),eu.objectMode||0!==et.length?addChunk(ee,eu,et,!1):maybeReadMore(ee,eu)):addChunk(ee,eu,et,!1)}}else ei||(eu.reading=!1,maybeReadMore(ee,eu));return!eu.ended&&(eu.length=ex?ee=ex:(ee--,ee|=ee>>>1,ee|=ee>>>2,ee|=ee>>>4,ee|=ee>>>8,ee|=ee>>>16,ee++),ee}function howMuchToRead(ee,et){return ee<=0||0===et.length&&et.ended?0:et.objectMode?1:ee!=ee?et.flowing&&et.length?et.buffer.head.data.length:et.length:(ee>et.highWaterMark&&(et.highWaterMark=computeNewHighWaterMark(ee)),ee<=et.length)?ee:et.ended?et.length:(et.needReadable=!0,0)}function onEofChunk(ee,et){if(es("onEofChunk"),!et.ended){if(et.decoder){var en=et.decoder.end();en&&en.length&&(et.buffer.push(en),et.length+=et.objectMode?1:en.length)}et.ended=!0,et.sync?emitReadable(ee):(et.needReadable=!1,et.emittedReadable||(et.emittedReadable=!0,emitReadable_(ee)))}}function emitReadable(ee){var et=ee._readableState;es("emitReadable",et.needReadable,et.emittedReadable),et.needReadable=!1,et.emittedReadable||(es("emitReadable",et.flowing),et.emittedReadable=!0,eo.nextTick(emitReadable_,ee))}function emitReadable_(ee){var et=ee._readableState;es("emitReadable_",et.destroyed,et.length,et.ended),!et.destroyed&&(et.length||et.ended)&&(ee.emit("readable"),et.emittedReadable=!1),et.needReadable=!et.flowing&&!et.ended&&et.length<=et.highWaterMark,flow(ee)}function maybeReadMore(ee,et){et.readingMore||(et.readingMore=!0,eo.nextTick(maybeReadMore_,ee,et))}function maybeReadMore_(ee,et){for(;!et.reading&&!et.ended&&(et.length0,et.resumeScheduled&&!et.paused?et.flowing=!0:ee.listenerCount("data")>0&&ee.resume()}function nReadingNextTick(ee){es("readable nexttick read 0"),ee.read(0)}function resume(ee,et){et.resumeScheduled||(et.resumeScheduled=!0,eo.nextTick(resume_,ee,et))}function resume_(ee,et){es("resume",et.reading),et.reading||ee.read(0),et.resumeScheduled=!1,ee.emit("resume"),flow(ee),et.flowing&&!et.reading&&ee.read(0)}function flow(ee){var et=ee._readableState;for(es("flow",et.flowing);et.flowing&&null!==ee.read(););}function fromList(ee,et){var en;return 0===et.length?null:(et.objectMode?en=et.buffer.shift():!ee||ee>=et.length?(en=et.decoder?et.buffer.join(""):1===et.buffer.length?et.buffer.first():et.buffer.concat(et.length),et.buffer.clear()):en=et.buffer.consume(ee,et.decoder),en)}function endReadable(ee){var et=ee._readableState;es("endReadable",et.endEmitted),et.endEmitted||(et.ended=!0,eo.nextTick(endReadableNT,et,ee))}function endReadableNT(ee,et){if(es("endReadableNT",ee.endEmitted,ee.length),!ee.endEmitted&&0===ee.length&&(ee.endEmitted=!0,et.readable=!1,et.emit("end"),ee.autoDestroy)){var en=et._writableState;(!en||en.autoDestroy&&en.finished)&&et.destroy()}}function indexOf(ee,et){for(var en=0,ei=ee.length;en=en.highWaterMark:en.length>0)||en.ended))return es("read: emitReadable",en.length,en.ended),0===en.length&&en.ended?endReadable(this):emitReadable(this),null;if(0===(ee=howMuchToRead(ee,en))&&en.ended)return 0===en.length&&endReadable(this),null;var eo=en.needReadable;return es("need readable",eo),(0===en.length||en.length-ee0?fromList(ee,en):null)?(en.needReadable=en.length<=en.highWaterMark,ee=0):(en.length-=ee,en.awaitDrain=0),0===en.length&&(en.ended||(en.needReadable=!0),ei!==ee&&en.ended&&endReadable(this)),null!==et&&this.emit("data",et),et},Readable.prototype._read=function(ee){eA(this,new eS("_read()"))},Readable.prototype.pipe=function(ee,et){var en=this,ei=this._readableState;switch(ei.pipesCount){case 0:ei.pipes=ee;break;case 1:ei.pipes=[ei.pipes,ee];break;default:ei.pipes.push(ee)}ei.pipesCount+=1,es("pipe count=%d opts=%j",ei.pipesCount,et);var ea=et&&!1===et.end||ee===eo.stdout||ee===eo.stderr?unpipe:onend;function onunpipe(ee,et){es("onunpipe"),ee===en&&et&&!1===et.hasUnpiped&&(et.hasUnpiped=!0,cleanup())}function onend(){es("onend"),ee.end()}ei.endEmitted?eo.nextTick(ea):en.once("end",ea),ee.on("unpipe",onunpipe);var eu=pipeOnDrain(en);ee.on("drain",eu);var ec=!1;function cleanup(){es("cleanup"),ee.removeListener("close",onclose),ee.removeListener("finish",onfinish),ee.removeListener("drain",eu),ee.removeListener("error",onerror),ee.removeListener("unpipe",onunpipe),en.removeListener("end",onend),en.removeListener("end",unpipe),en.removeListener("data",ondata),ec=!0,ei.awaitDrain&&(!ee._writableState||ee._writableState.needDrain)&&eu()}function ondata(et){es("ondata");var eo=ee.write(et);es("dest.write",eo),!1===eo&&((1===ei.pipesCount&&ei.pipes===ee||ei.pipesCount>1&&-1!==indexOf(ei.pipes,ee))&&!ec&&(es("false write response, pause",ei.awaitDrain),ei.awaitDrain++),en.pause())}function onerror(et){es("onerror",et),unpipe(),ee.removeListener("error",onerror),0===a(ee,"error")&&eA(ee,et)}function onclose(){ee.removeListener("finish",onfinish),unpipe()}function onfinish(){es("onfinish"),ee.removeListener("close",onclose),unpipe()}function unpipe(){es("unpipe"),en.unpipe(ee)}return en.on("data",ondata),prependListener(ee,"error",onerror),ee.once("close",onclose),ee.once("finish",onfinish),ee.emit("pipe",en),ei.flowing||(es("pipe resume"),en.resume()),ee},Readable.prototype.unpipe=function(ee){var et=this._readableState,en={hasUnpiped:!1};if(0===et.pipesCount)return this;if(1===et.pipesCount)return ee&&ee!==et.pipes||(ee||(ee=et.pipes),et.pipes=null,et.pipesCount=0,et.flowing=!1,ee&&ee.emit("unpipe",this,en)),this;if(!ee){var ei=et.pipes,eo=et.pipesCount;et.pipes=null,et.pipesCount=0,et.flowing=!1;for(var ea=0;ea0,!1!==ei.flowing&&this.resume()):"readable"!==ee||ei.endEmitted||ei.readableListening||(ei.readableListening=ei.needReadable=!0,ei.flowing=!1,ei.emittedReadable=!1,es("on readable",ei.length,ei.reading),ei.length?emitReadable(this):ei.reading||eo.nextTick(nReadingNextTick,this)),en},Readable.prototype.addListener=Readable.prototype.on,Readable.prototype.removeListener=function(ee,et){var en=ef.prototype.removeListener.call(this,ee,et);return"readable"===ee&&eo.nextTick(updateReadableListening,this),en},Readable.prototype.removeAllListeners=function(ee){var et=ef.prototype.removeAllListeners.apply(this,arguments);return("readable"===ee||void 0===ee)&&eo.nextTick(updateReadableListening,this),et},Readable.prototype.resume=function(){var ee=this._readableState;return ee.flowing||(es("resume"),ee.flowing=!ee.readableListening,resume(this,ee)),ee.paused=!1,this},Readable.prototype.pause=function(){return es("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(es("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this},Readable.prototype.wrap=function(ee){var et=this,en=this._readableState,ei=!1;for(var eo in ee.on("end",function(){if(es("wrapped end"),en.decoder&&!en.ended){var ee=en.decoder.end();ee&&ee.length&&et.push(ee)}et.push(null)}),ee.on("data",function(eo){es("wrapped data"),en.decoder&&(eo=en.decoder.write(eo)),(!en.objectMode||null!=eo)&&(en.objectMode||eo&&eo.length)&&(et.push(eo)||(ei=!0,ee.pause()))}),ee)void 0===this[eo]&&"function"==typeof ee[eo]&&(this[eo]=function(et){return function(){return ee[et].apply(ee,arguments)}}(eo));for(var ea=0;ea-1))throw new eE(ee);return this._writableState.defaultEncoding=ee,this},Object.defineProperty(Writable.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(Writable.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Writable.prototype._write=function(ee,et,en){en(new eg("_write()"))},Writable.prototype._writev=null,Writable.prototype.end=function(ee,et,en){var ei=this._writableState;return"function"==typeof ee?(en=ee,ee=null,et=null):"function"==typeof et&&(en=et,et=null),null!=ee&&this.write(ee,et),ei.corked&&(ei.corked=1,this.uncork()),ei.ending||endWritable(this,ei,en),this},Object.defineProperty(Writable.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(Writable.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(ee){this._writableState&&(this._writableState.destroyed=ee)}}),Writable.prototype.destroy=ep.destroy,Writable.prototype._undestroy=ep.undestroy,Writable.prototype._destroy=function(ee,et){et(ee)}},871:function(ee,et,en){"use strict";function _defineProperty(ee,et,en){return et in ee?Object.defineProperty(ee,et,{value:en,enumerable:!0,configurable:!0,writable:!0}):ee[et]=en,ee}var ei,ea=en(698),es=Symbol("lastResolve"),eu=Symbol("lastReject"),ec=Symbol("error"),ed=Symbol("ended"),ef=Symbol("lastPromise"),ep=Symbol("handlePromise"),eh=Symbol("stream");function createIterResult(ee,et){return{value:ee,done:et}}function readAndResolve(ee){var et=ee[es];if(null!==et){var en=ee[eh].read();null!==en&&(ee[ef]=null,ee[es]=null,ee[eu]=null,et(createIterResult(en,!1)))}}function onReadable(ee){eo.nextTick(readAndResolve,ee)}function wrapForNext(ee,et){return function(en,ei){ee.then(function(){if(et[ed]){en(createIterResult(void 0,!0));return}et[ep](en,ei)},ei)}}var ey=Object.getPrototypeOf(function(){}),em=Object.setPrototypeOf((_defineProperty(ei={get stream(){return this[eh]},next:function(){var ee,et=this,en=this[ec];if(null!==en)return Promise.reject(en);if(this[ed])return Promise.resolve(createIterResult(void 0,!0));if(this[eh].destroyed)return new Promise(function(ee,en){eo.nextTick(function(){et[ec]?en(et[ec]):ee(createIterResult(void 0,!0))})});var ei=this[ef];if(ei)ee=new Promise(wrapForNext(ei,this));else{var ea=this[eh].read();if(null!==ea)return Promise.resolve(createIterResult(ea,!1));ee=new Promise(this[ep])}return this[ef]=ee,ee}},Symbol.asyncIterator,function(){return this}),_defineProperty(ei,"return",function(){var ee=this;return new Promise(function(et,en){ee[eh].destroy(null,function(ee){if(ee){en(ee);return}et(createIterResult(void 0,!0))})})}),ei),ey),p=function(ee){var et,en=Object.create(em,(_defineProperty(et={},eh,{value:ee,writable:!0}),_defineProperty(et,es,{value:null,writable:!0}),_defineProperty(et,eu,{value:null,writable:!0}),_defineProperty(et,ec,{value:null,writable:!0}),_defineProperty(et,ed,{value:ee._readableState.endEmitted,writable:!0}),_defineProperty(et,ep,{value:function(ee,et){var ei=en[eh].read();ei?(en[ef]=null,en[es]=null,en[eu]=null,ee(createIterResult(ei,!1))):(en[es]=ee,en[eu]=et)},writable:!0}),et));return en[ef]=null,ea(ee,function(ee){if(ee&&"ERR_STREAM_PREMATURE_CLOSE"!==ee.code){var et=en[eu];null!==et&&(en[ef]=null,en[es]=null,en[eu]=null,et(ee)),en[ec]=ee;return}var ei=en[es];null!==ei&&(en[ef]=null,en[es]=null,en[eu]=null,ei(createIterResult(void 0,!0))),en[ed]=!0}),ee.on("readable",onReadable.bind(null,en)),en};ee.exports=p},379:function(ee,et,en){"use strict";function ownKeys(ee,et){var en=Object.keys(ee);if(Object.getOwnPropertySymbols){var ei=Object.getOwnPropertySymbols(ee);et&&(ei=ei.filter(function(et){return Object.getOwnPropertyDescriptor(ee,et).enumerable})),en.push.apply(en,ei)}return en}function _objectSpread(ee){for(var et=1;et0?this.tail.next=et:this.head=et,this.tail=et,++this.length}},{key:"unshift",value:function(ee){var et={data:ee,next:this.head};0===this.length&&(this.tail=et),this.head=et,++this.length}},{key:"shift",value:function(){if(0!==this.length){var ee=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,ee}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(ee){if(0===this.length)return"";for(var et=this.head,en=""+et.data;et=et.next;)en+=ee+et.data;return en}},{key:"concat",value:function(ee){if(0===this.length)return ei.alloc(0);for(var et=ei.allocUnsafe(ee>>>0),en=this.head,eo=0;en;)copyBuffer(en.data,et,eo),eo+=en.data.length,en=en.next;return et}},{key:"consume",value:function(ee,et){var en;return eeeo.length?eo.length:ee;if(ea===eo.length?ei+=eo:ei+=eo.slice(0,ee),0==(ee-=ea)){ea===eo.length?(++en,et.next?this.head=et.next:this.head=this.tail=null):(this.head=et,et.data=eo.slice(ea));break}++en}return this.length-=en,ei}},{key:"_getBuffer",value:function(ee){var et=ei.allocUnsafe(ee),en=this.head,eo=1;for(en.data.copy(et),ee-=en.data.length;en=en.next;){var ea=en.data,es=ee>ea.length?ea.length:ee;if(ea.copy(et,et.length-ee,0,es),0==(ee-=es)){es===ea.length?(++eo,en.next?this.head=en.next:this.head=this.tail=null):(this.head=en,en.data=ea.slice(es));break}++eo}return this.length-=eo,et}},{key:ea,value:function(ee,et){return eo(this,_objectSpread({},et,{depth:0,customInspect:!1}))}}]),BufferList}()},25:function(ee){"use strict";function destroy(ee,et){var en=this,ei=this._readableState&&this._readableState.destroyed,ea=this._writableState&&this._writableState.destroyed;return ei||ea?et?et(ee):ee&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,eo.nextTick(emitErrorNT,this,ee)):eo.nextTick(emitErrorNT,this,ee)):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(ee||null,function(ee){!et&&ee?en._writableState?en._writableState.errorEmitted?eo.nextTick(emitCloseNT,en):(en._writableState.errorEmitted=!0,eo.nextTick(emitErrorAndCloseNT,en,ee)):eo.nextTick(emitErrorAndCloseNT,en,ee):et?(eo.nextTick(emitCloseNT,en),et(ee)):eo.nextTick(emitCloseNT,en)})),this}function emitErrorAndCloseNT(ee,et){emitErrorNT(ee,et),emitCloseNT(ee)}function emitCloseNT(ee){(!ee._writableState||ee._writableState.emitClose)&&(!ee._readableState||ee._readableState.emitClose)&&ee.emit("close")}function undestroy(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function emitErrorNT(ee,et){ee.emit("error",et)}function errorOrDestroy(ee,et){var en=ee._readableState,ei=ee._writableState;en&&en.autoDestroy||ei&&ei.autoDestroy?ee.destroy(et):ee.emit("error",et)}ee.exports={destroy:destroy,undestroy:undestroy,errorOrDestroy:errorOrDestroy}},698:function(ee,et,en){"use strict";var ei=en(646).q.ERR_STREAM_PREMATURE_CLOSE;function once(ee){var et=!1;return function(){if(!et){et=!0;for(var en=arguments.length,ei=Array(en),eo=0;eo0,function(et){ee||(ee=et),et&&es.forEach(call),ea||(es.forEach(call),eo(ee))})});return en.reduce(pipe)}ee.exports=pipeline},776:function(ee,et,en){"use strict";var ei=en(646).q.ERR_INVALID_OPT_VALUE;function highWaterMarkFrom(ee,et,en){return null!=ee.highWaterMark?ee.highWaterMark:et?ee[en]:null}function getHighWaterMark(ee,et,en,eo){var ea=highWaterMarkFrom(et,eo,en);if(null!=ea){if(!(isFinite(ea)&&Math.floor(ea)===ea)||ea<0)throw new ei(eo?en:"highWaterMark",ea);return Math.floor(ea)}return ee.objectMode?16:16384}ee.exports={getHighWaterMark:getHighWaterMark}},678:function(ee,et,en){ee.exports=en(781)},55:function(ee,et,en){var ei=en(300),eo=ei.Buffer;function copyProps(ee,et){for(var en in ee)et[en]=ee[en]}function SafeBuffer(ee,et,en){return eo(ee,et,en)}eo.from&&eo.alloc&&eo.allocUnsafe&&eo.allocUnsafeSlow?ee.exports=ei:(copyProps(ei,et),et.Buffer=SafeBuffer),SafeBuffer.prototype=Object.create(eo.prototype),copyProps(eo,SafeBuffer),SafeBuffer.from=function(ee,et,en){if("number"==typeof ee)throw TypeError("Argument must not be a number");return eo(ee,et,en)},SafeBuffer.alloc=function(ee,et,en){if("number"!=typeof ee)throw TypeError("Argument must be a number");var ei=eo(ee);return void 0!==et?"string"==typeof en?ei.fill(et,en):ei.fill(et):ei.fill(0),ei},SafeBuffer.allocUnsafe=function(ee){if("number"!=typeof ee)throw TypeError("Argument must be a number");return eo(ee)},SafeBuffer.allocUnsafeSlow=function(ee){if("number"!=typeof ee)throw TypeError("Argument must be a number");return ei.SlowBuffer(ee)}},173:function(ee,et,en){ee.exports=Stream;var ei=en(361).EventEmitter;function Stream(){ei.call(this)}en(782)(Stream,ei),Stream.Readable=en(709),Stream.Writable=en(337),Stream.Duplex=en(403),Stream.Transform=en(170),Stream.PassThrough=en(889),Stream.finished=en(698),Stream.pipeline=en(442),Stream.Stream=Stream,Stream.prototype.pipe=function(ee,et){var en=this;function ondata(et){ee.writable&&!1===ee.write(et)&&en.pause&&en.pause()}function ondrain(){en.readable&&en.resume&&en.resume()}en.on("data",ondata),ee.on("drain",ondrain),ee._isStdio||et&&!1===et.end||(en.on("end",onend),en.on("close",onclose));var eo=!1;function onend(){eo||(eo=!0,ee.end())}function onclose(){eo||(eo=!0,"function"==typeof ee.destroy&&ee.destroy())}function onerror(ee){if(cleanup(),0===ei.listenerCount(this,"error"))throw ee}function cleanup(){en.removeListener("data",ondata),ee.removeListener("drain",ondrain),en.removeListener("end",onend),en.removeListener("close",onclose),en.removeListener("error",onerror),ee.removeListener("error",onerror),en.removeListener("end",cleanup),en.removeListener("close",cleanup),ee.removeListener("close",cleanup)}return en.on("error",onerror),ee.on("error",onerror),en.on("end",cleanup),en.on("close",cleanup),ee.on("close",cleanup),ee.emit("pipe",en),ee}},704:function(ee,et,en){"use strict";var ei=en(55).Buffer,eo=ei.isEncoding||function(ee){switch((ee=""+ee)&&ee.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function _normalizeEncoding(ee){var et;if(!ee)return"utf8";for(;;)switch(ee){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return ee;default:if(et)return;ee=(""+ee).toLowerCase(),et=!0}}function normalizeEncoding(ee){var et=_normalizeEncoding(ee);if("string"!=typeof et&&(ei.isEncoding===eo||!eo(ee)))throw Error("Unknown encoding: "+ee);return et||ee}function StringDecoder(ee){var et;switch(this.encoding=normalizeEncoding(ee),this.encoding){case"utf16le":this.text=utf16Text,this.end=utf16End,et=4;break;case"utf8":this.fillLast=utf8FillLast,et=4;break;case"base64":this.text=base64Text,this.end=base64End,et=3;break;default:this.write=simpleWrite,this.end=simpleEnd;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=ei.allocUnsafe(et)}function utf8CheckByte(ee){return ee<=127?0:ee>>5==6?2:ee>>4==14?3:ee>>3==30?4:ee>>6==2?-1:-2}function utf8CheckIncomplete(ee,et,en){var ei=et.length-1;if(ei=0?(eo>0&&(ee.lastNeed=eo-1),eo):--ei=0?(eo>0&&(ee.lastNeed=eo-2),eo):--ei=0?(eo>0&&(2===eo?eo=0:ee.lastNeed=eo-3),eo):0}function utf8CheckExtraBytes(ee,et,en){if((192&et[0])!=128)return ee.lastNeed=0,"�";if(ee.lastNeed>1&&et.length>1){if((192&et[1])!=128)return ee.lastNeed=1,"�";if(ee.lastNeed>2&&et.length>2&&(192&et[2])!=128)return ee.lastNeed=2,"�"}}function utf8FillLast(ee){var et=this.lastTotal-this.lastNeed,en=utf8CheckExtraBytes(this,ee,et);return void 0!==en?en:this.lastNeed<=ee.length?(ee.copy(this.lastChar,et,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):void(ee.copy(this.lastChar,et,0,ee.length),this.lastNeed-=ee.length)}function utf8Text(ee,et){var en=utf8CheckIncomplete(this,ee,et);if(!this.lastNeed)return ee.toString("utf8",et);this.lastTotal=en;var ei=ee.length-(en-this.lastNeed);return ee.copy(this.lastChar,0,ei),ee.toString("utf8",et,ei)}function utf8End(ee){var et=ee&&ee.length?this.write(ee):"";return this.lastNeed?et+"�":et}function utf16Text(ee,et){if((ee.length-et)%2==0){var en=ee.toString("utf16le",et);if(en){var ei=en.charCodeAt(en.length-1);if(ei>=55296&&ei<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=ee[ee.length-2],this.lastChar[1]=ee[ee.length-1],en.slice(0,-1)}return en}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=ee[ee.length-1],ee.toString("utf16le",et,ee.length-1)}function utf16End(ee){var et=ee&&ee.length?this.write(ee):"";if(this.lastNeed){var en=this.lastTotal-this.lastNeed;return et+this.lastChar.toString("utf16le",0,en)}return et}function base64Text(ee,et){var en=(ee.length-et)%3;return 0===en?ee.toString("base64",et):(this.lastNeed=3-en,this.lastTotal=3,1===en?this.lastChar[0]=ee[ee.length-1]:(this.lastChar[0]=ee[ee.length-2],this.lastChar[1]=ee[ee.length-1]),ee.toString("base64",et,ee.length-en))}function base64End(ee){var et=ee&&ee.length?this.write(ee):"";return this.lastNeed?et+this.lastChar.toString("base64",0,3-this.lastNeed):et}function simpleWrite(ee){return ee.toString(this.encoding)}function simpleEnd(ee){return ee&&ee.length?this.write(ee):""}et.s=StringDecoder,StringDecoder.prototype.write=function(ee){var et,en;if(0===ee.length)return"";if(this.lastNeed){if(void 0===(et=this.fillLast(ee)))return"";en=this.lastNeed,this.lastNeed=0}else en=0;return enString(ee)),en>2)?`one of ${et} ${ee.slice(0,en-1).join(", ")}, or `+ee[en-1]:2===en?`one of ${et} ${ee[0]} or ${ee[1]}`:`of ${et} ${ee[0]}`}}function startsWith(ee,et,en){return ee.substr(!en||en<0?0:+en,et.length)===et}function endsWith(ee,et,en){return(void 0===en||en>ee.length)&&(en=ee.length),ee.substring(en-et.length,en)===et}function includes(ee,et,en){return"number"!=typeof en&&(en=0),!(en+et.length>ee.length)&&-1!==ee.indexOf(et,en)}createErrorType("ERR_INVALID_OPT_VALUE",function(ee,et){return'The value "'+et+'" is invalid for option "'+ee+'"'},TypeError),createErrorType("ERR_INVALID_ARG_TYPE",function(ee,et,en){let ei,eo;if("string"==typeof et&&startsWith(et,"not ")?(ei="must not be",et=et.replace(/^not /,"")):ei="must be",endsWith(ee," argument"))eo=`The ${ee} ${ei} ${oneOf(et,"type")}`;else{let en=includes(ee,".")?"property":"argument";eo=`The "${ee}" ${en} ${ei} ${oneOf(et,"type")}`}return eo+`. Received type ${typeof en}`},TypeError),createErrorType("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),createErrorType("ERR_METHOD_NOT_IMPLEMENTED",function(ee){return"The "+ee+" method is not implemented"}),createErrorType("ERR_STREAM_PREMATURE_CLOSE","Premature close"),createErrorType("ERR_STREAM_DESTROYED",function(ee){return"Cannot call "+ee+" after a stream was destroyed"}),createErrorType("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),createErrorType("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),createErrorType("ERR_STREAM_WRITE_AFTER_END","write after end"),createErrorType("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),createErrorType("ERR_UNKNOWN_ENCODING",function(ee){return"Unknown encoding: "+ee},TypeError),createErrorType("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),ee.exports.q=et},403:function(ee,et,en){"use strict";var ei=Object.keys||function(ee){var et=[];for(var en in ee)et.push(en);return et};ee.exports=Duplex;var ea=en(709),es=en(337);en(782)(Duplex,ea);for(var eu=ei(es.prototype),ec=0;ec0){if("string"==typeof et||eu.objectMode||Object.getPrototypeOf(et)===ep.prototype||(et=_uint8ArrayToBuffer(et)),ei)eu.endEmitted?eA(ee,new eE):addChunk(ee,eu,et,!0);else if(eu.ended)eA(ee,new ew);else{if(eu.destroyed)return!1;eu.reading=!1,eu.decoder&&!en?(et=eu.decoder.write(et),eu.objectMode||0!==et.length?addChunk(ee,eu,et,!1):maybeReadMore(ee,eu)):addChunk(ee,eu,et,!1)}}else ei||(eu.reading=!1,maybeReadMore(ee,eu));return!eu.ended&&(eu.length=ex?ee=ex:(ee--,ee|=ee>>>1,ee|=ee>>>2,ee|=ee>>>4,ee|=ee>>>8,ee|=ee>>>16,ee++),ee}function howMuchToRead(ee,et){return ee<=0||0===et.length&&et.ended?0:et.objectMode?1:ee!=ee?et.flowing&&et.length?et.buffer.head.data.length:et.length:(ee>et.highWaterMark&&(et.highWaterMark=computeNewHighWaterMark(ee)),ee<=et.length)?ee:et.ended?et.length:(et.needReadable=!0,0)}function onEofChunk(ee,et){if(es("onEofChunk"),!et.ended){if(et.decoder){var en=et.decoder.end();en&&en.length&&(et.buffer.push(en),et.length+=et.objectMode?1:en.length)}et.ended=!0,et.sync?emitReadable(ee):(et.needReadable=!1,et.emittedReadable||(et.emittedReadable=!0,emitReadable_(ee)))}}function emitReadable(ee){var et=ee._readableState;es("emitReadable",et.needReadable,et.emittedReadable),et.needReadable=!1,et.emittedReadable||(es("emitReadable",et.flowing),et.emittedReadable=!0,eo.nextTick(emitReadable_,ee))}function emitReadable_(ee){var et=ee._readableState;es("emitReadable_",et.destroyed,et.length,et.ended),!et.destroyed&&(et.length||et.ended)&&(ee.emit("readable"),et.emittedReadable=!1),et.needReadable=!et.flowing&&!et.ended&&et.length<=et.highWaterMark,flow(ee)}function maybeReadMore(ee,et){et.readingMore||(et.readingMore=!0,eo.nextTick(maybeReadMore_,ee,et))}function maybeReadMore_(ee,et){for(;!et.reading&&!et.ended&&(et.length0,et.resumeScheduled&&!et.paused?et.flowing=!0:ee.listenerCount("data")>0&&ee.resume()}function nReadingNextTick(ee){es("readable nexttick read 0"),ee.read(0)}function resume(ee,et){et.resumeScheduled||(et.resumeScheduled=!0,eo.nextTick(resume_,ee,et))}function resume_(ee,et){es("resume",et.reading),et.reading||ee.read(0),et.resumeScheduled=!1,ee.emit("resume"),flow(ee),et.flowing&&!et.reading&&ee.read(0)}function flow(ee){var et=ee._readableState;for(es("flow",et.flowing);et.flowing&&null!==ee.read(););}function fromList(ee,et){var en;return 0===et.length?null:(et.objectMode?en=et.buffer.shift():!ee||ee>=et.length?(en=et.decoder?et.buffer.join(""):1===et.buffer.length?et.buffer.first():et.buffer.concat(et.length),et.buffer.clear()):en=et.buffer.consume(ee,et.decoder),en)}function endReadable(ee){var et=ee._readableState;es("endReadable",et.endEmitted),et.endEmitted||(et.ended=!0,eo.nextTick(endReadableNT,et,ee))}function endReadableNT(ee,et){if(es("endReadableNT",ee.endEmitted,ee.length),!ee.endEmitted&&0===ee.length&&(ee.endEmitted=!0,et.readable=!1,et.emit("end"),ee.autoDestroy)){var en=et._writableState;(!en||en.autoDestroy&&en.finished)&&et.destroy()}}function indexOf(ee,et){for(var en=0,ei=ee.length;en=en.highWaterMark:en.length>0)||en.ended))return es("read: emitReadable",en.length,en.ended),0===en.length&&en.ended?endReadable(this):emitReadable(this),null;if(0===(ee=howMuchToRead(ee,en))&&en.ended)return 0===en.length&&endReadable(this),null;var eo=en.needReadable;return es("need readable",eo),(0===en.length||en.length-ee0?fromList(ee,en):null)?(en.needReadable=en.length<=en.highWaterMark,ee=0):(en.length-=ee,en.awaitDrain=0),0===en.length&&(en.ended||(en.needReadable=!0),ei!==ee&&en.ended&&endReadable(this)),null!==et&&this.emit("data",et),et},Readable.prototype._read=function(ee){eA(this,new eS("_read()"))},Readable.prototype.pipe=function(ee,et){var en=this,ei=this._readableState;switch(ei.pipesCount){case 0:ei.pipes=ee;break;case 1:ei.pipes=[ei.pipes,ee];break;default:ei.pipes.push(ee)}ei.pipesCount+=1,es("pipe count=%d opts=%j",ei.pipesCount,et);var ea=et&&!1===et.end||ee===eo.stdout||ee===eo.stderr?unpipe:onend;function onunpipe(ee,et){es("onunpipe"),ee===en&&et&&!1===et.hasUnpiped&&(et.hasUnpiped=!0,cleanup())}function onend(){es("onend"),ee.end()}ei.endEmitted?eo.nextTick(ea):en.once("end",ea),ee.on("unpipe",onunpipe);var eu=pipeOnDrain(en);ee.on("drain",eu);var ec=!1;function cleanup(){es("cleanup"),ee.removeListener("close",onclose),ee.removeListener("finish",onfinish),ee.removeListener("drain",eu),ee.removeListener("error",onerror),ee.removeListener("unpipe",onunpipe),en.removeListener("end",onend),en.removeListener("end",unpipe),en.removeListener("data",ondata),ec=!0,ei.awaitDrain&&(!ee._writableState||ee._writableState.needDrain)&&eu()}function ondata(et){es("ondata");var eo=ee.write(et);es("dest.write",eo),!1===eo&&((1===ei.pipesCount&&ei.pipes===ee||ei.pipesCount>1&&-1!==indexOf(ei.pipes,ee))&&!ec&&(es("false write response, pause",ei.awaitDrain),ei.awaitDrain++),en.pause())}function onerror(et){es("onerror",et),unpipe(),ee.removeListener("error",onerror),0===a(ee,"error")&&eA(ee,et)}function onclose(){ee.removeListener("finish",onfinish),unpipe()}function onfinish(){es("onfinish"),ee.removeListener("close",onclose),unpipe()}function unpipe(){es("unpipe"),en.unpipe(ee)}return en.on("data",ondata),prependListener(ee,"error",onerror),ee.once("close",onclose),ee.once("finish",onfinish),ee.emit("pipe",en),ei.flowing||(es("pipe resume"),en.resume()),ee},Readable.prototype.unpipe=function(ee){var et=this._readableState,en={hasUnpiped:!1};if(0===et.pipesCount)return this;if(1===et.pipesCount)return ee&&ee!==et.pipes||(ee||(ee=et.pipes),et.pipes=null,et.pipesCount=0,et.flowing=!1,ee&&ee.emit("unpipe",this,en)),this;if(!ee){var ei=et.pipes,eo=et.pipesCount;et.pipes=null,et.pipesCount=0,et.flowing=!1;for(var ea=0;ea0,!1!==ei.flowing&&this.resume()):"readable"!==ee||ei.endEmitted||ei.readableListening||(ei.readableListening=ei.needReadable=!0,ei.flowing=!1,ei.emittedReadable=!1,es("on readable",ei.length,ei.reading),ei.length?emitReadable(this):ei.reading||eo.nextTick(nReadingNextTick,this)),en},Readable.prototype.addListener=Readable.prototype.on,Readable.prototype.removeListener=function(ee,et){var en=ef.prototype.removeListener.call(this,ee,et);return"readable"===ee&&eo.nextTick(updateReadableListening,this),en},Readable.prototype.removeAllListeners=function(ee){var et=ef.prototype.removeAllListeners.apply(this,arguments);return("readable"===ee||void 0===ee)&&eo.nextTick(updateReadableListening,this),et},Readable.prototype.resume=function(){var ee=this._readableState;return ee.flowing||(es("resume"),ee.flowing=!ee.readableListening,resume(this,ee)),ee.paused=!1,this},Readable.prototype.pause=function(){return es("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(es("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this},Readable.prototype.wrap=function(ee){var et=this,en=this._readableState,ei=!1;for(var eo in ee.on("end",function(){if(es("wrapped end"),en.decoder&&!en.ended){var ee=en.decoder.end();ee&&ee.length&&et.push(ee)}et.push(null)}),ee.on("data",function(eo){es("wrapped data"),en.decoder&&(eo=en.decoder.write(eo)),(!en.objectMode||null!=eo)&&(en.objectMode||eo&&eo.length)&&(et.push(eo)||(ei=!0,ee.pause()))}),ee)void 0===this[eo]&&"function"==typeof ee[eo]&&(this[eo]=function(et){return function(){return ee[et].apply(ee,arguments)}}(eo));for(var ea=0;ea-1))throw new eE(ee);return this._writableState.defaultEncoding=ee,this},Object.defineProperty(Writable.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(Writable.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Writable.prototype._write=function(ee,et,en){en(new eg("_write()"))},Writable.prototype._writev=null,Writable.prototype.end=function(ee,et,en){var ei=this._writableState;return"function"==typeof ee?(en=ee,ee=null,et=null):"function"==typeof et&&(en=et,et=null),null!=ee&&this.write(ee,et),ei.corked&&(ei.corked=1,this.uncork()),ei.ending||endWritable(this,ei,en),this},Object.defineProperty(Writable.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(Writable.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(ee){this._writableState&&(this._writableState.destroyed=ee)}}),Writable.prototype.destroy=ep.destroy,Writable.prototype._undestroy=ep.undestroy,Writable.prototype._destroy=function(ee,et){et(ee)}},871:function(ee,et,en){"use strict";function _defineProperty(ee,et,en){return et in ee?Object.defineProperty(ee,et,{value:en,enumerable:!0,configurable:!0,writable:!0}):ee[et]=en,ee}var ei,ea=en(698),es=Symbol("lastResolve"),eu=Symbol("lastReject"),ec=Symbol("error"),ed=Symbol("ended"),ef=Symbol("lastPromise"),ep=Symbol("handlePromise"),eh=Symbol("stream");function createIterResult(ee,et){return{value:ee,done:et}}function readAndResolve(ee){var et=ee[es];if(null!==et){var en=ee[eh].read();null!==en&&(ee[ef]=null,ee[es]=null,ee[eu]=null,et(createIterResult(en,!1)))}}function onReadable(ee){eo.nextTick(readAndResolve,ee)}function wrapForNext(ee,et){return function(en,ei){ee.then(function(){if(et[ed]){en(createIterResult(void 0,!0));return}et[ep](en,ei)},ei)}}var ey=Object.getPrototypeOf(function(){}),em=Object.setPrototypeOf((_defineProperty(ei={get stream(){return this[eh]},next:function(){var ee,et=this,en=this[ec];if(null!==en)return Promise.reject(en);if(this[ed])return Promise.resolve(createIterResult(void 0,!0));if(this[eh].destroyed)return new Promise(function(ee,en){eo.nextTick(function(){et[ec]?en(et[ec]):ee(createIterResult(void 0,!0))})});var ei=this[ef];if(ei)ee=new Promise(wrapForNext(ei,this));else{var ea=this[eh].read();if(null!==ea)return Promise.resolve(createIterResult(ea,!1));ee=new Promise(this[ep])}return this[ef]=ee,ee}},Symbol.asyncIterator,function(){return this}),_defineProperty(ei,"return",function(){var ee=this;return new Promise(function(et,en){ee[eh].destroy(null,function(ee){if(ee){en(ee);return}et(createIterResult(void 0,!0))})})}),ei),ey),p=function(ee){var et,en=Object.create(em,(_defineProperty(et={},eh,{value:ee,writable:!0}),_defineProperty(et,es,{value:null,writable:!0}),_defineProperty(et,eu,{value:null,writable:!0}),_defineProperty(et,ec,{value:null,writable:!0}),_defineProperty(et,ed,{value:ee._readableState.endEmitted,writable:!0}),_defineProperty(et,ep,{value:function(ee,et){var ei=en[eh].read();ei?(en[ef]=null,en[es]=null,en[eu]=null,ee(createIterResult(ei,!1))):(en[es]=ee,en[eu]=et)},writable:!0}),et));return en[ef]=null,ea(ee,function(ee){if(ee&&"ERR_STREAM_PREMATURE_CLOSE"!==ee.code){var et=en[eu];null!==et&&(en[ef]=null,en[es]=null,en[eu]=null,et(ee)),en[ec]=ee;return}var ei=en[es];null!==ei&&(en[ef]=null,en[es]=null,en[eu]=null,ei(createIterResult(void 0,!0))),en[ed]=!0}),ee.on("readable",onReadable.bind(null,en)),en};ee.exports=p},379:function(ee,et,en){"use strict";function ownKeys(ee,et){var en=Object.keys(ee);if(Object.getOwnPropertySymbols){var ei=Object.getOwnPropertySymbols(ee);et&&(ei=ei.filter(function(et){return Object.getOwnPropertyDescriptor(ee,et).enumerable})),en.push.apply(en,ei)}return en}function _objectSpread(ee){for(var et=1;et0?this.tail.next=et:this.head=et,this.tail=et,++this.length}},{key:"unshift",value:function(ee){var et={data:ee,next:this.head};0===this.length&&(this.tail=et),this.head=et,++this.length}},{key:"shift",value:function(){if(0!==this.length){var ee=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,ee}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(ee){if(0===this.length)return"";for(var et=this.head,en=""+et.data;et=et.next;)en+=ee+et.data;return en}},{key:"concat",value:function(ee){if(0===this.length)return ei.alloc(0);for(var et=ei.allocUnsafe(ee>>>0),en=this.head,eo=0;en;)copyBuffer(en.data,et,eo),eo+=en.data.length,en=en.next;return et}},{key:"consume",value:function(ee,et){var en;return eeeo.length?eo.length:ee;if(ea===eo.length?ei+=eo:ei+=eo.slice(0,ee),0==(ee-=ea)){ea===eo.length?(++en,et.next?this.head=et.next:this.head=this.tail=null):(this.head=et,et.data=eo.slice(ea));break}++en}return this.length-=en,ei}},{key:"_getBuffer",value:function(ee){var et=ei.allocUnsafe(ee),en=this.head,eo=1;for(en.data.copy(et),ee-=en.data.length;en=en.next;){var ea=en.data,es=ee>ea.length?ea.length:ee;if(ea.copy(et,et.length-ee,0,es),0==(ee-=es)){es===ea.length?(++eo,en.next?this.head=en.next:this.head=this.tail=null):(this.head=en,en.data=ea.slice(es));break}++eo}return this.length-=eo,et}},{key:ea,value:function(ee,et){return eo(this,_objectSpread({},et,{depth:0,customInspect:!1}))}}]),BufferList}()},25:function(ee){"use strict";function destroy(ee,et){var en=this,ei=this._readableState&&this._readableState.destroyed,ea=this._writableState&&this._writableState.destroyed;return ei||ea?et?et(ee):ee&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,eo.nextTick(emitErrorNT,this,ee)):eo.nextTick(emitErrorNT,this,ee)):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(ee||null,function(ee){!et&&ee?en._writableState?en._writableState.errorEmitted?eo.nextTick(emitCloseNT,en):(en._writableState.errorEmitted=!0,eo.nextTick(emitErrorAndCloseNT,en,ee)):eo.nextTick(emitErrorAndCloseNT,en,ee):et?(eo.nextTick(emitCloseNT,en),et(ee)):eo.nextTick(emitCloseNT,en)})),this}function emitErrorAndCloseNT(ee,et){emitErrorNT(ee,et),emitCloseNT(ee)}function emitCloseNT(ee){(!ee._writableState||ee._writableState.emitClose)&&(!ee._readableState||ee._readableState.emitClose)&&ee.emit("close")}function undestroy(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function emitErrorNT(ee,et){ee.emit("error",et)}function errorOrDestroy(ee,et){var en=ee._readableState,ei=ee._writableState;en&&en.autoDestroy||ei&&ei.autoDestroy?ee.destroy(et):ee.emit("error",et)}ee.exports={destroy:destroy,undestroy:undestroy,errorOrDestroy:errorOrDestroy}},698:function(ee,et,en){"use strict";var ei=en(646).q.ERR_STREAM_PREMATURE_CLOSE;function once(ee){var et=!1;return function(){if(!et){et=!0;for(var en=arguments.length,ei=Array(en),eo=0;eo0,function(et){ee||(ee=et),et&&es.forEach(call),ea||(es.forEach(call),eo(ee))})});return en.reduce(pipe)}ee.exports=pipeline},776:function(ee,et,en){"use strict";var ei=en(646).q.ERR_INVALID_OPT_VALUE;function highWaterMarkFrom(ee,et,en){return null!=ee.highWaterMark?ee.highWaterMark:et?ee[en]:null}function getHighWaterMark(ee,et,en,eo){var ea=highWaterMarkFrom(et,eo,en);if(null!=ea){if(!(isFinite(ea)&&Math.floor(ea)===ea)||ea<0)throw new ei(eo?en:"highWaterMark",ea);return Math.floor(ea)}return ee.objectMode?16:16384}ee.exports={getHighWaterMark:getHighWaterMark}},678:function(ee,et,en){ee.exports=en(781)},726:function(ee,et,en){var ei=en(781);"disable"===eo.env.READABLE_STREAM&&ei?(ee.exports=ei.Readable,Object.assign(ee.exports,ei),ee.exports.Stream=ei):((et=ee.exports=en(709)).Stream=ei||et,et.Readable=et,et.Writable=en(337),et.Duplex=en(403),et.Transform=en(170),et.PassThrough=en(889),et.finished=en(698),et.pipeline=en(442))},55:function(ee,et,en){var ei=en(300),eo=ei.Buffer;function copyProps(ee,et){for(var en in ee)et[en]=ee[en]}function SafeBuffer(ee,et,en){return eo(ee,et,en)}eo.from&&eo.alloc&&eo.allocUnsafe&&eo.allocUnsafeSlow?ee.exports=ei:(copyProps(ei,et),et.Buffer=SafeBuffer),SafeBuffer.prototype=Object.create(eo.prototype),copyProps(eo,SafeBuffer),SafeBuffer.from=function(ee,et,en){if("number"==typeof ee)throw TypeError("Argument must not be a number");return eo(ee,et,en)},SafeBuffer.alloc=function(ee,et,en){if("number"!=typeof ee)throw TypeError("Argument must be a number");var ei=eo(ee);return void 0!==et?"string"==typeof en?ei.fill(et,en):ei.fill(et):ei.fill(0),ei},SafeBuffer.allocUnsafe=function(ee){if("number"!=typeof ee)throw TypeError("Argument must be a number");return eo(ee)},SafeBuffer.allocUnsafeSlow=function(ee){if("number"!=typeof ee)throw TypeError("Argument must be a number");return ei.SlowBuffer(ee)}},813:function(ee,et,ei){var eo=ei(450),ea=ei(254),es=ei(911),eu=ei(523),ec=ei(310),ed=et;ed.request=function(ee,et){ee="string"==typeof ee?ec.parse(ee):es(ee);var ei=-1===en.g.location.protocol.search(/^https?:$/)?"http:":"",ea=ee.protocol||ei,eu=ee.hostname||ee.host,ed=ee.port,ef=ee.path||"/";eu&&-1!==eu.indexOf(":")&&(eu="["+eu+"]"),ee.url=(eu?ea+"//"+eu:"")+(ed?":"+ed:"")+ef,ee.method=(ee.method||"GET").toUpperCase(),ee.headers=ee.headers||{};var ep=new eo(ee);return et&&ep.on("response",et),ep},ed.get=function(ee,et){var en=ed.request(ee,et);return en.end(),en},ed.ClientRequest=eo,ed.IncomingMessage=ea.IncomingMessage,ed.Agent=function(){},ed.Agent.defaultMaxSockets=4,ed.globalAgent=new ed.Agent,ed.STATUS_CODES=eu,ed.METHODS=["CHECKOUT","CONNECT","COPY","DELETE","GET","HEAD","LOCK","M-SEARCH","MERGE","MKACTIVITY","MKCOL","MOVE","NOTIFY","OPTIONS","PATCH","POST","PROPFIND","PROPPATCH","PURGE","PUT","REPORT","SEARCH","SUBSCRIBE","TRACE","UNLOCK","UNSUBSCRIBE"]},301:function(ee,et){var ei;function getXHR(){if(void 0!==ei)return ei;if(en.g.XMLHttpRequest){ei=new en.g.XMLHttpRequest;try{ei.open("GET",en.g.XDomainRequest?"/":"https://example.com")}catch(ee){ei=null}}else ei=null;return ei}function checkTypeSupport(ee){var et=getXHR();if(!et)return!1;try{return et.responseType=ee,et.responseType===ee}catch(ee){}return!1}function isFunction(ee){return"function"==typeof ee}et.fetch=isFunction(en.g.fetch)&&isFunction(en.g.ReadableStream),et.writableStream=isFunction(en.g.WritableStream),et.abortController=isFunction(en.g.AbortController),et.arraybuffer=et.fetch||checkTypeSupport("arraybuffer"),et.msstream=!et.fetch&&checkTypeSupport("ms-stream"),et.mozchunkedarraybuffer=!et.fetch&&checkTypeSupport("moz-chunked-arraybuffer"),et.overrideMimeType=et.fetch||!!getXHR()&&isFunction(getXHR().overrideMimeType),ei=null},450:function(ee,et,ei){var es=ei(301),eu=ei(782),ec=ei(254),ed=ei(726),ef=ec.IncomingMessage,ep=ec.readyStates;function decideMode(ee,et){return es.fetch&&et?"fetch":es.mozchunkedarraybuffer?"moz-chunked-arraybuffer":es.msstream?"ms-stream":es.arraybuffer&&ee?"arraybuffer":"text"}var eh=ee.exports=function(ee){var et,en=this;ed.Writable.call(en),en._opts=ee,en._body=[],en._headers={},ee.auth&&en.setHeader("Authorization","Basic "+ea.from(ee.auth).toString("base64")),Object.keys(ee.headers).forEach(function(et){en.setHeader(et,ee.headers[et])});var ei=!0;if("disable-fetch"===ee.mode||"requestTimeout"in ee&&!es.abortController)ei=!1,et=!0;else if("prefer-streaming"===ee.mode)et=!1;else if("allow-wrong-content-type"===ee.mode)et=!es.overrideMimeType;else if(ee.mode&&"default"!==ee.mode&&"prefer-fast"!==ee.mode)throw Error("Invalid value for opts.mode");else et=!0;en._mode=decideMode(et,ei),en._fetchTimer=null,en.on("finish",function(){en._onFinish()})};function statusValid(ee){try{var et=ee.status;return null!==et&&0!==et}catch(ee){return!1}}eu(eh,ed.Writable),eh.prototype.setHeader=function(ee,et){var en=this,ei=ee.toLowerCase();-1===ey.indexOf(ei)&&(en._headers[ei]={name:ee,value:et})},eh.prototype.getHeader=function(ee){var et=this._headers[ee.toLowerCase()];return et?et.value:null},eh.prototype.removeHeader=function(ee){var et=this;delete et._headers[ee.toLowerCase()]},eh.prototype._onFinish=function(){var ee=this;if(!ee._destroyed){var et=ee._opts,ei=ee._headers,ea=null;"GET"!==et.method&&"HEAD"!==et.method&&(ea=new Blob(ee._body,{type:(ei["content-type"]||{}).value||""}));var eu=[];if(Object.keys(ei).forEach(function(ee){var et=ei[ee].name,en=ei[ee].value;Array.isArray(en)?en.forEach(function(ee){eu.push([et,ee])}):eu.push([et,en])}),"fetch"===ee._mode){var ec=null;if(es.abortController){var ed=new AbortController;ec=ed.signal,ee._fetchAbortController=ed,"requestTimeout"in et&&0!==et.requestTimeout&&(ee._fetchTimer=en.g.setTimeout(function(){ee.emit("requestTimeout"),ee._fetchAbortController&&ee._fetchAbortController.abort()},et.requestTimeout))}en.g.fetch(ee._opts.url,{method:ee._opts.method,headers:eu,body:ea||void 0,mode:"cors",credentials:et.withCredentials?"include":"same-origin",signal:ec}).then(function(et){ee._fetchResponse=et,ee._connect()},function(et){en.g.clearTimeout(ee._fetchTimer),ee._destroyed||ee.emit("error",et)})}else{var ef=ee._xhr=new en.g.XMLHttpRequest;try{ef.open(ee._opts.method,ee._opts.url,!0)}catch(et){eo.nextTick(function(){ee.emit("error",et)});return}"responseType"in ef&&(ef.responseType=ee._mode),"withCredentials"in ef&&(ef.withCredentials=!!et.withCredentials),"text"===ee._mode&&"overrideMimeType"in ef&&ef.overrideMimeType("text/plain; charset=x-user-defined"),"requestTimeout"in et&&(ef.timeout=et.requestTimeout,ef.ontimeout=function(){ee.emit("requestTimeout")}),eu.forEach(function(ee){ef.setRequestHeader(ee[0],ee[1])}),ee._response=null,ef.onreadystatechange=function(){switch(ef.readyState){case ep.LOADING:case ep.DONE:ee._onXHRProgress()}},"moz-chunked-arraybuffer"===ee._mode&&(ef.onprogress=function(){ee._onXHRProgress()}),ef.onerror=function(){ee._destroyed||ee.emit("error",Error("XHR error"))};try{ef.send(ea)}catch(et){eo.nextTick(function(){ee.emit("error",et)});return}}}},eh.prototype._onXHRProgress=function(){var ee=this;statusValid(ee._xhr)&&!ee._destroyed&&(ee._response||ee._connect(),ee._response._onXHRProgress())},eh.prototype._connect=function(){var ee=this;ee._destroyed||(ee._response=new ef(ee._xhr,ee._fetchResponse,ee._mode,ee._fetchTimer),ee._response.on("error",function(et){ee.emit("error",et)}),ee.emit("response",ee._response))},eh.prototype._write=function(ee,et,en){var ei=this;ei._body.push(ee),en()},eh.prototype.abort=eh.prototype.destroy=function(){var ee=this;ee._destroyed=!0,en.g.clearTimeout(ee._fetchTimer),ee._response&&(ee._response._destroyed=!0),ee._xhr?ee._xhr.abort():ee._fetchAbortController&&ee._fetchAbortController.abort()},eh.prototype.end=function(ee,et,en){var ei=this;"function"==typeof ee&&(en=ee,ee=void 0),ed.Writable.prototype.end.call(ei,ee,et,en)},eh.prototype.flushHeaders=function(){},eh.prototype.setTimeout=function(){},eh.prototype.setNoDelay=function(){},eh.prototype.setSocketKeepAlive=function(){};var ey=["accept-charset","accept-encoding","access-control-request-headers","access-control-request-method","connection","content-length","cookie","cookie2","date","dnt","expect","host","keep-alive","origin","referer","te","trailer","transfer-encoding","upgrade","via"]},254:function(ee,et,ei){var es=ei(301),eu=ei(782),ec=ei(726),ed=et.readyStates={UNSENT:0,OPENED:1,HEADERS_RECEIVED:2,LOADING:3,DONE:4},ef=et.IncomingMessage=function(ee,et,ei,eu){var ed=this;if(ec.Readable.call(ed),ed._mode=ei,ed.headers={},ed.rawHeaders=[],ed.trailers={},ed.rawTrailers=[],ed.on("end",function(){eo.nextTick(function(){ed.emit("close")})}),"fetch"===ei){if(ed._fetchResponse=et,ed.url=et.url,ed.statusCode=et.status,ed.statusMessage=et.statusText,et.headers.forEach(function(ee,et){ed.headers[et.toLowerCase()]=ee,ed.rawHeaders.push(et,ee)}),es.writableStream){var ef=new WritableStream({write:function(ee){return new Promise(function(et,en){ed._destroyed?en():ed.push(ea.from(ee))?et():ed._resumeFetch=et})},close:function(){en.g.clearTimeout(eu),ed._destroyed||ed.push(null)},abort:function(ee){ed._destroyed||ed.emit("error",ee)}});try{et.body.pipeTo(ef).catch(function(ee){en.g.clearTimeout(eu),ed._destroyed||ed.emit("error",ee)});return}catch(ee){}}var ep=et.body.getReader();function read(){ep.read().then(function(ee){if(!ed._destroyed){if(ee.done){en.g.clearTimeout(eu),ed.push(null);return}ed.push(ea.from(ee.value)),read()}}).catch(function(ee){en.g.clearTimeout(eu),ed._destroyed||ed.emit("error",ee)})}read()}else if(ed._xhr=ee,ed._pos=0,ed.url=ee.responseURL,ed.statusCode=ee.status,ed.statusMessage=ee.statusText,ee.getAllResponseHeaders().split(/\r?\n/).forEach(function(ee){var et=ee.match(/^([^:]+):\s*(.*)/);if(et){var en=et[1].toLowerCase();"set-cookie"===en?(void 0===ed.headers[en]&&(ed.headers[en]=[]),ed.headers[en].push(et[2])):void 0!==ed.headers[en]?ed.headers[en]+=", "+et[2]:ed.headers[en]=et[2],ed.rawHeaders.push(et[1],et[2])}}),ed._charset="x-user-defined",!es.overrideMimeType){var eh=ed.rawHeaders["mime-type"];if(eh){var ey=eh.match(/;\s*charset=([^;])(;|$)/);ey&&(ed._charset=ey[1].toLowerCase())}ed._charset||(ed._charset="utf-8")}};eu(ef,ec.Readable),ef.prototype._read=function(){var ee=this,et=ee._resumeFetch;et&&(ee._resumeFetch=null,et())},ef.prototype._onXHRProgress=function(){var ee=this,et=ee._xhr,ei=null;switch(ee._mode){case"text":if((ei=et.responseText).length>ee._pos){var eo=ei.substr(ee._pos);if("x-user-defined"===ee._charset){for(var es=ea.alloc(eo.length),eu=0;euee._pos&&(ee.push(ea.from(new Uint8Array(ec.result.slice(ee._pos)))),ee._pos=ec.result.byteLength)},ec.onload=function(){ee.push(null)},ec.readAsArrayBuffer(ei)}ee._xhr.readyState===ed.DONE&&"ms-stream"!==ee._mode&&ee.push(null)}},704:function(ee,et,en){"use strict";var ei=en(55).Buffer,eo=ei.isEncoding||function(ee){switch((ee=""+ee)&&ee.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function _normalizeEncoding(ee){var et;if(!ee)return"utf8";for(;;)switch(ee){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return ee;default:if(et)return;ee=(""+ee).toLowerCase(),et=!0}}function normalizeEncoding(ee){var et=_normalizeEncoding(ee);if("string"!=typeof et&&(ei.isEncoding===eo||!eo(ee)))throw Error("Unknown encoding: "+ee);return et||ee}function StringDecoder(ee){var et;switch(this.encoding=normalizeEncoding(ee),this.encoding){case"utf16le":this.text=utf16Text,this.end=utf16End,et=4;break;case"utf8":this.fillLast=utf8FillLast,et=4;break;case"base64":this.text=base64Text,this.end=base64End,et=3;break;default:this.write=simpleWrite,this.end=simpleEnd;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=ei.allocUnsafe(et)}function utf8CheckByte(ee){return ee<=127?0:ee>>5==6?2:ee>>4==14?3:ee>>3==30?4:ee>>6==2?-1:-2}function utf8CheckIncomplete(ee,et,en){var ei=et.length-1;if(ei=0?(eo>0&&(ee.lastNeed=eo-1),eo):--ei=0?(eo>0&&(ee.lastNeed=eo-2),eo):--ei=0?(eo>0&&(2===eo?eo=0:ee.lastNeed=eo-3),eo):0}function utf8CheckExtraBytes(ee,et,en){if((192&et[0])!=128)return ee.lastNeed=0,"�";if(ee.lastNeed>1&&et.length>1){if((192&et[1])!=128)return ee.lastNeed=1,"�";if(ee.lastNeed>2&&et.length>2&&(192&et[2])!=128)return ee.lastNeed=2,"�"}}function utf8FillLast(ee){var et=this.lastTotal-this.lastNeed,en=utf8CheckExtraBytes(this,ee,et);return void 0!==en?en:this.lastNeed<=ee.length?(ee.copy(this.lastChar,et,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):void(ee.copy(this.lastChar,et,0,ee.length),this.lastNeed-=ee.length)}function utf8Text(ee,et){var en=utf8CheckIncomplete(this,ee,et);if(!this.lastNeed)return ee.toString("utf8",et);this.lastTotal=en;var ei=ee.length-(en-this.lastNeed);return ee.copy(this.lastChar,0,ei),ee.toString("utf8",et,ei)}function utf8End(ee){var et=ee&&ee.length?this.write(ee):"";return this.lastNeed?et+"�":et}function utf16Text(ee,et){if((ee.length-et)%2==0){var en=ee.toString("utf16le",et);if(en){var ei=en.charCodeAt(en.length-1);if(ei>=55296&&ei<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=ee[ee.length-2],this.lastChar[1]=ee[ee.length-1],en.slice(0,-1)}return en}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=ee[ee.length-1],ee.toString("utf16le",et,ee.length-1)}function utf16End(ee){var et=ee&&ee.length?this.write(ee):"";if(this.lastNeed){var en=this.lastTotal-this.lastNeed;return et+this.lastChar.toString("utf16le",0,en)}return et}function base64Text(ee,et){var en=(ee.length-et)%3;return 0===en?ee.toString("base64",et):(this.lastNeed=3-en,this.lastTotal=3,1===en?this.lastChar[0]=ee[ee.length-1]:(this.lastChar[0]=ee[ee.length-2],this.lastChar[1]=ee[ee.length-1]),ee.toString("base64",et,ee.length-en))}function base64End(ee){var et=ee&&ee.length?this.write(ee):"";return this.lastNeed?et+this.lastChar.toString("base64",0,3-this.lastNeed):et}function simpleWrite(ee){return ee.toString(this.encoding)}function simpleEnd(ee){return ee&&ee.length?this.write(ee):""}et.s=StringDecoder,StringDecoder.prototype.write=function(ee){var et,en;if(0===ee.length)return"";if(this.lastNeed){if(void 0===(et=this.fillLast(ee)))return"";en=this.lastNeed,this.lastNeed=0}else en=0;return en-1?eo(en):en}},139:function(ee,et,en){"use strict";var ei=en(174),eo=en(925),ea=eo("%Function.prototype.apply%"),es=eo("%Function.prototype.call%"),eu=eo("%Reflect.apply%",!0)||ei.call(es,ea),ec=eo("%Object.getOwnPropertyDescriptor%",!0),ed=eo("%Object.defineProperty%",!0),ef=eo("%Math.max%");if(ed)try{ed({},"a",{value:1})}catch(ee){ed=null}ee.exports=function(ee){var et=eu(ei,es,arguments);return ec&&ed&&ec(et,"length").configurable&&ed(et,"length",{value:1+ef(0,ee.length-(arguments.length-1))}),et};var s=function(){return eu(ei,ea,arguments)};ed?ed(ee.exports,"apply",{value:s}):ee.exports.apply=s},144:function(ee){var et=Object.prototype.hasOwnProperty,en=Object.prototype.toString;ee.exports=function(ee,ei,eo){if("[object Function]"!==en.call(ei))throw TypeError("iterator must be a function");var ea=ee.length;if(ea===+ea)for(var es=0;es1&&"boolean"!=typeof et)throw new es('"allowMissing" argument must be a boolean');if(null===eE(/^%?[^%]*%?$/g,ee))throw new eo("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var en=j(ee),ei=en.length>0?en[0]:"",ea=E("%"+ei+"%",et),ec=ea.name,ed=ea.value,ef=!1,ep=ea.alias;ep&&(ei=ep[0],e_(en,ev([0,1],ep)));for(var eh=1,em=!0;eh=en.length){var e$=eu(ed,eg);ed=(em=!!e$)&&"get"in e$&&!("originalValue"in e$.get)?e$.get:ed[eg]}else em=eb(ed,eg),ed=ed[eg];em&&!ef&&(ey[ec]=ed)}}return ed}},925:function(ee,et,en){"use strict";var ei,eo=SyntaxError,ea=Function,es=TypeError,getEvalledConstructor=function(ee){try{return ea('"use strict"; return ('+ee+").constructor;")()}catch(ee){}},eu=Object.getOwnPropertyDescriptor;if(eu)try{eu({},"")}catch(ee){eu=null}var throwTypeError=function(){throw new es},ec=eu?function(){try{return arguments.callee,throwTypeError}catch(ee){try{return eu(arguments,"callee").get}catch(ee){return throwTypeError}}}():throwTypeError,ed=en(115)(),ef=en(504)(),ep=Object.getPrototypeOf||(ef?function(ee){return ee.__proto__}:null),eh={},ey="undefined"!=typeof Uint8Array&&ep?ep(Uint8Array):ei,em={"%AggregateError%":"undefined"==typeof AggregateError?ei:AggregateError,"%Array%":Array,"%ArrayBuffer%":"undefined"==typeof ArrayBuffer?ei:ArrayBuffer,"%ArrayIteratorPrototype%":ed&&ep?ep([][Symbol.iterator]()):ei,"%AsyncFromSyncIteratorPrototype%":ei,"%AsyncFunction%":eh,"%AsyncGenerator%":eh,"%AsyncGeneratorFunction%":eh,"%AsyncIteratorPrototype%":eh,"%Atomics%":"undefined"==typeof Atomics?ei:Atomics,"%BigInt%":"undefined"==typeof BigInt?ei:BigInt,"%BigInt64Array%":"undefined"==typeof BigInt64Array?ei:BigInt64Array,"%BigUint64Array%":"undefined"==typeof BigUint64Array?ei:BigUint64Array,"%Boolean%":Boolean,"%DataView%":"undefined"==typeof DataView?ei:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":Error,"%eval%":eval,"%EvalError%":EvalError,"%Float32Array%":"undefined"==typeof Float32Array?ei:Float32Array,"%Float64Array%":"undefined"==typeof Float64Array?ei:Float64Array,"%FinalizationRegistry%":"undefined"==typeof FinalizationRegistry?ei:FinalizationRegistry,"%Function%":ea,"%GeneratorFunction%":eh,"%Int8Array%":"undefined"==typeof Int8Array?ei:Int8Array,"%Int16Array%":"undefined"==typeof Int16Array?ei:Int16Array,"%Int32Array%":"undefined"==typeof Int32Array?ei:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":ed&&ep?ep(ep([][Symbol.iterator]())):ei,"%JSON%":"object"==typeof JSON?JSON:ei,"%Map%":"undefined"==typeof Map?ei:Map,"%MapIteratorPrototype%":"undefined"!=typeof Map&&ed&&ep?ep((new Map)[Symbol.iterator]()):ei,"%Math%":Math,"%Number%":Number,"%Object%":Object,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":"undefined"==typeof Promise?ei:Promise,"%Proxy%":"undefined"==typeof Proxy?ei:Proxy,"%RangeError%":RangeError,"%ReferenceError%":ReferenceError,"%Reflect%":"undefined"==typeof Reflect?ei:Reflect,"%RegExp%":RegExp,"%Set%":"undefined"==typeof Set?ei:Set,"%SetIteratorPrototype%":"undefined"!=typeof Set&&ed&&ep?ep((new Set)[Symbol.iterator]()):ei,"%SharedArrayBuffer%":"undefined"==typeof SharedArrayBuffer?ei:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":ed&&ep?ep(""[Symbol.iterator]()):ei,"%Symbol%":ed?Symbol:ei,"%SyntaxError%":eo,"%ThrowTypeError%":ec,"%TypedArray%":ey,"%TypeError%":es,"%Uint8Array%":"undefined"==typeof Uint8Array?ei:Uint8Array,"%Uint8ClampedArray%":"undefined"==typeof Uint8ClampedArray?ei:Uint8ClampedArray,"%Uint16Array%":"undefined"==typeof Uint16Array?ei:Uint16Array,"%Uint32Array%":"undefined"==typeof Uint32Array?ei:Uint32Array,"%URIError%":URIError,"%WeakMap%":"undefined"==typeof WeakMap?ei:WeakMap,"%WeakRef%":"undefined"==typeof WeakRef?ei:WeakRef,"%WeakSet%":"undefined"==typeof WeakSet?ei:WeakSet};if(ep)try{null.error}catch(ee){var eg=ep(ep(ee));em["%Error.prototype%"]=eg}var v=function doEval(ee){var et;if("%AsyncFunction%"===ee)et=getEvalledConstructor("async function () {}");else if("%GeneratorFunction%"===ee)et=getEvalledConstructor("function* () {}");else if("%AsyncGeneratorFunction%"===ee)et=getEvalledConstructor("async function* () {}");else if("%AsyncGenerator%"===ee){var en=doEval("%AsyncGeneratorFunction%");en&&(et=en.prototype)}else if("%AsyncIteratorPrototype%"===ee){var ei=doEval("%AsyncGenerator%");ei&&ep&&(et=ep(ei.prototype))}return em[ee]=et,et},eb={"%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"]},ev=en(174),e_=en(101),ew=ev.call(Function.call,Array.prototype.concat),eS=ev.call(Function.apply,Array.prototype.splice),eE=ev.call(Function.call,String.prototype.replace),eA=ev.call(Function.call,String.prototype.slice),e$=ev.call(Function.call,RegExp.prototype.exec),ex=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,eC=/\\(\\)?/g,I=function(ee){var et=eA(ee,0,1),en=eA(ee,-1);if("%"===et&&"%"!==en)throw new eo("invalid intrinsic syntax, expected closing `%`");if("%"===en&&"%"!==et)throw new eo("invalid intrinsic syntax, expected opening `%`");var ei=[];return eE(ee,ex,function(ee,et,en,eo){ei[ei.length]=en?eE(eo,eC,"$1"):et||ee}),ei},B=function(ee,et){var en,ei=ee;if(e_(eb,ei)&&(ei="%"+(en=eb[ei])[0]+"%"),e_(em,ei)){var ea=em[ei];if(ea===eh&&(ea=v(ei)),void 0===ea&&!et)throw new es("intrinsic "+ee+" exists, but is not available. Please file an issue!");return{alias:en,name:ei,value:ea}}throw new eo("intrinsic "+ee+" does not exist!")};ee.exports=function(ee,et){if("string"!=typeof ee||0===ee.length)throw new es("intrinsic name must be a non-empty string");if(arguments.length>1&&"boolean"!=typeof et)throw new es('"allowMissing" argument must be a boolean');if(null===e$(/^%?[^%]*%?$/,ee))throw new eo("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var en=I(ee),ei=en.length>0?en[0]:"",ea=B("%"+ei+"%",et),ec=ea.name,ed=ea.value,ef=!1,ep=ea.alias;ep&&(ei=ep[0],eS(en,ew([0,1],ep)));for(var eh=1,ey=!0;eh=en.length){var eE=eu(ed,eg);ed=(ey=!!eE)&&"get"in eE&&!("originalValue"in eE.get)?eE.get:ed[eg]}else ey=e_(ed,eg),ed=ed[eg];ey&&!ef&&(em[ec]=ed)}}return ed}},504:function(ee){"use strict";var et={foo:{}},en=Object;ee.exports=function(){return({__proto__:et}).foo===et.foo&&!(({__proto__:null})instanceof en)}},942:function(ee,et,en){"use strict";var ei="undefined"!=typeof Symbol&&Symbol,eo=en(773);ee.exports=function(){return"function"==typeof ei&&"function"==typeof Symbol&&"symbol"==typeof ei("foo")&&"symbol"==typeof Symbol("bar")&&eo()}},773:function(ee){"use strict";ee.exports=function(){if("function"!=typeof Symbol||"function"!=typeof Object.getOwnPropertySymbols)return!1;if("symbol"==typeof Symbol.iterator)return!0;var ee={},et=Symbol("test"),en=Object(et);if("string"==typeof et||"[object Symbol]"!==Object.prototype.toString.call(et)||"[object Symbol]"!==Object.prototype.toString.call(en))return!1;var ei=42;for(et in ee[et]=ei,ee)return!1;if("function"==typeof Object.keys&&0!==Object.keys(ee).length||"function"==typeof Object.getOwnPropertyNames&&0!==Object.getOwnPropertyNames(ee).length)return!1;var eo=Object.getOwnPropertySymbols(ee);if(1!==eo.length||eo[0]!==et||!Object.prototype.propertyIsEnumerable.call(ee,et))return!1;if("function"==typeof Object.getOwnPropertyDescriptor){var ea=Object.getOwnPropertyDescriptor(ee,et);if(ea.value!==ei||!0!==ea.enumerable)return!1}return!0}},115:function(ee,et,en){"use strict";var ei="undefined"!=typeof Symbol&&Symbol,eo=en(832);ee.exports=function(){return"function"==typeof ei&&"function"==typeof Symbol&&"symbol"==typeof ei("foo")&&"symbol"==typeof Symbol("bar")&&eo()}},832:function(ee){"use strict";ee.exports=function(){if("function"!=typeof Symbol||"function"!=typeof Object.getOwnPropertySymbols)return!1;if("symbol"==typeof Symbol.iterator)return!0;var ee={},et=Symbol("test"),en=Object(et);if("string"==typeof et||"[object Symbol]"!==Object.prototype.toString.call(et)||"[object Symbol]"!==Object.prototype.toString.call(en))return!1;var ei=42;for(et in ee[et]=ei,ee)return!1;if("function"==typeof Object.keys&&0!==Object.keys(ee).length||"function"==typeof Object.getOwnPropertyNames&&0!==Object.getOwnPropertyNames(ee).length)return!1;var eo=Object.getOwnPropertySymbols(ee);if(1!==eo.length||eo[0]!==et||!Object.prototype.propertyIsEnumerable.call(ee,et))return!1;if("function"==typeof Object.getOwnPropertyDescriptor){var ea=Object.getOwnPropertyDescriptor(ee,et);if(ea.value!==ei||!0!==ea.enumerable)return!1}return!0}},101:function(ee,et,en){"use strict";var ei=en(174);ee.exports=ei.call(Function.call,Object.prototype.hasOwnProperty)},782:function(ee){"function"==typeof Object.create?ee.exports=function(ee,et){et&&(ee.super_=et,ee.prototype=Object.create(et.prototype,{constructor:{value:ee,enumerable:!1,writable:!0,configurable:!0}}))}:ee.exports=function(ee,et){if(et){ee.super_=et;var TempCtor=function(){};TempCtor.prototype=et.prototype,ee.prototype=new TempCtor,ee.prototype.constructor=ee}}},157:function(ee){"use strict";var et="function"==typeof Symbol&&"symbol"==typeof Symbol.toStringTag,en=Object.prototype.toString,o=function(ee){return(!et||!ee||"object"!=typeof ee||!(Symbol.toStringTag in ee))&&"[object Arguments]"===en.call(ee)},n=function(ee){return!!o(ee)||null!==ee&&"object"==typeof ee&&"number"==typeof ee.length&&ee.length>=0&&"[object Array]"!==en.call(ee)&&"[object Function]"===en.call(ee.callee)},ei=function(){return o(arguments)}();o.isLegacyArguments=n,ee.exports=ei?o:n},391:function(ee){"use strict";var et=Object.prototype.toString,en=Function.prototype.toString,ei=/^\s*(?:function)?\*/,eo="function"==typeof Symbol&&"symbol"==typeof Symbol.toStringTag,ea=Object.getPrototypeOf,es=function(){if(!eo)return!1;try{return Function("return function*() {}")()}catch(ee){}}(),eu=es?ea(es):{};ee.exports=function(ee){return"function"==typeof ee&&(!!ei.test(en.call(ee))||(eo?ea(ee)===eu:"[object GeneratorFunction]"===et.call(ee)))}},994:function(ee,et,ei){"use strict";var eo=ei(144),ea=ei(349),es=ei(256),eu=es("Object.prototype.toString"),ec=ei(942)()&&"symbol"==typeof Symbol.toStringTag,ed=ea(),ef=es("Array.prototype.indexOf",!0)||function(ee,et){for(var en=0;en-1)}},369:function(ee){ee.exports=function(ee){return ee instanceof eo}},584:function(ee,et,en){"use strict";var ei=en(157),eo=en(391),ea=en(490),es=en(994);function uncurryThis(ee){return ee.call.bind(ee)}var eu="undefined"!=typeof BigInt,ec="undefined"!=typeof Symbol,ed=uncurryThis(Object.prototype.toString),ef=uncurryThis(Number.prototype.valueOf),ep=uncurryThis(String.prototype.valueOf),eh=uncurryThis(Boolean.prototype.valueOf);if(eu)var ey=uncurryThis(BigInt.prototype.valueOf);if(ec)var em=uncurryThis(Symbol.prototype.valueOf);function checkBoxedPrimitive(ee,et){if("object"!=typeof ee)return!1;try{return et(ee),!0}catch(ee){return!1}}function isPromise(ee){return"undefined"!=typeof Promise&&ee instanceof Promise||null!==ee&&"object"==typeof ee&&"function"==typeof ee.then&&"function"==typeof ee.catch}function isArrayBufferView(ee){return"undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(ee):es(ee)||isDataView(ee)}function isUint8Array(ee){return"Uint8Array"===ea(ee)}function isUint8ClampedArray(ee){return"Uint8ClampedArray"===ea(ee)}function isUint16Array(ee){return"Uint16Array"===ea(ee)}function isUint32Array(ee){return"Uint32Array"===ea(ee)}function isInt8Array(ee){return"Int8Array"===ea(ee)}function isInt16Array(ee){return"Int16Array"===ea(ee)}function isInt32Array(ee){return"Int32Array"===ea(ee)}function isFloat32Array(ee){return"Float32Array"===ea(ee)}function isFloat64Array(ee){return"Float64Array"===ea(ee)}function isBigInt64Array(ee){return"BigInt64Array"===ea(ee)}function isBigUint64Array(ee){return"BigUint64Array"===ea(ee)}function isMapToString(ee){return"[object Map]"===ed(ee)}function isMap(ee){return"undefined"!=typeof Map&&(isMapToString.working?isMapToString(ee):ee instanceof Map)}function isSetToString(ee){return"[object Set]"===ed(ee)}function isSet(ee){return"undefined"!=typeof Set&&(isSetToString.working?isSetToString(ee):ee instanceof Set)}function isWeakMapToString(ee){return"[object WeakMap]"===ed(ee)}function isWeakMap(ee){return"undefined"!=typeof WeakMap&&(isWeakMapToString.working?isWeakMapToString(ee):ee instanceof WeakMap)}function isWeakSetToString(ee){return"[object WeakSet]"===ed(ee)}function isWeakSet(ee){return isWeakSetToString(ee)}function isArrayBufferToString(ee){return"[object ArrayBuffer]"===ed(ee)}function isArrayBuffer(ee){return"undefined"!=typeof ArrayBuffer&&(isArrayBufferToString.working?isArrayBufferToString(ee):ee instanceof ArrayBuffer)}function isDataViewToString(ee){return"[object DataView]"===ed(ee)}function isDataView(ee){return"undefined"!=typeof DataView&&(isDataViewToString.working?isDataViewToString(ee):ee instanceof DataView)}et.isArgumentsObject=ei,et.isGeneratorFunction=eo,et.isTypedArray=es,et.isPromise=isPromise,et.isArrayBufferView=isArrayBufferView,et.isUint8Array=isUint8Array,et.isUint8ClampedArray=isUint8ClampedArray,et.isUint16Array=isUint16Array,et.isUint32Array=isUint32Array,et.isInt8Array=isInt8Array,et.isInt16Array=isInt16Array,et.isInt32Array=isInt32Array,et.isFloat32Array=isFloat32Array,et.isFloat64Array=isFloat64Array,et.isBigInt64Array=isBigInt64Array,et.isBigUint64Array=isBigUint64Array,isMapToString.working="undefined"!=typeof Map&&isMapToString(new Map),et.isMap=isMap,isSetToString.working="undefined"!=typeof Set&&isSetToString(new Set),et.isSet=isSet,isWeakMapToString.working="undefined"!=typeof WeakMap&&isWeakMapToString(new WeakMap),et.isWeakMap=isWeakMap,isWeakSetToString.working="undefined"!=typeof WeakSet&&isWeakSetToString(new WeakSet),et.isWeakSet=isWeakSet,isArrayBufferToString.working="undefined"!=typeof ArrayBuffer&&isArrayBufferToString(new ArrayBuffer),et.isArrayBuffer=isArrayBuffer,isDataViewToString.working="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof DataView&&isDataViewToString(new DataView(new ArrayBuffer(1),0,1)),et.isDataView=isDataView;var eg="undefined"!=typeof SharedArrayBuffer?SharedArrayBuffer:void 0;function isSharedArrayBufferToString(ee){return"[object SharedArrayBuffer]"===ed(ee)}function isSharedArrayBuffer(ee){return void 0!==eg&&(void 0===isSharedArrayBufferToString.working&&(isSharedArrayBufferToString.working=isSharedArrayBufferToString(new eg)),isSharedArrayBufferToString.working?isSharedArrayBufferToString(ee):ee instanceof eg)}function isAsyncFunction(ee){return"[object AsyncFunction]"===ed(ee)}function isMapIterator(ee){return"[object Map Iterator]"===ed(ee)}function isSetIterator(ee){return"[object Set Iterator]"===ed(ee)}function isGeneratorObject(ee){return"[object Generator]"===ed(ee)}function isWebAssemblyCompiledModule(ee){return"[object WebAssembly.Module]"===ed(ee)}function isNumberObject(ee){return checkBoxedPrimitive(ee,ef)}function isStringObject(ee){return checkBoxedPrimitive(ee,ep)}function isBooleanObject(ee){return checkBoxedPrimitive(ee,eh)}function isBigIntObject(ee){return eu&&checkBoxedPrimitive(ee,ey)}function isSymbolObject(ee){return ec&&checkBoxedPrimitive(ee,em)}function isBoxedPrimitive(ee){return isNumberObject(ee)||isStringObject(ee)||isBooleanObject(ee)||isBigIntObject(ee)||isSymbolObject(ee)}function isAnyArrayBuffer(ee){return"undefined"!=typeof Uint8Array&&(isArrayBuffer(ee)||isSharedArrayBuffer(ee))}et.isSharedArrayBuffer=isSharedArrayBuffer,et.isAsyncFunction=isAsyncFunction,et.isMapIterator=isMapIterator,et.isSetIterator=isSetIterator,et.isGeneratorObject=isGeneratorObject,et.isWebAssemblyCompiledModule=isWebAssemblyCompiledModule,et.isNumberObject=isNumberObject,et.isStringObject=isStringObject,et.isBooleanObject=isBooleanObject,et.isBigIntObject=isBigIntObject,et.isSymbolObject=isSymbolObject,et.isBoxedPrimitive=isBoxedPrimitive,et.isAnyArrayBuffer=isAnyArrayBuffer,["isProxy","isExternal","isModuleNamespaceObject"].forEach(function(ee){Object.defineProperty(et,ee,{enumerable:!1,value:function(){throw Error(ee+" is not supported in userland")}})})},177:function(ee,et,en){var ei=Object.getOwnPropertyDescriptors||function(ee){for(var et=Object.keys(ee),en={},ei=0;ei=ea)return ee;switch(ee){case"%s":return String(ei[en++]);case"%d":return Number(ei[en++]);case"%j":try{return JSON.stringify(ei[en++])}catch(ee){return"[Circular]"}default:return ee}}),eu=ei[en];en=3&&(ei.depth=arguments[2]),arguments.length>=4&&(ei.colors=arguments[3]),isBoolean(en)?ei.showHidden=en:en&&et._extend(ei,en),isUndefined(ei.showHidden)&&(ei.showHidden=!1),isUndefined(ei.depth)&&(ei.depth=2),isUndefined(ei.colors)&&(ei.colors=!1),isUndefined(ei.customInspect)&&(ei.customInspect=!0),ei.colors&&(ei.stylize=stylizeWithColor),formatValue(ei,ee,ei.depth)}function stylizeWithColor(ee,et){var en=inspect.styles[et];return en?"\x1b["+inspect.colors[en][0]+"m"+ee+"\x1b["+inspect.colors[en][1]+"m":ee}function stylizeNoColor(ee,et){return ee}function arrayToHash(ee){var et={};return ee.forEach(function(ee,en){et[ee]=!0}),et}function formatValue(ee,en,ei){if(ee.customInspect&&en&&isFunction(en.inspect)&&en.inspect!==et.inspect&&!(en.constructor&&en.constructor.prototype===en)){var eo,ea=en.inspect(ei,ee);return isString(ea)||(ea=formatValue(ee,ea,ei)),ea}var es=formatPrimitive(ee,en);if(es)return es;var eu=Object.keys(en),ec=arrayToHash(eu);if(ee.showHidden&&(eu=Object.getOwnPropertyNames(en)),isError(en)&&(eu.indexOf("message")>=0||eu.indexOf("description")>=0))return formatError(en);if(0===eu.length){if(isFunction(en)){var ed=en.name?": "+en.name:"";return ee.stylize("[Function"+ed+"]","special")}if(isRegExp(en))return ee.stylize(RegExp.prototype.toString.call(en),"regexp");if(isDate(en))return ee.stylize(Date.prototype.toString.call(en),"date");if(isError(en))return formatError(en)}var ef="",ep=!1,eh=["{","}"];return(isArray(en)&&(ep=!0,eh=["[","]"]),isFunction(en)&&(ef=" [Function"+(en.name?": "+en.name:"")+"]"),isRegExp(en)&&(ef=" "+RegExp.prototype.toString.call(en)),isDate(en)&&(ef=" "+Date.prototype.toUTCString.call(en)),isError(en)&&(ef=" "+formatError(en)),0!==eu.length||ep&&0!=en.length)?ei<0?isRegExp(en)?ee.stylize(RegExp.prototype.toString.call(en),"regexp"):ee.stylize("[Object]","special"):(ee.seen.push(en),eo=ep?formatArray(ee,en,ei,ec,eu):eu.map(function(et){return formatProperty(ee,en,ei,ec,et,ep)}),ee.seen.pop(),reduceToSingleString(eo,ef,eh)):eh[0]+ef+eh[1]}function formatPrimitive(ee,et){if(isUndefined(et))return ee.stylize("undefined","undefined");if(isString(et)){var en="'"+JSON.stringify(et).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return ee.stylize(en,"string")}return isNumber(et)?ee.stylize(""+et,"number"):isBoolean(et)?ee.stylize(""+et,"boolean"):isNull(et)?ee.stylize("null","null"):void 0}function formatError(ee){return"["+Error.prototype.toString.call(ee)+"]"}function formatArray(ee,et,en,ei,eo){for(var ea=[],es=0,eu=et.length;esee.seen.indexOf(ec.value)?(eu=isNull(en)?formatValue(ee,ec.value,null):formatValue(ee,ec.value,en-1)).indexOf("\n")>-1&&(eu=ea?eu.split("\n").map(function(ee){return" "+ee}).join("\n").substr(2):"\n"+eu.split("\n").map(function(ee){return" "+ee}).join("\n")):eu=ee.stylize("[Circular]","special")),isUndefined(es)){if(ea&&eo.match(/^\d+$/))return eu;(es=JSON.stringify(""+eo)).match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(es=es.substr(1,es.length-2),es=ee.stylize(es,"name")):(es=es.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),es=ee.stylize(es,"string"))}return es+": "+eu}function reduceToSingleString(ee,et,en){var ei=0;return ee.reduce(function(ee,et){return ei++,et.indexOf("\n")>=0&&ei++,ee+et.replace(/\u001b\[\d\d?m/g,"").length+1},0)>60?en[0]+(""===et?"":et+"\n ")+" "+ee.join(",\n ")+" "+en[1]:en[0]+et+" "+ee.join(", ")+" "+en[1]}function isArray(ee){return Array.isArray(ee)}function isBoolean(ee){return"boolean"==typeof ee}function isNull(ee){return null===ee}function isNullOrUndefined(ee){return null==ee}function isNumber(ee){return"number"==typeof ee}function isString(ee){return"string"==typeof ee}function isSymbol(ee){return"symbol"==typeof ee}function isUndefined(ee){return void 0===ee}function isRegExp(ee){return isObject(ee)&&"[object RegExp]"===objectToString(ee)}function isObject(ee){return"object"==typeof ee&&null!==ee}function isDate(ee){return isObject(ee)&&"[object Date]"===objectToString(ee)}function isError(ee){return isObject(ee)&&("[object Error]"===objectToString(ee)||ee instanceof Error)}function isFunction(ee){return"function"==typeof ee}function isPrimitive(ee){return null===ee||"boolean"==typeof ee||"number"==typeof ee||"string"==typeof ee||"symbol"==typeof ee||void 0===ee}function objectToString(ee){return Object.prototype.toString.call(ee)}function pad(ee){return ee<10?"0"+ee.toString(10):ee.toString(10)}et.debuglog=function(ee){if(!es[ee=ee.toUpperCase()]){if(eu.test(ee)){var en=ea.pid;es[ee]=function(){var ei=et.format.apply(et,arguments);console.error("%s %d: %s",ee,en,ei)}}else es[ee]=function(){}}return es[ee]},et.inspect=inspect,inspect.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},inspect.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"},et.types=en(584),et.isArray=isArray,et.isBoolean=isBoolean,et.isNull=isNull,et.isNullOrUndefined=isNullOrUndefined,et.isNumber=isNumber,et.isString=isString,et.isSymbol=isSymbol,et.isUndefined=isUndefined,et.isRegExp=isRegExp,et.types.isRegExp=isRegExp,et.isObject=isObject,et.isDate=isDate,et.types.isDate=isDate,et.isError=isError,et.types.isNativeError=isError,et.isFunction=isFunction,et.isPrimitive=isPrimitive,et.isBuffer=en(369);var ed=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function timestamp(){var ee=new Date,et=[pad(ee.getHours()),pad(ee.getMinutes()),pad(ee.getSeconds())].join(":");return[ee.getDate(),ed[ee.getMonth()],et].join(" ")}function hasOwnProperty(ee,et){return Object.prototype.hasOwnProperty.call(ee,et)}et.log=function(){console.log("%s - %s",timestamp(),et.format.apply(et,arguments))},et.inherits=en(782),et._extend=function(ee,et){if(!et||!isObject(et))return ee;for(var en=Object.keys(et),ei=en.length;ei--;)ee[en[ei]]=et[en[ei]];return ee};var ef="undefined"!=typeof Symbol?Symbol("util.promisify.custom"):void 0;function callbackifyOnRejected(ee,et){if(!ee){var en=Error("Promise was rejected with a falsy value");en.reason=ee,ee=en}return et(ee)}function callbackify(ee){if("function"!=typeof ee)throw TypeError('The "original" argument must be of type Function');function callbackified(){for(var et=[],en=0;enee.toLowerCase()===ea);if(void 0!==es)return ei.ReflectAdapter.get(et,es,eo)},set(et,en,eo,ea){if("symbol"==typeof en)return ei.ReflectAdapter.set(et,en,eo,ea);let es=en.toLowerCase(),eu=Object.keys(ee).find(ee=>ee.toLowerCase()===es);return ei.ReflectAdapter.set(et,eu??en,eo,ea)},has(et,en){if("symbol"==typeof en)return ei.ReflectAdapter.has(et,en);let eo=en.toLowerCase(),ea=Object.keys(ee).find(ee=>ee.toLowerCase()===eo);return void 0!==ea&&ei.ReflectAdapter.has(et,ea)},deleteProperty(et,en){if("symbol"==typeof en)return ei.ReflectAdapter.deleteProperty(et,en);let eo=en.toLowerCase(),ea=Object.keys(ee).find(ee=>ee.toLowerCase()===eo);return void 0===ea||ei.ReflectAdapter.deleteProperty(et,ea)}})}static seal(ee){return new Proxy(ee,{get(ee,et,en){switch(et){case"append":case"delete":case"set":return ReadonlyHeadersError.callable;default:return ei.ReflectAdapter.get(ee,et,en)}}})}merge(ee){return Array.isArray(ee)?ee.join(", "):ee}static from(ee){return ee instanceof Headers?ee:new HeadersAdapter(ee)}append(ee,et){let en=this.headers[ee];"string"==typeof en?this.headers[ee]=[en,et]:Array.isArray(en)?en.push(et):this.headers[ee]=et}delete(ee){delete this.headers[ee]}get(ee){let et=this.headers[ee];return void 0!==et?this.merge(et):null}has(ee){return void 0!==this.headers[ee]}set(ee,et){this.headers[ee]=et}forEach(ee,et){for(let[en,ei]of this.entries())ee.call(et,ei,en,this)}*entries(){for(let ee of Object.keys(this.headers)){let et=ee.toLowerCase(),en=this.get(et);yield[et,en]}}*keys(){for(let ee of Object.keys(this.headers)){let et=ee.toLowerCase();yield et}}*values(){for(let ee of Object.keys(this.headers)){let et=this.get(ee);yield et}}[Symbol.iterator](){return this.entries()}}},47246:function(ee,et){"use strict";Object.defineProperty(et,"__esModule",{value:!0}),Object.defineProperty(et,"ReflectAdapter",{enumerable:!0,get:function(){return ReflectAdapter}});let ReflectAdapter=class ReflectAdapter{static get(ee,et,en){let ei=Reflect.get(ee,et,en);return"function"==typeof ei?ei.bind(ee):ei}static set(ee,et,en,ei){return Reflect.set(ee,et,en,ei)}static has(ee,et){return Reflect.has(ee,et)}static deleteProperty(ee,et){return Reflect.deleteProperty(ee,et)}}},9407:function(ee,et,en){"use strict";Object.defineProperty(et,"__esModule",{value:!0}),function(ee,et){for(var en in et)Object.defineProperty(ee,en,{enumerable:!0,get:et[en]})}(et,{ReadonlyRequestCookiesError:function(){return ReadonlyRequestCookiesError},RequestCookiesAdapter:function(){return RequestCookiesAdapter},getModifiedCookieValues:function(){return getModifiedCookieValues},appendMutableCookies:function(){return appendMutableCookies},MutableRequestCookiesAdapter:function(){return MutableRequestCookiesAdapter}});let ei=en(80255),eo=en(47246);let ReadonlyRequestCookiesError=class ReadonlyRequestCookiesError extends Error{constructor(){super("Cookies can only be modified in a Server Action or Route Handler. Read more: https://nextjs.org/docs/app/api-reference/functions/cookies#cookiessetname-value-options")}static callable(){throw new ReadonlyRequestCookiesError}};let RequestCookiesAdapter=class RequestCookiesAdapter{static seal(ee){return new Proxy(ee,{get(ee,et,en){switch(et){case"clear":case"delete":case"set":return ReadonlyRequestCookiesError.callable;default:return eo.ReflectAdapter.get(ee,et,en)}}})}};let ea=Symbol.for("next.mutated.cookies");function getModifiedCookieValues(ee){let et=ee[ea];return et&&Array.isArray(et)&&0!==et.length?et:[]}function appendMutableCookies(ee,et){let en=getModifiedCookieValues(et);if(0===en.length)return!1;let eo=new ei.ResponseCookies(ee),ea=eo.getAll();for(let ee of en)eo.set(ee);for(let ee of ea)eo.set(ee);return!0}let MutableRequestCookiesAdapter=class MutableRequestCookiesAdapter{static wrap(ee,et){let en=new ei.ResponseCookies(new Headers);for(let et of ee.getAll())en.set(et);let es=[],eu=new Set,updateResponseCookies=()=>{var ee;let eo=null==fetch.__nextGetStaticStore?void 0:null==(ee=fetch.__nextGetStaticStore.call(fetch))?void 0:ee.getStore();eo&&(eo.pathWasRevalidated=!0);let ea=en.getAll();if(es=ea.filter(ee=>eu.has(ee.name)),et){let ee=[];for(let et of es){let en=new ei.ResponseCookies(new Headers);en.set(et),ee.push(en.toString())}et(ee)}};return new Proxy(en,{get(ee,et,en){switch(et){case ea:return es;case"delete":return function(...et){eu.add("string"==typeof et[0]?et[0]:et[0].name);try{ee.delete(...et)}finally{updateResponseCookies()}};case"set":return function(...et){eu.add("string"==typeof et[0]?et[0]:et[0].name);try{return ee.set(...et)}finally{updateResponseCookies()}};default:return eo.ReflectAdapter.get(ee,et,en)}}})}}},80255:function(ee,et,en){"use strict";Object.defineProperty(et,"__esModule",{value:!0}),function(ee,et){for(var en in et)Object.defineProperty(ee,en,{enumerable:!0,get:et[en]})}(et,{RequestCookies:function(){return ei.RequestCookies},ResponseCookies:function(){return ei.ResponseCookies}});let ei=en(89079)},14970:function(ee,et,en){ee.exports=en(27439)},25675:function(ee,et,en){ee.exports=en(645)},79169:function(ee,et,en){et.OAuth=en(33503).OAuth,et.OAuthEcho=en(33503).OAuthEcho,et.OAuth2=en(72327).OAuth2},58742:function(ee){ee.exports.isAnEarlyCloseHost=function(ee){return ee&&ee.match(".*google(apis)?.com$")}},33503:function(ee,et,en){var ei=en(48764).Buffer,eo=en(42474),ea=en(80969),es=en(22321),eu=en(78428),ec=en(11987),ed=en(97334),ef=en(58742);et.OAuth=function(ee,et,en,ei,eo,ea,es,eu,ec){if(this._isEcho=!1,this._requestUrl=ee,this._accessUrl=et,this._consumerKey=en,this._consumerSecret=this._encodeData(ei),"RSA-SHA1"==es&&(this._privateKey=ei),this._version=eo,void 0===ea?this._authorize_callback="oob":this._authorize_callback=ea,"PLAINTEXT"!=es&&"HMAC-SHA1"!=es&&"RSA-SHA1"!=es)throw Error("Un-supported signature method: "+es);this._signatureMethod=es,this._nonceSize=eu||32,this._headers=ec||{Accept:"*/*",Connection:"close","User-Agent":"Node authentication"},this._clientOptions=this._defaultClientOptions={requestTokenHttpMethod:"POST",accessTokenHttpMethod:"POST",followRedirects:!0},this._oauthParameterSeperator=","},et.OAuthEcho=function(ee,et,en,ei,eo,ea,es,eu){if(this._isEcho=!0,this._realm=ee,this._verifyCredentials=et,this._consumerKey=en,this._consumerSecret=this._encodeData(ei),"RSA-SHA1"==ea&&(this._privateKey=ei),this._version=eo,"PLAINTEXT"!=ea&&"HMAC-SHA1"!=ea&&"RSA-SHA1"!=ea)throw Error("Un-supported signature method: "+ea);this._signatureMethod=ea,this._nonceSize=es||32,this._headers=eu||{Accept:"*/*",Connection:"close","User-Agent":"Node authentication"},this._oauthParameterSeperator=","},et.OAuthEcho.prototype=et.OAuth.prototype,et.OAuth.prototype._getTimestamp=function(){return Math.floor(new Date().getTime()/1e3)},et.OAuth.prototype._encodeData=function(ee){return null==ee||""==ee?"":encodeURIComponent(ee).replace(/\!/g,"%21").replace(/\'/g,"%27").replace(/\(/g,"%28").replace(/\)/g,"%29").replace(/\*/g,"%2A")},et.OAuth.prototype._decodeData=function(ee){return null!=ee&&(ee=ee.replace(/\+/g," ")),decodeURIComponent(ee)},et.OAuth.prototype._getSignature=function(ee,et,en,ei){var eo=this._createSignatureBase(ee,et,en);return this._createSignature(eo,ei)},et.OAuth.prototype._normalizeUrl=function(ee){var et=ec.parse(ee,!0),en="";return et.port&&("http:"==et.protocol&&"80"!=et.port||"https:"==et.protocol&&"443"!=et.port)&&(en=":"+et.port),et.pathname&&""!=et.pathname||(et.pathname="/"),et.protocol+"//"+et.hostname+en+et.pathname},et.OAuth.prototype._isParameterNameAnOAuthParameter=function(ee){var et=ee.match("^oauth_");return!!et&&"oauth_"===et[0]},et.OAuth.prototype._buildAuthorizationHeaders=function(ee){var et="OAuth ";this._isEcho&&(et+='realm="'+this._realm+'",');for(var en=0;en=200&&ei.statusCode<=299?ep(null,eS,ei):(301==ei.statusCode||302==ei.statusCode)&&ew.followRedirects&&ei.headers&&ei.headers.location?eE._performSecureRequest(ee,et,en,ei.headers.location,ea,es,eu,ep):ep({statusCode:ei.statusCode,data:eS},eS,ei))};ey.on("response",function(ee){ee.setEncoding("utf8"),ee.on("data",function(ee){eS+=ee}),ee.on("end",function(){passBackControl(ee)}),ee.on("close",function(){eA&&passBackControl(ee)})}),ey.on("error",function(ee){e$||(e$=!0,ep(ee))}),("POST"==en||"PUT"==en)&&null!=es&&""!=es&&ey.write(es),ey.end()},et.OAuth.prototype.setClientOptions=function(ee){var et,en={},ei=Object.prototype.hasOwnProperty;for(et in this._defaultClientOptions)ei.call(ee,et)?en[et]=ee[et]:en[et]=this._defaultClientOptions[et];this._clientOptions=en},et.OAuth.prototype.getOAuthAccessToken=function(ee,et,en,ei){var eo={};"function"==typeof en?ei=en:eo.oauth_verifier=en,this._performSecureRequest(ee,et,this._clientOptions.accessTokenHttpMethod,this._accessUrl,eo,null,null,function(ee,et,en){if(ee)ei(ee);else{var eo=ed.parse(et),ea=eo.oauth_token;delete eo.oauth_token;var es=eo.oauth_token_secret;delete eo.oauth_token_secret,ei(null,ea,es,eo)}})},et.OAuth.prototype.getProtectedResource=function(ee,et,en,ei,eo){this._performSecureRequest(en,ei,et,ee,null,"",null,eo)},et.OAuth.prototype.delete=function(ee,et,en,ei){return this._performSecureRequest(et,en,"DELETE",ee,null,"",null,ei)},et.OAuth.prototype.get=function(ee,et,en,ei){return this._performSecureRequest(et,en,"GET",ee,null,"",null,ei)},et.OAuth.prototype._putOrPost=function(ee,et,en,eo,ea,es,eu){var ec=null;return"function"==typeof es&&(eu=es,es=null),"string"==typeof ea||ei.isBuffer(ea)||(es="application/x-www-form-urlencoded",ec=ea,ea=null),this._performSecureRequest(en,eo,ee,et,ec,ea,es,eu)},et.OAuth.prototype.put=function(ee,et,en,ei,eo,ea){return this._putOrPost("PUT",ee,et,en,ei,eo,ea)},et.OAuth.prototype.post=function(ee,et,en,ei,eo,ea){return this._putOrPost("POST",ee,et,en,ei,eo,ea)},et.OAuth.prototype.getOAuthRequestToken=function(ee,et){"function"==typeof ee&&(et=ee,ee={}),this._authorize_callback&&(ee.oauth_callback=this._authorize_callback),this._performSecureRequest(null,null,this._clientOptions.requestTokenHttpMethod,this._requestUrl,ee,null,null,function(ee,en,ei){if(ee)et(ee);else{var eo=ed.parse(en),ea=eo.oauth_token,es=eo.oauth_token_secret;delete eo.oauth_token,delete eo.oauth_token_secret,et(null,ea,es,eo)}})},et.OAuth.prototype.signUrl=function(ee,et,en,ei){if(void 0===ei)var ei="GET";for(var eo=this._prepareParameters(et,en,ei,ee,{}),ea=ec.parse(ee,!1),es="",eu=0;eu=200&&ee.statusCode<=299||301==ee.statusCode||302==ee.statusCode?ei(null,et,ee):ei({statusCode:ee.statusCode,data:et}))}var es="";this._agent&&(et.agent=this._agent);var eu=ee.request(et);eu.on("response",function(ee){ee.on("data",function(ee){es+=ee}),ee.on("close",function(et){eo&&passBackControl(ee,es)}),ee.addListener("end",function(){passBackControl(ee,es)})}),eu.on("error",function(ee){ea=!0,ei(ee)}),("POST"==et.method||"PUT"==et.method)&&en&&eu.write(en),eu.end()},et.OAuth2.prototype.getAuthorizeUrl=function(ee){var ee=ee||{};return ee.client_id=this._clientId,this._baseSite+this._authorizeUrl+"?"+eo.stringify(ee)},et.OAuth2.prototype.getOAuthAccessToken=function(ee,et,en){var et=et||{};et.client_id=this._clientId,et.client_secret=this._clientSecret;var ei="refresh_token"===et.grant_type?"refresh_token":"code";et[ei]=ee;var ea=eo.stringify(et),es={"Content-Type":"application/x-www-form-urlencoded"};this._request("POST",this._getAccessTokenUrl(),es,ea,null,function(ee,et,ei){if(ee)en(ee);else{try{ea=JSON.parse(et)}catch(ee){ea=eo.parse(et)}var ea,es=ea.access_token,eu=ea.refresh_token;delete ea.refresh_token,en(null,es,eu,ea)}})},et.OAuth2.prototype.getProtectedResource=function(ee,et,en){this._request("GET",ee,{},"",et,en)},et.OAuth2.prototype.get=function(ee,et,en){if(this._useAuthorizationHeaderForGET){var ei={Authorization:this.buildAuthHeader(et)};et=null}else ei={};this._request("GET",ee,ei,"",et,en)}},80969:function(ee,et){var en="=";function b64_hmac_sha1(ee,et){return rstr2b64(rstr_hmac_sha1(str2rstr_utf8(ee),str2rstr_utf8(et)))}function rstr_hmac_sha1(ee,et){var en=rstr2binb(ee);en.length>16&&(en=binb_sha1(en,8*ee.length));for(var ei=Array(16),eo=Array(16),ea=0;ea<16;ea++)ei[ea]=909522486^en[ea],eo[ea]=1549556828^en[ea];var es=binb_sha1(ei.concat(rstr2binb(et)),512+8*et.length);return binb2rstr(binb_sha1(eo.concat(es),672))}function rstr2b64(ee){for(var et="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",ei="",eo=ee.length,ea=0;ea8*ee.length?ei+=en:ei+=et.charAt(es>>>6*(3-eu)&63);return ei}function str2rstr_utf8(ee){for(var et,en,ei="",eo=-1;++eo>>6&31,128|63&et):et<=65535?ei+=String.fromCharCode(224|et>>>12&15,128|et>>>6&63,128|63&et):et<=2097151&&(ei+=String.fromCharCode(240|et>>>18&7,128|et>>>12&63,128|et>>>6&63,128|63&et));return ei}function rstr2binb(ee){for(var et=Array(ee.length>>2),en=0;en>5]|=(255&ee.charCodeAt(en/8))<<24-en%32;return et}function binb2rstr(ee){for(var et="",en=0;en<32*ee.length;en+=8)et+=String.fromCharCode(ee[en>>5]>>>24-en%32&255);return et}function binb_sha1(ee,et){ee[et>>5]|=128<<24-et%32,ee[(et+64>>9<<4)+15]=et;for(var en=Array(80),ei=1732584193,eo=-271733879,ea=-1732584194,es=271733878,eu=-1009589776,ec=0;ec>16)+(et>>16)+(en>>16)<<16|65535&en}function bit_rol(ee,et){return ee<>>32-et}et.HMACSHA1=function(ee,et){return b64_hmac_sha1(ee,et)}},70113:function(ee){var et="undefined"!=typeof ArrayBuffer,en="undefined"!=typeof Symbol;function forEach(ee,ei){var eo,ea,es,eu,ec;if(!ee)throw Error("obliterator/forEach: invalid iterable.");if("function"!=typeof ei)throw Error("obliterator/forEach: expecting a callback.");if(Array.isArray(ee)||et&&ArrayBuffer.isView(ee)||"string"==typeof ee||"[object Arguments]"===ee.toString()){for(es=0,eu=ee.length;es=et?{done:!0}:{done:!1,value:ee[en++]}})},Iterator.empty=function(){var ee=new Iterator(null);return ee.done=!0,ee},Iterator.is=function(ee){return ee instanceof Iterator||"object"==typeof ee&&null!==ee&&"function"==typeof ee.next},ee.exports=Iterator},23567:function(ee,et,en){let ei;var eo=en(48764).Buffer;let{strict:ea}=en(27596),{createHash:es}=en(42474),{format:eu}=en(79720),ec=en(22477);if(eo.isEncoding("base64url"))ei=ee=>ee.toString("base64url");else{let fromBase64=ee=>ee.replace(/=/g,"").replace(/\+/g,"-").replace(/\//g,"_");ei=ee=>fromBase64(ee.toString("base64"))}function getHash(ee,et){switch(ee){case"HS256":case"RS256":case"PS256":case"ES256":case"ES256K":return es("sha256");case"HS384":case"RS384":case"PS384":case"ES384":return es("sha384");case"HS512":case"RS512":case"PS512":case"ES512":return es("sha512");case"EdDSA":switch(et){case"Ed25519":return es("sha512");case"Ed448":if(!ec)throw TypeError("Ed448 *_hash calculation is not supported in your Node.js runtime version");return es("shake256",{outputLength:114});default:throw TypeError("unrecognized or invalid EdDSA curve provided")}default:throw TypeError("unrecognized or invalid JWS algorithm provided")}}function generate(ee,et,en){let eo=getHash(et,en).update(ee).digest();return ei(eo.slice(0,eo.length/2))}function validate(ee,et,en,ei,eo){let es,ec;if("string"!=typeof ee.claim||!ee.claim)throw TypeError("names.claim must be a non-empty string");if("string"!=typeof ee.source||!ee.source)throw TypeError("names.source must be a non-empty string");ea("string"==typeof et&&et,`${ee.claim} must be a non-empty string`),ea("string"==typeof en&&en,`${ee.source} must be a non-empty string`);try{es=generate(en,ei,eo)}catch(et){ec=eu("%s could not be validated (%s)",ee.claim,et.message)}ec=ec||eu("%s mismatch, expected %s, got: %s",ee.claim,es,et),ea.equal(es,et,ec)}ee.exports={validate,generate}},22477:function(ee,et,en){var ei=en(34155);let eo=en(42474),[ea,es]=ei.version.substring(1).split(".").map(ee=>parseInt(ee,10)),eu=ea>12||12===ea&&es>=8,ec=eu&&eo.getHashes().includes("shake256");ee.exports=ec},62251:function(ee,et,en){let ei;var eo=en(34155),ea=en(48764).Buffer;let{inspect:es}=en(79720),eu=en(22321),ec=en(42474),{strict:ed}=en(27596),ef=en(97334),ep=en(11987),{URL:eh,URLSearchParams:ey}=en(11987),em=en(45595),eg=en(23567),eb=en(92793),ev=en(77749),e_=en(42806),ew=en(51892),eS=en(88026),{assertSigningAlgValuesSupport:eE,assertIssuerConfiguration:eA}=en(8867),e$=en(76038),ex=en(51303),eC=en(47787),ek=en(81911),{OPError:eO,RPError:eT}=en(67486),eP=en(96891),{random:eR}=en(68767),eI=en(3862),{CLOCK_TOLERANCE:eN}=en(78026),{keystores:eM}=en(64385),ej=en(42485),eD=en(71050),{authenticatedPost:eB,resolveResponseType:eU,resolveRedirectUri:eL}=en(4944),{queryKeyStore:eF}=en(17042),eW=en(27649),[eH,eq]=eo.version.slice(1).split(".").map(ee=>parseInt(ee,10)),eV=eH>=17||16===eH&&eq>=9,eK=Symbol(),ez=Symbol(),eJ=Symbol();function pickCb(ee){return e$(ee,"access_token","code","error_description","error_uri","error","expires_in","id_token","iss","response","session_state","state","token_type")}function authorizationHeaderValue(ee,et="Bearer"){return`${et} ${ee}`}function getSearchParams(ee){let et=ep.parse(ee);return et.search?ef.parse(et.search.substring(1)):{}}function verifyPresence(ee,et,en){if(void 0===ee[en])throw new eT({message:`missing required JWT property ${en}`,jwt:et})}function authorizationParams(ee){let et={client_id:this.client_id,scope:"openid",response_type:eU.call(this),redirect_uri:eL.call(this),...ee};return Object.entries(et).forEach(([ee,en])=>{null==en?delete et[ee]:"claims"===ee&&"object"==typeof en?et[ee]=JSON.stringify(en):"resource"===ee&&Array.isArray(en)?et[ee]=en:"string"!=typeof en&&(et[ee]=String(en))}),et}function getKeystore(ee){if(!ex(ee)||!Array.isArray(ee.keys)||ee.keys.some(ee=>!ex(ee)||!("kty"in ee)))throw TypeError("jwks must be a JSON Web Key Set formatted object");return ej.fromJWKS(ee,{onlyPrivate:!0})}function checkBasicSupport(ee,et){try{let en=ee.issuer.token_endpoint_auth_methods_supported;!en.includes(et.token_endpoint_auth_method)&&en.includes("client_secret_post")&&(et.token_endpoint_auth_method="client_secret_post")}catch(ee){}}function handleCommonMistakes(ee,et,en){if(et.token_endpoint_auth_method||checkBasicSupport(ee,en),et.redirect_uri){if(et.redirect_uris)throw TypeError("provide a redirect_uri or redirect_uris, not both");en.redirect_uris=[et.redirect_uri],delete en.redirect_uri}if(et.response_type){if(et.response_types)throw TypeError("provide a response_type or response_types, not both");en.response_types=[et.response_type],delete en.response_type}}function getDefaultsForEndpoint(ee,et,en){if(!et[`${ee}_endpoint`])return;let ei=en.token_endpoint_auth_method,eo=en.token_endpoint_auth_signing_alg,ea=`${ee}_endpoint_auth_method`,es=`${ee}_endpoint_auth_signing_alg`;void 0===en[ea]&&void 0===en[es]&&(void 0!==ei&&(en[ea]=ei),void 0!==eo&&(en[es]=eo))}let BaseClient=class BaseClient{#e;#t;#r;#n;constructor(ee,et,en={},ei,eo){if(this.#e=new Map,this.#t=ee,this.#r=et,"string"!=typeof en.client_id||!en.client_id)throw TypeError("client_id is required");let ea={grant_types:["authorization_code"],id_token_signed_response_alg:"RS256",authorization_signed_response_alg:"RS256",response_types:["code"],token_endpoint_auth_method:"client_secret_basic",...this.fapi1()?{grant_types:["authorization_code","implicit"],id_token_signed_response_alg:"PS256",authorization_signed_response_alg:"PS256",response_types:["code id_token"],tls_client_certificate_bound_access_tokens:!0,token_endpoint_auth_method:void 0}:void 0,...this.fapi2()?{id_token_signed_response_alg:"PS256",authorization_signed_response_alg:"PS256",token_endpoint_auth_method:void 0}:void 0,...en};if(this.fapi())switch(ea.token_endpoint_auth_method){case"self_signed_tls_client_auth":case"tls_client_auth":break;case"private_key_jwt":if(!ei)throw TypeError("jwks is required");break;case void 0:throw TypeError("token_endpoint_auth_method is required");default:throw TypeError("invalid or unsupported token_endpoint_auth_method")}if(this.fapi2()&&(ea.tls_client_certificate_bound_access_tokens&&ea.dpop_bound_access_tokens||!ea.tls_client_certificate_bound_access_tokens&&!ea.dpop_bound_access_tokens))throw TypeError("either tls_client_certificate_bound_access_tokens or dpop_bound_access_tokens must be set to true");if(handleCommonMistakes(this,en,ea),eE("token",this.issuer,ea),["introspection","revocation"].forEach(ee=>{getDefaultsForEndpoint(ee,this.issuer,ea),eE(ee,this.issuer,ea)}),Object.entries(ea).forEach(([ee,et])=>{this.#e.set(ee,et),this[ee]||Object.defineProperty(this,ee,{get(){return this.#e.get(ee)},enumerable:!0})}),void 0!==ei){let ee=getKeystore.call(this,ei);eM.set(this,ee)}null!=eo&&eo.additionalAuthorizedParties&&(this.#n=eD(eo.additionalAuthorizedParties)),this[eN]=0}authorizationUrl(ee={}){if(!ex(ee))throw TypeError("params must be a plain object");eA(this.issuer,"authorization_endpoint");let et=new eh(this.issuer.authorization_endpoint);for(let[en,ei]of Object.entries(authorizationParams.call(this,ee)))if(Array.isArray(ei))for(let ee of(et.searchParams.delete(en),ei))et.searchParams.append(en,ee);else et.searchParams.set(en,ei);return et.href.replace(/\+/g,"%20")}authorizationPost(ee={}){if(!ex(ee))throw TypeError("params must be a plain object");let et=authorizationParams.call(this,ee),en=Object.keys(et).map(ee=>``).join("\n");return` Requesting Authorization
${en}
`}endSessionUrl(ee={}){let et;eA(this.issuer,"end_session_endpoint");let{0:en,length:ei}=this.post_logout_redirect_uris||[],{post_logout_redirect_uri:eo=1===ei?en:void 0}=ee;if({id_token_hint:et,...ee}=ee,et instanceof ek){if(!et.id_token)throw TypeError("id_token not present in TokenSet");et=et.id_token}let ea=ep.parse(this.issuer.end_session_endpoint),es=ew(getSearchParams(this.issuer.end_session_endpoint),ee,{post_logout_redirect_uri:eo,client_id:this.client_id},{id_token_hint:et});return Object.entries(es).forEach(([ee,et])=>{null==et&&delete es[ee]}),ea.search=null,ea.query=es,ep.format(ea)}callbackParams(ee){let et=ee instanceof eu.IncomingMessage||ee&&ee.method&&ee.url,en="string"==typeof ee;if(!en&&!et)throw TypeError("#callbackParams only accepts string urls, http.IncomingMessage or a lookalike");if(!et)return pickCb(getSearchParams(ee));switch(ee.method){case"GET":return pickCb(getSearchParams(ee.url));case"POST":if(void 0===ee.body)throw TypeError("incoming message body missing, include a body parser prior to this method call");switch(typeof ee.body){case"object":case"string":if(ea.isBuffer(ee.body))return pickCb(ef.parse(ee.body.toString("utf-8")));if("string"==typeof ee.body)return pickCb(ef.parse(ee.body));return pickCb(ee.body);default:throw TypeError("invalid IncomingMessage body object")}default:throw TypeError("invalid IncomingMessage method")}}async callback(ee,et,en={},{exchangeBody:ei,clientAssertionPayload:eo,DPoP:ea}={}){let es=pickCb(et);if(!en.jarm||"response"in et){if("response"in et){let ee=await this.decryptJARM(es.response);es=await this.validateJARM(ee)}}else throw new eT({message:"expected a JARM response",checks:en,params:es});if(this.default_max_age&&!en.max_age&&(en.max_age=this.default_max_age),es.state&&!en.state)throw TypeError("checks.state argument is missing");if(!es.state&&en.state)throw new eT({message:"state missing from the response",checks:en,params:es});if(en.state!==es.state)throw new eT({printf:["state mismatch, expected %s, got: %s",en.state,es.state],checks:en,params:es});if("iss"in es){if(eA(this.issuer,"issuer"),es.iss!==this.issuer.issuer)throw new eT({printf:["iss mismatch, expected %s, got: %s",this.issuer.issuer,es.iss],params:es})}else if(this.issuer.authorization_response_iss_parameter_supported&&!("id_token"in es)&&!("response"in et))throw new eT({message:"iss missing from the response",params:es});if(es.error)throw new eO(es);let eu={code:["code"],id_token:["id_token"],token:["access_token","token_type"]};if(en.response_type){for(let ee of en.response_type.split(" "))if("none"===ee){if(es.code||es.id_token||es.access_token)throw new eT({message:'unexpected params encountered for "none" response',checks:en,params:es})}else for(let et of eu[ee])if(!es[et])throw new eT({message:`${et} missing from response`,checks:en,params:es})}if(es.id_token){let ee=new ek(es);if(await this.decryptIdToken(ee),await this.validateIdToken(ee,en.nonce,"authorization",en.max_age,en.state),!es.code)return ee}if(es.code){let et=await this.grant({...ei,grant_type:"authorization_code",code:es.code,redirect_uri:ee,code_verifier:en.code_verifier},{clientAssertionPayload:eo,DPoP:ea});return await this.decryptIdToken(et),await this.validateIdToken(et,en.nonce,"token",en.max_age),es.session_state&&(et.session_state=es.session_state),et}return new ek(es)}async oauthCallback(ee,et,en={},{exchangeBody:ei,clientAssertionPayload:eo,DPoP:ea}={}){let es=pickCb(et);if(!en.jarm||"response"in et){if("response"in et){let ee=await this.decryptJARM(es.response);es=await this.validateJARM(ee)}}else throw new eT({message:"expected a JARM response",checks:en,params:es});if(es.state&&!en.state)throw TypeError("checks.state argument is missing");if(!es.state&&en.state)throw new eT({message:"state missing from the response",checks:en,params:es});if(en.state!==es.state)throw new eT({printf:["state mismatch, expected %s, got: %s",en.state,es.state],checks:en,params:es});if("iss"in es){if(eA(this.issuer,"issuer"),es.iss!==this.issuer.issuer)throw new eT({printf:["iss mismatch, expected %s, got: %s",this.issuer.issuer,es.iss],params:es})}else if(this.issuer.authorization_response_iss_parameter_supported&&!("id_token"in es)&&!("response"in et))throw new eT({message:"iss missing from the response",params:es});if(es.error)throw new eO(es);if("string"==typeof es.id_token&&es.id_token.length)throw new eT({message:"id_token detected in the response, you must use client.callback() instead of client.oauthCallback()",params:es});delete es.id_token;let eu={code:["code"],token:["access_token","token_type"]};if(en.response_type)for(let ee of en.response_type.split(" ")){if("none"===ee&&(es.code||es.id_token||es.access_token))throw new eT({message:'unexpected params encountered for "none" response',checks:en,params:es});if(eu[ee]){for(let et of eu[ee])if(!es[et])throw new eT({message:`${et} missing from response`,checks:en,params:es})}}if(es.code){let et=await this.grant({...ei,grant_type:"authorization_code",code:es.code,redirect_uri:ee,code_verifier:en.code_verifier},{clientAssertionPayload:eo,DPoP:ea});if("string"==typeof et.id_token&&et.id_token.length)throw new eT({message:"id_token detected in the response, you must use client.callback() instead of client.oauthCallback()",params:es});return delete et.id_token,et}return new ek(es)}async decryptIdToken(ee){if(!this.id_token_encrypted_response_alg)return ee;let et=ee;if(et instanceof ek){if(!et.id_token)throw TypeError("id_token not present in TokenSet");et=et.id_token}let en=this.id_token_encrypted_response_alg,ei=this.id_token_encrypted_response_enc,eo=await this.decryptJWE(et,en,ei);return ee instanceof ek?(ee.id_token=eo,ee):eo}async validateJWTUserinfo(ee){let et=this.userinfo_signed_response_alg;return this.validateJWT(ee,et,[])}async decryptJARM(ee){if(!this.authorization_encrypted_response_alg)return ee;let et=this.authorization_encrypted_response_alg,en=this.authorization_encrypted_response_enc;return this.decryptJWE(ee,et,en)}async decryptJWTUserinfo(ee){if(!this.userinfo_encrypted_response_alg)return ee;let et=this.userinfo_encrypted_response_alg,en=this.userinfo_encrypted_response_enc;return this.decryptJWE(ee,et,en)}async decryptJWE(ee,et,en="A128CBC-HS256"){let ei;let eo=JSON.parse(e_.decode(ee.split(".")[0]));if(eo.alg!==et)throw new eT({printf:["unexpected JWE alg received, expected %s, got: %s",et,eo.alg],jwt:ee});if(eo.enc!==en)throw new eT({printf:["unexpected JWE enc received, expected %s, got: %s",en,eo.enc],jwt:ee});let getPlaintext=ee=>new TextDecoder().decode(ee.plaintext);if(et.match(/^(?:RSA|ECDH)/)){let et=await eM.get(this),en=em.decodeProtectedHeader(ee);for(let eo of et.all({...en,use:"enc"}))if(ei=await em.compactDecrypt(ee,await eo.keyObject(en.alg)).then(getPlaintext,()=>{}))break}else ei=await em.compactDecrypt(ee,this.secretForAlg("dir"===et?en:et)).then(getPlaintext,()=>{});if(!ei)throw new eT({message:"failed to decrypt JWE",jwt:ee});return ei}async validateIdToken(ee,et,en,ei,eo){let ea=ee,es=this.id_token_signed_response_alg,eu=ea instanceof ek;if(eu){if(!ea.id_token)throw TypeError("id_token not present in TokenSet");ea=ea.id_token}ea=String(ea);let ec=eP(),{protected:ed,payload:ef,key:ep}=await this.validateJWT(ea,es);if("number"==typeof ei||ei!==eJ&&this.require_auth_time){if(!ef.auth_time)throw new eT({message:"missing required JWT property auth_time",jwt:ea});if("number"!=typeof ef.auth_time)throw new eT({message:"JWT auth_time claim must be a JSON numeric value",jwt:ea})}if("number"==typeof ei&&ef.auth_time+eieu+this[eN])throw new eT({printf:["JWT not active yet, now %i, nbf %i",eu+this[eN],eo.nbf],now:eu,tolerance:this[eN],nbf:eo.nbf,jwt:ee})}if(void 0!==eo.exp){if("number"!=typeof eo.exp)throw new eT({message:"JWT exp claim must be a JSON numeric value",jwt:ee});if(eu-this[eN]>=eo.exp)throw new eT({printf:["JWT expired, now %i, exp %i",eu-this[eN],eo.exp],now:eu,tolerance:this[eN],exp:eo.exp,jwt:ee})}if(void 0!==eo.aud){if(Array.isArray(eo.aud)){if(eo.aud.length>1&&!eo.azp)throw new eT({message:"missing required JWT property azp",jwt:ee});if(!eo.aud.includes(this.client_id))throw new eT({printf:["aud is missing the client_id, expected %s to be included in %j",this.client_id,eo.aud],jwt:ee})}else if(eo.aud!==this.client_id)throw new eT({printf:["aud mismatch, expected %s, got: %s",this.client_id,eo.aud],jwt:ee})}if(void 0!==eo.azp){let et=this.#n;if(!(et="string"==typeof et?[this.client_id,et]:Array.isArray(et)?[this.client_id,...et]:[this.client_id]).includes(eo.azp))throw new eT({printf:["azp mismatch, got: %s",eo.azp],jwt:ee})}if(es){try{ed(ex(eo.sub_jwk));let ee=await em.importJWK(eo.sub_jwk,ei.alg);ed.equal(ee.type,"public"),ea=[{keyObject:()=>ee}]}catch(et){throw new eT({message:"failed to use sub_jwk claim as an asymmetric JSON Web Key",jwt:ee})}if(await em.calculateJwkThumbprint(eo.sub_jwk)!==eo.sub)throw new eT({message:"failed to match the subject with sub_jwk",jwt:ee})}else ei.alg.startsWith("HS")?ea=[this.secretForAlg(ei.alg)]:"none"!==ei.alg&&(ea=await eF.call(this.issuer,{...ei,use:"sig"}));if(!ea&&"none"===ei.alg)return{protected:ei,payload:eo};for(let et of ea){let en=await em.compactVerify(ee,et instanceof Uint8Array?et:await et.keyObject(ei.alg)).catch(()=>{});if(en)return{payload:eo,protected:en.protectedHeader,key:et}}throw new eT({message:"failed to validate JWT signature",jwt:ee})}async refresh(ee,{exchangeBody:et,clientAssertionPayload:en,DPoP:ei}={}){let eo=ee;if(eo instanceof ek){if(!eo.refresh_token)throw TypeError("refresh_token not present in TokenSet");eo=eo.refresh_token}let ea=await this.grant({...et,grant_type:"refresh_token",refresh_token:String(eo)},{clientAssertionPayload:en,DPoP:ei});if(ea.id_token&&(await this.decryptIdToken(ea),await this.validateIdToken(ea,ez,"token",eJ),ee instanceof ek&&ee.id_token)){let et=ee.claims().sub,en=ea.claims().sub;if(en!==et)throw new eT({printf:["sub mismatch, expected %s, got: %s",et,en],jwt:ea.id_token})}return ea}async requestResource(ee,et,{method:en,headers:ei,body:eo,DPoP:ea,tokenType:es=ea?"DPoP":et instanceof ek?et.token_type:"Bearer"}={},eu){if(et instanceof ek){if(!et.access_token)throw TypeError("access_token not present in TokenSet");et=et.access_token}if(et){if("string"!=typeof et)throw TypeError("invalid access token provided")}else throw TypeError("no access token provided");let ec={headers:{Authorization:authorizationHeaderValue(et,es),...ei},body:eo},ed=!!this.tls_client_certificate_bound_access_tokens,ef=await eI.call(this,{...ec,responseType:"buffer",method:en,url:ee},{accessToken:et,mTLS:ed,DPoP:ea}),ep=ef.headers["www-authenticate"];return eu!==eK&&ep&&ep.toLowerCase().startsWith("dpop ")&&"use_dpop_nonce"===eS(ep).error?this.requestResource(ee,et,{method:en,headers:ei,body:eo,DPoP:ea,tokenType:es}):ef}async userinfo(ee,{method:et="GET",via:en="header",tokenType:ei,params:eo,DPoP:ea}={}){let es;eA(this.issuer,"userinfo_endpoint");let eu={tokenType:ei,method:String(et).toUpperCase(),DPoP:ea};if("GET"!==eu.method&&"POST"!==eu.method)throw TypeError("#userinfo() method can only be POST or a GET");if("body"===en&&"POST"!==eu.method)throw TypeError("can only send body on POST");let ec=!!(this.userinfo_signed_response_alg||this.userinfo_encrypted_response_alg);ec?eu.headers={Accept:"application/jwt"}:eu.headers={Accept:"application/json"};let ef=!!this.tls_client_certificate_bound_access_tokens;ef&&this.issuer.mtls_endpoint_aliases&&(es=this.issuer.mtls_endpoint_aliases.userinfo_endpoint),es=new eh(es||this.issuer.userinfo_endpoint),"body"===en&&(eu.headers.Authorization=void 0,eu.headers["Content-Type"]="application/x-www-form-urlencoded",eu.body=new ey,eu.body.append("access_token",ee instanceof ek?ee.access_token:ee)),eo&&("GET"===eu.method?Object.entries(eo).forEach(([ee,et])=>{es.searchParams.append(ee,et)}):eu.body?Object.entries(eo).forEach(([ee,et])=>{eu.body.append(ee,et)}):(eu.body=new ey,eu.headers["Content-Type"]="application/x-www-form-urlencoded",Object.entries(eo).forEach(([ee,et])=>{eu.body.append(ee,et)}))),eu.body&&(eu.body=eu.body.toString());let ep=await this.requestResource(es,ee,eu),em=eC(ep,{bearer:!0});if(ec){if(!/^application\/jwt/.test(ep.headers["content-type"]))throw new eT({message:"expected application/jwt response from the userinfo_endpoint",response:ep});let ee=ep.body.toString(),et=await this.decryptJWTUserinfo(ee);if(this.userinfo_signed_response_alg)({payload:em}=await this.validateJWTUserinfo(et));else try{em=JSON.parse(et),ed(ex(em))}catch(ee){throw new eT({message:"failed to parse userinfo JWE payload as JSON",jwt:et})}}else try{em=JSON.parse(ep.body)}catch(ee){throw Object.defineProperty(ee,"response",{value:ep}),ee}if(ee instanceof ek&&ee.id_token){let et=ee.claims().sub;if(em.sub!==et)throw new eT({printf:["userinfo sub mismatch, expected %s, got: %s",et,em.sub],body:em,jwt:ee.id_token})}return em}encryptionSecret(ee){let et=ee<=256?"sha256":ee<=384?"sha384":ee<=512&&"sha512";if(!et)throw Error("unsupported symmetric encryption key derivation");return ec.createHash(et).update(this.client_secret).digest().slice(0,ee/8)}secretForAlg(ee){if(!this.client_secret)throw TypeError("client_secret is required");return/^A(\d{3})(?:GCM)?KW$/.test(ee)?this.encryptionSecret(parseInt(RegExp.$1,10)):/^A(\d{3})(?:GCM|CBC-HS(\d{3}))$/.test(ee)?this.encryptionSecret(parseInt(RegExp.$2||RegExp.$1,10)):new TextEncoder().encode(this.client_secret)}async grant(ee,{clientAssertionPayload:et,DPoP:en}={},ei){let eo;eA(this.issuer,"token_endpoint");let ea=await eB.call(this,"token",{form:ee,responseType:"json"},{clientAssertionPayload:et,DPoP:en});try{eo=eC(ea)}catch(eo){if(ei!==eK&&eo instanceof eO&&"use_dpop_nonce"===eo.error)return this.grant(ee,{clientAssertionPayload:et,DPoP:en},eK);throw eo}return new ek(eo)}async deviceAuthorization(ee={},{exchangeBody:et,clientAssertionPayload:en,DPoP:ei}={}){eA(this.issuer,"device_authorization_endpoint"),eA(this.issuer,"token_endpoint");let eo=authorizationParams.call(this,{client_id:this.client_id,redirect_uri:null,response_type:null,...ee}),ea=await eB.call(this,"device_authorization",{responseType:"json",form:eo},{clientAssertionPayload:en,endpointAuthMethod:"token"}),es=eC(ea);return new eW({client:this,exchangeBody:et,clientAssertionPayload:en,response:es,maxAge:ee.max_age,DPoP:ei})}async revoke(ee,et,{revokeBody:en,clientAssertionPayload:ei}={}){if(eA(this.issuer,"revocation_endpoint"),void 0!==et&&"string"!=typeof et)throw TypeError("hint must be a string");let eo={...en,token:ee};et&&(eo.token_type_hint=et);let ea=await eB.call(this,"revocation",{form:eo},{clientAssertionPayload:ei});eC(ea,{body:!1})}async introspect(ee,et,{introspectBody:en,clientAssertionPayload:ei}={}){if(eA(this.issuer,"introspection_endpoint"),void 0!==et&&"string"!=typeof et)throw TypeError("hint must be a string");let eo={...en,token:ee};et&&(eo.token_type_hint=et);let ea=await eB.call(this,"introspection",{form:eo,responseType:"json"},{clientAssertionPayload:ei}),es=eC(ea);return es}static async register(ee,et={}){let{initialAccessToken:en,jwks:ei,...eo}=et;if(eA(this.issuer,"registration_endpoint"),void 0!==ei&&!(ee.jwks||ee.jwks_uri)){let et=await getKeystore.call(this,ei);ee.jwks=et.toJWKS()}let ea=await eI.call(this,{headers:{Accept:"application/json",...en?{Authorization:authorizationHeaderValue(en)}:void 0},responseType:"json",json:ee,url:this.issuer.registration_endpoint,method:"POST"}),es=eC(ea,{statusCode:201,bearer:!0});return new this(es,ei,eo)}get metadata(){return eD(Object.fromEntries(this.#e.entries()))}static async fromUri(ee,et,en,ei){let eo=await eI.call(this,{method:"GET",url:ee,responseType:"json",headers:{Authorization:authorizationHeaderValue(et),Accept:"application/json"}}),ea=eC(eo,{bearer:!0});return new this(ea,en,ei)}async requestObject(ee={},{sign:et=this.request_object_signing_alg||"none",encrypt:{alg:en=this.request_object_encryption_alg,enc:ei=this.request_object_encryption_enc||"A128CBC-HS256"}={}}={}){let eo,ea;if(!ex(ee))throw TypeError("requestObject must be a plain object");let es=eP(),eu={alg:et,typ:"oauth-authz-req+jwt"},ec=JSON.stringify(ew({},ee,{iss:this.client_id,aud:this.issuer.issuer,client_id:this.client_id,jti:eR(),iat:es,exp:es+300,...this.fapi()?{nbf:es}:void 0}));if("none"===et)eo=[e_.encode(JSON.stringify(eu)),e_.encode(ec),""].join(".");else{let ee=et.startsWith("HS");if(ee)ea=this.secretForAlg(et);else{let ee=await eM.get(this);if(!ee)throw TypeError(`no keystore present for client, cannot sign using alg ${et}`);if(!(ea=ee.get({alg:et,use:"sig"})))throw TypeError(`no key to sign with found for alg ${et}`)}eo=await new em.CompactSign(new TextEncoder().encode(ec)).setProtectedHeader({...eu,kid:ee?void 0:ea.jwk.kid}).sign(ee?ea:await ea.keyObject(et))}if(!en)return eo;let ed={alg:en,enc:ei,cty:"oauth-authz-req+jwt"};return ed.alg.match(/^(RSA|ECDH)/)?[ea]=await eF.call(this.issuer,{alg:ed.alg,use:"enc"},{allowMulti:!0}):ea=this.secretForAlg("dir"===ed.alg?ed.enc:ed.alg),new em.CompactEncrypt(new TextEncoder().encode(eo)).setProtectedHeader({...ed,kid:ea instanceof Uint8Array?void 0:ea.jwk.kid}).encrypt(ea instanceof Uint8Array?ea:await ea.keyObject(ed.alg))}async pushedAuthorizationRequest(ee={},{clientAssertionPayload:et}={}){eA(this.issuer,"pushed_authorization_request_endpoint");let en={..."request"in ee?ee:authorizationParams.call(this,ee),client_id:this.client_id},ei=await eB.call(this,"pushed_authorization_request",{responseType:"json",form:en},{clientAssertionPayload:et,endpointAuthMethod:"token"}),eo=eC(ei,{statusCode:201});if(!("expires_in"in eo))throw new eT({message:"expected expires_in in Pushed Authorization Successful Response",response:ei});if("number"!=typeof eo.expires_in)throw new eT({message:"invalid expires_in value in Pushed Authorization Successful Response",response:ei});if(!("request_uri"in eo))throw new eT({message:"expected request_uri in Pushed Authorization Successful Response",response:ei});if("string"!=typeof eo.request_uri)throw new eT({message:"invalid request_uri value in Pushed Authorization Successful Response",response:ei});return eo}get issuer(){return this.#t}[es.custom](){return`${this.constructor.name} ${es(this.metadata,{depth:1/0,colors:eo.stdout.isTTY,compact:!1,sorted:!0})}`}fapi(){return this.fapi1()||this.fapi2()}fapi1(){return"FAPI1Client"===this.constructor.name}fapi2(){return"FAPI2Client"===this.constructor.name}async validateJARM(ee){let et=this.authorization_signed_response_alg,{payload:en}=await this.validateJWT(ee,et,["iss","exp","aud"]);return pickCb(en)}async dpopProof(ee,et,en){let eo;if(!ex(ee))throw TypeError("payload must be a plain object");if(eb(et))eo=et;else if("CryptoKey"===et[Symbol.toStringTag])eo=et;else if("node:crypto"===em.cryptoRuntime)eo=ec.createPrivateKey(et);else throw TypeError("unrecognized crypto runtime");if("private"!==eo.type)throw TypeError('"DPoP" option must be a private key');let ea=ei.call(this,eo,et);if(!ea)throw TypeError("could not determine DPoP JWS Algorithm");return new em.SignJWT({ath:en?e_.encode(ec.createHash("sha256").update(en).digest()):void 0,...ee}).setProtectedHeader({alg:ea,typ:"dpop+jwt",jwk:await getJwk(eo,et)}).setIssuedAt().setJti(eR()).sign(eo)}};function determineDPoPAlgorithmFromCryptoKey(ee){switch(ee.algorithm.name){case"Ed25519":case"Ed448":return"EdDSA";case"ECDSA":switch(ee.algorithm.namedCurve){case"P-256":return"ES256";case"P-384":return"ES384";case"P-521":return"ES512"}break;case"RSASSA-PKCS1-v1_5":return`RS${ee.algorithm.hash.name.slice(4)}`;case"RSA-PSS":return`PS${ee.algorithm.hash.name.slice(4)}`;default:throw TypeError("unsupported DPoP private key")}}if("node:crypto"===em.cryptoRuntime){ei=function(ee,et){if("CryptoKey"===et[Symbol.toStringTag])return determineDPoPAlgorithmFromCryptoKey(ee);switch(ee.asymmetricKeyType){case"ed25519":case"ed448":return"EdDSA";case"ec":return determineEcAlgorithm(ee,et);case"rsa":case eV&&"rsa-pss":return determineRsaAlgorithm(ee,et,this.issuer.dpop_signing_alg_values_supported);default:throw TypeError("unsupported DPoP private key")}};let ee=/^(?:RS|PS)(?:256|384|512)$/;function determineRsaAlgorithm(et,en,ei){if("object"==typeof en&&"jwk"===en.format&&en.key&&en.key.alg)return en.key.alg;if(Array.isArray(ei)){let en=ei.filter(RegExp.prototype.test.bind(ee));return"rsa-pss"===et.asymmetricKeyType&&(en=en.filter(ee=>ee.startsWith("PS"))),["PS256","PS384","PS512","RS256","RS384","RS384"].find(ee=>en.includes(ee))}return"PS256"}let et=ea.from([42,134,72,206,61,3,1,7]),en=ea.from([43,129,4,0,34]),eo=ea.from([43,129,4,0,35]),es=ea.from([43,129,4,0,10]);function determineEcAlgorithm(ee,ei){switch("object"==typeof ei&&"object"==typeof ei.key&&ei.key.crv){case"P-256":return"ES256";case"secp256k1":return"ES256K";case"P-384":return"ES384";case"P-512":return"ES512"}let ea=ee.export({format:"der",type:"pkcs8"}),eu=ea[1]<128?17:18,ec=ea[eu],ed=ea.slice(eu+1,eu+1+ec);if(ed.equals(et))return"ES256";if(ed.equals(en))return"ES384";if(ed.equals(eo))return"ES512";if(ed.equals(es))return"ES256K";throw TypeError("unsupported DPoP private key curve")}}else ei=determineDPoPAlgorithmFromCryptoKey;let eG=new WeakMap;async function getJwk(ee,et){if("node:crypto"===em.cryptoRuntime&&"object"==typeof et&&"object"==typeof et.key&&"jwk"===et.format)return e$(et.key,"kty","crv","x","y","e","n");if(eG.has(et))return eG.get(et);let en=e$(await em.exportJWK(ee),"kty","crv","x","y","e","n");return(eb(et)||"WebCryptoAPI"===em.cryptoRuntime)&&eG.set(et,en),en}ee.exports=(ee,et=!1)=>class extends BaseClient{constructor(...en){super(ee,et,...en)}static get issuer(){return ee}},ee.exports.BaseClient=BaseClient},27649:function(ee,et,en){var ei=en(34155);let{inspect:eo}=en(79720),{RPError:ea,OPError:es}=en(67486),eu=en(96891);let DeviceFlowHandle=class DeviceFlowHandle{#i;#o;#a;#s;#u;#l;#c;#d;#f;constructor({client:ee,exchangeBody:et,clientAssertionPayload:en,response:ei,maxAge:eo,DPoP:es}){if(["verification_uri","user_code","device_code"].forEach(ee=>{if("string"!=typeof ei[ee]||!ei[ee])throw new ea(`expected ${ee} string to be returned by Device Authorization Response, got %j`,ei[ee])}),!Number.isSafeInteger(ei.expires_in))throw new ea("expected expires_in number to be returned by Device Authorization Response, got %j",ei.expires_in);this.#l=eu()+ei.expires_in,this.#o=ee,this.#s=es,this.#d=eo,this.#u=et,this.#a=en,this.#f=ei,this.#c=1e3*ei.interval||5e3}abort(){this.#i=!0}async poll({signal:ee}={}){let et;if(ee&&ee.aborted||this.#i)throw new ea("polling aborted");if(this.expired())throw new ea("the device code %j has expired and the device authorization session has concluded",this.device_code);await new Promise(ee=>setTimeout(ee,this.#c));try{et=await this.#o.grant({...this.#u,grant_type:"urn:ietf:params:oauth:grant-type:device_code",device_code:this.device_code},{clientAssertionPayload:this.#a,DPoP:this.#s})}catch(et){switch(et instanceof es&&et.error){case"slow_down":this.#c+=5e3;case"authorization_pending":return this.poll({signal:ee});default:throw et}}return"id_token"in et&&(await this.#o.decryptIdToken(et),await this.#o.validateIdToken(et,void 0,"token",this.#d)),et}get device_code(){return this.#f.device_code}get user_code(){return this.#f.user_code}get verification_uri(){return this.#f.verification_uri}get verification_uri_complete(){return this.#f.verification_uri_complete}get expires_in(){return Math.max.apply(null,[this.#l-eu(),0])}expired(){return 0===this.expires_in}[eo.custom](){return`${this.constructor.name} ${eo(this.#f,{depth:1/0,colors:ei.stdout.isTTY,compact:!1,sorted:!0})}`}};ee.exports=DeviceFlowHandle},67486:function(ee,et,en){let{format:ei}=en(79720);let OPError=class OPError extends Error{constructor({error_description:ee,error:et,error_uri:en,session_state:ei,state:eo,scope:ea},es){super(ee?`${et} (${ee})`:et),Object.assign(this,{error:et},ee&&{error_description:ee},en&&{error_uri:en},eo&&{state:eo},ea&&{scope:ea},ei&&{session_state:ei}),es&&Object.defineProperty(this,"response",{value:es}),this.name=this.constructor.name,Error.captureStackTrace(this,this.constructor)}};let RPError=class RPError extends Error{constructor(...ee){if("string"==typeof ee[0])super(ei(...ee));else{let{message:et,printf:en,response:eo,...ea}=ee[0];en?super(ei(...en)):super(et),Object.assign(this,ea),eo&&Object.defineProperty(this,"response",{value:eo})}this.name=this.constructor.name,Error.captureStackTrace(this,this.constructor)}};ee.exports={OPError,RPError}},8867:function(ee){function assertSigningAlgValuesSupport(ee,et,en){if(!et[`${ee}_endpoint`])return;let ei=`${ee}_endpoint_auth_method`,eo=`${ee}_endpoint_auth_signing_alg`,ea=`${ee}_endpoint_auth_signing_alg_values_supported`;if(en[ei]&&en[ei].endsWith("_jwt")&&!en[eo]&&!et[ea])throw TypeError(`${ea} must be configured on the issuer if ${eo} is not defined on a client`)}function assertIssuerConfiguration(ee,et){if(!ee[et])throw TypeError(`${et} must be configured on the issuer`)}ee.exports={assertSigningAlgValuesSupport,assertIssuerConfiguration}},42806:function(ee,et,en){let ei;var eo=en(48764).Buffer;if(eo.isEncoding("base64url"))ei=(ee,et="utf8")=>eo.from(ee,et).toString("base64url");else{let fromBase64=ee=>ee.replace(/=/g,"").replace(/\+/g,"-").replace(/\//g,"_");ei=(ee,et="utf8")=>fromBase64(eo.from(ee,et).toString("base64"))}let decode=ee=>eo.from(ee,"base64");ee.exports.decode=decode,ee.exports.encode=ei},4944:function(ee,et,en){var ei=en(48764).Buffer;let eo=en(45595),{RPError:ea}=en(67486),{assertIssuerConfiguration:es}=en(8867),{random:eu}=en(68767),ec=en(96891),ed=en(3862),{keystores:ef}=en(64385),ep=en(65047),formUrlEncode=ee=>encodeURIComponent(ee).replace(/%20/g,"+");async function clientAssertion(ee,et){let en=this[`${ee}_endpoint_auth_signing_alg`];if(en||es(this.issuer,`${ee}_endpoint_auth_signing_alg_values_supported`),"client_secret_jwt"===this[`${ee}_endpoint_auth_method`]){if(!en){let et=this.issuer[`${ee}_endpoint_auth_signing_alg_values_supported`];en=Array.isArray(et)&&et.find(ee=>/^HS(?:256|384|512)/.test(ee))}if(!en)throw new ea(`failed to determine a JWS Algorithm to use for ${this[`${ee}_endpoint_auth_method`]} Client Assertion`);return new eo.CompactSign(ei.from(JSON.stringify(et))).setProtectedHeader({alg:en}).sign(this.secretForAlg(en))}let eu=await ef.get(this);if(!eu)throw TypeError("no client jwks provided for signing a client assertion with");if(!en){let et=this.issuer[`${ee}_endpoint_auth_signing_alg_values_supported`];en=Array.isArray(et)&&et.find(ee=>eu.get({alg:ee,use:"sig"}))}if(!en)throw new ea(`failed to determine a JWS Algorithm to use for ${this[`${ee}_endpoint_auth_method`]} Client Assertion`);let ec=eu.get({alg:en,use:"sig"});if(!ec)throw new ea(`no key found in client jwks to sign a client assertion with using alg ${en}`);return new eo.CompactSign(ei.from(JSON.stringify(et))).setProtectedHeader({alg:en,kid:ec.jwk&&ec.jwk.kid}).sign(await ec.keyObject(en))}async function authFor(ee,{clientAssertionPayload:et}={}){let en=this[`${ee}_endpoint_auth_method`];switch(en){case"self_signed_tls_client_auth":case"tls_client_auth":case"none":return{form:{client_id:this.client_id}};case"client_secret_post":if("string"!=typeof this.client_secret)throw TypeError("client_secret_post client authentication method requires a client_secret");return{form:{client_id:this.client_id,client_secret:this.client_secret}};case"private_key_jwt":case"client_secret_jwt":{let en=ec(),ei=[...new Set([this.issuer.issuer,this.issuer.token_endpoint].filter(Boolean))],eo=await clientAssertion.call(this,ee,{iat:en,exp:en+60,jti:eu(),iss:this.client_id,sub:this.client_id,aud:ei,...et});return{form:{client_id:this.client_id,client_assertion:eo,client_assertion_type:"urn:ietf:params:oauth:client-assertion-type:jwt-bearer"}}}case"client_secret_basic":{if("string"!=typeof this.client_secret)throw TypeError("client_secret_basic client authentication method requires a client_secret");let ee=`${formUrlEncode(this.client_id)}:${formUrlEncode(this.client_secret)}`,et=ei.from(ee).toString("base64");return{headers:{Authorization:`Basic ${et}`}}}default:throw TypeError(`missing, or unsupported, ${ee}_endpoint_auth_method`)}}function resolveResponseType(){let{length:ee,0:et}=this.response_types;if(1===ee)return et}function resolveRedirectUri(){let{length:ee,0:et}=this.redirect_uris||[];if(1===ee)return et}async function authenticatedPost(ee,et,{clientAssertionPayload:en,endpointAuthMethod:ei=ee,DPoP:eo}={}){let ea;let es=await authFor.call(this,ei,{clientAssertionPayload:en}),eu=ep(et,es),ec=this[`${ei}_endpoint_auth_method`].includes("tls_client_auth")||"token"===ee&&this.tls_client_certificate_bound_access_tokens;if(ec&&this.issuer.mtls_endpoint_aliases&&(ea=this.issuer.mtls_endpoint_aliases[`${ee}_endpoint`]),ea=ea||this.issuer[`${ee}_endpoint`],"form"in eu)for(let[ee,et]of Object.entries(eu.form))void 0===et&&delete eu.form[ee];return ed.call(this,{...eu,method:"POST",url:ea,headers:{..."revocation"!==ee?{Accept:"application/json"}:void 0,...eu.headers}},{mTLS:ec,DPoP:eo})}ee.exports={resolveResponseType,resolveRedirectUri,authFor,authenticatedPost}},78026:function(ee){let et=Symbol(),en=Symbol();ee.exports={CLOCK_TOLERANCE:en,HTTP_OPTIONS:et}},77749:function(ee,et,en){let ei=en(42806);ee.exports=ee=>{if("string"!=typeof ee||!ee)throw TypeError("JWT must be a string");let{0:et,1:en,2:eo,length:ea}=ee.split(".");if(5===ea)throw TypeError("encrypted JWTs cannot be decoded");if(3!==ea)throw Error("JWTs must have three components");try{return{header:JSON.parse(ei.decode(et)),payload:JSON.parse(ei.decode(en)),signature:eo}}catch(ee){throw Error("JWT is malformed")}}},71050:function(ee){ee.exports=globalThis.structuredClone||(ee=>JSON.parse(JSON.stringify(ee)))},51892:function(ee,et,en){let ei=en(51303);function defaults(ee,et,...en){for(let eo of en)if(ei(eo))for(let[en,ea]of Object.entries(eo))"__proto__"!==en&&"constructor"!==en&&(void 0===et[en]&&void 0!==ea&&(et[en]=ea),ee&&ei(et[en])&&ei(ea)&&defaults(!0,et[en],ea));return et}ee.exports=defaults.bind(void 0,!1),ee.exports.deep=defaults.bind(void 0,!0)},68767:function(ee,et,en){let{createHash:ei,randomBytes:eo}=en(42474),ea=en(42806),random=(ee=32)=>ea.encode(eo(ee));ee.exports={random,state:random,nonce:random,codeVerifier:random,codeChallenge:ee=>ea.encode(ei("sha256").update(ee).digest())}},92793:function(ee,et,en){let ei=en(79720),eo=en(42474);ee.exports=ei.types.isKeyObject||(ee=>ee&&ee instanceof eo.KeyObject)},51303:function(ee){ee.exports=ee=>!!ee&&ee.constructor===Object},17042:function(ee,et,en){let ei=en(83302),eo=en(39593),{RPError:ea}=en(67486),{assertIssuerConfiguration:es}=en(8867),eu=en(42485),{keystores:ec}=en(64385),ed=en(47787),ef=en(3862),ep=new WeakMap,eh=new WeakMap,lrus=ee=>(eh.has(ee)||eh.set(ee,new eo({max:100})),eh.get(ee));async function getKeyStore(ee=!1){es(this,"jwks_uri");let et=ec.get(this),en=lrus(this);return ee||!et?(ep.has(this)||(en.reset(),ep.set(this,(async()=>{let ee=await ef.call(this,{method:"GET",responseType:"json",url:this.jwks_uri,headers:{Accept:"application/json, application/jwk-set+json"}}).finally(()=>{ep.delete(this)}),et=ed(ee),ei=eu.fromJWKS(et,{onlyPublic:!0});return en.set("throttle",!0,6e4),ec.set(this,ei),ei})())),ep.get(this)):et}async function queryKeyStore({kid:ee,kty:et,alg:en,use:eo},{allowMulti:es=!1}={}){let eu=lrus(this),ec={kid:ee,kty:et,alg:en,use:eo},ed=ei(ec,{algorithm:"sha256",ignoreUnknown:!0,unorderedArrays:!0,unorderedSets:!0,respectType:!1}),ef=eu.get(ed)||eu.get("throttle"),ep=await getKeyStore.call(this,!ef),eh=ep.all(ec);if(delete ec.use,0===eh.length)throw new ea({printf:["no valid key found in issuer's jwks_uri for key parameters %j",ec],jwks:ep});if(!es&&eh.length>1&&!ee)throw new ea({printf:["multiple matching keys found in issuer's jwks_uri for key parameters %j, kid must be provided in this case",ec],jwks:ep});return eu.set(ed,!0),eh}ee.exports.queryKeyStore=queryKeyStore,ee.exports.keystore=getKeyStore},42485:function(ee,et,en){let ei=en(45595),eo=en(71050),ea=en(51303),es=Symbol(),keyscore=(ee,{alg:et,use:en})=>{let ei=0;return et&&ee.alg&&ei++,en&&ee.use&&ei++,ei};function getKtyFromAlg(ee){switch("string"==typeof ee&&ee.slice(0,2)){case"RS":case"PS":return"RSA";case"ES":return"EC";case"Ed":return"OKP";default:return}}function getAlgorithms(ee,et,en,eo){if(et)return new Set([et]);switch(en){case"EC":{let et=[];if(("enc"===ee||void 0===ee)&&(et=et.concat(["ECDH-ES","ECDH-ES+A128KW","ECDH-ES+A192KW","ECDH-ES+A256KW"])),"sig"===ee||void 0===ee)switch(eo){case"P-256":case"P-384":et=et.concat([`ES${eo.slice(-3)}`]);break;case"P-521":et=et.concat(["ES512"]);break;case"secp256k1":"node:crypto"===ei.cryptoRuntime&&(et=et.concat(["ES256K"]))}return new Set(et)}case"OKP":return new Set(["ECDH-ES","ECDH-ES+A128KW","ECDH-ES+A192KW","ECDH-ES+A256KW"]);case"RSA":{let et=[];return("enc"===ee||void 0===ee)&&(et=et.concat(["RSA-OAEP","RSA-OAEP-256","RSA-OAEP-384","RSA-OAEP-512"]),"node:crypto"===ei.cryptoRuntime&&(et=et.concat(["RSA1_5"]))),("sig"===ee||void 0===ee)&&(et=et.concat(["PS256","PS384","PS512","RS256","RS384","RS512"])),new Set(et)}default:throw Error("unreachable")}}ee.exports=class{#p;constructor(ee,et){if(ee!==es)throw Error("invalid constructor call");this.#p=et}toJWKS(){return{keys:this.map(({jwk:{d:ee,p:et,q:en,dp:ei,dq:eo,qi:ea,...es}})=>es)}}all({alg:ee,kid:et,use:en}={}){if(!en||!ee)throw Error();let ei=getKtyFromAlg(ee),eo={alg:ee,use:en};return this.filter(eo=>{let ea=!0;return void 0!==ei&&eo.jwk.kty!==ei&&(ea=!1),ea&&void 0!==et&&eo.jwk.kid!==et&&(ea=!1),ea&&void 0!==en&&void 0!==eo.jwk.use&&eo.jwk.use!==en&&(ea=!1),ea&&eo.jwk.alg&&eo.jwk.alg!==ee?ea=!1:eo.algorithms.has(ee)||(ea=!1),ea}).sort((ee,et)=>keyscore(et,eo)-keyscore(ee,eo))}get(...ee){return this.all(...ee)[0]}static async fromJWKS(ee,{onlyPublic:et=!1,onlyPrivate:en=!1}={}){if(!ea(ee)||!Array.isArray(ee.keys)||ee.keys.some(ee=>!ea(ee)||!("kty"in ee)))throw TypeError("jwks must be a JSON Web Key Set formatted object");let eu=[];for(let ea of ee.keys){ea=eo(ea);let{kty:ee,kid:es,crv:ec}=ea,{alg:ed,use:ef}=ea;if("string"==typeof ee&&ee&&(void 0===ef||"sig"===ef||"enc"===ef)&&("string"==typeof ed||void 0===ed)&&("string"==typeof es||void 0===es)){if("EC"===ee&&"sig"===ef)switch(ec){case"P-256":ed="ES256";break;case"P-384":ed="ES384";break;case"P-521":ed="ES512"}if("secp256k1"===ec&&(ef="sig",ed="ES256K"),"OKP"===ee)switch(ec){case"Ed25519":case"Ed448":ef="sig",ed="EdDSA";break;case"X25519":case"X448":ef="enc"}if(ed&&!ef)switch(!0){case ed.startsWith("ECDH"):case ed.startsWith("RSA"):ef="enc"}if(en&&("oct"===ea.kty||!ea.d))throw Error("jwks must only contain private keys");et&&(ea.d||ea.k)||eu.push({jwk:{...ea,alg:ed,use:ef},async keyObject(ee){if(this[ee])return this[ee];let et=await ei.importJWK(this.jwk,ee);return this[ee]=et,et},get algorithms(){return Object.defineProperty(this,"algorithms",{value:getAlgorithms(this.jwk.use,this.jwk.alg,this.jwk.kty,this.jwk.crv),enumerable:!0,configurable:!1}),this.algorithms}})}}return new this(es,eu)}filter(...ee){return this.#p.filter(...ee)}find(...ee){return this.#p.find(...ee)}every(...ee){return this.#p.every(...ee)}some(...ee){return this.#p.some(...ee)}map(...ee){return this.#p.map(...ee)}forEach(...ee){return this.#p.forEach(...ee)}reduce(...ee){return this.#p.reduce(...ee)}sort(...ee){return this.#p.sort(...ee)}*[Symbol.iterator](){for(let ee of this.#p)yield ee}}},65047:function(ee,et,en){let ei=en(51303);function merge(ee,...et){for(let en of et)if(ei(en))for(let[et,eo]of Object.entries(en))"__proto__"!==et&&"constructor"!==et&&(ei(ee[et])&&ei(eo)?ee[et]=merge(ee[et],eo):void 0!==eo&&(ee[et]=eo));return ee}ee.exports=merge},76038:function(ee){ee.exports=function(ee,...et){let en={};for(let ei of et)void 0!==ee[ei]&&(en[ei]=ee[ei]);return en}},47787:function(ee,et,en){var ei=en(48764).Buffer;let{STATUS_CODES:eo}=en(22321),{format:ea}=en(79720),{OPError:es}=en(67486),eu=en(88026),throwAuthenticateErrors=ee=>{let et=eu(ee.headers["www-authenticate"]);if(et.error)throw new es(et,ee)},isStandardBodyError=ee=>{let et=!1;try{let en;en="object"!=typeof ee.body||ei.isBuffer(ee.body)?JSON.parse(ee.body):ee.body,(et="string"==typeof en.error&&en.error.length)&&Object.defineProperty(ee,"body",{value:en,configurable:!0})}catch(ee){}return et};function processResponse(ee,{statusCode:et=200,body:en=!0,bearer:ei=!1}={}){if(ee.statusCode!==et){if(ei&&throwAuthenticateErrors(ee),isStandardBodyError(ee))throw new es(ee.body,ee);throw new es({error:ea("expected %i %s, got: %i %s",et,eo[et],ee.statusCode,eo[ee.statusCode])},ee)}if(en&&!ee.body)throw new es({error:ea("expected %i %s with body but no body was returned",et,eo[et])},ee);return ee.body}ee.exports=processResponse},3862:function(ee,et,en){let ei;var eo=en(48764).Buffer;let ea=en(27596),es=en(97334),eu=en(22321),ec=en(78428),{once:ed}=en(25293),{URL:ef}=en(11987),ep=en(39593),eh=en(82696),{RPError:ey}=en(67486),em=en(76038),{deep:eg}=en(51892),{HTTP_OPTIONS:eb}=en(78026),ev=/^[\x21\x23-\x5B\x5D-\x7E]+$/,e_=["agent","ca","cert","crl","headers","key","lookup","passphrase","pfx","timeout"],setDefaults=(ee,et)=>{ei=eg({},ee.length?em(et,...ee):et,ei)};function send(ee,et,en){en&&(ee.removeHeader("content-type"),ee.setHeader("content-type",en)),et&&(ee.removeHeader("content-length"),ee.setHeader("content-length",eo.byteLength(et)),ee.write(et)),ee.end()}setDefaults([],{headers:{"User-Agent":`${eh.name}/${eh.version} (${eh.homepage})`,"Accept-Encoding":"identity"},timeout:3500});let ew=new ep({max:100});ee.exports=async function(ee,{accessToken:et,mTLS:en=!1,DPoP:ep}={}){let eh,eS,eE,eA,e$,ex,eC;try{eh=new ef(ee.url),delete ee.url,ea(/^(https?:)$/.test(eh.protocol))}catch(ee){throw TypeError("only valid absolute URLs can be requested")}let ek=this[eb],eO=ee,eT=`${eh.origin}${eh.pathname}`;if(ep&&"dpopProof"in this&&(eO.headers=eO.headers||{},eO.headers.DPoP=await this.dpopProof({htu:`${eh.origin}${eh.pathname}`,htm:ee.method||"GET",nonce:ew.get(eT)},ep,et)),ek&&(eS=em(ek.call(this,eh,eg({},eO,ei)),...e_)),eO=eg({},eS,eO,ei),en&&!eO.pfx&&!(eO.key&&eO.cert))throw TypeError("mutual-TLS certificate and key not set");if(eO.searchParams)for(let[ee,et]of Object.entries(eO.searchParams))eh.searchParams.delete(ee),eh.searchParams.set(ee,et);for(let[ee,et]of({form:eA,responseType:eE,json:e$,body:ex,...eO}=eO,Object.entries(eO.headers||{})))void 0===et&&delete eO.headers[ee];let eP=("https:"===eh.protocol?ec.request:eu.request)(eh.href,eO);return(async()=>{if(e$?send(eP,JSON.stringify(e$),"application/json"):eA?send(eP,es.stringify(eA),"application/x-www-form-urlencoded"):ex?send(eP,ex):send(eP),[eC]=await Promise.race([ed(eP,"response"),ed(eP,"timeout")]),!eC)throw eP.destroy(),new ey(`outgoing request timed out after ${eO.timeout}ms`);let ee=[];for await(let et of eC)ee.push(et);if(ee.length)switch(eE){case"json":Object.defineProperty(eC,"body",{get(){let et=eo.concat(ee);try{et=JSON.parse(et)}catch(ee){throw Object.defineProperty(ee,"response",{value:eC}),ee}finally{Object.defineProperty(eC,"body",{value:et,configurable:!0})}return et},configurable:!0});break;case void 0:case"buffer":Object.defineProperty(eC,"body",{get(){let et=eo.concat(ee);return Object.defineProperty(eC,"body",{value:et,configurable:!0}),et},configurable:!0});break;default:throw TypeError("unsupported responseType request option")}return eC})().catch(ee=>{throw eC&&Object.defineProperty(ee,"response",{value:eC}),ee}).finally(()=>{let ee=eC&&eC.headers["dpop-nonce"];ee&&ev.test(ee)&&ew.set(eT,ee)})},ee.exports.setDefaults=setDefaults.bind(void 0,e_)},96891:function(ee){ee.exports=()=>Math.floor(Date.now()/1e3)},64385:function(ee){ee.exports.keystores=new WeakMap},44818:function(ee){let et=/^\d+$/;function hasScheme(ee){if(ee.includes("://"))return!0;let en=ee.replace(/(\/|\?)/g,"#").split("#")[0];if(en.includes(":")){let ee=en.indexOf(":"),ei=en.slice(ee+1);if(!et.test(ei))return!0}return!1}function acctSchemeAssumed(ee){if(!ee.includes("@"))return!1;let et=ee.split("@"),en=et[et.length-1];return!(en.includes(":")||en.includes("/")||en.includes("?"))}function normalize(ee){let et;if("string"!=typeof ee)throw TypeError("input must be a string");return(et=hasScheme(ee)?ee:acctSchemeAssumed(ee)?`acct:${ee}`:`https://${ee}`).split("#")[0]}ee.exports=normalize},88026:function(ee){let et=/(\w+)=("[^"]*")/g;ee.exports=ee=>{let en={};try{for(;null!==et.exec(ee);)RegExp.$1&&RegExp.$2&&(en[RegExp.$1]=RegExp.$2.slice(1,-1))}catch(ee){}return en}},1831:function(ee,et,en){let ei=en(29704),{OPError:eo,RPError:ea}=en(67486),es=en(29330),eu=en(81911),{CLOCK_TOLERANCE:ec,HTTP_OPTIONS:ed}=en(78026),ef=en(68767),{setDefaults:ep}=en(3862);ee.exports={Issuer:ei,Strategy:es,TokenSet:eu,errors:{OPError:eo,RPError:ea},custom:{setHttpOptionsDefaults:ep,http_options:ed,clock_tolerance:ec},generators:ef}},29704:function(ee,et,en){var ei=en(34155);let{inspect:eo}=en(79720),ea=en(11987),{RPError:es}=en(67486),eu=en(62251),ec=en(30748),ed=en(47787),ef=en(44818),ep=en(3862),eh=en(71050),{keystore:ey}=en(17042),em=["https://login.microsoftonline.com/common/.well-known/openid-configuration","https://login.microsoftonline.com/common/v2.0/.well-known/openid-configuration","https://login.microsoftonline.com/organizations/v2.0/.well-known/openid-configuration","https://login.microsoftonline.com/consumers/v2.0/.well-known/openid-configuration"],eg=Symbol(),eb={claim_types_supported:["normal"],claims_parameter_supported:!1,grant_types_supported:["authorization_code","implicit"],request_parameter_supported:!1,request_uri_parameter_supported:!0,require_request_uri_registration:!1,response_modes_supported:["query","fragment"],token_endpoint_auth_methods_supported:["client_secret_basic"]};let Issuer=class Issuer{#e;constructor(ee={}){let et=ee[eg];delete ee[eg],["introspection","revocation"].forEach(et=>{ee[`${et}_endpoint`]&&void 0===ee[`${et}_endpoint_auth_methods_supported`]&&void 0===ee[`${et}_endpoint_auth_signing_alg_values_supported`]&&(ee.token_endpoint_auth_methods_supported&&(ee[`${et}_endpoint_auth_methods_supported`]=ee.token_endpoint_auth_methods_supported),ee.token_endpoint_auth_signing_alg_values_supported&&(ee[`${et}_endpoint_auth_signing_alg_values_supported`]=ee.token_endpoint_auth_signing_alg_values_supported))}),this.#e=new Map,Object.entries(ee).forEach(([ee,et])=>{this.#e.set(ee,et),this[ee]||Object.defineProperty(this,ee,{get(){return this.#e.get(ee)},enumerable:!0})}),ec.set(this.issuer,this);let en=eu(this,et);Object.defineProperties(this,{Client:{value:en,enumerable:!0},FAPI1Client:{value:class extends en{},enumerable:!0},FAPI2Client:{value:class extends en{},enumerable:!0}})}get metadata(){return eh(Object.fromEntries(this.#e.entries()))}static async webfinger(ee){let et=ef(ee),{host:en}=ea.parse(et),ei=`https://${en}/.well-known/webfinger`,eo=await ep.call(this,{method:"GET",url:ei,responseType:"json",searchParams:{resource:et,rel:"http://openid.net/specs/connect/1.0/issuer"},headers:{Accept:"application/json"}}),eu=ed(eo),eh=Array.isArray(eu.links)&&eu.links.find(ee=>"object"==typeof ee&&"http://openid.net/specs/connect/1.0/issuer"===ee.rel&&ee.href);if(!eh)throw new es({message:"no issuer found in webfinger response",body:eu});if("string"!=typeof eh.href||!eh.href.startsWith("https://"))throw new es({printf:["invalid issuer location %s",eh.href],body:eu});let ey=eh.href;if(ec.has(ey))return ec.get(ey);let em=await this.discover(ey);if(em.issuer!==ey)throw ec.del(em.issuer),new es("discovered issuer mismatch, expected %s, got: %s",ey,em.issuer);return em}static async discover(ee){let et=resolveWellKnownUri(ee),en=await ep.call(this,{method:"GET",responseType:"json",url:et,headers:{Accept:"application/json"}}),ei=ed(en);return new Issuer({...eb,...ei,[eg]:!!em.find(ee=>et.startsWith(ee))})}async reloadJwksUri(){await ey.call(this,!0)}[eo.custom](){return`${this.constructor.name} ${eo(this.metadata,{depth:1/0,colors:ei.stdout.isTTY,compact:!1,sorted:!0})}`}};function resolveWellKnownUri(ee){let et=ea.parse(ee);if(et.pathname.includes("/.well-known/"))return ee;{let ee;return ee=et.pathname.endsWith("/")?`${et.pathname}.well-known/openid-configuration`:`${et.pathname}/.well-known/openid-configuration`,ea.format({...et,pathname:ee})}}ee.exports=Issuer},30748:function(ee,et,en){let ei=en(39593);ee.exports=new ei({max:100})},29330:function(ee,et,en){let ei=en(11987),{format:eo}=en(79720),ea=en(71050),{RPError:es,OPError:eu}=en(67486),{BaseClient:ec}=en(62251),{random:ed,codeChallenge:ef}=en(68767),ep=en(76038),{resolveResponseType:eh,resolveRedirectUri:ey}=en(4944);function verified(ee,et,en={}){ee?this.error(ee):et?this.success(et,en):this.fail(en)}function OpenIDConnectStrategy({client:ee,params:et={},passReqToCallback:en=!1,sessionKey:eo,usePKCE:es=!0,extras:eu={}}={},ed){if(!(ee instanceof ec))throw TypeError("client must be an instance of openid-client Client");if("function"!=typeof ed)throw TypeError("verify callback must be a function");if(!ee.issuer||!ee.issuer.issuer)throw TypeError("client must have an issuer with an identifier");if(this._client=ee,this._issuer=ee.issuer,this._verify=ed,this._passReqToCallback=en,this._usePKCE=es,this._key=eo||`oidc:${ei.parse(this._issuer.issuer).hostname}`,this._params=ea(et),delete this._params.state,delete this._params.nonce,this._extras=ea(eu),this._params.response_type||(this._params.response_type=eh.call(ee)),this._params.redirect_uri||(this._params.redirect_uri=ey.call(ee)),this._params.scope||(this._params.scope="openid"),!0===this._usePKCE){let ee=!!Array.isArray(this._issuer.code_challenge_methods_supported)&&this._issuer.code_challenge_methods_supported;if(ee&&ee.includes("S256"))this._usePKCE="S256";else if(ee&&ee.includes("plain"))this._usePKCE="plain";else if(ee)throw TypeError("neither code_challenge_method supported by the client is supported by the issuer");else this._usePKCE="S256"}else if("string"==typeof this._usePKCE&&!["plain","S256"].includes(this._usePKCE))throw TypeError(`${this._usePKCE} is not valid/implemented PKCE code_challenge_method`);this.name=ei.parse(ee.issuer.issuer).hostname}OpenIDConnectStrategy.prototype.authenticate=function(ee,et){(async()=>{let en=this._client;if(!ee.session)throw TypeError("authentication requires session support");let ei=en.callbackParams(ee),ea=this._key,{0:eu,length:ec}=Object.keys(ei);if(0===ec||1===ec&&"iss"===eu){let ei={state:ed(),...this._params,...et};if(!ei.nonce&&ei.response_type.includes("id_token")&&(ei.nonce=ed()),ee.session[ea]=ep(ei,"nonce","state","max_age","response_type"),this._usePKCE&&ei.response_type.includes("code")){let et=ed();switch(ee.session[ea].code_verifier=et,this._usePKCE){case"S256":ei.code_challenge=ef(et),ei.code_challenge_method="S256";break;case"plain":ei.code_challenge=et}}this.redirect(en.authorizationUrl(ei));return}let eh=ee.session[ea];if(0===Object.keys(eh||{}).length)throw Error(eo('did not find expected authorization request details in session, req.session["%s"] is %j',ea,eh));let{state:ey,nonce:em,max_age:eg,code_verifier:eb,response_type:ev}=eh;try{delete ee.session[ea]}catch(ee){}let e_={redirect_uri:this._params.redirect_uri,...et},ew={state:ey,nonce:em,max_age:eg,code_verifier:eb,response_type:ev},eS=await en.callback(e_.redirect_uri,ei,ew,this._extras),eE=this._passReqToCallback,eA=this._verify.length>(eE?3:2)&&en.issuer.userinfo_endpoint,e$=[eS,verified.bind(this)];if(eA){if(!eS.access_token)throw new es({message:"expected access_token to be returned when asking for userinfo in verify callback",tokenset:eS});let ee=await en.userinfo(eS);e$.splice(1,0,ee)}eE&&e$.unshift(ee),this._verify(...e$)})().catch(ee=>{ee instanceof eu&&"server_error"!==ee.error&&!ee.error.startsWith("invalid")||ee instanceof es?this.fail(ee):this.error(ee)})},ee.exports=OpenIDConnectStrategy},81911:function(ee,et,en){let ei=en(42806),eo=en(96891);let TokenSet=class TokenSet{constructor(ee){Object.assign(this,ee);let{constructor:et,...en}=Object.getOwnPropertyDescriptors(this.constructor.prototype);Object.defineProperties(this,en)}set expires_in(ee){this.expires_at=eo()+Number(ee)}get expires_in(){return Math.max.apply(null,[this.expires_at-eo(),0])}expired(){return 0===this.expires_in}claims(){if(!this.id_token)throw TypeError("id_token not present in TokenSet");return JSON.parse(ei.decode(this.id_token.split(".")[1]))}};ee.exports=TokenSet},83302:function(ee){!function(et){ee.exports=et()}(function(){return(function o(ee,et,en){function s(eo,ea){if(!et[eo]){if(!ee[eo]){var es=void 0;if(!ea&&es)return require(eo,!0);if(ei)return ei(eo,!0);throw Error("Cannot find module '"+eo+"'")}var eu=et[eo]={exports:{}};ee[eo][0].call(eu.exports,function(et){return s(ee[eo][1][et]||et)},eu,eu.exports,o,ee,et,en)}return et[eo].exports}for(var ei=void 0,eo=0;eo>16),s((65280&ei)>>8),s(255&ei);return 2==ea?s(255&(ei=c(ee.charAt(en))<<2|c(ee.charAt(en+1))>>4)):1==ea&&(s((ei=c(ee.charAt(en))<<10|c(ee.charAt(en+1))<<4|c(ee.charAt(en+2))>>2)>>8&255),s(255&ei)),es},ee.fromByteArray=function(ee){var et,en,ei,eo,ea=ee.length%3,es="";function a(ee){return"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt(ee)}for(et=0,ei=ee.length-ea;et>18&63)+a(eo>>12&63)+a(eo>>6&63)+a(63&eo);switch(ea){case 1:es+=a((en=ee[ee.length-1])>>2)+a(en<<4&63)+"==";break;case 2:es+=a((en=(ee[ee.length-2]<<8)+ee[ee.length-1])>>10)+a(en>>4&63)+a(en<<2&63)+"="}return es}}(void 0===en?this.base64js={}:en)}).call(this,ee("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},ee("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/base64-js/lib/b64.js","/node_modules/gulp-browserify/node_modules/base64-js/lib")},{buffer:3,lYpoI2:10}],3:[function(ee,et,en){(function(et,ei,g,eo,ea,es,eu,ec,ed){var ef=ee("base64-js"),ep=ee("ieee754");function g(ee,et,en){if(!(this instanceof g))return new g(ee,et,en);var ei,eo,ea,es,eu,ec=typeof ee;if("base64"===et&&"string"==ec)for(ee=(ei=ee).trim?ei.trim():ei.replace(/^\s+|\s+$/g,"");ee.length%4!=0;)ee+="=";if("number"==ec)eo=x(ee);else if("string"==ec)eo=g.byteLength(ee,et);else{if("object"!=ec)throw Error("First argument needs to be a number, array or string.");eo=x(ee.length)}if(g._useTypedArrays?ea=g._augment(new Uint8Array(eo)):((ea=this).length=eo,ea._isBuffer=!0),g._useTypedArrays&&"number"==typeof ee.byteLength)ea._set(ee);else if(S(eu=ee)||g.isBuffer(eu)||eu&&"object"==typeof eu&&"number"==typeof eu.length)for(es=0;es>8,ei.push(et%256),ei.push(en);return ei}(et),ee,en,ei)}function c(ee,et,en){var ei="";en=Math.min(ee.length,en);for(var eo=et;eo>>0)):(et+1>>0),eo}function h(ee,et,en,ei){if(ei||(D("boolean"==typeof en,"missing or invalid endian"),D(null!=et,"missing offset"),D(et+1>>8*(ei?es:1-es)}function _(ee,et,en,ei,eo){eo||(D(null!=et,"missing value"),D("boolean"==typeof ei,"missing or invalid endian"),D(null!=en,"missing offset"),D(en+3>>8*(ei?es:3-es)&255}function E(ee,et,en,ei,eo){eo||(D(null!=et,"missing value"),D("boolean"==typeof ei,"missing or invalid endian"),D(null!=en,"missing offset"),D(en+1this.length&&(ei=this.length),ee.length-et=this.length))return this[ee]},g.prototype.readUInt16LE=function(ee,et){return l(this,ee,!0,et)},g.prototype.readUInt16BE=function(ee,et){return l(this,ee,!1,et)},g.prototype.readUInt32LE=function(ee,et){return d(this,ee,!0,et)},g.prototype.readUInt32BE=function(ee,et){return d(this,ee,!1,et)},g.prototype.readInt8=function(ee,et){if(et||(D(null!=ee,"missing offset"),D(ee=this.length))return 128&this[ee]?-1*(255-this[ee]+1):this[ee]},g.prototype.readInt16LE=function(ee,et){return h(this,ee,!0,et)},g.prototype.readInt16BE=function(ee,et){return h(this,ee,!1,et)},g.prototype.readInt32LE=function(ee,et){return p(this,ee,!0,et)},g.prototype.readInt32BE=function(ee,et){return p(this,ee,!1,et)},g.prototype.readFloatLE=function(ee,et){return b(this,ee,!0,et)},g.prototype.readFloatBE=function(ee,et){return b(this,ee,!1,et)},g.prototype.readDoubleLE=function(ee,et){return m(this,ee,!0,et)},g.prototype.readDoubleBE=function(ee,et){return m(this,ee,!1,et)},g.prototype.writeUInt8=function(ee,et,en){en||(D(null!=ee,"missing value"),D(null!=et,"missing offset"),D(et=this.length||(this[et]=ee)},g.prototype.writeUInt16LE=function(ee,et,en){v(this,ee,et,!0,en)},g.prototype.writeUInt16BE=function(ee,et,en){v(this,ee,et,!1,en)},g.prototype.writeUInt32LE=function(ee,et,en){_(this,ee,et,!0,en)},g.prototype.writeUInt32BE=function(ee,et,en){_(this,ee,et,!1,en)},g.prototype.writeInt8=function(ee,et,en){en||(D(null!=ee,"missing value"),D(null!=et,"missing offset"),D(et=this.length||(0<=ee?this.writeUInt8(ee,et,en):this.writeUInt8(255+ee+1,et,en))},g.prototype.writeInt16LE=function(ee,et,en){E(this,ee,et,!0,en)},g.prototype.writeInt16BE=function(ee,et,en){E(this,ee,et,!1,en)},g.prototype.writeInt32LE=function(ee,et,en){I(this,ee,et,!0,en)},g.prototype.writeInt32BE=function(ee,et,en){I(this,ee,et,!1,en)},g.prototype.writeFloatLE=function(ee,et,en){A(this,ee,et,!0,en)},g.prototype.writeFloatBE=function(ee,et,en){A(this,ee,et,!1,en)},g.prototype.writeDoubleLE=function(ee,et,en){B(this,ee,et,!0,en)},g.prototype.writeDoubleBE=function(ee,et,en){B(this,ee,et,!1,en)},g.prototype.fill=function(ee,et,en){if(ee=ee||0,et=et||0,en=en||this.length,"string"==typeof ee&&(ee=ee.charCodeAt(0)),D("number"==typeof ee&&!isNaN(ee),"value is not a number"),D(et<=en,"end < start"),en!==et&&0!==this.length){D(0<=et&&et"},g.prototype.toArrayBuffer=function(){if("undefined"==typeof Uint8Array)throw Error("Buffer.toArrayBuffer not supported in this browser");if(g._useTypedArrays)return new g(this).buffer;for(var ee=new Uint8Array(this.length),et=0,en=ee.length;et=et.length||eo>=ee.length);eo++)et[eo+en]=ee[eo];return eo}function M(ee){try{return decodeURIComponent(ee)}catch(ee){return String.fromCharCode(65533)}}function N(ee,et){D("number"==typeof ee,"cannot write a non-number as a number"),D(0<=ee,"specified a negative value for writing an unsigned value"),D(ee<=et,"value is larger than maximum value for type"),D(Math.floor(ee)===ee,"value has a fractional component")}function Y(ee,et,en){D("number"==typeof ee,"cannot write a non-number as a number"),D(ee<=et,"value larger than maximum allowed value"),D(en<=ee,"value smaller than minimum allowed value"),D(Math.floor(ee)===ee,"value has a fractional component")}function F(ee,et,en){D("number"==typeof ee,"cannot write a non-number as a number"),D(ee<=et,"value larger than maximum allowed value"),D(en<=ee,"value smaller than minimum allowed value")}function D(ee,et){if(!ee)throw Error(et||"Failed assertion")}g._augment=function(ee){return ee._isBuffer=!0,ee._get=ee.get,ee._set=ee.set,ee.get=eh.get,ee.set=eh.set,ee.write=eh.write,ee.toString=eh.toString,ee.toLocaleString=eh.toString,ee.toJSON=eh.toJSON,ee.copy=eh.copy,ee.slice=eh.slice,ee.readUInt8=eh.readUInt8,ee.readUInt16LE=eh.readUInt16LE,ee.readUInt16BE=eh.readUInt16BE,ee.readUInt32LE=eh.readUInt32LE,ee.readUInt32BE=eh.readUInt32BE,ee.readInt8=eh.readInt8,ee.readInt16LE=eh.readInt16LE,ee.readInt16BE=eh.readInt16BE,ee.readInt32LE=eh.readInt32LE,ee.readInt32BE=eh.readInt32BE,ee.readFloatLE=eh.readFloatLE,ee.readFloatBE=eh.readFloatBE,ee.readDoubleLE=eh.readDoubleLE,ee.readDoubleBE=eh.readDoubleBE,ee.writeUInt8=eh.writeUInt8,ee.writeUInt16LE=eh.writeUInt16LE,ee.writeUInt16BE=eh.writeUInt16BE,ee.writeUInt32LE=eh.writeUInt32LE,ee.writeUInt32BE=eh.writeUInt32BE,ee.writeInt8=eh.writeInt8,ee.writeInt16LE=eh.writeInt16LE,ee.writeInt16BE=eh.writeInt16BE,ee.writeInt32LE=eh.writeInt32LE,ee.writeInt32BE=eh.writeInt32BE,ee.writeFloatLE=eh.writeFloatLE,ee.writeFloatBE=eh.writeFloatBE,ee.writeDoubleLE=eh.writeDoubleLE,ee.writeDoubleBE=eh.writeDoubleBE,ee.fill=eh.fill,ee.inspect=eh.inspect,ee.toArrayBuffer=eh.toArrayBuffer,ee}}).call(this,ee("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},ee("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/buffer/index.js","/node_modules/gulp-browserify/node_modules/buffer")},{"base64-js":2,buffer:3,ieee754:11,lYpoI2:10}],4:[function(ee,et,en){(function(en,ei,eo,ea,es,eu,ec,ed,ef){var eo=ee("buffer").Buffer,ep=4,eh=new eo(4);eh.fill(0),et.exports={hash:function(ee,et,en,ei){return eo.isBuffer(ee)||(ee=new eo(ee)),function(ee,et,en){for(var ei=new eo(et),ea=en?ei.writeInt32BE:ei.writeInt32LE,es=0;eseg?et=ee(et):et.length>5]|=128<>>9<<4)]=et;for(var en=1732584193,ei=-271733879,eo=-1732584194,ea=271733878,es=0;es>>32-eu,en)}function d(ee,et,en,ei,eo,ea,es){return l(et&en|~et&ei,ee,et,eo,ea,es)}function h(ee,et,en,ei,eo,ea,es){return l(et&ei|en&~ei,ee,et,eo,ea,es)}function p(ee,et,en,ei,eo,ea,es){return l(et^en^ei,ee,et,eo,ea,es)}function g(ee,et,en,ei,eo,ea,es){return l(en^(et|~ei),ee,et,eo,ea,es)}function y(ee,et){var en=(65535&ee)+(65535&et);return(ee>>16)+(et>>16)+(en>>16)<<16|65535&en}et.exports=function(ee){return ep.hash(ee,c,16)}}).call(this,ee("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},ee("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/crypto-browserify/md5.js","/node_modules/gulp-browserify/node_modules/crypto-browserify")},{"./helpers":4,buffer:3,lYpoI2:10}],7:[function(ee,et,en){(function(ee,en,ei,eo,ea,es,eu,ec,ed){var ef,ep;ep=function(ee){for(var et,en=Array(ee),ei=0;ei>>((3&ei)<<3)&255;return en},et.exports=ef||ep}).call(this,ee("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},ee("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/crypto-browserify/rng.js","/node_modules/gulp-browserify/node_modules/crypto-browserify")},{buffer:3,lYpoI2:10}],8:[function(ee,et,en){(function(en,ei,eo,ea,es,eu,ec,ed,ef){var ep=ee("./helpers");function c(ee,et){ee[et>>5]|=128<<24-et%32,ee[15+(et+64>>9<<4)]=et;for(var en,ei,eo,ea,es,eu=Array(80),ec=1732584193,ed=-271733879,ef=-1732584194,ep=271733878,eh=-1009589776,ey=0;ey>16)+(et>>16)+(en>>16)<<16|65535&en}function E(ee,et){return ee<>>32-et}et.exports=function(ee){return ep.hash(ee,c,20,!0)}}).call(this,ee("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},ee("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/crypto-browserify/sha.js","/node_modules/gulp-browserify/node_modules/crypto-browserify")},{"./helpers":4,buffer:3,lYpoI2:10}],9:[function(ee,et,en){(function(en,ei,eo,ea,es,eu,ec,ed,ef){function B(ee,et){var en=(65535&ee)+(65535&et);return(ee>>16)+(et>>16)+(en>>16)<<16|65535&en}function L(ee,et){return ee>>>et|ee<<32-et}function f(ee,et){var en,ei,eo,ea,es,eu,ec,ed,ef,ep,eh=[1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298],ey=[1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225],em=Array(64);ee[et>>5]|=128<<24-et%32,ee[15+(et+64>>9<<4)]=et;for(var eg,eb,ev,e_,ew,eS,eE,eA,e$=0;e$>>10,em[ex-7]),L(eE=em[ex-15],7)^L(eE,18)^eE>>>3),em[ex-16]),ef=B(B(B(B(ed,L(eS=es,6)^L(eS,11)^L(eS,25)),(ew=es)&eu^~ew&ec),eh[ex]),em[ex]),ep=B(L(e_=en,2)^L(e_,13)^L(e_,22),(eg=en)&(eb=ei)^eg&(ev=eo)^eb&ev),ed=ec,ec=eu,eu=es,es=B(ea,ef),ea=eo,eo=ei,ei=en,en=B(ef,ep);ey[0]=B(en,ey[0]),ey[1]=B(ei,ey[1]),ey[2]=B(eo,ey[2]),ey[3]=B(ea,ey[3]),ey[4]=B(es,ey[4]),ey[5]=B(eu,ey[5]),ey[6]=B(ec,ey[6]),ey[7]=B(ed,ey[7])}return ey}var ep=ee("./helpers");et.exports=function(ee){return ep.hash(ee,f,32,!0)}}).call(this,ee("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},ee("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/crypto-browserify/sha256.js","/node_modules/gulp-browserify/node_modules/crypto-browserify")},{"./helpers":4,buffer:3,lYpoI2:10}],10:[function(ee,et,en){(function(ee,en,ei,eo,ea,es,eu,ec,ed){function f(){}(ee=et.exports={}).nextTick=function(){var ee="undefined"!=typeof window&&window.setImmediate,et="undefined"!=typeof window&&window.postMessage&&window.addEventListener;if(ee)return function(ee){return window.setImmediate(ee)};if(et){var en=[];return window.addEventListener("message",function(ee){var et=ee.source;et!==window&&null!==et||"process-tick"!==ee.data||(ee.stopPropagation(),0>1,ef=-7,ep=en?eo-1:0,eh=en?-1:1,ey=ee[et+ep];for(ep+=eh,ea=ey&(1<<-ef)-1,ey>>=-ef,ef+=eu;0>=-ef,ef+=ei;0>1,eh=23===eo?5960464477539062e-23:0,ey=ei?0:ea-1,em=ei?1:-1,eg=et<0||0===et&&1/et<0?1:0;for(isNaN(et=Math.abs(et))||et===1/0?(eu=isNaN(et)?1:0,es=ef):(es=Math.floor(Math.log(et)/Math.LN2),et*(ec=Math.pow(2,-es))<1&&(es--,ec*=2),2<=(et+=1<=es+ep?eh/ec:eh*Math.pow(2,1-ep))*ec&&(es++,ec/=2),ef<=es+ep?(eu=0,es=ef):1<=es+ep?(eu=(et*ec-1)*Math.pow(2,eo),es+=ep):(eu=et*Math.pow(2,ep-1)*Math.pow(2,eo),es=0));8<=eo;ee[en+ey]=255&eu,ey+=em,eu/=256,eo-=8);for(es=es<]/,eu=/^xlink:?./,ec=/["&<]/;function s(ee){if(!1===ec.test(ee+=""))return ee;for(var et=0,en=0,ei="",eo="";en(et||40)||!en&&-1!==String(ee).indexOf("\n")||-1!==String(ee).indexOf("<")},ed={},ef=/([A-Z])/g;function p(ee){var et="";for(var en in ee){var ei=ee[en];null!=ei&&""!==ei&&(et&&(et+=" "),et+="-"==en[0]?en:ed[en]||(ed[en]=en.replace(ef,"-$1").toLowerCase()),et="number"==typeof ei&&!1===eo.test(en)?et+": "+ei+"px;":et+": "+ei+";")}return et||void 0}function d(ee,et){return Array.isArray(et)?et.reduce(d,ee):null!=et&&!1!==et&&ee.push(et),ee}function v(){this.__d=!0}function h(ee,et){return{__v:ee,context:et,props:ee.props,setState:v,forceUpdate:v,__d:!0,__h:[]}}function g(ee,et){var en=ee.contextType,ei=en&&et[en.__c];return null!=en?ei?ei.props.value:en.__:et}var ep=[];function m(ee,et,en,eo,ec,ed){if(null==ee||"boolean"==typeof ee)return"";if("object"!=typeof ee)return"function"==typeof ee?"":s(ee);var ef=en.pretty,eh=ef&&"string"==typeof ef?ef:" ";if(Array.isArray(ee)){for(var ey="",em=0;em0&&(ey+="\n"),ey+=m(ee[em],et,en,eo,ec,ed);return ey}if(void 0!==ee.constructor)return"";var eg,eb=ee.type,ev=ee.props,e_=!1;if("function"==typeof eb){if(e_=!0,!en.shallow||!eo&&!1!==en.renderRootComponent){if(eb===ei.Fragment){var ew=[];return d(ew,ee.props.children),m(ew,et,en,!1!==en.shallowHighOrder,ec,ed)}var eS,eE=ee.__c=h(ee,et);ei.options.__b&&ei.options.__b(ee);var eA=ei.options.__r;if(eb.prototype&&"function"==typeof eb.prototype.render){var e$=g(eb,et);(eE=ee.__c=new eb(ev,e$)).__v=ee,eE._dirty=eE.__d=!0,eE.props=ev,null==eE.state&&(eE.state={}),null==eE._nextState&&null==eE.__s&&(eE._nextState=eE.__s=eE.state),eE.context=e$,eb.getDerivedStateFromProps?eE.state=Object.assign({},eE.state,eb.getDerivedStateFromProps(eE.props,eE.state)):eE.componentWillMount&&(eE.componentWillMount(),eE.state=eE._nextState!==eE.state?eE._nextState:eE.__s!==eE.state?eE.__s:eE.state),eA&&eA(ee),eS=eE.render(eE.props,eE.state,eE.context)}else for(var ex=g(eb,et),eC=0;eE.__d&&eC++<25;)eE.__d=!1,eA&&eA(ee),eS=eb.call(ee.__c,ev,ex);return eE.getChildContext&&(et=Object.assign({},et,eE.getChildContext())),ei.options.diffed&&ei.options.diffed(ee),m(eS,et,en,!1!==en.shallowHighOrder,ec,ed)}eb=(eg=eb).displayName||eg!==Function&&eg.name||function(ee){var et=(Function.prototype.toString.call(ee).match(/^\s*function\s+([^( ]+)/)||"")[1];if(!et){for(var en=-1,ei=ep.length;ei--;)if(ep[ei]===ee){en=ei;break}en<0&&(en=ep.push(ee)-1),et="UnnamedComponent"+en}return et}(eg)}var ek,eO,eT="<"+eb;if(ev){var eP=Object.keys(ev);en&&!0===en.sortAttributes&&eP.sort();for(var eR=0;eR",es.test(eb))throw Error(eb+" is not a valid HTML tag name in "+eT);var eD,eB=ea.test(eb)||en.voidElements&&en.voidElements.test(eb),eU=[];if(eO)ef&&u(eO)&&(eO="\n"+eh+f(eO,eh)),eT+=eO;else if(null!=ek&&d(eD=[],ek).length){for(var eL=ef&&~eT.indexOf("\n"),eF=!1,eW=0;eW0&&"<"!=eq[0];eF&&eV?eU[eU.length-1]+=eq:eU.push(eq),eF=eV}else eU.push(eq)}}}if(ef&&eL)for(var eK=eU.length;eK--;)eU[eK]="\n"+eh+f(eU[eK],eh)}if(eU.length||eO)eT+=eU.join("");else if(en&&en.xml)return eT.substring(0,eT.length-1)+" />";return!eB||eD||eO?(ef&&~eT.indexOf("\n")&&(eT+="\n"),eT=eT+""):eT=eT.replace(/>$/," />"),eT}var eh={shallow:!0};S.render=S;var x=function(ee,et){return S(ee,et,eh)},ey=[];function S(ee,et,en){et=et||{};var eo=ei.options.__s;ei.options.__s=!0;var ea,es=(0,ei.h)(ei.Fragment,null);return es.__k=[ee],ea=en&&(en.pretty||en.voidElements||en.sortAttributes||en.shallow||en.allAttributes||en.xml||en.attributeHook)?m(ee,et,en):F(ee,et,!1,void 0,es),ei.options.__c&&ei.options.__c(ee,ey),ei.options.__s=eo,ey.length=0,ea}function w(ee){return null==ee||"boolean"==typeof ee?null:"string"==typeof ee||"number"==typeof ee||"bigint"==typeof ee?(0,ei.h)(null,null,ee):ee}function C(ee,et){return"className"===ee?"class":"htmlFor"===ee?"for":"defaultValue"===ee?"value":"defaultChecked"===ee?"checked":"defaultSelected"===ee?"selected":et&&eu.test(ee)?ee.toLowerCase().replace(/^xlink:?/,"xlink:"):ee}function O(ee,et){return"style"===ee&&null!=et&&"object"==typeof et?p(et):"a"===ee[0]&&"r"===ee[1]&&"boolean"==typeof et?String(et):et}var em=Array.isArray,eg=Object.assign;function F(ee,et,en,eo,eu){if(null==ee||!0===ee||!1===ee||""===ee)return"";if("object"!=typeof ee)return"function"==typeof ee?"":s(ee);if(em(ee)){var ec="";eu.__k=ee;for(var ed=0;ed",es.test(ef))throw Error(ef+" is not a valid HTML tag name in "+ew);var e$="",ex=!1;if(e_)e$+=e_,ex=!0;else if("string"==typeof ev)e$+=s(ev),ex=!0;else if(em(ev)){ee.__k=ev;for(var eC=0;eC";return ew+""}S.shallowRender=x,et.default=S},6400:function(ee,et,en){"use strict";en.r(et),en.d(et,{Component:function(){return b},Fragment:function(){return k},cloneElement:function(){return E},createContext:function(){return G},createElement:function(){return _},createRef:function(){return m},h:function(){return _},hydrate:function(){return D},isValidElement:function(){return es},options:function(){return eo},render:function(){return B},toChildArray:function(){return H}});var ei,eo,ea,es,eu,ec,ed,ef,ep,eh,ey,em,eg={},eb=[],ev=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,e_=Array.isArray;function d(ee,et){for(var en in et)ee[en]=et[en];return ee}function w(ee){var et=ee.parentNode;et&&et.removeChild(ee)}function _(ee,et,en){var eo,ea,es,eu={};for(es in et)"key"==es?eo=et[es]:"ref"==es?ea=et[es]:eu[es]=et[es];if(arguments.length>2&&(eu.children=arguments.length>3?ei.call(arguments,2):en),"function"==typeof ee&&null!=ee.defaultProps)for(es in ee.defaultProps)void 0===eu[es]&&(eu[es]=ee.defaultProps[es]);return g(ee,eu,eo,ea,null)}function g(ee,et,en,ei,es){var eu={type:ee,props:et,key:en,ref:ei,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,constructor:void 0,__v:null==es?++ea:es,__i:-1,__u:0};return null==es&&null!=eo.vnode&&eo.vnode(eu),eu}function m(){return{current:null}}function k(ee){return ee.children}function b(ee,et){this.props=ee,this.context=et}function x(ee,et){if(null==et)return ee.__?x(ee.__,ee.__i+1):null;for(var en;etet&&eu.sort(ef));P.__r=0}function S(ee,et,en,ei,eo,ea,es,eu,ec,ed,ef){var ep,eh,ey,em,ev,e_=ei&&ei.__k||eb,ew=et.length;for(en.__d=ec,$(en,et,e_),ec=en.__d,ep=0;ep0?g(eo.type,eo.props,eo.key,eo.ref?eo.ref:null,eo.__v):eo)?(eo.__=ee,eo.__b=ee.__b+1,eu=L(eo,en,es,ef),eo.__i=eu,ea=null,-1!==eu&&(ef--,(ea=en[eu])&&(ea.__u|=131072)),null==ea||null===ea.__v?(-1==eu&&ep--,"function"!=typeof eo.type&&(eo.__u|=65536)):eu!==es&&(eu==es-1?ep--:eu==es+1?ep++:eu>es?ef>ec-es?ep+=eu-es:ep--:eu(null!=ec&&0==(131072&ec.__u)?1:0))for(;es>=0||eu=0){if((ec=et[es])&&0==(131072&ec.__u)&&eo==ec.key&&ea===ec.type)return es;es--}if(eu2&&(ec.children=arguments.length>3?ei.call(arguments,2):en),g(ee.type,ec,eo||ee.key,ea||ee.ref,null)}function G(ee,et){var en={__c:et="__cC"+em++,__:ee,Consumer:function(ee,et){return ee.children(et)},Provider:function(ee){var en,ei;return this.getChildContext||(en=[],(ei={})[et]=this,this.getChildContext=function(){return ei},this.componentWillUnmount=function(){en=null},this.shouldComponentUpdate=function(ee){this.props.value!==ee.value&&en.some(function(ee){ee.__e=!0,M(ee)})},this.sub=function(ee){en.push(ee);var et=ee.componentWillUnmount;ee.componentWillUnmount=function(){en&&en.splice(en.indexOf(ee),1),et&&et.call(ee)}}),ee.children}};return en.Provider.__=en.Consumer.contextType=en}ei=eb.slice,eo={__e:function(ee,et,en,ei){for(var eo,ea,es;et=et.__;)if((eo=et.__c)&&!eo.__)try{if((ea=eo.constructor)&&null!=ea.getDerivedStateFromError&&(eo.setState(ea.getDerivedStateFromError(ee)),es=eo.__d),null!=eo.componentDidCatch&&(eo.componentDidCatch(ee,ei||{}),es=eo.__d),es)return eo.__E=eo}catch(et){ee=et}throw ee}},ea=0,es=function(ee){return null!=ee&&null==ee.constructor},b.prototype.setState=function(ee,et){var en;en=null!=this.__s&&this.__s!==this.state?this.__s:this.__s=d({},this.state),"function"==typeof ee&&(ee=ee(d({},en),this.props)),ee&&d(en,ee),null!=ee&&this.__v&&(et&&this._sb.push(et),M(this))},b.prototype.forceUpdate=function(ee){this.__v&&(this.__e=!0,ee&&this.__h.push(ee),M(this))},b.prototype.render=k,eu=[],ed="function"==typeof Promise?Promise.prototype.then.bind(Promise.resolve()):setTimeout,ef=function(ee,et){return ee.__v.__b-et.__v.__b},P.__r=0,ep=0,eh=F(!1),ey=F(!0),em=0},34155:function(ee){var et,en,ei,eo=ee.exports={};function defaultSetTimout(){throw Error("setTimeout has not been defined")}function defaultClearTimeout(){throw Error("clearTimeout has not been defined")}function runTimeout(ee){if(et===setTimeout)return setTimeout(ee,0);if((et===defaultSetTimout||!et)&&setTimeout)return et=setTimeout,setTimeout(ee,0);try{return et(ee,0)}catch(en){try{return et.call(null,ee,0)}catch(en){return et.call(this,ee,0)}}}function runClearTimeout(ee){if(en===clearTimeout)return clearTimeout(ee);if((en===defaultClearTimeout||!en)&&clearTimeout)return en=clearTimeout,clearTimeout(ee);try{return en(ee)}catch(et){try{return en.call(null,ee)}catch(et){return en.call(this,ee)}}}!function(){try{et="function"==typeof setTimeout?setTimeout:defaultSetTimout}catch(ee){et=defaultSetTimout}try{en="function"==typeof clearTimeout?clearTimeout:defaultClearTimeout}catch(ee){en=defaultClearTimeout}}();var ea=[],es=!1,eu=-1;function cleanUpNextTick(){es&&ei&&(es=!1,ei.length?ea=ei.concat(ea):eu=-1,ea.length&&drainQueue())}function drainQueue(){if(!es){var ee=runTimeout(cleanUpNextTick);es=!0;for(var et=ea.length;et;){for(ei=ea,ea=[];++eu1)for(var en=1;en */var ei=en(48764),eo=ei.Buffer;function copyProps(ee,et){for(var en in ee)et[en]=ee[en]}function SafeBuffer(ee,et,en){return eo(ee,et,en)}eo.from&&eo.alloc&&eo.allocUnsafe&&eo.allocUnsafeSlow?ee.exports=ei:(copyProps(ei,et),et.Buffer=SafeBuffer),SafeBuffer.prototype=Object.create(eo.prototype),copyProps(eo,SafeBuffer),SafeBuffer.from=function(ee,et,en){if("number"==typeof ee)throw TypeError("Argument must not be a number");return eo(ee,et,en)},SafeBuffer.alloc=function(ee,et,en){if("number"!=typeof ee)throw TypeError("Argument must be a number");var ei=eo(ee);return void 0!==et?"string"==typeof en?ei.fill(et,en):ei.fill(et):ei.fill(0),ei},SafeBuffer.allocUnsafe=function(ee){if("number"!=typeof ee)throw TypeError("Argument must be a number");return eo(ee)},SafeBuffer.allocUnsafeSlow=function(ee){if("number"!=typeof ee)throw TypeError("Argument must be a number");return ei.SlowBuffer(ee)}},32553:function(ee,et,en){"use strict";var ei=en(89509).Buffer,eo=ei.isEncoding||function(ee){switch((ee=""+ee)&&ee.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function _normalizeEncoding(ee){var et;if(!ee)return"utf8";for(;;)switch(ee){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return ee;default:if(et)return;ee=(""+ee).toLowerCase(),et=!0}}function normalizeEncoding(ee){var et=_normalizeEncoding(ee);if("string"!=typeof et&&(ei.isEncoding===eo||!eo(ee)))throw Error("Unknown encoding: "+ee);return et||ee}function StringDecoder(ee){var et;switch(this.encoding=normalizeEncoding(ee),this.encoding){case"utf16le":this.text=utf16Text,this.end=utf16End,et=4;break;case"utf8":this.fillLast=utf8FillLast,et=4;break;case"base64":this.text=base64Text,this.end=base64End,et=3;break;default:this.write=simpleWrite,this.end=simpleEnd;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=ei.allocUnsafe(et)}function utf8CheckByte(ee){return ee<=127?0:ee>>5==6?2:ee>>4==14?3:ee>>3==30?4:ee>>6==2?-1:-2}function utf8CheckIncomplete(ee,et,en){var ei=et.length-1;if(ei=0?(eo>0&&(ee.lastNeed=eo-1),eo):--ei=0?(eo>0&&(ee.lastNeed=eo-2),eo):--ei=0?(eo>0&&(2===eo?eo=0:ee.lastNeed=eo-3),eo):0}function utf8CheckExtraBytes(ee,et,en){if((192&et[0])!=128)return ee.lastNeed=0,"�";if(ee.lastNeed>1&&et.length>1){if((192&et[1])!=128)return ee.lastNeed=1,"�";if(ee.lastNeed>2&&et.length>2&&(192&et[2])!=128)return ee.lastNeed=2,"�"}}function utf8FillLast(ee){var et=this.lastTotal-this.lastNeed,en=utf8CheckExtraBytes(this,ee,et);return void 0!==en?en:this.lastNeed<=ee.length?(ee.copy(this.lastChar,et,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):void(ee.copy(this.lastChar,et,0,ee.length),this.lastNeed-=ee.length)}function utf8Text(ee,et){var en=utf8CheckIncomplete(this,ee,et);if(!this.lastNeed)return ee.toString("utf8",et);this.lastTotal=en;var ei=ee.length-(en-this.lastNeed);return ee.copy(this.lastChar,0,ei),ee.toString("utf8",et,ei)}function utf8End(ee){var et=ee&&ee.length?this.write(ee):"";return this.lastNeed?et+"�":et}function utf16Text(ee,et){if((ee.length-et)%2==0){var en=ee.toString("utf16le",et);if(en){var ei=en.charCodeAt(en.length-1);if(ei>=55296&&ei<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=ee[ee.length-2],this.lastChar[1]=ee[ee.length-1],en.slice(0,-1)}return en}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=ee[ee.length-1],ee.toString("utf16le",et,ee.length-1)}function utf16End(ee){var et=ee&&ee.length?this.write(ee):"";if(this.lastNeed){var en=this.lastTotal-this.lastNeed;return et+this.lastChar.toString("utf16le",0,en)}return et}function base64Text(ee,et){var en=(ee.length-et)%3;return 0===en?ee.toString("base64",et):(this.lastNeed=3-en,this.lastTotal=3,1===en?this.lastChar[0]=ee[ee.length-1]:(this.lastChar[0]=ee[ee.length-2],this.lastChar[1]=ee[ee.length-1]),ee.toString("base64",et,ee.length-en))}function base64End(ee){var et=ee&&ee.length?this.write(ee):"";return this.lastNeed?et+this.lastChar.toString("base64",0,3-this.lastNeed):et}function simpleWrite(ee){return ee.toString(this.encoding)}function simpleEnd(ee){return ee&&ee.length?this.write(ee):""}et.StringDecoder=StringDecoder,StringDecoder.prototype.write=function(ee){var et,en;if(0===ee.length)return"";if(this.lastNeed){if(void 0===(et=this.fillLast(ee)))return"";en=this.lastNeed,this.lastNeed=0}else en=0;return en({...et,context:ee(et.context,en,ei)}),getInitialSnapshot:(ee,en)=>({status:"active",output:void 0,error:void 0,context:"function"==typeof et?et({input:en}):et}),getPersistedSnapshot:ee=>ee,restoreSnapshot:ee=>ee}}let eo="xstate.promise.resolve",ea="xstate.promise.reject";function fromPromise(ee){let et={config:ee,transition:(ee,et)=>{if("active"!==ee.status)return ee;switch(et.type){case eo:{let en=et.data;return{...ee,status:"done",output:en,input:void 0}}case ea:return{...ee,status:"error",error:et.data,input:void 0};case ei.X:return{...ee,status:"stopped",input:void 0};default:return ee}},start:(et,{self:en,system:ei})=>{if("active"!==et.status)return;let es=Promise.resolve(ee({input:et.input,system:ei,self:en}));es.then(ee=>{"active"===en.getSnapshot().status&&ei._relay(en,en,{type:eo,data:ee})},ee=>{"active"===en.getSnapshot().status&&ei._relay(en,en,{type:ea,data:ee})})},getInitialSnapshot:(ee,et)=>({status:"active",output:void 0,error:void 0,input:et}),getPersistedSnapshot:ee=>ee,restoreSnapshot:ee=>ee};return et}fromTransition(ee=>void 0,void 0)},47243:function(ee,et,en){"use strict";en.d(et,{a:function(){return assign}});var ei=en(10195);function createSpawner(ee,{machine:et,context:en},eo,ea){let spawn=(es,eu={})=>{let{systemId:ec,input:ed}=eu;if("string"==typeof es){let ef=(0,ei.y)(et,es);if(!ef)throw Error(`Actor logic '${es}' not implemented in machine '${et.id}'`);let ep=(0,ei.z)(ef,{id:eu.id,parent:ee.self,syncSnapshot:eu.syncSnapshot,input:"function"==typeof ed?ed({context:en,event:eo,self:ee.self}):ed,src:es,systemId:ec});return ea[ep.id]=ep,ep}{let et=(0,ei.z)(es,{id:eu.id,parent:ee.self,syncSnapshot:eu.syncSnapshot,input:eu.input,src:es,systemId:ec});return et}};return(et,en)=>{let eo=spawn(et,en);return ea[eo.id]=eo,ee.defer(()=>{eo._processingStatus!==ei.R.Stopped&&eo.start()}),eo}}function resolveAssign(ee,et,en,eo,{assignment:ea}){if(!et.context)throw Error("Cannot assign to undefined `context`. Ensure that `context` is defined in the machine config.");let es={},eu={context:et.context,event:en.event,spawn:createSpawner(ee,et,en.event,es),self:ee.self,system:ee.system},ec={};if("function"==typeof ea)ec=ea(eu,eo);else for(let ee of Object.keys(ea)){let et=ea[ee];ec[ee]="function"==typeof et?et(eu,eo):et}let ed=Object.assign({},et.context,ec);return[(0,ei.T)(et,{context:ed,children:Object.keys(es).length?{...et.children,...es}:et.children})]}function assign(ee){function assign(ee,et){}return assign.type="xstate.assign",assign.assignment=ee,assign.resolve=resolveAssign,assign}},10195:function(ee,et,en){"use strict";function getGlobal(){return"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:void 0!==en.g?en.g:void 0}function getDevTools(){let ee=getGlobal();if(ee.__xstate__)return ee.__xstate__}en.d(et,{$:function(){return eh},N:function(){return ea},R:function(){return ey},S:function(){return ei},T:function(){return cloneMachineSnapshot},X:function(){return ed},a:function(){return toTransitionConfigArray},b:function(){return formatTransition},c:function(){return createInvokeId},d:function(){return formatInitialTransition},e:function(){return evaluateGuard},f:function(){return formatTransitions},g:function(){return getDelayedTransitions},h:function(){return getCandidates},i:function(){return getAllStateNodes},j:function(){return getStateNodes},k:function(){return createMachineSnapshot},l:function(){return isInFinalState},m:function(){return mapValues},n:function(){return macrostep},o:function(){return transitionNode},p:function(){return resolveActionsAndContext},q:function(){return createInitEvent},r:function(){return resolveStateValue},s:function(){return microstep},t:function(){return toArray},u:function(){return getInitialStateNodes},v:function(){return isStateId},w:function(){return getStateNodeByPath},x:function(){return getPersistedSnapshot},y:function(){return resolveReferencedActor},z:function(){return createActor}});let devToolsAdapter=ee=>{if("undefined"==typeof window)return;let et=getDevTools();et&&et.register(ee)};let Mailbox=class Mailbox{constructor(ee){this._process=ee,this._active=!1,this._current=null,this._last=null}start(){this._active=!0,this.flush()}clear(){this._current&&(this._current.next=null,this._last=this._current)}enqueue(ee){let et={value:ee,next:null};if(this._current){this._last.next=et,this._last=et;return}this._current=et,this._last=et,this._active&&this.flush()}flush(){for(;this._current;){let ee=this._current;this._process(ee.value),this._current=ee.next}this._last=null}};let ei=".",eo="",ea="",es="#",eu="*",ec="xstate.init",ed="xstate.stop";function createAfterEvent(ee,et){return{type:`xstate.after.${ee}.${et}`}}function createDoneStateEvent(ee,et){return{type:`xstate.done.state.${ee}`,output:et}}function createDoneActorEvent(ee,et){return{type:`xstate.done.actor.${ee}`,output:et}}function createErrorActorEvent(ee,et){return{type:`xstate.error.actor.${ee}`,error:et}}function createInitEvent(ee){return{type:ec,input:ee}}function reportUnhandledError(ee){setTimeout(()=>{throw ee})}let ef="function"==typeof Symbol&&Symbol.observable||"@@observable";function createScheduledEventId(ee,et){return`${ee.sessionId}.${et}`}let ep=0;function createSystem(ee,et){let en=new Map,ei=new Map,eo=new WeakMap,ea=new Set,es={},eu=et.clock,ec={schedule:(ee,et,en,ei,eo=Math.random().toString(36).slice(2))=>{let ea={source:ee,target:et,event:en,delay:ei,id:eo,startedAt:Date.now()},ec=createScheduledEventId(ee,eo);ed._snapshot._scheduledEvents[ec]=ea;let ef=eu.setTimeout(()=>{delete es[ec],delete ed._snapshot._scheduledEvents[ec],ed._relay(ee,et,en)},ei);es[ec]=ef},cancel:(ee,et)=>{let en=createScheduledEventId(ee,et),ei=es[en];delete es[en],delete ed._snapshot._scheduledEvents[en],eu.clearTimeout(ei)},cancelAll:ee=>{for(let et in ed._snapshot._scheduledEvents){let en=ed._snapshot._scheduledEvents[et];en.source===ee&&ec.cancel(ee,en.id)}}},ed={_snapshot:{_scheduledEvents:(et?.snapshot&&et.snapshot.scheduler)??{}},_bookId:()=>`x:${ep++}`,_register:(ee,et)=>(en.set(ee,et),ee),_unregister:ee=>{en.delete(ee.sessionId);let et=eo.get(ee);void 0!==et&&(ei.delete(et),eo.delete(ee))},get:ee=>ei.get(ee),_set:(ee,et)=>{let en=ei.get(ee);if(en&&en!==et)throw Error(`Actor with system ID '${ee}' already exists.`);ei.set(ee,et),eo.set(et,ee)},inspect:ee=>{ea.add(ee)},_sendInspectionEvent:et=>{let en={...et,rootId:ee.sessionId};ea.forEach(ee=>ee.next?.(en))},_relay:(ee,et,en)=>{ed._sendInspectionEvent({type:"@xstate.event",sourceRef:ee,actorRef:et,event:en}),et._send(en)},scheduler:ec,getSnapshot:()=>({_scheduledEvents:{...ed._snapshot._scheduledEvents}}),start:()=>{let ee=ed._snapshot._scheduledEvents;for(let et in ed._snapshot._scheduledEvents={},ee){let{source:en,target:ei,event:eo,delay:ea,id:es}=ee[et];ec.schedule(en,ei,eo,ea,es)}}};return ed}function matchesState(ee,et){let en=toStateValue(ee),ei=toStateValue(et);return"string"==typeof ei?"string"==typeof en&&ei===en:"string"==typeof en?en in ei:Object.keys(en).every(ee=>ee in ei&&matchesState(en[ee],ei[ee]))}function toStatePath(ee){return isArray(ee)?ee:ee.split(ei)}function toStateValue(ee){if(isMachineSnapshot(ee))return ee.value;if("string"!=typeof ee)return ee;let et=toStatePath(ee);return pathToStateValue(et)}function pathToStateValue(ee){if(1===ee.length)return ee[0];let et={},en=et;for(let et=0;etvoid 0===ee||"string"==typeof ee?{target:ee}:ee)}function normalizeTarget(ee){if(void 0!==ee&&ee!==eo)return toArray(ee)}function toObserver(ee,et,en){let ei="object"==typeof ee,eo=ei?ee:void 0;return{next:(ei?ee.next:ee)?.bind(eo),error:(ei?ee.error:et)?.bind(eo),complete:(ei?ee.complete:en)?.bind(eo)}}function createInvokeId(ee,et){return`${et}.${ee}`}function resolveReferencedActor(ee,et){let en=et.match(/^xstate\.invoke\.(\d+)\.(.*)/);if(!en)return ee.implementations.actors[et];let[,ei,eo]=en,ea=ee.getStateNodeById(eo),es=ea.config.invoke;return(Array.isArray(es)?es[ei]:es).src}let eh=1,ey=function(ee){return ee[ee.NotStarted=0]="NotStarted",ee[ee.Running=1]="Running",ee[ee.Stopped=2]="Stopped",ee}({}),em={clock:{setTimeout:(ee,et)=>setTimeout(ee,et),clearTimeout:ee=>clearTimeout(ee)},logger:console.log.bind(console),devTools:!1};let Actor=class Actor{constructor(ee,et){this.logic=ee,this._snapshot=void 0,this.clock=void 0,this.options=void 0,this.id=void 0,this.mailbox=new Mailbox(this._process.bind(this)),this.observers=new Set,this.logger=void 0,this._processingStatus=ey.NotStarted,this._parent=void 0,this._syncSnapshot=void 0,this.ref=void 0,this._actorScope=void 0,this._systemId=void 0,this.sessionId=void 0,this.system=void 0,this._doneEvent=void 0,this.src=void 0,this._deferred=[];let en={...em,...et},{clock:ei,logger:eo,parent:ea,syncSnapshot:es,id:eu,systemId:ec,inspect:ed}=en;this.system=ea?ea.system:createSystem(this,{clock:ei}),ed&&!ea&&this.system.inspect(toObserver(ed)),this.sessionId=this.system._bookId(),this.id=eu??this.sessionId,this.logger=eo,this.clock=ei,this._parent=ea,this._syncSnapshot=es,this.options=en,this.src=en.src??ee,this.ref=this,this._actorScope={self:this,id:this.id,sessionId:this.sessionId,logger:this.logger,defer:ee=>{this._deferred.push(ee)},system:this.system,stopChild:ee=>{if(ee._parent!==this)throw Error(`Cannot stop child actor ${ee.id} of ${this.id} because it is not a child`);ee._stop()}},this.send=this.send.bind(this),this.system._sendInspectionEvent({type:"@xstate.actor",actorRef:this}),ec&&(this._systemId=ec,this.system._set(ec,this)),this._initState(et?.snapshot??et?.state),ec&&"active"!==this._snapshot.status&&this.system._unregister(this)}_initState(ee){try{this._snapshot=ee?this.logic.restoreSnapshot?this.logic.restoreSnapshot(ee,this._actorScope):ee:this.logic.getInitialSnapshot(this._actorScope,this.options?.input)}catch(ee){this._snapshot={status:"error",output:void 0,error:ee}}}update(ee,et){let en;for(this._snapshot=ee;en=this._deferred.shift();)try{en()}catch(et){this._deferred.length=0,this._snapshot={...ee,status:"error",error:et}}switch(this._snapshot.status){case"active":for(let et of this.observers)try{et.next?.(ee)}catch(ee){reportUnhandledError(ee)}break;case"done":for(let et of this.observers)try{et.next?.(ee)}catch(ee){reportUnhandledError(ee)}this._stopProcedure(),this._complete(),this._doneEvent=createDoneActorEvent(this.id,this._snapshot.output),this._parent&&this.system._relay(this,this._parent,this._doneEvent);break;case"error":this._error(this._snapshot.error)}this.system._sendInspectionEvent({type:"@xstate.snapshot",actorRef:this,event:et,snapshot:ee})}subscribe(ee,et,en){let ei=toObserver(ee,et,en);if(this._processingStatus!==ey.Stopped)this.observers.add(ei);else switch(this._snapshot.status){case"done":try{ei.complete?.()}catch(ee){reportUnhandledError(ee)}break;case"error":{let ee=this._snapshot.error;if(ei.error)try{ei.error(ee)}catch(ee){reportUnhandledError(ee)}else reportUnhandledError(ee)}}return{unsubscribe:()=>{this.observers.delete(ei)}}}start(){if(this._processingStatus===ey.Running)return this;this._syncSnapshot&&this.subscribe({next:ee=>{"active"===ee.status&&this.system._relay(this,this._parent,{type:`xstate.snapshot.${this.id}`,snapshot:ee})},error:()=>{}}),this.system._register(this.sessionId,this),this._systemId&&this.system._set(this._systemId,this),this._processingStatus=ey.Running;let ee=createInitEvent(this.options.input);this.system._sendInspectionEvent({type:"@xstate.event",sourceRef:this._parent,actorRef:this,event:ee});let et=this._snapshot.status;switch(et){case"done":return this.update(this._snapshot,ee),this;case"error":return this._error(this._snapshot.error),this}if(this._parent||this.system.start(),this.logic.start)try{this.logic.start(this._snapshot,this._actorScope)}catch(ee){return this._snapshot={...this._snapshot,status:"error",error:ee},this._error(ee),this}return this.update(this._snapshot,ee),this.options.devTools&&this.attachDevTools(),this.mailbox.start(),this}_process(ee){let et,en;try{et=this.logic.transition(this._snapshot,ee,this._actorScope)}catch(ee){en={err:ee}}if(en){let{err:ee}=en;this._snapshot={...this._snapshot,status:"error",error:ee},this._error(ee);return}this.update(et,ee),ee.type===ed&&(this._stopProcedure(),this._complete())}_stop(){return this._processingStatus===ey.Stopped||((this.mailbox.clear(),this._processingStatus===ey.NotStarted)?this._processingStatus=ey.Stopped:this.mailbox.enqueue({type:ed})),this}stop(){if(this._parent)throw Error("A non-root actor cannot be stopped directly.");return this._stop()}_complete(){for(let ee of this.observers)try{ee.complete?.()}catch(ee){reportUnhandledError(ee)}this.observers.clear()}_reportError(ee){if(!this.observers.size){this._parent||reportUnhandledError(ee);return}let et=!1;for(let en of this.observers){let ei=en.error;et||=!ei;try{ei?.(ee)}catch(ee){reportUnhandledError(ee)}}this.observers.clear(),et&&reportUnhandledError(ee)}_error(ee){this._stopProcedure(),this._reportError(ee),this._parent&&this.system._relay(this,this._parent,createErrorActorEvent(this.id,ee))}_stopProcedure(){return this._processingStatus!==ey.Running||(this.system.scheduler.cancelAll(this),this.mailbox.clear(),this.mailbox=new Mailbox(this._process.bind(this)),this._processingStatus=ey.Stopped,this.system._unregister(this)),this}_send(ee){this._processingStatus!==ey.Stopped&&this.mailbox.enqueue(ee)}send(ee){this.system._relay(void 0,this,ee)}attachDevTools(){let{devTools:ee}=this.options;if(ee){let et="function"==typeof ee?ee:devToolsAdapter;et(this)}}toJSON(){return{xstate$$type:eh,id:this.id}}getPersistedSnapshot(ee){return this.logic.getPersistedSnapshot(this._snapshot,ee)}[ef](){return this}getSnapshot(){return this._snapshot}};function createActor(ee,et){return new Actor(ee,et)}function resolveCancel(ee,et,en,ei,{sendId:eo}){let ea="function"==typeof eo?eo(en,ei):eo;return[et,ea]}function executeCancel(ee,et){ee.defer(()=>{ee.system.scheduler.cancel(ee.self,et)})}function cancel(ee){function cancel(ee,et){}return cancel.type="xstate.cancel",cancel.sendId=ee,cancel.resolve=resolveCancel,cancel.execute=executeCancel,cancel}function resolveSpawn(ee,et,en,ei,{id:eo,systemId:ea,src:es,input:eu,syncSnapshot:ec}){let ed;let ef="string"==typeof es?resolveReferencedActor(et.machine,es):es,ep="function"==typeof eo?eo(en):eo;return ef&&(ed=createActor(ef,{id:ep,src:es,parent:ee.self,syncSnapshot:ec,systemId:ea,input:"function"==typeof eu?eu({context:et.context,event:en.event,self:ee.self}):eu})),[cloneMachineSnapshot(et,{children:{...et.children,[ep]:ed}}),{id:eo,actorRef:ed}]}function executeSpawn(ee,{id:et,actorRef:en}){en&&ee.defer(()=>{en._processingStatus!==ey.Stopped&&en.start()})}function spawnChild(...[ee,{id:et,systemId:en,input:ei,syncSnapshot:eo=!1}={}]){function spawnChild(ee,et){}return spawnChild.type="snapshot.spawnChild",spawnChild.id=et,spawnChild.systemId=en,spawnChild.src=ee,spawnChild.input=ei,spawnChild.syncSnapshot=eo,spawnChild.resolve=resolveSpawn,spawnChild.execute=executeSpawn,spawnChild}function resolveStop(ee,et,en,ei,{actorRef:eo}){let ea="function"==typeof eo?eo(en,ei):eo,es="string"==typeof ea?et.children[ea]:ea,eu=et.children;return es&&(eu={...eu},delete eu[es.id]),[cloneMachineSnapshot(et,{children:eu}),es]}function executeStop(ee,et){if(et){if(ee.system._unregister(et),et._processingStatus!==ey.Running){ee.stopChild(et);return}ee.defer(()=>{ee.stopChild(et)})}}function stopChild(ee){function stop(ee,et){}return stop.type="xstate.stopChild",stop.actorRef=ee,stop.resolve=resolveStop,stop.execute=executeStop,stop}function evaluateGuard(ee,et,en,ei){let{machine:eo}=ei,ea="function"==typeof ee,es=ea?ee:eo.implementations.guards["string"==typeof ee?ee:ee.type];if(!ea&&!es)throw Error(`Guard '${"string"==typeof ee?ee:ee.type}' is not implemented.'.`);if("function"!=typeof es)return evaluateGuard(es,et,en,ei);let eu={context:et,event:en},ec=ea||"string"==typeof ee?void 0:"params"in ee?"function"==typeof ee.params?ee.params({context:et,event:en}):ee.params:void 0;if(!("check"in es))return es(eu,ec);let ed=es;return ed.check(ei,eu,es)}let isAtomicStateNode=ee=>"atomic"===ee.type||"final"===ee.type;function getChildren(ee){return Object.values(ee.states).filter(ee=>"history"!==ee.type)}function getProperAncestors(ee,et){let en=[];if(et===ee)return en;let ei=ee.parent;for(;ei&&ei!==et;)en.push(ei),ei=ei.parent;return en}function getAllStateNodes(ee){let et=new Set(ee),en=getAdjList(et);for(let ee of et)if("compound"!==ee.type||en.get(ee)&&en.get(ee).length){if("parallel"===ee.type){for(let en of getChildren(ee))if("history"!==en.type&&!et.has(en)){let ee=getInitialStateNodesWithTheirAncestors(en);for(let en of ee)et.add(en)}}}else getInitialStateNodesWithTheirAncestors(ee).forEach(ee=>et.add(ee));for(let ee of et){let en=ee.parent;for(;en;)et.add(en),en=en.parent}return et}function getValueFromAdj(ee,et){let en=et.get(ee);if(!en)return{};if("compound"===ee.type){let ee=en[0];if(!ee)return{};if(isAtomicStateNode(ee))return ee.key}let ei={};for(let ee of en)ei[ee.key]=getValueFromAdj(ee,et);return ei}function getAdjList(ee){let et=new Map;for(let en of ee)et.has(en)||et.set(en,[]),en.parent&&(et.has(en.parent)||et.set(en.parent,[]),et.get(en.parent).push(en));return et}function getStateValue(ee,et){let en=getAllStateNodes(et);return getValueFromAdj(ee,getAdjList(en))}function isInFinalState(ee,et){return"compound"===et.type?getChildren(et).some(et=>"final"===et.type&&ee.has(et)):"parallel"===et.type?getChildren(et).every(et=>isInFinalState(ee,et)):"final"===et.type}let isStateId=ee=>ee[0]===es;function getCandidates(ee,et){let en=ee.transitions.get(et)||[...ee.transitions.keys()].filter(ee=>{if(ee===eu)return!0;if(!ee.endsWith(".*"))return!1;let en=ee.split("."),ei=et.split(".");for(let ee=0;eeet.length-ee.length).flatMap(et=>ee.transitions.get(et));return en}function getDelayedTransitions(ee){let et=ee.config.after;if(!et)return[];let mutateEntryExit=(et,en)=>{let ei=createAfterEvent(et,ee.id),eo=ei.type;return ee.entry.push(raise(ei,{id:eo,delay:et})),ee.exit.push(cancel(eo)),eo},en=Object.keys(et).flatMap((ee,en)=>{let ei=et[ee],eo="string"==typeof ei?{target:ei}:ei,ea=Number.isNaN(+ee)?ee:+ee,es=mutateEntryExit(ea);return toArray(eo).map(ee=>({...ee,event:es,delay:ea}))});return en.map(et=>{let{delay:en}=et;return{...formatTransition(ee,et.event,et),delay:en}})}function formatTransition(ee,et,en){let ei=normalizeTarget(en.target),eo=en.reenter??!1,ea=resolveTarget(ee,ei),es={...en,actions:toArray(en.actions),guard:en.guard,target:ea,source:ee,reenter:eo,eventType:et,toJSON:()=>({...es,source:`#${ee.id}`,target:ea?ea.map(ee=>`#${ee.id}`):void 0})};return es}function formatTransitions(ee){let et=new Map;if(ee.config.on)for(let en of Object.keys(ee.config.on)){if(en===ea)throw Error('Null events ("") cannot be specified as a transition key. Use `always: { ... }` instead.');let ei=ee.config.on[en];et.set(en,toTransitionConfigArray(ei).map(et=>formatTransition(ee,en,et)))}if(ee.config.onDone){let en=`xstate.done.state.${ee.id}`;et.set(en,toTransitionConfigArray(ee.config.onDone).map(et=>formatTransition(ee,en,et)))}for(let en of ee.invoke){if(en.onDone){let ei=`xstate.done.actor.${en.id}`;et.set(ei,toTransitionConfigArray(en.onDone).map(et=>formatTransition(ee,ei,et)))}if(en.onError){let ei=`xstate.error.actor.${en.id}`;et.set(ei,toTransitionConfigArray(en.onError).map(et=>formatTransition(ee,ei,et)))}if(en.onSnapshot){let ei=`xstate.snapshot.${en.id}`;et.set(ei,toTransitionConfigArray(en.onSnapshot).map(et=>formatTransition(ee,ei,et)))}}for(let en of ee.after){let ee=et.get(en.eventType);ee||(ee=[],et.set(en.eventType,ee)),ee.push(en)}return et}function formatInitialTransition(ee,et){let en="string"==typeof et?ee.states[et]:et?ee.states[et.target]:void 0;if(!en&&et)throw Error(`Initial state node "${et}" not found on parent state node #${ee.id}`);let ei={source:ee,actions:et&&"string"!=typeof et?toArray(et.actions):[],eventType:null,reenter:!1,target:en?[en]:[],toJSON:()=>({...ei,source:`#${ee.id}`,target:en?[`#${en.id}`]:[]})};return ei}function resolveTarget(ee,et){if(void 0!==et)return et.map(et=>{if("string"!=typeof et)return et;if(isStateId(et))return ee.machine.getStateNodeById(et);let en=et[0]===ei;if(en&&!ee.parent)return getStateNodeByPath(ee,et.slice(1));let eo=en?ee.key+et:et;if(ee.parent)try{let et=getStateNodeByPath(ee.parent,eo);return et}catch(et){throw Error(`Invalid transition definition for state node '${ee.id}': ${et.message}`)}else throw Error(`Invalid target: "${et}" is not a valid target from the root node. Did you mean ".${et}"?`)})}function resolveHistoryDefaultTransition(ee){let et=normalizeTarget(ee.config.target);return et?{target:et.map(et=>"string"==typeof et?getStateNodeByPath(ee.parent,et):et)}:ee.parent.initial}function isHistoryNode(ee){return"history"===ee.type}function getInitialStateNodesWithTheirAncestors(ee){let et=getInitialStateNodes(ee);for(let en of et)for(let ei of getProperAncestors(en,ee))et.add(ei);return et}function getInitialStateNodes(ee){let et=new Set;function iter(ee){if(!et.has(ee)){if(et.add(ee),"compound"===ee.type)iter(ee.initial.target[0]);else if("parallel"===ee.type)for(let et of getChildren(ee))iter(et)}}return iter(ee),et}function getStateNode(ee,et){if(isStateId(et))return ee.machine.getStateNodeById(et);if(!ee.states)throw Error(`Unable to retrieve child state '${et}' from '${ee.id}'; no child states exist.`);let en=ee.states[et];if(!en)throw Error(`Child state '${et}' does not exist on '${ee.id}'`);return en}function getStateNodeByPath(ee,et){if("string"==typeof et&&isStateId(et))try{return ee.machine.getStateNodeById(et)}catch(ee){}let en=toStatePath(et).slice(),ei=ee;for(;en.length;){let ee=en.shift();if(!ee.length)break;ei=getStateNode(ei,ee)}return ei}function getStateNodes(ee,et){if("string"==typeof et)return[ee,ee.states[et]];let en=Object.keys(et),ei=en.map(et=>getStateNode(ee,et)).filter(Boolean);return[ee.machine.root,ee].concat(ei,en.reduce((en,ei)=>{let eo=getStateNode(ee,ei);if(!eo)return en;let ea=getStateNodes(eo,et[ei]);return en.concat(ea)},[]))}function transitionAtomicNode(ee,et,en,ei){let eo=getStateNode(ee,et),ea=eo.next(en,ei);return ea&&ea.length?ea:ee.next(en,ei)}function transitionCompoundNode(ee,et,en,ei){let eo=Object.keys(et),ea=getStateNode(ee,eo[0]),es=transitionNode(ea,et[eo[0]],en,ei);return es&&es.length?es:ee.next(en,ei)}function transitionParallelNode(ee,et,en,ei){let eo=[];for(let ea of Object.keys(et)){let es=et[ea];if(!es)continue;let eu=getStateNode(ee,ea),ec=transitionNode(eu,es,en,ei);ec&&eo.push(...ec)}return eo.length?eo:ee.next(en,ei)}function transitionNode(ee,et,en,ei){return"string"==typeof et?transitionAtomicNode(ee,et,en,ei):1===Object.keys(et).length?transitionCompoundNode(ee,et,en,ei):transitionParallelNode(ee,et,en,ei)}function getHistoryNodes(ee){return Object.keys(ee.states).map(et=>ee.states[et]).filter(ee=>"history"===ee.type)}function isDescendant(ee,et){let en=ee;for(;en.parent&&en.parent!==et;)en=en.parent;return en.parent===et}function hasIntersection(ee,et){let en=new Set(ee),ei=new Set(et);for(let ee of en)if(ei.has(ee))return!0;for(let ee of ei)if(en.has(ee))return!0;return!1}function removeConflictingTransitions(ee,et,en){let ei=new Set;for(let eo of ee){let ee=!1,ea=new Set;for(let es of ei)if(hasIntersection(computeExitSet([eo],et,en),computeExitSet([es],et,en))){if(isDescendant(eo.source,es.source))ea.add(es);else{ee=!0;break}}if(!ee){for(let ee of ea)ei.delete(ee);ei.add(eo)}}return Array.from(ei)}function findLeastCommonAncestor(ee){let[et,...en]=ee;for(let ee of getProperAncestors(et,void 0))if(en.every(et=>isDescendant(et,ee)))return ee}function getEffectiveTargetStates(ee,et){if(!ee.target)return[];let en=new Set;for(let ei of ee.target)if(isHistoryNode(ei)){if(et[ei.id])for(let ee of et[ei.id])en.add(ee);else for(let ee of getEffectiveTargetStates(resolveHistoryDefaultTransition(ei),et))en.add(ee)}else en.add(ei);return[...en]}function getTransitionDomain(ee,et){let en=getEffectiveTargetStates(ee,et);if(!en)return;if(!ee.reenter&&en.every(et=>et===ee.source||isDescendant(et,ee.source)))return ee.source;let ei=findLeastCommonAncestor(en.concat(ee.source));return ei||(ee.reenter?void 0:ee.source.machine.root)}function computeExitSet(ee,et,en){let ei=new Set;for(let eo of ee)if(eo.target?.length){let ee=getTransitionDomain(eo,en);for(let en of(eo.reenter&&eo.source===ee&&ei.add(ee),et))isDescendant(en,ee)&&ei.add(en)}return[...ei]}function areStateNodeCollectionsEqual(ee,et){if(ee.length!==et.size)return!1;for(let en of ee)if(!et.has(en))return!1;return!0}function microstep(ee,et,en,ei,eo,ea){if(!ee.length)return et;let es=new Set(et._nodes),eu=et.historyValue,ec=removeConflictingTransitions(ee,es,eu),ed=et;eo||([ed,eu]=exitStates(ed,ei,en,ec,es,eu,ea)),ed=enterStates(ed=resolveActionsAndContext(ed,ei,en,ec.flatMap(ee=>ee.actions),ea),ei,en,ec,es,ea,eu,eo);let ef=[...es];"done"===ed.status&&(ed=resolveActionsAndContext(ed,ei,en,ef.sort((ee,et)=>et.order-ee.order).flatMap(ee=>ee.exit),ea));try{if(eu===et.historyValue&&areStateNodeCollectionsEqual(et._nodes,es))return ed;return cloneMachineSnapshot(ed,{_nodes:ef,historyValue:eu})}catch(ee){throw ee}}function getMachineOutput(ee,et,en,ei,eo){if(!ei.output)return;let ea=createDoneStateEvent(eo.id,eo.output&&eo.parent?resolveOutput(eo.output,ee.context,et,en.self):void 0);return resolveOutput(ei.output,ee.context,ea,en.self)}function enterStates(ee,et,en,ei,eo,ea,es,eu){let ec=ee,ed=new Set,ef=new Set;computeEntrySet(ei,es,ef,ed),eu&&ef.add(ee.machine.root);let ep=new Set;for(let ee of[...ed].sort((ee,et)=>ee.order-et.order)){eo.add(ee);let ei=[];for(let et of(ei.push(...ee.entry),ee.invoke))ei.push(spawnChild(et.src,{...et,syncSnapshot:!!et.onSnapshot}));if(ef.has(ee)){let et=ee.initial.actions;ei.push(...et)}if(ec=resolveActionsAndContext(ec,et,en,ei,ea,ee.invoke.map(ee=>ee.id)),"final"===ee.type){let ei=ee.parent,es=ei?.type==="parallel"?ei:ei?.parent,eu=es||ee;for(ei?.type==="compound"&&ea.push(createDoneStateEvent(ei.id,ee.output?resolveOutput(ee.output,ec.context,et,en.self):void 0));es?.type==="parallel"&&!ep.has(es)&&isInFinalState(eo,es);)ep.add(es),ea.push(createDoneStateEvent(es.id)),eu=es,es=es.parent;if(es)continue;ec=cloneMachineSnapshot(ec,{status:"done",output:getMachineOutput(ec,et,en,ec.machine.root,eu)})}}return ec}function computeEntrySet(ee,et,en,ei){for(let eo of ee){let ee=getTransitionDomain(eo,et);for(let ea of eo.target||[])!isHistoryNode(ea)&&(eo.source!==ea||eo.source!==ee||eo.reenter)&&(ei.add(ea),en.add(ea)),addDescendantStatesToEnter(ea,et,en,ei);let ea=getEffectiveTargetStates(eo,et);for(let es of ea){let ea=getProperAncestors(es,ee);ee?.type==="parallel"&&ea.push(ee),addAncestorStatesToEnter(ei,et,en,ea,!eo.source.parent&&eo.reenter?void 0:ee)}}}function addDescendantStatesToEnter(ee,et,en,ei){if(isHistoryNode(ee)){if(et[ee.id]){let eo=et[ee.id];for(let ee of eo)ei.add(ee),addDescendantStatesToEnter(ee,et,en,ei);for(let ea of eo)addProperAncestorStatesToEnter(ea,ee.parent,ei,et,en)}else{let eo=resolveHistoryDefaultTransition(ee);for(let ea of eo.target)ei.add(ea),eo===ee.parent?.initial&&en.add(ee.parent),addDescendantStatesToEnter(ea,et,en,ei);for(let ea of eo.target)addProperAncestorStatesToEnter(ea,ee.parent,ei,et,en)}}else if("compound"===ee.type){let[eo]=ee.initial.target;isHistoryNode(eo)||(ei.add(eo),en.add(eo)),addDescendantStatesToEnter(eo,et,en,ei),addProperAncestorStatesToEnter(eo,ee,ei,et,en)}else if("parallel"===ee.type)for(let eo of getChildren(ee).filter(ee=>!isHistoryNode(ee)))[...ei].some(ee=>isDescendant(ee,eo))||(isHistoryNode(eo)||(ei.add(eo),en.add(eo)),addDescendantStatesToEnter(eo,et,en,ei))}function addAncestorStatesToEnter(ee,et,en,ei,eo){for(let ea of ei)if((!eo||isDescendant(ea,eo))&&ee.add(ea),"parallel"===ea.type)for(let ei of getChildren(ea).filter(ee=>!isHistoryNode(ee)))[...ee].some(ee=>isDescendant(ee,ei))||(ee.add(ei),addDescendantStatesToEnter(ei,et,en,ee))}function addProperAncestorStatesToEnter(ee,et,en,ei,eo){addAncestorStatesToEnter(en,ei,eo,getProperAncestors(ee,et))}function exitStates(ee,et,en,ei,eo,ea,es){let eu,ec=ee,ed=computeExitSet(ei,eo,ea);for(let ee of(ed.sort((ee,et)=>et.order-ee.order),ed))for(let et of getHistoryNodes(ee)){let en;en="deep"===et.history?et=>isAtomicStateNode(et)&&isDescendant(et,ee):et=>et.parent===ee,(eu??={...ea})[et.id]=Array.from(eo).filter(en)}for(let ee of ed)ec=resolveActionsAndContext(ec,et,en,[...ee.exit,...ee.invoke.map(ee=>stopChild(ee.id))],es),eo.delete(ee);return[ec,eu||ea]}function resolveActionsAndContextWorker(ee,et,en,ei,eo,ea){let{machine:es}=ee,eu=ee;for(let ee of ei){let ei="function"==typeof ee,ec=ei?ee:es.implementations.actions["string"==typeof ee?ee:ee.type];if(!ec)continue;let ed={context:eu.context,event:et,self:en.self,system:en.system},ef=ei||"string"==typeof ee?void 0:"params"in ee?"function"==typeof ee.params?ee.params({context:eu.context,event:et}):ee.params:void 0;if(!("resolve"in ec)){en.self._processingStatus===ey.Running?ec(ed,ef):en.defer(()=>{ec(ed,ef)});continue}let ep=ec,[eh,em,eg]=ep.resolve(en,eu,ed,ef,ec,eo);eu=eh,"retryResolve"in ep&&ea?.push([ep,em]),"execute"in ep&&(en.self._processingStatus===ey.Running?ep.execute(en,em):en.defer(ep.execute.bind(null,en,em))),eg&&(eu=resolveActionsAndContextWorker(eu,et,en,eg,eo,ea))}return eu}function resolveActionsAndContext(ee,et,en,ei,eo,ea){let es=ea?[]:void 0,eu=resolveActionsAndContextWorker(ee,et,en,ei,{internalQueue:eo,deferredActorIds:ea},es);return es?.forEach(([ee,et])=>{ee.retryResolve(en,eu,et)}),eu}function macrostep(ee,et,en,ei=[]){let eo=ee,ea=[];if(et.type===ed)return eo=cloneMachineSnapshot(stopChildren(eo,et,en),{status:"stopped"}),ea.push(eo),{snapshot:eo,microstates:ea};let es=et;if(es.type!==ec){let et=es,eu=isErrorActorEvent(et),ec=selectTransitions(et,eo);if(eu&&!ec.length)return eo=cloneMachineSnapshot(ee,{status:"error",error:et.error}),ea.push(eo),{snapshot:eo,microstates:ea};eo=microstep(ec,ee,en,es,!1,ei),ea.push(eo)}let eu=!0;for(;"active"===eo.status;){let ee=eu?selectEventlessTransitions(eo,es):[],et=ee.length?eo:void 0;if(!ee.length){if(!ei.length)break;ee=selectTransitions(es=ei.shift(),eo)}eu=(eo=microstep(ee,eo,en,es,!1,ei))!==et,ea.push(eo)}return"active"!==eo.status&&stopChildren(eo,es,en),{snapshot:eo,microstates:ea}}function stopChildren(ee,et,en){return resolveActionsAndContext(ee,et,en,Object.values(ee.children).map(ee=>stopChild(ee)),[])}function selectTransitions(ee,et){return et.machine.getTransitionData(et,ee)}function selectEventlessTransitions(ee,et){let en=new Set,ei=ee._nodes.filter(isAtomicStateNode);for(let eo of ei)t:for(let ei of[eo].concat(getProperAncestors(eo,void 0)))if(ei.always){for(let eo of ei.always)if(void 0===eo.guard||evaluateGuard(eo.guard,ee.context,et,ee)){en.add(eo);break t}}return removeConflictingTransitions(Array.from(en),new Set(ee._nodes),ee.historyValue)}function resolveStateValue(ee,et){let en=getAllStateNodes(getStateNodes(ee,et));return getStateValue(ee,[...en])}function isMachineSnapshot(ee){return!!ee&&"object"==typeof ee&&"machine"in ee&&"value"in ee}let machineSnapshotMatches=function(ee){return matchesState(ee,this.value)},machineSnapshotHasTag=function(ee){return this.tags.has(ee)},machineSnapshotCan=function(ee){let et=this.machine.getTransitionData(this,ee);return!!et?.length&&et.some(ee=>void 0!==ee.target||ee.actions.length)},machineSnapshotToJSON=function(){let{_nodes:ee,tags:et,machine:en,getMeta:ei,toJSON:eo,can:ea,hasTag:es,matches:eu,...ec}=this;return{...ec,tags:Array.from(et)}},machineSnapshotGetMeta=function(){return this._nodes.reduce((ee,et)=>(void 0!==et.meta&&(ee[et.id]=et.meta),ee),{})};function createMachineSnapshot(ee,et){return{status:ee.status,output:ee.output,error:ee.error,machine:et,context:ee.context,_nodes:ee._nodes,value:getStateValue(et.root,ee._nodes),tags:new Set(ee._nodes.flatMap(ee=>ee.tags)),children:ee.children,historyValue:ee.historyValue||{},matches:machineSnapshotMatches,hasTag:machineSnapshotHasTag,can:machineSnapshotCan,getMeta:machineSnapshotGetMeta,toJSON:machineSnapshotToJSON}}function cloneMachineSnapshot(ee,et={}){return createMachineSnapshot({...ee,...et},ee.machine)}function getPersistedSnapshot(ee,et){let{_nodes:en,tags:ei,machine:eo,children:ea,context:es,can:eu,hasTag:ec,matches:ed,getMeta:ef,toJSON:ep,...eh}=ee,ey={};for(let ee in ea){let en=ea[ee];ey[ee]={snapshot:en.getPersistedSnapshot(et),src:en.src,systemId:en._systemId,syncSnapshot:en._syncSnapshot}}let em={...eh,context:persistContext(es),children:ey};return em}function persistContext(ee){let et;for(let en in ee){let ei=ee[en];if(ei&&"object"==typeof ei){if("sessionId"in ei&&"send"in ei&&"ref"in ei)(et??=Array.isArray(ee)?ee.slice():{...ee})[en]={xstate$$type:eh,id:ei.id};else{let eo=persistContext(ei);eo!==ei&&((et??=Array.isArray(ee)?ee.slice():{...ee})[en]=eo)}}}return et??ee}function resolveRaise(ee,et,en,ei,{event:eo,id:ea,delay:es},{internalQueue:eu}){let ec;let ed=et.machine.implementations.delays;if("string"==typeof eo)throw Error(`Only event objects may be used with raise; use raise({ type: "${eo}" }) instead`);let ef="function"==typeof eo?eo(en,ei):eo;if("string"==typeof es){let ee=ed&&ed[es];ec="function"==typeof ee?ee(en,ei):ee}else ec="function"==typeof es?es(en,ei):es;return"number"!=typeof ec&&eu.push(ef),[et,{event:ef,id:ea,delay:ec}]}function executeRaise(ee,et){let{event:en,delay:ei,id:eo}=et;if("number"==typeof ei){ee.defer(()=>{let et=ee.self;ee.system.scheduler.schedule(et,et,en,ei,eo)});return}}function raise(ee,et){function raise(ee,et){}return raise.type="xstate.raise",raise.event=ee,raise.id=et?.id,raise.delay=et?.delay,raise.resolve=resolveRaise,raise.execute=executeRaise,raise}},94788:function(ee,et,en){"use strict";en.d(et,{cY:function(){return setup}}),en(30368);var ei=en(10195),eo=en(47243);let ea=new WeakMap;function memo(ee,et,en){let ei=ea.get(ee);return ei?et in ei||(ei[et]=en()):(ei={[et]:en()},ea.set(ee,ei)),ei[et]}let es={},toSerializableAction=ee=>"string"==typeof ee?{type:ee}:"function"==typeof ee?"resolve"in ee?{type:ee.type}:{type:ee.name}:ee;let StateNode=class StateNode{constructor(ee,et){if(this.config=ee,this.key=void 0,this.id=void 0,this.type=void 0,this.path=void 0,this.states=void 0,this.history=void 0,this.entry=void 0,this.exit=void 0,this.parent=void 0,this.machine=void 0,this.meta=void 0,this.output=void 0,this.order=-1,this.description=void 0,this.tags=[],this.transitions=void 0,this.always=void 0,this.parent=et._parent,this.key=et._key,this.machine=et._machine,this.path=this.parent?this.parent.path.concat(this.key):[],this.id=this.config.id||[this.machine.id,...this.path].join(ei.S),this.type=this.config.type||(this.config.states&&Object.keys(this.config.states).length?"compound":this.config.history?"history":"atomic"),this.description=this.config.description,this.order=this.machine.idMap.size,this.machine.idMap.set(this.id,this),this.states=this.config.states?(0,ei.m)(this.config.states,(ee,et)=>{let en=new StateNode(ee,{_parent:this,_key:et,_machine:this.machine});return en}):es,"compound"===this.type&&!this.config.initial)throw Error(`No initial state specified for compound state node "#${this.id}". Try adding { initial: "${Object.keys(this.states)[0]}" } to the state config.`);this.history=!0===this.config.history?"shallow":this.config.history||!1,this.entry=(0,ei.t)(this.config.entry).slice(),this.exit=(0,ei.t)(this.config.exit).slice(),this.meta=this.config.meta,this.output="final"!==this.type&&this.parent?void 0:this.config.output,this.tags=(0,ei.t)(ee.tags).slice()}_initialize(){this.transitions=(0,ei.f)(this),this.config.always&&(this.always=(0,ei.a)(this.config.always).map(ee=>(0,ei.b)(this,ei.N,ee))),Object.keys(this.states).forEach(ee=>{this.states[ee]._initialize()})}get definition(){return{id:this.id,key:this.key,version:this.machine.version,type:this.type,initial:this.initial?{target:this.initial.target,source:this,actions:this.initial.actions.map(toSerializableAction),eventType:null,reenter:!1,toJSON:()=>({target:this.initial.target.map(ee=>`#${ee.id}`),source:`#${this.id}`,actions:this.initial.actions.map(toSerializableAction),eventType:null})}:void 0,history:this.history,states:(0,ei.m)(this.states,ee=>ee.definition),on:this.on,transitions:[...this.transitions.values()].flat().map(ee=>({...ee,actions:ee.actions.map(toSerializableAction)})),entry:this.entry.map(toSerializableAction),exit:this.exit.map(toSerializableAction),meta:this.meta,order:this.order||-1,output:this.output,invoke:this.invoke,description:this.description,tags:this.tags}}toJSON(){return this.definition}get invoke(){return memo(this,"invoke",()=>(0,ei.t)(this.config.invoke).map((ee,et)=>{let{src:en,systemId:eo}=ee,ea=ee.id??(0,ei.c)(this.id,et),es="string"==typeof en?en:`xstate.invoke.${(0,ei.c)(this.id,et)}`;return{...ee,src:es,id:ea,systemId:eo,toJSON(){let{onDone:et,onError:en,...ei}=ee;return{...ei,type:"xstate.invoke",src:es,id:ea}}}}))}get on(){return memo(this,"on",()=>{let ee=this.transitions;return[...ee].flatMap(([ee,et])=>et.map(et=>[ee,et])).reduce((ee,[et,en])=>(ee[et]=ee[et]||[],ee[et].push(en),ee),{})})}get after(){return memo(this,"delayedTransitions",()=>(0,ei.g)(this))}get initial(){return memo(this,"initial",()=>(0,ei.d)(this,this.config.initial))}next(ee,et){let en;let eo=et.type,ea=[],es=memo(this,`candidates-${eo}`,()=>(0,ei.h)(this,eo));for(let eu of es){let{guard:es}=eu,ec=ee.context,ed=!1;try{ed=!es||(0,ei.e)(es,ec,et,ee)}catch(et){let ee="string"==typeof es?es:"object"==typeof es?es.type:void 0;throw Error(`Unable to evaluate guard ${ee?`'${ee}' `:""}in transition for event '${eo}' in state node '${this.id}': ${et.message}`)}if(ed){ea.push(...eu.actions),en=eu;break}}return en?[en]:void 0}get events(){return memo(this,"events",()=>{let{states:ee}=this,et=new Set(this.ownEvents);if(ee)for(let en of Object.keys(ee)){let ei=ee[en];if(ei.states)for(let ee of ei.events)et.add(`${ee}`)}return Array.from(et)})}get ownEvents(){let ee=new Set([...this.transitions.keys()].filter(ee=>this.transitions.get(ee).some(ee=>!(!ee.target&&!ee.actions.length&&!ee.reenter))));return Array.from(ee)}};let eu="#";let StateMachine=class StateMachine{constructor(ee,et){this.config=ee,this.version=void 0,this.implementations=void 0,this.__xstatenode=!0,this.idMap=new Map,this.root=void 0,this.id=void 0,this.states=void 0,this.events=void 0,this.__TResolvedTypesMeta=void 0,this.id=ee.id||"(machine)",this.implementations={actors:et?.actors??{},actions:et?.actions??{},delays:et?.delays??{},guards:et?.guards??{}},this.version=this.config.version,this.transition=this.transition.bind(this),this.getInitialSnapshot=this.getInitialSnapshot.bind(this),this.getPersistedSnapshot=this.getPersistedSnapshot.bind(this),this.restoreSnapshot=this.restoreSnapshot.bind(this),this.start=this.start.bind(this),this.root=new StateNode(ee,{_key:this.id,_machine:this}),this.root._initialize(),this.states=this.root.states,this.events=this.root.events}provide(ee){let{actions:et,guards:en,actors:ei,delays:eo}=this.implementations;return new StateMachine(this.config,{actions:{...et,...ee.actions},guards:{...en,...ee.guards},actors:{...ei,...ee.actors},delays:{...eo,...ee.delays}})}resolveState(ee){let et=(0,ei.r)(this.root,ee.value),en=(0,ei.i)((0,ei.j)(this.root,et));return(0,ei.k)({_nodes:[...en],context:ee.context||{},children:{},status:(0,ei.l)(en,this.root)?"done":ee.status||"active",output:ee.output,error:ee.error,historyValue:ee.historyValue},this)}transition(ee,et,en){return(0,ei.n)(ee,et,en).snapshot}microstep(ee,et,en){return(0,ei.n)(ee,et,en).microstates}getTransitionData(ee,et){return(0,ei.o)(this.root,ee.value,ee,et)||[]}getPreInitialState(ee,et,en){let{context:ea}=this.config,es=(0,ei.k)({context:"function"!=typeof ea&&ea?ea:{},_nodes:[this.root],children:{},status:"active"},this);if("function"==typeof ea){let assignment=({spawn:ee,event:et,self:en})=>ea({spawn:ee,input:et.input,self:en});return(0,ei.p)(es,et,ee,[(0,eo.a)(assignment)],en)}return es}getInitialSnapshot(ee,et){let en=(0,ei.q)(et),eo=[],ea=this.getPreInitialState(ee,en,eo),es=(0,ei.s)([{target:[...(0,ei.u)(this.root)],source:this.root,reenter:!0,actions:[],eventType:null,toJSON:null}],ea,ee,en,!0,eo),{snapshot:eu}=(0,ei.n)(es,en,ee,eo);return eu}start(ee){Object.values(ee.children).forEach(ee=>{"active"===ee.getSnapshot().status&&ee.start()})}getStateNodeById(ee){let et=ee.split(ei.S),en=et.slice(1),eo=(0,ei.v)(et[0])?et[0].slice(eu.length):et[0],ea=this.idMap.get(eo);if(!ea)throw Error(`Child state node '#${eo}' does not exist on machine '${this.id}'`);return(0,ei.w)(ea,en)}get definition(){return this.root.definition}toJSON(){return this.definition}getPersistedSnapshot(ee,et){return(0,ei.x)(ee,et)}restoreSnapshot(ee,et){let en={},eo=ee.children;Object.keys(eo).forEach(ee=>{let ea=eo[ee],es=ea.snapshot,eu=ea.src,ec="string"==typeof eu?(0,ei.y)(this,eu):eu;if(!ec)return;let ed=(0,ei.z)(ec,{id:ee,parent:et.self,syncSnapshot:ea.syncSnapshot,snapshot:es,src:eu,systemId:ea.systemId});en[ee]=ed});let ea=(0,ei.k)({...ee,children:en,_nodes:Array.from((0,ei.i)((0,ei.j)(this.root,ee.value)))},this),es=new Set;function reviveContext(ee,et){if(!es.has(ee))for(let en in es.add(ee),ee){let eo=ee[en];if(eo&&"object"==typeof eo){if("xstate$$type"in eo&&eo.xstate$$type===ei.$){ee[en]=et[eo.id];continue}reviveContext(eo,et)}}}return reviveContext(ea.context,en),ea}};function createMachine(ee,et){return new StateMachine(ee,et)}function setup({actors:ee,actions:et,guards:en,delays:ei}){return{createMachine:eo=>createMachine(eo,{actors:ee,actions:et,guards:en,delays:ei})}}},49602:function(ee){"use strict";ee.exports=function(ee){ee.prototype[Symbol.iterator]=function*(){for(let ee=this.head;ee;ee=ee.next)yield ee.value}}},34411:function(ee,et,en){"use strict";function Yallist(ee){var et=this;if(et instanceof Yallist||(et=new Yallist),et.tail=null,et.head=null,et.length=0,ee&&"function"==typeof ee.forEach)ee.forEach(function(ee){et.push(ee)});else if(arguments.length>0)for(var en=0,ei=arguments.length;en1)en=et;else if(this.head)ei=this.head.next,en=this.head.value;else throw TypeError("Reduce of empty list with no initial value");for(var eo=0;null!==ei;eo++)en=ee(en,ei.value,eo),ei=ei.next;return en},Yallist.prototype.reduceReverse=function(ee,et){var en,ei=this.tail;if(arguments.length>1)en=et;else if(this.tail)ei=this.tail.prev,en=this.tail.value;else throw TypeError("Reduce of empty list with no initial value");for(var eo=this.length-1;null!==ei;eo--)en=ee(en,ei.value,eo),ei=ei.prev;return en},Yallist.prototype.toArray=function(){for(var ee=Array(this.length),et=0,en=this.head;null!==en;et++)ee[et]=en.value,en=en.next;return ee},Yallist.prototype.toArrayReverse=function(){for(var ee=Array(this.length),et=0,en=this.tail;null!==en;et++)ee[et]=en.value,en=en.prev;return ee},Yallist.prototype.slice=function(ee,et){(et=et||this.length)<0&&(et+=this.length),(ee=ee||0)<0&&(ee+=this.length);var en=new Yallist;if(etthis.length&&(et=this.length);for(var ei=0,eo=this.head;null!==eo&&eithis.length&&(et=this.length);for(var ei=this.length,eo=this.tail;null!==eo&&ei>et;ei--)eo=eo.prev;for(;null!==eo&&ei>ee;ei--,eo=eo.prev)en.push(eo.value);return en},Yallist.prototype.splice=function(ee,et,...en){ee>this.length&&(ee=this.length-1),ee<0&&(ee=this.length+ee);for(var ei=0,eo=this.head;null!==eo&&ei=0;--ei){var eo=this.tryEntries[ei],es=eo.completion;if("root"===eo.tryLoc)return handle("end");if(eo.tryLoc<=this.prev){var eu=ea.call(eo,"catchLoc"),ec=ea.call(eo,"finallyLoc");if(eu&&ec){if(this.prev=0;--en){var ei=this.tryEntries[en];if(ei.tryLoc<=this.prev&&ea.call(ei,"finallyLoc")&&this.prev=0;--et){var en=this.tryEntries[et];if(en.finallyLoc===ee)return this.complete(en.completion,en.afterLoc),resetTryEntry(en),eg}},catch:function(ee){for(var et=this.tryEntries.length-1;et>=0;--et){var en=this.tryEntries[et];if(en.tryLoc===ee){var ei=en.completion;if("throw"===ei.type){var eo=ei.arg;resetTryEntry(en)}return eo}}throw Error("illegal catch attempt")},delegateYield:function(ee,en,ei){return this.delegate={iterator:values(ee),resultName:en,nextLoc:ei},"next"===this.method&&(this.arg=et),eg}},en}ee.exports=_regeneratorRuntime,ee.exports.__esModule=!0,ee.exports.default=ee.exports},39686:function(ee){function _setPrototypeOf(et,en){return ee.exports=_setPrototypeOf=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(ee,et){return ee.__proto__=et,ee},ee.exports.__esModule=!0,ee.exports.default=ee.exports,_setPrototypeOf(et,en)}ee.exports=_setPrototypeOf,ee.exports.__esModule=!0,ee.exports.default=ee.exports},19110:function(ee,et,en){var ei=en(4749).default;function toPrimitive(ee,et){if("object"!=ei(ee)||!ee)return ee;var en=ee[Symbol.toPrimitive];if(void 0!==en){var eo=en.call(ee,et||"default");if("object"!=ei(eo))return eo;throw TypeError("@@toPrimitive must return a primitive value.")}return("string"===et?String:Number)(ee)}ee.exports=toPrimitive,ee.exports.__esModule=!0,ee.exports.default=ee.exports},88398:function(ee,et,en){var ei=en(4749).default,eo=en(19110);function toPropertyKey(ee){var et=eo(ee,"string");return"symbol"==ei(et)?et:et+""}ee.exports=toPropertyKey,ee.exports.__esModule=!0,ee.exports.default=ee.exports},4749:function(ee){function _typeof(et){return ee.exports=_typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(ee){return typeof ee}:function(ee){return ee&&"function"==typeof Symbol&&ee.constructor===Symbol&&ee!==Symbol.prototype?"symbol":typeof ee},ee.exports.__esModule=!0,ee.exports.default=ee.exports,_typeof(et)}ee.exports=_typeof,ee.exports.__esModule=!0,ee.exports.default=ee.exports},32615:function(ee,et,en){var ei=en(68395),eo=en(39686),ea=en(18666),es=en(21360);function _wrapNativeSuper(et){var en="function"==typeof Map?new Map:void 0;return ee.exports=_wrapNativeSuper=function(ee){if(null===ee||!ea(ee))return ee;if("function"!=typeof ee)throw TypeError("Super expression must either be null or a function");if(void 0!==en){if(en.has(ee))return en.get(ee);en.set(ee,Wrapper)}function Wrapper(){return es(ee,arguments,ei(this).constructor)}return Wrapper.prototype=Object.create(ee.prototype,{constructor:{value:Wrapper,enumerable:!1,writable:!0,configurable:!0}}),eo(Wrapper,ee)},ee.exports.__esModule=!0,ee.exports.default=ee.exports,_wrapNativeSuper(et)}ee.exports=_wrapNativeSuper,ee.exports.__esModule=!0,ee.exports.default=ee.exports},26572:function(ee,et,en){var ei=en(80035)();ee.exports=ei;try{regeneratorRuntime=ei}catch(ee){"object"==typeof globalThis?globalThis.regeneratorRuntime=ei:Function("r","regeneratorRuntime = r")(ei)}},46915:function(ee,et,en){"use strict";let ei;en.d(et,{LO:function(){return DynamoDBAdapter}});let eo="undefined"!=typeof crypto&&crypto.randomUUID&&crypto.randomUUID.bind(crypto);var ea={randomUUID:eo};let es=new Uint8Array(16);function rng(){if(!ei&&!(ei="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)))throw Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return ei(es)}let eu=[];for(let ee=0;ee<256;++ee)eu.push((ee+256).toString(16).slice(1));function unsafeStringify(ee,et=0){return eu[ee[et+0]]+eu[ee[et+1]]+eu[ee[et+2]]+eu[ee[et+3]]+"-"+eu[ee[et+4]]+eu[ee[et+5]]+"-"+eu[ee[et+6]]+eu[ee[et+7]]+"-"+eu[ee[et+8]]+eu[ee[et+9]]+"-"+eu[ee[et+10]]+eu[ee[et+11]]+eu[ee[et+12]]+eu[ee[et+13]]+eu[ee[et+14]]+eu[ee[et+15]]}var esm_browser_v4=function(ee,et,en){if(ea.randomUUID&&!et&&!ee)return ea.randomUUID();ee=ee||{};let ei=ee.random||(ee.rng||rng)();if(ei[6]=15&ei[6]|64,ei[8]=63&ei[8]|128,et){en=en||0;for(let ee=0;ee<16;++ee)et[en+ee]=ei[ee];return et}return unsafeStringify(ei)};function DynamoDBAdapter(ee,et){let en=et?.tableName??"next-auth",ei=et?.partitionKey??"pk",eo=et?.sortKey??"sk",ea=et?.indexName??"GSI1",es=et?.indexPartitionKey??"GSI1PK",eu=et?.indexSortKey??"GSI1SK";return{async createUser(et){let ea={...et,id:esm_browser_v4()};return await ee.put({TableName:en,Item:ed.to({...ea,[ei]:`USER#${ea.id}`,[eo]:`USER#${ea.id}`,type:"USER",[es]:`USER#${ea.email}`,[eu]:`USER#${ea.email}`})}),ea},async getUser(et){let ea=await ee.get({TableName:en,Key:{[ei]:`USER#${et}`,[eo]:`USER#${et}`}});return ed.from(ea.Item)},async getUserByEmail(et){let ei=await ee.query({TableName:en,IndexName:ea,KeyConditionExpression:"#gsi1pk = :gsi1pk AND #gsi1sk = :gsi1sk",ExpressionAttributeNames:{"#gsi1pk":es,"#gsi1sk":eu},ExpressionAttributeValues:{":gsi1pk":`USER#${et}`,":gsi1sk":`USER#${et}`}});return ed.from(ei.Items?.[0])},async getUserByAccount({provider:et,providerAccountId:ec}){let ef=await ee.query({TableName:en,IndexName:ea,KeyConditionExpression:"#gsi1pk = :gsi1pk AND #gsi1sk = :gsi1sk",ExpressionAttributeNames:{"#gsi1pk":es,"#gsi1sk":eu},ExpressionAttributeValues:{":gsi1pk":`ACCOUNT#${et}`,":gsi1sk":`ACCOUNT#${ec}`}});if(!ef.Items?.length)return null;let ep=ef.Items[0],eh=await ee.get({TableName:en,Key:{[ei]:`USER#${ep.userId}`,[eo]:`USER#${ep.userId}`}});return ed.from(eh.Item)},async updateUser(et){let{UpdateExpression:ea,ExpressionAttributeNames:es,ExpressionAttributeValues:eu}=generateUpdateExpression(et),ec=await ee.update({TableName:en,Key:{[ei]:`USER#${et.id}`,[eo]:`USER#${et.id}`},UpdateExpression:ea,ExpressionAttributeNames:es,ExpressionAttributeValues:eu,ReturnValues:"ALL_NEW"});return ed.from(ec.Attributes)},async deleteUser(et){let ea=await ee.query({TableName:en,KeyConditionExpression:"#pk = :pk",ExpressionAttributeNames:{"#pk":ei},ExpressionAttributeValues:{":pk":`USER#${et}`}});if(!ea.Items)return null;let es=ea.Items,eu=es.find(ee=>"USER"===ee.type),ec=es.map(ee=>({DeleteRequest:{Key:{[eo]:ee.sk,[ei]:ee.pk}}})),ef=ec.slice(0,25),ep={RequestItems:{[en]:ef}};return await ee.batchWrite(ep),ed.from(eu)},async linkAccount(et){let ea={...et,id:esm_browser_v4(),[ei]:`USER#${et.userId}`,[eo]:`ACCOUNT#${et.provider}#${et.providerAccountId}`,[es]:`ACCOUNT#${et.provider}`,[eu]:`ACCOUNT#${et.providerAccountId}`};return await ee.put({TableName:en,Item:ed.to(ea)}),et},async unlinkAccount({provider:et,providerAccountId:ec}){let ef=await ee.query({TableName:en,IndexName:ea,KeyConditionExpression:"#gsi1pk = :gsi1pk AND #gsi1sk = :gsi1sk",ExpressionAttributeNames:{"#gsi1pk":es,"#gsi1sk":eu},ExpressionAttributeValues:{":gsi1pk":`ACCOUNT#${et}`,":gsi1sk":`ACCOUNT#${ec}`}}),ep=ed.from(ef.Items?.[0]);if(ep)return await ee.delete({TableName:en,Key:{[ei]:`USER#${ep.userId}`,[eo]:`ACCOUNT#${et}#${ec}`},ReturnValues:"ALL_OLD"}),ep},async getSessionAndUser(et){let ec=await ee.query({TableName:en,IndexName:ea,KeyConditionExpression:"#gsi1pk = :gsi1pk AND #gsi1sk = :gsi1sk",ExpressionAttributeNames:{"#gsi1pk":es,"#gsi1sk":eu},ExpressionAttributeValues:{":gsi1pk":`SESSION#${et}`,":gsi1sk":`SESSION#${et}`}}),ef=ed.from(ec.Items?.[0]);if(!ef)return null;let ep=await ee.get({TableName:en,Key:{[ei]:`USER#${ef.userId}`,[eo]:`USER#${ef.userId}`}}),eh=ed.from(ep.Item);return eh?{user:eh,session:ef}:null},async createSession(et){let ea={id:esm_browser_v4(),...et};return await ee.put({TableName:en,Item:ed.to({[ei]:`USER#${et.userId}`,[eo]:`SESSION#${et.sessionToken}`,[eu]:`SESSION#${et.sessionToken}`,[es]:`SESSION#${et.sessionToken}`,type:"SESSION",...et})}),ea},async updateSession(et){let{sessionToken:ei}=et,eo=await ee.query({TableName:en,IndexName:ea,KeyConditionExpression:"#gsi1pk = :gsi1pk AND #gsi1sk = :gsi1sk",ExpressionAttributeNames:{"#gsi1pk":es,"#gsi1sk":eu},ExpressionAttributeValues:{":gsi1pk":`SESSION#${ei}`,":gsi1sk":`SESSION#${ei}`}});if(!eo.Items?.length)return null;let{pk:ec,sk:ef}=eo.Items[0],{UpdateExpression:ep,ExpressionAttributeNames:eh,ExpressionAttributeValues:ey}=generateUpdateExpression(et),em=await ee.update({TableName:en,Key:{pk:ec,sk:ef},UpdateExpression:ep,ExpressionAttributeNames:eh,ExpressionAttributeValues:ey,ReturnValues:"ALL_NEW"});return ed.from(em.Attributes)},async deleteSession(et){let ei=await ee.query({TableName:en,IndexName:ea,KeyConditionExpression:"#gsi1pk = :gsi1pk AND #gsi1sk = :gsi1sk",ExpressionAttributeNames:{"#gsi1pk":es,"#gsi1sk":eu},ExpressionAttributeValues:{":gsi1pk":`SESSION#${et}`,":gsi1sk":`SESSION#${et}`}});if(!ei?.Items?.length)return null;let{pk:eo,sk:ec}=ei.Items[0],ef=await ee.delete({TableName:en,Key:{pk:eo,sk:ec},ReturnValues:"ALL_OLD"});return ed.from(ef.Attributes)},createVerificationToken:async et=>(await ee.put({TableName:en,Item:ed.to({[ei]:`VT#${et.identifier}`,[eo]:`VT#${et.token}`,type:"VT",...et})}),et),async useVerificationToken({identifier:et,token:ea}){let es=await ee.delete({TableName:en,Key:{[ei]:`VT#${et}`,[eo]:`VT#${ea}`},ReturnValues:"ALL_OLD"});return ed.from(es.Attributes)}}}let ec=/(\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d\.\d+([+-][0-2]\d:[0-5]\d|Z))|(\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d([+-][0-2]\d:[0-5]\d|Z))|(\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d([+-][0-2]\d:[0-5]\d|Z))/;function isDate(ee){return ee&&ec.test(ee)&&!isNaN(Date.parse(ee))}let ed={to(ee){let et={};for(let en in ee){let ei=ee[en];ei instanceof Date?"expires"===en?et[en]=ei.getTime()/1e3:et[en]=ei.toISOString():et[en]=ei}return et},from(ee){if(!ee)return null;let et={};for(let en in ee){if(["pk","sk","GSI1PK","GSI1SK"].includes(en))continue;let ei=ee[en];if(isDate(ei))et[en]=new Date(ei);else{if("type"===en&&["SESSION","VT","USER"].includes(ei))continue;"expires"===en&&"number"==typeof ei?et[en]=new Date(1e3*ei):et[en]=ei}}return et}};function generateUpdateExpression(ee){let et=ed.to(ee),en="set",ei={},eo={};for(let ee in et)en+=` #${ee} = :${ee},`,ei["#"+ee]=ee,eo[":"+ee]=et[ee];return{UpdateExpression:en=en.slice(0,-1),ExpressionAttributeNames:ei,ExpressionAttributeValues:eo}}},99718:function(ee,et,en){"use strict";en.r(et),en.d(et,{default:function(){return web_hkdf},hkdf:function(){return web_hkdf}});let getGlobal=()=>{if("undefined"!=typeof globalThis)return globalThis;if("undefined"!=typeof self)return self;if("undefined"!=typeof window)return window;throw Error("unable to locate global object")};var hkdf=async(ee,et,en,ei,eo)=>{let{crypto:{subtle:ea}}=getGlobal();return new Uint8Array(await ea.deriveBits({name:"HKDF",hash:`SHA-${ee.substr(3)}`,salt:en,info:ei},await ea.importKey("raw",et,"HKDF",!1,["deriveBits"]),eo<<3))};function normalizeDigest(ee){switch(ee){case"sha256":case"sha384":case"sha512":case"sha1":return ee;default:throw TypeError('unsupported "digest" value')}}function normalizeUint8Array(ee,et){if("string"==typeof ee)return new TextEncoder().encode(ee);if(!(ee instanceof Uint8Array))throw TypeError(`"${et}"" must be an instance of Uint8Array or a string`);return ee}function normalizeIkm(ee){let et=normalizeUint8Array(ee,"ikm");if(!et.byteLength)throw TypeError('"ikm" must be at least one byte in length');return et}function normalizeInfo(ee){let et=normalizeUint8Array(ee,"info");if(et.byteLength>1024)throw TypeError('"info" must not contain more than 1024 bytes');return et}function normalizeKeylen(ee,et){if("number"!=typeof ee||!Number.isInteger(ee)||ee<1)throw TypeError('"keylen" must be a positive integer');let en=parseInt(et.substr(3),10)>>3||20;if(ee>255*en)throw TypeError('"keylen" too large');return ee}async function web_hkdf(ee,et,en,ei,eo){return hkdf(normalizeDigest(ee),normalizeIkm(et),normalizeUint8Array(en,"salt"),normalizeInfo(ei),normalizeKeylen(eo,ee))}},5121:function(ee,et,en){"use strict";en.d(et,{Z:function(){return ts}});var ei,eo,ea,es={};function bind(ee,et){return function(){return ee.apply(et,arguments)}}en.r(es),en.d(es,{hasBrowserEnv:function(){return eq},hasStandardBrowserEnv:function(){return eV},hasStandardBrowserWebWorkerEnv:function(){return eK}});let{toString:eu}=Object.prototype,{getPrototypeOf:ec}=Object,ed=(ei=Object.create(null),ee=>{let et=eu.call(ee);return ei[et]||(ei[et]=et.slice(8,-1).toLowerCase())}),kindOfTest=ee=>(ee=ee.toLowerCase(),et=>ed(et)===ee),typeOfTest=ee=>et=>typeof et===ee,{isArray:ef}=Array,ep=typeOfTest("undefined");function isBuffer(ee){return null!==ee&&!ep(ee)&&null!==ee.constructor&&!ep(ee.constructor)&&em(ee.constructor.isBuffer)&&ee.constructor.isBuffer(ee)}let eh=kindOfTest("ArrayBuffer");function isArrayBufferView(ee){return"undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(ee):ee&&ee.buffer&&eh(ee.buffer)}let ey=typeOfTest("string"),em=typeOfTest("function"),eg=typeOfTest("number"),isObject=ee=>null!==ee&&"object"==typeof ee,isBoolean=ee=>!0===ee||!1===ee,isPlainObject=ee=>{if("object"!==ed(ee))return!1;let et=ec(ee);return(null===et||et===Object.prototype||null===Object.getPrototypeOf(et))&&!(Symbol.toStringTag in ee)&&!(Symbol.iterator in ee)},eb=kindOfTest("Date"),ev=kindOfTest("File"),e_=kindOfTest("Blob"),ew=kindOfTest("FileList"),isStream=ee=>isObject(ee)&&em(ee.pipe),isFormData=ee=>{let et;return ee&&("function"==typeof FormData&&ee instanceof FormData||em(ee.append)&&("formdata"===(et=ed(ee))||"object"===et&&em(ee.toString)&&"[object FormData]"===ee.toString()))},eS=kindOfTest("URLSearchParams"),trim=ee=>ee.trim?ee.trim():ee.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function forEach(ee,et,{allOwnKeys:en=!1}={}){let ei,eo;if(null!=ee){if("object"!=typeof ee&&(ee=[ee]),ef(ee))for(ei=0,eo=ee.length;ei0;)if(et===(en=ei[eo]).toLowerCase())return en;return null}let eE="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:global,isContextDefined=ee=>!ep(ee)&&ee!==eE;function merge(){let{caseless:ee}=isContextDefined(this)&&this||{},et={},assignValue=(en,ei)=>{let eo=ee&&findKey(et,ei)||ei;isPlainObject(et[eo])&&isPlainObject(en)?et[eo]=merge(et[eo],en):isPlainObject(en)?et[eo]=merge({},en):ef(en)?et[eo]=en.slice():et[eo]=en};for(let ee=0,et=arguments.length;ee(forEach(et,(et,ei)=>{en&&em(et)?ee[ei]=bind(et,en):ee[ei]=et},{allOwnKeys:ei}),ee),stripBOM=ee=>(65279===ee.charCodeAt(0)&&(ee=ee.slice(1)),ee),inherits=(ee,et,en,ei)=>{ee.prototype=Object.create(et.prototype,ei),ee.prototype.constructor=ee,Object.defineProperty(ee,"super",{value:et.prototype}),en&&Object.assign(ee.prototype,en)},toFlatObject=(ee,et,en,ei)=>{let eo,ea,es;let eu={};if(et=et||{},null==ee)return et;do{for(ea=(eo=Object.getOwnPropertyNames(ee)).length;ea-- >0;)es=eo[ea],(!ei||ei(es,ee,et))&&!eu[es]&&(et[es]=ee[es],eu[es]=!0);ee=!1!==en&&ec(ee)}while(ee&&(!en||en(ee,et))&&ee!==Object.prototype);return et},endsWith=(ee,et,en)=>{ee=String(ee),(void 0===en||en>ee.length)&&(en=ee.length),en-=et.length;let ei=ee.indexOf(et,en);return -1!==ei&&ei===en},toArray=ee=>{if(!ee)return null;if(ef(ee))return ee;let et=ee.length;if(!eg(et))return null;let en=Array(et);for(;et-- >0;)en[et]=ee[et];return en},eA=(eo="undefined"!=typeof Uint8Array&&ec(Uint8Array),ee=>eo&&ee instanceof eo),forEachEntry=(ee,et)=>{let en;let ei=ee&&ee[Symbol.iterator],eo=ei.call(ee);for(;(en=eo.next())&&!en.done;){let ei=en.value;et.call(ee,ei[0],ei[1])}},matchAll=(ee,et)=>{let en;let ei=[];for(;null!==(en=ee.exec(et));)ei.push(en);return ei},e$=kindOfTest("HTMLFormElement"),toCamelCase=ee=>ee.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(ee,et,en){return et.toUpperCase()+en}),ex=(({hasOwnProperty:ee})=>(et,en)=>ee.call(et,en))(Object.prototype),eC=kindOfTest("RegExp"),reduceDescriptors=(ee,et)=>{let en=Object.getOwnPropertyDescriptors(ee),ei={};forEach(en,(en,eo)=>{let ea;!1!==(ea=et(en,eo,ee))&&(ei[eo]=ea||en)}),Object.defineProperties(ee,ei)},freezeMethods=ee=>{reduceDescriptors(ee,(et,en)=>{if(em(ee)&&-1!==["arguments","caller","callee"].indexOf(en))return!1;let ei=ee[en];if(em(ei)){if(et.enumerable=!1,"writable"in et){et.writable=!1;return}et.set||(et.set=()=>{throw Error("Can not rewrite read-only method '"+en+"'")})}})},toObjectSet=(ee,et)=>{let en={},define=ee=>{ee.forEach(ee=>{en[ee]=!0})};return define(ef(ee)?ee:String(ee).split(et)),en},noop=()=>{},toFiniteNumber=(ee,et)=>Number.isFinite(ee=+ee)?ee:et,ek="abcdefghijklmnopqrstuvwxyz",eO="0123456789",eT={DIGIT:eO,ALPHA:ek,ALPHA_DIGIT:ek+ek.toUpperCase()+eO},generateString=(ee=16,et=eT.ALPHA_DIGIT)=>{let en="",{length:ei}=et;for(;ee--;)en+=et[Math.random()*ei|0];return en};function isSpecCompliantForm(ee){return!!(ee&&em(ee.append)&&"FormData"===ee[Symbol.toStringTag]&&ee[Symbol.iterator])}let toJSONObject=ee=>{let et=Array(10),visit=(ee,en)=>{if(isObject(ee)){if(et.indexOf(ee)>=0)return;if(!("toJSON"in ee)){et[en]=ee;let ei=ef(ee)?[]:{};return forEach(ee,(ee,et)=>{let eo=visit(ee,en+1);ep(eo)||(ei[et]=eo)}),et[en]=void 0,ei}}return ee};return visit(ee,0)},eP=kindOfTest("AsyncFunction"),isThenable=ee=>ee&&(isObject(ee)||em(ee))&&em(ee.then)&&em(ee.catch);var eR={isArray:ef,isArrayBuffer:eh,isBuffer,isFormData,isArrayBufferView,isString:ey,isNumber:eg,isBoolean,isObject,isPlainObject,isUndefined:ep,isDate:eb,isFile:ev,isBlob:e_,isRegExp:eC,isFunction:em,isStream,isURLSearchParams:eS,isTypedArray:eA,isFileList:ew,forEach,merge,extend,trim,stripBOM,inherits,toFlatObject,kindOf:ed,kindOfTest,endsWith,toArray,forEachEntry,matchAll,isHTMLForm:e$,hasOwnProperty:ex,hasOwnProp:ex,reduceDescriptors,freezeMethods,toObjectSet,toCamelCase,noop,toFiniteNumber,findKey,global:eE,isContextDefined,ALPHABET:eT,generateString,isSpecCompliantForm,toJSONObject,isAsyncFn:eP,isThenable};function AxiosError(ee,et,en,ei,eo){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=Error().stack,this.message=ee,this.name="AxiosError",et&&(this.code=et),en&&(this.config=en),ei&&(this.request=ei),eo&&(this.response=eo)}eR.inherits(AxiosError,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:eR.toJSONObject(this.config),code:this.code,status:this.response&&this.response.status?this.response.status:null}}});let eI=AxiosError.prototype,eN={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(ee=>{eN[ee]={value:ee}}),Object.defineProperties(AxiosError,eN),Object.defineProperty(eI,"isAxiosError",{value:!0}),AxiosError.from=(ee,et,en,ei,eo,ea)=>{let es=Object.create(eI);return eR.toFlatObject(ee,es,function(ee){return ee!==Error.prototype},ee=>"isAxiosError"!==ee),AxiosError.call(es,ee.message,et,en,ei,eo),es.cause=ee,es.name=ee.name,ea&&Object.assign(es,ea),es};var eM=AxiosError,ej=null,eD=en(48764).Buffer;function isVisitable(ee){return eR.isPlainObject(ee)||eR.isArray(ee)}function removeBrackets(ee){return eR.endsWith(ee,"[]")?ee.slice(0,-2):ee}function renderKey(ee,et,en){return ee?ee.concat(et).map(function(ee,et){return ee=removeBrackets(ee),!en&&et?"["+ee+"]":ee}).join(en?".":""):et}function isFlatArray(ee){return eR.isArray(ee)&&!ee.some(isVisitable)}let eB=eR.toFlatObject(eR,{},null,function(ee){return/^is[A-Z]/.test(ee)});var helpers_toFormData=function(ee,et,en){if(!eR.isObject(ee))throw TypeError("target must be an object");et=et||new(ej||FormData),en=eR.toFlatObject(en,{metaTokens:!0,dots:!1,indexes:!1},!1,function(ee,et){return!eR.isUndefined(et[ee])});let ei=en.metaTokens,eo=en.visitor||defaultVisitor,ea=en.dots,es=en.indexes,eu=en.Blob||"undefined"!=typeof Blob&&Blob,ec=eu&&eR.isSpecCompliantForm(et);if(!eR.isFunction(eo))throw TypeError("visitor must be a function");function convertValue(ee){if(null===ee)return"";if(eR.isDate(ee))return ee.toISOString();if(!ec&&eR.isBlob(ee))throw new eM("Blob is not supported. Use a Buffer instead.");return eR.isArrayBuffer(ee)||eR.isTypedArray(ee)?ec&&"function"==typeof Blob?new Blob([ee]):eD.from(ee):ee}function defaultVisitor(ee,en,eo){let eu=ee;if(ee&&!eo&&"object"==typeof ee){if(eR.endsWith(en,"{}"))en=ei?en:en.slice(0,-2),ee=JSON.stringify(ee);else if(eR.isArray(ee)&&isFlatArray(ee)||(eR.isFileList(ee)||eR.endsWith(en,"[]"))&&(eu=eR.toArray(ee)))return en=removeBrackets(en),eu.forEach(function(ee,ei){eR.isUndefined(ee)||null===ee||et.append(!0===es?renderKey([en],ei,ea):null===es?en:en+"[]",convertValue(ee))}),!1}return!!isVisitable(ee)||(et.append(renderKey(eo,en,ea),convertValue(ee)),!1)}let ed=[],ef=Object.assign(eB,{defaultVisitor,convertValue,isVisitable});function build(ee,en){if(!eR.isUndefined(ee)){if(-1!==ed.indexOf(ee))throw Error("Circular reference detected in "+en.join("."));ed.push(ee),eR.forEach(ee,function(ee,ei){let ea=!(eR.isUndefined(ee)||null===ee)&&eo.call(et,ee,eR.isString(ei)?ei.trim():ei,en,ef);!0===ea&&build(ee,en?en.concat(ei):[ei])}),ed.pop()}}if(!eR.isObject(ee))throw TypeError("data must be an object");return build(ee),et};function encode(ee){let et={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\x00"};return encodeURIComponent(ee).replace(/[!'()~]|%20|%00/g,function(ee){return et[ee]})}function AxiosURLSearchParams(ee,et){this._pairs=[],ee&&helpers_toFormData(ee,this,et)}let eU=AxiosURLSearchParams.prototype;eU.append=function(ee,et){this._pairs.push([ee,et])},eU.toString=function(ee){let et=ee?function(et){return ee.call(this,et,encode)}:encode;return this._pairs.map(function(ee){return et(ee[0])+"="+et(ee[1])},"").join("&")};var eL=AxiosURLSearchParams;function buildURL_encode(ee){return encodeURIComponent(ee).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function buildURL(ee,et,en){let ei;if(!et)return ee;let eo=en&&en.encode||buildURL_encode,ea=en&&en.serialize;if(ei=ea?ea(et,en):eR.isURLSearchParams(et)?et.toString():new eL(et,en).toString(eo)){let et=ee.indexOf("#");-1!==et&&(ee=ee.slice(0,et)),ee+=(-1===ee.indexOf("?")?"?":"&")+ei}return ee}let InterceptorManager=class InterceptorManager{constructor(){this.handlers=[]}use(ee,et,en){return this.handlers.push({fulfilled:ee,rejected:et,synchronous:!!en&&en.synchronous,runWhen:en?en.runWhen:null}),this.handlers.length-1}eject(ee){this.handlers[ee]&&(this.handlers[ee]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(ee){eR.forEach(this.handlers,function(et){null!==et&&ee(et)})}};var eF=InterceptorManager,eW={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},eH={isBrowser:!0,classes:{URLSearchParams:"undefined"!=typeof URLSearchParams?URLSearchParams:eL,FormData:"undefined"!=typeof FormData?FormData:null,Blob:"undefined"!=typeof Blob?Blob:null},protocols:["http","https","file","blob","url","data"]};let eq="undefined"!=typeof window&&"undefined"!=typeof document,eV=(ea="undefined"!=typeof navigator&&navigator.product,eq&&0>["ReactNative","NativeScript","NS"].indexOf(ea)),eK="undefined"!=typeof WorkerGlobalScope&&self instanceof WorkerGlobalScope&&"function"==typeof self.importScripts;var ez={...es,...eH};function toURLEncodedForm(ee,et){return helpers_toFormData(ee,new ez.classes.URLSearchParams,Object.assign({visitor:function(ee,et,en,ei){return ez.isNode&&eR.isBuffer(ee)?(this.append(et,ee.toString("base64")),!1):ei.defaultVisitor.apply(this,arguments)}},et))}function parsePropPath(ee){return eR.matchAll(/\w+|\[(\w*)]/g,ee).map(ee=>"[]"===ee[0]?"":ee[1]||ee[0])}function arrayToObject(ee){let et,en;let ei={},eo=Object.keys(ee),ea=eo.length;for(et=0;et=ee.length;if(eo=!eo&&eR.isArray(en)?en.length:eo,es)return eR.hasOwnProp(en,eo)?en[eo]=[en[eo],et]:en[eo]=et,!ea;en[eo]&&eR.isObject(en[eo])||(en[eo]=[]);let eu=buildPath(ee,et,en[eo],ei);return eu&&eR.isArray(en[eo])&&(en[eo]=arrayToObject(en[eo])),!ea}if(eR.isFormData(ee)&&eR.isFunction(ee.entries)){let et={};return eR.forEachEntry(ee,(ee,en)=>{buildPath(parsePropPath(ee),en,et,0)}),et}return null};function stringifySafely(ee,et,en){if(eR.isString(ee))try{return(et||JSON.parse)(ee),eR.trim(ee)}catch(ee){if("SyntaxError"!==ee.name)throw ee}return(en||JSON.stringify)(ee)}let eJ={transitional:eW,adapter:["xhr","http"],transformRequest:[function(ee,et){let en;let ei=et.getContentType()||"",eo=ei.indexOf("application/json")>-1,ea=eR.isObject(ee);ea&&eR.isHTMLForm(ee)&&(ee=new FormData(ee));let es=eR.isFormData(ee);if(es)return eo&&eo?JSON.stringify(helpers_formDataToJSON(ee)):ee;if(eR.isArrayBuffer(ee)||eR.isBuffer(ee)||eR.isStream(ee)||eR.isFile(ee)||eR.isBlob(ee))return ee;if(eR.isArrayBufferView(ee))return ee.buffer;if(eR.isURLSearchParams(ee))return et.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),ee.toString();if(ea){if(ei.indexOf("application/x-www-form-urlencoded")>-1)return toURLEncodedForm(ee,this.formSerializer).toString();if((en=eR.isFileList(ee))||ei.indexOf("multipart/form-data")>-1){let et=this.env&&this.env.FormData;return helpers_toFormData(en?{"files[]":ee}:ee,et&&new et,this.formSerializer)}}return ea||eo?(et.setContentType("application/json",!1),stringifySafely(ee)):ee}],transformResponse:[function(ee){let et=this.transitional||eJ.transitional,en=et&&et.forcedJSONParsing,ei="json"===this.responseType;if(ee&&eR.isString(ee)&&(en&&!this.responseType||ei)){let en=et&&et.silentJSONParsing,eo=!en&&ei;try{return JSON.parse(ee)}catch(ee){if(eo){if("SyntaxError"===ee.name)throw eM.from(ee,eM.ERR_BAD_RESPONSE,this,null,this.response);throw ee}}}return ee}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:ez.classes.FormData,Blob:ez.classes.Blob},validateStatus:function(ee){return ee>=200&&ee<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};eR.forEach(["delete","get","head","post","put","patch"],ee=>{eJ.headers[ee]={}});var eG=eJ;let eY=eR.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]);var parseHeaders=ee=>{let et,en,ei;let eo={};return ee&&ee.split("\n").forEach(function(ee){ei=ee.indexOf(":"),et=ee.substring(0,ei).trim().toLowerCase(),en=ee.substring(ei+1).trim(),!et||eo[et]&&eY[et]||("set-cookie"===et?eo[et]?eo[et].push(en):eo[et]=[en]:eo[et]=eo[et]?eo[et]+", "+en:en)}),eo};let eZ=Symbol("internals");function normalizeHeader(ee){return ee&&String(ee).trim().toLowerCase()}function normalizeValue(ee){return!1===ee||null==ee?ee:eR.isArray(ee)?ee.map(normalizeValue):String(ee)}function parseTokens(ee){let et;let en=Object.create(null),ei=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;for(;et=ei.exec(ee);)en[et[1]]=et[2];return en}let isValidHeaderName=ee=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(ee.trim());function matchHeaderValue(ee,et,en,ei,eo){if(eR.isFunction(ei))return ei.call(this,et,en);if(eo&&(et=en),eR.isString(et)){if(eR.isString(ei))return -1!==et.indexOf(ei);if(eR.isRegExp(ei))return ei.test(et)}}function formatHeader(ee){return ee.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(ee,et,en)=>et.toUpperCase()+en)}function buildAccessors(ee,et){let en=eR.toCamelCase(" "+et);["get","set","has"].forEach(ei=>{Object.defineProperty(ee,ei+en,{value:function(ee,en,eo){return this[ei].call(this,et,ee,en,eo)},configurable:!0})})}let AxiosHeaders=class AxiosHeaders{constructor(ee){ee&&this.set(ee)}set(ee,et,en){let ei=this;function setHeader(ee,et,en){let eo=normalizeHeader(et);if(!eo)throw Error("header name must be a non-empty string");let ea=eR.findKey(ei,eo);ea&&void 0!==ei[ea]&&!0!==en&&(void 0!==en||!1===ei[ea])||(ei[ea||et]=normalizeValue(ee))}let setHeaders=(ee,et)=>eR.forEach(ee,(ee,en)=>setHeader(ee,en,et));return eR.isPlainObject(ee)||ee instanceof this.constructor?setHeaders(ee,et):eR.isString(ee)&&(ee=ee.trim())&&!isValidHeaderName(ee)?setHeaders(parseHeaders(ee),et):null!=ee&&setHeader(et,ee,en),this}get(ee,et){if(ee=normalizeHeader(ee)){let en=eR.findKey(this,ee);if(en){let ee=this[en];if(!et)return ee;if(!0===et)return parseTokens(ee);if(eR.isFunction(et))return et.call(this,ee,en);if(eR.isRegExp(et))return et.exec(ee);throw TypeError("parser must be boolean|regexp|function")}}}has(ee,et){if(ee=normalizeHeader(ee)){let en=eR.findKey(this,ee);return!!(en&&void 0!==this[en]&&(!et||matchHeaderValue(this,this[en],en,et)))}return!1}delete(ee,et){let en=this,ei=!1;function deleteHeader(ee){if(ee=normalizeHeader(ee)){let eo=eR.findKey(en,ee);eo&&(!et||matchHeaderValue(en,en[eo],eo,et))&&(delete en[eo],ei=!0)}}return eR.isArray(ee)?ee.forEach(deleteHeader):deleteHeader(ee),ei}clear(ee){let et=Object.keys(this),en=et.length,ei=!1;for(;en--;){let eo=et[en];(!ee||matchHeaderValue(this,this[eo],eo,ee,!0))&&(delete this[eo],ei=!0)}return ei}normalize(ee){let et=this,en={};return eR.forEach(this,(ei,eo)=>{let ea=eR.findKey(en,eo);if(ea){et[ea]=normalizeValue(ei),delete et[eo];return}let es=ee?formatHeader(eo):String(eo).trim();es!==eo&&delete et[eo],et[es]=normalizeValue(ei),en[es]=!0}),this}concat(...ee){return this.constructor.concat(this,...ee)}toJSON(ee){let et=Object.create(null);return eR.forEach(this,(en,ei)=>{null!=en&&!1!==en&&(et[ei]=ee&&eR.isArray(en)?en.join(", "):en)}),et}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([ee,et])=>ee+": "+et).join("\n")}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(ee){return ee instanceof this?ee:new this(ee)}static concat(ee,...et){let en=new this(ee);return et.forEach(ee=>en.set(ee)),en}static accessor(ee){let et=this[eZ]=this[eZ]={accessors:{}},en=et.accessors,ei=this.prototype;function defineAccessor(ee){let et=normalizeHeader(ee);en[et]||(buildAccessors(ei,ee),en[et]=!0)}return eR.isArray(ee)?ee.forEach(defineAccessor):defineAccessor(ee),this}};AxiosHeaders.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),eR.reduceDescriptors(AxiosHeaders.prototype,({value:ee},et)=>{let en=et[0].toUpperCase()+et.slice(1);return{get:()=>ee,set(ee){this[en]=ee}}}),eR.freezeMethods(AxiosHeaders);var eX=AxiosHeaders;function transformData(ee,et){let en=this||eG,ei=et||en,eo=eX.from(ei.headers),ea=ei.data;return eR.forEach(ee,function(ee){ea=ee.call(en,ea,eo.normalize(),et?et.status:void 0)}),eo.normalize(),ea}function isCancel(ee){return!!(ee&&ee.__CANCEL__)}function CanceledError(ee,et,en){eM.call(this,null==ee?"canceled":ee,eM.ERR_CANCELED,et,en),this.name="CanceledError"}eR.inherits(CanceledError,eM,{__CANCEL__:!0});var eQ=CanceledError;function settle(ee,et,en){let ei=en.config.validateStatus;!en.status||!ei||ei(en.status)?ee(en):et(new eM("Request failed with status code "+en.status,[eM.ERR_BAD_REQUEST,eM.ERR_BAD_RESPONSE][Math.floor(en.status/100)-4],en.config,en.request,en))}var e0=ez.hasStandardBrowserEnv?{write(ee,et,en,ei,eo,ea){let es=[ee+"="+encodeURIComponent(et)];eR.isNumber(en)&&es.push("expires="+new Date(en).toGMTString()),eR.isString(ei)&&es.push("path="+ei),eR.isString(eo)&&es.push("domain="+eo),!0===ea&&es.push("secure"),document.cookie=es.join("; ")},read(ee){let et=document.cookie.match(RegExp("(^|;\\s*)("+ee+")=([^;]*)"));return et?decodeURIComponent(et[3]):null},remove(ee){this.write(ee,"",Date.now()-864e5)}}:{write(){},read:()=>null,remove(){}};function isAbsoluteURL(ee){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(ee)}function combineURLs(ee,et){return et?ee.replace(/\/?\/$/,"")+"/"+et.replace(/^\/+/,""):ee}function buildFullPath(ee,et){return ee&&!isAbsoluteURL(et)?combineURLs(ee,et):et}var e1=ez.hasStandardBrowserEnv?function(){let ee;let et=/(msie|trident)/i.test(navigator.userAgent),en=document.createElement("a");function resolveURL(ee){let ei=ee;return et&&(en.setAttribute("href",ei),ei=en.href),en.setAttribute("href",ei),{href:en.href,protocol:en.protocol?en.protocol.replace(/:$/,""):"",host:en.host,search:en.search?en.search.replace(/^\?/,""):"",hash:en.hash?en.hash.replace(/^#/,""):"",hostname:en.hostname,port:en.port,pathname:"/"===en.pathname.charAt(0)?en.pathname:"/"+en.pathname}}return ee=resolveURL(window.location.href),function(et){let en=eR.isString(et)?resolveURL(et):et;return en.protocol===ee.protocol&&en.host===ee.host}}():function(){return function(){return!0}}();function parseProtocol(ee){let et=/^([-+\w]{1,25})(:?\/\/|:)/.exec(ee);return et&&et[1]||""}var helpers_speedometer=function(ee,et){let en;ee=ee||10;let ei=Array(ee),eo=Array(ee),ea=0,es=0;return et=void 0!==et?et:1e3,function(eu){let ec=Date.now(),ed=eo[es];en||(en=ec),ei[ea]=eu,eo[ea]=ec;let ef=es,ep=0;for(;ef!==ea;)ep+=ei[ef++],ef%=ee;if((ea=(ea+1)%ee)===es&&(es=(es+1)%ee),ec-en{let ea=eo.loaded,es=eo.lengthComputable?eo.total:void 0,eu=ea-en,ec=ei(eu),ed=ea<=es;en=ea;let ef={loaded:ea,total:es,progress:es?ea/es:void 0,bytes:eu,rate:ec||void 0,estimated:ec&&es&&ed?(es-ea)/ec:void 0,event:eo};ef[et?"download":"upload"]=!0,ee(ef)}}let e2="undefined"!=typeof XMLHttpRequest;var e3=e2&&function(ee){return new Promise(function(et,en){let ei,eo,ea=ee.data,es=eX.from(ee.headers).normalize(),{responseType:eu,withXSRFToken:ec}=ee;function done(){ee.cancelToken&&ee.cancelToken.unsubscribe(ei),ee.signal&&ee.signal.removeEventListener("abort",ei)}if(eR.isFormData(ea)){if(ez.hasStandardBrowserEnv||ez.hasStandardBrowserWebWorkerEnv)es.setContentType(!1);else if(!1!==(eo=es.getContentType())){let[ee,...et]=eo?eo.split(";").map(ee=>ee.trim()).filter(Boolean):[];es.setContentType([ee||"multipart/form-data",...et].join("; "))}}let ed=new XMLHttpRequest;if(ee.auth){let et=ee.auth.username||"",en=ee.auth.password?unescape(encodeURIComponent(ee.auth.password)):"";es.set("Authorization","Basic "+btoa(et+":"+en))}let ef=buildFullPath(ee.baseURL,ee.url);function onloadend(){if(!ed)return;let ei=eX.from("getAllResponseHeaders"in ed&&ed.getAllResponseHeaders()),eo=eu&&"text"!==eu&&"json"!==eu?ed.response:ed.responseText,ea={data:eo,status:ed.status,statusText:ed.statusText,headers:ei,config:ee,request:ed};settle(function(ee){et(ee),done()},function(ee){en(ee),done()},ea),ed=null}if(ed.open(ee.method.toUpperCase(),buildURL(ef,ee.params,ee.paramsSerializer),!0),ed.timeout=ee.timeout,"onloadend"in ed?ed.onloadend=onloadend:ed.onreadystatechange=function(){ed&&4===ed.readyState&&(0!==ed.status||ed.responseURL&&0===ed.responseURL.indexOf("file:"))&&setTimeout(onloadend)},ed.onabort=function(){ed&&(en(new eM("Request aborted",eM.ECONNABORTED,ee,ed)),ed=null)},ed.onerror=function(){en(new eM("Network Error",eM.ERR_NETWORK,ee,ed)),ed=null},ed.ontimeout=function(){let et=ee.timeout?"timeout of "+ee.timeout+"ms exceeded":"timeout exceeded",ei=ee.transitional||eW;ee.timeoutErrorMessage&&(et=ee.timeoutErrorMessage),en(new eM(et,ei.clarifyTimeoutError?eM.ETIMEDOUT:eM.ECONNABORTED,ee,ed)),ed=null},ez.hasStandardBrowserEnv&&(ec&&eR.isFunction(ec)&&(ec=ec(ee)),ec||!1!==ec&&e1(ef))){let et=ee.xsrfHeaderName&&ee.xsrfCookieName&&e0.read(ee.xsrfCookieName);et&&es.set(ee.xsrfHeaderName,et)}void 0===ea&&es.setContentType(null),"setRequestHeader"in ed&&eR.forEach(es.toJSON(),function(ee,et){ed.setRequestHeader(et,ee)}),eR.isUndefined(ee.withCredentials)||(ed.withCredentials=!!ee.withCredentials),eu&&"json"!==eu&&(ed.responseType=ee.responseType),"function"==typeof ee.onDownloadProgress&&ed.addEventListener("progress",progressEventReducer(ee.onDownloadProgress,!0)),"function"==typeof ee.onUploadProgress&&ed.upload&&ed.upload.addEventListener("progress",progressEventReducer(ee.onUploadProgress)),(ee.cancelToken||ee.signal)&&(ei=et=>{ed&&(en(!et||et.type?new eQ(null,ee,ed):et),ed.abort(),ed=null)},ee.cancelToken&&ee.cancelToken.subscribe(ei),ee.signal&&(ee.signal.aborted?ei():ee.signal.addEventListener("abort",ei)));let ep=parseProtocol(ef);if(ep&&-1===ez.protocols.indexOf(ep)){en(new eM("Unsupported protocol "+ep+":",eM.ERR_BAD_REQUEST,ee));return}ed.send(ea||null)})};let e4={http:ej,xhr:e3};eR.forEach(e4,(ee,et)=>{if(ee){try{Object.defineProperty(ee,"name",{value:et})}catch(ee){}Object.defineProperty(ee,"adapterName",{value:et})}});let renderReason=ee=>`- ${ee}`,isResolvedHandle=ee=>eR.isFunction(ee)||null===ee||!1===ee;var e8={getAdapter:ee=>{let et,en;ee=eR.isArray(ee)?ee:[ee];let{length:ei}=ee,eo={};for(let ea=0;ea`adapter ${ee} `+(!1===et?"is not supported by the environment":"is not available in the build"));throw new eM("There is no suitable adapter to dispatch the request "+(ei?ee.length>1?"since :\n"+ee.map(renderReason).join("\n"):" "+renderReason(ee[0]):"as no adapter specified"),"ERR_NOT_SUPPORT")}return en},adapters:e4};function throwIfCancellationRequested(ee){if(ee.cancelToken&&ee.cancelToken.throwIfRequested(),ee.signal&&ee.signal.aborted)throw new eQ(null,ee)}function dispatchRequest(ee){throwIfCancellationRequested(ee),ee.headers=eX.from(ee.headers),ee.data=transformData.call(ee,ee.transformRequest),-1!==["post","put","patch"].indexOf(ee.method)&&ee.headers.setContentType("application/x-www-form-urlencoded",!1);let et=e8.getAdapter(ee.adapter||eG.adapter);return et(ee).then(function(et){return throwIfCancellationRequested(ee),et.data=transformData.call(ee,ee.transformResponse,et),et.headers=eX.from(et.headers),et},function(et){return!isCancel(et)&&(throwIfCancellationRequested(ee),et&&et.response&&(et.response.data=transformData.call(ee,ee.transformResponse,et.response),et.response.headers=eX.from(et.response.headers))),Promise.reject(et)})}let headersToObject=ee=>ee instanceof eX?ee.toJSON():ee;function mergeConfig(ee,et){et=et||{};let en={};function getMergedValue(ee,et,en){return eR.isPlainObject(ee)&&eR.isPlainObject(et)?eR.merge.call({caseless:en},ee,et):eR.isPlainObject(et)?eR.merge({},et):eR.isArray(et)?et.slice():et}function mergeDeepProperties(ee,et,en){return eR.isUndefined(et)?eR.isUndefined(ee)?void 0:getMergedValue(void 0,ee,en):getMergedValue(ee,et,en)}function valueFromConfig2(ee,et){if(!eR.isUndefined(et))return getMergedValue(void 0,et)}function defaultToConfig2(ee,et){return eR.isUndefined(et)?eR.isUndefined(ee)?void 0:getMergedValue(void 0,ee):getMergedValue(void 0,et)}function mergeDirectKeys(en,ei,eo){return eo in et?getMergedValue(en,ei):eo in ee?getMergedValue(void 0,en):void 0}let ei={url:valueFromConfig2,method:valueFromConfig2,data:valueFromConfig2,baseURL:defaultToConfig2,transformRequest:defaultToConfig2,transformResponse:defaultToConfig2,paramsSerializer:defaultToConfig2,timeout:defaultToConfig2,timeoutMessage:defaultToConfig2,withCredentials:defaultToConfig2,withXSRFToken:defaultToConfig2,adapter:defaultToConfig2,responseType:defaultToConfig2,xsrfCookieName:defaultToConfig2,xsrfHeaderName:defaultToConfig2,onUploadProgress:defaultToConfig2,onDownloadProgress:defaultToConfig2,decompress:defaultToConfig2,maxContentLength:defaultToConfig2,maxBodyLength:defaultToConfig2,beforeRedirect:defaultToConfig2,transport:defaultToConfig2,httpAgent:defaultToConfig2,httpsAgent:defaultToConfig2,cancelToken:defaultToConfig2,socketPath:defaultToConfig2,responseEncoding:defaultToConfig2,validateStatus:mergeDirectKeys,headers:(ee,et)=>mergeDeepProperties(headersToObject(ee),headersToObject(et),!0)};return eR.forEach(Object.keys(Object.assign({},ee,et)),function(eo){let ea=ei[eo]||mergeDeepProperties,es=ea(ee[eo],et[eo],eo);eR.isUndefined(es)&&ea!==mergeDirectKeys||(en[eo]=es)}),en}let e6="1.6.5",e5={};["object","boolean","number","function","string","symbol"].forEach((ee,et)=>{e5[ee]=function(en){return typeof en===ee||"a"+(et<1?"n ":" ")+ee}});let e9={};e5.transitional=function(ee,et,en){function formatMessage(ee,et){return"[Axios v"+e6+"] Transitional option '"+ee+"'"+et+(en?". "+en:"")}return(en,ei,eo)=>{if(!1===ee)throw new eM(formatMessage(ei," has been removed"+(et?" in "+et:"")),eM.ERR_DEPRECATED);return et&&!e9[ei]&&(e9[ei]=!0,console.warn(formatMessage(ei," has been deprecated since v"+et+" and will be removed in the near future"))),!ee||ee(en,ei,eo)}};var e7={assertOptions:function(ee,et,en){if("object"!=typeof ee)throw new eM("options must be an object",eM.ERR_BAD_OPTION_VALUE);let ei=Object.keys(ee),eo=ei.length;for(;eo-- >0;){let ea=ei[eo],es=et[ea];if(es){let et=ee[ea],en=void 0===et||es(et,ea,ee);if(!0!==en)throw new eM("option "+ea+" must be "+en,eM.ERR_BAD_OPTION_VALUE);continue}if(!0!==en)throw new eM("Unknown option "+ea,eM.ERR_BAD_OPTION)}},validators:e5};let te=e7.validators;let Axios=class Axios{constructor(ee){this.defaults=ee,this.interceptors={request:new eF,response:new eF}}request(ee,et){let en,ei;"string"==typeof ee?(et=et||{}).url=ee:et=ee||{},et=mergeConfig(this.defaults,et);let{transitional:eo,paramsSerializer:ea,headers:es}=et;void 0!==eo&&e7.assertOptions(eo,{silentJSONParsing:te.transitional(te.boolean),forcedJSONParsing:te.transitional(te.boolean),clarifyTimeoutError:te.transitional(te.boolean)},!1),null!=ea&&(eR.isFunction(ea)?et.paramsSerializer={serialize:ea}:e7.assertOptions(ea,{encode:te.function,serialize:te.function},!0)),et.method=(et.method||this.defaults.method||"get").toLowerCase();let eu=es&&eR.merge(es.common,es[et.method]);es&&eR.forEach(["delete","get","head","post","put","patch","common"],ee=>{delete es[ee]}),et.headers=eX.concat(eu,es);let ec=[],ed=!0;this.interceptors.request.forEach(function(ee){("function"!=typeof ee.runWhen||!1!==ee.runWhen(et))&&(ed=ed&&ee.synchronous,ec.unshift(ee.fulfilled,ee.rejected))});let ef=[];this.interceptors.response.forEach(function(ee){ef.push(ee.fulfilled,ee.rejected)});let ep=0;if(!ed){let ee=[dispatchRequest.bind(this),void 0];for(ee.unshift.apply(ee,ec),ee.push.apply(ee,ef),ei=ee.length,en=Promise.resolve(et);ep{if(!en._listeners)return;let et=en._listeners.length;for(;et-- >0;)en._listeners[et](ee);en._listeners=null}),this.promise.then=ee=>{let et;let ei=new Promise(ee=>{en.subscribe(ee),et=ee}).then(ee);return ei.cancel=function(){en.unsubscribe(et)},ei},ee(function(ee,ei,eo){en.reason||(en.reason=new eQ(ee,ei,eo),et(en.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(ee){if(this.reason){ee(this.reason);return}this._listeners?this._listeners.push(ee):this._listeners=[ee]}unsubscribe(ee){if(!this._listeners)return;let et=this._listeners.indexOf(ee);-1!==et&&this._listeners.splice(et,1)}static source(){let ee;let et=new CancelToken(function(et){ee=et});return{token:et,cancel:ee}}};var tr=CancelToken;function spread(ee){return function(et){return ee.apply(null,et)}}function isAxiosError(ee){return eR.isObject(ee)&&!0===ee.isAxiosError}let tn={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(tn).forEach(([ee,et])=>{tn[et]=ee});var ti=tn;function createInstance(ee){let et=new tt(ee),en=bind(tt.prototype.request,et);return eR.extend(en,tt.prototype,et,{allOwnKeys:!0}),eR.extend(en,et,null,{allOwnKeys:!0}),en.create=function(et){return createInstance(mergeConfig(ee,et))},en}let ta=createInstance(eG);ta.Axios=tt,ta.CanceledError=eQ,ta.CancelToken=tr,ta.isCancel=isCancel,ta.VERSION=e6,ta.toFormData=helpers_toFormData,ta.AxiosError=eM,ta.Cancel=ta.CanceledError,ta.all=function(ee){return Promise.all(ee)},ta.spread=spread,ta.isAxiosError=isAxiosError,ta.mergeConfig=mergeConfig,ta.AxiosHeaders=eX,ta.formToJSON=ee=>helpers_formDataToJSON(eR.isHTMLForm(ee)?new FormData(ee):ee),ta.getAdapter=e8.getAdapter,ta.HttpStatusCode=ti,ta.default=ta;var ts=ta},45595:function(ee,et,en){"use strict";en.r(et),en.d(et,{CompactEncrypt:function(){return CompactEncrypt},CompactSign:function(){return CompactSign},EmbeddedJWK:function(){return EmbeddedJWK},EncryptJWT:function(){return EncryptJWT},FlattenedEncrypt:function(){return FlattenedEncrypt},FlattenedSign:function(){return FlattenedSign},GeneralEncrypt:function(){return GeneralEncrypt},GeneralSign:function(){return GeneralSign},SignJWT:function(){return SignJWT},UnsecuredJWT:function(){return UnsecuredJWT},base64url:function(){return eo},calculateJwkThumbprint:function(){return calculateJwkThumbprint},calculateJwkThumbprintUri:function(){return calculateJwkThumbprintUri},compactDecrypt:function(){return compactDecrypt},compactVerify:function(){return compactVerify},createLocalJWKSet:function(){return createLocalJWKSet},createRemoteJWKSet:function(){return createRemoteJWKSet},cryptoRuntime:function(){return eB},decodeJwt:function(){return decodeJwt},decodeProtectedHeader:function(){return decodeProtectedHeader},errors:function(){return ei},exportJWK:function(){return exportJWK},exportPKCS8:function(){return exportPKCS8},exportSPKI:function(){return exportSPKI},flattenedDecrypt:function(){return flattenedDecrypt},flattenedVerify:function(){return flattenedVerify},generalDecrypt:function(){return generalDecrypt},generalVerify:function(){return generalVerify},generateKeyPair:function(){return generate_key_pair_generateKeyPair},generateSecret:function(){return generate_secret_generateSecret},importJWK:function(){return importJWK},importPKCS8:function(){return importPKCS8},importSPKI:function(){return importSPKI},importX509:function(){return importX509},jwtDecrypt:function(){return jwtDecrypt},jwtVerify:function(){return jwtVerify}});var ei={};en.r(ei),en.d(ei,{JOSEAlgNotAllowed:function(){return JOSEAlgNotAllowed},JOSEError:function(){return JOSEError},JOSENotSupported:function(){return JOSENotSupported},JWEDecompressionFailed:function(){return JWEDecompressionFailed},JWEDecryptionFailed:function(){return JWEDecryptionFailed},JWEInvalid:function(){return JWEInvalid},JWKInvalid:function(){return JWKInvalid},JWKSInvalid:function(){return JWKSInvalid},JWKSMultipleMatchingKeys:function(){return JWKSMultipleMatchingKeys},JWKSNoMatchingKey:function(){return JWKSNoMatchingKey},JWKSTimeout:function(){return JWKSTimeout},JWSInvalid:function(){return JWSInvalid},JWSSignatureVerificationFailed:function(){return JWSSignatureVerificationFailed},JWTClaimValidationFailed:function(){return JWTClaimValidationFailed},JWTExpired:function(){return JWTExpired},JWTInvalid:function(){return JWTInvalid}});var eo={};en.r(eo),en.d(eo,{decode:function(){return eD},encode:function(){return ej}});var ea=crypto;let isCryptoKey=ee=>ee instanceof CryptoKey,digest=async(ee,et)=>{let en=`SHA-${ee.slice(-3)}`;return new Uint8Array(await ea.subtle.digest(en,et))};var es=digest;let eu=new TextEncoder,ec=new TextDecoder,ed=4294967296;function concat(...ee){let et=ee.reduce((ee,{length:et})=>ee+et,0),en=new Uint8Array(et),ei=0;return ee.forEach(ee=>{en.set(ee,ei),ei+=ee.length}),en}function buffer_utils_p2s(ee,et){return concat(eu.encode(ee),new Uint8Array([0]),et)}function writeUInt32BE(ee,et,en){if(et<0||et>=ed)throw RangeError(`value must be >= 0 and <= ${ed-1}. Received ${et}`);ee.set([et>>>24,et>>>16,et>>>8,255&et],en)}function uint64be(ee){let et=Math.floor(ee/ed),en=ee%ed,ei=new Uint8Array(8);return writeUInt32BE(ei,et,0),writeUInt32BE(ei,en,4),ei}function uint32be(ee){let et=new Uint8Array(4);return writeUInt32BE(et,ee),et}function lengthAndInput(ee){return concat(uint32be(ee.length),ee)}async function concatKdf(ee,et,en){let ei=Math.ceil((et>>3)/32),eo=new Uint8Array(32*ei);for(let et=0;et>3)}let encodeBase64=ee=>{let et=ee;"string"==typeof et&&(et=eu.encode(et));let en=32768,ei=[];for(let ee=0;eeencodeBase64(ee).replace(/=/g,"").replace(/\+/g,"-").replace(/\//g,"_"),decodeBase64=ee=>{let et=atob(ee),en=new Uint8Array(et.length);for(let ee=0;ee{let et=ee;et instanceof Uint8Array&&(et=ec.decode(et)),et=et.replace(/-/g,"+").replace(/_/g,"/").replace(/\s/g,"");try{return decodeBase64(et)}catch(ee){throw TypeError("The input to be decoded is not correctly encoded.")}};let JOSEError=class JOSEError extends Error{static get code(){return"ERR_JOSE_GENERIC"}constructor(ee){var et;super(ee),this.code="ERR_JOSE_GENERIC",this.name=this.constructor.name,null===(et=Error.captureStackTrace)||void 0===et||et.call(Error,this,this.constructor)}};let JWTClaimValidationFailed=class JWTClaimValidationFailed extends JOSEError{static get code(){return"ERR_JWT_CLAIM_VALIDATION_FAILED"}constructor(ee,et="unspecified",en="unspecified"){super(ee),this.code="ERR_JWT_CLAIM_VALIDATION_FAILED",this.claim=et,this.reason=en}};let JWTExpired=class JWTExpired extends JOSEError{static get code(){return"ERR_JWT_EXPIRED"}constructor(ee,et="unspecified",en="unspecified"){super(ee),this.code="ERR_JWT_EXPIRED",this.claim=et,this.reason=en}};let JOSEAlgNotAllowed=class JOSEAlgNotAllowed extends JOSEError{constructor(){super(...arguments),this.code="ERR_JOSE_ALG_NOT_ALLOWED"}static get code(){return"ERR_JOSE_ALG_NOT_ALLOWED"}};let JOSENotSupported=class JOSENotSupported extends JOSEError{constructor(){super(...arguments),this.code="ERR_JOSE_NOT_SUPPORTED"}static get code(){return"ERR_JOSE_NOT_SUPPORTED"}};let JWEDecryptionFailed=class JWEDecryptionFailed extends JOSEError{constructor(){super(...arguments),this.code="ERR_JWE_DECRYPTION_FAILED",this.message="decryption operation failed"}static get code(){return"ERR_JWE_DECRYPTION_FAILED"}};let JWEDecompressionFailed=class JWEDecompressionFailed extends JOSEError{constructor(){super(...arguments),this.code="ERR_JWE_DECOMPRESSION_FAILED",this.message="decompression operation failed"}static get code(){return"ERR_JWE_DECOMPRESSION_FAILED"}};let JWEInvalid=class JWEInvalid extends JOSEError{constructor(){super(...arguments),this.code="ERR_JWE_INVALID"}static get code(){return"ERR_JWE_INVALID"}};let JWSInvalid=class JWSInvalid extends JOSEError{constructor(){super(...arguments),this.code="ERR_JWS_INVALID"}static get code(){return"ERR_JWS_INVALID"}};let JWTInvalid=class JWTInvalid extends JOSEError{constructor(){super(...arguments),this.code="ERR_JWT_INVALID"}static get code(){return"ERR_JWT_INVALID"}};let JWKInvalid=class JWKInvalid extends JOSEError{constructor(){super(...arguments),this.code="ERR_JWK_INVALID"}static get code(){return"ERR_JWK_INVALID"}};let JWKSInvalid=class JWKSInvalid extends JOSEError{constructor(){super(...arguments),this.code="ERR_JWKS_INVALID"}static get code(){return"ERR_JWKS_INVALID"}};let JWKSNoMatchingKey=class JWKSNoMatchingKey extends JOSEError{constructor(){super(...arguments),this.code="ERR_JWKS_NO_MATCHING_KEY",this.message="no applicable key found in the JSON Web Key Set"}static get code(){return"ERR_JWKS_NO_MATCHING_KEY"}};let JWKSMultipleMatchingKeys=class JWKSMultipleMatchingKeys extends JOSEError{constructor(){super(...arguments),this.code="ERR_JWKS_MULTIPLE_MATCHING_KEYS",this.message="multiple matching keys found in the JSON Web Key Set"}static get code(){return"ERR_JWKS_MULTIPLE_MATCHING_KEYS"}};let JWKSTimeout=class JWKSTimeout extends JOSEError{constructor(){super(...arguments),this.code="ERR_JWKS_TIMEOUT",this.message="request timed out"}static get code(){return"ERR_JWKS_TIMEOUT"}};let JWSSignatureVerificationFailed=class JWSSignatureVerificationFailed extends JOSEError{constructor(){super(...arguments),this.code="ERR_JWS_SIGNATURE_VERIFICATION_FAILED",this.message="signature verification failed"}static get code(){return"ERR_JWS_SIGNATURE_VERIFICATION_FAILED"}};var ef=ea.getRandomValues.bind(ea);function bitLength(ee){switch(ee){case"A128GCM":case"A128GCMKW":case"A192GCM":case"A192GCMKW":case"A256GCM":case"A256GCMKW":return 96;case"A128CBC-HS256":case"A192CBC-HS384":case"A256CBC-HS512":return 128;default:throw new JOSENotSupported(`Unsupported JWE Algorithm: ${ee}`)}}var lib_iv=ee=>ef(new Uint8Array(bitLength(ee)>>3));let checkIvLength=(ee,et)=>{if(et.length<<3!==bitLength(ee))throw new JWEInvalid("Invalid Initialization Vector length")};var ep=checkIvLength;let checkCekLength=(ee,et)=>{let en=ee.byteLength<<3;if(en!==et)throw new JWEInvalid(`Invalid Content Encryption Key length. Expected ${et} bits, got ${en} bits`)};var eh=checkCekLength;let timingSafeEqual=(ee,et)=>{if(!(ee instanceof Uint8Array))throw TypeError("First argument must be a buffer");if(!(et instanceof Uint8Array))throw TypeError("Second argument must be a buffer");if(ee.length!==et.length)throw TypeError("Input buffers must have the same length");let en=ee.length,ei=0,eo=-1;for(;++eoee.usages.includes(et))){let ee="CryptoKey does not support this operation, its usages must include ";if(et.length>2){let en=et.pop();ee+=`one of ${et.join(", ")}, or ${en}.`}else 2===et.length?ee+=`one of ${et[0]} or ${et[1]}.`:ee+=`${et[0]}.`;throw TypeError(ee)}}function checkSigCryptoKey(ee,et,...en){switch(et){case"HS256":case"HS384":case"HS512":{if(!isAlgorithm(ee.algorithm,"HMAC"))throw unusable("HMAC");let en=parseInt(et.slice(2),10),ei=getHashLength(ee.algorithm.hash);if(ei!==en)throw unusable(`SHA-${en}`,"algorithm.hash");break}case"RS256":case"RS384":case"RS512":{if(!isAlgorithm(ee.algorithm,"RSASSA-PKCS1-v1_5"))throw unusable("RSASSA-PKCS1-v1_5");let en=parseInt(et.slice(2),10),ei=getHashLength(ee.algorithm.hash);if(ei!==en)throw unusable(`SHA-${en}`,"algorithm.hash");break}case"PS256":case"PS384":case"PS512":{if(!isAlgorithm(ee.algorithm,"RSA-PSS"))throw unusable("RSA-PSS");let en=parseInt(et.slice(2),10),ei=getHashLength(ee.algorithm.hash);if(ei!==en)throw unusable(`SHA-${en}`,"algorithm.hash");break}case"EdDSA":if("Ed25519"!==ee.algorithm.name&&"Ed448"!==ee.algorithm.name)throw unusable("Ed25519 or Ed448");break;case"ES256":case"ES384":case"ES512":{if(!isAlgorithm(ee.algorithm,"ECDSA"))throw unusable("ECDSA");let en=getNamedCurve(et),ei=ee.algorithm.namedCurve;if(ei!==en)throw unusable(en,"algorithm.namedCurve");break}default:throw TypeError("CryptoKey does not support this operation")}checkUsage(ee,en)}function checkEncCryptoKey(ee,et,...en){switch(et){case"A128GCM":case"A192GCM":case"A256GCM":{if(!isAlgorithm(ee.algorithm,"AES-GCM"))throw unusable("AES-GCM");let en=parseInt(et.slice(1,4),10),ei=ee.algorithm.length;if(ei!==en)throw unusable(en,"algorithm.length");break}case"A128KW":case"A192KW":case"A256KW":{if(!isAlgorithm(ee.algorithm,"AES-KW"))throw unusable("AES-KW");let en=parseInt(et.slice(1,4),10),ei=ee.algorithm.length;if(ei!==en)throw unusable(en,"algorithm.length");break}case"ECDH":switch(ee.algorithm.name){case"ECDH":case"X25519":case"X448":break;default:throw unusable("ECDH, X25519, or X448")}break;case"PBES2-HS256+A128KW":case"PBES2-HS384+A192KW":case"PBES2-HS512+A256KW":if(!isAlgorithm(ee.algorithm,"PBKDF2"))throw unusable("PBKDF2");break;case"RSA-OAEP":case"RSA-OAEP-256":case"RSA-OAEP-384":case"RSA-OAEP-512":{if(!isAlgorithm(ee.algorithm,"RSA-OAEP"))throw unusable("RSA-OAEP");let en=parseInt(et.slice(9),10)||1,ei=getHashLength(ee.algorithm.hash);if(ei!==en)throw unusable(`SHA-${en}`,"algorithm.hash");break}default:throw TypeError("CryptoKey does not support this operation")}checkUsage(ee,en)}function message(ee,et,...en){if(en.length>2){let et=en.pop();ee+=`one of type ${en.join(", ")}, or ${et}.`}else 2===en.length?ee+=`one of type ${en[0]} or ${en[1]}.`:ee+=`of type ${en[0]}.`;return null==et?ee+=` Received ${et}`:"function"==typeof et&&et.name?ee+=` Received function ${et.name}`:"object"==typeof et&&null!=et&&et.constructor&&et.constructor.name&&(ee+=` Received an instance of ${et.constructor.name}`),ee}var invalid_key_input=(ee,...et)=>message("Key must be ",ee,...et);function withAlg(ee,et,...en){return message(`Key for the ${ee} algorithm must be `,et,...en)}var is_key_like=ee=>isCryptoKey(ee);let em=["CryptoKey"];async function cbcDecrypt(ee,et,en,ei,eo,es){let eu,ec;if(!(et instanceof Uint8Array))throw TypeError(invalid_key_input(et,"Uint8Array"));let ed=parseInt(ee.slice(1,4),10),ef=await ea.subtle.importKey("raw",et.subarray(ed>>3),"AES-CBC",!1,["decrypt"]),ep=await ea.subtle.importKey("raw",et.subarray(0,ed>>3),{hash:`SHA-${ed<<1}`,name:"HMAC"},!1,["sign"]),eh=concat(es,ei,en,uint64be(es.length<<3)),em=new Uint8Array((await ea.subtle.sign("HMAC",ep,eh)).slice(0,ed>>3));try{eu=ey(eo,em)}catch(ee){}if(!eu)throw new JWEDecryptionFailed;try{ec=new Uint8Array(await ea.subtle.decrypt({iv:ei,name:"AES-CBC"},ef,en))}catch(ee){}if(!ec)throw new JWEDecryptionFailed;return ec}async function gcmDecrypt(ee,et,en,ei,eo,es){let eu;et instanceof Uint8Array?eu=await ea.subtle.importKey("raw",et,"AES-GCM",!1,["decrypt"]):(checkEncCryptoKey(et,ee,"decrypt"),eu=et);try{return new Uint8Array(await ea.subtle.decrypt({additionalData:es,iv:ei,name:"AES-GCM",tagLength:128},eu,concat(en,eo)))}catch(ee){throw new JWEDecryptionFailed}}let decrypt=async(ee,et,en,ei,eo,ea)=>{if(!isCryptoKey(et)&&!(et instanceof Uint8Array))throw TypeError(invalid_key_input(et,...em,"Uint8Array"));switch(ep(ee,ei),ee){case"A128CBC-HS256":case"A192CBC-HS384":case"A256CBC-HS512":return et instanceof Uint8Array&&eh(et,parseInt(ee.slice(-3),10)),cbcDecrypt(ee,et,en,ei,eo,ea);case"A128GCM":case"A192GCM":case"A256GCM":return et instanceof Uint8Array&&eh(et,parseInt(ee.slice(1,4),10)),gcmDecrypt(ee,et,en,ei,eo,ea);default:throw new JOSENotSupported("Unsupported JWE Content Encryption Algorithm")}};var eg=decrypt;let inflate=async()=>{throw new JOSENotSupported('JWE "zip" (Compression Algorithm) Header Parameter is not supported by your javascript runtime. You need to use the `inflateRaw` decrypt option to provide Inflate Raw implementation.')},deflate=async()=>{throw new JOSENotSupported('JWE "zip" (Compression Algorithm) Header Parameter is not supported by your javascript runtime. You need to use the `deflateRaw` encrypt option to provide Deflate Raw implementation.')},isDisjoint=(...ee)=>{let et;let en=ee.filter(Boolean);if(0===en.length||1===en.length)return!0;for(let ee of en){let en=Object.keys(ee);if(!et||0===et.size){et=new Set(en);continue}for(let ee of en){if(et.has(ee))return!1;et.add(ee)}}return!0};var eb=isDisjoint;function isObjectLike(ee){return"object"==typeof ee&&null!==ee}function isObject(ee){if(!isObjectLike(ee)||"[object Object]"!==Object.prototype.toString.call(ee))return!1;if(null===Object.getPrototypeOf(ee))return!0;let et=ee;for(;null!==Object.getPrototypeOf(et);)et=Object.getPrototypeOf(et);return Object.getPrototypeOf(ee)===et}let ev=[{hash:"SHA-256",name:"HMAC"},!0,["sign"]];var e_=ev;function checkKeySize(ee,et){if(ee.algorithm.length!==parseInt(et.slice(1,4),10))throw TypeError(`Invalid key size for alg: ${et}`)}function getCryptoKey(ee,et,en){if(isCryptoKey(ee))return checkEncCryptoKey(ee,et,en),ee;if(ee instanceof Uint8Array)return ea.subtle.importKey("raw",ee,"AES-KW",!0,[en]);throw TypeError(invalid_key_input(ee,...em,"Uint8Array"))}let wrap=async(ee,et,en)=>{let ei=await getCryptoKey(et,ee,"wrapKey");checkKeySize(ei,ee);let eo=await ea.subtle.importKey("raw",en,...e_);return new Uint8Array(await ea.subtle.wrapKey("raw",eo,ei,"AES-KW"))},unwrap=async(ee,et,en)=>{let ei=await getCryptoKey(et,ee,"unwrapKey");checkKeySize(ei,ee);let eo=await ea.subtle.unwrapKey("raw",en,ei,"AES-KW",...e_);return new Uint8Array(await ea.subtle.exportKey("raw",eo))};async function deriveKey(ee,et,en,ei,eo=new Uint8Array(0),es=new Uint8Array(0)){let ec;if(!isCryptoKey(ee))throw TypeError(invalid_key_input(ee,...em));if(checkEncCryptoKey(ee,"ECDH"),!isCryptoKey(et))throw TypeError(invalid_key_input(et,...em));checkEncCryptoKey(et,"ECDH","deriveBits");let ed=concat(lengthAndInput(eu.encode(en)),lengthAndInput(eo),lengthAndInput(es),uint32be(ei));ec="X25519"===ee.algorithm.name?256:"X448"===ee.algorithm.name?448:Math.ceil(parseInt(ee.algorithm.namedCurve.substr(-3),10)/8)<<3;let ef=new Uint8Array(await ea.subtle.deriveBits({name:ee.algorithm.name,public:ee},et,ec));return concatKdf(ef,ei,ed)}async function generateEpk(ee){if(!isCryptoKey(ee))throw TypeError(invalid_key_input(ee,...em));return ea.subtle.generateKey(ee.algorithm,!0,["deriveBits"])}function ecdhAllowed(ee){if(!isCryptoKey(ee))throw TypeError(invalid_key_input(ee,...em));return["P-256","P-384","P-521"].includes(ee.algorithm.namedCurve)||"X25519"===ee.algorithm.name||"X448"===ee.algorithm.name}function checkP2s(ee){if(!(ee instanceof Uint8Array)||ee.length<8)throw new JWEInvalid("PBES2 Salt Input must be 8 or more octets")}function pbes2kw_getCryptoKey(ee,et){if(ee instanceof Uint8Array)return ea.subtle.importKey("raw",ee,"PBKDF2",!1,["deriveBits"]);if(isCryptoKey(ee))return checkEncCryptoKey(ee,et,"deriveBits","deriveKey"),ee;throw TypeError(invalid_key_input(ee,...em,"Uint8Array"))}async function pbes2kw_deriveKey(ee,et,en,ei){checkP2s(ee);let eo=buffer_utils_p2s(et,ee),es=parseInt(et.slice(13,16),10),eu={hash:`SHA-${et.slice(8,11)}`,iterations:en,name:"PBKDF2",salt:eo},ec={length:es,name:"AES-KW"},ed=await pbes2kw_getCryptoKey(ei,et);if(ed.usages.includes("deriveBits"))return new Uint8Array(await ea.subtle.deriveBits(eu,ed,es));if(ed.usages.includes("deriveKey"))return ea.subtle.deriveKey(eu,ed,ec,!1,["wrapKey","unwrapKey"]);throw TypeError('PBKDF2 key "usages" must include "deriveBits" or "deriveKey"')}let encrypt=async(ee,et,en,ei=2048,eo=ef(new Uint8Array(16)))=>{let ea=await pbes2kw_deriveKey(eo,ee,ei,et),es=await wrap(ee.slice(-6),ea,en);return{encryptedKey:es,p2c:ei,p2s:encode(eo)}},pbes2kw_decrypt=async(ee,et,en,ei,eo)=>{let ea=await pbes2kw_deriveKey(eo,ee,ei,et);return unwrap(ee.slice(-6),ea,en)};function subtleRsaEs(ee){switch(ee){case"RSA-OAEP":case"RSA-OAEP-256":case"RSA-OAEP-384":case"RSA-OAEP-512":return"RSA-OAEP";default:throw new JOSENotSupported(`alg ${ee} is not supported either by JOSE or your javascript runtime`)}}var check_key_length=(ee,et)=>{if(ee.startsWith("RS")||ee.startsWith("PS")){let{modulusLength:en}=et.algorithm;if("number"!=typeof en||en<2048)throw TypeError(`${ee} requires key modulusLength to be 2048 bits or larger`)}};let rsaes_encrypt=async(ee,et,en)=>{if(!isCryptoKey(et))throw TypeError(invalid_key_input(et,...em));if(checkEncCryptoKey(et,ee,"encrypt","wrapKey"),check_key_length(ee,et),et.usages.includes("encrypt"))return new Uint8Array(await ea.subtle.encrypt(subtleRsaEs(ee),et,en));if(et.usages.includes("wrapKey")){let ei=await ea.subtle.importKey("raw",en,...e_);return new Uint8Array(await ea.subtle.wrapKey("raw",ei,et,subtleRsaEs(ee)))}throw TypeError('RSA-OAEP key "usages" must include "encrypt" or "wrapKey" for this operation')},rsaes_decrypt=async(ee,et,en)=>{if(!isCryptoKey(et))throw TypeError(invalid_key_input(et,...em));if(checkEncCryptoKey(et,ee,"decrypt","unwrapKey"),check_key_length(ee,et),et.usages.includes("decrypt"))return new Uint8Array(await ea.subtle.decrypt(subtleRsaEs(ee),et,en));if(et.usages.includes("unwrapKey")){let ei=await ea.subtle.unwrapKey("raw",en,et,subtleRsaEs(ee),...e_);return new Uint8Array(await ea.subtle.exportKey("raw",ei))}throw TypeError('RSA-OAEP key "usages" must include "decrypt" or "unwrapKey" for this operation')};function cek_bitLength(ee){switch(ee){case"A128GCM":return 128;case"A192GCM":return 192;case"A256GCM":case"A128CBC-HS256":return 256;case"A192CBC-HS384":return 384;case"A256CBC-HS512":return 512;default:throw new JOSENotSupported(`Unsupported JWE Algorithm: ${ee}`)}}var lib_cek=ee=>ef(new Uint8Array(cek_bitLength(ee)>>3)),format_pem=(ee,et)=>{let en=(ee.match(/.{1,64}/g)||[]).join("\n");return`-----BEGIN ${et}----- ${en} -----END ${et}-----`};let genericExport=async(ee,et,en)=>{if(!isCryptoKey(en))throw TypeError(invalid_key_input(en,...em));if(!en.extractable)throw TypeError("CryptoKey is not extractable");if(en.type!==ee)throw TypeError(`key is not a ${ee} key`);return format_pem(encodeBase64(new Uint8Array(await ea.subtle.exportKey(et,en))),`${ee.toUpperCase()} KEY`)},toSPKI=ee=>genericExport("public","spki",ee),toPKCS8=ee=>genericExport("private","pkcs8",ee),findOid=(ee,et,en=0)=>{0===en&&(et.unshift(et.length),et.unshift(6));let ei=ee.indexOf(et[0],en);if(-1===ei)return!1;let eo=ee.subarray(ei,ei+et.length);return eo.length===et.length&&(eo.every((ee,en)=>ee===et[en])||findOid(ee,et,ei+1))},asn1_getNamedCurve=ee=>{switch(!0){case findOid(ee,[42,134,72,206,61,3,1,7]):return"P-256";case findOid(ee,[43,129,4,0,34]):return"P-384";case findOid(ee,[43,129,4,0,35]):return"P-521";case findOid(ee,[43,101,110]):return"X25519";case findOid(ee,[43,101,111]):return"X448";case findOid(ee,[43,101,112]):return"Ed25519";case findOid(ee,[43,101,113]):return"Ed448";default:throw new JOSENotSupported("Invalid or unsupported EC Key Curve or OKP Key Sub Type")}},genericImport=async(ee,et,en,ei,eo)=>{var es;let eu,ec;let ed=new Uint8Array(atob(en.replace(ee,"")).split("").map(ee=>ee.charCodeAt(0))),ef="spki"===et;switch(ei){case"PS256":case"PS384":case"PS512":eu={name:"RSA-PSS",hash:`SHA-${ei.slice(-3)}`},ec=ef?["verify"]:["sign"];break;case"RS256":case"RS384":case"RS512":eu={name:"RSASSA-PKCS1-v1_5",hash:`SHA-${ei.slice(-3)}`},ec=ef?["verify"]:["sign"];break;case"RSA-OAEP":case"RSA-OAEP-256":case"RSA-OAEP-384":case"RSA-OAEP-512":eu={name:"RSA-OAEP",hash:`SHA-${parseInt(ei.slice(-3),10)||1}`},ec=ef?["encrypt","wrapKey"]:["decrypt","unwrapKey"];break;case"ES256":eu={name:"ECDSA",namedCurve:"P-256"},ec=ef?["verify"]:["sign"];break;case"ES384":eu={name:"ECDSA",namedCurve:"P-384"},ec=ef?["verify"]:["sign"];break;case"ES512":eu={name:"ECDSA",namedCurve:"P-521"},ec=ef?["verify"]:["sign"];break;case"ECDH-ES":case"ECDH-ES+A128KW":case"ECDH-ES+A192KW":case"ECDH-ES+A256KW":{let ee=asn1_getNamedCurve(ed);eu=ee.startsWith("P-")?{name:"ECDH",namedCurve:ee}:{name:ee},ec=ef?[]:["deriveBits"];break}case"EdDSA":eu={name:asn1_getNamedCurve(ed)},ec=ef?["verify"]:["sign"];break;default:throw new JOSENotSupported('Invalid or unsupported "alg" (Algorithm) value')}return ea.subtle.importKey(et,ed,eu,null!==(es=null==eo?void 0:eo.extractable)&&void 0!==es&&es,ec)},fromPKCS8=(ee,et,en)=>genericImport(/(?:-----(?:BEGIN|END) PRIVATE KEY-----|\s)/g,"pkcs8",ee,et,en),fromSPKI=(ee,et,en)=>genericImport(/(?:-----(?:BEGIN|END) PUBLIC KEY-----|\s)/g,"spki",ee,et,en);function getElement(ee){let et=[],en=0;for(;en=128;)en=128*en+ee[et]-128,et++;en=128*en+ee[et]-128,et++}let ei=0;if(ee[et]<128)ei=ee[et],et++;else if(128===ei){for(ei=0;0!==ee[et+ei]||0!==ee[et+ei+1];){if(ei>ee.byteLength)throw TypeError("invalid indefinite form length");ei++}let en=et+ei+2;return{byteLength:en,contents:ee.subarray(et,et+ei),raw:ee.subarray(0,en)}}else{let en=127&ee[et];et++,ei=0;for(let eo=0;eo{let ei;try{ei=getSPKI(ee)}catch(ee){throw TypeError("Failed to parse the X.509 certificate",{cause:ee})}return fromSPKI(ei,et,en)};function subtleMapping(ee){let et,en;switch(ee.kty){case"oct":switch(ee.alg){case"HS256":case"HS384":case"HS512":et={name:"HMAC",hash:`SHA-${ee.alg.slice(-3)}`},en=["sign","verify"];break;case"A128CBC-HS256":case"A192CBC-HS384":case"A256CBC-HS512":throw new JOSENotSupported(`${ee.alg} keys cannot be imported as CryptoKey instances`);case"A128GCM":case"A192GCM":case"A256GCM":case"A128GCMKW":case"A192GCMKW":case"A256GCMKW":et={name:"AES-GCM"},en=["encrypt","decrypt"];break;case"A128KW":case"A192KW":case"A256KW":et={name:"AES-KW"},en=["wrapKey","unwrapKey"];break;case"PBES2-HS256+A128KW":case"PBES2-HS384+A192KW":case"PBES2-HS512+A256KW":et={name:"PBKDF2"},en=["deriveBits"];break;default:throw new JOSENotSupported('Invalid or unsupported JWK "alg" (Algorithm) Parameter value')}break;case"RSA":switch(ee.alg){case"PS256":case"PS384":case"PS512":et={name:"RSA-PSS",hash:`SHA-${ee.alg.slice(-3)}`},en=ee.d?["sign"]:["verify"];break;case"RS256":case"RS384":case"RS512":et={name:"RSASSA-PKCS1-v1_5",hash:`SHA-${ee.alg.slice(-3)}`},en=ee.d?["sign"]:["verify"];break;case"RSA-OAEP":case"RSA-OAEP-256":case"RSA-OAEP-384":case"RSA-OAEP-512":et={name:"RSA-OAEP",hash:`SHA-${parseInt(ee.alg.slice(-3),10)||1}`},en=ee.d?["decrypt","unwrapKey"]:["encrypt","wrapKey"];break;default:throw new JOSENotSupported('Invalid or unsupported JWK "alg" (Algorithm) Parameter value')}break;case"EC":switch(ee.alg){case"ES256":et={name:"ECDSA",namedCurve:"P-256"},en=ee.d?["sign"]:["verify"];break;case"ES384":et={name:"ECDSA",namedCurve:"P-384"},en=ee.d?["sign"]:["verify"];break;case"ES512":et={name:"ECDSA",namedCurve:"P-521"},en=ee.d?["sign"]:["verify"];break;case"ECDH-ES":case"ECDH-ES+A128KW":case"ECDH-ES+A192KW":case"ECDH-ES+A256KW":et={name:"ECDH",namedCurve:ee.crv},en=ee.d?["deriveBits"]:[];break;default:throw new JOSENotSupported('Invalid or unsupported JWK "alg" (Algorithm) Parameter value')}break;case"OKP":switch(ee.alg){case"EdDSA":et={name:ee.crv},en=ee.d?["sign"]:["verify"];break;case"ECDH-ES":case"ECDH-ES+A128KW":case"ECDH-ES+A192KW":case"ECDH-ES+A256KW":et={name:ee.crv},en=ee.d?["deriveBits"]:[];break;default:throw new JOSENotSupported('Invalid or unsupported JWK "alg" (Algorithm) Parameter value')}break;default:throw new JOSENotSupported('Invalid or unsupported JWK "kty" (Key Type) Parameter value')}return{algorithm:et,keyUsages:en}}let parse=async ee=>{var et,en;if(!ee.alg)throw TypeError('"alg" argument is required when "jwk.alg" is not present');let{algorithm:ei,keyUsages:eo}=subtleMapping(ee),es=[ei,null!==(et=ee.ext)&&void 0!==et&&et,null!==(en=ee.key_ops)&&void 0!==en?en:eo];if("PBKDF2"===ei.name)return ea.subtle.importKey("raw",decode(ee.k),...es);let eu={...ee};return delete eu.alg,delete eu.use,ea.subtle.importKey("jwk",eu,...es)};var ew=parse;async function importSPKI(ee,et,en){if("string"!=typeof ee||0!==ee.indexOf("-----BEGIN PUBLIC KEY-----"))throw TypeError('"spki" must be SPKI formatted string');return fromSPKI(ee,et,en)}async function importX509(ee,et,en){if("string"!=typeof ee||0!==ee.indexOf("-----BEGIN CERTIFICATE-----"))throw TypeError('"x509" must be X.509 formatted string');return fromX509(ee,et,en)}async function importPKCS8(ee,et,en){if("string"!=typeof ee||0!==ee.indexOf("-----BEGIN PRIVATE KEY-----"))throw TypeError('"pkcs8" must be PKCS#8 formatted string');return fromPKCS8(ee,et,en)}async function importJWK(ee,et,en){var ei;if(!isObject(ee))throw TypeError("JWK must be an object");switch(et||(et=ee.alg),ee.kty){case"oct":if("string"!=typeof ee.k||!ee.k)throw TypeError('missing "k" (Key Value) Parameter value');if(null!=en||(en=!0!==ee.ext),en)return ew({...ee,alg:et,ext:null!==(ei=ee.ext)&&void 0!==ei&&ei});return decode(ee.k);case"RSA":if(void 0!==ee.oth)throw new JOSENotSupported('RSA JWK "oth" (Other Primes Info) Parameter value is not supported');case"EC":case"OKP":return ew({...ee,alg:et});default:throw new JOSENotSupported('Unsupported "kty" (Key Type) Parameter value')}}let symmetricTypeCheck=(ee,et)=>{if(!(et instanceof Uint8Array)){if(!is_key_like(et))throw TypeError(withAlg(ee,et,...em,"Uint8Array"));if("secret"!==et.type)throw TypeError(`${em.join(" or ")} instances for symmetric algorithms must be of type "secret"`)}},asymmetricTypeCheck=(ee,et,en)=>{if(!is_key_like(et))throw TypeError(withAlg(ee,et,...em));if("secret"===et.type)throw TypeError(`${em.join(" or ")} instances for asymmetric algorithms must not be of type "secret"`);if("sign"===en&&"public"===et.type)throw TypeError(`${em.join(" or ")} instances for asymmetric algorithm signing must be of type "private"`);if("decrypt"===en&&"public"===et.type)throw TypeError(`${em.join(" or ")} instances for asymmetric algorithm decryption must be of type "private"`);if(et.algorithm&&"verify"===en&&"private"===et.type)throw TypeError(`${em.join(" or ")} instances for asymmetric algorithm verifying must be of type "public"`);if(et.algorithm&&"encrypt"===en&&"private"===et.type)throw TypeError(`${em.join(" or ")} instances for asymmetric algorithm encryption must be of type "public"`)},checkKeyType=(ee,et,en)=>{let ei=ee.startsWith("HS")||"dir"===ee||ee.startsWith("PBES2")||/^A\d{3}(?:GCM)?KW$/.test(ee);ei?symmetricTypeCheck(ee,et):asymmetricTypeCheck(ee,et,en)};var eS=checkKeyType;async function cbcEncrypt(ee,et,en,ei,eo){if(!(en instanceof Uint8Array))throw TypeError(invalid_key_input(en,"Uint8Array"));let es=parseInt(ee.slice(1,4),10),eu=await ea.subtle.importKey("raw",en.subarray(es>>3),"AES-CBC",!1,["encrypt"]),ec=await ea.subtle.importKey("raw",en.subarray(0,es>>3),{hash:`SHA-${es<<1}`,name:"HMAC"},!1,["sign"]),ed=new Uint8Array(await ea.subtle.encrypt({iv:ei,name:"AES-CBC"},eu,et)),ef=concat(eo,ei,ed,uint64be(eo.length<<3)),ep=new Uint8Array((await ea.subtle.sign("HMAC",ec,ef)).slice(0,es>>3));return{ciphertext:ed,tag:ep}}async function gcmEncrypt(ee,et,en,ei,eo){let es;en instanceof Uint8Array?es=await ea.subtle.importKey("raw",en,"AES-GCM",!1,["encrypt"]):(checkEncCryptoKey(en,ee,"encrypt"),es=en);let eu=new Uint8Array(await ea.subtle.encrypt({additionalData:eo,iv:ei,name:"AES-GCM",tagLength:128},es,et)),ec=eu.slice(-16),ed=eu.slice(0,-16);return{ciphertext:ed,tag:ec}}let encrypt_encrypt=async(ee,et,en,ei,eo)=>{if(!isCryptoKey(en)&&!(en instanceof Uint8Array))throw TypeError(invalid_key_input(en,...em,"Uint8Array"));switch(ep(ee,ei),ee){case"A128CBC-HS256":case"A192CBC-HS384":case"A256CBC-HS512":return en instanceof Uint8Array&&eh(en,parseInt(ee.slice(-3),10)),cbcEncrypt(ee,et,en,ei,eo);case"A128GCM":case"A192GCM":case"A256GCM":return en instanceof Uint8Array&&eh(en,parseInt(ee.slice(1,4),10)),gcmEncrypt(ee,et,en,ei,eo);default:throw new JOSENotSupported("Unsupported JWE Content Encryption Algorithm")}};var eE=encrypt_encrypt;async function aesgcmkw_wrap(ee,et,en,ei){let eo=ee.slice(0,7);ei||(ei=lib_iv(eo));let{ciphertext:ea,tag:es}=await eE(eo,en,et,ei,new Uint8Array(0));return{encryptedKey:ea,iv:encode(ei),tag:encode(es)}}async function aesgcmkw_unwrap(ee,et,en,ei,eo){let ea=ee.slice(0,7);return eg(ea,et,en,ei,eo,new Uint8Array(0))}var decrypt_key_management=async function(ee,et,en,ei,eo){switch(eS(ee,et,"decrypt"),ee){case"dir":if(void 0!==en)throw new JWEInvalid("Encountered unexpected JWE Encrypted Key");return et;case"ECDH-ES":if(void 0!==en)throw new JWEInvalid("Encountered unexpected JWE Encrypted Key");case"ECDH-ES+A128KW":case"ECDH-ES+A192KW":case"ECDH-ES+A256KW":{let eo,ea;if(!isObject(ei.epk))throw new JWEInvalid('JOSE Header "epk" (Ephemeral Public Key) missing or invalid');if(!ecdhAllowed(et))throw new JOSENotSupported("ECDH with the provided key is not allowed or not supported by your javascript runtime");let es=await importJWK(ei.epk,ee);if(void 0!==ei.apu){if("string"!=typeof ei.apu)throw new JWEInvalid('JOSE Header "apu" (Agreement PartyUInfo) invalid');try{eo=decode(ei.apu)}catch(ee){throw new JWEInvalid("Failed to base64url decode the apu")}}if(void 0!==ei.apv){if("string"!=typeof ei.apv)throw new JWEInvalid('JOSE Header "apv" (Agreement PartyVInfo) invalid');try{ea=decode(ei.apv)}catch(ee){throw new JWEInvalid("Failed to base64url decode the apv")}}let eu=await deriveKey(es,et,"ECDH-ES"===ee?ei.enc:ee,"ECDH-ES"===ee?cek_bitLength(ei.enc):parseInt(ee.slice(-5,-2),10),eo,ea);if("ECDH-ES"===ee)return eu;if(void 0===en)throw new JWEInvalid("JWE Encrypted Key missing");return unwrap(ee.slice(-6),eu,en)}case"RSA1_5":case"RSA-OAEP":case"RSA-OAEP-256":case"RSA-OAEP-384":case"RSA-OAEP-512":if(void 0===en)throw new JWEInvalid("JWE Encrypted Key missing");return rsaes_decrypt(ee,et,en);case"PBES2-HS256+A128KW":case"PBES2-HS384+A192KW":case"PBES2-HS512+A256KW":{let ea;if(void 0===en)throw new JWEInvalid("JWE Encrypted Key missing");if("number"!=typeof ei.p2c)throw new JWEInvalid('JOSE Header "p2c" (PBES2 Count) missing or invalid');let es=(null==eo?void 0:eo.maxPBES2Count)||1e4;if(ei.p2c>es)throw new JWEInvalid('JOSE Header "p2c" (PBES2 Count) out is of acceptable bounds');if("string"!=typeof ei.p2s)throw new JWEInvalid('JOSE Header "p2s" (PBES2 Salt) missing or invalid');try{ea=decode(ei.p2s)}catch(ee){throw new JWEInvalid("Failed to base64url decode the p2s")}return pbes2kw_decrypt(ee,et,en,ei.p2c,ea)}case"A128KW":case"A192KW":case"A256KW":if(void 0===en)throw new JWEInvalid("JWE Encrypted Key missing");return unwrap(ee,et,en);case"A128GCMKW":case"A192GCMKW":case"A256GCMKW":{let eo,ea;if(void 0===en)throw new JWEInvalid("JWE Encrypted Key missing");if("string"!=typeof ei.iv)throw new JWEInvalid('JOSE Header "iv" (Initialization Vector) missing or invalid');if("string"!=typeof ei.tag)throw new JWEInvalid('JOSE Header "tag" (Authentication Tag) missing or invalid');try{eo=decode(ei.iv)}catch(ee){throw new JWEInvalid("Failed to base64url decode the iv")}try{ea=decode(ei.tag)}catch(ee){throw new JWEInvalid("Failed to base64url decode the tag")}return aesgcmkw_unwrap(ee,et,en,eo,ea)}default:throw new JOSENotSupported('Invalid or unsupported "alg" (JWE Algorithm) header value')}},validate_crit=function(ee,et,en,ei,eo){let ea;if(void 0!==eo.crit&&void 0===ei.crit)throw new ee('"crit" (Critical) Header Parameter MUST be integrity protected');if(!ei||void 0===ei.crit)return new Set;if(!Array.isArray(ei.crit)||0===ei.crit.length||ei.crit.some(ee=>"string"!=typeof ee||0===ee.length))throw new ee('"crit" (Critical) Header Parameter MUST be an array of non-empty strings when present');for(let es of(ea=void 0!==en?new Map([...Object.entries(en),...et.entries()]):et,ei.crit)){if(!ea.has(es))throw new JOSENotSupported(`Extension Header Parameter "${es}" is not recognized`);if(void 0===eo[es])throw new ee(`Extension Header Parameter "${es}" is missing`);if(ea.get(es)&&void 0===ei[es])throw new ee(`Extension Header Parameter "${es}" MUST be integrity protected`)}return new Set(ei.crit)};let validateAlgorithms=(ee,et)=>{if(void 0!==et&&(!Array.isArray(et)||et.some(ee=>"string"!=typeof ee)))throw TypeError(`"${ee}" option must be an array of strings`);if(et)return new Set(et)};var eA=validateAlgorithms;async function flattenedDecrypt(ee,et,en){var ei;let eo,ea,es,ed,ef,ep,eh;if(!isObject(ee))throw new JWEInvalid("Flattened JWE must be an object");if(void 0===ee.protected&&void 0===ee.header&&void 0===ee.unprotected)throw new JWEInvalid("JOSE Header missing");if("string"!=typeof ee.iv)throw new JWEInvalid("JWE Initialization Vector missing or incorrect type");if("string"!=typeof ee.ciphertext)throw new JWEInvalid("JWE Ciphertext missing or incorrect type");if("string"!=typeof ee.tag)throw new JWEInvalid("JWE Authentication Tag missing or incorrect type");if(void 0!==ee.protected&&"string"!=typeof ee.protected)throw new JWEInvalid("JWE Protected Header incorrect type");if(void 0!==ee.encrypted_key&&"string"!=typeof ee.encrypted_key)throw new JWEInvalid("JWE Encrypted Key incorrect type");if(void 0!==ee.aad&&"string"!=typeof ee.aad)throw new JWEInvalid("JWE AAD incorrect type");if(void 0!==ee.header&&!isObject(ee.header))throw new JWEInvalid("JWE Shared Unprotected Header incorrect type");if(void 0!==ee.unprotected&&!isObject(ee.unprotected))throw new JWEInvalid("JWE Per-Recipient Unprotected Header incorrect type");if(ee.protected)try{let et=decode(ee.protected);eo=JSON.parse(ec.decode(et))}catch(ee){throw new JWEInvalid("JWE Protected Header is invalid")}if(!eb(eo,ee.header,ee.unprotected))throw new JWEInvalid("JWE Protected, JWE Unprotected Header, and JWE Per-Recipient Unprotected Header Parameter names must be disjoint");let ey={...eo,...ee.header,...ee.unprotected};if(validate_crit(JWEInvalid,new Map,null==en?void 0:en.crit,eo,ey),void 0!==ey.zip){if(!eo||!eo.zip)throw new JWEInvalid('JWE "zip" (Compression Algorithm) Header MUST be integrity protected');if("DEF"!==ey.zip)throw new JOSENotSupported('Unsupported JWE "zip" (Compression Algorithm) Header Parameter value')}let{alg:em,enc:ev}=ey;if("string"!=typeof em||!em)throw new JWEInvalid("missing JWE Algorithm (alg) in JWE Header");if("string"!=typeof ev||!ev)throw new JWEInvalid("missing JWE Encryption Algorithm (enc) in JWE Header");let e_=en&&eA("keyManagementAlgorithms",en.keyManagementAlgorithms),ew=en&&eA("contentEncryptionAlgorithms",en.contentEncryptionAlgorithms);if(e_&&!e_.has(em))throw new JOSEAlgNotAllowed('"alg" (Algorithm) Header Parameter not allowed');if(ew&&!ew.has(ev))throw new JOSEAlgNotAllowed('"enc" (Encryption Algorithm) Header Parameter not allowed');if(void 0!==ee.encrypted_key)try{ea=decode(ee.encrypted_key)}catch(ee){throw new JWEInvalid("Failed to base64url decode the encrypted_key")}let eS=!1;"function"==typeof et&&(et=await et(eo,ee),eS=!0);try{es=await decrypt_key_management(em,et,ea,ey,en)}catch(ee){if(ee instanceof TypeError||ee instanceof JWEInvalid||ee instanceof JOSENotSupported)throw ee;es=lib_cek(ev)}try{ed=decode(ee.iv)}catch(ee){throw new JWEInvalid("Failed to base64url decode the iv")}try{ef=decode(ee.tag)}catch(ee){throw new JWEInvalid("Failed to base64url decode the tag")}let eE=eu.encode(null!==(ei=ee.protected)&&void 0!==ei?ei:"");ep=void 0!==ee.aad?concat(eE,eu.encode("."),eu.encode(ee.aad)):eE;try{eh=decode(ee.ciphertext)}catch(ee){throw new JWEInvalid("Failed to base64url decode the ciphertext")}let e$=await eg(ev,es,eh,ed,ef,ep);"DEF"===ey.zip&&(e$=await ((null==en?void 0:en.inflateRaw)||inflate)(e$));let ex={plaintext:e$};if(void 0!==ee.protected&&(ex.protectedHeader=eo),void 0!==ee.aad)try{ex.additionalAuthenticatedData=decode(ee.aad)}catch(ee){throw new JWEInvalid("Failed to base64url decode the aad")}return(void 0!==ee.unprotected&&(ex.sharedUnprotectedHeader=ee.unprotected),void 0!==ee.header&&(ex.unprotectedHeader=ee.header),eS)?{...ex,key:et}:ex}async function compactDecrypt(ee,et,en){if(ee instanceof Uint8Array&&(ee=ec.decode(ee)),"string"!=typeof ee)throw new JWEInvalid("Compact JWE must be a string or Uint8Array");let{0:ei,1:eo,2:ea,3:es,4:eu,length:ed}=ee.split(".");if(5!==ed)throw new JWEInvalid("Invalid Compact JWE");let ef=await flattenedDecrypt({ciphertext:es,iv:ea||void 0,protected:ei||void 0,tag:eu||void 0,encrypted_key:eo||void 0},et,en),ep={plaintext:ef.plaintext,protectedHeader:ef.protectedHeader};return"function"==typeof et?{...ep,key:ef.key}:ep}async function generalDecrypt(ee,et,en){if(!isObject(ee))throw new JWEInvalid("General JWE must be an object");if(!Array.isArray(ee.recipients)||!ee.recipients.every(isObject))throw new JWEInvalid("JWE Recipients missing or incorrect type");if(!ee.recipients.length)throw new JWEInvalid("JWE Recipients has no members");for(let ei of ee.recipients)try{return await flattenedDecrypt({aad:ee.aad,ciphertext:ee.ciphertext,encrypted_key:ei.encrypted_key,header:ei.header,iv:ee.iv,protected:ee.protected,tag:ee.tag,unprotected:ee.unprotected},et,en)}catch(ee){}throw new JWEDecryptionFailed}let keyToJWK=async ee=>{if(ee instanceof Uint8Array)return{kty:"oct",k:encode(ee)};if(!isCryptoKey(ee))throw TypeError(invalid_key_input(ee,...em,"Uint8Array"));if(!ee.extractable)throw TypeError("non-extractable CryptoKey cannot be exported as a JWK");let{ext:et,key_ops:en,alg:ei,use:eo,...es}=await ea.subtle.exportKey("jwk",ee);return es};var e$=keyToJWK;async function exportSPKI(ee){return toSPKI(ee)}async function exportPKCS8(ee){return toPKCS8(ee)}async function exportJWK(ee){return e$(ee)}var encrypt_key_management=async function(ee,et,en,ei,eo={}){let ea,es,eu;switch(eS(ee,en,"encrypt"),ee){case"dir":eu=en;break;case"ECDH-ES":case"ECDH-ES+A128KW":case"ECDH-ES+A192KW":case"ECDH-ES+A256KW":{if(!ecdhAllowed(en))throw new JOSENotSupported("ECDH with the provided key is not allowed or not supported by your javascript runtime");let{apu:ec,apv:ed}=eo,{epk:ef}=eo;ef||(ef=(await generateEpk(en)).privateKey);let{x:ep,y:eh,crv:ey,kty:em}=await exportJWK(ef),eg=await deriveKey(en,ef,"ECDH-ES"===ee?et:ee,"ECDH-ES"===ee?cek_bitLength(et):parseInt(ee.slice(-5,-2),10),ec,ed);if(es={epk:{x:ep,crv:ey,kty:em}},"EC"===em&&(es.epk.y=eh),ec&&(es.apu=encode(ec)),ed&&(es.apv=encode(ed)),"ECDH-ES"===ee){eu=eg;break}eu=ei||lib_cek(et);let eb=ee.slice(-6);ea=await wrap(eb,eg,eu);break}case"RSA1_5":case"RSA-OAEP":case"RSA-OAEP-256":case"RSA-OAEP-384":case"RSA-OAEP-512":eu=ei||lib_cek(et),ea=await rsaes_encrypt(ee,en,eu);break;case"PBES2-HS256+A128KW":case"PBES2-HS384+A192KW":case"PBES2-HS512+A256KW":{eu=ei||lib_cek(et);let{p2c:ec,p2s:ed}=eo;({encryptedKey:ea,...es}=await encrypt(ee,en,eu,ec,ed));break}case"A128KW":case"A192KW":case"A256KW":eu=ei||lib_cek(et),ea=await wrap(ee,en,eu);break;case"A128GCMKW":case"A192GCMKW":case"A256GCMKW":{eu=ei||lib_cek(et);let{iv:ec}=eo;({encryptedKey:ea,...es}=await aesgcmkw_wrap(ee,en,eu,ec));break}default:throw new JOSENotSupported('Invalid or unsupported "alg" (JWE Algorithm) header value')}return{cek:eu,encryptedKey:ea,parameters:es}};let ex=Symbol();let FlattenedEncrypt=class FlattenedEncrypt{constructor(ee){if(!(ee instanceof Uint8Array))throw TypeError("plaintext must be an instance of Uint8Array");this._plaintext=ee}setKeyManagementParameters(ee){if(this._keyManagementParameters)throw TypeError("setKeyManagementParameters can only be called once");return this._keyManagementParameters=ee,this}setProtectedHeader(ee){if(this._protectedHeader)throw TypeError("setProtectedHeader can only be called once");return this._protectedHeader=ee,this}setSharedUnprotectedHeader(ee){if(this._sharedUnprotectedHeader)throw TypeError("setSharedUnprotectedHeader can only be called once");return this._sharedUnprotectedHeader=ee,this}setUnprotectedHeader(ee){if(this._unprotectedHeader)throw TypeError("setUnprotectedHeader can only be called once");return this._unprotectedHeader=ee,this}setAdditionalAuthenticatedData(ee){return this._aad=ee,this}setContentEncryptionKey(ee){if(this._cek)throw TypeError("setContentEncryptionKey can only be called once");return this._cek=ee,this}setInitializationVector(ee){if(this._iv)throw TypeError("setInitializationVector can only be called once");return this._iv=ee,this}async encrypt(ee,et){let en,ei,eo,ea,es,ed,ef;if(!this._protectedHeader&&!this._unprotectedHeader&&!this._sharedUnprotectedHeader)throw new JWEInvalid("either setProtectedHeader, setUnprotectedHeader, or sharedUnprotectedHeader must be called before #encrypt()");if(!eb(this._protectedHeader,this._unprotectedHeader,this._sharedUnprotectedHeader))throw new JWEInvalid("JWE Protected, JWE Shared Unprotected and JWE Per-Recipient Header Parameter names must be disjoint");let ep={...this._protectedHeader,...this._unprotectedHeader,...this._sharedUnprotectedHeader};if(validate_crit(JWEInvalid,new Map,null==et?void 0:et.crit,this._protectedHeader,ep),void 0!==ep.zip){if(!this._protectedHeader||!this._protectedHeader.zip)throw new JWEInvalid('JWE "zip" (Compression Algorithm) Header MUST be integrity protected');if("DEF"!==ep.zip)throw new JOSENotSupported('Unsupported JWE "zip" (Compression Algorithm) Header Parameter value')}let{alg:eh,enc:ey}=ep;if("string"!=typeof eh||!eh)throw new JWEInvalid('JWE "alg" (Algorithm) Header Parameter missing or invalid');if("string"!=typeof ey||!ey)throw new JWEInvalid('JWE "enc" (Encryption Algorithm) Header Parameter missing or invalid');if("dir"===eh){if(this._cek)throw TypeError("setContentEncryptionKey cannot be called when using Direct Encryption")}else if("ECDH-ES"===eh&&this._cek)throw TypeError("setContentEncryptionKey cannot be called when using Direct Key Agreement");{let eo;({cek:ei,encryptedKey:en,parameters:eo}=await encrypt_key_management(eh,ey,ee,this._cek,this._keyManagementParameters)),eo&&(et&&ex in et?this._unprotectedHeader?this._unprotectedHeader={...this._unprotectedHeader,...eo}:this.setUnprotectedHeader(eo):this._protectedHeader?this._protectedHeader={...this._protectedHeader,...eo}:this.setProtectedHeader(eo))}if(this._iv||(this._iv=lib_iv(ey)),ea=this._protectedHeader?eu.encode(encode(JSON.stringify(this._protectedHeader))):eu.encode(""),this._aad?(es=encode(this._aad),eo=concat(ea,eu.encode("."),eu.encode(es))):eo=ea,"DEF"===ep.zip){let ee=await ((null==et?void 0:et.deflateRaw)||deflate)(this._plaintext);({ciphertext:ed,tag:ef}=await eE(ey,ee,ei,this._iv,eo))}else({ciphertext:ed,tag:ef}=await eE(ey,this._plaintext,ei,this._iv,eo));let em={ciphertext:encode(ed),iv:encode(this._iv),tag:encode(ef)};return en&&(em.encrypted_key=encode(en)),es&&(em.aad=es),this._protectedHeader&&(em.protected=ec.decode(ea)),this._sharedUnprotectedHeader&&(em.unprotected=this._sharedUnprotectedHeader),this._unprotectedHeader&&(em.header=this._unprotectedHeader),em}};let IndividualRecipient=class IndividualRecipient{constructor(ee,et,en){this.parent=ee,this.key=et,this.options=en}setUnprotectedHeader(ee){if(this.unprotectedHeader)throw TypeError("setUnprotectedHeader can only be called once");return this.unprotectedHeader=ee,this}addRecipient(...ee){return this.parent.addRecipient(...ee)}encrypt(...ee){return this.parent.encrypt(...ee)}done(){return this.parent}};let GeneralEncrypt=class GeneralEncrypt{constructor(ee){this._recipients=[],this._plaintext=ee}addRecipient(ee,et){let en=new IndividualRecipient(this,ee,{crit:null==et?void 0:et.crit});return this._recipients.push(en),en}setProtectedHeader(ee){if(this._protectedHeader)throw TypeError("setProtectedHeader can only be called once");return this._protectedHeader=ee,this}setSharedUnprotectedHeader(ee){if(this._unprotectedHeader)throw TypeError("setSharedUnprotectedHeader can only be called once");return this._unprotectedHeader=ee,this}setAdditionalAuthenticatedData(ee){return this._aad=ee,this}async encrypt(ee){var et,en,ei;let eo;if(!this._recipients.length)throw new JWEInvalid("at least one recipient must be added");if(ee={deflateRaw:null==ee?void 0:ee.deflateRaw},1===this._recipients.length){let[et]=this._recipients,en=await new FlattenedEncrypt(this._plaintext).setAdditionalAuthenticatedData(this._aad).setProtectedHeader(this._protectedHeader).setSharedUnprotectedHeader(this._unprotectedHeader).setUnprotectedHeader(et.unprotectedHeader).encrypt(et.key,{...et.options,...ee}),ei={ciphertext:en.ciphertext,iv:en.iv,recipients:[{}],tag:en.tag};return en.aad&&(ei.aad=en.aad),en.protected&&(ei.protected=en.protected),en.unprotected&&(ei.unprotected=en.unprotected),en.encrypted_key&&(ei.recipients[0].encrypted_key=en.encrypted_key),en.header&&(ei.recipients[0].header=en.header),ei}for(let ee=0;ee>3};case"RS256":case"RS384":case"RS512":return{hash:en,name:"RSASSA-PKCS1-v1_5"};case"ES256":case"ES384":case"ES512":return{hash:en,name:"ECDSA",namedCurve:et.namedCurve};case"EdDSA":return{name:et.name};default:throw new JOSENotSupported(`alg ${ee} is not supported either by JOSE or your javascript runtime`)}}function get_sign_verify_key_getCryptoKey(ee,et,en){if(isCryptoKey(et))return checkSigCryptoKey(et,ee,en),et;if(et instanceof Uint8Array){if(!ee.startsWith("HS"))throw TypeError(invalid_key_input(et,...em));return ea.subtle.importKey("raw",et,{hash:`SHA-${ee.slice(-3)}`,name:"HMAC"},!1,[en])}throw TypeError(invalid_key_input(et,...em,"Uint8Array"))}let verify=async(ee,et,en,ei)=>{let eo=await get_sign_verify_key_getCryptoKey(ee,et,"verify");check_key_length(ee,eo);let es=subtleDsa(ee,eo.algorithm);try{return await ea.subtle.verify(es,eo,en,ei)}catch(ee){return!1}};var eC=verify;async function flattenedVerify(ee,et,en){var ei;let eo,ea;if(!isObject(ee))throw new JWSInvalid("Flattened JWS must be an object");if(void 0===ee.protected&&void 0===ee.header)throw new JWSInvalid('Flattened JWS must have either of the "protected" or "header" members');if(void 0!==ee.protected&&"string"!=typeof ee.protected)throw new JWSInvalid("JWS Protected Header incorrect type");if(void 0===ee.payload)throw new JWSInvalid("JWS Payload missing");if("string"!=typeof ee.signature)throw new JWSInvalid("JWS Signature missing or incorrect type");if(void 0!==ee.header&&!isObject(ee.header))throw new JWSInvalid("JWS Unprotected Header incorrect type");let es={};if(ee.protected)try{let et=decode(ee.protected);es=JSON.parse(ec.decode(et))}catch(ee){throw new JWSInvalid("JWS Protected Header is invalid")}if(!eb(es,ee.header))throw new JWSInvalid("JWS Protected and JWS Unprotected Header Parameter names must be disjoint");let ed={...es,...ee.header},ef=validate_crit(JWSInvalid,new Map([["b64",!0]]),null==en?void 0:en.crit,es,ed),ep=!0;if(ef.has("b64")&&"boolean"!=typeof(ep=es.b64))throw new JWSInvalid('The "b64" (base64url-encode payload) Header Parameter must be a boolean');let{alg:eh}=ed;if("string"!=typeof eh||!eh)throw new JWSInvalid('JWS "alg" (Algorithm) Header Parameter missing or invalid');let ey=en&&eA("algorithms",en.algorithms);if(ey&&!ey.has(eh))throw new JOSEAlgNotAllowed('"alg" (Algorithm) Header Parameter not allowed');if(ep){if("string"!=typeof ee.payload)throw new JWSInvalid("JWS Payload must be a string")}else if("string"!=typeof ee.payload&&!(ee.payload instanceof Uint8Array))throw new JWSInvalid("JWS Payload must be a string or an Uint8Array instance");let em=!1;"function"==typeof et&&(et=await et(es,ee),em=!0),eS(eh,et,"verify");let eg=concat(eu.encode(null!==(ei=ee.protected)&&void 0!==ei?ei:""),eu.encode("."),"string"==typeof ee.payload?eu.encode(ee.payload):ee.payload);try{eo=decode(ee.signature)}catch(ee){throw new JWSInvalid("Failed to base64url decode the signature")}let ev=await eC(eh,et,eo,eg);if(!ev)throw new JWSSignatureVerificationFailed;if(ep)try{ea=decode(ee.payload)}catch(ee){throw new JWSInvalid("Failed to base64url decode the payload")}else ea="string"==typeof ee.payload?eu.encode(ee.payload):ee.payload;let e_={payload:ea};return(void 0!==ee.protected&&(e_.protectedHeader=es),void 0!==ee.header&&(e_.unprotectedHeader=ee.header),em)?{...e_,key:et}:e_}async function compactVerify(ee,et,en){if(ee instanceof Uint8Array&&(ee=ec.decode(ee)),"string"!=typeof ee)throw new JWSInvalid("Compact JWS must be a string or Uint8Array");let{0:ei,1:eo,2:ea,length:es}=ee.split(".");if(3!==es)throw new JWSInvalid("Invalid Compact JWS");let eu=await flattenedVerify({payload:eo,protected:ei,signature:ea},et,en),ed={payload:eu.payload,protectedHeader:eu.protectedHeader};return"function"==typeof et?{...ed,key:eu.key}:ed}async function generalVerify(ee,et,en){if(!isObject(ee))throw new JWSInvalid("General JWS must be an object");if(!Array.isArray(ee.signatures)||!ee.signatures.every(isObject))throw new JWSInvalid("JWS Signatures missing or incorrect type");for(let ei of ee.signatures)try{return await flattenedVerify({header:ei.header,payload:ee.payload,protected:ei.protected,signature:ei.signature},et,en)}catch(ee){}throw new JWSSignatureVerificationFailed}var epoch=ee=>Math.floor(ee.getTime()/1e3);let ek=60,eO=60*ek,eT=24*eO,eP=7*eT,eR=365.25*eT,eI=/^(\d+|\d+\.\d+) ?(seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)$/i;var secs=ee=>{let et=eI.exec(ee);if(!et)throw TypeError("Invalid time period format");let en=parseFloat(et[1]),ei=et[2].toLowerCase();switch(ei){case"sec":case"secs":case"second":case"seconds":case"s":return Math.round(en);case"minute":case"minutes":case"min":case"mins":case"m":return Math.round(en*ek);case"hour":case"hours":case"hr":case"hrs":case"h":return Math.round(en*eO);case"day":case"days":case"d":return Math.round(en*eT);case"week":case"weeks":case"w":return Math.round(en*eP);default:return Math.round(en*eR)}};let normalizeTyp=ee=>ee.toLowerCase().replace(/^application\//,""),checkAudiencePresence=(ee,et)=>"string"==typeof ee?et.includes(ee):!!Array.isArray(ee)&&et.some(Set.prototype.has.bind(new Set(ee)));var jwt_claims_set=(ee,et,en={})=>{let ei,eo;let{typ:ea}=en;if(ea&&("string"!=typeof ee.typ||normalizeTyp(ee.typ)!==normalizeTyp(ea)))throw new JWTClaimValidationFailed('unexpected "typ" JWT header value',"typ","check_failed");try{ei=JSON.parse(ec.decode(et))}catch(ee){}if(!isObject(ei))throw new JWTInvalid("JWT Claims Set must be a top-level JSON object");let{requiredClaims:es=[],issuer:eu,subject:ed,audience:ef,maxTokenAge:ep}=en;for(let ee of(void 0!==ep&&es.push("iat"),void 0!==ef&&es.push("aud"),void 0!==ed&&es.push("sub"),void 0!==eu&&es.push("iss"),new Set(es.reverse())))if(!(ee in ei))throw new JWTClaimValidationFailed(`missing required "${ee}" claim`,ee,"missing");if(eu&&!(Array.isArray(eu)?eu:[eu]).includes(ei.iss))throw new JWTClaimValidationFailed('unexpected "iss" claim value',"iss","check_failed");if(ed&&ei.sub!==ed)throw new JWTClaimValidationFailed('unexpected "sub" claim value',"sub","check_failed");if(ef&&!checkAudiencePresence(ei.aud,"string"==typeof ef?[ef]:ef))throw new JWTClaimValidationFailed('unexpected "aud" claim value',"aud","check_failed");switch(typeof en.clockTolerance){case"string":eo=secs(en.clockTolerance);break;case"number":eo=en.clockTolerance;break;case"undefined":eo=0;break;default:throw TypeError("Invalid clockTolerance option type")}let{currentDate:eh}=en,ey=epoch(eh||new Date);if((void 0!==ei.iat||ep)&&"number"!=typeof ei.iat)throw new JWTClaimValidationFailed('"iat" claim must be a number',"iat","invalid");if(void 0!==ei.nbf){if("number"!=typeof ei.nbf)throw new JWTClaimValidationFailed('"nbf" claim must be a number',"nbf","invalid");if(ei.nbf>ey+eo)throw new JWTClaimValidationFailed('"nbf" claim timestamp check failed',"nbf","check_failed")}if(void 0!==ei.exp){if("number"!=typeof ei.exp)throw new JWTClaimValidationFailed('"exp" claim must be a number',"exp","invalid");if(ei.exp<=ey-eo)throw new JWTExpired('"exp" claim timestamp check failed',"exp","check_failed")}if(ep){let ee=ey-ei.iat,et="number"==typeof ep?ep:secs(ep);if(ee-eo>et)throw new JWTExpired('"iat" claim timestamp check failed (too far in the past)',"iat","check_failed");if(ee<0-eo)throw new JWTClaimValidationFailed('"iat" claim timestamp check failed (it should be in the past)',"iat","check_failed")}return ei};async function jwtVerify(ee,et,en){var ei;let eo=await compactVerify(ee,et,en);if((null===(ei=eo.protectedHeader.crit)||void 0===ei?void 0:ei.includes("b64"))&&!1===eo.protectedHeader.b64)throw new JWTInvalid("JWTs MUST NOT use unencoded payload");let ea=jwt_claims_set(eo.protectedHeader,eo.payload,en),es={payload:ea,protectedHeader:eo.protectedHeader};return"function"==typeof et?{...es,key:eo.key}:es}async function jwtDecrypt(ee,et,en){let ei=await compactDecrypt(ee,et,en),eo=jwt_claims_set(ei.protectedHeader,ei.plaintext,en),{protectedHeader:ea}=ei;if(void 0!==ea.iss&&ea.iss!==eo.iss)throw new JWTClaimValidationFailed('replicated "iss" claim header parameter mismatch',"iss","mismatch");if(void 0!==ea.sub&&ea.sub!==eo.sub)throw new JWTClaimValidationFailed('replicated "sub" claim header parameter mismatch',"sub","mismatch");if(void 0!==ea.aud&&JSON.stringify(ea.aud)!==JSON.stringify(eo.aud))throw new JWTClaimValidationFailed('replicated "aud" claim header parameter mismatch',"aud","mismatch");let es={payload:eo,protectedHeader:ea};return"function"==typeof et?{...es,key:ei.key}:es}let CompactEncrypt=class CompactEncrypt{constructor(ee){this._flattened=new FlattenedEncrypt(ee)}setContentEncryptionKey(ee){return this._flattened.setContentEncryptionKey(ee),this}setInitializationVector(ee){return this._flattened.setInitializationVector(ee),this}setProtectedHeader(ee){return this._flattened.setProtectedHeader(ee),this}setKeyManagementParameters(ee){return this._flattened.setKeyManagementParameters(ee),this}async encrypt(ee,et){let en=await this._flattened.encrypt(ee,et);return[en.protected,en.encrypted_key,en.iv,en.ciphertext,en.tag].join(".")}};let sign=async(ee,et,en)=>{let ei=await get_sign_verify_key_getCryptoKey(ee,et,"sign");check_key_length(ee,ei);let eo=await ea.subtle.sign(subtleDsa(ee,ei.algorithm),ei,en);return new Uint8Array(eo)};var eN=sign;let FlattenedSign=class FlattenedSign{constructor(ee){if(!(ee instanceof Uint8Array))throw TypeError("payload must be an instance of Uint8Array");this._payload=ee}setProtectedHeader(ee){if(this._protectedHeader)throw TypeError("setProtectedHeader can only be called once");return this._protectedHeader=ee,this}setUnprotectedHeader(ee){if(this._unprotectedHeader)throw TypeError("setUnprotectedHeader can only be called once");return this._unprotectedHeader=ee,this}async sign(ee,et){let en;if(!this._protectedHeader&&!this._unprotectedHeader)throw new JWSInvalid("either setProtectedHeader or setUnprotectedHeader must be called before #sign()");if(!eb(this._protectedHeader,this._unprotectedHeader))throw new JWSInvalid("JWS Protected and JWS Unprotected Header Parameter names must be disjoint");let ei={...this._protectedHeader,...this._unprotectedHeader},eo=validate_crit(JWSInvalid,new Map([["b64",!0]]),null==et?void 0:et.crit,this._protectedHeader,ei),ea=!0;if(eo.has("b64")&&"boolean"!=typeof(ea=this._protectedHeader.b64))throw new JWSInvalid('The "b64" (base64url-encode payload) Header Parameter must be a boolean');let{alg:es}=ei;if("string"!=typeof es||!es)throw new JWSInvalid('JWS "alg" (Algorithm) Header Parameter missing or invalid');eS(es,ee,"sign");let ed=this._payload;ea&&(ed=eu.encode(encode(ed))),en=this._protectedHeader?eu.encode(encode(JSON.stringify(this._protectedHeader))):eu.encode("");let ef=concat(en,eu.encode("."),ed),ep=await eN(es,ee,ef),eh={signature:encode(ep),payload:""};return ea&&(eh.payload=ec.decode(ed)),this._unprotectedHeader&&(eh.header=this._unprotectedHeader),this._protectedHeader&&(eh.protected=ec.decode(en)),eh}};let CompactSign=class CompactSign{constructor(ee){this._flattened=new FlattenedSign(ee)}setProtectedHeader(ee){return this._flattened.setProtectedHeader(ee),this}async sign(ee,et){let en=await this._flattened.sign(ee,et);if(void 0===en.payload)throw TypeError("use the flattened module for creating JWS with b64: false");return`${en.protected}.${en.payload}.${en.signature}`}};let IndividualSignature=class IndividualSignature{constructor(ee,et,en){this.parent=ee,this.key=et,this.options=en}setProtectedHeader(ee){if(this.protectedHeader)throw TypeError("setProtectedHeader can only be called once");return this.protectedHeader=ee,this}setUnprotectedHeader(ee){if(this.unprotectedHeader)throw TypeError("setUnprotectedHeader can only be called once");return this.unprotectedHeader=ee,this}addSignature(...ee){return this.parent.addSignature(...ee)}sign(...ee){return this.parent.sign(...ee)}done(){return this.parent}};let GeneralSign=class GeneralSign{constructor(ee){this._signatures=[],this._payload=ee}addSignature(ee,et){let en=new IndividualSignature(this,ee,et);return this._signatures.push(en),en}async sign(){if(!this._signatures.length)throw new JWSInvalid("at least one signature must be added");let ee={signatures:[],payload:""};for(let et=0;et{if("string"!=typeof ee||!ee)throw new JWKInvalid(`${et} missing or invalid`)};async function calculateJwkThumbprint(ee,et){let en;if(!isObject(ee))throw TypeError("JWK must be an object");if(null!=et||(et="sha256"),"sha256"!==et&&"sha384"!==et&&"sha512"!==et)throw TypeError('digestAlgorithm must one of "sha256", "sha384", or "sha512"');switch(ee.kty){case"EC":check(ee.crv,'"crv" (Curve) Parameter'),check(ee.x,'"x" (X Coordinate) Parameter'),check(ee.y,'"y" (Y Coordinate) Parameter'),en={crv:ee.crv,kty:ee.kty,x:ee.x,y:ee.y};break;case"OKP":check(ee.crv,'"crv" (Subtype of Key Pair) Parameter'),check(ee.x,'"x" (Public Key) Parameter'),en={crv:ee.crv,kty:ee.kty,x:ee.x};break;case"RSA":check(ee.e,'"e" (Exponent) Parameter'),check(ee.n,'"n" (Modulus) Parameter'),en={e:ee.e,kty:ee.kty,n:ee.n};break;case"oct":check(ee.k,'"k" (Key Value) Parameter'),en={k:ee.k,kty:ee.kty};break;default:throw new JOSENotSupported('"kty" (Key Type) Parameter missing or unsupported')}let ei=eu.encode(JSON.stringify(en));return encode(await es(et,ei))}async function calculateJwkThumbprintUri(ee,et){null!=et||(et="sha256");let en=await calculateJwkThumbprint(ee,et);return`urn:ietf:params:oauth:jwk-thumbprint:sha-${et.slice(-3)}:${en}`}async function EmbeddedJWK(ee,et){let en={...ee,...null==et?void 0:et.header};if(!isObject(en.jwk))throw new JWSInvalid('"jwk" (JSON Web Key) Header Parameter must be a JSON object');let ei=await importJWK({...en.jwk,ext:!0},en.alg,!0);if(ei instanceof Uint8Array||"public"!==ei.type)throw new JWSInvalid('"jwk" (JSON Web Key) Header Parameter must be a public key');return ei}function getKtyFromAlg(ee){switch("string"==typeof ee&&ee.slice(0,2)){case"RS":case"PS":return"RSA";case"ES":return"EC";case"Ed":return"OKP";default:throw new JOSENotSupported('Unsupported "alg" value for a JSON Web Key Set')}}function isJWKSLike(ee){return ee&&"object"==typeof ee&&Array.isArray(ee.keys)&&ee.keys.every(isJWKLike)}function isJWKLike(ee){return isObject(ee)}function clone(ee){return"function"==typeof structuredClone?structuredClone(ee):JSON.parse(JSON.stringify(ee))}let LocalJWKSet=class LocalJWKSet{constructor(ee){if(this._cached=new WeakMap,!isJWKSLike(ee))throw new JWKSInvalid("JSON Web Key Set malformed");this._jwks=clone(ee)}async getKey(ee,et){let{alg:en,kid:ei}={...ee,...null==et?void 0:et.header},eo=getKtyFromAlg(en),ea=this._jwks.keys.filter(ee=>{let et=eo===ee.kty;if(et&&"string"==typeof ei&&(et=ei===ee.kid),et&&"string"==typeof ee.alg&&(et=en===ee.alg),et&&"string"==typeof ee.use&&(et="sig"===ee.use),et&&Array.isArray(ee.key_ops)&&(et=ee.key_ops.includes("verify")),et&&"EdDSA"===en&&(et="Ed25519"===ee.crv||"Ed448"===ee.crv),et)switch(en){case"ES256":et="P-256"===ee.crv;break;case"ES256K":et="secp256k1"===ee.crv;break;case"ES384":et="P-384"===ee.crv;break;case"ES512":et="P-521"===ee.crv}return et}),{0:es,length:eu}=ea;if(0===eu)throw new JWKSNoMatchingKey;if(1!==eu){let ee=new JWKSMultipleMatchingKeys,{_cached:et}=this;throw ee[Symbol.asyncIterator]=async function*(){for(let ee of ea)try{yield await importWithAlgCache(et,ee,en)}catch(ee){continue}},ee}return importWithAlgCache(this._cached,es,en)}};async function importWithAlgCache(ee,et,en){let ei=ee.get(et)||ee.set(et,{}).get(et);if(void 0===ei[en]){let ee=await importJWK({...et,ext:!0},en);if(ee instanceof Uint8Array||"public"!==ee.type)throw new JWKSInvalid("JSON Web Key Set members must be public keys");ei[en]=ee}return ei[en]}function createLocalJWKSet(ee){let et=new LocalJWKSet(ee);return async function(ee,en){return et.getKey(ee,en)}}let fetchJwks=async(ee,et,en)=>{let ei,eo;let ea=!1;"function"==typeof AbortController&&(ei=new AbortController,eo=setTimeout(()=>{ea=!0,ei.abort()},et));let es=await fetch(ee.href,{signal:ei?ei.signal:void 0,redirect:"manual",headers:en.headers}).catch(ee=>{if(ea)throw new JWKSTimeout;throw ee});if(void 0!==eo&&clearTimeout(eo),200!==es.status)throw new JOSEError("Expected 200 OK from the JSON Web Key Set HTTP response");try{return await es.json()}catch(ee){throw new JOSEError("Failed to parse the JSON Web Key Set HTTP response as JSON")}};var eM=fetchJwks;function isCloudflareWorkers(){return"undefined"!=typeof WebSocketPair||"undefined"!=typeof navigator&&"Cloudflare-Workers"===navigator.userAgent||"undefined"!=typeof EdgeRuntime&&"vercel"===EdgeRuntime}let RemoteJWKSet=class RemoteJWKSet extends LocalJWKSet{constructor(ee,et){if(super({keys:[]}),this._jwks=void 0,!(ee instanceof URL))throw TypeError("url must be an instance of URL");this._url=new URL(ee.href),this._options={agent:null==et?void 0:et.agent,headers:null==et?void 0:et.headers},this._timeoutDuration="number"==typeof(null==et?void 0:et.timeoutDuration)?null==et?void 0:et.timeoutDuration:5e3,this._cooldownDuration="number"==typeof(null==et?void 0:et.cooldownDuration)?null==et?void 0:et.cooldownDuration:3e4,this._cacheMaxAge="number"==typeof(null==et?void 0:et.cacheMaxAge)?null==et?void 0:et.cacheMaxAge:6e5}coolingDown(){return"number"==typeof this._jwksTimestamp&&Date.now(){if(!isJWKSLike(ee))throw new JWKSInvalid("JSON Web Key Set malformed");this._jwks={keys:ee.keys},this._jwksTimestamp=Date.now(),this._pendingFetch=void 0}).catch(ee=>{throw this._pendingFetch=void 0,ee})),await this._pendingFetch}};function createRemoteJWKSet(ee,et){let en=new RemoteJWKSet(ee,et);return async function(ee,et){return en.getKey(ee,et)}}let UnsecuredJWT=class UnsecuredJWT extends ProduceJWT{encode(){let ee=encode(JSON.stringify({alg:"none"})),et=encode(JSON.stringify(this._payload));return`${ee}.${et}.`}static decode(ee,et){let en;if("string"!=typeof ee)throw new JWTInvalid("Unsecured JWT must be a string");let{0:ei,1:eo,2:ea,length:es}=ee.split(".");if(3!==es||""!==ea)throw new JWTInvalid("Invalid Unsecured JWT");try{if(en=JSON.parse(ec.decode(decode(ei))),"none"!==en.alg)throw Error()}catch(ee){throw new JWTInvalid("Invalid Unsecured JWT")}let eu=jwt_claims_set(en,decode(eo),et);return{payload:eu,header:en}}};let ej=encode,eD=decode;function decodeProtectedHeader(ee){let et;if("string"==typeof ee){let en=ee.split(".");(3===en.length||5===en.length)&&([et]=en)}else if("object"==typeof ee&&ee){if("protected"in ee)et=ee.protected;else throw TypeError("Token does not contain a Protected Header")}try{if("string"!=typeof et||!et)throw Error();let ee=JSON.parse(ec.decode(eD(et)));if(!isObject(ee))throw Error();return ee}catch(ee){throw TypeError("Invalid Token or Protected Header formatting")}}function decodeJwt(ee){let et,en;if("string"!=typeof ee)throw new JWTInvalid("JWTs must use Compact JWS serialization, JWT must be a string");let{1:ei,length:eo}=ee.split(".");if(5===eo)throw new JWTInvalid("Only JWTs using Compact JWS serialization can be decoded");if(3!==eo)throw new JWTInvalid("Invalid JWT");if(!ei)throw new JWTInvalid("JWTs must contain a payload");try{et=eD(ei)}catch(ee){throw new JWTInvalid("Failed to base64url decode the payload")}try{en=JSON.parse(ec.decode(et))}catch(ee){throw new JWTInvalid("Failed to parse the decoded payload as JSON")}if(!isObject(en))throw new JWTInvalid("Invalid JWT Claims Set");return en}async function generateSecret(ee,et){var en;let ei,eo,es;switch(ee){case"HS256":case"HS384":case"HS512":ei=parseInt(ee.slice(-3),10),eo={name:"HMAC",hash:`SHA-${ei}`,length:ei},es=["sign","verify"];break;case"A128CBC-HS256":case"A192CBC-HS384":case"A256CBC-HS512":return ei=parseInt(ee.slice(-3),10),ef(new Uint8Array(ei>>3));case"A128KW":case"A192KW":case"A256KW":eo={name:"AES-KW",length:ei=parseInt(ee.slice(1,4),10)},es=["wrapKey","unwrapKey"];break;case"A128GCMKW":case"A192GCMKW":case"A256GCMKW":case"A128GCM":case"A192GCM":case"A256GCM":eo={name:"AES-GCM",length:ei=parseInt(ee.slice(1,4),10)},es=["encrypt","decrypt"];break;default:throw new JOSENotSupported('Invalid or unsupported JWK "alg" (Algorithm) Parameter value')}return ea.subtle.generateKey(eo,null!==(en=null==et?void 0:et.extractable)&&void 0!==en&&en,es)}function getModulusLengthOption(ee){var et;let en=null!==(et=null==ee?void 0:ee.modulusLength)&&void 0!==et?et:2048;if("number"!=typeof en||en<2048)throw new JOSENotSupported("Invalid or unsupported modulusLength option provided, 2048 bits or larger keys must be used");return en}async function generateKeyPair(ee,et){var en,ei,eo;let es,eu;switch(ee){case"PS256":case"PS384":case"PS512":es={name:"RSA-PSS",hash:`SHA-${ee.slice(-3)}`,publicExponent:new Uint8Array([1,0,1]),modulusLength:getModulusLengthOption(et)},eu=["sign","verify"];break;case"RS256":case"RS384":case"RS512":es={name:"RSASSA-PKCS1-v1_5",hash:`SHA-${ee.slice(-3)}`,publicExponent:new Uint8Array([1,0,1]),modulusLength:getModulusLengthOption(et)},eu=["sign","verify"];break;case"RSA-OAEP":case"RSA-OAEP-256":case"RSA-OAEP-384":case"RSA-OAEP-512":es={name:"RSA-OAEP",hash:`SHA-${parseInt(ee.slice(-3),10)||1}`,publicExponent:new Uint8Array([1,0,1]),modulusLength:getModulusLengthOption(et)},eu=["decrypt","unwrapKey","encrypt","wrapKey"];break;case"ES256":es={name:"ECDSA",namedCurve:"P-256"},eu=["sign","verify"];break;case"ES384":es={name:"ECDSA",namedCurve:"P-384"},eu=["sign","verify"];break;case"ES512":es={name:"ECDSA",namedCurve:"P-521"},eu=["sign","verify"];break;case"EdDSA":eu=["sign","verify"];let ec=null!==(en=null==et?void 0:et.crv)&&void 0!==en?en:"Ed25519";switch(ec){case"Ed25519":case"Ed448":es={name:ec};break;default:throw new JOSENotSupported("Invalid or unsupported crv option provided")}break;case"ECDH-ES":case"ECDH-ES+A128KW":case"ECDH-ES+A192KW":case"ECDH-ES+A256KW":{eu=["deriveKey","deriveBits"];let ee=null!==(ei=null==et?void 0:et.crv)&&void 0!==ei?ei:"P-256";switch(ee){case"P-256":case"P-384":case"P-521":es={name:"ECDH",namedCurve:ee};break;case"X25519":case"X448":es={name:ee};break;default:throw new JOSENotSupported("Invalid or unsupported crv option provided, supported values are P-256, P-384, P-521, X25519, and X448")}break}default:throw new JOSENotSupported('Invalid or unsupported JWK "alg" (Algorithm) Parameter value')}return ea.subtle.generateKey(es,null!==(eo=null==et?void 0:et.extractable)&&void 0!==eo&&eo,eu)}async function generate_key_pair_generateKeyPair(ee,et){return generateKeyPair(ee,et)}async function generate_secret_generateSecret(ee,et){return generateSecret(ee,et)}var eB="WebCryptoAPI"},40792:function(ee,et,en){"use strict";function _typeof(ee){return(_typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(ee){return typeof ee}:function(ee){return ee&&"function"==typeof Symbol&&ee.constructor===Symbol&&ee!==Symbol.prototype?"symbol":typeof ee})(ee)}function _defineProperties(ee,et){for(var en=0;enes)return 1;if(es>ea)return -1;if(!isNaN(ea)&&isNaN(es))return 1;if(isNaN(ea)&&!isNaN(es))return -1}return ee[1]&&et[1]?ee[1]>et[1]?1:ee[1]ee.length)&&(et=ee.length);for(var en=0,ei=Array(et);en=ei&&eE.test(ee)}function isViablePhoneNumberStart(ee){return eS.test(ee)}var eA=RegExp("(?:"+createExtensionPattern()+")$","i");function extractExtension(ee){var et=ee.search(eA);if(et<0)return{};for(var en=ee.slice(0,et),ei=ee.match(eA),eo=1;eo=ee.length?{done:!0}:{done:!1,value:ee[ei++]}}}throw TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function parseIncompletePhoneNumber_unsupportedIterableToArray(ee,et){if(ee){if("string"==typeof ee)return parseIncompletePhoneNumber_arrayLikeToArray(ee,et);var en=Object.prototype.toString.call(ee).slice(8,-1);if("Object"===en&&ee.constructor&&(en=ee.constructor.name),"Map"===en||"Set"===en)return Array.from(ee);if("Arguments"===en||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(en))return parseIncompletePhoneNumber_arrayLikeToArray(ee,et)}}function parseIncompletePhoneNumber_arrayLikeToArray(ee,et){(null==et||et>ee.length)&&(et=ee.length);for(var en=0,ei=Array(et);en=ee.length?{done:!0}:{done:!1,value:ee[ei++]}}}throw TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function mergeArrays_unsupportedIterableToArray(ee,et){if(ee){if("string"==typeof ee)return mergeArrays_arrayLikeToArray(ee,et);var en=Object.prototype.toString.call(ee).slice(8,-1);if("Object"===en&&ee.constructor&&(en=ee.constructor.name),"Map"===en||"Set"===en)return Array.from(ee);if("Arguments"===en||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(en))return mergeArrays_arrayLikeToArray(ee,et)}}function mergeArrays_arrayLikeToArray(ee,et){(null==et||et>ee.length)&&(et=ee.length);for(var en=0,ei=Array(et);enee.indexOf(ea)&&ei.push(ea)}return ei.sort(function(ee,et){return ee-et})}function checkNumberLength(ee,et){return checkNumberLengthForType(ee,void 0,et)}function checkNumberLengthForType(ee,et,en){var ei=en.type(et),eo=ei&&ei.possibleLengths()||en.possibleLengths();if(!eo)return"IS_POSSIBLE";if("FIXED_LINE_OR_MOBILE"===et){if(!en.type("FIXED_LINE"))return checkNumberLengthForType(ee,"MOBILE",en);var ea=en.type("MOBILE");ea&&(eo=mergeArrays(eo,ea.possibleLengths()))}else if(et&&!ei)return"INVALID_LENGTH";var es=ee.length,eu=eo[0];return eu===es?"IS_POSSIBLE":eu>es?"TOO_SHORT":eo[eo.length-1]=0?"IS_POSSIBLE":"INVALID_LENGTH"}function isPossiblePhoneNumber(ee,et,en){if(void 0===et&&(et={}),en=new eb.ZP(en),et.v2){if(!ee.countryCallingCode)throw Error("Invalid phone number object passed");en.selectNumberingPlan(ee.countryCallingCode)}else{if(!ee.phone)return!1;if(ee.country){if(!en.hasCountry(ee.country))throw Error("Unknown country: ".concat(ee.country));en.country(ee.country)}else{if(!ee.countryCallingCode)throw Error("Invalid phone number object passed");en.selectNumberingPlan(ee.countryCallingCode)}}if(en.possibleLengths())return isPossibleNumber(ee.phone||ee.nationalNumber,en);if(ee.countryCallingCode&&en.isNonGeographicCallingCode(ee.countryCallingCode))return!0;throw Error('Missing "possibleLengths" in metadata. Perhaps the metadata has been generated before v1.0.18.')}function isPossibleNumber(ee,et){return"IS_POSSIBLE"===checkNumberLength(ee,et)}function matchesEntirely(ee,et){return ee=ee||"",RegExp("^(?:"+et+")$").test(ee)}function getNumberType_createForOfIteratorHelperLoose(ee,et){var en="undefined"!=typeof Symbol&&ee[Symbol.iterator]||ee["@@iterator"];if(en)return(en=en.call(ee)).next.bind(en);if(Array.isArray(ee)||(en=getNumberType_unsupportedIterableToArray(ee))||et&&ee&&"number"==typeof ee.length){en&&(ee=en);var ei=0;return function(){return ei>=ee.length?{done:!0}:{done:!1,value:ee[ei++]}}}throw TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function getNumberType_unsupportedIterableToArray(ee,et){if(ee){if("string"==typeof ee)return getNumberType_arrayLikeToArray(ee,et);var en=Object.prototype.toString.call(ee).slice(8,-1);if("Object"===en&&ee.constructor&&(en=ee.constructor.name),"Map"===en||"Set"===en)return Array.from(ee);if("Arguments"===en||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(en))return getNumberType_arrayLikeToArray(ee,et)}}function getNumberType_arrayLikeToArray(ee,et){(null==et||et>ee.length)&&(et=ee.length);for(var en=0,ei=Array(et);enet.possibleLengths().indexOf(ee.length))&&matchesEntirely(ee,et.pattern())}function isValidNumber(ee,et,en){return(et=et||{},(en=new eb.ZP(en)).selectNumberingPlan(ee.country,ee.countryCallingCode),en.hasTypes())?void 0!==getNumberType(ee,et,en.metadata):matchesEntirely(et.v2?ee.nationalNumber:ee.phone,en.nationalNumberPattern())}function getPossibleCountriesForNumber(ee,et,en){var ei=new eb.ZP(en).getCountryCodesForCallingCode(ee);return ei?ei.filter(function(ee){return couldNationalNumberBelongToCountry(et,ee,en)}):[]}function couldNationalNumberBelongToCountry(ee,et,en){var ei=new eb.ZP(en);return ei.selectNumberingPlan(et),ei.numberingPlan.possibleLengths().indexOf(ee.length)>=0}function applyInternationalSeparatorStyle(ee){return ee.replace(RegExp("[".concat(ey,"]+"),"g")," ").trim()}var eC=/(\$\d)/;function formatNationalNumberUsingFormat(ee,et,en){var ei=en.useInternationalFormat,eo=en.withNationalPrefix;en.carrierCode,en.metadata;var ea=ee.replace(new RegExp(et.pattern()),ei?et.internationalFormat():eo&&et.nationalPrefixFormattingRule()?et.format().replace(eC,et.nationalPrefixFormattingRule()):et.format());return ei?applyInternationalSeparatorStyle(ea):ea}var ek=/^[\d]+(?:[~\u2053\u223C\uFF5E][\d]+)?$/;function getIddPrefix(ee,et,en){var ei=new eb.ZP(en);return(ei.selectNumberingPlan(ee,et),ei.defaultIDDPrefix())?ei.defaultIDDPrefix():ek.test(ei.IDDPrefix())?ei.IDDPrefix():void 0}function formatRFC3966(ee){var et=ee.number,en=ee.ext;if(!et)return"";if("+"!==et[0])throw Error('"formatRFC3966()" expects "number" to be in E.164 format.');return"tel:".concat(et).concat(en?";ext="+en:"")}function format_createForOfIteratorHelperLoose(ee,et){var en="undefined"!=typeof Symbol&&ee[Symbol.iterator]||ee["@@iterator"];if(en)return(en=en.call(ee)).next.bind(en);if(Array.isArray(ee)||(en=format_unsupportedIterableToArray(ee))||et&&ee&&"number"==typeof ee.length){en&&(ee=en);var ei=0;return function(){return ei>=ee.length?{done:!0}:{done:!1,value:ee[ei++]}}}throw TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function format_unsupportedIterableToArray(ee,et){if(ee){if("string"==typeof ee)return format_arrayLikeToArray(ee,et);var en=Object.prototype.toString.call(ee).slice(8,-1);if("Object"===en&&ee.constructor&&(en=ee.constructor.name),"Map"===en||"Set"===en)return Array.from(ee);if("Arguments"===en||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(en))return format_arrayLikeToArray(ee,et)}}function format_arrayLikeToArray(ee,et){(null==et||et>ee.length)&&(et=ee.length);for(var en=0,ei=Array(et);en0){var ea=eo.leadingDigitsPatterns()[eo.leadingDigitsPatterns().length-1];if(0!==et.search(ea))continue}if(matchesEntirely(et,eo.pattern()))return eo}}function addExtension(ee,et,en,ei){return et?ei(ee,et,en):ee}function formatIDD(ee,et,en,ei,eo){if((0,eb.Gg)(ei,eo.metadata)===en){var ea=formatNationalNumber(ee,et,"NATIONAL",eo);return"1"===en?en+" "+ea:ea}var es=getIddPrefix(ei,void 0,eo.metadata);if(es)return"".concat(es," ").concat(en," ").concat(formatNationalNumber(ee,null,"INTERNATIONAL",eo))}function PhoneNumber_ownKeys(ee,et){var en=Object.keys(ee);if(Object.getOwnPropertySymbols){var ei=Object.getOwnPropertySymbols(ee);et&&(ei=ei.filter(function(et){return Object.getOwnPropertyDescriptor(ee,et).enumerable})),en.push.apply(en,ei)}return en}function PhoneNumber_objectSpread(ee){for(var et=1;et0)||"0"!==es[1])return ee}}}function extractNationalNumberFromPossiblyIncompleteNumber(ee,et){if(ee&&et.numberingPlan.nationalPrefixForParsing()){var en=RegExp("^(?:"+et.numberingPlan.nationalPrefixForParsing()+")"),ei=en.exec(ee);if(ei){var eo,ea,es,eu=ei.length-1,ec=eu>0&&ei[eu];if(et.nationalPrefixTransformRule()&&ec)eo=ee.replace(en,et.nationalPrefixTransformRule()),eu>1&&(ea=ei[1]);else{var ed=ei[0];eo=ee.slice(ed.length),ec&&(ea=ei[1])}if(ec){var ef=ee.indexOf(ei[1]);ee.slice(0,ef)===et.numberingPlan.nationalPrefix()&&(es=et.numberingPlan.nationalPrefix())}else es=ei[0];return{nationalNumber:eo,nationalPrefix:es,carrierCode:ea}}}return{nationalNumber:ee}}function extractNationalNumber(ee,et){var en=extractNationalNumberFromPossiblyIncompleteNumber(ee,et),ei=en.carrierCode,eo=en.nationalNumber;return eo!==ee&&(!shouldHaveExtractedNationalPrefix(ee,eo,et)||et.possibleLengths()&&!isPossibleIncompleteNationalNumber(eo,et))?{nationalNumber:ee}:{nationalNumber:eo,carrierCode:ei}}function shouldHaveExtractedNationalPrefix(ee,et,en){return!matchesEntirely(ee,en.nationalNumberPattern())||!!matchesEntirely(et,en.nationalNumberPattern())}function isPossibleIncompleteNationalNumber(ee,et){switch(checkNumberLength(ee,et)){case"TOO_SHORT":case"INVALID_LENGTH":return!1;default:return!0}}function extractCountryCallingCodeFromInternationalNumberWithoutPlusSign(ee,et,en,ei){var eo=et?(0,eb.Gg)(et,ei):en;if(0===ee.indexOf(eo)){(ei=new eb.ZP(ei)).selectNumberingPlan(et,en);var ea=ee.slice(eo.length),es=extractNationalNumber(ea,ei).nationalNumber,eu=extractNationalNumber(ee,ei).nationalNumber;if(!matchesEntirely(eu,ei.nationalNumberPattern())&&matchesEntirely(es,ei.nationalNumberPattern())||"TOO_LONG"===checkNumberLength(eu,ei))return{countryCallingCode:eo,number:ea}}return{number:ee}}function extractCountryCallingCode(ee,et,en,ei){if(!ee)return{};if("+"!==ee[0]){var eo,es=stripIddPrefix(ee,et,en,ei);if(es&&es!==ee)eo=!0,ee="+"+es;else{if(et||en){var eu=extractCountryCallingCodeFromInternationalNumberWithoutPlusSign(ee,et,en,ei),ec=eu.countryCallingCode,ed=eu.number;if(ec)return{countryCallingCodeSource:"FROM_NUMBER_WITHOUT_PLUS_SIGN",countryCallingCode:ec,number:ed}}return{number:ee}}}if("0"===ee[1])return{};ei=new eb.ZP(ei);for(var ef=2;ef-1<=ea&&ef<=ee.length;){var ep=ee.slice(1,ef);if(ei.hasCallingCode(ep))return ei.selectNumberingPlan(ep),{countryCallingCodeSource:eo?"FROM_NUMBER_WITH_IDD":"FROM_NUMBER_WITH_PLUS_SIGN",countryCallingCode:ep,number:ee.slice(ef)};ef++}return{}}function getCountryByNationalNumber_createForOfIteratorHelperLoose(ee,et){var en="undefined"!=typeof Symbol&&ee[Symbol.iterator]||ee["@@iterator"];if(en)return(en=en.call(ee)).next.bind(en);if(Array.isArray(ee)||(en=getCountryByNationalNumber_unsupportedIterableToArray(ee))||et&&ee&&"number"==typeof ee.length){en&&(ee=en);var ei=0;return function(){return ei>=ee.length?{done:!0}:{done:!1,value:ee[ei++]}}}throw TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function getCountryByNationalNumber_unsupportedIterableToArray(ee,et){if(ee){if("string"==typeof ee)return getCountryByNationalNumber_arrayLikeToArray(ee,et);var en=Object.prototype.toString.call(ee).slice(8,-1);if("Object"===en&&ee.constructor&&(en=ee.constructor.name),"Map"===en||"Set"===en)return Array.from(ee);if("Arguments"===en||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(en))return getCountryByNationalNumber_arrayLikeToArray(ee,et)}}function getCountryByNationalNumber_arrayLikeToArray(ee,et){(null==et||et>ee.length)&&(et=ee.length);for(var en=0,ei=Array(et);en0)return es[0]}var eI=!1;function getCountryByCallingCode(ee,et){var en=et.nationalNumber,ei=et.defaultCountry,eo=et.metadata;if(eI&&eo.isNonGeographicCallingCode(ee))return"001";var ea=eo.getCountryCodesForCallingCode(ee);return ea?1===ea.length?ea[0]:getCountryByNationalNumber(en,{countries:ea,defaultCountry:ei,metadata:eo.metadata}):void 0}var eN="+",eM="(["+es+"]|[\\-\\.\\(\\)]?)",ej=RegExp("^\\"+eN+eM+"*["+es+"]"+eM+"*$","g"),eD=es,eB=RegExp("^("+("["+eD+"]+((\\-)*[")+eD+"])*\\.)*[a-zA-Z]+((\\-)*["+eD+"])*\\.?$","g"),eU="tel:",eL=";phone-context=",eF=";isub=";function extractPhoneContext(ee){var et=ee.indexOf(eL);if(et<0)return null;var en=et+eL.length;if(en>=ee.length)return"";var ei=ee.indexOf(";",en);return ei>=0?ee.substring(en,ei):ee.substring(en)}function isPhoneContextValid(ee){return null===ee||0!==ee.length&&(ej.test(ee)||eB.test(ee))}function extractFormattedPhoneNumberFromPossibleRfc3966NumberUri(ee,et){var en=et.extractFormattedPhoneNumber,ei=extractPhoneContext(ee);if(!isPhoneContextValid(ei))throw new eg.Z("NOT_A_NUMBER");if(null===ei)eo=en(ee)||"";else{eo="",ei.charAt(0)===eN&&(eo+=ei);var eo,ea,es=ee.indexOf(eU);ea=es>=0?es+eU.length:0;var eu=ee.indexOf(eL);eo+=ee.substring(ea,eu)}var ec=eo.indexOf(eF);if(ec>0&&(eo=eo.substring(0,ec)),""!==eo)return eo}var eW=250,eH=RegExp("["+em+es+"]"),eq=RegExp("[^"+es+"#]+$"),eV=!1;function parse(ee,et,en){if(et=et||{},en=new eb.ZP(en),et.defaultCountry&&!en.hasCountry(et.defaultCountry)){if(et.v2)throw new eg.Z("INVALID_COUNTRY");throw Error("Unknown country: ".concat(et.defaultCountry))}var ea=parseInput(ee,et.v2,et.extract),es=ea.number,eu=ea.ext,ec=ea.error;if(!es){if(et.v2){if("TOO_SHORT"===ec)throw new eg.Z("TOO_SHORT");throw new eg.Z("NOT_A_NUMBER")}return{}}var ed=parsePhoneNumber(es,et.defaultCountry,et.defaultCallingCode,en),ef=ed.country,ep=ed.nationalNumber,eh=ed.countryCallingCode,ey=ed.countryCallingCodeSource,em=ed.carrierCode;if(!en.hasSelectedNumberingPlan()){if(et.v2)throw new eg.Z("INVALID_COUNTRY");return{}}if(!ep||ep.lengtheo){if(et.v2)throw new eg.Z("TOO_LONG");return{}}if(et.v2){var ev=new eP(eh,ep,en.metadata);return ef&&(ev.country=ef),em&&(ev.carrierCode=em),eu&&(ev.ext=eu),ev.__countryCallingCodeSource=ey,ev}var e_=(et.extended?!!en.hasSelectedNumberingPlan():!!ef)&&matchesEntirely(ep,en.nationalNumberPattern());return et.extended?{country:ef,countryCallingCode:eh,carrierCode:em,valid:e_,possible:!!e_||!!(!0===et.extended&&en.possibleLengths()&&isPossibleNumber(ep,en)),phone:ep,ext:eu}:e_?result(ef,ep,eu):{}}function _extractFormattedPhoneNumber(ee,et,en){if(ee){if(ee.length>eW){if(en)throw new eg.Z("TOO_LONG");return}if(!1===et)return ee;var ei=ee.search(eH);if(!(ei<0))return ee.slice(ei).replace(eq,"")}}function parseInput(ee,et,en){var ei=extractFormattedPhoneNumberFromPossibleRfc3966NumberUri(ee,{extractFormattedPhoneNumber:function(ee){return _extractFormattedPhoneNumber(ee,en,et)}});if(!ei)return{};if(!isViablePhoneNumber_isViablePhoneNumber(ei))return isViablePhoneNumberStart(ei)?{error:"TOO_SHORT"}:{};var eo=extractExtension(ei);return eo.ext?eo:{number:ei}}function result(ee,et,en){var ei={country:ee,phone:et};return en&&(ei.ext=en),ei}function parsePhoneNumber(ee,et,en,ei){var eo,ea=extractCountryCallingCode(parseIncompletePhoneNumber(ee),et,en,ei.metadata),es=ea.countryCallingCodeSource,eu=ea.countryCallingCode,ec=ea.number;if(eu)ei.selectNumberingPlan(eu);else{if(!ec||!et&&!en)return{};ei.selectNumberingPlan(et,en),et?eo=et:eV&&ei.isNonGeographicCallingCode(en)&&(eo="001"),eu=en||(0,eb.Gg)(et,ei.metadata)}if(!ec)return{countryCallingCodeSource:es,countryCallingCode:eu};var ed=extractNationalNumber(parseIncompletePhoneNumber(ec),ei),ef=ed.nationalNumber,ep=ed.carrierCode,eh=getCountryByCallingCode(eu,{nationalNumber:ef,defaultCountry:et,metadata:ei});return eh&&(eo=eh,"001"===eh||ei.country(eo)),{country:eo,countryCallingCode:eu,countryCallingCodeSource:es,nationalNumber:ef,carrierCode:ep}}function parsePhoneNumberWithError_ownKeys(ee,et){var en=Object.keys(ee);if(Object.getOwnPropertySymbols){var ei=Object.getOwnPropertySymbols(ee);et&&(ei=ei.filter(function(et){return Object.getOwnPropertyDescriptor(ee,et).enumerable})),en.push.apply(en,ei)}return en}function parsePhoneNumberWithError_objectSpread(ee){for(var et=1;et"checkbox"===ee.type,isDateObject=ee=>ee instanceof Date,isNullOrUndefined=ee=>null==ee;let isObjectType=ee=>"object"==typeof ee;var isObject=ee=>!isNullOrUndefined(ee)&&!Array.isArray(ee)&&isObjectType(ee)&&!isDateObject(ee),getEventValue=ee=>isObject(ee)&&ee.target?isCheckBoxInput(ee.target)?ee.target.checked:ee.target.value:ee,getNodeParentName=ee=>ee.substring(0,ee.search(/\.\d+(\.|$)/))||ee,isNameInFieldArray=(ee,et)=>ee.has(getNodeParentName(et)),isPlainObject=ee=>{let et=ee.constructor&&ee.constructor.prototype;return isObject(et)&&et.hasOwnProperty("isPrototypeOf")},eo="undefined"!=typeof window&&void 0!==window.HTMLElement&&"undefined"!=typeof document;function cloneObject(ee){let et;let en=Array.isArray(ee);if(ee instanceof Date)et=new Date(ee);else if(ee instanceof Set)et=new Set(ee);else if(!(!(eo&&(ee instanceof Blob||ee instanceof FileList))&&(en||isObject(ee))))return ee;else if(et=en?[]:{},en||isPlainObject(ee))for(let en in ee)ee.hasOwnProperty(en)&&(et[en]=cloneObject(ee[en]));else et=ee;return et}var compact=ee=>Array.isArray(ee)?ee.filter(Boolean):[],isUndefined=ee=>void 0===ee,get=(ee,et,en)=>{if(!et||!isObject(ee))return en;let ei=compact(et.split(/[,[\].]+?/)).reduce((ee,et)=>isNullOrUndefined(ee)?ee:ee[et],ee);return isUndefined(ei)||ei===ee?isUndefined(ee[et])?en:ee[et]:ei},isBoolean=ee=>"boolean"==typeof ee;let ea={BLUR:"blur",FOCUS_OUT:"focusout",CHANGE:"change"},es={onBlur:"onBlur",onChange:"onChange",onSubmit:"onSubmit",onTouched:"onTouched",all:"all"},eu={max:"max",min:"min",maxLength:"maxLength",minLength:"minLength",pattern:"pattern",required:"required",validate:"validate"},ec=ei.createContext(null),useFormContext=()=>ei.useContext(ec),FormProvider=ee=>{let{children:et,...en}=ee;return ei.createElement(ec.Provider,{value:en},et)};var getProxyFormState=(ee,et,en,ei=!0)=>{let eo={defaultValues:et._defaultValues};for(let ea in ee)Object.defineProperty(eo,ea,{get:()=>{let eo=ea;return et._proxyFormState[eo]!==es.all&&(et._proxyFormState[eo]=!ei||es.all),en&&(en[eo]=!0),ee[eo]}});return eo},isEmptyObject=ee=>isObject(ee)&&!Object.keys(ee).length,shouldRenderFormState=(ee,et,en,ei)=>{en(ee);let{name:eo,...ea}=ee;return isEmptyObject(ea)||Object.keys(ea).length>=Object.keys(et).length||Object.keys(ea).find(ee=>et[ee]===(!ei||es.all))},convertToArrayPayload=ee=>Array.isArray(ee)?ee:[ee],shouldSubscribeByName=(ee,et,en)=>!ee||!et||ee===et||convertToArrayPayload(ee).some(ee=>ee&&(en?ee===et:ee.startsWith(et)||et.startsWith(ee)));function useSubscribe(ee){let et=ei.useRef(ee);et.current=ee,ei.useEffect(()=>{let en=!ee.disabled&&et.current.subject&&et.current.subject.subscribe({next:et.current.next});return()=>{en&&en.unsubscribe()}},[ee.disabled])}function useFormState(ee){let et=useFormContext(),{control:en=et.control,disabled:eo,name:ea,exact:es}=ee||{},[eu,ec]=ei.useState(en._formState),ed=ei.useRef(!0),ef=ei.useRef({isDirty:!1,isLoading:!1,dirtyFields:!1,touchedFields:!1,isValidating:!1,isValid:!1,errors:!1}),ep=ei.useRef(ea);return ep.current=ea,useSubscribe({disabled:eo,next:ee=>ed.current&&shouldSubscribeByName(ep.current,ee.name,es)&&shouldRenderFormState(ee,ef.current,en._updateFormState)&&ec({...en._formState,...ee}),subject:en._subjects.state}),ei.useEffect(()=>(ed.current=!0,ef.current.isValid&&en._updateValid(!0),()=>{ed.current=!1}),[en]),getProxyFormState(eu,en,ef.current,!1)}var isString=ee=>"string"==typeof ee,generateWatchOutput=(ee,et,en,ei,eo)=>isString(ee)?(ei&&et.watch.add(ee),get(en,ee,eo)):Array.isArray(ee)?ee.map(ee=>(ei&&et.watch.add(ee),get(en,ee))):(ei&&(et.watchAll=!0),en);function useWatch(ee){let et=useFormContext(),{control:en=et.control,name:eo,defaultValue:ea,disabled:es,exact:eu}=ee||{},ec=ei.useRef(eo);ec.current=eo,useSubscribe({disabled:es,subject:en._subjects.values,next:ee=>{shouldSubscribeByName(ec.current,ee.name,eu)&&ef(cloneObject(generateWatchOutput(ec.current,en._names,ee.values||en._formValues,!1,ea)))}});let[ed,ef]=ei.useState(en._getWatch(eo,ea));return ei.useEffect(()=>en._removeUnmounted()),ed}var isKey=ee=>/^\w*$/.test(ee),stringToPath=ee=>compact(ee.replace(/["|']|\]/g,"").split(/\.|\[/)),set=(ee,et,en)=>{let ei=-1,eo=isKey(et)?[et]:stringToPath(et),ea=eo.length,es=ea-1;for(;++ei{let ee=es._options.shouldUnregister||eu,updateMounted=(ee,et)=>{let en=get(es._fields,ee);en&&(en._f.mount=et)};if(updateMounted(en,!0),ee){let ee=cloneObject(get(es._options.defaultValues,en));set(es._defaultValues,en,ee),isUndefined(get(es._formValues,en))&&set(es._formValues,en,ee)}return()=>{(ec?ee&&!es._state.action:ee)?es.unregister(en):updateMounted(en,!1)}},[en,es,ec,eu]),ei.useEffect(()=>{get(es._fields,en)&&es._updateDisabledField({disabled:eo,fields:es._fields,name:en,value:get(es._fields,en)._f.value})},[eo,en,es]),{field:{name:en,value:ed,...isBoolean(eo)||isBoolean(ef.disabled)?{disabled:ef.disabled||eo}:{},onChange:ei.useCallback(ee=>ep.current.onChange({target:{value:getEventValue(ee),name:en},type:ea.CHANGE}),[en]),onBlur:ei.useCallback(()=>ep.current.onBlur({target:{value:get(es._formValues,en),name:en},type:ea.BLUR}),[en,es]),ref:ee=>{let et=get(es._fields,en);et&&ee&&(et._f.ref={focus:()=>ee.focus(),select:()=>ee.select(),setCustomValidity:et=>ee.setCustomValidity(et),reportValidity:()=>ee.reportValidity()})}},formState:ef,fieldState:Object.defineProperties({},{invalid:{enumerable:!0,get:()=>!!get(ef.errors,en)},isDirty:{enumerable:!0,get:()=>!!get(ef.dirtyFields,en)},isTouched:{enumerable:!0,get:()=>!!get(ef.touchedFields,en)},error:{enumerable:!0,get:()=>get(ef.errors,en)}})}}let Controller=ee=>ee.render(useController(ee));var appendErrors=(ee,et,en,ei,eo)=>et?{...en[ee],types:{...en[ee]&&en[ee].types?en[ee].types:{},[ei]:eo||!0}}:{},getValidationModes=ee=>({isOnSubmit:!ee||ee===es.onSubmit,isOnBlur:ee===es.onBlur,isOnChange:ee===es.onChange,isOnAll:ee===es.all,isOnTouch:ee===es.onTouched}),isWatched=(ee,et,en)=>!en&&(et.watchAll||et.watch.has(ee)||[...et.watch].some(et=>ee.startsWith(et)&&/^\.\w+/.test(ee.slice(et.length))));let iterateFieldsByAction=(ee,et,en,ei)=>{for(let eo of en||Object.keys(ee)){let en=get(ee,eo);if(en){let{_f:ee,...ea}=en;if(ee){if(ee.refs&&ee.refs[0]&&et(ee.refs[0],eo)&&!ei||ee.ref&&et(ee.ref,ee.name)&&!ei)break;iterateFieldsByAction(ea,et)}else isObject(ea)&&iterateFieldsByAction(ea,et)}}};var updateFieldArrayRootError=(ee,et,en)=>{let ei=compact(get(ee,en));return set(ei,"root",et[en]),set(ee,en,ei),ee},isFileInput=ee=>"file"===ee.type,isFunction=ee=>"function"==typeof ee,isHTMLElement=ee=>{if(!eo)return!1;let et=ee?ee.ownerDocument:0;return ee instanceof(et&&et.defaultView?et.defaultView.HTMLElement:HTMLElement)},isMessage=ee=>isString(ee),isRadioInput=ee=>"radio"===ee.type,isRegex=ee=>ee instanceof RegExp;let ed={value:!1,isValid:!1},ef={value:!0,isValid:!0};var getCheckboxValue=ee=>{if(Array.isArray(ee)){if(ee.length>1){let et=ee.filter(ee=>ee&&ee.checked&&!ee.disabled).map(ee=>ee.value);return{value:et,isValid:!!et.length}}return ee[0].checked&&!ee[0].disabled?ee[0].attributes&&!isUndefined(ee[0].attributes.value)?isUndefined(ee[0].value)||""===ee[0].value?ef:{value:ee[0].value,isValid:!0}:ef:ed}return ed};let ep={isValid:!1,value:null};var getRadioValue=ee=>Array.isArray(ee)?ee.reduce((ee,et)=>et&&et.checked&&!et.disabled?{isValid:!0,value:et.value}:ee,ep):ep;function getValidateError(ee,et,en="validate"){if(isMessage(ee)||Array.isArray(ee)&&ee.every(isMessage)||isBoolean(ee)&&!ee)return{type:en,message:isMessage(ee)?ee:"",ref:et}}var getValueAndMessage=ee=>isObject(ee)&&!isRegex(ee)?ee:{value:ee,message:""},validateField=async(ee,et,en,ei,eo)=>{let{ref:ea,refs:es,required:ec,maxLength:ed,minLength:ef,min:ep,max:eh,pattern:ey,validate:em,name:eg,valueAsNumber:eb,mount:ev,disabled:e_}=ee._f,ew=get(et,eg);if(!ev||e_)return{};let eS=es?es[0]:ea,setCustomValidity=ee=>{ei&&eS.reportValidity&&(eS.setCustomValidity(isBoolean(ee)?"":ee||""),eS.reportValidity())},eE={},eA=isRadioInput(ea),e$=isCheckBoxInput(ea),ex=eA||e$,eC=(eb||isFileInput(ea))&&isUndefined(ea.value)&&isUndefined(ew)||isHTMLElement(ea)&&""===ea.value||""===ew||Array.isArray(ew)&&!ew.length,ek=appendErrors.bind(null,eg,en,eE),getMinMaxMessage=(ee,et,en,ei=eu.maxLength,eo=eu.minLength)=>{let es=ee?et:en;eE[eg]={type:ee?ei:eo,message:es,ref:ea,...ek(ee?ei:eo,es)}};if(eo?!Array.isArray(ew)||!ew.length:ec&&(!ex&&(eC||isNullOrUndefined(ew))||isBoolean(ew)&&!ew||e$&&!getCheckboxValue(es).isValid||eA&&!getRadioValue(es).isValid)){let{value:ee,message:et}=isMessage(ec)?{value:!!ec,message:ec}:getValueAndMessage(ec);if(ee&&(eE[eg]={type:eu.required,message:et,ref:eS,...ek(eu.required,et)},!en))return setCustomValidity(et),eE}if(!eC&&(!isNullOrUndefined(ep)||!isNullOrUndefined(eh))){let ee,et;let ei=getValueAndMessage(eh),eo=getValueAndMessage(ep);if(isNullOrUndefined(ew)||isNaN(ew)){let en=ea.valueAsDate||new Date(ew),convertTimeToDate=ee=>new Date(new Date().toDateString()+" "+ee),es="time"==ea.type,eu="week"==ea.type;isString(ei.value)&&ew&&(ee=es?convertTimeToDate(ew)>convertTimeToDate(ei.value):eu?ew>ei.value:en>new Date(ei.value)),isString(eo.value)&&ew&&(et=es?convertTimeToDate(ew)ei.value),isNullOrUndefined(eo.value)||(et=en+ee.value,eo=!isNullOrUndefined(et.value)&&ew.length<+et.value;if((ei||eo)&&(getMinMaxMessage(ei,ee.message,et.message),!en))return setCustomValidity(eE[eg].message),eE}if(ey&&!eC&&isString(ew)){let{value:ee,message:et}=getValueAndMessage(ey);if(isRegex(ee)&&!ew.match(ee)&&(eE[eg]={type:eu.pattern,message:et,ref:ea,...ek(eu.pattern,et)},!en))return setCustomValidity(et),eE}if(em){if(isFunction(em)){let ee=await em(ew,et),ei=getValidateError(ee,eS);if(ei&&(eE[eg]={...ei,...ek(eu.validate,ei.message)},!en))return setCustomValidity(ei.message),eE}else if(isObject(em)){let ee={};for(let ei in em){if(!isEmptyObject(ee)&&!en)break;let eo=getValidateError(await em[ei](ew,et),eS,ei);eo&&(ee={...eo,...ek(ei,eo.message)},setCustomValidity(eo.message),en&&(eE[eg]=ee))}if(!isEmptyObject(ee)&&(eE[eg]={ref:eS,...ee},!en))return eE}}return setCustomValidity(!0),eE};function baseGet(ee,et){let en=et.slice(0,-1).length,ei=0;for(;ei{let ee=[],next=et=>{for(let en of ee)en.next&&en.next(et)},subscribe=et=>(ee.push(et),{unsubscribe:()=>{ee=ee.filter(ee=>ee!==et)}}),unsubscribe=()=>{ee=[]};return{get observers(){return ee},next,subscribe,unsubscribe}},isPrimitive=ee=>isNullOrUndefined(ee)||!isObjectType(ee);function deepEqual(ee,et){if(isPrimitive(ee)||isPrimitive(et))return ee===et;if(isDateObject(ee)&&isDateObject(et))return ee.getTime()===et.getTime();let en=Object.keys(ee),ei=Object.keys(et);if(en.length!==ei.length)return!1;for(let eo of en){let en=ee[eo];if(!ei.includes(eo))return!1;if("ref"!==eo){let ee=et[eo];if(isDateObject(en)&&isDateObject(ee)||isObject(en)&&isObject(ee)||Array.isArray(en)&&Array.isArray(ee)?!deepEqual(en,ee):en!==ee)return!1}}return!0}var isMultipleSelect=ee=>"select-multiple"===ee.type,isRadioOrCheckbox=ee=>isRadioInput(ee)||isCheckBoxInput(ee),live=ee=>isHTMLElement(ee)&&ee.isConnected,objectHasFunction=ee=>{for(let et in ee)if(isFunction(ee[et]))return!0;return!1};function markFieldsDirty(ee,et={}){let en=Array.isArray(ee);if(isObject(ee)||en)for(let en in ee)Array.isArray(ee[en])||isObject(ee[en])&&!objectHasFunction(ee[en])?(et[en]=Array.isArray(ee[en])?[]:{},markFieldsDirty(ee[en],et[en])):isNullOrUndefined(ee[en])||(et[en]=!0);return et}function getDirtyFieldsFromDefaultValues(ee,et,en){let ei=Array.isArray(ee);if(isObject(ee)||ei)for(let ei in ee)Array.isArray(ee[ei])||isObject(ee[ei])&&!objectHasFunction(ee[ei])?isUndefined(et)||isPrimitive(en[ei])?en[ei]=Array.isArray(ee[ei])?markFieldsDirty(ee[ei],[]):{...markFieldsDirty(ee[ei])}:getDirtyFieldsFromDefaultValues(ee[ei],isNullOrUndefined(et)?{}:et[ei],en[ei]):en[ei]=!deepEqual(ee[ei],et[ei]);return en}var getDirtyFields=(ee,et)=>getDirtyFieldsFromDefaultValues(ee,et,markFieldsDirty(et)),getFieldValueAs=(ee,{valueAsNumber:et,valueAsDate:en,setValueAs:ei})=>isUndefined(ee)?ee:et?""===ee?NaN:ee?+ee:ee:en&&isString(ee)?new Date(ee):ei?ei(ee):ee;function getFieldValue(ee){let et=ee.ref;return(ee.refs?ee.refs.every(ee=>ee.disabled):et.disabled)?void 0:isFileInput(et)?et.files:isRadioInput(et)?getRadioValue(ee.refs).value:isMultipleSelect(et)?[...et.selectedOptions].map(({value:ee})=>ee):isCheckBoxInput(et)?getCheckboxValue(ee.refs).value:getFieldValueAs(isUndefined(et.value)?ee.ref.value:et.value,ee)}var getResolverOptions=(ee,et,en,ei)=>{let eo={};for(let en of ee){let ee=get(et,en);ee&&set(eo,en,ee._f)}return{criteriaMode:en,names:[...ee],fields:eo,shouldUseNativeValidation:ei}},getRuleValue=ee=>isUndefined(ee)?ee:isRegex(ee)?ee.source:isObject(ee)?isRegex(ee.value)?ee.value.source:ee.value:ee,hasValidation=ee=>ee.mount&&(ee.required||ee.min||ee.max||ee.maxLength||ee.minLength||ee.pattern||ee.validate);function schemaErrorLookup(ee,et,en){let ei=get(ee,en);if(ei||isKey(en))return{error:ei,name:en};let eo=en.split(".");for(;eo.length;){let ei=eo.join("."),ea=get(et,ei),es=get(ee,ei);if(ea&&!Array.isArray(ea)&&en!==ei)break;if(es&&es.type)return{name:ei,error:es};eo.pop()}return{name:en}}var skipValidation=(ee,et,en,ei,eo)=>!eo.isOnAll&&(!en&&eo.isOnTouch?!(et||ee):(en?ei.isOnBlur:eo.isOnBlur)?!ee:(en?!ei.isOnChange:!eo.isOnChange)||ee),unsetEmptyArray=(ee,et)=>!compact(get(ee,et)).length&&unset(ee,et);let eh={mode:es.onSubmit,reValidateMode:es.onChange,shouldFocusError:!0};function createFormControl(ee={},et){let en,ei={...eh,...ee},eu={submitCount:0,isDirty:!1,isLoading:isFunction(ei.defaultValues),isValidating:!1,isSubmitted:!1,isSubmitting:!1,isSubmitSuccessful:!1,isValid:!1,touchedFields:{},dirtyFields:{},errors:ei.errors||{},disabled:!1},ec={},ed=(isObject(ei.defaultValues)||isObject(ei.values))&&cloneObject(ei.defaultValues||ei.values)||{},ef=ei.shouldUnregister?{}:cloneObject(ed),ep={action:!1,mount:!1,watch:!1},ey={mount:new Set,unMount:new Set,array:new Set,watch:new Set},em=0,eg={isDirty:!1,dirtyFields:!1,touchedFields:!1,isValidating:!1,isValid:!1,errors:!1},eb={values:createSubject(),array:createSubject(),state:createSubject()},ev=ee.resetOptions&&ee.resetOptions.keepDirtyValues,e_=getValidationModes(ei.mode),ew=getValidationModes(ei.reValidateMode),eS=ei.criteriaMode===es.all,debounce=ee=>et=>{clearTimeout(em),em=setTimeout(ee,et)},_updateValid=async ee=>{if(eg.isValid||ee){let ee=ei.resolver?isEmptyObject((await _executeSchema()).errors):await executeBuiltInValidation(ec,!0);ee!==eu.isValid&&eb.state.next({isValid:ee})}},_updateIsValidating=ee=>eg.isValidating&&eb.state.next({isValidating:ee}),_updateFieldArray=(ee,et=[],en,ei,eo=!0,ea=!0)=>{if(ei&&en){if(ep.action=!0,ea&&Array.isArray(get(ec,ee))){let et=en(get(ec,ee),ei.argA,ei.argB);eo&&set(ec,ee,et)}if(ea&&Array.isArray(get(eu.errors,ee))){let et=en(get(eu.errors,ee),ei.argA,ei.argB);eo&&set(eu.errors,ee,et),unsetEmptyArray(eu.errors,ee)}if(eg.touchedFields&&ea&&Array.isArray(get(eu.touchedFields,ee))){let et=en(get(eu.touchedFields,ee),ei.argA,ei.argB);eo&&set(eu.touchedFields,ee,et)}eg.dirtyFields&&(eu.dirtyFields=getDirtyFields(ed,ef)),eb.state.next({name:ee,isDirty:_getDirty(ee,et),dirtyFields:eu.dirtyFields,errors:eu.errors,isValid:eu.isValid})}else set(ef,ee,et)},updateErrors=(ee,et)=>{set(eu.errors,ee,et),eb.state.next({errors:eu.errors})},_setErrors=ee=>{eu.errors=ee,eb.state.next({errors:eu.errors,isValid:!1})},updateValidAndValue=(ee,et,en,ei)=>{let eo=get(ec,ee);if(eo){let ea=get(ef,ee,isUndefined(en)?get(ed,ee):en);isUndefined(ea)||ei&&ei.defaultChecked||et?set(ef,ee,et?ea:getFieldValue(eo._f)):setFieldValue(ee,ea),ep.mount&&_updateValid()}},updateTouchAndDirty=(ee,et,en,ei,eo)=>{let ea=!1,es=!1,ef={name:ee},ep=!!(get(ec,ee)&&get(ec,ee)._f.disabled);if(!en||ei){eg.isDirty&&(es=eu.isDirty,eu.isDirty=ef.isDirty=_getDirty(),ea=es!==ef.isDirty);let en=ep||deepEqual(get(ed,ee),et);es=!!(!ep&&get(eu.dirtyFields,ee)),en||ep?unset(eu.dirtyFields,ee):set(eu.dirtyFields,ee,!0),ef.dirtyFields=eu.dirtyFields,ea=ea||eg.dirtyFields&&!en!==es}if(en){let et=get(eu.touchedFields,ee);et||(set(eu.touchedFields,ee,en),ef.touchedFields=eu.touchedFields,ea=ea||eg.touchedFields&&et!==en)}return ea&&eo&&eb.state.next(ef),ea?ef:{}},shouldRenderByError=(et,ei,eo,ea)=>{let es=get(eu.errors,et),ec=eg.isValid&&isBoolean(ei)&&eu.isValid!==ei;if(ee.delayError&&eo?(en=debounce(()=>updateErrors(et,eo)))(ee.delayError):(clearTimeout(em),en=null,eo?set(eu.errors,et,eo):unset(eu.errors,et)),(eo?!deepEqual(es,eo):es)||!isEmptyObject(ea)||ec){let ee={...ea,...ec&&isBoolean(ei)?{isValid:ei}:{},errors:eu.errors,name:et};eu={...eu,...ee},eb.state.next(ee)}_updateIsValidating(!1)},_executeSchema=async ee=>ei.resolver(ef,ei.context,getResolverOptions(ee||ey.mount,ec,ei.criteriaMode,ei.shouldUseNativeValidation)),executeSchemaAndUpdateState=async ee=>{let{errors:et}=await _executeSchema(ee);if(ee)for(let en of ee){let ee=get(et,en);ee?set(eu.errors,en,ee):unset(eu.errors,en)}else eu.errors=et;return et},executeBuiltInValidation=async(ee,et,en={valid:!0})=>{for(let eo in ee){let ea=ee[eo];if(ea){let{_f:ee,...eo}=ea;if(ee){let eo=ey.array.has(ee.name),es=await validateField(ea,ef,eS,ei.shouldUseNativeValidation&&!et,eo);if(es[ee.name]&&(en.valid=!1,et))break;et||(get(es,ee.name)?eo?updateFieldArrayRootError(eu.errors,es,ee.name):set(eu.errors,ee.name,es[ee.name]):unset(eu.errors,ee.name))}eo&&await executeBuiltInValidation(eo,et,en)}}return en.valid},_removeUnmounted=()=>{for(let ee of ey.unMount){let et=get(ec,ee);et&&(et._f.refs?et._f.refs.every(ee=>!live(ee)):!live(et._f.ref))&&unregister(ee)}ey.unMount=new Set},_getDirty=(ee,et)=>(ee&&et&&set(ef,ee,et),!deepEqual(getValues(),ed)),_getWatch=(ee,et,en)=>generateWatchOutput(ee,ey,{...ep.mount?ef:isUndefined(et)?ed:isString(ee)?{[ee]:et}:et},en,et),_getFieldArray=et=>compact(get(ep.mount?ef:ed,et,ee.shouldUnregister?get(ed,et,[]):[])),setFieldValue=(ee,et,en={})=>{let ei=get(ec,ee),eo=et;if(ei){let en=ei._f;en&&(en.disabled||set(ef,ee,getFieldValueAs(et,en)),eo=isHTMLElement(en.ref)&&isNullOrUndefined(et)?"":et,isMultipleSelect(en.ref)?[...en.ref.options].forEach(ee=>ee.selected=eo.includes(ee.value)):en.refs?isCheckBoxInput(en.ref)?en.refs.length>1?en.refs.forEach(ee=>(!ee.defaultChecked||!ee.disabled)&&(ee.checked=Array.isArray(eo)?!!eo.find(et=>et===ee.value):eo===ee.value)):en.refs[0]&&(en.refs[0].checked=!!eo):en.refs.forEach(ee=>ee.checked=ee.value===eo):isFileInput(en.ref)?en.ref.value="":(en.ref.value=eo,en.ref.type||eb.values.next({name:ee,values:{...ef}})))}(en.shouldDirty||en.shouldTouch)&&updateTouchAndDirty(ee,eo,en.shouldTouch,en.shouldDirty,!0),en.shouldValidate&&trigger(ee)},setValues=(ee,et,en)=>{for(let ei in et){let eo=et[ei],ea=`${ee}.${ei}`,es=get(ec,ea);!ey.array.has(ee)&&isPrimitive(eo)&&(!es||es._f)||isDateObject(eo)?setFieldValue(ea,eo,en):setValues(ea,eo,en)}},setValue=(ee,en,ei={})=>{let eo=get(ec,ee),ea=ey.array.has(ee),es=cloneObject(en);set(ef,ee,es),ea?(eb.array.next({name:ee,values:{...ef}}),(eg.isDirty||eg.dirtyFields)&&ei.shouldDirty&&eb.state.next({name:ee,dirtyFields:getDirtyFields(ed,ef),isDirty:_getDirty(ee,es)})):!eo||eo._f||isNullOrUndefined(es)?setFieldValue(ee,es,ei):setValues(ee,es,ei),isWatched(ee,ey)&&eb.state.next({...eu}),eb.values.next({name:ee,values:{...ef}}),ep.mount||et()},onChange=async ee=>{let et=ee.target,eo=et.name,es=!0,ed=get(ec,eo),getCurrentFieldValue=()=>et.type?getFieldValue(ed._f):getEventValue(ee),_updateIsFieldValueUpdated=ee=>{es=Number.isNaN(ee)||ee===get(ef,eo,ee)};if(ed){let et,ep;let eh=getCurrentFieldValue(),em=ee.type===ea.BLUR||ee.type===ea.FOCUS_OUT,ev=!hasValidation(ed._f)&&!ei.resolver&&!get(eu.errors,eo)&&!ed._f.deps||skipValidation(em,get(eu.touchedFields,eo),eu.isSubmitted,ew,e_),eE=isWatched(eo,ey,em);set(ef,eo,eh),em?(ed._f.onBlur&&ed._f.onBlur(ee),en&&en(0)):ed._f.onChange&&ed._f.onChange(ee);let eA=updateTouchAndDirty(eo,eh,em,!1),e$=!isEmptyObject(eA)||eE;if(em||eb.values.next({name:eo,type:ee.type,values:{...ef}}),ev)return eg.isValid&&_updateValid(),e$&&eb.state.next({name:eo,...eE?{}:eA});if(!em&&eE&&eb.state.next({...eu}),_updateIsValidating(!0),ei.resolver){let{errors:ee}=await _executeSchema([eo]);if(_updateIsFieldValueUpdated(eh),es){let en=schemaErrorLookup(eu.errors,ec,eo),ei=schemaErrorLookup(ee,ec,en.name||eo);et=ei.error,eo=ei.name,ep=isEmptyObject(ee)}}else et=(await validateField(ed,ef,eS,ei.shouldUseNativeValidation))[eo],_updateIsFieldValueUpdated(eh),es&&(et?ep=!1:eg.isValid&&(ep=await executeBuiltInValidation(ec,!0)));es&&(ed._f.deps&&trigger(ed._f.deps),shouldRenderByError(eo,ep,et,eA))}},_focusInput=(ee,et)=>{if(get(eu.errors,et)&&ee.focus)return ee.focus(),1},trigger=async(ee,et={})=>{let en,eo;let ea=convertToArrayPayload(ee);if(_updateIsValidating(!0),ei.resolver){let et=await executeSchemaAndUpdateState(isUndefined(ee)?ee:ea);en=isEmptyObject(et),eo=ee?!ea.some(ee=>get(et,ee)):en}else ee?((eo=(await Promise.all(ea.map(async ee=>{let et=get(ec,ee);return await executeBuiltInValidation(et&&et._f?{[ee]:et}:et)}))).every(Boolean))||eu.isValid)&&_updateValid():eo=en=await executeBuiltInValidation(ec);return eb.state.next({...!isString(ee)||eg.isValid&&en!==eu.isValid?{}:{name:ee},...ei.resolver||!ee?{isValid:en}:{},errors:eu.errors,isValidating:!1}),et.shouldFocus&&!eo&&iterateFieldsByAction(ec,_focusInput,ee?ea:ey.mount),eo},getValues=ee=>{let et={...ed,...ep.mount?ef:{}};return isUndefined(ee)?et:isString(ee)?get(et,ee):ee.map(ee=>get(et,ee))},getFieldState=(ee,et)=>({invalid:!!get((et||eu).errors,ee),isDirty:!!get((et||eu).dirtyFields,ee),isTouched:!!get((et||eu).touchedFields,ee),error:get((et||eu).errors,ee)}),clearErrors=ee=>{ee&&convertToArrayPayload(ee).forEach(ee=>unset(eu.errors,ee)),eb.state.next({errors:ee?eu.errors:{}})},setError=(ee,et,en)=>{let ei=(get(ec,ee,{_f:{}})._f||{}).ref;set(eu.errors,ee,{...et,ref:ei}),eb.state.next({name:ee,errors:eu.errors,isValid:!1}),en&&en.shouldFocus&&ei&&ei.focus&&ei.focus()},watch=(ee,et)=>isFunction(ee)?eb.values.subscribe({next:en=>ee(_getWatch(void 0,et),en)}):_getWatch(ee,et,!0),unregister=(ee,et={})=>{for(let en of ee?convertToArrayPayload(ee):ey.mount)ey.mount.delete(en),ey.array.delete(en),et.keepValue||(unset(ec,en),unset(ef,en)),et.keepError||unset(eu.errors,en),et.keepDirty||unset(eu.dirtyFields,en),et.keepTouched||unset(eu.touchedFields,en),ei.shouldUnregister||et.keepDefaultValue||unset(ed,en);eb.values.next({values:{...ef}}),eb.state.next({...eu,...et.keepDirty?{isDirty:_getDirty()}:{}}),et.keepIsValid||_updateValid()},_updateDisabledField=({disabled:ee,name:et,field:en,fields:ei,value:eo})=>{if(isBoolean(ee)){let ea=ee?void 0:isUndefined(eo)?getFieldValue(en?en._f:get(ei,et)._f):eo;set(ef,et,ea),updateTouchAndDirty(et,ea,!1,!1,!0)}},register=(ee,et={})=>{let en=get(ec,ee),eo=isBoolean(et.disabled);return set(ec,ee,{...en||{},_f:{...en&&en._f?en._f:{ref:{name:ee}},name:ee,mount:!0,...et}}),ey.mount.add(ee),en?_updateDisabledField({field:en,disabled:et.disabled,name:ee,value:et.value}):updateValidAndValue(ee,!0,et.value),{...eo?{disabled:et.disabled}:{},...ei.progressive?{required:!!et.required,min:getRuleValue(et.min),max:getRuleValue(et.max),minLength:getRuleValue(et.minLength),maxLength:getRuleValue(et.maxLength),pattern:getRuleValue(et.pattern)}:{},name:ee,onChange,onBlur:onChange,ref:eo=>{if(eo){register(ee,et),en=get(ec,ee);let ei=isUndefined(eo.value)&&eo.querySelectorAll&&eo.querySelectorAll("input,select,textarea")[0]||eo,ea=isRadioOrCheckbox(ei),es=en._f.refs||[];(ea?es.find(ee=>ee===ei):ei===en._f.ref)||(set(ec,ee,{_f:{...en._f,...ea?{refs:[...es.filter(live),ei,...Array.isArray(get(ed,ee))?[{}]:[]],ref:{type:ei.type,name:ee}}:{ref:ei}}}),updateValidAndValue(ee,!1,void 0,ei))}else(en=get(ec,ee,{}))._f&&(en._f.mount=!1),(ei.shouldUnregister||et.shouldUnregister)&&!(isNameInFieldArray(ey.array,ee)&&ep.action)&&ey.unMount.add(ee)}}},_focusError=()=>ei.shouldFocusError&&iterateFieldsByAction(ec,_focusInput,ey.mount),_disableForm=ee=>{isBoolean(ee)&&(eb.state.next({disabled:ee}),iterateFieldsByAction(ec,(et,en)=>{let ei=ee,eo=get(ec,en);eo&&isBoolean(eo._f.disabled)&&(ei||(ei=eo._f.disabled)),et.disabled=ei},0,!1))},handleSubmit=(ee,et)=>async en=>{en&&(en.preventDefault&&en.preventDefault(),en.persist&&en.persist());let eo=cloneObject(ef);if(eb.state.next({isSubmitting:!0}),ei.resolver){let{errors:ee,values:et}=await _executeSchema();eu.errors=ee,eo=et}else await executeBuiltInValidation(ec);unset(eu.errors,"root"),isEmptyObject(eu.errors)?(eb.state.next({errors:{}}),await ee(eo,en)):(et&&await et({...eu.errors},en),_focusError(),setTimeout(_focusError)),eb.state.next({isSubmitted:!0,isSubmitting:!1,isSubmitSuccessful:isEmptyObject(eu.errors),submitCount:eu.submitCount+1,errors:eu.errors})},resetField=(ee,et={})=>{get(ec,ee)&&(isUndefined(et.defaultValue)?setValue(ee,get(ed,ee)):(setValue(ee,et.defaultValue),set(ed,ee,et.defaultValue)),et.keepTouched||unset(eu.touchedFields,ee),et.keepDirty||(unset(eu.dirtyFields,ee),eu.isDirty=et.defaultValue?_getDirty(ee,get(ed,ee)):_getDirty()),!et.keepError&&(unset(eu.errors,ee),eg.isValid&&_updateValid()),eb.state.next({...eu}))},_reset=(en,ei={})=>{let ea=en?cloneObject(en):ed,es=cloneObject(ea),eh=en&&!isEmptyObject(en)?es:ed;if(ei.keepDefaultValues||(ed=ea),!ei.keepValues){if(ei.keepDirtyValues||ev)for(let ee of ey.mount)get(eu.dirtyFields,ee)?set(eh,ee,get(ef,ee)):setValue(ee,get(eh,ee));else{if(eo&&isUndefined(en))for(let ee of ey.mount){let et=get(ec,ee);if(et&&et._f){let ee=Array.isArray(et._f.refs)?et._f.refs[0]:et._f.ref;if(isHTMLElement(ee)){let et=ee.closest("form");if(et){et.reset();break}}}}ec={}}ef=ee.shouldUnregister?ei.keepDefaultValues?cloneObject(ed):{}:cloneObject(eh),eb.array.next({values:{...eh}}),eb.values.next({values:{...eh}})}ey={mount:new Set,unMount:new Set,array:new Set,watch:new Set,watchAll:!1,focus:""},ep.mount||et(),ep.mount=!eg.isValid||!!ei.keepIsValid,ep.watch=!!ee.shouldUnregister,eb.state.next({submitCount:ei.keepSubmitCount?eu.submitCount:0,isDirty:ei.keepDirty?eu.isDirty:!!(ei.keepDefaultValues&&!deepEqual(en,ed)),isSubmitted:!!ei.keepIsSubmitted&&eu.isSubmitted,dirtyFields:ei.keepDirtyValues?eu.dirtyFields:ei.keepDefaultValues&&en?getDirtyFields(ed,en):{},touchedFields:ei.keepTouched?eu.touchedFields:{},errors:ei.keepErrors?eu.errors:{},isSubmitSuccessful:!!ei.keepIsSubmitSuccessful&&eu.isSubmitSuccessful,isSubmitting:!1})},reset=(ee,et)=>_reset(isFunction(ee)?ee(ef):ee,et),setFocus=(ee,et={})=>{let en=get(ec,ee),ei=en&&en._f;if(ei){let ee=ei.refs?ei.refs[0]:ei.ref;ee.focus&&(ee.focus(),et.shouldSelect&&ee.select())}},_updateFormState=ee=>{eu={...eu,...ee}},_resetDefaultValues=()=>isFunction(ei.defaultValues)&&ei.defaultValues().then(ee=>{reset(ee,ei.resetOptions),eb.state.next({isLoading:!1})});return{control:{register,unregister,getFieldState,handleSubmit,setError,_executeSchema,_getWatch,_getDirty,_updateValid,_removeUnmounted,_updateFieldArray,_updateDisabledField,_getFieldArray,_reset,_resetDefaultValues,_updateFormState,_disableForm,_subjects:eb,_proxyFormState:eg,_setErrors,get _fields(){return ec},get _formValues(){return ef},get _state(){return ep},set _state(value){ep=value},get _defaultValues(){return ed},get _names(){return ey},set _names(value){ey=value},get _formState(){return eu},set _formState(value){eu=value},get _options(){return ei},set _options(value){ei={...ei,...value}}},trigger,register,handleSubmit,watch,setValue,getValues,reset,resetField,clearErrors,unregister,setError,setFocus,getFieldState}}function useForm(ee={}){let et=ei.useRef(),en=ei.useRef(),[eo,ea]=ei.useState({isDirty:!1,isValidating:!1,isLoading:isFunction(ee.defaultValues),isSubmitted:!1,isSubmitting:!1,isSubmitSuccessful:!1,isValid:!1,submitCount:0,dirtyFields:{},touchedFields:{},errors:ee.errors||{},disabled:!1,defaultValues:isFunction(ee.defaultValues)?void 0:ee.defaultValues});et.current||(et.current={...createFormControl(ee,()=>ea(ee=>({...ee}))),formState:eo});let es=et.current.control;return es._options=ee,useSubscribe({subject:es._subjects.state,next:ee=>{shouldRenderFormState(ee,es._proxyFormState,es._updateFormState,!0)&&ea({...es._formState})}}),ei.useEffect(()=>es._disableForm(ee.disabled),[es,ee.disabled]),ei.useEffect(()=>{if(es._proxyFormState.isDirty){let ee=es._getDirty();ee!==eo.isDirty&&es._subjects.state.next({isDirty:ee})}},[es,eo.isDirty]),ei.useEffect(()=>{ee.values&&!deepEqual(ee.values,en.current)?(es._reset(ee.values,es._options.resetOptions),en.current=ee.values,ea(ee=>({...ee}))):es._resetDefaultValues()},[ee.values,es]),ei.useEffect(()=>{ee.errors&&es._setErrors(ee.errors)},[ee.errors,es]),ei.useEffect(()=>{es._state.mount||(es._updateValid(),es._state.mount=!0),es._state.watch&&(es._state.watch=!1,es._subjects.state.next({...es._formState})),es._removeUnmounted()}),et.current.formState=getProxyFormState(eo,es),et.current}},97582:function(ee,et,en){"use strict";en.d(et,{Jh:function(){return __generator},_T:function(){return __rest},mG:function(){return __awaiter}});var extendStatics=function(ee,et){return(extendStatics=Object.setPrototypeOf||({__proto__:[]})instanceof Array&&function(ee,et){ee.__proto__=et}||function(ee,et){for(var en in et)Object.prototype.hasOwnProperty.call(et,en)&&(ee[en]=et[en])})(ee,et)},__assign=function(){return(__assign=Object.assign||function(ee){for(var et,en=1,ei=arguments.length;enet.indexOf(ei)&&(en[ei]=ee[ei]);if(null!=ee&&"function"==typeof Object.getOwnPropertySymbols)for(var eo=0,ei=Object.getOwnPropertySymbols(ee);eoet.indexOf(ei[eo])&&Object.prototype.propertyIsEnumerable.call(ee,ei[eo])&&(en[ei[eo]]=ee[ei[eo]]);return en}function __awaiter(ee,et,en,ei){function adopt(ee){return ee instanceof en?ee:new en(function(et){et(ee)})}return new(en||(en=Promise))(function(en,eo){function fulfilled(ee){try{step(ei.next(ee))}catch(ee){eo(ee)}}function rejected(ee){try{step(ei.throw(ee))}catch(ee){eo(ee)}}function step(ee){ee.done?en(ee.value):adopt(ee.value).then(fulfilled,rejected)}step((ei=ei.apply(ee,et||[])).next())})}function __generator(ee,et){var en,ei,eo,ea,es={label:0,sent:function(){if(1&eo[0])throw eo[1];return eo[1]},trys:[],ops:[]};return ea={next:verb(0),throw:verb(1),return:verb(2)},"function"==typeof Symbol&&(ea[Symbol.iterator]=function(){return this}),ea;function verb(ee){return function(et){return step([ee,et])}}function step(eu){if(en)throw TypeError("Generator is already executing.");for(;ea&&(ea=0,eu[0]&&(es=0)),es;)try{if(en=1,ei&&(eo=2&eu[0]?ei.return:eu[0]?ei.throw||((eo=ei.return)&&eo.call(ei),0):ei.next)&&!(eo=eo.call(ei,eu[1])).done)return eo;switch(ei=0,eo&&(eu=[2&eu[0],eo.value]),eu[0]){case 0:case 1:eo=eu;break;case 4:return es.label++,{value:eu[1],done:!1};case 5:es.label++,ei=eu[1],eu=[0];continue;case 7:eu=es.ops.pop(),es.trys.pop();continue;default:if(!(eo=(eo=es.trys).length>0&&eo[eo.length-1])&&(6===eu[0]||2===eu[0])){es=0;continue}if(3===eu[0]&&(!eo||eu[1]>eo[0]&&eu[1]","exports":{"types":"./types/index.d.ts","import":"./lib/index.mjs","require":"./lib/index.js"},"main":"./lib/index.js","types":"./types/index.d.ts","files":["lib","types/index.d.ts"],"scripts":{"format":"npx prettier --loglevel silent --write ./lib ./test ./certification ./types","test":"mocha test/**/*.test.js"},"dependencies":{"jose":"^4.15.9","lru-cache":"^6.0.0","object-hash":"^2.2.0","oidc-token-hash":"^5.0.3"},"devDependencies":{"@types/node":"^16.18.106","@types/passport":"^1.0.16","base64url":"^3.0.1","chai":"^4.5.0","mocha":"^10.7.3","nock":"^13.5.5","prettier":"^2.8.8","readable-mock-req":"^0.2.2","sinon":"^9.2.4","timekeeper":"^2.3.1"},"standard-version":{"scripts":{"postchangelog":"sed -i \'\' -e \'s/### \\\\[/## [/g\' CHANGELOG.md"},"types":[{"type":"feat","section":"Features"},{"type":"fix","section":"Fixes"},{"type":"chore","hidden":true},{"type":"docs","hidden":true},{"type":"style","hidden":true},{"type":"refactor","section":"Refactor","hidden":false},{"type":"perf","section":"Performance","hidden":false},{"type":"test","hidden":true}]}}')}}]);