diff --git a/MyApp/wwwroot/lib/mjs/servicestack-client.min.mjs b/MyApp/wwwroot/lib/mjs/servicestack-client.min.mjs index 0b2fc10..097133b 100644 --- a/MyApp/wwwroot/lib/mjs/servicestack-client.min.mjs +++ b/MyApp/wwwroot/lib/mjs/servicestack-client.min.mjs @@ -1 +1 @@ -class ResponseStatus{constructor(e){Object.assign(this,e)}errorCode;message;stackTrace;errors;meta}class ResponseError{constructor(e){Object.assign(this,e)}errorCode;fieldName;message;meta}class ErrorResponse{constructor(e){Object.assign(this,e)}type;responseStatus}class EmptyResponse{constructor(e){Object.assign(this,e)}responseStatus}class NavItem{label;href;exact;id;className;iconClass;show;hide;children;meta;constructor(e){Object.assign(this,e)}}class GetNavItems{constructor(e){Object.assign(this,e)}createResponse(){return new GetNavItemsResponse}getTypeName(){return"GetNavItems"}getMethod(){return"GET"}}class GetNavItemsResponse{baseUrl;results;navItemsMap;meta;responseStatus;constructor(e){Object.assign(this,e)}}class MetadataTypesConfig{baseUrl;defaultNamespaces;defaultImports;includeTypes;excludeTypes;treatTypesAsStrings;globalNamespace;ignoreTypes;exportTypes;exportAttributes;ignoreTypesInNamespaces;constructor(e){Object.assign(this,e)}}class MetadataRoute{path;verbs;notes;summary;constructor(e){Object.assign(this,e)}}class MetadataOperationType{request;response;actions;returnsVoid;returnType;routes;dataModel;viewModel;requiresAuth;requiredRoles;requiresAnyRole;requiredPermissions;requiresAnyPermission;tags;constructor(e){Object.assign(this,e)}}class MetadataTypes{config;namespaces;types;operations;constructor(e){Object.assign(this,e)}}class MetadataTypeName{name;namespace;genericArgs;constructor(e){Object.assign(this,e)}}class MetadataDataContract{name;namespace;constructor(e){Object.assign(this,e)}}class MetadataDataMember{name;order;isRequired;emitDefaultValue;constructor(e){Object.assign(this,e)}}class MetadataAttribute{name;constructorArgs;args;constructor(e){Object.assign(this,e)}}class MetadataPropertyType{name;type;isValueType;isSystemType;isEnum;isPrimaryKey;typeNamespace;genericArgs;value;description;dataMember;readOnly;paramType;displayType;isRequired;allowableValues;allowableMin;allowableMax;attributes;constructor(e){Object.assign(this,e)}}class MetadataType{name;namespace;genericArgs;inherits;implements;displayType;description;isNested;isEnum;isEnumInt;isInterface;isAbstract;dataContract;properties;attributes;innerTypes;enumNames;enumValues;enumMemberValues;enumDescriptions;meta;constructor(e){Object.assign(this,e)}}class NewInstanceResolver{tryResolve(e){return new e}}class SingletonInstanceResolver{tryResolve(e){return e.instance||(e.instance=new e)}}function eventMessageType(e){switch(e){case"onConnect":return"ServerEventConnect";case"onHeartbeat":return"ServerEventHeartbeat";case"onJoin":return"ServerEventJoin";case"onLeave":return"ServerEventLeave";case"onUpdate":return"ServerEventUpdate"}return null}var ReadyState,Types;!function(e){e[e.CONNECTING=0]="CONNECTING",e[e.OPEN=1]="OPEN",e[e.CLOSED=2]="CLOSED"}(ReadyState=ReadyState||{});class ServerEventsClient{channels;options;eventSource;static UnknownChannel="*";eventStreamUri;updateSubscriberUrl;connectionInfo;serviceClient;stopped;resolver;listeners;EventSource;withCredentials;constructor(e,t,r={},s=null){if(this.channels=t,this.options=r,this.eventSource=s,0===this.channels.length)throw"at least 1 channel is required";this.resolver=this.options.resolver||new NewInstanceResolver,this.eventStreamUri=combinePaths(e,"event-stream")+"?",this.updateChannels(t),this.serviceClient=new JsonServiceClient(e),this.listeners={},this.withCredentials=!0,this.options.handlers||(this.options.handlers={})}onMessage=e=>{if("undefined"==typeof document){var t,r,s,n=e.data?e.data.indexOf("\n"):-1;if(0<=n)return t=e.data,s=e.lastEventId,r=Object.assign({},{lastEventId:s,data:t.substring(0,n)}),s=Object.assign({},{lastEventId:s,data:t.substring(n+1)}),this._onMessage(r),void this._onMessage(s)}this._onMessage(e)};_onMessage=a=>{if(!this.stopped){let n=this.options;void 0===o&&(o={querySelectorAll:e=>[]});var o,i=splitOnFirst(a.data," ");let e=null,t=i[0];var l=splitOnFirst(t,"@"),l=(1{if(this.eventSource.readyState===EventSource.CLOSED)clearInterval(n.heartbeat),null!=(e=n.handlers.onStop)&&e.apply(this.eventSource),this.reconnectServerEvents({error:new Error("EventSource is CLOSED")});else{var e=new Request(n.heartbeatUrl,{method:"POST",mode:"cors",headers:s,credentials:this.serviceClient.credentials});try{var t,r=await fetch(e);r.ok?await r.text():(t=new Error(r.status+" - "+r.statusText),this.reconnectServerEvents({error:t}))}catch(e){this.reconnectServerEvents({error:e})}}},this.connectionInfo&&this.connectionInfo.heartbeatIntervalMs||n.heartbeatIntervalMs||1e4)),n.unRegisterUrl&&"undefined"!=typeof window&&(window.onunload=()=>{navigator.sendBeacon?(this.stopped=!0,this.eventSource&&this.eventSource.close(),navigator.sendBeacon(n.unRegisterUrl)):this.stop()}),this.updateSubscriberUrl=n.updateSubscriberUrl,this.updateChannels((n.channels||"").split(","))}else{p="onJoin"==h||"onLeave"==h||"onUpdate"==h;let e=n.handlers[h];e?p?e.call(f||o.body,l):e.call(f||o.body,r,a):p||(c=n.receivers&&n.receivers.cmd,this.invokeReceiver(c,h,f,a,"cmd")),p&&(e=n.handlers.onCommand)&&e.call(f||o.body,l)}else"trigger"===u?this.raiseEvent(i,a):"css"===u&&css(d||$$("body"),h,r);c=n.receivers&&n.receivers[u];this.invokeReceiver(c,h,f,a,u),eventMessageType(h)||(p=n.handlers.onMessage)&&p.call(f||o.body,l),n.onTick&&n.onTick()}}};onError=e=>{var t;this.stopped||(e=e||event,null!=(t=this.options.onException)&&t.call(this.eventSource,e),this.options.onTick&&this.options.onTick())};getEventSourceOptions(){return{withCredentials:this.withCredentials}}reconnectServerEvents(t={}){if(!this.stopped){t.error&&this.onError(t.error);const n=this.eventSource;let e=t.url||this.eventStreamUri||n.url;null!=this.options.resolveStreamUrl&&(e=this.options.resolveStreamUrl(e));var r=new(this.EventSource||EventSource)(e,this.getEventSourceOptions()),s=(r.addEventListener("error",e=>(t.onerror||n.onerror||this.onError)(e)),r.addEventListener("message",t.onmessage||n.onmessage||this.onMessage),this.options.onReconnect);return null!=s&&s.call(r,t.error),n.removeEventListener&&(n.removeEventListener("error",this.onError),n.removeEventListener("message",this.onMessage)),n.close(),this.eventSource=r}}start(){if(this.stopped=!1,null==this.eventSource||this.eventSource.readyState===EventSource.CLOSED){let e=this.eventStreamUri;null!=this.options.resolveStreamUrl&&(e=this.options.resolveStreamUrl(e)),this.eventSource=new(this.EventSource||EventSource)(e,this.getEventSourceOptions()),this.eventSource.addEventListener("error",this.onError),this.eventSource.addEventListener("message",e=>this.onMessage(e))}return this}stop(){this.stopped=!0,this.eventSource&&this.eventSource.close();var e=this.options,e=(e&&e.heartbeat&&clearInterval(e.heartbeat),this.connectionInfo);return null==e||null==e.unRegisterUrl?new Promise((e,t)=>e()):(this.connectionInfo=null,fetch(new Request(e.unRegisterUrl,{method:"POST",mode:"cors",credentials:this.serviceClient.credentials})).then(e=>{if(!e.ok)throw new Error(e.status+" - "+e.statusText)}).catch(this.onError))}invokeReceiver(r,e,s,n,t){if(r)if("function"==typeof r&&(r=this.resolver.tryResolve(r)),e=e.replace("-",""),r.client=this,r.request=n,"function"==typeof r[e])r[e].call(s||r,n.body,n);else if(e in r)r[e]=n.body;else{var a=Object.getOwnPropertyDescriptor(r,e);if(null!=a)a.set?a.set(n.body):a.writable&&(r[e]=n.body);else{let t=e.toLowerCase();getAllMembers(r).forEach(e=>{e.toLowerCase()==t&&("function"==typeof r[e]?r[e].call(s||r,n.body,n):r[e]=n.body)});a=r.noSuchMethod;"function"==typeof a&&a.call(s||r,n.target,n)}}}hasConnected(){return null!=this.connectionInfo}registerHandler(e,t){return this.options.handlers||(this.options.handlers={}),this.options.handlers[e]=t,this}setResolver(e){return this.options.resolver=e,this}registerReceiver(e){return this.registerNamedReceiver("cmd",e)}registerNamedReceiver(e,t){return this.options.receivers||(this.options.receivers={}),this.options.receivers[e]=t,this}unregisterReceiver(e="cmd"){return this.options.receivers&&delete this.options.receivers[e],this}updateChannels(e){this.channels=e;var t=null!=this.eventSource?this.eventSource.url:this.eventStreamUri;this.eventStreamUri=t.substring(0,Math.min(t.indexOf("?"),t.length))+"?channels="+e.join(",")+"&t="+(new Date).getTime()}update(e,t){var r,s="string"==typeof e?e.split(","):e,n="string"==typeof t?t.split(","):t,a=[];for(r in this.channels){var o=this.channels[r];null!=n&&-1!==n.indexOf(o)||a.push(o)}if(s)for(var i in s){i=s[i];-1===a.indexOf(i)&&a.push(i)}this.updateChannels(a)}addListener(e,t){return(this.listeners[e]||(this.listeners[e]=[])).push(t),this}removeListener(e,t){e=this.listeners[e];return e&&0<=(t=e.indexOf(t))&&e.splice(t,1),this}raiseEvent(e,t){e=this.listeners[e];e&&e.forEach(e=>{try{e(t)}catch(e){this.onError(e)}})}getConnectionInfo(){if(null==this.connectionInfo)throw"Not Connected";return this.connectionInfo}getSubscriptionId(){return this.getConnectionInfo().id}updateSubscriber(t){return null==t.id&&(t.id=this.getSubscriptionId()),this.serviceClient.post(t).then(e=>{this.update(t.subscribeChannels,t.unsubscribeChannels)}).catch(this.onError)}subscribeToChannels(...t){var e=new UpdateEventSubscriber;return e.id=this.getSubscriptionId(),e.subscribeChannels=t,this.serviceClient.post(e).then(e=>{this.update(t,null)}).catch(this.onError)}unsubscribeFromChannels(...t){var e=new UpdateEventSubscriber;return e.id=this.getSubscriptionId(),e.unsubscribeChannels=t,this.serviceClient.post(e).then(e=>{this.update(null,t)}).catch(this.onError)}getChannelSubscribers(){var e=new GetEventSubscribers;return e.channels=this.channels,this.serviceClient.get(e).then(e=>e.map(e=>this.toServerEventUser(e))).catch(e=>(this.onError(e),[]))}toServerEventUser(e){var t,r=e.channels,s=new ServerEventUser;for(t in s.userId=e.userId,s.displayName=e.displayName,s.profileUrl=e.profileUrl,s.channels=r?r.split(","):null,e)"userId"!=t&&"displayName"!=t&&"profileUrl"!=t&&"channels"!=t&&(null==s.meta&&(s.meta={}),s.meta[t]=e[t]);return s}}function getAllMembers(e){let s=[];do{var t=Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e).map(e=>e.toString())).sort().filter((e,t,r)=>"constructor"!==e&&(0==t||e!==r[t-1])&&-1===s.indexOf(e));s=s.concat(t)}while((e=Object.getPrototypeOf(e))&&Object.getPrototypeOf(e));return s}class ServerEventReceiver{client;request;noSuchMethod(e,t){}}class UpdateEventSubscriber{id;subscribeChannels;unsubscribeChannels;createResponse(){return new UpdateEventSubscriberResponse}getTypeName(){return"UpdateEventSubscriber"}}class UpdateEventSubscriberResponse{responseStatus}class GetEventSubscribers{channels;createResponse(){return[]}getTypeName(){return"GetEventSubscribers"}}class ServerEventUser{userId;displayName;profileUrl;channels;meta}class HttpMethods{static Get="GET";static Post="POST";static Put="PUT";static Delete="DELETE";static Patch="PATCH";static Head="HEAD";static Options="OPTIONS";static hasRequestBody=e=>!("GET"===e||"DELETE"===e||"HEAD"===e||"OPTIONS"===e)}class GetAccessToken{constructor(e){Object.assign(this,e)}refreshToken;useTokenCookie;createResponse(){return new GetAccessTokenResponse}getTypeName(){return"GetAccessToken"}getMethod(){return"POST"}}class GetAccessTokenResponse{accessToken;responseStatus}class JsonServiceClient{baseUrl;replyBaseUrl;oneWayBaseUrl;mode;credentials;headers;userName;password;bearerToken;refreshToken;refreshTokenUri;useTokenCookie;enableAutoRefreshToken;requestFilter;static globalRequestFilter;responseFilter;static globalResponseFilter;exceptionFilter;urlFilter;onAuthenticationRequired;manageCookies;cookies;parseJson;static toBase64;constructor(e="/"){this.baseUrl=e,this.replyBaseUrl=combinePaths(e,"json","reply")+"/",this.oneWayBaseUrl=combinePaths(e,"json","oneway")+"/",this.mode="cors",this.credentials="include",this.headers=new Headers,this.headers.set("Content-Type","application/json"),this.manageCookies="undefined"==typeof document,this.cookies={},this.enableAutoRefreshToken=!0}setCredentials(e,t){this.userName=e,this.password=t}useBasePath(e){return this.basePath=e,this}set basePath(e){e?("/"!=e[0]&&(e="/"+e),this.replyBaseUrl=combinePaths(this.baseUrl,e)+"/",this.oneWayBaseUrl=combinePaths(this.baseUrl,e)+"/"):(this.replyBaseUrl=combinePaths(this.baseUrl,"json","reply")+"/",this.oneWayBaseUrl=combinePaths(this.baseUrl,"json","oneway")+"/")}apply(e){return e(this),this}get(e,t){return"string"!=typeof e?this.fetch(HttpMethods.Get,e,t):this.fetch(HttpMethods.Get,null,t,this.toAbsoluteUrl(e))}delete(e,t){return"string"!=typeof e?this.fetch(HttpMethods.Delete,e,t):this.fetch(HttpMethods.Delete,null,t,this.toAbsoluteUrl(e))}post(e,t){return this.fetch(HttpMethods.Post,e,t)}postToUrl(e,t,r){return this.fetch(HttpMethods.Post,t,r,this.toAbsoluteUrl(e))}postBody(e,t,r){return this.fetchBody(HttpMethods.Post,e,t,r)}put(e,t){return this.fetch(HttpMethods.Put,e,t)}putToUrl(e,t,r){return this.fetch(HttpMethods.Put,t,r,this.toAbsoluteUrl(e))}putBody(e,t,r){return this.fetchBody(HttpMethods.Put,e,t,r)}patch(e,t){return this.fetch(HttpMethods.Patch,e,t)}patchToUrl(e,t,r){return this.fetch(HttpMethods.Patch,t,r,this.toAbsoluteUrl(e))}patchBody(e,t,r){return this.fetchBody(HttpMethods.Patch,e,t,r)}publish(e,t){return this.sendOneWay(e,t)}sendOneWay(e,t){var r=combinePaths(this.oneWayBaseUrl,nameOf(e));return this.fetch(HttpMethods.Post,e,null,r)}sendAll(e){var t;return 0==e.length?Promise.resolve([]):(t=combinePaths(this.replyBaseUrl,nameOf(e[0])+"[]"),this.fetch(HttpMethods.Post,e,null,t))}sendAllOneWay(e){var t;return 0==e.length?Promise.resolve(void 0):(t=combinePaths(this.oneWayBaseUrl,nameOf(e[0])+"[]"),this.fetch(HttpMethods.Post,e,null,t).then(e=>{}))}createUrlFromDto(e,t){let r=combinePaths(this.replyBaseUrl,nameOf(t));e=HttpMethods.hasRequestBody(e);return r=e?r:appendQueryString(r,t)}toAbsoluteUrl(e){return e.startsWith("http://")||e.startsWith("https://")?e:combinePaths(this.baseUrl,e)}deleteCookie(e){this.manageCookies?delete this.cookies[e]:document&&(document.cookie=e+"=; expires=Thu, 01 Jan 1970 00:00:00 UTC; path=/")}createRequest({method:e,request:t,url:r,args:s,body:n}){r=r||this.createUrlFromDto(e,t),s&&(r=appendQueryString(r,s)),null!=this.bearerToken?this.headers.set("Authorization","Bearer "+this.bearerToken):null!=this.userName&&this.headers.set("Authorization","Basic "+JsonServiceClient.toBase64(this.userName+":"+this.password)),this.manageCookies&&(0<(s=Object.keys(this.cookies).map(e=>{e=this.cookies[e];return e.expires&&e.expires0{"set-cookie"===t.toLowerCase()&&e.split(",").forEach(e=>r.push(e))}),r.forEach(e=>{e=parseCookie(e);e&&(this.cookies[e.name]=e)})}e.headers.forEach((e,t)=>{"x-cookies"===t.toLowerCase()&&0<=e.split(",").indexOf("ss-reftok")&&(this.useTokenCookie=!0)}),this.applyResponseFilters(e);let r=t&&"string"!=typeof t&&"function"==typeof t.createResponse?t.createResponse():null;if("string"==typeof r)return e.text().then(e=>e);t=e.headers.get("content-type"),t=t&&-1!==t.indexOf("application/json");if(t)return this.json(e).then(e=>e);if("undefined"!=typeof Uint8Array&&r instanceof Uint8Array){if("function"!=typeof e.arrayBuffer)throw new Error("This fetch polyfill does not implement 'arrayBuffer'");return e.arrayBuffer().then(e=>new Uint8Array(e))}if("function"==typeof Blob&&r instanceof Blob){if("function"!=typeof e.blob)throw new Error("This fetch polyfill does not implement 'blob'");return e.blob().then(e=>e)}var s=e.headers.get("content-length");return"0"===s||null==s&&!t?e.text().then(e=>r):this.json(e).then(e=>e)}handleError(e,r,t=null){if(r instanceof Error)throw this.raiseError(e,r);if(r.bodyUsed)throw this.raiseError(r,createErrorResponse(r.status,r.statusText,t));return void 0===r.json&&r.responseStatus?new Promise((e,t)=>t(this.raiseError(null,r))):this.json(r).then(e=>{e=sanitize(e);if(e.responseStatus)throw null!=t&&(e.type=t),e;throw createErrorResponse(r.status,r.statusText,t)}).catch(e=>{if(e instanceof Error||"undefined"!=typeof window&&window.DOMException&&e instanceof window.DOMException)throw this.raiseError(r,createErrorResponse(r.status,r.statusText,t));throw this.raiseError(r,e)})}fetch(e,t,r,s){return this.sendRequest({method:e,request:t,args:r,url:s})}fetchBody(e,t,r,s){var n=combinePaths(this.replyBaseUrl,nameOf(t));return this.sendRequest({method:e,request:r,body:"string"==typeof r||isFormData(r)?r:JSON.stringify(r),url:appendQueryString(n,t),args:s,returns:t})}sendRequest(t){var e=this.createRequest(t);const r=t.returns||t.request;let n=null;const a=()=>{var e=this.createRequest(t);return this.urlFilter&&this.urlFilter(e.url),fetch(e.url,e).then(e=>this.createResponse(e,r)).catch(e=>this.handleError(n,e))};return this.urlFilter&&this.urlFilter(e.url),fetch(e.url,e).then(e=>{return n=e,this.createResponse(e,r)}).catch(e=>{if(401===e.status){if(this.enableAutoRefreshToken&&(this.refreshToken||this.useTokenCookie||null!=this.cookies["ss-reftok"])){const s=new GetAccessToken({refreshToken:this.refreshToken,useTokenCookie:!!this.useTokenCookie});var t=this.refreshTokenUri||this.createUrlFromDto(HttpMethods.Post,s),r=(this.useTokenCookie&&(this.bearerToken=null,this.headers.delete("Authorization")),this.createRequest({method:HttpMethods.Post,request:s,args:null,url:t}));return fetch(t,r).then(e=>this.createResponse(e,s).then(e=>(this.bearerToken=e?.accessToken||null,a()))).catch(e=>this.onAuthenticationRequired?this.onAuthenticationRequired().then(a).catch(e=>this.handleError(n,e,"RefreshTokenException")):this.handleError(n,e,"RefreshTokenException"))}if(this.onAuthenticationRequired)return this.onAuthenticationRequired().then(a)}return this.handleError(n,e)})}raiseError(e,t){return null!=this.exceptionFilter&&this.exceptionFilter(e,t),t}send(e,t,r){return this.sendRequest({method:getMethod(e),request:e,args:t,url:r})}sendVoid(e,t,r){return this.sendRequest({method:getMethod(e),request:e,args:t,url:r})}async api(e,t,r){try{var s=await this.fetch(getMethod(e,r),e,t);return new ApiResult({response:s})}catch(e){return new ApiResult({error:getResponseStatus(e)})}}async apiVoid(e,t,r){try{var s=await this.fetch(getMethod(e,r),e,t);return new ApiResult({response:s??new EmptyResponse})}catch(e){return new ApiResult({error:getResponseStatus(e)})}}async apiForm(e,t,r,s){try{var n=await this.fetchBody(getMethod(e,s),e,t,r);return new ApiResult({response:n})}catch(e){return new ApiResult({error:getResponseStatus(e)})}}async apiFormVoid(e,t,r,s){try{var n=await this.fetchBody(getMethod(e,s),e,t,r);return new ApiResult({response:n??new EmptyResponse})}catch(e){return new ApiResult({error:getResponseStatus(e)})}}}class JsonApiClient{static create(e="/",t){return new JsonServiceClient(e).apply(e=>{e.basePath="/api",e.headers=new Headers,e.enableAutoRefreshToken=!1,t&&t(e)})}}function getMethod(e,t){return t??("function"==typeof e.getMethod?e.getMethod():HttpMethods.Post)}function getResponseStatus(e){return e.responseStatus??e.ResponseStatus??(e.errorCode?e:e.message?createErrorStatus(e.message,e.errorCode):null)}class ApiResult{response;error;constructor(e){Object.assign(this,e)}get completed(){return null!=this.response||null!=this.error}get failed(){return null!=this.error?.errorCode||null!=this.error?.message}get succeeded(){return!this.failed&&null!=this.response}get errorMessage(){return this.error?.message}get errorCode(){return this.error?.errorCode}get errors(){return this.error?.errors??[]}get errorSummary(){return null!=this.error&&0==this.errors.length?this.errorMessage:null}fieldError(e){let t=e.toLowerCase();return this.errors?.find(e=>e.fieldName.toLowerCase()==t)}fieldErrorMessage(e){return this.fieldError(e)?.message}hasFieldError(e){return null!=this.fieldError(e)}showSummary(e=[]){return!!this.failed&&e.every(e=>!this.hasFieldError(e))}summaryMessage(e=[]){if(this.showSummary(e)){let t=e.map(e=>e.toLowerCase());return t.find(e=>-1==t.indexOf(e.toLowerCase()))??this.errorMessage}}addFieldError(e,t,r="Exception"){this.error||(this.error=new ResponseStatus);var s=this.fieldError(e);null!=s?(s.errorCode=r,s.message=t):this.error.errors.push(new ResponseError({fieldName:e,errorCode:r,message:t}))}}function createErrorStatus(e,t="Exception"){return new ResponseStatus({errorCode:t,message:e})}function createFieldError(e,t,r="Exception"){return new ResponseStatus({errors:[new ResponseError({fieldName:e,errorCode:r,message:t})]})}function isFormData(e){return"undefined"!=typeof window&&e instanceof FormData}function createErrorResponse(t,r,s=null){return apply(new ErrorResponse,e=>{null!=s&&(e.type=s),e.responseStatus=apply(new ResponseStatus,e=>{e.errorCode=t&&t.toString(),e.message=r})})}function createError(e,t,r){return new ErrorResponse({responseStatus:new ResponseStatus({errorCode:e,message:t,errors:r?[new ResponseError({errorCode:e,message:t,fieldName:r})]:void 0})})}function toCamelCase(e){return e&&e.charAt(0).toLowerCase()+e.substring(1)}function toPascalCase(e){return e&&e.charAt(0).toUpperCase()+e.substring(1)}function toKebabCase(e){return(e||"").replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase()}function map(e,t){return null==e?null:t(e)}function camelCaseAny(e){if(!e||!(e instanceof Object)||Array.isArray(e))return e;var t,r,s,n={};for(t in e)e.hasOwnProperty(t)&&(r=toCamelCase(t),s=e[t],Array.isArray(s)?n[r]=s.map(e=>camelCaseAny(e)):s instanceof Object?n[r]=camelCaseAny(s):n[r]=s);return n}function sanitize(e){return sanitize&&(e.responseStatus||e.errors?e:camelCaseAny(e))}function nameOf(e){if(!e)return"null";if("function"==typeof e.getTypeName)return e.getTypeName();var t=e&&e.constructor;if(null==t)throw e+" doesn't have constructor";return t.name||(e=t.toString()).substring(9,e.indexOf("("))}function log(e,t="LOG"){return console.log(t,e),e}function css(e,t,r){var s="string"==typeof e?document.querySelectorAll(e):e;for(let e=0;er[e]=t[e]),r}function splitCase(e){return"string"!=typeof e?e:e.replace(/([A-Z]|[0-9]+)/g," $1").replace(/_/g," ").trim()}function humanize(e){return!e||0<=e.indexOf(" ")?e:splitCase(toPascalCase(e))}const ucFirst=e=>e.charAt(0).toUpperCase()+e.substring(1),isUpper=e=>"A"<=e&&e<="Z",isLower=e=>"a"<=e&&e<="z",isDigit=e=>"0"<=e&&e<="9",upperOrDigit=e=>isUpper(e)||isDigit(e);function splitTitleCase(t){var r=[];if("string"!=typeof t)return r;let s=0;for(let e=0;e!!e)}function humanify(e){return!e||0<=e.indexOf(" ")?e:ucFirst(splitTitleCase(e).join(" "))}function queryString(e){if(!e||-1===e.indexOf("?"))return{};var t=rightPart(e,"?").split("&"),r={};for(let e=0;e>>e&24),2!=e&&n.length-s!=1||(a+=String.fromCharCode(uint6ToB64(r>>>18&63),uint6ToB64(r>>>12&63),uint6ToB64(r>>>6&63),uint6ToB64(63&r)),r=0);return 0==e?a:a.substring(0,a.length-e)+(1==e?"=":"==")}function uint6ToB64(e){return e<26?e+65:e<52?e+71:e<62?e-4:62===e?43:63===e?47:65}function _btoa(e){return"function"==typeof btoa?btoa(e):Buffer.from(e).toString("base64")}function _atob(e){return"function"==typeof atob?atob(e):Buffer.from(e,"base64").toString()}function stripQuotes(e){return e&&'"'==e[0]&&'"'==e[e.length]?e.slice(1,-1):e}function tryDecode(t){try{return decodeURIComponent(t)}catch(e){return t}}function parseCookie(e){if(!e)return null;let t=null;var r=e.split(/; */);for(let e=0;enormalizeKey(e)===normalizeKey(t))[0]||""]}function parseResponseStatus(t,r=null){try{var e=JSON.parse(t);return sanitize(e.ResponseStatus||e.responseStatus)}catch(e){return{message:r||e.message||e,__error:{error:e,json:t}}}}function toFormData(e){if("undefined"!=typeof window){var t,r=new FormData;for(t in e)r.append(t,e[t]);return r}}function toObject(e){const t={};if(e){if("object"!=typeof e)throw new Error("keys must be an Array of object keys");Array.prototype.slice.call(e).forEach(e=>{this[e]&&(t[e]=this[e])})}return t}function errorResponseSummary(){var e=this.responseStatus||this.ResponseStatus;return null==e||(e=e.ErrorCode?sanitize(e):e).errors&&0!=e.errors.length?void 0:e.message||e.errorCode}function errorResponseExcept(e){var t=this.responseStatus||this.ResponseStatus;if(null!=t){t=t.ErrorCode?sanitize(t):t,e=toVarNames(e);if(e&&null!=t.errors&&0!=t.errors.length){var r,s,n=e.map(e=>(e||"").toLowerCase());for(r of t.errors)if(-1!==n.indexOf((r.fieldName||"").toLowerCase()))return;for(s of t.errors)if(-1===n.indexOf((s.fieldName||"").toLowerCase()))return s.message||s.errorCode}return t.message||t.errorCode||void 0}}function errorResponse(t){var e;return null==t?errorResponseSummary.call(this):null!=(e=this.responseStatus||this.ResponseStatus)&&null!=(e=e.ErrorCode?sanitize(e):e).errors&&0!=e.errors.length&&(e=e.errors.find(e=>(e.fieldName||"").toLowerCase()==t.toLowerCase()))?e.message||e.errorCode:void 0}function isDate(e){return e&&"[object Date]"===Object.prototype.toString.call(e)&&!isNaN(e)}function toDate(e){return e?isDate(e)?e:"/"==e[0]?new Date(parseFloat(/Date\(([^)]+)\)/.exec(e)[1])):new Date(e):null}function toDateFmt(e){return dateFmt(toDate(e))}function padInt(e){return e<10?"0"+e:e}function dateFmt(e=new Date){return e.getFullYear()+"/"+padInt(e.getMonth()+1)+"/"+padInt(e.getDate())}function dateFmtHM(e=new Date){return e.getFullYear()+"/"+padInt(e.getMonth()+1)+"/"+padInt(e.getDate())+" "+padInt(e.getHours())+":"+padInt(e.getMinutes())}function timeFmt12(e=new Date){return padInt((e.getHours()+24)%12||12)+":"+padInt(e.getMinutes())+":"+padInt(e.getSeconds())+" "+(12'+e+""}function attr(e,t){return e.getAttribute(t)}function sattr(e,t,r){return e.setAttribute(t,r)}function rattr(e,t){return e.removeAttribute(t)}function createElement(e,t){var r={className:"class",htmlFor:"for"},s=document.createElement(e);if(t?.attrs)for(const n in t.attrs)sattr(s,r[n]||n,t.attrs[n]);return t?.events&&on(s,t.events),t&&t.insertAfter&&t.insertAfter.parentNode.insertBefore(s,t.insertAfter.nextSibling),s}function showInvalidInputs(){var e,t,r,s=attr(this,"data-invalid");s&&(e=(r="checkbox"===this.type||"radio"===this.type||hasClass(this,"form-check"))?parent(this,"form-check"):null,r?addClass(e||this.parentElement,"is-invalid form-control"):addClass(this,"is-invalid"),(null!=(r=!(t=this.nextElementSibling)||attr(t,"for")!==this.id&&"SMALL"!==t.tagName?this:r?e||t.parentElement:t)&&r.nextElementSibling&&hasClass(r.nextElementSibling,"invalid-feedback")?r.nextElementSibling:createElement("div",{insertAfter:r,attrs:{className:"invalid-feedback"}})).innerHTML=s)}function parent(e,t){for(;null!=e&&!hasClass(e,t);)e=e.parentElement;return e}function hasClass(e,t){return!!e&&(e.classList?e.classList.contains(t):-1<(" "+e.className+" ").replace(/[\n\t\r]/g," ").indexOf(" "+t+" "))}function addClass(e,t){return e?e.classList?e.classList.add(...t.split(" ")):hasClass(e,t)?null:e.className=(e.className+" "+t).trim():null}function remClass(e,t){return e?e.classList?e.classList.remove(t):hasClass(e,t)?e.className=e.className.replace(/(\s|^)someclass(\s|$)/," "):null:null}function isElement(e){return"undefined"!=typeof window&&(e instanceof window.Element||e==window.document)}function $1(e,t){return"string"==typeof e?(t||document).querySelector(e):e||null}function $$(e,t){return"string"==typeof e?Array.from((t||document).querySelectorAll(e)):Array.isArray(e)?e.flatMap(e=>$$(e,t)):[e]}function on(e,s){return $$(e).forEach(r=>{Object.keys(s).forEach(function(e){var t=s[e];"string"==typeof e&&"function"==typeof t&&r.addEventListener(e,s[e]=t.bind(r))})}),s}function addScript(r){return new Promise((e,t)=>{document.body.appendChild(createElement("script",{attrs:{src:r},events:{load:e,error:t}}))})}function delaySet(e,t){t=t&&t.duration||300;let r=setTimeout(()=>e(!0),t);return()=>{clearTimeout(r),e(!1)}}function bootstrap(e){var t=(e||document).querySelectorAll("[data-invalid]");for(let e=0;ehandleEvent(t,r,e)):["click","dblclick","change","focus","blur","focusin","focusout","select","keydown","keypress","keyup","hover","toggle","input"].forEach(e=>{r.querySelector(`[data-${e}]`)&&handleEvent(t,r,e)})}function bootstrapForm(t,r){t&&(r.model&&populateForm(t,r.model),t.onsubmit=function(e){return e.preventDefault(),r.type="bootstrap-v4",ajaxSubmit(t,r)})}function applyErrors(e,r,t){var s={overrideMessages:!1,messages:{NotEmpty:"Required",NotNull:"Required",Email:"Invalid email",AlreadyExists:"Already exists"},errorFilter:function(e,t,r){return this.overrideMessages?this.messages[t]||e||splitCase(t):e||splitCase(t)}};if(clearErrors(e),r){r=sanitize(r),addClass(e,"has-errors");const h=t&&"bootstrap-v4"===t.type;var s={...s,...t},o=(t.messages&&(s.overrideMessages=!0),s.errorFilter.bind(s)),t=r.errors;if(t&&t.length){let n={},a={};$$("input,textarea,select,button").forEach(e=>{var t=e.previousElementSibling,r=e.nextElementSibling,s=("radio"===e.type||"checkbox"===e.type?null:e.id)||attr(e,"name");s&&(s=s.toLowerCase(),n[s]=e,h||(hasClass(t,"help-inline")||hasClass(t,"help-block")?a[s]=t:(hasClass(r,"help-inline")||hasClass(r,"help-block"))&&(a[s]=r)))}),$$(".help-inline[data-for],.help-block[data-for]").forEach(e=>{var t=attr(e,"data-for").toLowerCase();a[t]=e});for(var i of t){var l=(i.fieldName||"").toLowerCase(),u=n[l],c=(u&&(h?("radio"!==(c=attr(u,"type"))&&"checkbox"!==c&&addClass(u,"is-invalid"),sattr(u,"data-invalid",o(i.message,i.errorCode,"field"))):(addClass(u,"error"),addClass(u.parentElement,"has-error"))),a[l]);c&&(addClass(c,"error"),c.innerHTML=o(i.message,i.errorCode,"field"),c.style.display="block")}$$("[data-validation-summary]").forEach(e=>{var t=attr(e,"data-validation-summary").split(","),t=errorResponseExcept.call(r,t);t&&(e.innerHTML=bsAlert(t))})}else{const n=o(r.message||splitCase(r.errorCode),r.errorCode,"summary");h?$$("[data-validation-summary]").forEach(e=>e.innerHTML="<"===n[0]?n:bsAlert(n)):$$(".error-summary").forEach(e=>{e.innerHTML=n(e).style.display="block"})}return e}}function clearErrors(e){remClass(e,"has-errors"),$$(".error-summary").forEach(e=>{e.innerHTML="",e.style.display="none"}),$$("[data-validation-summary]").forEach(e=>{e.innerHTML=""}),$$(".error").forEach(e=>remClass(e,"error")),$$(".form-check.is-invalid [data-invalid]").forEach(e=>{rattr(e,"data-invalid")}),$$(".form-check.is-invalid").forEach(e=>remClass(e,"form-control")),$$(".is-invalid").forEach(e=>{remClass(e,"is-invalid"),rattr(e,"data-invalid")}),$$(".is-valid").forEach(e=>remClass(e,"is-valid"))}function toVarNames(e){return e?isArray(e)?e:e.split(",").map(e=>e.trim()):[]}function formSubmit(e={}){const r=this;var t=attr(r,"enctype")||Types.UrlEncoded;if(t==Types.MultiPart&&void 0===window.FormData)throw new Error(`FormData Type is needed to send '${Types.MultiPart}' Content Types`);let s;try{s=serializeForm(r,t)}catch(e){throw new Error(""+(e.message||e))}var n=new Headers,t=(n.set("Accept",Types.Json),n.set("Content-Type",t),{method:attr(r,"method")||"POST",credentials:"include",mode:"cors",headers:n,body:s});return e.requestFilter&&e.requestFilter(t),fetch(new Request(e.url||attr(r,"action"),t)).catch(e=>{throw new Error(`Network is unreachable (${e.message||e})`)}).then(t=>(e.responseFilter&&e.responseFilter(t),t.ok?(handleHeaderBehaviors(r,t),fromResponse(t)):t.json().catch(e=>{throw new Error("The request failed with "+(t.statusText||t.status))}).then(e=>{throw Object.assign(new ErrorResponse,sanitize(e))})))}function handleHeaderBehaviors(e,t){var r=t.headers.get("X-Location"),r=(r&&(location.href=r),t.headers.get("X-Trigger"));r&&triggerEvent(e,0<=(t=r.indexOf(":"))?r.substring(0,t):r,(e=0<=t?r.substring(t+1):null)?[e]:[])}function ajaxSubmit(s,n={}){const a="bootstrap-v4"===n.type;clearErrors(s);try{if(n.validate&&!1===n.validate.call(s))return!1}catch(e){return!1}addClass(s,"loading");const e=null==n.onSubmitDisable?"[type=submit]":n.onSubmitDisable,t=null!=e&&""!=e;function r(e,t=null){var r;t?applyErrors(s,t.ResponseStatus||t.responseStatus,{...n}):e&&(addClass(s,"has-errors"),(r=$$(".error-summary")[0])&&(r.innerHTML=e),a)&&(r=$$("[data-validation-summary]")[0])&&(r.innerHTML=bsAlert(e)),n.error&&n.error.call(s,t),a&&$$("[data-invalid]").forEach(e=>showInvalidInputs.call(e))}return t&&$$(e).forEach(e=>{sattr(e,"disabled","disabled")}),(n.submit||formSubmit).call(s,n).then(e=>(n.success&&n.success.call(s,e),!1)).catch(e=>{e.responseStatus?r(null,e):r(""+(e.message||e),null)}).finally(()=>{remClass(s,"loading"),t&&$$(e).forEach(e=>{rattr(e,"disabled")}),n.complete&&n.complete.call(s)})}function fromResponse(e){var t,r=e.headers.get("content-type"),r=r&&-1!==r.indexOf(Types.Json);return!r&&("0"===(t=e.headers.get("content-length"))||null==t&&!r)?null:e.json()}function serializeForm(e,t=null){return t===Types.MultiPart?new FormData(e):t==Types.Json?JSON.stringify(serializeToObject(e)):serializeToUrlEncoded(e)}function formEntries(e,r,s){var n,a=e,o=a.elements.length;for(let t=0;te[t]=r)}function serializeToUrlEncoded(e){return formEntries(e,[],(e,t,r)=>"string"==typeof r?e.push(encodeURIComponent(t)+"="+encodeURIComponent(r)):null).join("&").replace(/%20/g,"+")}function serializeToFormData(e){return formEntries(e,new FormData,(e,t,r)=>e.append(t,r))}function sanitizeFormData(e){for(var[t,r]of e)"object"==typeof r&&0===r.size&&e.delete(t);return e}function triggerEvent(e,t,r=null){var s;document.createEvent?((s=document.createEvent("click"==t||t.startsWith("mouse")?"MouseEvents":"HTMLEvents")).initEvent(t,!0,!0),s.data=r,e.dispatchEvent(s)):(r=document.createEventObject(),e.fireEvent("on"+t,r))}function populateForm(r,s){if(s){var n;for(let e in s){let t=s[e];void 0!==t&&null!==t||(t="");var a=r.elements.namedItem(e)||r.elements.namedItem((n=e)&&(n[0]===n[0].toUpperCase()?toCamelCase(n):n[0]===n[0].toLowerCase()?toPascalCase(n):n)),o=a;if(a)switch(o.type||a[0].type){case"radio":case"checkbox":var i=a.length;for(let e=0;e(r(e,t),e),t||{})}function resolve(e,t){e="function"==typeof e?e():e;return"function"==typeof t?t(e):e}function mapGet(e,r){if(!e||!r)return null;var s=e[r];if(s)return s;if("object"!=typeof e)return null;{let t=r.toLowerCase();s=Object.keys(e).find(e=>e.toLowerCase()===t);return s?e[s]:null}}function apiValue(e){return null==e?"":"string"==typeof e?"/Date("===e.substring(0,6)?toDate(e):e.trim():e}function apiValueFmt(e){e=apiValue(e);return(null!=e?isDate(e)?dateFmt(e):e:null)||""}function activeClassNav(e,t){return null!=e.href&&(e.exact||t.length<=1?trimEnd(t,"/").toLowerCase()===trimEnd(e.href,"/").toLowerCase():trimEnd(t,"/").toLowerCase().startsWith(trimEnd(e.href,"/").toLowerCase()))?"active":null}function activeClass(e,t,r){return null!=e&&(r||t.length<=1?trimEnd(t,"/").toLowerCase()===trimEnd(e,"/").toLowerCase():trimEnd(t,"/").toLowerCase().startsWith(trimEnd(e,"/").toLowerCase()))?"active":null}function bootstrapColors(){return["primary","secondary","success","info","warning","danger","light","dark"]}JsonServiceClient.toBase64=e=>_btoa(encodeURIComponent(e).replace(/%([0-9A-F]{2})/g,(e,t)=>String.fromCharCode(new Number("0x"+t).valueOf()))),"undefined"!=typeof window&&void 0!==window.Element&&(Element.prototype.matches||(Element.prototype.matches=Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector),Element.prototype.closest||(Element.prototype.closest=function(e){let t=this;do{if(t.matches(e))return t}while(null!==(t=t.parentElement||t.parentNode)&&1===t.nodeType);return null})),function(e){e.MultiPart="multipart/form-data",e.UrlEncoded="application/x-www-form-urlencoded",e.Json="application/json"}(Types=Types||{});const BootstrapColors=bootstrapColors();function btnColorClass(e){for(const t of bootstrapColors()){if(e[t])return"btn-"+t;if(e["outline-"+t])return"btn-outline-"+t}return null}function bootstrapSizes(){return["xs","sm","md","lg"]}const BootstrapSizes=bootstrapSizes();function btnSizeClass(e){for(const t of bootstrapSizes())if(e[t])return"btn-"+t;return null}function btnClasses(e){var t=[],r=btnColorClass(e),r=(r&&t.push(r),btnSizeClass(e));return r&&t.push(r),e.block&&t.push("btn-block"),t}class NavDefaults{static navClass="nav";static navItemClass="nav-item";static navLinkClass="nav-link";static childNavItemClass="nav-item dropdown";static childNavLinkClass="nav-link dropdown-toggle";static childNavMenuClass="dropdown-menu";static childNavMenuItemClass="dropdown-item";static create(){return new NavOptions}static forNav(e){return e||NavDefaults.create()}static overrideDefaults(e,t){return null==e?t:((e=Object.assign({},e)).navClass===NavDefaults.navClass&&null!=t.navClass&&(e.navClass=t.navClass),e.navItemClass===NavDefaults.navItemClass&&null!=t.navItemClass&&(e.navItemClass=t.navItemClass),e.navLinkClass===NavDefaults.navLinkClass&&null!=t.navLinkClass&&(e.navLinkClass=t.navLinkClass),e.childNavItemClass===NavDefaults.childNavItemClass&&null!=t.childNavItemClass&&(e.childNavItemClass=t.childNavItemClass),e.childNavLinkClass===NavDefaults.childNavLinkClass&&null!=t.childNavLinkClass&&(e.childNavLinkClass=t.childNavLinkClass),e.childNavMenuClass===NavDefaults.childNavMenuClass&&null!=t.childNavMenuClass&&(e.childNavMenuClass=t.childNavMenuClass),e.childNavMenuItemClass===NavDefaults.childNavMenuItemClass&&null!=t.childNavMenuItemClass&&(e.childNavMenuItemClass=t.childNavMenuItemClass),e)}static showNav(e,t){return null==t||0===t.length?null==e.show:!(null!=e.show&&t.indexOf(e.show)<0||null!=e.hide&&0<=t.indexOf(e.hide))}}class NavLinkDefaults{static forNavLink(e){return e||NavDefaults.create()}}class NavbarDefaults{static navClass="navbar-nav";static create(){return new NavOptions({navClass:NavbarDefaults.navClass})}static forNavbar(e){return NavDefaults.overrideDefaults(e,NavbarDefaults.create())}}class NavButtonGroupDefaults{static navClass="btn-group";static navItemClass="btn btn-primary";static create(){return new NavOptions({navClass:NavButtonGroupDefaults.navClass,navItemClass:NavButtonGroupDefaults.navItemClass})}static forNavButtonGroup(e){return NavDefaults.overrideDefaults(e,NavButtonGroupDefaults.create())}}class LinkButtonDefaults{static navItemClass="btn";static create(){return new NavOptions({navItemClass:LinkButtonDefaults.navItemClass})}static forLinkButton(e){return NavDefaults.overrideDefaults(e||null,LinkButtonDefaults.create())}}class UserAttributes{static fromSession(e){var t=[];return null!=e&&(t.push("auth"),e.roles&&t.push(...e.roles.map(e=>"role:"+e)),e.permissions)&&t.push(...e.permissions.map(e=>"perm:"+e)),t}}class NavOptions{static fromSession(e,t){return(t=t||new NavOptions).attributes=UserAttributes.fromSession(e),t}attributes;activePath;baseHref;navClass;navItemClass;navLinkClass;childNavItemClass;childNavLinkClass;childNavMenuClass;childNavMenuItemClass;constructor(e){this.attributes=[],this.navClass=NavDefaults.navClass,this.navItemClass=NavDefaults.navItemClass,this.navLinkClass=NavDefaults.navLinkClass,this.childNavItemClass=NavDefaults.childNavItemClass,this.childNavLinkClass=NavDefaults.childNavLinkClass,this.childNavMenuClass=NavDefaults.childNavMenuClass,this.childNavMenuItemClass=NavDefaults.childNavMenuItemClass,Object.assign(this,e)}}function classNames(...t){var r=[];for(let e=0;ee.concat(r(t)),[])}function uniq(e){return Array.from(new Set(e)).sort((e,t)=>t/g,">").replace(/'/g,"'").replace(/"/g,"""):""+e}function htmlAttrs(t){let r=[];return Object.keys(t).forEach(e=>{0Object.keys(e).forEach(e=>{-1===t.indexOf(e)&&t.push(e)})),t}function alignLeft(e,t,r=" "){return t<0?"":t+1-e.length<=0?e:r+e+r.repeat(t+1-e.length)}function alignCenter(e,t,r=" "){var s,n;return t<0?"":(n=(e=e||"").length,s=Math.floor(t/2-n/2),n=Math.abs(n%2-t%2),r.repeat(s+1)+e+r.repeat(s+1+n))}function alignRight(e,t,r=" "){return t<0?"":t+1-e.length<=0?e:r.repeat(t+1-e.length)+e+r}function alignAuto(e,t,r=" "){var s=""+e;return s.length<=t?("number"==typeof e?alignRight:alignLeft)(s,t,r):s}function EventBus(){var{subscribe:e,publish:t}=createBus();this.subscribe=e,this.publish=t}function createBus(){let s={};return{subscribe:function(e,t){let r=Symbol("id");return s[e]||(s[e]={}),s[e][r]=t,{unsubscribe:function(){delete s[e][r],0===Object.getOwnPropertySymbols(s[e]).length&&delete s[e]}}},publish:function(t,r){s[t]&&Object.getOwnPropertySymbols(s[t]).forEach(e=>s[t][e](r))}}}class Inspect{static async vars(n){if("object"==typeof process){let s=process.env.INSPECT_VARS;if(s&&n){const e=e=>"node:"+e;await import(e("fs")).then(async r=>{await import(e("path")).then(e=>{var t=s.replace(/\\/g,"/");0<=t.indexOf("/")&&(e=e.dirname(t),r.existsSync(e)||r.mkdirSync(e)),r.writeFileSync(t,JSON.stringify(n))})})}}}static dump(e){return JSON.stringify(e,null,4).replace(/"/g,"")}static printDump(e){console.log(Inspect.dump(e))}static dumpTable(e){let s=e,n=uniqueKeys(s),a={};n.forEach(t=>{let r=t.length;s.forEach(e=>{var e=e[t];null!=e&&(e=(""+e).length)>r&&(r=e)}),a[t]=r});e=Object.keys(a).length,e=Object.keys(a).map(e=>a[e]).reduce((e,t)=>e+t,0)+2*e+(e+1);let o=[],t=(o.push(`+${"-".repeat(e-2)}+`),"|");return n.forEach(e=>t+=alignCenter(e,a[e])+"|"),o.push(t),o.push(`|${"-".repeat(e-2)}|`),s.forEach(t=>{let r="|";n.forEach(e=>r+=alignAuto(t[e],a[e])+"|"),o.push(r)}),o.push(`+${"-".repeat(e-2)}+`),o.join("\n")}static printDumpTable(e){console.log(Inspect.dumpTable(e))}}export{ResponseStatus,ResponseError,ErrorResponse,EmptyResponse,NavItem,GetNavItems,GetNavItemsResponse,MetadataTypesConfig,MetadataRoute,MetadataOperationType,MetadataTypes,MetadataTypeName,MetadataDataContract,MetadataDataMember,MetadataAttribute,MetadataPropertyType,MetadataType,NewInstanceResolver,SingletonInstanceResolver,ReadyState,ServerEventsClient,getAllMembers,ServerEventReceiver,UpdateEventSubscriber,UpdateEventSubscriberResponse,GetEventSubscribers,ServerEventUser,HttpMethods,GetAccessTokenResponse,JsonServiceClient,JsonApiClient,getMethod,getResponseStatus,ApiResult,createErrorStatus,createFieldError,isFormData,createError,toCamelCase,toPascalCase,toKebabCase,map,camelCaseAny,sanitize,nameOf,css,splitOnFirst,splitOnLast,leftPart,rightPart,lastLeftPart,lastRightPart,chop,onlyProps,humanize,ucFirst,isUpper,isLower,isDigit,splitTitleCase,humanify,queryString,combinePaths,createPath,createUrl,appendQueryString,setQueryString,bytesToBase64,stripQuotes,tryDecode,parseCookie,normalizeKey,normalize,getField,parseResponseStatus,toFormData,toObject,errorResponseSummary,errorResponseExcept,errorResponse,isDate,toDate,toDateFmt,padInt,dateFmt,dateFmtHM,timeFmt12,toLocalISOString,toTime,msToTime,padStart,createElement,isElement,$1,$$,on,addScript,delaySet,bootstrap,bindHandlers,bootstrapForm,toVarNames,formSubmit,ajaxSubmit,serializeForm,serializeToObject,serializeToUrlEncoded,serializeToFormData,sanitizeFormData,triggerEvent,populateForm,trimEnd,safeVarName,pick,omit,omitEmpty,apply,each,resolve,mapGet,apiValue,apiValueFmt,activeClassNav,activeClass,BootstrapColors,btnColorClass,BootstrapSizes,btnSizeClass,btnClasses,NavDefaults,NavLinkDefaults,NavbarDefaults,NavButtonGroupDefaults,LinkButtonDefaults,UserAttributes,NavOptions,classNames,fromXsdDuration,toXsdDuration,toTimeSpanFmt,flatMap,uniq,enc,htmlAttrs,indexOfAny,isNullOrEmpty,fromDateTime,toDateTime,fromTimeSpan,toTimeSpan,fromGuid,toGuid,fromByteArray,toByteArray,toBase64String,StringBuffer,JSV,uniqueKeys,alignLeft,alignCenter,alignRight,alignAuto,EventBus,createBus,Inspect}; \ No newline at end of file +class ResponseStatus{constructor(e){Object.assign(this,e)}errorCode;message;stackTrace;errors;meta}class ResponseError{constructor(e){Object.assign(this,e)}errorCode;fieldName;message;meta}class ErrorResponse{constructor(e){Object.assign(this,e)}type;responseStatus}class EmptyResponse{constructor(e){Object.assign(this,e)}responseStatus}class NavItem{label;href;exact;id;className;iconClass;show;hide;children;meta;constructor(e){Object.assign(this,e)}}class GetNavItems{constructor(e){Object.assign(this,e)}createResponse(){return new GetNavItemsResponse}getTypeName(){return"GetNavItems"}getMethod(){return"GET"}}class GetNavItemsResponse{baseUrl;results;navItemsMap;meta;responseStatus;constructor(e){Object.assign(this,e)}}class MetadataTypesConfig{baseUrl;defaultNamespaces;defaultImports;includeTypes;excludeTypes;treatTypesAsStrings;globalNamespace;ignoreTypes;exportTypes;exportAttributes;ignoreTypesInNamespaces;constructor(e){Object.assign(this,e)}}class MetadataRoute{path;verbs;notes;summary;constructor(e){Object.assign(this,e)}}class MetadataOperationType{request;response;actions;returnsVoid;returnType;routes;dataModel;viewModel;requiresAuth;requiredRoles;requiresAnyRole;requiredPermissions;requiresAnyPermission;tags;constructor(e){Object.assign(this,e)}}class MetadataTypes{config;namespaces;types;operations;constructor(e){Object.assign(this,e)}}class MetadataTypeName{name;namespace;genericArgs;constructor(e){Object.assign(this,e)}}class MetadataDataContract{name;namespace;constructor(e){Object.assign(this,e)}}class MetadataDataMember{name;order;isRequired;emitDefaultValue;constructor(e){Object.assign(this,e)}}class MetadataAttribute{name;constructorArgs;args;constructor(e){Object.assign(this,e)}}class MetadataPropertyType{name;type;isValueType;isSystemType;isEnum;isPrimaryKey;typeNamespace;genericArgs;value;description;dataMember;readOnly;paramType;displayType;isRequired;allowableValues;allowableMin;allowableMax;attributes;constructor(e){Object.assign(this,e)}}class MetadataType{name;namespace;genericArgs;inherits;implements;displayType;description;isNested;isEnum;isEnumInt;isInterface;isAbstract;dataContract;properties;attributes;innerTypes;enumNames;enumValues;enumMemberValues;enumDescriptions;meta;constructor(e){Object.assign(this,e)}}class NewInstanceResolver{tryResolve(e){return new e}}class SingletonInstanceResolver{tryResolve(e){return e.instance||(e.instance=new e)}}function eventMessageType(e){switch(e){case"onConnect":return"ServerEventConnect";case"onHeartbeat":return"ServerEventHeartbeat";case"onJoin":return"ServerEventJoin";case"onLeave":return"ServerEventLeave";case"onUpdate":return"ServerEventUpdate"}return null}var ReadyState,Types;!function(e){e[e.CONNECTING=0]="CONNECTING",e[e.OPEN=1]="OPEN",e[e.CLOSED=2]="CLOSED"}(ReadyState=ReadyState||{});class ServerEventsClient{channels;options;eventSource;static UnknownChannel="*";eventStreamUri;updateSubscriberUrl;connectionInfo;serviceClient;stopped;resolver;listeners;EventSource;withCredentials;constructor(e,t,r={},s=null){if(this.channels=t,this.options=r,this.eventSource=s,0===this.channels.length)throw"at least 1 channel is required";this.resolver=this.options.resolver||new NewInstanceResolver,this.eventStreamUri=combinePaths(e,"event-stream")+"?",this.updateChannels(t),this.serviceClient=new JsonServiceClient(e),this.listeners={},this.withCredentials=!0,this.options.handlers||(this.options.handlers={})}onMessage=e=>{if("undefined"==typeof document){var t,r,s,n=e.data?e.data.indexOf("\n"):-1;if(0<=n)return t=e.data,s=e.lastEventId,r=Object.assign({},{lastEventId:s,data:t.substring(0,n)}),s=Object.assign({},{lastEventId:s,data:t.substring(n+1)}),this._onMessage(r),void this._onMessage(s)}this._onMessage(e)};_onMessage=a=>{if(!this.stopped){let n=this.options;void 0===o&&(o={querySelectorAll:e=>[]});var o,i=splitOnFirst(a.data," ");let e=null,t=i[0];var l=splitOnFirst(t,"@"),l=(1{if(this.eventSource.readyState===EventSource.CLOSED)clearInterval(n.heartbeat),null!=(e=n.handlers.onStop)&&e.apply(this.eventSource),this.reconnectServerEvents({error:new Error("EventSource is CLOSED")});else{var e=new Request(n.heartbeatUrl,{method:"POST",mode:"cors",headers:s,credentials:this.serviceClient.credentials});try{var t,r=await fetch(e);r.ok?await r.text():(t=new Error(r.status+" - "+r.statusText),this.reconnectServerEvents({error:t}))}catch(e){this.reconnectServerEvents({error:e})}}},this.connectionInfo&&this.connectionInfo.heartbeatIntervalMs||n.heartbeatIntervalMs||1e4)),n.unRegisterUrl&&"undefined"!=typeof window&&(window.onunload=()=>{navigator.sendBeacon?(this.stopped=!0,this.eventSource&&this.eventSource.close(),navigator.sendBeacon(n.unRegisterUrl)):this.stop()}),this.updateSubscriberUrl=n.updateSubscriberUrl,this.updateChannels((n.channels||"").split(","))}else{p="onJoin"==h||"onLeave"==h||"onUpdate"==h;let e=n.handlers[h];e?p?e.call(f||o.body,l):e.call(f||o.body,r,a):p||(c=n.receivers&&n.receivers.cmd,this.invokeReceiver(c,h,f,a,"cmd")),p&&(e=n.handlers.onCommand)&&e.call(f||o.body,l)}else"trigger"===u?this.raiseEvent(i,a):"css"===u&&css(d||$$("body"),h,r);c=n.receivers&&n.receivers[u];this.invokeReceiver(c,h,f,a,u),eventMessageType(h)||(p=n.handlers.onMessage)&&p.call(f||o.body,l),n.onTick&&n.onTick()}}};onError=e=>{var t;this.stopped||(e=e||event,null!=(t=this.options.onException)&&t.call(this.eventSource,e),this.options.onTick&&this.options.onTick())};getEventSourceOptions(){return{withCredentials:this.withCredentials}}reconnectServerEvents(t={}){if(!this.stopped){t.error&&this.onError(t.error);const n=this.eventSource;let e=t.url||this.eventStreamUri||n.url;null!=this.options.resolveStreamUrl&&(e=this.options.resolveStreamUrl(e));var r=new(this.EventSource||EventSource)(e,this.getEventSourceOptions()),s=(r.addEventListener("error",e=>(t.onerror||n.onerror||this.onError)(e)),r.addEventListener("message",t.onmessage||n.onmessage||this.onMessage),this.options.onReconnect);return null!=s&&s.call(r,t.error),n.removeEventListener&&(n.removeEventListener("error",this.onError),n.removeEventListener("message",this.onMessage)),n.close(),this.eventSource=r}}start(){if(this.stopped=!1,null==this.eventSource||this.eventSource.readyState===EventSource.CLOSED){let e=this.eventStreamUri;null!=this.options.resolveStreamUrl&&(e=this.options.resolveStreamUrl(e)),this.eventSource=new(this.EventSource||EventSource)(e,this.getEventSourceOptions()),this.eventSource.addEventListener("error",this.onError),this.eventSource.addEventListener("message",e=>this.onMessage(e))}return this}stop(){this.stopped=!0,this.eventSource&&this.eventSource.close();var e=this.options,e=(e&&e.heartbeat&&clearInterval(e.heartbeat),this.connectionInfo);return null==e||null==e.unRegisterUrl?new Promise((e,t)=>e()):(this.connectionInfo=null,fetch(new Request(e.unRegisterUrl,{method:"POST",mode:"cors",credentials:this.serviceClient.credentials})).then(e=>{if(!e.ok)throw new Error(e.status+" - "+e.statusText)}).catch(this.onError))}invokeReceiver(r,e,s,n,t){if(r)if("function"==typeof r&&(r=this.resolver.tryResolve(r)),e=e.replace("-",""),r.client=this,r.request=n,"function"==typeof r[e])r[e].call(s||r,n.body,n);else if(e in r)r[e]=n.body;else{var a=Object.getOwnPropertyDescriptor(r,e);if(null!=a)a.set?a.set(n.body):a.writable&&(r[e]=n.body);else{let t=e.toLowerCase();getAllMembers(r).forEach(e=>{e.toLowerCase()==t&&("function"==typeof r[e]?r[e].call(s||r,n.body,n):r[e]=n.body)});a=r.noSuchMethod;"function"==typeof a&&a.call(s||r,n.target,n)}}}hasConnected(){return null!=this.connectionInfo}registerHandler(e,t){return this.options.handlers||(this.options.handlers={}),this.options.handlers[e]=t,this}setResolver(e){return this.options.resolver=e,this}registerReceiver(e){return this.registerNamedReceiver("cmd",e)}registerNamedReceiver(e,t){return this.options.receivers||(this.options.receivers={}),this.options.receivers[e]=t,this}unregisterReceiver(e="cmd"){return this.options.receivers&&delete this.options.receivers[e],this}updateChannels(e){this.channels=e;var t=null!=this.eventSource?this.eventSource.url:this.eventStreamUri;this.eventStreamUri=t.substring(0,Math.min(t.indexOf("?"),t.length))+"?channels="+e.join(",")+"&t="+(new Date).getTime()}update(e,t){var r,s="string"==typeof e?e.split(","):e,n="string"==typeof t?t.split(","):t,a=[];for(r in this.channels){var o=this.channels[r];null!=n&&-1!==n.indexOf(o)||a.push(o)}if(s)for(var i in s){i=s[i];-1===a.indexOf(i)&&a.push(i)}this.updateChannels(a)}addListener(e,t){return(this.listeners[e]||(this.listeners[e]=[])).push(t),this}removeListener(e,t){e=this.listeners[e];return e&&0<=(t=e.indexOf(t))&&e.splice(t,1),this}raiseEvent(e,t){e=this.listeners[e];e&&e.forEach(e=>{try{e(t)}catch(e){this.onError(e)}})}getConnectionInfo(){if(null==this.connectionInfo)throw"Not Connected";return this.connectionInfo}getSubscriptionId(){return this.getConnectionInfo().id}updateSubscriber(t){return null==t.id&&(t.id=this.getSubscriptionId()),this.serviceClient.post(t).then(e=>{this.update(t.subscribeChannels,t.unsubscribeChannels)}).catch(this.onError)}subscribeToChannels(...t){var e=new UpdateEventSubscriber;return e.id=this.getSubscriptionId(),e.subscribeChannels=t,this.serviceClient.post(e).then(e=>{this.update(t,null)}).catch(this.onError)}unsubscribeFromChannels(...t){var e=new UpdateEventSubscriber;return e.id=this.getSubscriptionId(),e.unsubscribeChannels=t,this.serviceClient.post(e).then(e=>{this.update(null,t)}).catch(this.onError)}getChannelSubscribers(){var e=new GetEventSubscribers;return e.channels=this.channels,this.serviceClient.get(e).then(e=>e.map(e=>this.toServerEventUser(e))).catch(e=>(this.onError(e),[]))}toServerEventUser(e){var t,r=e.channels,s=new ServerEventUser;for(t in s.userId=e.userId,s.displayName=e.displayName,s.profileUrl=e.profileUrl,s.channels=r?r.split(","):null,e)"userId"!=t&&"displayName"!=t&&"profileUrl"!=t&&"channels"!=t&&(null==s.meta&&(s.meta={}),s.meta[t]=e[t]);return s}}function getAllMembers(e){let s=[];do{var t=Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e).map(e=>e.toString())).sort().filter((e,t,r)=>"constructor"!==e&&(0==t||e!==r[t-1])&&-1===s.indexOf(e));s=s.concat(t)}while((e=Object.getPrototypeOf(e))&&Object.getPrototypeOf(e));return s}class ServerEventReceiver{client;request;noSuchMethod(e,t){}}class UpdateEventSubscriber{id;subscribeChannels;unsubscribeChannels;createResponse(){return new UpdateEventSubscriberResponse}getTypeName(){return"UpdateEventSubscriber"}}class UpdateEventSubscriberResponse{responseStatus}class GetEventSubscribers{channels;createResponse(){return[]}getTypeName(){return"GetEventSubscribers"}}class ServerEventUser{userId;displayName;profileUrl;channels;meta}class HttpMethods{static Get="GET";static Post="POST";static Put="PUT";static Delete="DELETE";static Patch="PATCH";static Head="HEAD";static Options="OPTIONS";static hasRequestBody=e=>!("GET"===e||"DELETE"===e||"HEAD"===e||"OPTIONS"===e)}class GetAccessToken{constructor(e){Object.assign(this,e)}refreshToken;useTokenCookie;createResponse(){return new GetAccessTokenResponse}getTypeName(){return"GetAccessToken"}getMethod(){return"POST"}}class GetAccessTokenResponse{accessToken;responseStatus}class JsonServiceClient{baseUrl;replyBaseUrl;oneWayBaseUrl;mode;credentials;headers;userName;password;bearerToken;refreshToken;refreshTokenUri;useTokenCookie;enableAutoRefreshToken;requestFilter;static globalRequestFilter;responseFilter;static globalResponseFilter;exceptionFilter;urlFilter;onAuthenticationRequired;manageCookies;cookies;parseJson;static toBase64;constructor(e="/"){this.baseUrl=e,this.mode="cors",this.credentials="include",this.headers=new Headers,this.headers.set("Content-Type","application/json"),this.manageCookies="undefined"==typeof document,this.cookies={},this.enableAutoRefreshToken=!0,this.basePath="api"}setCredentials(e,t){this.userName=e,this.password=t}useBasePath(e){return this.basePath=e,this}set basePath(e){e?(this.replyBaseUrl=combinePaths(this.baseUrl,e)+"/",this.oneWayBaseUrl=combinePaths(this.baseUrl,e)+"/"):(this.replyBaseUrl=combinePaths(this.baseUrl,"json","reply")+"/",this.oneWayBaseUrl=combinePaths(this.baseUrl,"json","oneway")+"/")}apply(e){return e(this),this}get(e,t){return"string"!=typeof e?this.fetch(HttpMethods.Get,e,t):this.fetch(HttpMethods.Get,null,t,this.toAbsoluteUrl(e))}delete(e,t){return"string"!=typeof e?this.fetch(HttpMethods.Delete,e,t):this.fetch(HttpMethods.Delete,null,t,this.toAbsoluteUrl(e))}post(e,t){return this.fetch(HttpMethods.Post,e,t)}postToUrl(e,t,r){return this.fetch(HttpMethods.Post,t,r,this.toAbsoluteUrl(e))}postBody(e,t,r){return this.fetchBody(HttpMethods.Post,e,t,r)}put(e,t){return this.fetch(HttpMethods.Put,e,t)}putToUrl(e,t,r){return this.fetch(HttpMethods.Put,t,r,this.toAbsoluteUrl(e))}putBody(e,t,r){return this.fetchBody(HttpMethods.Put,e,t,r)}patch(e,t){return this.fetch(HttpMethods.Patch,e,t)}patchToUrl(e,t,r){return this.fetch(HttpMethods.Patch,t,r,this.toAbsoluteUrl(e))}patchBody(e,t,r){return this.fetchBody(HttpMethods.Patch,e,t,r)}publish(e,t){return this.sendOneWay(e,t)}sendOneWay(e,t){var r=combinePaths(this.oneWayBaseUrl,nameOf(e));return this.fetch(HttpMethods.Post,e,null,r)}sendAll(e){var t;return 0==e.length?Promise.resolve([]):(t=combinePaths(this.replyBaseUrl,nameOf(e[0])+"[]"),this.fetch(HttpMethods.Post,e,null,t))}sendAllOneWay(e){var t;return 0==e.length?Promise.resolve(void 0):(t=combinePaths(this.oneWayBaseUrl,nameOf(e[0])+"[]"),this.fetch(HttpMethods.Post,e,null,t).then(e=>{}))}createUrlFromDto(e,t){let r=combinePaths(this.replyBaseUrl,nameOf(t));e=HttpMethods.hasRequestBody(e);return r=e?r:appendQueryString(r,t)}toAbsoluteUrl(e){return e.startsWith("http://")||e.startsWith("https://")?e:combinePaths(this.baseUrl,e)}deleteCookie(e){this.manageCookies?delete this.cookies[e]:document&&(document.cookie=e+"=; expires=Thu, 01 Jan 1970 00:00:00 UTC; path=/")}createRequest({method:e,request:t,url:r,args:s,body:n}){r=r||this.createUrlFromDto(e,t),s&&(r=appendQueryString(r,s)),null!=this.bearerToken?this.headers.set("Authorization","Bearer "+this.bearerToken):null!=this.userName&&this.headers.set("Authorization","Basic "+JsonServiceClient.toBase64(this.userName+":"+this.password)),this.manageCookies&&(0<(s=Object.keys(this.cookies).map(e=>{e=this.cookies[e];return e.expires&&e.expires0{"set-cookie"===t.toLowerCase()&&e.split(",").forEach(e=>r.push(e))}),r.forEach(e=>{e=parseCookie(e);e&&(this.cookies[e.name]=e)})}e.headers.forEach((e,t)=>{"x-cookies"===t.toLowerCase()&&0<=e.split(",").indexOf("ss-reftok")&&(this.useTokenCookie=!0)}),this.applyResponseFilters(e);let r=t&&"string"!=typeof t&&"function"==typeof t.createResponse?t.createResponse():null;if("string"==typeof r)return e.text().then(e=>e);t=e.headers.get("content-type"),t=t&&-1!==t.indexOf("application/json");if(t)return this.json(e).then(e=>e);if("undefined"!=typeof Uint8Array&&r instanceof Uint8Array){if("function"!=typeof e.arrayBuffer)throw new Error("This fetch polyfill does not implement 'arrayBuffer'");return e.arrayBuffer().then(e=>new Uint8Array(e))}if("function"==typeof Blob&&r instanceof Blob){if("function"!=typeof e.blob)throw new Error("This fetch polyfill does not implement 'blob'");return e.blob().then(e=>e)}var s=e.headers.get("content-length");return"0"===s||null==s&&!t?e.text().then(e=>r):this.json(e).then(e=>e)}handleError(e,r,t=null){if(r instanceof Error)throw this.raiseError(e,r);if(r.bodyUsed)throw this.raiseError(r,createErrorResponse(r.status,r.statusText,t));return void 0===r.json&&r.responseStatus?new Promise((e,t)=>t(this.raiseError(null,r))):this.json(r).then(e=>{e=sanitize(e);if(e.responseStatus)throw null!=t&&(e.type=t),e;throw createErrorResponse(r.status,r.statusText,t)}).catch(e=>{if(e instanceof Error||"undefined"!=typeof window&&window.DOMException&&e instanceof window.DOMException)throw this.raiseError(r,createErrorResponse(r.status,r.statusText,t));throw this.raiseError(r,e)})}fetch(e,t,r,s){return this.sendRequest({method:e,request:t,args:r,url:s})}fetchBody(e,t,r,s){var n=combinePaths(this.replyBaseUrl,nameOf(t));return this.sendRequest({method:e,request:r,body:"string"==typeof r||isFormData(r)?r:JSON.stringify(r),url:appendQueryString(n,t),args:s,returns:t})}sendRequest(t){var e=this.createRequest(t);const r=t.returns||t.request;let n=null;const a=()=>{var e=this.createRequest(t);return this.urlFilter&&this.urlFilter(e.url),fetch(e.url,e).then(e=>this.createResponse(e,r)).catch(e=>this.handleError(n,e))};return this.urlFilter&&this.urlFilter(e.url),fetch(e.url,e).then(e=>{return n=e,this.createResponse(e,r)}).catch(e=>{if(401===e.status){if(this.enableAutoRefreshToken&&(this.refreshToken||this.useTokenCookie||null!=this.cookies["ss-reftok"])){const s=new GetAccessToken({refreshToken:this.refreshToken,useTokenCookie:!!this.useTokenCookie});var t=this.refreshTokenUri||this.createUrlFromDto(HttpMethods.Post,s),r=(this.useTokenCookie&&(this.bearerToken=null,this.headers.delete("Authorization")),this.createRequest({method:HttpMethods.Post,request:s,args:null,url:t}));return fetch(t,r).then(e=>this.createResponse(e,s).then(e=>(this.bearerToken=e?.accessToken||null,a()))).catch(e=>this.onAuthenticationRequired?this.onAuthenticationRequired().then(a).catch(e=>this.handleError(n,e,"RefreshTokenException")):this.handleError(n,e,"RefreshTokenException"))}if(this.onAuthenticationRequired)return this.onAuthenticationRequired().then(a)}return this.handleError(n,e)})}raiseError(e,t){return null!=this.exceptionFilter&&this.exceptionFilter(e,t),t}send(e,t,r){return this.sendRequest({method:getMethod(e),request:e,args:t,url:r})}sendVoid(e,t,r){return this.sendRequest({method:getMethod(e),request:e,args:t,url:r})}async api(e,t,r){try{var s=await this.fetch(getMethod(e,r),e,t);return new ApiResult({response:s})}catch(e){return new ApiResult({error:getResponseStatus(e)})}}async apiVoid(e,t,r){try{var s=await this.fetch(getMethod(e,r),e,t);return new ApiResult({response:s??new EmptyResponse})}catch(e){return new ApiResult({error:getResponseStatus(e)})}}async apiForm(e,t,r,s){try{var n=await this.fetchBody(getMethod(e,s),e,t,r);return new ApiResult({response:n})}catch(e){return new ApiResult({error:getResponseStatus(e)})}}async apiFormVoid(e,t,r,s){try{var n=await this.fetchBody(getMethod(e,s),e,t,r);return new ApiResult({response:n??new EmptyResponse})}catch(e){return new ApiResult({error:getResponseStatus(e)})}}}class JsonApiClient{static create(e="/",t){return new JsonServiceClient(e).apply(e=>{e.basePath="/api",e.headers=new Headers,e.enableAutoRefreshToken=!1,t&&t(e)})}}function getMethod(e,t){return t??("function"==typeof e.getMethod?e.getMethod():HttpMethods.Post)}function getResponseStatus(e){return e.responseStatus??e.ResponseStatus??(e.errorCode?e:e.message?createErrorStatus(e.message,e.errorCode):null)}class ApiResult{response;error;constructor(e){Object.assign(this,e)}get completed(){return null!=this.response||null!=this.error}get failed(){return null!=this.error?.errorCode||null!=this.error?.message}get succeeded(){return!this.failed&&null!=this.response}get errorMessage(){return this.error?.message}get errorCode(){return this.error?.errorCode}get errors(){return this.error?.errors??[]}get errorSummary(){return null!=this.error&&0==this.errors.length?this.errorMessage:null}fieldError(e){let t=e.toLowerCase();return this.errors?.find(e=>e.fieldName.toLowerCase()==t)}fieldErrorMessage(e){return this.fieldError(e)?.message}hasFieldError(e){return null!=this.fieldError(e)}showSummary(e=[]){return!!this.failed&&e.every(e=>!this.hasFieldError(e))}summaryMessage(e=[]){if(this.showSummary(e)){let t=e.map(e=>e.toLowerCase());return t.find(e=>-1==t.indexOf(e.toLowerCase()))??this.errorMessage}}addFieldError(e,t,r="Exception"){this.error||(this.error=new ResponseStatus);var s=this.fieldError(e);null!=s?(s.errorCode=r,s.message=t):this.error.errors.push(new ResponseError({fieldName:e,errorCode:r,message:t}))}}function createErrorStatus(e,t="Exception"){return new ResponseStatus({errorCode:t,message:e})}function createFieldError(e,t,r="Exception"){return new ResponseStatus({errors:[new ResponseError({fieldName:e,errorCode:r,message:t})]})}function isFormData(e){return"undefined"!=typeof window&&e instanceof FormData}function createErrorResponse(t,r,s=null){return apply(new ErrorResponse,e=>{null!=s&&(e.type=s),e.responseStatus=apply(new ResponseStatus,e=>{e.errorCode=t&&t.toString(),e.message=r})})}function createError(e,t,r){return new ErrorResponse({responseStatus:new ResponseStatus({errorCode:e,message:t,errors:r?[new ResponseError({errorCode:e,message:t,fieldName:r})]:void 0})})}function toCamelCase(e){return e&&e.charAt(0).toLowerCase()+e.substring(1)}function toPascalCase(e){return e&&e.charAt(0).toUpperCase()+e.substring(1)}function toKebabCase(e){return(e||"").replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase()}function map(e,t){return null==e?null:t(e)}function camelCaseAny(e){if(!e||!(e instanceof Object)||Array.isArray(e))return e;var t,r,s,n={};for(t in e)e.hasOwnProperty(t)&&(r=toCamelCase(t),s=e[t],Array.isArray(s)?n[r]=s.map(e=>camelCaseAny(e)):s instanceof Object?n[r]=camelCaseAny(s):n[r]=s);return n}function sanitize(e){return sanitize&&(e.responseStatus||e.errors?e:camelCaseAny(e))}function nameOf(e){if(!e)return"null";if("function"==typeof e.getTypeName)return e.getTypeName();var t=e&&e.constructor;if(null==t)throw e+" doesn't have constructor";return t.name||(e=t.toString()).substring(9,e.indexOf("("))}function log(e,t="LOG"){return console.log(t,e),e}function css(e,t,r){var s="string"==typeof e?document.querySelectorAll(e):e;for(let e=0;er[e]=t[e]),r}function splitCase(e){return"string"!=typeof e?e:e.replace(/([A-Z]|[0-9]+)/g," $1").replace(/_/g," ").trim()}function humanize(e){return!e||0<=e.indexOf(" ")?e:splitCase(toPascalCase(e))}const ucFirst=e=>e.charAt(0).toUpperCase()+e.substring(1),isUpper=e=>"A"<=e&&e<="Z",isLower=e=>"a"<=e&&e<="z",isDigit=e=>"0"<=e&&e<="9",upperOrDigit=e=>isUpper(e)||isDigit(e);function splitTitleCase(t){var r=[];if("string"!=typeof t)return r;let s=0;for(let e=0;e!!e)}function humanify(e){return!e||0<=e.indexOf(" ")?e:ucFirst(splitTitleCase(e).join(" "))}function queryString(e){if(!e||-1===e.indexOf("?"))return{};var t=rightPart(e,"?").split("&"),r={};for(let e=0;e>>e&24),2!=e&&n.length-s!=1||(a+=String.fromCharCode(uint6ToB64(r>>>18&63),uint6ToB64(r>>>12&63),uint6ToB64(r>>>6&63),uint6ToB64(63&r)),r=0);return 0==e?a:a.substring(0,a.length-e)+(1==e?"=":"==")}function uint6ToB64(e){return e<26?e+65:e<52?e+71:e<62?e-4:62===e?43:63===e?47:65}function _btoa(e){return"function"==typeof btoa?btoa(e):Buffer.from(e).toString("base64")}function _atob(e){return"function"==typeof atob?atob(e):Buffer.from(e,"base64").toString()}function stripQuotes(e){return e&&'"'==e[0]&&'"'==e[e.length]?e.slice(1,-1):e}function tryDecode(t){try{return decodeURIComponent(t)}catch(e){return t}}function parseCookie(e){if(!e)return null;let t=null;var r=e.split(/; */);for(let e=0;enormalizeKey(e)===normalizeKey(t))[0]||""]}function parseResponseStatus(t,r=null){try{var e=JSON.parse(t);return sanitize(e.ResponseStatus||e.responseStatus)}catch(e){return{message:r||e.message||e,__error:{error:e,json:t}}}}function toFormData(e){if("undefined"!=typeof window){var t,r=new FormData;for(t in e)r.append(t,e[t]);return r}}function toObject(e){const t={};if(e){if("object"!=typeof e)throw new Error("keys must be an Array of object keys");Array.prototype.slice.call(e).forEach(e=>{this[e]&&(t[e]=this[e])})}return t}function errorResponseSummary(){var e=this.responseStatus||this.ResponseStatus;return null==e||(e=e.ErrorCode?sanitize(e):e).errors&&0!=e.errors.length?void 0:e.message||e.errorCode}function errorResponseExcept(e){var t=this.responseStatus||this.ResponseStatus;if(null!=t){t=t.ErrorCode?sanitize(t):t,e=toVarNames(e);if(e&&null!=t.errors&&0!=t.errors.length){var r,s,n=e.map(e=>(e||"").toLowerCase());for(r of t.errors)if(-1!==n.indexOf((r.fieldName||"").toLowerCase()))return;for(s of t.errors)if(-1===n.indexOf((s.fieldName||"").toLowerCase()))return s.message||s.errorCode}return t.message||t.errorCode||void 0}}function errorResponse(t){var e;return null==t?errorResponseSummary.call(this):null!=(e=this.responseStatus||this.ResponseStatus)&&null!=(e=e.ErrorCode?sanitize(e):e).errors&&0!=e.errors.length&&(e=e.errors.find(e=>(e.fieldName||"").toLowerCase()==t.toLowerCase()))?e.message||e.errorCode:void 0}function isDate(e){return e&&"[object Date]"===Object.prototype.toString.call(e)&&!isNaN(e)}function toDate(e){return e?isDate(e)?e:"/"==e[0]?new Date(parseFloat(/Date\(([^)]+)\)/.exec(e)[1])):new Date(e):null}function toDateFmt(e){return dateFmt(toDate(e))}function padInt(e){return e<10?"0"+e:e}function dateFmt(e=new Date){return e.getFullYear()+"/"+padInt(e.getMonth()+1)+"/"+padInt(e.getDate())}function dateFmtHM(e=new Date){return e.getFullYear()+"/"+padInt(e.getMonth()+1)+"/"+padInt(e.getDate())+" "+padInt(e.getHours())+":"+padInt(e.getMinutes())}function timeFmt12(e=new Date){return padInt((e.getHours()+24)%12||12)+":"+padInt(e.getMinutes())+":"+padInt(e.getSeconds())+" "+(12'+e+""}function attr(e,t){return e.getAttribute(t)}function sattr(e,t,r){return e.setAttribute(t,r)}function rattr(e,t){return e.removeAttribute(t)}function createElement(e,t){var r={className:"class",htmlFor:"for"},s=document.createElement(e);if(t?.attrs)for(const n in t.attrs)sattr(s,r[n]||n,t.attrs[n]);return t?.events&&on(s,t.events),t&&t.insertAfter&&t.insertAfter.parentNode.insertBefore(s,t.insertAfter.nextSibling),s}function showInvalidInputs(){var e,t,r,s=attr(this,"data-invalid");s&&(e=(r="checkbox"===this.type||"radio"===this.type||hasClass(this,"form-check"))?parent(this,"form-check"):null,r?addClass(e||this.parentElement,"is-invalid form-control"):addClass(this,"is-invalid"),(null!=(r=!(t=this.nextElementSibling)||attr(t,"for")!==this.id&&"SMALL"!==t.tagName?this:r?e||t.parentElement:t)&&r.nextElementSibling&&hasClass(r.nextElementSibling,"invalid-feedback")?r.nextElementSibling:createElement("div",{insertAfter:r,attrs:{className:"invalid-feedback"}})).innerHTML=s)}function parent(e,t){for(;null!=e&&!hasClass(e,t);)e=e.parentElement;return e}function hasClass(e,t){return!!e&&(e.classList?e.classList.contains(t):-1<(" "+e.className+" ").replace(/[\n\t\r]/g," ").indexOf(" "+t+" "))}function addClass(e,t){return e?e.classList?e.classList.add(...t.split(" ")):hasClass(e,t)?null:e.className=(e.className+" "+t).trim():null}function remClass(e,t){return e?e.classList?e.classList.remove(t):hasClass(e,t)?e.className=e.className.replace(/(\s|^)someclass(\s|$)/," "):null:null}function isElement(e){return"undefined"!=typeof window&&(e instanceof window.Element||e==window.document)}function $1(e,t){return"string"==typeof e?(t||document).querySelector(e):e||null}function $$(e,t){return"string"==typeof e?Array.from((t||"undefined"!=typeof document?document:null)?.querySelectorAll(e)??[]):Array.isArray(e)?e.flatMap(e=>$$(e,t)):[e]}function on(e,s){return $$(e).forEach(r=>{Object.keys(s).forEach(function(e){var t=s[e];"string"==typeof e&&"function"==typeof t&&r.addEventListener(e,s[e]=t.bind(r))})}),s}function addScript(r){return new Promise((e,t)=>{document.body.appendChild(createElement("script",{attrs:{src:r},events:{load:e,error:t}}))})}function delaySet(e,t){t=t&&t.duration||300;let r=setTimeout(()=>e(!0),t);return()=>{clearTimeout(r),e(!1)}}function bootstrap(e){var t=(e||document).querySelectorAll("[data-invalid]");for(let e=0;ehandleEvent(t,r,e)):["click","dblclick","change","focus","blur","focusin","focusout","select","keydown","keypress","keyup","hover","toggle","input"].forEach(e=>{r.querySelector(`[data-${e}]`)&&handleEvent(t,r,e)})}function bootstrapForm(t,r){t&&(r.model&&populateForm(t,r.model),t.onsubmit=function(e){return e.preventDefault(),r.type="bootstrap-v4",ajaxSubmit(t,r)})}function applyErrors(e,r,t){var s={overrideMessages:!1,messages:{NotEmpty:"Required",NotNull:"Required",Email:"Invalid email",AlreadyExists:"Already exists"},errorFilter:function(e,t,r){return this.overrideMessages?this.messages[t]||e||splitCase(t):e||splitCase(t)}};if(clearErrors(e),r){r=sanitize(r),addClass(e,"has-errors");const h=t&&"bootstrap-v4"===t.type;var s={...s,...t},o=(t.messages&&(s.overrideMessages=!0),s.errorFilter.bind(s)),t=r.errors;if(t&&t.length){let n={},a={};$$("input,textarea,select,button").forEach(e=>{var t=e.previousElementSibling,r=e.nextElementSibling,s=("radio"===e.type||"checkbox"===e.type?null:e.id)||attr(e,"name");s&&(s=s.toLowerCase(),n[s]=e,h||(hasClass(t,"help-inline")||hasClass(t,"help-block")?a[s]=t:(hasClass(r,"help-inline")||hasClass(r,"help-block"))&&(a[s]=r)))}),$$(".help-inline[data-for],.help-block[data-for]").forEach(e=>{var t=attr(e,"data-for").toLowerCase();a[t]=e});for(var i of t){var l=(i.fieldName||"").toLowerCase(),u=n[l],c=(u&&(h?("radio"!==(c=attr(u,"type"))&&"checkbox"!==c&&addClass(u,"is-invalid"),sattr(u,"data-invalid",o(i.message,i.errorCode,"field"))):(addClass(u,"error"),addClass(u.parentElement,"has-error"))),a[l]);c&&(addClass(c,"error"),c.innerHTML=o(i.message,i.errorCode,"field"),c.style.display="block")}$$("[data-validation-summary]").forEach(e=>{var t=attr(e,"data-validation-summary").split(","),t=errorResponseExcept.call(r,t);t&&(e.innerHTML=bsAlert(t))})}else{const n=o(r.message||splitCase(r.errorCode),r.errorCode,"summary");h?$$("[data-validation-summary]").forEach(e=>e.innerHTML="<"===n[0]?n:bsAlert(n)):$$(".error-summary").forEach(e=>{e.innerHTML=n(e).style.display="block"})}return e}}function clearErrors(e){remClass(e,"has-errors"),$$(".error-summary").forEach(e=>{e.innerHTML="",e.style.display="none"}),$$("[data-validation-summary]").forEach(e=>{e.innerHTML=""}),$$(".error").forEach(e=>remClass(e,"error")),$$(".form-check.is-invalid [data-invalid]").forEach(e=>{rattr(e,"data-invalid")}),$$(".form-check.is-invalid").forEach(e=>remClass(e,"form-control")),$$(".is-invalid").forEach(e=>{remClass(e,"is-invalid"),rattr(e,"data-invalid")}),$$(".is-valid").forEach(e=>remClass(e,"is-valid"))}function toVarNames(e){return e?isArray(e)?e:e.split(",").map(e=>e.trim()):[]}function formSubmit(e={}){const r=this;var t=attr(r,"enctype")||Types.UrlEncoded;if(t==Types.MultiPart&&void 0===window.FormData)throw new Error(`FormData Type is needed to send '${Types.MultiPart}' Content Types`);let s;try{s=serializeForm(r,t)}catch(e){throw new Error(""+(e.message||e))}var n=new Headers,t=(n.set("Accept",Types.Json),n.set("Content-Type",t),{method:attr(r,"method")||"POST",credentials:"include",mode:"cors",headers:n,body:s});return e.requestFilter&&e.requestFilter(t),fetch(new Request(e.url||attr(r,"action"),t)).catch(e=>{throw new Error(`Network is unreachable (${e.message||e})`)}).then(t=>(e.responseFilter&&e.responseFilter(t),t.ok?(handleHeaderBehaviors(r,t),fromResponse(t)):t.json().catch(e=>{throw new Error("The request failed with "+(t.statusText||t.status))}).then(e=>{throw Object.assign(new ErrorResponse,sanitize(e))})))}function handleHeaderBehaviors(e,t){var r=t.headers.get("X-Location"),r=(r&&(location.href=r),t.headers.get("X-Trigger"));r&&triggerEvent(e,0<=(t=r.indexOf(":"))?r.substring(0,t):r,(e=0<=t?r.substring(t+1):null)?[e]:[])}function ajaxSubmit(s,n={}){const a="bootstrap-v4"===n.type;clearErrors(s);try{if(n.validate&&!1===n.validate.call(s))return!1}catch(e){return!1}addClass(s,"loading");const e=null==n.onSubmitDisable?"[type=submit]":n.onSubmitDisable,t=null!=e&&""!=e;function r(e,t=null){var r;t?applyErrors(s,t.ResponseStatus||t.responseStatus,{...n}):e&&(addClass(s,"has-errors"),(r=$$(".error-summary")[0])&&(r.innerHTML=e),a)&&(r=$$("[data-validation-summary]")[0])&&(r.innerHTML=bsAlert(e)),n.error&&n.error.call(s,t),a&&$$("[data-invalid]").forEach(e=>showInvalidInputs.call(e))}return t&&$$(e).forEach(e=>{sattr(e,"disabled","disabled")}),(n.submit||formSubmit).call(s,n).then(e=>(n.success&&n.success.call(s,e),!1)).catch(e=>{e.responseStatus?r(null,e):r(""+(e.message||e),null)}).finally(()=>{remClass(s,"loading"),t&&$$(e).forEach(e=>{rattr(e,"disabled")}),n.complete&&n.complete.call(s)})}function fromResponse(e){var t,r=e.headers.get("content-type"),r=r&&-1!==r.indexOf(Types.Json);return!r&&("0"===(t=e.headers.get("content-length"))||null==t&&!r)?null:e.json()}function serializeForm(e,t=null){return t===Types.MultiPart?new FormData(e):t==Types.Json?JSON.stringify(serializeToObject(e)):serializeToUrlEncoded(e)}function formEntries(e,r,s){var n,a=e,o=a.elements.length;for(let t=0;te[t]=r)}function serializeToUrlEncoded(e){return formEntries(e,[],(e,t,r)=>"string"==typeof r?e.push(encodeURIComponent(t)+"="+encodeURIComponent(r)):null).join("&").replace(/%20/g,"+")}function serializeToFormData(e){return formEntries(e,new FormData,(e,t,r)=>e.append(t,r))}function sanitizeFormData(e){for(var[t,r]of e)"object"==typeof r&&0===r.size&&e.delete(t);return e}function triggerEvent(e,t,r=null){var s;document.createEvent?((s=document.createEvent("click"==t||t.startsWith("mouse")?"MouseEvents":"HTMLEvents")).initEvent(t,!0,!0),s.data=r,e.dispatchEvent(s)):(r=document.createEventObject(),e.fireEvent("on"+t,r))}function populateForm(r,s){if(s){var n;for(let e in s){let t=s[e];void 0!==t&&null!==t||(t="");var a=r.elements.namedItem(e)||r.elements.namedItem((n=e)&&(n[0]===n[0].toUpperCase()?toCamelCase(n):n[0]===n[0].toLowerCase()?toPascalCase(n):n)),o=a;if(a)switch(o.type||a[0].type){case"radio":case"checkbox":var i=a.length;for(let e=0;e(r(e,t),e),t||{})}function resolve(e,t){e="function"==typeof e?e():e;return"function"==typeof t?t(e):e}function mapGet(e,r){if(!e||!r)return null;var s=e[r];if(s)return s;if("object"!=typeof e)return null;{let t=r.toLowerCase();s=Object.keys(e).find(e=>e.toLowerCase()===t);return s?e[s]:null}}function apiValue(e){return null==e?"":"string"==typeof e?"/Date("===e.substring(0,6)?toDate(e):e.trim():e}function apiValueFmt(e){e=apiValue(e);return(null!=e?isDate(e)?dateFmt(e):e:null)||""}function activeClassNav(e,t){return null!=e.href&&(e.exact||t.length<=1?trimEnd(t,"/").toLowerCase()===trimEnd(e.href,"/").toLowerCase():trimEnd(t,"/").toLowerCase().startsWith(trimEnd(e.href,"/").toLowerCase()))?"active":null}function activeClass(e,t,r){return null!=e&&(r||t.length<=1?trimEnd(t,"/").toLowerCase()===trimEnd(e,"/").toLowerCase():trimEnd(t,"/").toLowerCase().startsWith(trimEnd(e,"/").toLowerCase()))?"active":null}function bootstrapColors(){return["primary","secondary","success","info","warning","danger","light","dark"]}JsonServiceClient.toBase64=e=>_btoa(encodeURIComponent(e).replace(/%([0-9A-F]{2})/g,(e,t)=>String.fromCharCode(new Number("0x"+t).valueOf()))),"undefined"!=typeof window&&void 0!==window.Element&&(Element.prototype.matches||(Element.prototype.matches=Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector),Element.prototype.closest||(Element.prototype.closest=function(e){let t=this;do{if(t.matches(e))return t}while(null!==(t=t.parentElement||t.parentNode)&&1===t.nodeType);return null})),function(e){e.MultiPart="multipart/form-data",e.UrlEncoded="application/x-www-form-urlencoded",e.Json="application/json"}(Types=Types||{});const BootstrapColors=bootstrapColors();function btnColorClass(e){for(const t of bootstrapColors()){if(e[t])return"btn-"+t;if(e["outline-"+t])return"btn-outline-"+t}return null}function bootstrapSizes(){return["xs","sm","md","lg"]}const BootstrapSizes=bootstrapSizes();function btnSizeClass(e){for(const t of bootstrapSizes())if(e[t])return"btn-"+t;return null}function btnClasses(e){var t=[],r=btnColorClass(e),r=(r&&t.push(r),btnSizeClass(e));return r&&t.push(r),e.block&&t.push("btn-block"),t}class NavDefaults{static navClass="nav";static navItemClass="nav-item";static navLinkClass="nav-link";static childNavItemClass="nav-item dropdown";static childNavLinkClass="nav-link dropdown-toggle";static childNavMenuClass="dropdown-menu";static childNavMenuItemClass="dropdown-item";static create(){return new NavOptions}static forNav(e){return e||NavDefaults.create()}static overrideDefaults(e,t){return null==e?t:((e=Object.assign({},e)).navClass===NavDefaults.navClass&&null!=t.navClass&&(e.navClass=t.navClass),e.navItemClass===NavDefaults.navItemClass&&null!=t.navItemClass&&(e.navItemClass=t.navItemClass),e.navLinkClass===NavDefaults.navLinkClass&&null!=t.navLinkClass&&(e.navLinkClass=t.navLinkClass),e.childNavItemClass===NavDefaults.childNavItemClass&&null!=t.childNavItemClass&&(e.childNavItemClass=t.childNavItemClass),e.childNavLinkClass===NavDefaults.childNavLinkClass&&null!=t.childNavLinkClass&&(e.childNavLinkClass=t.childNavLinkClass),e.childNavMenuClass===NavDefaults.childNavMenuClass&&null!=t.childNavMenuClass&&(e.childNavMenuClass=t.childNavMenuClass),e.childNavMenuItemClass===NavDefaults.childNavMenuItemClass&&null!=t.childNavMenuItemClass&&(e.childNavMenuItemClass=t.childNavMenuItemClass),e)}static showNav(e,t){return null==t||0===t.length?null==e.show:!(null!=e.show&&t.indexOf(e.show)<0||null!=e.hide&&0<=t.indexOf(e.hide))}}class NavLinkDefaults{static forNavLink(e){return e||NavDefaults.create()}}class NavbarDefaults{static navClass="navbar-nav";static create(){return new NavOptions({navClass:NavbarDefaults.navClass})}static forNavbar(e){return NavDefaults.overrideDefaults(e,NavbarDefaults.create())}}class NavButtonGroupDefaults{static navClass="btn-group";static navItemClass="btn btn-primary";static create(){return new NavOptions({navClass:NavButtonGroupDefaults.navClass,navItemClass:NavButtonGroupDefaults.navItemClass})}static forNavButtonGroup(e){return NavDefaults.overrideDefaults(e,NavButtonGroupDefaults.create())}}class LinkButtonDefaults{static navItemClass="btn";static create(){return new NavOptions({navItemClass:LinkButtonDefaults.navItemClass})}static forLinkButton(e){return NavDefaults.overrideDefaults(e||null,LinkButtonDefaults.create())}}class UserAttributes{static fromSession(e){var t=[];return null!=e&&(t.push("auth"),e.roles&&t.push(...e.roles.map(e=>"role:"+e)),e.permissions)&&t.push(...e.permissions.map(e=>"perm:"+e)),t}}class NavOptions{static fromSession(e,t){return(t=t||new NavOptions).attributes=UserAttributes.fromSession(e),t}attributes;activePath;baseHref;navClass;navItemClass;navLinkClass;childNavItemClass;childNavLinkClass;childNavMenuClass;childNavMenuItemClass;constructor(e){this.attributes=[],this.navClass=NavDefaults.navClass,this.navItemClass=NavDefaults.navItemClass,this.navLinkClass=NavDefaults.navLinkClass,this.childNavItemClass=NavDefaults.childNavItemClass,this.childNavLinkClass=NavDefaults.childNavLinkClass,this.childNavMenuClass=NavDefaults.childNavMenuClass,this.childNavMenuItemClass=NavDefaults.childNavMenuItemClass,Object.assign(this,e)}}function classNames(...t){var r=[];for(let e=0;ee.concat(r(t)),[])}function uniq(e){return Array.from(new Set(e)).sort((e,t)=>t/g,">").replace(/'/g,"'").replace(/"/g,"""):""+e}function htmlAttrs(t){let r=[];return Object.keys(t).forEach(e=>{0Object.keys(e).forEach(e=>{-1===t.indexOf(e)&&t.push(e)})),t}function alignLeft(e,t,r=" "){return t<0?"":t+1-e.length<=0?e:r+e+r.repeat(t+1-e.length)}function alignCenter(e,t,r=" "){var s,n;return t<0?"":(n=(e=e||"").length,s=Math.floor(t/2-n/2),n=Math.abs(n%2-t%2),r.repeat(s+1)+e+r.repeat(s+1+n))}function alignRight(e,t,r=" "){return t<0?"":t+1-e.length<=0?e:r.repeat(t+1-e.length)+e+r}function alignAuto(e,t,r=" "){var s=""+e;return s.length<=t?("number"==typeof e?alignRight:alignLeft)(s,t,r):s}function EventBus(){var{subscribe:e,publish:t}=createBus();this.subscribe=e,this.publish=t}function createBus(){let s={};return{subscribe:function(e,t){let r=Symbol("id");return s[e]||(s[e]={}),s[e][r]=t,{unsubscribe:function(){delete s[e][r],0===Object.getOwnPropertySymbols(s[e]).length&&delete s[e]}}},publish:function(t,r){s[t]&&Object.getOwnPropertySymbols(s[t]).forEach(e=>s[t][e](r))}}}class Inspect{static async vars(n){if("object"==typeof process){let s=process.env.INSPECT_VARS;if(s&&n){const e=e=>"node:"+e;await import(e("fs")).then(async r=>{await import(e("path")).then(e=>{var t=s.replace(/\\/g,"/");0<=t.indexOf("/")&&(e=e.dirname(t),r.existsSync(e)||r.mkdirSync(e)),r.writeFileSync(t,JSON.stringify(n))})})}}}static dump(e){return JSON.stringify(e,null,4).replace(/"/g,"")}static printDump(e){console.log(Inspect.dump(e))}static dumpTable(e){let s=e,n=uniqueKeys(s),a={};n.forEach(t=>{let r=t.length;s.forEach(e=>{var e=e[t];null!=e&&(e=(""+e).length)>r&&(r=e)}),a[t]=r});e=Object.keys(a).length,e=Object.keys(a).map(e=>a[e]).reduce((e,t)=>e+t,0)+2*e+(e+1);let o=[],t=(o.push(`+${"-".repeat(e-2)}+`),"|");return n.forEach(e=>t+=alignCenter(e,a[e])+"|"),o.push(t),o.push(`|${"-".repeat(e-2)}|`),s.forEach(t=>{let r="|";n.forEach(e=>r+=alignAuto(t[e],a[e])+"|"),o.push(r)}),o.push(`+${"-".repeat(e-2)}+`),o.join("\n")}static printDumpTable(e){console.log(Inspect.dumpTable(e))}}export{ResponseStatus,ResponseError,ErrorResponse,EmptyResponse,NavItem,GetNavItems,GetNavItemsResponse,MetadataTypesConfig,MetadataRoute,MetadataOperationType,MetadataTypes,MetadataTypeName,MetadataDataContract,MetadataDataMember,MetadataAttribute,MetadataPropertyType,MetadataType,NewInstanceResolver,SingletonInstanceResolver,ReadyState,ServerEventsClient,getAllMembers,ServerEventReceiver,UpdateEventSubscriber,UpdateEventSubscriberResponse,GetEventSubscribers,ServerEventUser,HttpMethods,GetAccessTokenResponse,JsonServiceClient,JsonApiClient,getMethod,getResponseStatus,ApiResult,createErrorStatus,createFieldError,isFormData,createError,toCamelCase,toPascalCase,toKebabCase,map,camelCaseAny,sanitize,nameOf,css,splitOnFirst,splitOnLast,leftPart,rightPart,lastLeftPart,lastRightPart,chop,onlyProps,humanize,ucFirst,isUpper,isLower,isDigit,splitTitleCase,humanify,queryString,combinePaths,createPath,createUrl,appendQueryString,setQueryString,bytesToBase64,stripQuotes,tryDecode,parseCookie,normalizeKey,normalize,getField,parseResponseStatus,toFormData,toObject,errorResponseSummary,errorResponseExcept,errorResponse,isDate,toDate,toDateFmt,padInt,dateFmt,dateFmtHM,timeFmt12,toLocalISOString,toTime,msToTime,padStart,createElement,isElement,$1,$$,on,addScript,delaySet,bootstrap,bindHandlers,bootstrapForm,toVarNames,formSubmit,ajaxSubmit,serializeForm,serializeToObject,serializeToUrlEncoded,serializeToFormData,sanitizeFormData,triggerEvent,populateForm,trimEnd,safeVarName,pick,omit,omitEmpty,apply,each,resolve,mapGet,apiValue,apiValueFmt,activeClassNav,activeClass,BootstrapColors,btnColorClass,BootstrapSizes,btnSizeClass,btnClasses,NavDefaults,NavLinkDefaults,NavbarDefaults,NavButtonGroupDefaults,LinkButtonDefaults,UserAttributes,NavOptions,classNames,fromXsdDuration,toXsdDuration,toTimeSpanFmt,flatMap,uniq,enc,htmlAttrs,indexOfAny,isNullOrEmpty,fromDateTime,toDateTime,fromTimeSpan,toTimeSpan,fromGuid,toGuid,fromByteArray,toByteArray,toBase64String,StringBuffer,JSV,uniqueKeys,alignLeft,alignCenter,alignRight,alignAuto,EventBus,createBus,Inspect}; \ No newline at end of file diff --git a/MyApp/wwwroot/lib/mjs/servicestack-client.mjs b/MyApp/wwwroot/lib/mjs/servicestack-client.mjs index 662ec63..026e037 100644 --- a/MyApp/wwwroot/lib/mjs/servicestack-client.mjs +++ b/MyApp/wwwroot/lib/mjs/servicestack-client.mjs @@ -745,8 +745,6 @@ export class JsonServiceClient { static toBase64; constructor(baseUrl = "/") { this.baseUrl = baseUrl; - this.replyBaseUrl = combinePaths(baseUrl, "json", "reply") + "/"; - this.oneWayBaseUrl = combinePaths(baseUrl, "json", "oneway") + "/"; this.mode = "cors"; this.credentials = "include"; this.headers = new Headers(); @@ -754,6 +752,7 @@ export class JsonServiceClient { this.manageCookies = typeof document == "undefined"; //because node-fetch doesn't this.cookies = {}; this.enableAutoRefreshToken = true; + this.basePath = 'api'; } setCredentials(userName, password) { this.userName = userName; @@ -769,9 +768,6 @@ export class JsonServiceClient { this.oneWayBaseUrl = combinePaths(this.baseUrl, "json", "oneway") + "/"; } else { - if (path[0] != '/') { - path = '/' + path; - } this.replyBaseUrl = combinePaths(this.baseUrl, path) + "/"; this.oneWayBaseUrl = combinePaths(this.baseUrl, path) + "/"; } @@ -1767,7 +1763,7 @@ export function $1(sel, el) { } export function $$(sel, el) { if (typeof sel === "string") - return Array.from((el || document).querySelectorAll(sel)); + return Array.from((el || typeof document != "undefined" ? document : null)?.querySelectorAll(sel) ?? []); if (Array.isArray(sel)) return sel.flatMap(x => $$(x, el)); return [sel]; diff --git a/MyApp/wwwroot/lib/mjs/servicestack-vue.min.mjs b/MyApp/wwwroot/lib/mjs/servicestack-vue.min.mjs index ff292dc..7a03e4c 100644 --- a/MyApp/wwwroot/lib/mjs/servicestack-vue.min.mjs +++ b/MyApp/wwwroot/lib/mjs/servicestack-vue.min.mjs @@ -1,4 +1,4 @@ -var lo=Object.defineProperty,no=(e,t,l)=>t in e?lo(e,t,{enumerable:!0,configurable:!0,writable:!0,value:l}):e[t]=l,Ce=(e,t,l)=>(no(e,"symbol"!=typeof t?t+"":t,l),l);import{defineComponent as ce,computed as f,openBlock as a,createElementBlock as u,normalizeClass as w,unref as o,createElementVNode as s,createCommentVNode as k,renderSlot as Z,ref as A,toDisplayString as T,inject as Ne,nextTick as xt,isRef as Gn,mergeProps as Me,withModifiers as Ue,h as gt,resolveComponent as X,createBlock as se,withCtx as ke,useAttrs as so,createVNode as $e,createTextVNode as we,watchEffect as hl,normalizeStyle as Xl,Fragment as Te,renderList as Ie,withDirectives as kt,vModelCheckbox as Yl,withKeys as Wn,createStaticVNode as wl,vModelSelect as oo,useSlots as en,getCurrentInstance as Be,onMounted as tt,createSlots as tn,normalizeProps as jt,guardReactiveProps as gl,vModelDynamic as ao,onUnmounted as Rt,watch as Lt,vModelText as io,resolveDynamicComponent as Jn,provide as Xt,resolveDirective as ro}from"vue";import{errorResponseExcept as uo,dateFmt as Xn,toTime as co,omit as dt,enc as Hl,setQueryString as fo,appendQueryString as Kt,nameOf as mo,ApiResult as Je,lastRightPart as $t,leftPart as xl,map as qe,toDate as Vt,toDateTime as vo,toCamelCase as ho,mapGet as ye,chop as go,fromXsdDuration as Yn,isDate as kl,timeFmt12 as po,apiValue as yo,indexOfAny as bo,createBus as wo,toKebabCase as Nn,sanitize as xo,humanize as He,delaySet as es,rightPart as dl,queryString as zl,combinePaths as ko,toPascalCase as st,errorResponse as mt,trimEnd as $o,$1 as pl,lastLeftPart as Co,ResponseStatus as Bl,ResponseError as Un,HttpMethods as ln,omitEmpty as _o,uniqueKeys as Nl,humanify as ts,each as Lo}from"@servicestack/client";const Vo={class:"flex items-center"},So={key:0,class:"flex-shrink-0 mr-3"},Mo={key:0,class:"h-5 w-5 text-yellow-400",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true"},Ao=s("path",{"fill-rule":"evenodd",d:"M8.257 3.099c.765-1.36 2.722-1.36 3.486 0l5.58 9.92c.75 1.334-.213 2.98-1.742 2.98H4.42c-1.53 0-2.493-1.646-1.743-2.98l5.58-9.92zM11 13a1 1 0 11-2 0 1 1 0 012 0zm-1-8a1 1 0 00-1 1v3a1 1 0 002 0V6a1 1 0 00-1-1z","clip-rule":"evenodd"},null,-1),To=[Ao],Fo={key:1,class:"h-5 w-5 text-red-400",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true"},Io=s("path",{"fill-rule":"evenodd",d:"M10 18a8 8 0 100-16 8 8 0 000 16zM8.28 7.22a.75.75 0 00-1.06 1.06L8.94 10l-1.72 1.72a.75.75 0 101.06 1.06L10 11.06l1.72 1.72a.75.75 0 101.06-1.06L11.06 10l1.72-1.72a.75.75 0 00-1.06-1.06L10 8.94 8.28 7.22z","clip-rule":"evenodd"},null,-1),Do=[Io],jo={key:2,class:"h-5 w-5 text-blue-400",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true"},Oo=s("path",{"fill-rule":"evenodd",d:"M19 10.5a8.5 8.5 0 11-17 0 8.5 8.5 0 0117 0zM8.25 9.75A.75.75 0 019 9h.253a1.75 1.75 0 011.709 2.13l-.46 2.066a.25.25 0 00.245.304H11a.75.75 0 010 1.5h-.253a1.75 1.75 0 01-1.709-2.13l.46-2.066a.25.25 0 00-.245-.304H9a.75.75 0 01-.75-.75zM10 7a1 1 0 100-2 1 1 0 000 2z","clip-rule":"evenodd"},null,-1),Po=[Oo],Bo={key:3,class:"h-5 w-5 text-green-400",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true"},Ro=s("path",{"fill-rule":"evenodd",d:"M10 18a8 8 0 100-16 8 8 0 000 16zm3.857-9.809a.75.75 0 00-1.214-.882l-3.483 4.79-1.88-1.88a.75.75 0 10-1.06 1.061l2.5 2.5a.75.75 0 001.137-.089l4-5.5z","clip-rule":"evenodd"},null,-1),Eo=[Ro],Ho=ce({__name:"Alert",props:{type:{default:"warn"},hideIcon:{type:Boolean}},setup(l){const e=l,n=f(()=>"info"==e.type?"bg-blue-50 dark:bg-blue-200":"error"==e.type?"bg-red-50 dark:bg-red-200":"success"==e.type?"bg-green-50 dark:bg-green-200":"bg-yellow-50 dark:bg-yellow-200"),r=f(()=>"info"==e.type?"border-blue-400":"error"==e.type?"border-red-400":"success"==e.type?"border-green-400":"border-yellow-400"),i=f(()=>"info"==e.type?"text-blue-700":"error"==e.type?"text-red-700":"success"==e.type?"text-green-700":"text-yellow-700");return(e,t)=>(a(),u("div",{class:w([o(n),o(r),"border-l-4 p-4"])},[s("div",Vo,[l.hideIcon?k("",!0):(a(),u("div",So,["warn"==l.type?(a(),u("svg",Mo,To)):"error"==l.type?(a(),u("svg",Fo,Do)):"info"==l.type?(a(),u("svg",jo,Po)):"success"==l.type?(a(),u("svg",Bo,Eo)):k("",!0)])),s("div",null,[s("p",{class:w([o(i),"text-sm"])},[Z(e.$slots,"default")],2)])])],2))}}),zo={key:0,class:"rounded-md bg-green-50 dark:bg-green-200 p-4",role:"alert"},No={class:"flex"},Uo=s("div",{class:"flex-shrink-0"},[s("svg",{class:"h-5 w-5 text-green-400 dark:text-green-500",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},[s("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M5 13l4 4L19 7"})])],-1),qo={class:"ml-3"},Qo={class:"text-sm font-medium text-green-800"},Ko={key:0},Zo={class:"ml-auto pl-3"},Go={class:"-mx-1.5 -my-1.5"},Wo=s("span",{class:"sr-only"},"Dismiss",-1),Jo=s("svg",{class:"h-5 w-5",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true"},[s("path",{d:"M6.28 5.22a.75.75 0 00-1.06 1.06L8.94 10l-3.72 3.72a.75.75 0 101.06 1.06L10 11.06l3.72 3.72a.75.75 0 101.06-1.06L11.06 10l3.72-3.72a.75.75 0 00-1.06-1.06L10 8.94 6.28 5.22z"})],-1),Xo=[Wo,Jo],Yo=ce({__name:"AlertSuccess",props:{message:null},setup(l){const n=A(!1);return(e,t)=>n.value?k("",!0):(a(),u("div",zo,[s("div",No,[Uo,s("div",qo,[s("h3",Qo,[l.message?(a(),u("span",Ko,T(l.message),1)):Z(e.$slots,"default",{key:1})])]),s("div",Zo,[s("div",Go,[s("button",{type:"button",class:"inline-flex rounded-md bg-green-50 dark:bg-green-200 p-1.5 text-green-500 dark:text-green-600 hover:bg-green-100 dark:hover:bg-green-700 dark:hover:text-white focus:outline-none focus:ring-2 focus:ring-green-600 focus:ring-offset-2 focus:ring-offset-green-50 dark:ring-offset-green-200",onClick:t[0]||(t[0]=e=>n.value=!0)},Xo)])])])]))}}),ea={class:"flex"},ta=s("div",{class:"flex-shrink-0"},[s("svg",{class:"h-5 w-5 text-red-400",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},[s("path",{fill:"currentColor",d:"M12 2c5.53 0 10 4.47 10 10s-4.47 10-10 10S2 17.53 2 12S6.47 2 12 2m3.59 5L12 10.59L8.41 7L7 8.41L10.59 12L7 15.59L8.41 17L12 13.41L15.59 17L17 15.59L13.41 12L17 8.41L15.59 7Z"})])],-1),la={class:"ml-3"},na={class:"text-sm text-red-700 dark:text-red-200"},sa=ce({__name:"ErrorSummary",props:{status:null,except:null,class:null},setup(e){const t=e;let l=Ne("ApiState",void 0);const n=f(()=>t.status||null!=l&&l.error.value?uo.call({responseStatus:t.status??(null==l?void 0:l.error.value)},t.except??[]):null);return(e,t)=>o(n)?(a(),u("div",{key:0,class:w("bg-red-50 dark:bg-red-900 border-l-4 border-red-400 p-4 "+e.$props.class)},[s("div",ea,[ta,s("div",la,[s("p",na,T(o(n)),1)])])],2)):k("",!0)}}),oa=["id","aria-describedby"],aa=ce({__name:"InputDescription",props:{id:null,description:null},setup(l){return(e,t)=>l.description?(a(),u("div",{key:"description",class:"mt-2 text-sm text-gray-500",id:l.id+"-description","aria-describedby":l.id+"-description"},[s("div",null,T(l.description),1)],8,oa)):k("",!0)}});function $l(e){return Xn(e).replace(/\//g,"-")}function ls(e){return null==e?"":co(e)}function ns(e,t){e.value=null,xt(()=>e.value=t)}function Tt(l){return Object.keys(l).forEach(e=>{var t=l[e];l[e]=Gn(t)?o(t):t}),l}function Ct(e,t,l){l?(t.value=e.entering.cls+" "+e.entering.from,setTimeout(()=>t.value=e.entering.cls+" "+e.entering.to,0)):(t.value=e.leaving.cls+" "+e.leaving.from,setTimeout(()=>t.value=e.leaving.cls+" "+e.leaving.to,0))}function cl(l){if(!("u"0":"<"+e+Ul(l)+`>${t||""}`}function Ul(l){return Object.keys(l).reduce((e,t)=>`${e} ${t}="${Hl(l[t])}"`,"")}function Cl(e){return Object.assign({target:"_blank",rel:"noopener",class:"text-blue-600"},e)}function Dt(e){return kn(e)}let ia=["string","number","boolean","null","undefined"];function _t(e){return 0<=ia.indexOf(typeof e)||e instanceof Date}function Zt(e){return!_t(e)}class ss{get length(){return"u"",";"].some(e=>t.includes(e)))throw new Error(`Unsafe script: '${t}'`);e=Object.assign(Object.keys(globalThis).reduce((e,t)=>(e[t]=void 0,e),{}),e);return new Function("with(this) { return ("+t+") }").call(e)}function ql(e){typeof navigator<"u"&&navigator.clipboard.writeText(e)}function on(e){e=ne.config.storage.getItem(e);return e?JSON.parse(e):null}function _l(e,t){return Kt("swr."+mo(e),t?Object.assign({},e,t):e)}function ra(e){e.request&&(e=_l(e.request,e.args),ne.config.storage.removeItem(e))}async function os(e,t,l,a,s){var n=_l(t,a),e=(l(new Je({response:on(n)})),await e.api(t,a,s));return e.succeeded&&e.response&&(e.response._date=(new Date).valueOf(),t=JSON.stringify(e.response),ne.config.storage.setItem(n,t),l(e)),e}function as(t,l){let a=null;return(...e)=>{a&&clearTimeout(a),a=setTimeout(()=>{t(...e)},l||100)}}function pt(e){return"string"==typeof e?e.split(","):e||[]}function wt(e,t){const l=pt(t);return e.reduce((e,t)=>(e[t]=!l.includes(t),e),{})}function is(){return{LocalStore:ss,dateInputFormat:$l,timeInputFormat:ls,setRef:ns,unRefs:Tt,transition:Ct,focusNextElement:cl,getTypeName:Et,htmlTag:rt,htmlAttrs:Ul,linkAttrs:Cl,toAppUrl:Dt,isPrimitive:_t,isComplexType:Zt,pushState:nn,scopedExpr:sn,copyText:ql,fromCache:on,swrCacheKey:_l,swrClear:ra,swrApi:os,asStrings:pt,asOptions:wt,createDebounce:as}}const rs="png,jpg,jpeg,jfif,gif,svg,webp".split(","),us={img:"png,jpg,jpeg,gif,svg,webp,png,jpg,jpeg,gif,bmp,tif,tiff,webp,ai,psd,ps".split(","),vid:"avi,m4v,mov,mp4,mpg,mpeg,wmv,webm".split(","),aud:"mp3,mpa,ogg,wav,wma,mid,webm".split(","),ppt:"key,odp,pps,ppt,pptx".split(","),xls:"xls,xlsm,xlsx,ods,csv,tsv".split(","),doc:"doc,docx,pdf,rtf,tex,txt,md,rst,xls,xlsm,xlsx,ods,key,odp,pps,ppt,pptx".split(","),zip:"zip,tar,gz,7z,rar,gzip,deflate,br,iso,dmg,z,lz,lz4,lzh,s7z,apl,arg,jar,war".split(","),exe:"exe,bat,sh,cmd,com,app,msi,run,vb,vbs,js,ws,wsh".split(","),att:"bin,oct,dat".split(",")},qn=Object.keys(us),ft=(e,t)=>``,fl={img:ft("4 4 16 16",""),vid:ft("0 0 24 24",""),aud:ft("0 0 24 24",""),ppt:ft("0 0 48 48",""),xls:ft("0 0 256 256",""),doc:ft("0 0 32 32",""),zip:ft("0 0 16 16",""),exe:ft("0 0 16 16",""),att:ft("0 0 24 24","")},ua=/[\r\n%#()<>?[\\\]^`{|}]/g,Qn=1024,da=["Bytes","KB","MB","GB","TB"],ca=(()=>{const t="application/",e=t+"vnd.openxmlformats-officedocument.",l="image/",a="text/",s="video/",n={jpg:l+"jpeg",tif:l+"tiff",svg:l+"svg+xml",ico:l+"x-icon",ts:a+"typescript",py:a+"x-python",sh:a+"x-sh",mp3:"audio/mpeg3",mpg:s+"mpeg",ogv:s+"ogg",xlsx:e+"spreadsheetml.sheet",xltx:e+"spreadsheetml.template",docx:e+"wordprocessingml.document",dotx:e+"wordprocessingml.template",pptx:e+"presentationml.presentation",potx:e+"presentationml.template",ppsx:e+"presentationml.slideshow",mdb:t+"vnd.ms-access"};function o(e,t){e.split(",").forEach(e=>n[e]=t)}function r(e,t){e.split(",").forEach(e=>n[e]=t(e))}return r("jpeg,gif,png,tiff,bmp,webp",e=>l+e),r("jsx,csv,css",e=>a+e),r("aac,ac3,aiff,m4a,m4b,m4p,mid,midi,wav",e=>"audio/"+e),r("3gpp,avi,dv,divx,ogg,mp4,webm",e=>s+e),r("rtf,pdf",e=>t+e),o("htm,html,shtm",a+"html"),o("js,mjs,cjs",a+"javascript"),o("yml,yaml",t+"yaml"),o("bat,cmd",t+"bat"),o("xml,csproj,fsproj,vbproj",a+"xml"),o("txt,ps1",a+"plain"),o("qt,mov",s+"quicktime"),o("doc,dot",t+"msword"),o("xls,xlt,xla",t+"excel"),o("ppt,oit,pps,ppa",t+"vnd.ms-powerpoint"),o("cer,crt,der",t+"x-x509-ca-cert"),o("gz,tgz,zip,rar,lzh,z",t+"x-compressed"),o("aaf,aca,asd,bin,cab,chm,class,cur,db,dat,deploy,dll,dsp,exe,fla,ics,inf,mix,msi,mso,obj,ocx,prm,prx,psd,psp,qxd,sea,snp,so,sqlite,toc,ttf,u32,xmp,xsn,xtp",t+"octet-stream"),n})();let Ql=[];function ds(e){return(e=(e=(e=e.replace(/"/g,"'")).replace(/>\s+<")).replace(/\s{2,}/g," ")).replace(ua,encodeURIComponent)}function an(e){return"data:image/svg+xml;utf8,"+ds(e)}function cs(e){e=URL.createObjectURL(e);return Ql.push(e),e}function fs(){Ql.forEach(e=>{try{URL.revokeObjectURL(e)}catch(e){console.error("URL.revokeObjectURL",e)}}),Ql=[]}function rn(e){return e?(e=xl(e,"?"),$t(e,"/")):null}function Yt(e){e=rn(e);return null==e||-1===e.indexOf(".")?null:$t(e,".").toLowerCase()}function un(e){var t=Yt(e.name);return t&&0<=rs.indexOf(t)?cs(e):yt(e.name)}function dn(e){return e&&(!(!e.startsWith("blob:")&&!e.startsWith("data:"))||(e=Yt(e))&&0<=rs.indexOf(e))||!1}function yt(e){var t;return e?null==(t=Yt(e))||dn(e)?e:Qt(t)||an(fl.doc):null}function Qt(e){e=ms(e);return e&&an(e)||null}function ms(t){if(fl[t])return fl[t];for(let e=0;e({fileName:e.name,contentLength:e.size,filePath:un(e)}))}function Ll(e,t){e.onerror=null,e.src=fn(e.src,t)||""}function fn(e,t){return Qt($t(e,".").toLowerCase())||(t?Qt(t)||t:null)||Qt("doc")}function Kl(e){if(e)return e=$t(e,".").toLowerCase(),ca[e]||"application/"+e;throw new Error("fileNameOrExt required")}function Ch(){return{extSvg:ms,extSrc:Qt,getExt:Yt,encodeSvg:ds,canPreview:dn,getFileName:rn,getMimeType:Kl,formatBytes:cn,filePathUri:yt,svgToDataUri:an,fileImageUri:un,objectUrl:cs,flush:fs,inputFiles:fa,iconOnError:Ll,iconFallbackSrc:fn}}class ma{constructor(e){Ce(this,"view"),Ce(this,"includeTypes"),Object.assign(this,e)}getTypeName(){return"MetadataApp"}getMethod(){return"GET"}createResponse(){return{}}}const Ot="/metadata/app.json",va={Boolean:"checkbox",DateTime:"date",DateOnly:"date",DateTimeOffset:"date",TimeSpan:"time",TimeOnly:"time",Byte:"number",Short:"number",Int64:"number",Int32:"number",UInt16:"number",UInt32:"number",UInt64:"number",Single:"number",Double:"number",Decimal:"number",String:"text",Guid:"text",Uri:"text"},ha={number:"Int32",checkbox:"Boolean",date:"DateTime","datetime-local":"DateTime",time:"TimeSpan"},Zl={Byte:"byte",Int16:"short",Int32:"int",Int64:"long",UInt16:"ushort",Unt32:"uint",UInt64:"ulong",Single:"float",Double:"double",Decimal:"decimal"},ga=([...Object.keys(Zl),...Object.values(Zl)],{String:"string",Boolean:"bool",...Zl});function rl(e){return ga[e]||e}function vs(e,t){return e?(t=t||[],"Nullable`1"===e?rl(t[0])+"?":e.endsWith("[]")?`List<${rl(e.substring(0,e.length-2))}>`:0===t.length?rl(e):xl(rl(e),"`")+"<"+t.join(",")+">"):""}function pa(e){return e&&vs(e.name,e.genericArgs)}class Pt{constructor(){Ce(this,"Query"),Ce(this,"QueryInto"),Ce(this,"Create"),Ce(this,"Update"),Ce(this,"Patch"),Ce(this,"Delete")}get AnyQuery(){return this.Query||this.QueryInto}get AnyUpdate(){return this.Patch||this.Update}toArray(){return[this.Query,this.QueryInto,this.Create,this.Update,this.Patch,this.Delete].filter(e=>!!e).map(e=>e)}get empty(){return!(this.Query||this.QueryInto||this.Create||this.Update||this.Patch||this.Delete)}add(e){ze.isQueryInto(e)&&!this.QueryInto?this.QueryInto=e:ze.isQuery(e)&&!this.Query?this.Query=e:ze.isCreate(e)&&!this.Create?this.Create=e:ze.isUpdate(e)&&!this.Update?this.Update=e:ze.isPatch(e)&&!this.Patch?this.Patch=e:ze.isDelete(e)&&!this.Delete&&(this.Delete=e)}static from(e){const t=new Pt;return e.forEach(e=>{t.add(e)}),t}static forType(l,e){var t;let a=new Pt;return l&&(null!=(e=e??(null==(t=ne.metadata.value)?void 0:t.api))&&e.operations.forEach(e=>{var t;(null==(t=e.dataModel)?void 0:t.name)==l&&a.add(e)})),a}}const ze={Create:"ICreateDb`1",Update:"IUpdateDb`1",Patch:"IPatchDb`1",Delete:"IDeleteDb`1",AnyRead:["QueryDb`1","QueryDb`2"],AnyWrite:["ICreateDb`1","IUpdateDb`1","IPatchDb`1","IDeleteDb`1"],isAnyQuery:e=>qe(e.request.inherits,e=>0<=ze.AnyRead.indexOf(e.name)),isQuery:e=>qe(e.request.inherits,e=>"QueryDb`1"===e.name),isQueryInto:e=>qe(e.request.inherits,e=>"QueryDb`2"===e.name),isCrud:e=>{return null==(e=e.request.implements)?void 0:e.some(e=>0<=ze.AnyWrite.indexOf(e.name))},isCreate:e=>ul(e,ze.Create),isUpdate:e=>ul(e,ze.Update),isPatch:e=>ul(e,ze.Patch),isDelete:e=>ul(e,ze.Delete),model:e=>{var t;return e?qe(e.inherits,e=>0<=ze.AnyRead.indexOf(e.name))?null==(t=e.inherits)?void 0:t.genericArgs[0]:null==(e=null==(t=e.implements)?void 0:t.find(e=>0<=ze.AnyWrite.indexOf(e.name)))?void 0:e.genericArgs[0]:null}};function ya(e){var t;return(null==(t=e.input)?void 0:t.type)||Vl(mn(e))}function hs(e){return e.endsWith("?")?go(e,1):e}function Vl(e){return va[hs(e)]}function ba(e){return e&&ha[e]||"String"}function mn(e){return"Nullable`1"===e.type?e.genericArgs[0]:e.type}function Gl(e){return e&&"number"==Vl(e)||!1}function gs(e){return e&&"string"==e.toLowerCase()||!1}function wa(e){return"List`1"==e||e.startsWith("List<")||e.endsWith("[]")}function ps(e){var t;return!(null==e||!e.type||(t=mn(e),e.isValueType&&-1==t.indexOf("`"))||e.isEnum||null!=Vl(e.type))}function ys(e){var t;return!!(null!=e&&e.type&&(t=mn(e),e.isValueType&&-1==t.indexOf("`")||e.isEnum||"hidden"==(null==(t=e.input)?void 0:t.type)||"file"==(null==(t=e.input)?void 0:t.type)||"tag"==(null==(t=e.input)?void 0:t.type)||"combobox"==(null==(t=e.input)?void 0:t.type)||null!=Vl(e.type)))}function Gt(e,t){let l="string"==typeof e?Sl(e):e,a=(l||(console.warn("Metadata not found for: "+e),l={request:{name:e}}),function(e){Object.assign(this,e)}),s=(n.prototype.createResponse=function(){return l.returnsVoid?void 0:new a},n.prototype.getTypeName=function(){return l.request.name},n.prototype.getMethod=function(){return l.method||"POST"},n);function n(e){Object.assign(this,e)}return new s(t)}function xa(e,t,l={}){let a=function(e){Object.assign(this,e)},s=(n.prototype.createResponse=function(){return"function"==typeof l.createResponse?l.createResponse():new a},n.prototype.getTypeName=function(){return e},n.prototype.getMethod=function(){return l.method||"POST"},n);function n(e){Object.assign(this,e)}return new s(t)}function ml(l,e){return l?(Object.keys(l).forEach(e=>{var t=l[e];"string"==typeof t?t.startsWith("/Date")&&(l[e]=$l(Vt(t))):null!=t&&"object"==typeof t&&(Array.isArray(t)?l[e]=Array.from(t):l[e]=Object.assign({},t))}),l):{}}function ka(e,r){let i={};return Array.from(e.elements).forEach(a=>{var s;if(a.id&&null!=a.value&&""!==a.value){const n=a.id.toLowerCase(),o=r&&r.find(e=>e.name.toLowerCase()==n);let e=null==o?void 0:o.type,t=null==(s=null==o?void 0:o.genericArgs)?void 0:s[0],l="checkbox"===a.type?a.checked:a.value;Gl(e)?l=Number(l):"List`1"===e&&"string"==typeof l&&(l=l.split(",").map(e=>Gl(t)?Number(e):e)),i[a.id]=l}}),i}function vn(e){var t;return(null==(t=null==e?void 0:e.api)?void 0:t.operations)&&0e)?!1:a)){if((t||l)&&(await Kn(t||Ot,l),null!=ne.metadata.value))return;var s=Ne("client");if(null!=s&&(e=await s.api(new ma)).succeeded&&Wt(e.response),null!=ne.metadata.value)return;await Kn(Ot)}return ne.metadata.value}function ot(t,l){var e,a=null==(a=ne.metadata.value)?void 0:a.api;return a&&t?a.types.find(e=>e.name.toLowerCase()===t.toLowerCase()&&(!l||e.namespace==l))||((e=Sl(t))?e.request:(e=a.operations.find(e=>e.response&&e.response.name.toLowerCase()===t.toLowerCase()&&(!l||e.response.namespace==l)))?e.response:null):null}function Sl(t){var e=null==(e=ne.metadata.value)?void 0:e.api;return e?e.operations.find(e=>e.request.name.toLowerCase()===t.toLowerCase()):null}function La({dataModel:e}){var t=null==(t=ne.metadata.value)?void 0:t.api;if(!t)return[];let l=t.operations;if(e){const a="string"==typeof e?ot(e):e;l=l.filter(e=>bs(e.dataModel,a))}return l}function gn(e){return e?ot(e.name,e.namespace):null}function bs(e,t){return e&&t&&e.name===t.name&&(!e.namespace||!t.namespace||e.namespace===t.namespace)}function Va(e,t){e=ot(e);return e&&e.properties&&e.properties.find(e=>e.name.toLowerCase()===t.toLowerCase())}function ws(e){return xs(ot(e))}function xs(t){if(t&&t.isEnum&&null!=t.enumNames){var l={};for(let e=0;el.push({key:e,value:t[e]})),l}}function Sa(e,t){a=e.name,l=(null==t?void 0:t.type)||ya(e)||"text";var l,a=Object.assign({id:a,name:a,type:l},t);return e.isEnum&&(a.type="select",a.allowableEntries=pn(ks(e))),a}function Ma(e){let n=[];if(e){const o=et(e),t=Sl(e.name),r=gn(null==t?void 0:t.dataModel);o.forEach(t=>{var e;if(ys(t)){const l=Sa(t,t.input);if(l.id=ho(l.id),"file"==l.type&&t.uploadTo&&!l.accept&&(e=null==(e=null==(e=ne.metadata.value)?void 0:e.plugins.filesUpload)?void 0:e.locations.find(e=>e.name==t.uploadTo))&&!l.accept&&e.allowExtensions&&(l.accept=e.allowExtensions.map(e=>e.startsWith(".")?e:"."+e).join(",")),r&&(e=null==(e=r.properties)?void 0:e.find(e=>e.name==t.name),t.ref||(t.ref=null==e?void 0:e.ref)),l.options)try{const a={input:l,$typeFields:o.map(e=>e.name),$dataModelFields:r?et(r).map(e=>e.name):[],...ne.config.scopeWhitelist},s=sn(l.options,a);Object.keys(s).forEach(e=>{l[e]=s[e]})}catch{console.error(`failed to evaluate '${l.options}'`)}n.push(l)}})}return n}function yn(t,e){if(!e.type)return console.error("enumDescriptions missing {type:'EnumType'} options"),[""+t];var l=ot(e.type);if(null==l||!l.enumValues)return console.error("Could not find metadata for "+e.type),[""+t];var a=[];for(let e=0;e"number"==typeof e?yn(e,{type:t}):e}function et(e){if(!e)return[];let t=[],l={};for(;e;)e.properties&&e.properties.forEach(e=>{l[e.name]||(l[e.name]=1,t.push(e))}),e=e.inherits?gn(e.inherits):null;return t.map(e=>e.type.endsWith("[]")?{...e,type:"List`1",genericArgs:[e.type.substring(0,e.type.length-2)]}:e)}function ul(e,t){return(null==(e=e.request.implements)?void 0:e.some(e=>e.name===t))||!1}function el(e){return e?Cs(e,et(e)):null}function Cs(e,t){var l=t.find(e=>"id"===e.name.toLowerCase());if(l&&l.isPrimaryKey)return l;t=t.find(e=>e.isPrimaryKey)||l;if(!t){l=ze.model(e);if(l)return qe(ot(l),e=>el(e));console.error("Primary Key not found in "+e.name)}return t||null}function Aa(e,t){return qe(el(e),e=>ye(t,e.name))}function _s(e,t,l){return e&&"none"===e.valueType?"":"%In"===l.key||"%Between"===l.key?`(${l.value})`:Ta(t,l.value)}function Ta(e,t){return!e||Gl(e=hs(e))||"Boolean"===e?t:wa(e)?`[${t}]`:`'${t}'`}function at(){var e=f(()=>{var e;return(null==(e=ne.metadata.value)?void 0:e.app)||null}),t=f(()=>{var e;return(null==(e=ne.metadata.value)?void 0:e.api)||null}),l=f(()=>{var e;return(null==(e=ne.metadata.value)?void 0:e.plugins.autoQuery.viewerConventions)||[]});return hn(),{loadMetadata:_a,getMetadata:$a,setMetadata:Wt,clearMetadata:Ca,metadataApp:e,metadataApi:t,filterDefinitions:l,typeOf:ot,typeOfRef:gn,typeEquals:bs,apiOf:Sl,findApis:La,typeName:pa,typeName2:vs,property:Va,enumOptions:ws,propertyOptions:ks,createFormLayout:Ma,typeProperties:et,supportsProp:ys,Crud:ze,Apis:Pt,getPrimaryKey:el,getPrimaryKeyByProps:Cs,getId:Aa,createDto:Gt,makeDto:xa,toFormValues:ml,formValues:ka,isComplexProp:ps,asKvps:pn,expandEnumFlags:yn,enumFlagsConverter:$s}}const Xe=class Xe{static async getOrFetchValue(e,t,l,a,s,n,o){return Xe.getValue(l,o,s)??(await Xe.fetchLookupIds(e,t,l,a,s,n,[o]),Xe.getValue(l,o,s))}static getValue(e,t,l){e=Xe.Lookup[e];if(e){e=e[t];if(e)return e[l=l.toLowerCase()]}}static setValue(e,t,l,a){e=Xe.Lookup[e]??(Xe.Lookup[e]={});(e[t]??(e[t]={}))[l=l.toLowerCase()]=a}static setRefValue(e,t){var l=ye(t,e.refId);return null==l||null==e.refLabel?null:(t=ye(t,e.refLabel),Xe.setValue(e.model,l,e.refLabel,t),t)}static async fetchLookupIds(e,t,l,a,s,n,o){t=t.operations.find(e=>{return ze.isAnyQuery(e)&&(null==(e=e.dataModel)?void 0:e.name)==l});if(t){const r=Xe.Lookup[l]??(Xe.Lookup[l]={}),i=[];Object.keys(r).forEach(e=>{var t=r[e];ye(t,s)&&i.push(e)});var o=o.filter(e=>!i.includes(e));0!=o.length&&(n=n?null:a+","+s,o={[a+"In"]:o.join(",")},n&&(o.fields=n),n=Gt(t,o),(o=await e.api(n,{jsconfig:"edv,eccn"})).succeeded?(ye(o.response,"results")||[]).forEach(e=>{var t,l;ye(e,a)?(t=""+ye(e,a),l=ye(e,s),s=s.toLowerCase(),(r[t]??(r[t]={}))[s]=""+l):console.error(`result[${a}] == null`,e)}):console.error("Failed to call "+t.request.name))}}};Ce(Xe,"Lookup",{});let Ft=Xe,Wl=()=>(new Date).getTime(),Fa=["/","T",":","-"],ut={assumeUtc:!0,date:{method:"Intl.DateTimeFormat",options:"{dateStyle:'medium'}"},maxFieldLength:150,maxNestedFields:2,maxNestedFieldLength:30},Ia=new Intl.RelativeTimeFormat(ut.locale,{}),Zn=31536e6,Rl={year:Zn,month:Zn/12,day:864e5,hour:36e5,minute:6e4,second:1e3},bt={currency:Vs,bytes:Ss,link:Ms,linkTel:As,linkMailTo:Ts,icon:Fs,iconRounded:Is,attachment:Ds,hidden:js,time:Os,relativeTime:wn,relativeTimeFromMs:Ml,enumFlags:Bs,formatDate:Ht,formatNumber:bn};"iconOnError"in globalThis||(globalThis.iconOnError=Ll);class Ke{}function Da(e){ut=Object.assign({},ut,e)}function ja(t){Object.keys(t||{}).forEach(e=>{"function"==typeof t[e]&&(bt[e]=t[e])})}function Ls(){return bt}function tl(e,t){return t?rt("span",e,t):e}function Vs(e,t){var l=dt(t,["currency"]);return tl(new Intl.NumberFormat(void 0,{style:"currency",currency:(null==t?void 0:t.currency)||"USD"}).format(e),l)}function Ss(e,t){return tl(cn(e),t)}function Ms(e,t){return rt("a",e,Cl({...t,href:e}))}function As(e,t){return rt("a",e,Cl({...t,href:"tel:"+e}))}function Ts(e,t){var{subject:l,body:a}=t=t||{},t=dt(t,["subject","body"]),s={};return l&&(s.subject=l),a&&(s.body=a),rt("a",e,Cl({...t,href:"mailto:"+Kt(e,s)}))}function Fs(e,t){return rt("img",void 0,Object.assign({class:"w-6 h-6",title:e,src:Dt(e),onerror:"iconOnError(this)"},t))}function Is(e,t){return rt("img",void 0,Object.assign({class:"w-8 h-8 rounded-full",title:e,src:Dt(e),onerror:"iconOnError(this)"},t))}function Ds(e,t){var l=rn(e),a=(null==Yt(l)||dn(e)?Dt:fn)(e),a=Dt(a),s=t&&(t["icon-class"]||t.iconClass),a=rt("img",void 0,Object.assign({class:"w-6 h-6",src:a,onerror:"iconOnError(this,'att')"},s?{class:s}:null));return rt("a",a+`${l}`,Object.assign({class:"flex",href:Dt(e),title:e},t?dt(t,["icon-class","iconClass"]):null))}function js(e){return""}function Os(e,t){var l="string"==typeof e?new Date(1e3*Yn(e)):kl(e)?Vt(e):null;return tl(l?po(l):e,t)}function Ht(e,t){var l,a;return null==e?"":(l="number"==typeof e?new Date(e):"string"==typeof e?Vt(e):e,kl(l)?tl(("function"==typeof(a=ut.date?Al(ut.date):null)?a:Xn)(l),t):(console.warn(l+" is not a Date value"),null==e?"":""+e))}function bn(e,t){if("number"!=typeof e)return e;let l=ut.number?Al(ut.number):null,a="function"==typeof l?l(e):""+e;return""===a&&(console.warn(`formatNumber(${e}) => `+a,l),a=""+e),tl(a,t)}function Ps(t,l,a){var e=yo(t),s=l?Al(l):null;if("function"!=typeof s)return(null!=e?kl(e)?Ht(e,a):"number"==typeof e?bn(e,a):e:null)??"";{let e=a;if(null!=l&&l.options)try{e=sn(l.options,a)}catch(e){console.error(`Could not evaluate '${l.options}'`,e,", with scope:",a)}return s(t,e)}}function Jt(e,t,l){return(_t(e)?Ps:Ea)(e,t,l)}function Oa(e){if(null!=e){if("number"==typeof e)return e;if(kl(e))return e.getTime()-Wl();if("string"==typeof e){var t=Number(e);if(!isNaN(t))return t;if("P"===e[0]||e.startsWith("-P"))return 1e3*Yn(e)*-1;if(0<=bo(e,Fa))return Vt(e).getTime()-Wl()}}return NaN}function Ml(e,t){for(var l in Rl)if(Math.abs(e)>Rl[l]||"second"===l)return(t||Ia).format(Math.round(e/Rl[l]),l)}function wn(e,t){e=Oa(e);return isNaN(e)?"":Ml(e,t)}function Pa(e,t){return Ml(e.getTime()-(t?t.getTime():Wl()))}function Bs(e,t){return yn(e,t).join(", ")}function Al(l){if(l){let{method:e,options:a}=l,s=e+`(${a})`,n=bt[s]||bt[e];if("function"==typeof n)return n;let o=l.locale||ut.locale;if(e.startsWith("Intl.")){l=o?`'${o}'`:"undefined",l=`return new ${e}(${l},${a||"undefined"})`;try{let t=Function(l)();return n="Intl.DateTimeFormat"===e?e=>t.format(Vt(e)):"Intl.NumberFormat"===e?e=>t.format(Number(e)):"Intl.RelativeTimeFormat"===e?e=>wn(e,t):e=>t.format(e),bt[s]=n}catch(e){console.error("Invalid format: "+l,e)}}else{let l=globalThis[e];if("function"==typeof l){let t=null!=a?Function("return "+a)():void 0;return n=e=>l(e,t,o),bt[s]=n}console.error(`No '${e}' function exists`,Object.keys(bt))}}return null}function Rs(e,t){return e?e.length>t?e.substring(0,t)+"...":e:""}function Es(e){return"/Date("===e.substring(0,6)?Ht(Vt(e)):e}function Ba(e){return xn(Bt(e)).replace(/"/g,"")}function Hs(e){if(null==e||""===e)return"";if("string"==typeof e)try{return JSON.parse(e)}catch{console.warn("couldn't parse as JSON",e)}return e}function xn(e,t=4){return"object"!=typeof(e=Hs(e))?"string"==typeof e?e:""+e:JSON.stringify(e,void 0,t)}function Ra(e){return"object"!=typeof(e=Hs(e))?"string"==typeof e?e:""+e:xn(e=Bt(e=Object.assign({},e)))}function Bt(l){if(null==l)return null;if("string"==typeof l)return Es(l);if(_t(l))return l;if(l instanceof Date)return Ht(l);if(Array.isArray(l))return l.map(Bt);if("object"!=typeof l)return l;{let t={};return Object.keys(l).forEach(e=>{"__type"!=e&&(t[e]=Bt(l[e]))}),t}}function Ea(e,t,l){let a=e;if(Array.isArray(e)){if(_t(e[0]))return a.join(",");null!=e[0]&&(a=e[0])}if(null==a)return"";if(a instanceof Date)return Ht(a,l);var s=Object.keys(a),n=[];for(let e=0;e${o}: `+Hl(Rs(Es(r),ut.maxNestedFieldLength)))}return 2t.value.navigate(e.to??"/");return(e,t)=>(a(),u("a",Me({onClick:Ue(s,["prevent"]),title:l.to,href:"javascript:void(0)"},e.$attrs),[Z(e.$slots,"default")],16,Ha))}});class Na{constructor(){Ce(this,"callbacks",{})}register(e,t){this.callbacks[e]=t}has(e){return!!this.callbacks[e]}invoke(e,t){var l=this.callbacks[e];"function"==typeof l&&l(e,t)}}const Ye=class Ye{static component(e){var t=Ye.components[e];if(t)return t;const l=Nn(e),a=Object.keys(Ye.components).find(e=>Nn(e)===l);return a&&Ye.components[a]||null}};Ce(Ye,"config",{redirectSignIn:"/signin",redirectSignOut:"/auth/logout",navigate:e=>location.href=e,assetsPathResolver:e=>e,fallbackPathResolver:e=>e,storage:new ss,tableIcon:{svg:""},scopeWhitelist:{enumFlagsConverter:$s,...Ls()}}),Ce(Ye,"autoQueryGridDefaults",{deny:[],hide:[],toolbarButtonClass:void 0,tableStyle:"stripedRows",take:25,maxFieldLength:150}),Ce(Ye,"events",wo()),Ce(Ye,"user",A(null)),Ce(Ye,"metadata",A(null)),Ce(Ye,"components",{RouterLink:za}),Ce(Ye,"interceptors",new Na);let ne=Ye;function Ua(e){ne.config=Object.assign(ne.config,e)}function qa(e){ne.autoQueryGridDefaults=Object.assign(ne.autoQueryGridDefaults,e)}function kn(e){return e&&ne.config.assetsPathResolver?ne.config.assetsPathResolver(e):e}function Qa(e){return e&&ne.config.fallbackPathResolver?ne.config.fallbackPathResolver(e):e}function Ka(e,t){ne.interceptors.register(e,t)}function St(){var e=f(()=>ne.config),t=f(()=>ne.autoQueryGridDefaults);return{config:e,setConfig:Ua,events:ne.events,autoQueryGridDefaults:t,setAutoQueryGridDefaults:qa,assetsPathResolver:kn,fallbackPathResolver:Qa,registerInterceptor:Ka}}const zs=ce({inheritAttrs:!1,props:{image:Object,svg:String,src:String,alt:String,type:String},setup(s,{attrs:n}){return()=>{let e=s.image;var t,l;s.type&&(l=at()["typeOf"],(l=l(s.type))||console.warn(`Type ${s.type} does not exist`),null!=l&&l.icon?e=null==l?void 0:l.icon:console.warn(`Type ${s.type} does not have a [Svg] icon`));let a=s.svg||(null==e?void 0:e.svg)||"";return a.startsWith("").indexOf("class="),t=`${(null==e?void 0:e.cls)||""} `+(n.class||""),a=-1==l?`Ll(e.target)})}}}),Za={class:"text-2xl font-semibold text-gray-900 dark:text-gray-300"},Ga={class:"flex"},Wa=s("path",{d:"M100 50.5908C100 78.2051 77.6142 100.591 50 100.591C22.3858 100.591 0 78.2051 0 50.5908C0 22.9766 22.3858 0.59082 50 0.59082C77.6142 0.59082 100 22.9766 100 50.5908ZM9.08144 50.5908C9.08144 73.1895 27.4013 91.5094 50 91.5094C72.5987 91.5094 90.9186 73.1895 90.9186 50.5908C90.9186 27.9921 72.5987 9.67226 50 9.67226C27.4013 9.67226 9.08144 27.9921 9.08144 50.5908Z",fill:"currentColor"},null,-1),Ja=s("path",{d:"M93.9676 39.0409C96.393 38.4038 97.8624 35.9116 97.0079 33.5539C95.2932 28.8227 92.871 24.3692 89.8167 20.348C85.8452 15.1192 80.8826 10.7238 75.2124 7.41289C69.5422 4.10194 63.2754 1.94025 56.7698 1.05124C51.7666 0.367541 46.6976 0.446843 41.7345 1.27873C39.2613 1.69328 37.813 4.19778 38.4501 6.62326C39.0873 9.04874 41.5694 10.4717 44.0505 10.1071C47.8511 9.54855 51.7191 9.52689 55.5402 10.0491C60.8642 10.7766 65.9928 12.5457 70.6331 15.2552C75.2735 17.9648 79.3347 21.5619 82.5849 25.841C84.9175 28.9121 86.7997 32.2913 88.1811 35.8758C89.083 38.2158 91.5421 39.6781 93.9676 39.0409Z",fill:"currentFill"},null,-1),Xa=[Wa,Ja],Ya=ce({__name:"Loading",props:{imageClass:{default:"w-6 h-6"}},setup(l){return(e,t)=>(a(),u("div",Za,[s("div",Ga,[(a(),u("svg",{class:w(["self-center inline mr-2 text-gray-200 animate-spin dark:text-gray-600 fill-gray-600 dark:fill-gray-300",l.imageClass]),role:"status",viewBox:"0 0 100 101",fill:"none",xmlns:"http://www.w3.org/2000/svg"},Xa,2)),s("span",null,[Z(e.$slots,"default")])])]))}}),ei=["href","onClick"],ti=["type"],li=ce({__name:"OutlineButton",props:{type:{default:"submit"},href:null},setup(n){const o="inline-flex items-center px-4 py-2 border border-gray-300 dark:border-gray-600 shadow-sm text-sm font-medium rounded-md text-gray-700 dark:text-gray-200 disabled:text-gray-400 bg-white dark:bg-black hover:bg-gray-50 hover:dark:bg-gray-900 disabled:hover:bg-white dark:disabled:hover:bg-black focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500 dark:ring-offset-black";return(t,e)=>{var l=X("router-link");return n.href?(a(),se(l,{key:0,to:n.href},{default:ke(({navigate:e})=>[s("button",{class:w(o),href:n.href,onClick:e},[Z(t.$slots,"default")],8,ei)]),_:3},8,["to"])):(a(),u("button",Me({key:1,type:n.type,class:o},t.$attrs),[Z(t.$slots,"default")],16,ti))}}}),ni=["href","onClick"],si=["type"],oi=ce({__name:"PrimaryButton",props:{type:{default:"submit"},href:null,color:{default:"indigo"}},setup(n){const e=n,t={blue:"text-white bg-blue-600 hover:bg-blue-700 disabled:bg-blue-400 disabled:hover:bg-blue-400 focus:ring-indigo-500 dark:bg-blue-600 dark:hover:bg-blue-700 dark:focus:ring-blue-800",purple:"text-white bg-purple-600 hover:bg-purple-700 disabled:bg-purple-400 disabled:hover:bg-purple-400 focus:ring-indigo-500 dark:bg-blue-600 dark:hover:bg-blue-700 dark:focus:ring-blue-800",red:"focus:ring-red-500 text-white bg-red-600 hover:bg-red-700 disabled:bg-red-400 disabled:hover:bg-red-400 focus:ring-red-500 dark:bg-red-600 dark:hover:bg-red-700 dark:focus:ring-red-500",green:"focus:ring-green-300 text-white bg-green-600 hover:bg-green-700 disabled:bg-green-400 disabled:hover:bg-green-400 focus:ring-green-500 dark:bg-green-600 dark:hover:bg-green-700 dark:focus:ring-green-500",sky:"focus:ring-sky-300 text-white bg-sky-600 hover:bg-sky-700 disabled:bg-sky-400 disabled:hover:bg-sky-400 focus:ring-sky-500 dark:bg-sky-600 dark:hover:bg-sky-700 dark:focus:ring-sky-500",cyan:"focus:ring-cyan-300 text-white bg-cyan-600 hover:bg-cyan-700 disabled:bg-cyan-400 disabled:hover:bg-cyan-400 focus:ring-cyan-500 dark:bg-cyan-600 dark:hover:bg-cyan-700 dark:focus:ring-cyan-500",indigo:"focus:ring-2 focus:ring-offset-2 text-white bg-indigo-600 hover:bg-indigo-700 disabled:bg-indigo-400 disabled:hover:bg-indigo-400 focus:ring-indigo-500 dark:bg-blue-600 dark:hover:bg-blue-700 dark:focus:ring-blue-800"},r=f(()=>"inline-flex justify-center rounded-md border border-transparent py-2 px-4 text-sm font-medium shadow-sm focus:outline-none focus:ring-2 focus:ring-offset-2 dark:ring-offset-black "+(t[e.color]||t.indigo));return(t,e)=>{var l=X("router-link");return n.href?(a(),se(l,{key:0,to:n.href},{default:ke(({navigate:e})=>[s("button",{class:w(o(r)),href:n.href,onClick:e},[Z(t.$slots,"default")],10,ni)]),_:3},8,["to"])):(a(),u("button",Me({key:1,type:n.type,class:o(r)},t.$attrs),[Z(t.$slots,"default")],16,si))}}}),ai=["type","href","onClick"],ii=["type"],ri=ce({__name:"SecondaryButton",props:{type:null,href:null},setup(n){const o="inline-flex justify-center rounded-md border border-gray-300 py-2 px-4 text-sm font-medium shadow-sm focus:outline-none focus:ring-2 focus:ring-offset-2 bg-white dark:bg-gray-800 border-gray-300 dark:border-gray-600 text-gray-700 dark:text-gray-400 dark:hover:text-white hover:bg-gray-50 dark:hover:bg-gray-700 focus:ring-indigo-500 dark:focus:ring-indigo-600 dark:ring-offset-black";return(t,e)=>{var l=X("router-link");return n.href?(a(),se(l,{key:0,to:n.href},{default:ke(({navigate:e})=>[s("button",{type:n.type??"button",class:w(o),href:n.href,onClick:e},[Z(t.$slots,"default")],8,ai)]),_:3},8,["to"])):(a(),u("button",Me({key:1,type:n.type??"button",class:o},t.$attrs),[Z(t.$slots,"default")],16,ii))}}});function We(e,t){return Array.isArray(e)?0<=e.indexOf(t):e==t||e.includes(t)}const bl={blue:"text-blue-600 dark:text-blue-400 hover:text-blue-800 dark:hover:text-blue-200",purple:"text-purple-600 dark:text-purple-400 hover:text-purple-800 dark:hover:text-purple-200",red:"text-red-700 dark:text-red-400 hover:text-red-900 dark:hover:text-red-200",green:"text-green-600 dark:text-green-400 hover:text-green-800 dark:hover:text-green-200",sky:"text-sky-600 dark:text-sky-400 hover:text-sky-800 dark:hover:text-sky-200",cyan:"text-cyan-600 dark:text-cyan-400 hover:text-cyan-800 dark:hover:text-cyan-200",indigo:"text-indigo-600 dark:text-indigo-400 hover:text-indigo-800 dark:hover:text-indigo-200"},nt={base:"block w-full sm:text-sm rounded-md dark:text-white dark:bg-gray-900 disabled:bg-slate-50 disabled:text-slate-500 disabled:border-slate-200 disabled:shadow-none",invalid:"pr-10 border-red-300 text-red-900 placeholder-red-300 focus:outline-none focus:ring-red-500 focus:border-red-500",valid:"shadow-sm focus:ring-indigo-500 focus:border-indigo-500 border-gray-300 dark:border-gray-600"},qt={panelClass:"shadow sm:rounded-md",formClass:"space-y-6 bg-white dark:bg-black py-6 px-4 sm:p-6",headingClass:"text-lg font-medium leading-6 text-gray-900 dark:text-gray-100",subHeadingClass:"mt-1 text-sm text-gray-500 dark:text-gray-400"},It={panelClass:"pointer-events-auto w-screen xl:max-w-3xl md:max-w-xl max-w-lg",formClass:"flex h-full flex-col divide-y divide-gray-200 dark:divide-gray-700 shadow-xl bg-white dark:bg-black",titlebarClass:"bg-gray-50 dark:bg-gray-900 px-4 py-6 sm:px-6",headingClass:"text-lg font-medium text-gray-900 dark:text-gray-100",subHeadingClass:"mt-1 text-sm text-gray-500 dark:text-gray-400",closeButtonClass:"rounded-md bg-gray-50 dark:bg-gray-900 text-gray-400 dark:text-gray-500 hover:text-gray-500 dark:hover:text-gray-400 focus:outline-none focus:ring-2 focus:ring-indigo-500 dark:ring-offset-black"},Jl={modalClass:"relative transform overflow-hidden rounded-lg bg-white dark:bg-black text-left shadow-xl transition-all sm:my-8",sizeClass:"sm:max-w-prose lg:max-w-screen-md xl:max-w-screen-lg 2xl:max-w-screen-xl sm:w-full"},Ze={panelClass(e="slideOver"){return("card"==e?qt:It).panelClass},formClass(e="slideOver"){return("card"==e?qt:It).formClass},headingClass(e="slideOver"){return("card"==e?qt:It).headingClass},subHeadingClass(e="slideOver"){return("card"==e?qt:It).subHeadingClass},buttonsClass:"mt-4 px-4 py-3 bg-gray-50 dark:bg-gray-900 sm:px-6 flex flex-wrap justify-between",legendClass:"text-base font-medium text-gray-900 dark:text-gray-100 text-center mb-4"},ge={getGridClass(e=0){return ge.gridClass},getGrid2Class(e="stripedRows"){return We(e,"fullWidth")?"overflow-x-auto":ge.grid2Class},getGrid3Class(e="stripedRows"){return We(e,"fullWidth")?"inline-block min-w-full py-2 align-middle":ge.grid3Class},getGrid4Class(e="stripedRows"){return We(e,"whiteBackground")?"":We(e,"fullWidth")?"overflow-hidden shadow-sm ring-1 ring-black ring-opacity-5":ge.grid4Class},getTableClass(e="stripedRows"){return We(e,"fullWidth")||We(e,"verticalLines")?"min-w-full divide-y divide-gray-300":ge.tableClass},getTheadClass(e="stripedRows"){return We(e,"whiteBackground")?"":ge.theadClass},getTheadRowClass(e="stripedRows"){return ge.theadRowClass+(We(e,"verticalLines")?" divide-x divide-gray-200 dark:divide-gray-700":"")},getTheadCellClass(e="stripedRows"){return ge.theadCellClass+(We(e,"uppercaseHeadings")?" uppercase":"")},getTbodyClass(e="stripedRows"){return(We(e,"whiteBackground")||We(e,"verticalLines")?"divide-y divide-gray-200 dark:divide-gray-800":ge.tableClass)+(We(e,"verticalLines")?" bg-white":"")},getTableRowClass(e="stripedRows",t,l,a){return(a?"cursor-pointer ":"")+(l?"bg-indigo-100 dark:bg-blue-800":(a?"hover:bg-yellow-50 dark:hover:bg-blue-900 ":"")+(!We(e,"stripedRows")||t%2==0?"bg-white dark:bg-black":"bg-gray-50 dark:bg-gray-800"))+(We(e,"verticalLines")?" divide-x divide-gray-200 dark:divide-gray-700":"")},gridClass:"flex flex-col",grid2Class:"",grid3Class:"inline-block min-w-full py-2 align-middle",grid4Class:"overflow-hidden shadow ring-1 ring-black ring-opacity-5 md:rounded-lg",tableClass:"min-w-full divide-y divide-gray-200 dark:divide-gray-700",theadClass:"bg-gray-50 dark:bg-gray-900",tableCellClass:"px-6 py-4 whitespace-nowrap text-sm text-gray-500 dark:text-gray-400",theadRowClass:"select-none",theadCellClass:"px-6 py-4 text-left text-sm font-medium tracking-wider whitespace-nowrap",toolbarButtonClass:"inline-flex items-center px-2.5 py-1.5 border border-gray-300 dark:border-gray-700 shadow-sm text-sm font-medium rounded text-gray-700 dark:text-gray-300 bg-white dark:bg-black hover:bg-gray-50 dark:hover:bg-gray-900 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500 dark:ring-offset-black"},ui={colspans:"col-span-3 sm:col-span-3"},Lh=Object.freeze(Object.defineProperty({__proto__:null,a:bl,card:qt,dummy:ui,form:Ze,grid:ge,input:nt,modal:Jl,slideOver:It},Symbol.toStringTag,{value:"Module"})),di=ce({__name:"TextLink",props:{color:{default:"blue"}},setup(e){const t=e,l=so(),s=f(()=>(bl[t.color]||bl.blue)+(l.href?"":" cursor-pointer"));return(e,t)=>(a(),u("a",{class:w(o(s))},[Z(e.$slots,"default")],2))}}),ci={class:"flex","aria-label":"Breadcrumb"},fi={role:"list",class:"flex items-center space-x-4"},mi=["href","title"],vi=s("svg",{class:"h-6 w-6 flex-shrink-0",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true"},[s("path",{"fill-rule":"evenodd",d:"M9.293 2.293a1 1 0 011.414 0l7 7A1 1 0 0117 11h-1v6a1 1 0 01-1 1h-2a1 1 0 01-1-1v-3a1 1 0 00-1-1H9a1 1 0 00-1 1v3a1 1 0 01-1 1H5a1 1 0 01-1-1v-6H3a1 1 0 01-.707-1.707l7-7z","clip-rule":"evenodd"})],-1),hi={class:"sr-only"},gi=ce({__name:"Breadcrumbs",props:{homeHref:{default:"/"},homeLabel:{default:"Home"}},setup(l){return(e,t)=>(a(),u("nav",ci,[s("ol",fi,[s("li",null,[s("div",null,[s("a",{href:l.homeHref,class:"text-gray-400 dark:text-gray-500 hover:text-gray-500 dark:hover:text-gray-400",title:l.homeLabel},[vi,s("span",hi,T(l.homeLabel),1)],8,mi)])]),Z(e.$slots,"default")])]))}}),pi={class:"flex items-center"},yi=s("svg",{class:"h-6 w-6 flex-shrink-0 text-gray-400 dark:text-gray-500",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true"},[s("path",{"fill-rule":"evenodd",d:"M7.21 14.77a.75.75 0 01.02-1.06L11.168 10 7.23 6.29a.75.75 0 111.04-1.08l4.5 4.25a.75.75 0 010 1.08l-4.5 4.25a.75.75 0 01-1.06-.02z","clip-rule":"evenodd"})],-1),bi=["href","title"],wi=["title"],xi=ce({__name:"Breadcrumb",props:{href:null,title:null},setup(l){return(e,t)=>(a(),u("li",null,[s("div",pi,[yi,l.href?(a(),u("a",{key:0,href:l.href,class:"ml-4 text-lg font-medium text-gray-500 dark:text-gray-400 hover:text-gray-700 dark:hover:text-gray-300",title:l.title},[Z(e.$slots,"default")],8,bi)):(a(),u("span",{key:1,class:"ml-4 text-lg font-medium text-gray-700 dark:text-gray-300",title:l.title},[Z(e.$slots,"default")],8,wi))])]))}}),ki={key:0,class:"text-base font-semibold text-gray-500 dark:text-gray-400"},$i={role:"list",class:"mt-4 divide-y divide-gray-200 dark:divide-gray-800 border-t border-b border-gray-200 dark:border-gray-800"},Ci=ce({__name:"NavList",props:{title:null},setup(l){return(e,t)=>(a(),u("div",null,[l.title?(a(),u("h2",ki,T(l.title),1)):k("",!0),s("ul",$i,[Z(e.$slots,"default")])]))}}),_i={class:"relative flex items-start space-x-4 py-6"},Li={class:"flex-shrink-0"},Vi={class:"flex h-12 w-12 items-center justify-center rounded-lg bg-indigo-50 dark:bg-indigo-900"},Si={class:"min-w-0 flex-1"},Mi={class:"text-base font-medium text-gray-900 dark:text-gray-100"},Ai={class:"rounded-sm focus-within:ring-2 focus-within:ring-indigo-500 focus-within:ring-offset-2"},Ti=["href"],Fi=s("span",{class:"absolute inset-0","aria-hidden":"true"},null,-1),Ii={class:"text-base text-gray-500"},Di=s("div",{class:"flex-shrink-0 self-center"},[s("svg",{class:"h-5 w-5 text-gray-400",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true"},[s("path",{"fill-rule":"evenodd",d:"M7.21 14.77a.75.75 0 01.02-1.06L11.168 10 7.23 6.29a.75.75 0 111.04-1.08l4.5 4.25a.75.75 0 010 1.08l-4.5 4.25a.75.75 0 01-1.06-.02z","clip-rule":"evenodd"})])],-1),ji=ce({__name:"NavListItem",props:{title:null,href:null,icon:null,iconSvg:null,iconSrc:null,iconAlt:null},setup(n){return(e,t)=>{var l=X("Icon");return a(),u("li",_i,[s("div",Li,[s("span",Vi,[$e(l,{class:"w-6 h-6 text-indigo-700 dark:text-indigo-300",image:n.icon,src:n.iconSrc,svg:n.iconSvg,alt:n.iconAlt},null,8,["image","src","svg","alt"])])]),s("div",Si,[s("h3",Mi,[s("span",Ai,[s("a",{href:n.href,class:"focus:outline-none"},[Fi,we(" "+T(n.title),1)],8,Ti)])]),s("p",Ii,[Z(e.$slots,"default")])]),Di])}}});function Ns(e){return e&&e.SessionId?xo(e):e}function Oi(e){ne.user.value=Ns(e),ne.events.publish("signIn",e)}function Pi(){ne.user.value=null,ne.events.publish("signOut",null)}const $n=e=>e.roles||[],Cn=e=>e.permissions||[];function Us(e){return 0<=$n(ne.user.value).indexOf(e)}function Bi(e){return 0<=Cn(ne.user.value).indexOf(e)}function _n(){return Us("Admin")}function vl(e){if(!e)return!1;if(!e.requiresAuth)return!0;var t=ne.user.value;if(!t)return!1;if(_n())return!0;let[l,a]=[$n(t),Cn(t)],[s,n,o,r]=[e.requiredRoles||[],e.requiredPermissions||[],e.requiresAnyRole||[],e.requiresAnyPermission||[]];return!(!s.every(e=>0<=l.indexOf(e))||00<=l.indexOf(e))||!n.every(e=>0<=a.indexOf(e))||00<=a.indexOf(e)))}function Ri(e){if(!e||!e.requiresAuth)return null;var t=ne.user.value;if(!t)return`${e.request.name} requires Authentication`;if(_n())return null;let[l,a]=[$n(t),Cn(t)],[s,n,o,r]=[e.requiredRoles||[],e.requiredPermissions||[],e.requiresAnyRole||[],e.requiresAnyPermission||[]],i=s.filter(e=>l.indexOf(e)<0);return 0""+e+"").join(", ")} Role`+(1a.indexOf(e)<0)).length?`Requires ${t.map(e=>""+e+"").join(", ")} Permission`+(10<=l.indexOf(e))?`Requires any ${o.filter(e=>l.indexOf(e)<0).map(e=>""+e+"").join(", ")} Role`+(10<=a.indexOf(e))?`Requires any ${r.filter(e=>a.indexOf(e)<0).map(e=>""+e+"").join(", ")} Permission`+(1ne.user.value||null),toAuth:Ns,isAuthenticated:f(()=>null!=ne.user.value),hasRole:Us,hasPermission:Bi,isAdmin:_n,canAccess:vl,invalidAccessMessage:Ri}}const Ei={key:0},Hi={class:"md:p-4"},qs=ce({__name:"EnsureAccess",props:{invalidAccess:null,alertClass:null},emits:["done"],setup(r){const i=Ln()["isAuthenticated"],t=St()["config"],d=()=>{var e=location.href.substring(location.origin.length)||"/",e=Kt(t.value.redirectSignIn,{redirect:e});t.value.navigate(e)},c=()=>{var e=location.href.substring(location.origin.length)||"/",e=Kt(t.value.redirectSignOut,{ReturnUrl:e});t.value.navigate(e)};return(e,t)=>{var l=X("Alert"),n=X("SecondaryButton");return r.invalidAccess?(a(),u("div",Ei,[$e(l,{class:w(r.alertClass),innerHTML:r.invalidAccess},null,8,["class","innerHTML"]),s("div",Hi,[o(i)?(a(),se(n,{key:1,onClick:c},{default:ke(()=>[we("Sign Out")]),_:1})):(a(),se(n,{key:0,onClick:d},{default:ke(()=>[we("Sign In")]),_:1}))])])):k("",!0)}}}),zi={class:"absolute top-0 right-0 bg-white dark:bg-black border dark:border-gray-800 rounded normal-case text-sm shadow w-80"},Ni={class:"p-4"},Ui=s("h3",{class:"text-base font-medium mb-3 dark:text-gray-100"},"Sort",-1),qi={class:"flex w-full justify-center"},Qi=s("svg",{class:"w-6 h-6",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 16 16"},[s("g",{fill:"currentColor"},[s("path",{"fill-rule":"evenodd",d:"M10.082 5.629L9.664 7H8.598l1.789-5.332h1.234L13.402 7h-1.12l-.419-1.371h-1.781zm1.57-.785L11 2.687h-.047l-.652 2.157h1.351z"}),s("path",{d:"M12.96 14H9.028v-.691l2.579-3.72v-.054H9.098v-.867h3.785v.691l-2.567 3.72v.054h2.645V14zm-8.46-.5a.5.5 0 0 1-1 0V3.707L2.354 4.854a.5.5 0 1 1-.708-.708l2-1.999l.007-.007a.498.498 0 0 1 .7.006l2 2a.5.5 0 1 1-.707.708L4.5 3.707V13.5z"})])],-1),Ki=s("span",null,"ASC",-1),Zi=[Qi,Ki],Gi=wl('DESC',2),Wi=[Gi],Ji=s("h3",{class:"text-base font-medium mt-4 mb-2"}," Filter ",-1),Xi={key:0},Yi=["id","value"],er=["for"],tr={key:1},lr={class:"mb-2"},nr={class:"inline-flex rounded-full items-center py-0.5 pl-2.5 pr-1 text-sm font-medium bg-indigo-100 text-indigo-700"},sr=["onClick"],or=s("svg",{class:"h-2 w-2",stroke:"currentColor",fill:"none",viewBox:"0 0 8 8"},[s("path",{"stroke-linecap":"round","stroke-width":"1.5",d:"M1 1l6 6m0-6L1 7"})],-1),ar=[or],ir={class:"flex"},rr=s("svg",{class:"h-6 w-6",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true"},[s("path",{"fill-rule":"evenodd",d:"M10 5a1 1 0 011 1v3h3a1 1 0 110 2h-3v3a1 1 0 11-2 0v-3H6a1 1 0 110-2h3V6a1 1 0 011-1z","clip-rule":"evenodd"})],-1),ur=[rr],dr={class:"bg-gray-50 dark:bg-gray-900 px-4 py-3 sm:px-6 sm:flex sm:flex-row-reverse"},Vn=ce({__name:"FilterColumn",props:{definitions:null,column:null,topLeft:null},emits:["done","save"],setup(d,{emit:l}){const c=d,v=A(),p=A(""),m=A(""),g=A([]),y=f(()=>1==c.column.meta.isEnum),n=f(()=>ot("Nullable`1"===c.column.meta.type?c.column.meta.genericArgs[0]:c.column.meta.type)),h=f(()=>1==c.column.meta.isEnum?pn(ws(n.value.name)):[]),b=f(()=>{var e;return(null==(e=r(c.column.type))?void 0:e.map(e=>({key:e.value,value:e.name})))||[]}),x=A({filters:[]}),C=f(()=>x.value.filters);function r(e){let t=c.definitions;return t=gs(e)?t:t.filter(e=>"string"!==e.types)}function L(e,t){return r(e).find(e=>e.value===t)}function V(){var e;p.value&&(e=null==(e=L(c.column.type,p.value))?void 0:e.name)&&(x.value.filters.push({key:p.value,name:e,value:m.value}),p.value=m.value="")}function M(){l("done")}function S(){var e;p.value="%",null!=(e=v.value)&&e.focus()}function I(){var e,t;m.value&&V(),y.value&&(t=Object.values(g.value).filter(e=>e),x.value.filters=0parseInt(e)).reduce((e,t)=>e+t,0).toString()}]:[{key:"%In",name:"In",value:t.join(",")}]:[]),l("save",x.value),l("done")}function $(e){x.value.sort=e===x.value.sort?void 0:e,xt(I)}return hl(()=>x.value=Object.assign({},c.column.settings,{filters:Array.from(c.column.settings.filters)})),hl(()=>{var e;let t=(null==(e=null==(e=null==(e=c.column.settings.filters)?void 0:e[0])?void 0:e.value)?void 0:e.split(","))||[];if(00<(l&parseInt(e))))||[]}g.value=t}),(e,t)=>{var l=X("SelectInput"),n=X("TextInput"),r=X("PrimaryButton"),i=X("SecondaryButton");return a(),u("div",{class:"fixed z-20 inset-0 overflow-y-auto",onClick:M,onVnodeMounted:S},[s("div",{class:"absolute",style:Xl(`top:${d.topLeft.y}px;left:${d.topLeft.x}px`),onClick:t[5]||(t[5]=Ue(()=>{},["stop"]))},[s("div",zi,[s("div",Ni,[Ui,s("div",qi,[s("button",{type:"button",title:"Sort Ascending",onClick:t[0]||(t[0]=e=>$("ASC")),class:w(`${"ASC"===x.value.sort?"bg-indigo-100 border-indigo-500":"bg-white hover:bg-gray-50 border-gray-300"} mr-1 inline-flex items-center px-2.5 py-1.5 border shadow-sm text-sm font-medium rounded text-gray-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500`)},Zi,2),s("button",{type:"button",title:"Sort Descending",onClick:t[1]||(t[1]=e=>$("DESC")),class:w(`${"DESC"===x.value.sort?"bg-indigo-100 border-indigo-500":"bg-white hover:bg-gray-50 border-gray-300"} ml-1 inline-flex items-center px-2.5 py-1.5 border shadow-sm text-sm font-medium rounded text-gray-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500`)},Wi,2)]),Ji,o(y)?(a(),u("div",Xi,[(a(!0),u(Te,null,Ie(o(h),e=>(a(),u("div",{key:e.key,class:"flex items-center"},[kt(s("input",{type:"checkbox",id:e.key,value:e.key,"onUpdate:modelValue":t[2]||(t[2]=e=>g.value=e),class:"h-4 w-4 border-gray-300 rounded text-indigo-600 focus:ring-indigo-500"},null,8,Yi),[[Yl,g.value]]),s("label",{for:e.key,class:"ml-3"},T(e.value),9,er)]))),128))])):(a(),u("div",tr,[(a(!0),u(Te,null,Ie(o(C),(e,l)=>{return a(),u("div",lr,[s("span",nr,[we(T(d.column.name)+" "+T(e.name)+" "+T((e=e,_s(L(c.column.type,e.key),c.column.type,e)))+" ",1),s("button",{type:"button",onClick:e=>{var t;t=l,x.value.filters.splice(t,1)},class:"flex-shrink-0 ml-0.5 h-4 w-4 rounded-full inline-flex items-center justify-center text-indigo-400 hover:bg-indigo-200 hover:text-indigo-500 focus:outline-none focus:bg-indigo-500 focus:text-white"},ar,8,sr)])])}),256)),s("div",ir,[$e(l,{id:"filterRule",class:"w-32 mr-1",modelValue:p.value,"onUpdate:modelValue":t[3]||(t[3]=e=>p.value=e),entries:o(b),label:"",placeholder:""},null,8,["modelValue","entries"]),"none"!==(null==(l=L(d.column.type,p.value))?void 0:l.valueType)?(a(),se(n,{key:0,ref_key:"txtFilter",ref:v,id:"filterValue",class:"w-32 mr-1",type:"text",modelValue:m.value,"onUpdate:modelValue":t[4]||(t[4]=e=>m.value=e),onKeyup:Wn(V,["enter"]),label:"",placeholder:""},null,8,["modelValue","onKeyup"])):k("",!0),s("div",{class:"pt-1"},[s("button",{type:"button",onClick:V,class:"inline-flex items-center p-1 border border-transparent rounded-full shadow-sm text-white bg-indigo-600 hover:bg-indigo-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500"},ur)])])]))]),s("div",dr,[$e(r,{onClick:I,color:"red",class:"ml-2"},{default:ke(()=>[we(" Save ")]),_:1}),$e(i,{onClick:M},{default:ke(()=>[we(" Cancel ")]),_:1})])])],4)],512)}}}),cr={class:"px-4 sm:px-6 lg:px-8 text-sm"},fr={class:"flex flex-wrap"},mr={class:"group pr-4 sm:pr-6 lg:pr-8"},vr={class:"flex justify-between w-full font-medium"},hr={class:"w-6 flex justify-end"},gr={class:"hidden group-hover:inline"},pr=["onClick","title"],yr=s("svg",{class:"h-2 w-2",stroke:"currentColor",fill:"none",viewBox:"0 0 8 8"},[s("path",{"stroke-linecap":"round","stroke-width":"1.5",d:"M1 1l6 6m0-6L1 7"})],-1),br=[yr],wr={key:0,class:"pt-2"},xr={class:"ml-2"},kr={key:1},$r={class:"pt-2"},Cr={class:"inline-flex rounded-full items-center py-0.5 pl-2.5 pr-1 text-sm font-medium bg-indigo-100 text-indigo-700"},_r=["onClick"],Lr=s("svg",{class:"h-2 w-2",stroke:"currentColor",fill:"none",viewBox:"0 0 8 8"},[s("path",{"stroke-linecap":"round","stroke-width":"1.5",d:"M1 1l6 6m0-6L1 7"})],-1),Vr=[Lr],Sr=s("span",null,"Clear All",-1),Mr=[Sr],Sn=ce({__name:"FilterViews",props:{definitions:null,columns:null},emits:["done","change"],setup(e,{emit:r}){const l=e,n=f(()=>l.columns.filter(e=>0"string"!==e.types)}(e).find(e=>e.value===t)}function d(){l.columns.forEach(e=>{e.settings.filters=[],r("change",e)}),r("done")}return(e,t)=>(a(),u("div",cr,[s("div",fr,[(a(!0),u(Te,null,Ie(o(n),n=>{return a(),u("fieldset",mr,[s("legend",vr,[s("span",null,T(o(He)(n.name)),1),s("span",hr,[s("span",gr,[s("button",{onClick:e=>{var t;(t=n).settings.filters=[],r("change",t)},title:`Clear all ${o(He)(n.name)} filters`,class:"flex-shrink-0 ml-0.5 h-4 w-4 rounded-full inline-flex items-center justify-center text-red-600 hover:bg-red-200 hover:text-red-500 focus:outline-none focus:bg-red-500 focus:text-white"},br,8,pr)])])]),n.meta.isEnum?(a(),u("div",wr,[(a(!0),u(Te,null,Ie(null==(e=null==(e=null==(e=n.settings.filters)?void 0:e[0])?void 0:e.value)?void 0:e.split(","),e=>(a(),u("div",{key:e,class:"flex items-center"},[s("label",xr,T(e),1)]))),128))])):(a(),u("div",kr,[(a(!0),u(Te,null,Ie(n.settings.filters,(e,l)=>{return a(),u("div",$r,[s("span",Cr,[we(T(n.name)+" "+T(e.name)+" "+T((e=e,_s(i((t=n).type,e.value),t.type,e)))+" ",1),s("button",{type:"button",onClick:e=>{var t;(t=n).settings.filters.splice(l,1),r("change",t)},class:"flex-shrink-0 ml-0.5 h-4 w-4 rounded-full inline-flex items-center justify-center text-indigo-400 hover:bg-indigo-200 hover:text-indigo-500 focus:outline-none focus:bg-indigo-500 focus:text-white"},Vr,8,_r)])]);var t}),256))]))]);var e}),256))]),s("div",{class:"flex justify-center pt-4"},[s("button",{type:"button",onClick:d,class:"inline-flex items-center px-2.5 py-1.5 border border-gray-300 shadow-sm text-sm font-medium rounded text-gray-700 bg-white hover:bg-gray-50 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500"},Mr)])]))}}),Ar={class:"bg-white dark:bg-black px-4 pt-5 pb-4 sm:p-6 sm:pb-4"},Tr={class:""},Fr={class:"mt-3 text-center sm:mt-0 sm:mx-4 sm:text-left"},Ir=s("h3",{class:"text-lg leading-6 font-medium text-gray-900 dark:text-gray-100"},"Query Preferences",-1),Dr={class:"mt-4"},jr=["for"],Or=["id"],Pr=["value","selected"],Br={class:"mt-4 flex items-center py-4 border-b border-gray-200 dark:border-gray-800"},Rr=["id","checked"],Er=["for"],Hr={class:"mt-4"},zr={class:"pb-2 px-4"},Nr={class:""},Ur=["id","value"],qr=["for"],Qr={class:"bg-gray-50 dark:bg-gray-900 px-4 py-3 sm:px-6 sm:flex sm:flex-row-reverse"},Mn=ce({__name:"QueryPrefs",props:{id:{default:"QueryPrefs"},columns:null,prefs:null,maxLimit:null},emits:["done","save"],setup(r,{emit:e}){const i=r,t=St()["autoQueryGridDefaults"],d=A({}),c=(hl(()=>d.value=Object.assign({take:t.value.take,selectedColumns:[]},i.prefs)),[10,25,50,100,250,500,1e3]);function v(){e("done")}function f(){e("save",d.value)}return(e,t)=>{const l=X("PrimaryButton"),n=X("SecondaryButton"),o=X("ModalDialog");return a(),se(o,{id:r.id,onDone:v,"size-class":"w-full sm:max-w-prose"},{default:ke(()=>[s("div",Ar,[s("div",Tr,[s("div",Fr,[Ir,s("div",Dr,[s("label",{for:r.id+"-take",class:"block text-sm font-medium text-gray-700 dark:text-gray-300"},"Results per page",8,jr),kt(s("select",{id:r.id+"-take","onUpdate:modelValue":t[0]||(t[0]=e=>d.value.take=e),class:"mt-1 block w-full pl-3 pr-10 py-2 text-base bg-white dark:bg-black border-gray-300 dark:border-gray-700 focus:outline-none focus:ring-indigo-500 focus:border-indigo-500 sm:text-sm rounded-md"},[(a(!0),u(Te,null,Ie(c.filter(e=>null==i.maxLimit||e<=i.maxLimit),e=>(a(),u("option",{value:e,selected:e===d.value.take},T(e),9,Pr))),256))],8,Or),[[oo,d.value.take]])]),s("div",Br,[s("input",{type:"radio",id:r.id+"-allColumns",onClick:t[1]||(t[1]=e=>d.value.selectedColumns=[]),checked:0===d.value.selectedColumns.length,class:"focus:ring-indigo-500 h-4 w-4 bg-white dark:bg-black text-indigo-600 dark:text-indigo-400 border-gray-300 dark:border-gray-700"},null,8,Rr),s("label",{class:"ml-3 block text-gray-700 dark:text-gray-300",for:r.id+"-allColumns"},"View all columns",8,Er)]),s("div",Hr,[s("div",zr,[s("div",Nr,[(a(!0),u(Te,null,Ie(r.columns,e=>(a(),u("div",{key:e.name,class:"flex items-center"},[kt(s("input",{type:"checkbox",id:e.name,value:e.name,"onUpdate:modelValue":t[2]||(t[2]=e=>d.value.selectedColumns=e),class:"h-4 w-4 bg-white dark:bg-black border-gray-300 dark:border-gray-700 rounded text-indigo-600 dark:text-indigo-400 focus:ring-indigo-500"},null,8,Ur),[[Yl,d.value.selectedColumns]]),s("label",{for:e.name,class:"ml-3"},T(e.name),9,qr)]))),128))])])])])])]),s("div",Qr,[$e(l,{onClick:f,color:"red",class:"ml-2"},{default:ke(()=>[we(" Save ")]),_:1}),$e(n,{onClick:v},{default:ke(()=>[we(" Cancel ")]),_:1})])]),_:1},8,["id"])}}}),Kr={key:0},Zr={key:1},Gr={key:2,class:"pt-1"},Wr={key:0},Jr={key:1},Xr={key:3},Yr={class:"pl-1 pt-1 flex flex-wrap"},eu={class:"flex mt-1"},tu=["title"],lu=s("svg",{class:"w-8 h-8",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},[s("g",{"stroke-width":"1.5",fill:"none"},[s("path",{d:"M9 3H3.6a.6.6 0 0 0-.6.6v16.8a.6.6 0 0 0 .6.6H9M9 3v18M9 3h6M9 21h6m0-18h5.4a.6.6 0 0 1 .6.6v16.8a.6.6 0 0 1-.6.6H15m0-18v18",stroke:"currentColor"})])],-1),nu=[lu],su=["disabled"],ou=s("svg",{class:"w-8 h-8",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},[s("path",{d:"M18.41 16.59L13.82 12l4.59-4.59L17 6l-6 6l6 6zM6 6h2v12H6z",fill:"currentColor"})],-1),au=[ou],iu=["disabled"],ru=s("svg",{class:"w-8 h-8",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},[s("path",{d:"M15.41 7.41L14 6l-6 6l6 6l1.41-1.41L10.83 12z",fill:"currentColor"})],-1),uu=[ru],du=["disabled"],cu=s("svg",{class:"w-8 h-8",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},[s("path",{d:"M10 6L8.59 7.41L13.17 12l-4.58 4.59L10 18l6-6z",fill:"currentColor"})],-1),fu=[cu],mu=["disabled"],vu=s("svg",{class:"w-8 h-8",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},[s("path",{d:"M5.59 7.41L10.18 12l-4.59 4.59L7 18l6-6l-6-6zM16 6h2v12h-2z",fill:"currentColor"})],-1),hu=[vu],gu={key:0,class:"flex mt-1"},pu={class:"px-4 text-lg text-black dark:text-white"},yu={key:0},bu={key:1},wu=s("span",{class:"hidden xl:inline"}," Showing Results ",-1),xu={key:2},ku={class:"flex flex-wrap"},$u={key:0,class:"pl-2 mt-1"},Cu=s("svg",{class:"w-5 h-5",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},[s("path",{fill:"none",stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M20 20v-5h-5M4 4v5h5m10.938 2A8.001 8.001 0 0 0 5.07 8m-1.008 5a8.001 8.001 0 0 0 14.868 3"})],-1),_u=[Cu],Lu={key:1,class:"pl-2 mt-1"},Vu=wl('Excel',2),Su=[Vu],Mu={key:2,class:"pl-2 mt-1"},Au={key:0,class:"w-5 h-5 mr-1 text-green-600 dark:text-green-400",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Tu=s("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M5 13l4 4L19 7"},null,-1),Fu=[Tu],Iu={key:1,class:"w-5 h-5 mr-1",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Du=s("g",{fill:"none"},[s("path",{d:"M8 4v12a2 2 0 0 0 2 2h8a2 2 0 0 0 2-2V7.242a2 2 0 0 0-.602-1.43L16.083 2.57A2 2 0 0 0 14.685 2H10a2 2 0 0 0-2 2z",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"}),s("path",{d:"M16 18v2a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V9a2 2 0 0 1 2-2h2",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"})],-1),ju=[Du],Ou=s("span",{class:"whitespace-nowrap"},"Copy URL",-1),Pu={key:3,class:"pl-2 mt-1"},Bu=s("svg",{class:"w-5 h-5",xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true",viewBox:"0 0 24 24"},[s("path",{fill:"currentColor",d:"M6.78 2.72a.75.75 0 0 1 0 1.06L4.56 6h8.69a7.75 7.75 0 1 1-7.75 7.75a.75.75 0 0 1 1.5 0a6.25 6.25 0 1 0 6.25-6.25H4.56l2.22 2.22a.75.75 0 1 1-1.06 1.06l-3.5-3.5a.75.75 0 0 1 0-1.06l3.5-3.5a.75.75 0 0 1 1.06 0Z"})],-1),Ru=[Bu],Eu={key:4,class:"pl-2 mt-1"},Hu=s("svg",{class:"flex-none w-5 h-5 mr-2 text-gray-400 dark:text-gray-500 group-hover:text-gray-500","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor"},[s("path",{"fill-rule":"evenodd",d:"M3 3a1 1 0 011-1h12a1 1 0 011 1v3a1 1 0 01-.293.707L12 11.414V15a1 1 0 01-.293.707l-2 2A1 1 0 018 17v-5.586L3.293 6.707A1 1 0 013 6V3z","clip-rule":"evenodd"})],-1),zu={class:"mr-1"},Nu={key:0,class:"h-5 w-5 text-gray-400 dark:text-gray-500 group-hover:text-gray-500",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true"},Uu=s("path",{"fill-rule":"evenodd",d:"M10 5a1 1 0 011 1v3h3a1 1 0 110 2h-3v3a1 1 0 11-2 0v-3H6a1 1 0 110-2h3V6a1 1 0 011-1z","clip-rule":"evenodd"},null,-1),qu=[Uu],Qu={key:1,class:"h-5 w-5 text-gray-400 dark:text-gray-500 group-hover:text-gray-500",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true"},Ku=s("path",{"fill-rule":"evenodd",d:"M5 10a1 1 0 011-1h8a1 1 0 110 2H6a1 1 0 01-1-1z","clip-rule":"evenodd"},null,-1),Zu=[Ku],Gu={key:5,class:"pl-2 mt-1"},Wu=["title"],Ju=s("svg",{class:"w-5 h-5 mr-1 text-gray-500 dark:text-gray-400 hover:text-gray-900 dark:hover:text-gray-50",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},[s("path",{d:"M19 13h-6v6h-2v-6H5v-2h6V5h2v6h6v2z",fill:"currentColor"})],-1),Xu={class:"whitespace-nowrap"},Yu={key:7},ed={key:0,class:"cursor-pointer flex justify-between items-center hover:text-gray-900 dark:hover:text-gray-50"},td={class:"mr-1 select-none"},ld={key:1,class:"flex justify-between items-center"},nd={class:"mr-1 select-none"},sd=ce({__name:"AutoQueryGrid",props:{filterDefinitions:null,id:{default:"AutoQueryGrid"},apis:null,type:null,prefs:null,deny:null,hide:null,selectedColumns:null,toolbarButtonClass:null,tableStyle:null,gridClass:null,grid2Class:null,grid3Class:null,grid4Class:null,tableClass:null,theadClass:null,tbodyClass:null,theadRowClass:null,theadCellClass:null,headerTitle:null,headerTitles:null,visibleFrom:null,rowClass:null,rowStyle:null,apiPrefs:null,canFilter:null,disableKeyBindings:null,configureField:null,skip:{default:0},create:{type:Boolean},edit:null,filters:null},emits:["headerSelected","rowSelected"],setup(p,{expose:e,emit:v}){const r=p,{config:t,autoQueryGridDefaults:W}=St(),G=W,J=Ne("client"),l=t.value.storage,Y="filtering,queryString,queryFilters".split(","),ee="copyApiUrl,downloadCsv,filtersView,newItem,pagingInfo,pagingNav,preferences,refresh,resetPreferences,toolbar".split(","),te=f(()=>r.deny?wt(Y,r.deny):wt(Y,G.value.deny)),le=f(()=>r.hide?wt(ee,r.hide):wt(ee,G.value.hide));function m(e){return te.value[e]}function g(e){return le.value[e]}const y=f(()=>r.tableStyle??G.value.tableStyle),ae=f(()=>r.gridClass??ge.getGridClass(y.value)),oe=f(()=>r.grid2Class??ge.getGrid2Class(y.value)),re=f(()=>r.grid3Class??ge.getGrid3Class(y.value)),ie=f(()=>r.grid4Class??ge.getGrid4Class(y.value)),ue=f(()=>r.tableClass??ge.getTableClass(y.value)),de=f(()=>r.theadClass??ge.getTheadClass(y.value)),ce=f(()=>r.theadRowClass??ge.getTheadRowClass(y.value)),ve=f(()=>r.theadCellClass??ge.getTheadCellClass(y.value)),h=f(()=>r.toolbarButtonClass??ge.toolbarButtonClass);function fe(e,t){var l,a;return r.rowClass?r.rowClass(e,t):(l=!!q.value.AnyUpdate,a=(null!=(a=i.value)&&a.name?ye(e,i.value.name):null)==S.value,ge.getTableRowClass(r.tableStyle,t,a,l))}const b=en(),pe=f(()=>{var e;return st((null==(e=q.value.AnyQuery.viewModel)?void 0:e.name)||q.value.AnyQuery.dataModel.name)}),me=f(()=>{const t=Object.keys(b).map(e=>e.toLowerCase());return et(pe.value).filter(e=>t.includes(e.name.toLowerCase())||t.includes(e.name.toLowerCase()+"-header")).map(e=>e.name)});const x=f(()=>{var e=(0<(e=pt(r.selectedColumns)).length?e:0e.toLowerCase());const l=et(pe.value);return 0l.find(e=>e.name.toLowerCase()===t)).filter(e=>null!=e):l}),he=f(()=>{let e=x.value.map(e=>e.name),t=pt(O.value.selectedColumns).map(e=>e.toLowerCase());return 0t.includes(e.toLowerCase())):e}),C=A([]),L=A(new Je),be=A(new Je),V=A(),M=A(!1),S=A(),I=A(),$=A(!1),F=A(),B=A(r.skip),j=A(!1),O=A({take:25}),H=A(!1),xe=f(()=>C.value.some(e=>0C.value.map(e=>e.settings.filters.length).reduce((e,t)=>e+t,0)),Le=f(()=>{var e;return et(st(d.value||(null==(e=q.value.AnyQuery)?void 0:e.dataModel.name)))}),i=f(()=>{var e;return el(st(d.value||(null==(e=q.value.AnyQuery)?void 0:e.dataModel.name)))}),D=f(()=>O.value.take??25),E=f(()=>L.value.response?ye(L.value.response,"results"):[]),z=f(()=>{var e;return(null==(e=L.value.response)?void 0:e.total)??E.value.length??0}),Te=f(()=>00E.value.length>=D.value),Me=f(()=>E.value.length>=D.value),_=A(),R=A(),Se={NoQuery:"No Query API was found"};function Fe(t){if(t){if(r.canFilter)return r.canFilter(t);var e=Le.value.find(e=>e.name.toLowerCase()==t.toLowerCase());if(e)return!ps(e)}}function n(e){m("queryString")&&nn(e)}async function N(e){B.value+=e,B.value<0&&(B.value=0);e=Math.floor(z.value/D.value)*D.value;B.value>e&&(B.value=e),n({skip:B.value||void 0}),await P()}async function je(e,t){var l,a;I.value=null,S.value=t,e&&t&&(a=Gt(q.value.AnyQuery,{[e]:t}),(a=await J.api(a)).succeeded)&&((a=null==(a=ye(a.response,"results"))?void 0:a[0])||console.warn(`API ${null==(l=q.value.AnyQuery)?void 0:l.request.name}(${e}:${t}) returned no results`),I.value=a)}async function Oe(e,t){v("rowSelected",e,t);t=null==(t=i.value)?void 0:t.name,e=t?ye(e,t):null;t&&e&&(n({edit:e}),je(t,e))}function He(t,e){var l,a,s;m("filtering")&&(l=e.target,Fe(t)&&"TD"!==(null==l?void 0:l.tagName)&&(l=null==(l=null==l?void 0:l.closest("TABLE"))?void 0:l.getBoundingClientRect(),a=C.value.find(e=>e.name.toLowerCase()==t.toLowerCase()))&&l&&(s=l.x+318+10,F.value={column:a,topLeft:{x:Math.max(Math.floor(e.clientX+159),s),y:l.y+45}}),v("headerSelected",t,e))}function De(){F.value=null}async function Ee(e){var t=null==(t=F.value)?void 0:t.column;t&&(t.settings=e,l.setItem(c(t.name),JSON.stringify(t.settings)),await P()),F.value=null}async function ze(e){l.setItem(c(e.name),JSON.stringify(e.settings)),await P()}async function _e(e){$.value=!1,O.value=e,l.setItem(Ye(),JSON.stringify(e)),await P()}function Re(e){Object.assign(I.value,e),Pe()}function Pe(){null!=(e=_.value)&&e.forceUpdate(),null!=(e=R.value)&&e.forceUpdate();var e=Be();null!=(e=null==e?void 0:e.proxy)&&e.$forceUpdate()}async function P(){await Ue(qe())}async function Ze(){await P()}async function Ue(a){var s=q.value.AnyQuery;if(s){let e=Gt(s,a),t=es(e=>{L.value.response=L.value.error=void 0,H.value=e}),l=await J.api(e);t(),xt(()=>L.value=l);s=ye(l.response,"results")||[];l.succeeded&&s.label}else console.error(Se.NoQuery)}function qe(){let a={include:"total",take:D.value},t=pt(O.value.selectedColumns||r.selectedColumns);if(0{var e,l=s.find(e=>e.name.toLowerCase()==t.toLowerCase());null!=(e=null==l?void 0:l.ref)&&e.selfId&&n.push(l.ref.selfId),ye(b,t)&&n.push(...s.filter(e=>{return(null==(e=null==(e=e.ref)?void 0:e.selfId)?void 0:e.toLowerCase())==t.toLowerCase()}).map(e=>e.name))}),n.forEach(e=>{t.includes(e)||t.push(e)}),a.fields=t.join(",")}let e=[];if(C.value.forEach(l=>{l.settings.sort&&e.push(("DESC"===l.settings.sort?"-":"")+l.name),l.settings.filters.forEach(e=>{var t=e.key.replace("%",l.name);a[t]=e.value})}),r.filters&&Object.keys(r.filters).forEach(e=>{a[e]=r.filters[e]}),m("queryString")&&m("queryFilters")){var l=location.search||(location.hash.includes("?")?"?"+dl(location.hash,"?"):"");let e=zl(l);Object.keys(e).forEach(t=>{x.value.find(e=>e.name.toLowerCase()===t.toLowerCase())&&(a[t]=e[t])}),typeof e.skip<"u"&&(l=parseInt(e.skip),isNaN(l)||(B.value=a.skip=l))}return"u"j.value=!1,3e3)}function Ke(e="json"){var t=qe(),l="/api/"+(null==(l=q.value.AnyQuery)?void 0:l.request.name),l=ko(J.baseUrl,Kt(l,{...t,jsconfig:"edv"}));return 0<=l.indexOf("?")?xl(l,"?")+"."+e+"?"+dl(l,"?"):l+".json"}async function We(){C.value.forEach(e=>{e.settings={filters:[]},l.removeItem(c(e.name))}),O.value={take:25},l.removeItem(Ye()),await P()}function Ge(){M.value=!0,n({create:null})}e({update:P,search:Ue,createRequestArgs:qe,reset:bt,createDone:K,createSave:ht,editDone:Q,editSave:yt,forceUpdate:Pe,setEdit:Re,edit:I}),ne.interceptors.has("AutoQueryGrid.new")&&ne.interceptors.invoke("AutoQueryGrid.new",{props:r});const d=f(()=>Et(r.type)),U=f(()=>{var e;return d.value||(null==(e=q.value.AnyQuery)?void 0:e.dataModel.name)}),Ye=()=>{var e;return r.id+"/ApiPrefs/"+(d.value||(null==(e=q.value.AnyQuery)?void 0:e.dataModel.name))},c=e=>{var t;return`Column/${r.id}:${d.value||(null==(t=q.value.AnyQuery)?void 0:t.dataModel.name)}.`+e},{metadataApi:lt,typeOf:st,apiOf:nt,filterDefinitions:ot}=at(),rt=Ln()["invalidAccessMessage"],it=f(()=>r.filterDefinitions||ot.value),q=f(()=>{var e=pt(r.apis);return 0nt(e)).filter(e=>null!=e).map(e=>e)):Pt.forType(d.value,lt.value)}),ut=e=>`${e}`,dt=f(()=>{var e;return lt.value?0<(e=pt(r.apis).map(e=>null==nt(e)?e:null).filter(e=>null!=e)).length?ut(`Unknown API${1useMetadata()`)}),ct=f(()=>q.value.AnyQuery&&rt(q.value.AnyQuery)),vt=f(()=>q.value.Create&&rt(q.value.Create)),ft=f(()=>q.value.AnyUpdate&&rt(q.value.AnyUpdate)),mt=f(()=>vl(q.value.Create)),gt=(f(()=>vl(q.value.AnyUpdate)),f(()=>vl(q.value.Delete)));function Q(){I.value=null,S.value=null,n({edit:void 0})}function K(){M.value=!1,n({create:void 0})}async function yt(){await P(),Q()}async function ht(){await P(),K()}function bt(){L.value=new Je,be.value=new Je,M.value=!1,S.value=null,I.value=null,$.value=!1,F.value=null,B.value=r.skip,j.value=!1,O.value={take:25},H.value=!1;var e,t=r.prefs||yl(l.getItem(Ye())),t=(t&&(O.value=t),C.value=x.value.map(e=>({name:e.name,type:e.type,meta:e,settings:Object.assign({filters:[]},yl(l.getItem(c(e.name))))})),isNaN(r.skip)||(B.value=r.skip),null==(t=i.value)?void 0:t.name);m("queryString")&&(e=location.search||(location.hash.includes("?")?"?"+dl(location.hash,"?"):""),typeof(e=zl(e)).create<"u"?M.value=typeof e.create<"u":!t||"string"!=typeof e.edit&&"number"!=typeof e.edit||je(t,e.edit)),!0===r.create&&(M.value=!0),t&&null!=r.edit&&je(t,r.edit)}return tt(async()=>{bt(),await P()}),(l,e)=>{const t=X("Alert"),n=X("EnsureAccessDialog"),r=X("AutoCreateForm"),i=X("AutoEditForm"),d=X("ErrorSummary"),c=X("Loading"),v=X("SettingsIcons"),f=X("DataGrid");return o(dt)?(a(),u("div",Kr,[$e(t,{innerHTML:o(dt)},null,8,["innerHTML"])])):o(ct)?(a(),u("div",Zr,[$e(qs,{"invalid-access":o(ct)},null,8,["invalid-access"])])):(a(),u("div",Gr,[M.value&&o(q).Create?(a(),u("div",Wr,[o(vt)?(a(),se(n,{key:0,title:"Create "+o(U),"invalid-access":o(vt),"alert-class":"text-yellow-700",onDone:K},null,8,["title","invalid-access"])):o(b).createform?Z(l.$slots,"createform",{key:1,type:o(q).Create.request.name,configure:p.configureField,done:K,save:ht}):(a(),se(r,{key:2,ref_key:"createForm",ref:_,type:o(q).Create.request.name,configure:p.configureField,onDone:K,onSave:ht},{header:ke(()=>[Z(l.$slots,"formheader",{form:"create",formInstance:_.value,apis:o(q),type:o(U)})]),footer:ke(()=>[Z(l.$slots,"formfooter",{form:"create",formInstance:_.value,apis:o(q),type:o(U)})]),_:3},8,["type","configure"]))])):I.value&&o(q).AnyUpdate?(a(),u("div",Jr,[o(ft)?(a(),se(n,{key:0,title:"Update "+o(U),"invalid-access":o(ft),"alert-class":"text-yellow-700",onDone:Q},null,8,["title","invalid-access"])):o(b).editform?Z(l.$slots,"editform",{key:1,model:I.value,type:o(q).AnyUpdate.request.name,deleteType:o(gt)?o(q).Delete.request.name:null,configure:p.configureField,done:Q,save:yt}):(a(),se(i,{key:2,ref_key:"editForm",ref:R,modelValue:I.value,"onUpdate:modelValue":e[0]||(e[0]=e=>I.value=e),type:o(q).AnyUpdate.request.name,deleteType:o(gt)?o(q).Delete.request.name:null,configure:p.configureField,onDone:Q,onSave:yt,onDelete:yt},{header:ke(()=>[Z(l.$slots,"formheader",{form:"edit",formInstance:R.value,apis:o(q),type:o(U),model:I.value,id:S.value,updateModel:Re})]),footer:ke(()=>[Z(l.$slots,"formfooter",{form:"edit",formInstance:R.value,apis:o(q),type:o(U),model:I.value,id:S.value,updateModel:Re})]),_:3},8,["modelValue","type","deleteType","configure"]))])):k("",!0),o(b).toolbar?Z(l.$slots,"toolbar",{key:2}):g("toolbar")?(a(),u("div",Xr,[$.value?(a(),se(Mn,{key:0,columns:o(x),prefs:O.value,onDone:e[1]||(e[1]=e=>$.value=!1),onSave:_e},null,8,["columns","prefs"])):k("",!0),s("div",Yr,[s("div",eu,[g("preferences")?(a(),u("button",{key:0,type:"button",class:"text-gray-700 dark:text-gray-300 hover:text-indigo-600 dark:hover:text-indigo-400",title:o(U)+" Preferences",onClick:e[2]||(e[2]=e=>$.value=!$.value)},nu,8,tu)):k("",!0),g("pagingNav")?(a(),u("button",{key:1,type:"button",class:w(["pl-2",o(Te)?"text-gray-700 dark:text-gray-300 hover:text-indigo-600 dark:hover:text-indigo-400":"text-gray-400 dark:text-gray-500"]),title:"First page",disabled:!o(Te),onClick:e[3]||(e[3]=e=>N(-o(z)))},au,10,su)):k("",!0),g("pagingNav")?(a(),u("button",{key:2,type:"button",class:w(["pl-2",o(Ae)?"text-gray-700 dark:text-gray-300 hover:text-indigo-600 dark:hover:text-indigo-400":"text-gray-400 dark:text-gray-500"]),title:"Previous page",disabled:!o(Ae),onClick:e[4]||(e[4]=e=>N(-o(D)))},uu,10,iu)):k("",!0),g("pagingNav")?(a(),u("button",{key:3,type:"button",class:w(["pl-2",o(Ve)?"text-gray-700 dark:text-gray-300 hover:text-indigo-600 dark:hover:text-indigo-400":"text-gray-400 dark:text-gray-500"]),title:"Next page",disabled:!o(Ve),onClick:e[5]||(e[5]=e=>N(o(D)))},fu,10,du)):k("",!0),g("pagingNav")?(a(),u("button",{key:4,type:"button",class:w(["pl-2",o(Me)?"text-gray-700 dark:text-gray-300 hover:text-indigo-600 dark:hover:text-indigo-400":"text-gray-400 dark:text-gray-500"]),title:"Last page",disabled:!o(Me),onClick:e[6]||(e[6]=e=>N(o(z)))},hu,10,mu)):k("",!0)]),g("pagingInfo")?(a(),u("div",gu,[s("div",pu,[H.value?(a(),u("span",yu,"Querying...")):k("",!0),o(E).length?(a(),u("span",bu,[wu,we(" "+T(B.value+1)+" - "+T(Math.min(B.value+o(E).length,o(z)))+" ",1),s("span",null," of "+T(o(z)),1)])):L.value.completed?(a(),u("span",xu,"No Results")):k("",!0)])])):k("",!0),s("div",ku,[g("refresh")?(a(),u("div",$u,[s("button",{type:"button",onClick:Ze,title:"Refresh",class:w(o(h))},_u,2)])):k("",!0),g("downloadCsv")?(a(),u("div",Lu,[s("button",{type:"button",onClick:Xe,title:"Download CSV",class:w(o(h))},Su,2)])):k("",!0),g("copyApiUrl")?(a(),u("div",Mu,[s("button",{type:"button",onClick:Qe,title:"Copy API URL",class:w(o(h))},[j.value?(a(),u("svg",Au,Fu)):(a(),u("svg",Iu,ju)),Ou],2)])):k("",!0),o(xe)&&g("resetPreferences")?(a(),u("div",Pu,[s("button",{type:"button",onClick:We,title:"Reset Preferences & Filters",class:w(o(h))},Ru,2)])):k("",!0),g("filtersView")&&0V.value="filters"==V.value?null:"filters"),class:w(o(h)),"aria-expanded":"false"},[Hu,s("span",zu,T(o(Ce))+" "+T(1==o(Ce)?"Filter":"Filters"),1),"filters"!=V.value?(a(),u("svg",Nu,qu)):(a(),u("svg",Qu,Zu))],2)])):k("",!0),g("newItem")&&o(q).Create&&o(mt)?(a(),u("div",Gu,[s("button",{type:"button",onClick:Ge,title:o(U),class:w(o(h))},[Ju,s("span",Xu,"New "+T(o(U)),1)],10,Wu)])):k("",!0),o(b).toolbarbuttons?Z(l.$slots,"toolbarbuttons",{key:6,toolbarButtonClass:o(h)}):k("",!0)])])])):k("",!0),"filters"==V.value?(a(),se(Sn,{key:4,class:"border-y border-gray-200 dark:border-gray-800 py-8 my-2",definitions:o(it),columns:C.value,onDone:e[8]||(e[8]=e=>V.value=null),onChange:ze},null,8,["definitions","columns"])):k("",!0),be.value.error??L.value.error?(a(),se(d,{key:5,status:be.value.error??L.value.error},null,8,["status"])):H.value?(a(),se(c,{key:6,class:"p-2"})):k("",!0),F.value?(a(),u("div",Yu,[$e(Vn,{definitions:o(it),column:F.value.column,"top-left":F.value.topLeft,onDone:De,onSave:Ee},null,8,["definitions","column","top-left"])])):k("",!0),o(E).length?(a(),se(f,{key:8,id:p.id,items:o(E),type:p.type,"selected-columns":o(he),class:"mt-1",onFiltersChanged:P,tableStyle:o(y),gridClass:o(ae),grid2Class:o(oe),grid3Class:o(re),grid4Class:o(ie),tableClass:o(ue),theadClass:o(de),theadRowClass:o(ce),theadCellClass:o(ve),tbodyClass:p.tbodyClass,rowClass:fe,onRowSelected:Oe,rowStyle:p.rowStyle,headerTitle:p.headerTitle,headerTitles:p.headerTitles,visibleFrom:p.visibleFrom,onHeaderSelected:He},tn({header:ke(({column:t,label:e})=>{var l;return[m("filtering")&&Fe(t)?(a(),u("div",ed,[s("span",td,T(e),1),$e(v,{column:C.value.find(e=>e.name.toLowerCase()===t.toLowerCase()),"is-open":(null==(l=F.value)?void 0:l.column.name)===t},null,8,["column","is-open"])])):(a(),u("div",ld,[s("span",nd,T(e),1)]))]}),_:2},[Ie(Object.keys(o(b)),t=>({name:t,fn:ke(e=>[Z(l.$slots,t,jt(gl(e)))])}))]),1032,["id","items","type","selected-columns","tableStyle","gridClass","grid2Class","grid3Class","grid4Class","tableClass","theadClass","theadRowClass","theadCellClass","tbodyClass","rowStyle","headerTitle","headerTitles","visibleFrom"])):k("",!0)]))}}}),od={class:"flex"},ad={key:0,class:"w-4 h-4",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},id=s("g",{fill:"none"},[s("path",{d:"M3 4a1 1 0 0 1 1-1h16a1 1 0 0 1 1 1v2.586a1 1 0 0 1-.293.707l-6.414 6.414a1 1 0 0 0-.293.707V17l-4 4v-6.586a1 1 0 0 0-.293-.707L3.293 7.293A1 1 0 0 1 3 6.586V4z",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"})],-1),rd=[id],ud=s("path",{d:"M505.5 658.7c3.2 4.4 9.7 4.4 12.9 0l178-246c3.8-5.3 0-12.7-6.5-12.7H643c-10.2 0-19.9 4.9-25.9 13.2L512 558.6L406.8 413.2c-6-8.3-15.6-13.2-25.9-13.2H334c-6.5 0-10.3 7.4-6.5 12.7l178 246z",fill:"currentColor"},null,-1),dd=s("path",{d:"M880 112H144c-17.7 0-32 14.3-32 32v736c0 17.7 14.3 32 32 32h736c17.7 0 32-14.3 32-32V144c0-17.7-14.3-32-32-32zm-40 728H184V184h656v656z",fill:"currentColor"},null,-1),cd=[ud,dd],fd={key:2,class:"w-4 h-4",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20"},md=s("g",{fill:"none"},[s("path",{d:"M8.998 4.71L6.354 7.354a.5.5 0 1 1-.708-.707L9.115 3.18A.499.499 0 0 1 9.498 3H9.5a.5.5 0 0 1 .354.147l.01.01l3.49 3.49a.5.5 0 1 1-.707.707l-2.65-2.649V16.5a.5.5 0 0 1-1 0V4.71z",fill:"currentColor"})],-1),vd=[md],hd={key:3,class:"w-4 h-4",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20"},gd=s("g",{fill:"none"},[s("path",{d:"M10.002 15.29l2.645-2.644a.5.5 0 0 1 .707.707L9.886 16.82a.5.5 0 0 1-.384.179h-.001a.5.5 0 0 1-.354-.147l-.01-.01l-3.49-3.49a.5.5 0 1 1 .707-.707l2.648 2.649V3.5a.5.5 0 0 1 1 0v11.79z",fill:"currentColor"})],-1),pd=[gd],yd=ce({__name:"SettingsIcons",props:{column:null,isOpen:{type:Boolean}},setup(s){return(e,t)=>{var l;return a(),u("div",od,[null!=(l=null==(l=null==(l=s.column)?void 0:l.settings)?void 0:l.filters)&&l.length?(a(),u("svg",ad,rd)):(a(),u("svg",{key:1,class:w(["w-4 h-4 transition-transform",s.isOpen?"rotate-180":""]),xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},cd,2)),"ASC"===(null==(l=null==(l=s.column)?void 0:l.settings)?void 0:l.sort)?(a(),u("svg",fd,vd)):"DESC"===(null==(l=null==(l=s.column)?void 0:l.settings)?void 0:l.sort)?(a(),u("svg",hd,pd)):k("",!0)])}}}),bd=ce({__name:"EnsureAccessDialog",props:{title:null,subtitle:null,invalidAccess:null,alertClass:null},emits:["done"],setup(n){return(t,e)=>{const l=X("EnsureAccess"),s=X("SlideOver");return n.invalidAccess?(a(),se(s,{key:0,title:n.title,onDone:e[0]||(e[0]=e=>t.$emit("done")),"content-class":"relative flex-1"},tn({default:ke(()=>[$e(l,{alertClass:n.alertClass,invalidAccess:n.invalidAccess},null,8,["alertClass","invalidAccess"])]),_:2},[n.subtitle?{name:"subtitle",fn:ke(()=>[we(T(n.subtitle),1)]),key:"0"}:void 0]),1032,["title"])):k("",!0)}}}),wd=["for"],xd={class:"mt-1 relative rounded-md shadow-sm"},kd=["type","name","id","placeholder","value","aria-invalid","aria-describedby"],$d={key:0,class:"absolute inset-y-0 right-0 pr-3 flex items-center pointer-events-none"},Cd=s("svg",{class:"h-5 w-5 text-red-500",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true"},[s("path",{"fill-rule":"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7 4a1 1 0 11-2 0 1 1 0 012 0zm-1-9a1 1 0 00-1 1v4a1 1 0 102 0V6a1 1 0 00-1-1z","clip-rule":"evenodd"})],-1),_d=[Cd],Ld=["id"],Vd=["id"],Sd={inheritAttrs:!1},Md=ce({...Sd,__name:"TextInput",props:{status:null,id:null,type:null,inputClass:null,label:null,labelClass:null,help:null,placeholder:null,modelValue:null},setup(l,{expose:e}){const t=l,n=(e({focus:function(){var e;null!=(e=n.value)&&e.focus()}}),A());const r=f(()=>t.type||"text"),i=f(()=>t.label??He(st(t.id))),d=f(()=>t.placeholder??i.value);let c=Ne("ApiState",void 0);const v=f(()=>mt.call({responseStatus:t.status??(null==c?void 0:c.error.value)},t.id)),p=f(()=>[nt.base,v.value?nt.invalid:nt.valid,t.inputClass]);return(t,e)=>(a(),u("div",{class:w([t.$attrs.class])},[Z(t.$slots,"header",Me({inputElement:n.value,id:l.id,modelValue:l.modelValue,status:l.status},t.$attrs)),o(i)?(a(),u("label",{key:0,for:l.id,class:w("block text-sm font-medium text-gray-700 dark:text-gray-300 "+(l.labelClass??""))},T(o(i)),11,wd)):k("",!0),s("div",xd,[s("input",Me({ref_key:"inputElement",ref:n,type:o(r),name:l.id,id:l.id,class:o(p),placeholder:o(d),value:l.modelValue,onInput:e[0]||(e[0]=e=>t.$emit("update:modelValue",e.target.value)),"aria-invalid":null!=o(v),"aria-describedby":l.id+"-error",step:"any"},o(dt)(t.$attrs,["class"])),null,16,kd),o(v)?(a(),u("div",$d,_d)):k("",!0)]),o(v)?(a(),u("p",{key:1,class:"mt-2 text-sm text-red-500",id:l.id+"-error"},T(o(v)),9,Ld)):l.help?(a(),u("p",{key:2,class:"mt-2 text-sm text-gray-500",id:l.id+"-description"},T(l.help),9,Vd)):k("",!0),Z(t.$slots,"footer",Me({inputElement:n.value,id:l.id,modelValue:l.modelValue,status:l.status},t.$attrs))],2))}}),Ad=["for"],Td={class:"mt-1 relative rounded-md shadow-sm"},Fd=["name","id","placeholder","aria-invalid","aria-describedby"],Id=["id"],Dd=["id"],jd={inheritAttrs:!1},Od=ce({...jd,__name:"TextareaInput",props:{status:null,id:null,inputClass:null,label:null,labelClass:null,help:null,placeholder:null,modelValue:null},setup(l){const e=l,n=f(()=>e.label??He(st(e.id))),r=f(()=>e.placeholder??n.value);let t=Ne("ApiState",void 0);const i=f(()=>mt.call({responseStatus:e.status??(null==t?void 0:t.error.value)},e.id)),d=f(()=>["shadow-sm "+nt.base,i.value?"text-red-900 focus:ring-red-500 focus:border-red-500 border-red-300":"text-gray-900 "+nt.valid,e.inputClass]);return(t,e)=>(a(),u("div",{class:w([t.$attrs.class])},[o(n)?(a(),u("label",{key:0,for:l.id,class:w("block text-sm font-medium text-gray-700 dark:text-gray-300 "+(l.labelClass??""))},T(o(n)),11,Ad)):k("",!0),s("div",Td,[s("textarea",Me({name:l.id,id:l.id,class:o(d),placeholder:o(r),onInput:e[0]||(e[0]=e=>t.$emit("update:modelValue",e.target.value)),"aria-invalid":null!=o(i),"aria-describedby":l.id+"-error"},o(dt)(t.$attrs,["class"])),T(l.modelValue),17,Fd)]),o(i)?(a(),u("p",{key:1,class:"mt-2 text-sm text-red-500",id:l.id+"-error"},T(o(i)),9,Id)):l.help?(a(),u("p",{key:2,class:"mt-2 text-sm text-gray-500",id:l.id+"-description"},T(l.help),9,Dd)):k("",!0)],2))}}),Pd=["for"],Bd=["id","name","value","aria-invalid","aria-describedby"],Rd=["value"],Ed=["id"],Hd={inheritAttrs:!1},zd=ce({...Hd,__name:"SelectInput",props:{status:null,id:null,modelValue:null,inputClass:null,label:null,labelClass:null,options:null,values:null,entries:null},setup(l){const t=l,n=f(()=>t.label??He(st(t.id)));let e=Ne("ApiState",void 0);const r=f(()=>mt.call({responseStatus:t.status??(null==e?void 0:e.error.value)},t.id)),i=f(()=>t.entries||(t.values?t.values.map(e=>({key:e,value:e})):t.options?Object.keys(t.options).map(e=>({key:e,value:t.options[e]})):[]));return(t,e)=>(a(),u("div",{class:w([t.$attrs.class])},[o(n)?(a(),u("label",{key:0,for:l.id,class:w("block text-sm font-medium text-gray-700 dark:text-gray-300 "+(l.labelClass??""))},T(o(n)),11,Pd)):k("",!0),s("select",Me({id:l.id,name:l.id,class:["mt-1 block w-full pl-3 pr-10 py-2 text-base focus:outline-none sm:text-sm rounded-md dark:text-white dark:bg-gray-900 dark:border-gray-600",o(r)?"border-red-300 text-red-900 focus:ring-red-500 focus:border-red-500":"border-gray-300 text-gray-900 focus:ring-indigo-500 focus:border-indigo-500",l.inputClass],value:l.modelValue,onInput:e[0]||(e[0]=e=>t.$emit("update:modelValue",e.target.value)),"aria-invalid":null!=o(r),"aria-describedby":l.id+"-error"},o(dt)(t.$attrs,["class"])),[(a(!0),u(Te,null,Ie(o(i),e=>(a(),u("option",{value:e.key},T(e.value),9,Rd))),256))],16,Bd),o(r)?(a(),u("p",{key:1,class:"mt-2 text-sm text-red-500",id:l.id+"-error"},T(o(r)),9,Ed)):k("",!0)],2))}}),Nd={class:"flex items-center h-5"},Ud=["id","name","checked"],qd={class:"ml-3 text-sm"},Qd=["for"],Kd={key:0,class:"mt-2 text-sm text-red-500",id:"`${id}-error`"},Zd={key:1,class:"mt-2 text-sm text-gray-500",id:"`${id}-description`"},Gd={inheritAttrs:!1},Wd=ce({...Gd,__name:"CheckboxInput",props:{modelValue:{type:Boolean},status:null,id:null,inputClass:null,label:null,labelClass:null,help:null},emits:["update:modelValue"],setup(l,{}){const e=l,n=f(()=>e.label??He(st(e.id)));let t=Ne("ApiState",void 0);const r=f(()=>mt.call({responseStatus:e.status??(null==t?void 0:t.error.value)},e.id));return(t,e)=>(a(),u("div",{class:w(["relative flex items-start",t.$attrs.class])},[s("div",Nd,[s("input",Me({id:l.id,name:l.id,type:"checkbox",checked:l.modelValue,onInput:e[0]||(e[0]=e=>t.$emit("update:modelValue",e.target.checked)),class:["focus:ring-indigo-500 h-4 w-4 text-indigo-600 rounded border-gray-300 dark:border-gray-600 dark:bg-gray-800",l.inputClass]},o(dt)(t.$attrs,["class"])),null,16,Ud)]),s("div",qd,[s("label",{for:l.id,class:w("font-medium text-gray-700 dark:text-gray-300 "+(l.labelClass??""))},T(o(n)),11,Qd),o(r)?(a(),u("p",Kd,T(o(r)),1)):l.help?(a(),u("p",Zd,T(l.help),1)):k("",!0)])],2))}}),Jd=["id"],Xd=["for"],Yd={class:"mt-1 relative rounded-md shadow-sm"},ec=["id","name","value"],tc=["onClick"],lc={class:"flex flex-wrap pb-1.5"},nc={class:"pt-1.5 pl-1"},sc={class:"inline-flex rounded-full items-center py-0.5 pl-2.5 pr-1 text-sm font-medium bg-indigo-100 dark:bg-indigo-800 text-indigo-700 dark:text-indigo-300"},oc=["onClick"],ac=s("svg",{class:"h-2 w-2",stroke:"currentColor",fill:"none",viewBox:"0 0 8 8"},[s("path",{"stroke-linecap":"round","stroke-width":"1.5",d:"M1 1l6 6m0-6L1 7"})],-1),ic=[ac],rc={class:"pt-1.5 pl-1 shrink"},uc=["type","name","id","aria-invalid","aria-describedby","onPaste"],dc=["id"],cc=["onMouseover","onClick"],fc={class:"block truncate"},mc={key:1,class:"absolute inset-y-0 right-0 pr-3 flex items-center pointer-events-none"},vc=s("svg",{class:"h-5 w-5 text-red-500",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true"},[s("path",{"fill-rule":"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7 4a1 1 0 11-2 0 1 1 0 012 0zm-1-9a1 1 0 00-1 1v4a1 1 0 102 0V6a1 1 0 00-1-1z","clip-rule":"evenodd"})],-1),hc=[vc],gc=["id"],pc=["id"],yc={inheritAttrs:!1},bc=ce({...yc,__name:"TagInput",props:{status:null,id:null,type:null,inputClass:null,label:null,labelClass:null,help:null,modelValue:{default:()=>[]},delimiters:{default:()=>[","]},allowableValues:null,string:{type:Boolean},converter:null},emits:["update:modelValue"],setup(l,{emit:t}){const n=l;const r=f(()=>{return qe((e=n.modelValue,n.converter?n.converter(e):e),e=>"string"==typeof e?0==e.trim().length?[]:e.split(","):e)||[];var e}),i=A(),d=A(!1),c=f(()=>n.allowableValues&&0!=n.allowableValues.length?n.allowableValues.filter(e=>!r.value.includes(e)&&e.toLowerCase().includes(p.value.toLowerCase())):[]);const v=A(null),p=A(""),m=f(()=>n.type||"text"),g=f(()=>n.label??He(st(n.id)));let e=Ne("ApiState",void 0);const y=f(()=>mt.call({responseStatus:n.status??(null==e?void 0:e.error.value)},n.id)),h=f(()=>["w-full cursor-text flex flex-wrap sm:text-sm rounded-md dark:text-white dark:bg-gray-900 border focus-within:border-transparent focus-within:ring-1 focus-within:outline-none",y.value?"pr-10 border-red-300 text-red-900 placeholder-red-300 focus-within:outline-none focus-within:ring-red-500 focus-within:border-red-500":"shadow-sm border-gray-300 dark:border-gray-600 focus-within:ring-indigo-500 focus-within:border-indigo-500",n.inputClass]),b=t=>M(r.value.filter(e=>e!=t));function x(e){document.activeElement===e.target&&null!=(e=v.value)&&e.focus()}const C=A();function L(){d.value=!0,C.value=!0}function V(){O(I()),C.value=!1,setTimeout(()=>{C.value||(d.value=!1)},200)}function M(e){e=n.string?e.join(","):e;t("update:modelValue",e)}function S(e){var t;"Backspace"==e.key&&0==p.value.length&&0e==t.key))&&t.preventDefault(),"Enter"==t.key||"NumpadEnter"==t.key||1==t.key.length&&e)&&O(l)}const F={behavior:"smooth",block:"nearest",inline:"nearest",scrollMode:"if-needed"};function B(){setTimeout(()=>{var e=pl(`#${n.id}-tag li.active`);e&&e.scrollIntoView(F)},0)}function j(){setTimeout(()=>{var e=pl(`#${n.id}-tag li.active`);e&&("scrollIntoViewIfNeeded"in e?e.scrollIntoViewIfNeeded(F):e.scrollIntoView(F))},0)}function O(e){var t;0!==e.length&&(-1==(t=Array.from(r.value)).indexOf(e)&&t.push(e),M(t),p.value="",d.value=!1)}function H(e){e=null==(e=e.clipboardData)?void 0:e.getData("Text");if(e){const t=new RegExp("\\n|\\t|"+n.delimiters.join("|")),l=Array.from(r.value);e.split(t).map(e=>e.trim()).forEach(e=>{-1==l.indexOf(e)&&l.push(e)}),M(l),p.value=""}}return(e,t)=>(a(),u("div",{class:w([e.$attrs.class]),id:l.id+"-tag",onmousemove:"cancelBlur=true"},[o(g)?(a(),u("label",{key:0,for:l.id,class:w("block text-sm font-medium text-gray-700 dark:text-gray-300 "+(l.labelClass??""))},T(o(g)),11,Xd)):k("",!0),s("div",Yd,[s("input",{type:"hidden",id:l.id,name:l.id,value:o(r).join(",")},null,8,ec),s("button",{class:w(o(h)),onClick:Ue(x,["prevent"]),onFocus:t[2]||(t[2]=e=>d.value=!0),tabindex:"-1"},[s("div",lc,[(a(!0),u(Te,null,Ie(o(r),t=>(a(),u("div",nc,[s("span",sc,[we(T(t)+" ",1),s("button",{type:"button",onClick:e=>b(t),class:"flex-shrink-0 ml-1 h-4 w-4 rounded-full inline-flex items-center justify-center text-indigo-400 dark:text-indigo-500 hover:bg-indigo-200 dark:hover:bg-indigo-800 hover:text-indigo-500 dark:hover:text-indigo-400 focus:outline-none focus:bg-indigo-500 focus:text-white dark:focus:text-black"},ic,8,oc)])]))),256)),s("div",rc,[kt(s("input",Me({ref_key:"txtInput",ref:v,type:o(m),role:"combobox","aria-controls":"options","aria-expanded":"false",autocomplete:"off",spellcheck:"false",name:l.id+"-txt",id:l.id+"-txt",class:"p-0 dark:bg-transparent rounded-md border-none focus:!border-none focus:!outline-none",style:`box-shadow:none !important;width:${p.value.length+1}ch`,"onUpdate:modelValue":t[0]||(t[0]=e=>p.value=e),"aria-invalid":null!=o(y),"aria-describedby":l.id+"-error",onKeydown:S,onKeypress:$,onPaste:Ue(H,["prevent","stop"]),onFocus:L,onBlur:V,onClick:t[1]||(t[1]=e=>d.value=!0)},o(dt)(e.$attrs,["class","required"])),null,16,uc),[[ao,p.value]])])])],42,tc),d.value&&o(c).length?(a(),u("ul",{key:0,class:"absolute z-10 mt-1 max-h-60 w-full overflow-auto rounded-md bg-white dark:bg-black py-1 text-base shadow-lg ring-1 ring-black ring-opacity-5 focus:outline-none sm:text-sm",onKeydown:S,id:l.id+"-options",role:"listbox"},[(a(!0),u(Te,null,Ie(o(c),l=>(a(),u("li",{class:w([l===i.value?"active bg-indigo-600 text-white":"text-gray-900 dark:text-gray-100","relative cursor-default select-none py-2 pl-3 pr-9"]),onMouseover:e=>{var t;t=l,i.value=t},onClick:e=>O(l),role:"option",tabindex:"-1"},[s("span",fc,T(l),1)],42,cc))),256))],40,dc)):k("",!0),o(y)?(a(),u("div",mc,hc)):k("",!0)]),o(y)?(a(),u("p",{key:1,class:"mt-2 text-sm text-red-500",id:l.id+"-error"},T(o(y)),9,gc)):l.help?(a(),u("p",{key:2,class:"mt-2 text-sm text-gray-500",id:l.id+"-description"},T(l.help),9,pc)):k("",!0)],10,Jd))}}),wc={class:"relative flex-grow mr-2 sm:mr-4"},xc=["for"],kc={class:"block mt-2"},$c={class:"sr-only"},Cc=["multiple","name","id","placeholder","aria-invalid","aria-describedby"],_c={key:0,class:"absolute inset-y-0 right-0 pr-3 flex items-center pointer-events-none"},Lc=s("svg",{class:"h-5 w-5 text-red-500",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true"},[s("path",{"fill-rule":"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7 4a1 1 0 11-2 0 1 1 0 012 0zm-1-9a1 1 0 00-1 1v4a1 1 0 102 0V6a1 1 0 00-1-1z","clip-rule":"evenodd"})],-1),Vc=[Lc],Sc=["id"],Mc=["id"],Ac={key:0},Tc=["title"],Fc=["alt","src"],Ic={key:1,class:"mt-3"},Dc={class:"w-full"},jc={class:"pr-6 align-bottom pb-2"},Oc=["title"],Pc=["src","onError"],Bc=["href"],Rc={key:1,class:"overflow-hidden"},Ec={class:"align-top pb-2 whitespace-nowrap"},Hc={key:0,class:"text-gray-500 dark:text-gray-400 text-sm bg-white dark:bg-black"},zc=ce({__name:"FileInput",props:{multiple:{type:Boolean},status:null,id:null,inputClass:null,label:null,labelClass:null,help:null,placeholder:null,modelValue:null,values:null,files:null},setup(l){var e;const t=l,n=A(null),{assetsPathResolver:r,fallbackPathResolver:i}=St(),d={},c=A(),v=A((null==(e=t.files)?void 0:e.map(p))||[]);function p(e){return e.filePath=r(e.filePath),e}t.values&&0{e=e.replace(/\\/g,"/");return{fileName:Co($t(e,"/"),"."),filePath:e,contentType:Kl(e)}}).map(p));const m=f(()=>t.label??He(st(t.id))),g=f(()=>t.placeholder??m.value);let y=Ne("ApiState",void 0);const h=f(()=>mt.call({responseStatus:t.status??(null==y?void 0:y.error.value)},t.id)),b=f(()=>["block w-full sm:text-sm rounded-md dark:text-white dark:bg-gray-900 file:mr-4 file:py-2 file:px-4 file:rounded-full file:border-0 file:text-sm file:font-semibold file:bg-violet-50 dark:file:bg-violet-900 file:text-violet-700 dark:file:text-violet-200 hover:file:bg-violet-100 dark:hover:file:bg-violet-800",h.value?"pr-10 border-red-300 text-red-900 placeholder-red-300 focus:outline-none focus:ring-red-500 focus:border-red-500":"text-slate-500 dark:text-slate-400",t.inputClass]),x=e=>{e=e.target;c.value="",v.value=Array.from(e.files||[]).map(e=>({fileName:e.name,filePath:un(e),contentLength:e.size,contentType:e.type||Kl(e.name)}))},C=()=>{var e;return null==(e=n.value)?void 0:e.click()},L=e=>null!=e&&(e.startsWith("data:")||e.startsWith("blob:")),V=f(()=>{var e;return 0!e||e.startsWith("data:")||e.endsWith(".svg")?"":"rounded-full object-cover";function S(e){c.value=i(V.value)}return Rt(fs),(e,t)=>(a(),u("div",{class:w(["flex",l.multiple?"flex-col":"justify-between"])},[s("div",wc,[o(m)?(a(),u("label",{key:0,for:l.id,class:w("block text-sm font-medium text-gray-700 dark:text-gray-300 "+(l.labelClass??""))},T(o(m)),11,xc)):k("",!0),s("div",kc,[s("span",$c,T(l.help??o(m)),1),s("input",Me({ref_key:"input",ref:n,type:"file",multiple:l.multiple,name:l.id,id:l.id,class:o(b),placeholder:o(g),"aria-invalid":null!=o(h),"aria-describedby":l.id+"-error"},e.$attrs,{onChange:x}),null,16,Cc),o(h)?(a(),u("div",_c,Vc)):k("",!0)]),o(h)?(a(),u("p",{key:1,class:"mt-2 text-sm text-red-500",id:l.id+"-error"},T(o(h)),9,Sc)):l.help?(a(),u("p",{key:2,class:"mt-2 text-sm text-gray-500",id:l.id+"-description"},T(l.help),9,Mc)):k("",!0)]),l.multiple?(a(),u("div",Ic,[s("table",Dc,[(a(!0),u(Te,null,Ie(v.value,t=>(a(),u("tr",null,[s("td",jc,[s("div",{class:"flex w-full",title:L(t.filePath)?"":t.filePath},[s("img",{src:d[o(yt)(t.filePath)]||o(r)(o(yt)(t.filePath)),class:w(["mr-2 h-8 w-8",M(t.filePath)]),onError:e=>d[o(yt)(t.filePath)]=o(i)(o(yt)(t.filePath))},null,42,Pc),L(t.filePath)?(a(),u("span",Rc,T(t.fileName),1)):(a(),u("a",{key:0,href:o(r)(t.filePath||""),target:"_blank",class:"overflow-hidden"},T(t.fileName),9,Bc))],8,Oc)]),s("td",Ec,[t.contentLength&&0[]},modelValue:null,match:null,viewCount:{default:100},pageSize:{default:8}},emits:["update:modelValue"],setup(l,{expose:e,emit:n}){const r=l,i=A(!1);function d(e){return Array.isArray(r.modelValue)&&0<=r.modelValue.indexOf(e)}e({toggle:B});const c=f(()=>r.label??He(st(r.id)));let t=Ne("ApiState",void 0);const v=f(()=>mt.call({responseStatus:r.status??(null==t?void 0:t.error.value)},r.id)),p=f(()=>[nt.base,v.value?nt.invalid:nt.valid]),m=A(null),g=A(""),y=A(null),h=A(r.viewCount),b=A([]),x=f(()=>g.value?r.options.filter(e=>r.match(e,g.value)).slice(0,h.value):r.options),C=["Tab","Escape","ArrowDown","ArrowUp","Enter","PageUp","PageDown","Home","End"];const L=[",",` +var lo=Object.defineProperty,no=(e,t,l)=>t in e?lo(e,t,{enumerable:!0,configurable:!0,writable:!0,value:l}):e[t]=l,Ce=(e,t,l)=>(no(e,"symbol"!=typeof t?t+"":t,l),l);import{defineComponent as ce,computed as f,openBlock as a,createElementBlock as u,normalizeClass as w,unref as o,createElementVNode as s,createCommentVNode as k,renderSlot as Z,ref as A,toDisplayString as T,inject as Ne,nextTick as xt,isRef as Gn,mergeProps as Me,withModifiers as Ue,h as gt,resolveComponent as X,createBlock as se,withCtx as ke,useAttrs as so,createVNode as $e,createTextVNode as we,watchEffect as hl,normalizeStyle as Xl,Fragment as Te,renderList as Ie,withDirectives as kt,vModelCheckbox as Yl,withKeys as Wn,createStaticVNode as wl,vModelSelect as oo,useSlots as en,getCurrentInstance as Be,onMounted as tt,createSlots as tn,normalizeProps as jt,guardReactiveProps as gl,vModelDynamic as ao,onUnmounted as Rt,watch as Lt,vModelText as io,resolveDynamicComponent as Jn,provide as Xt,resolveDirective as ro}from"vue";import{errorResponseExcept as uo,dateFmt as Xn,toTime as co,omit as dt,enc as Hl,setQueryString as fo,appendQueryString as Kt,nameOf as mo,ApiResult as Je,lastRightPart as $t,leftPart as xl,map as qe,toDate as Vt,toDateTime as vo,toCamelCase as ho,mapGet as ye,chop as go,fromXsdDuration as Yn,isDate as kl,timeFmt12 as po,apiValue as yo,indexOfAny as bo,createBus as wo,toKebabCase as Nn,sanitize as xo,humanize as He,delaySet as es,rightPart as dl,queryString as zl,combinePaths as ko,toPascalCase as st,errorResponse as mt,trimEnd as $o,$1 as pl,lastLeftPart as Co,ResponseStatus as Bl,ResponseError as Un,HttpMethods as ln,omitEmpty as _o,uniqueKeys as Nl,humanify as ts,each as Lo}from"@servicestack/client";const Vo={class:"flex items-center"},So={key:0,class:"flex-shrink-0 mr-3"},Mo={key:0,class:"h-5 w-5 text-yellow-400",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true"},Ao=s("path",{"fill-rule":"evenodd",d:"M8.257 3.099c.765-1.36 2.722-1.36 3.486 0l5.58 9.92c.75 1.334-.213 2.98-1.742 2.98H4.42c-1.53 0-2.493-1.646-1.743-2.98l5.58-9.92zM11 13a1 1 0 11-2 0 1 1 0 012 0zm-1-8a1 1 0 00-1 1v3a1 1 0 002 0V6a1 1 0 00-1-1z","clip-rule":"evenodd"},null,-1),To=[Ao],Fo={key:1,class:"h-5 w-5 text-red-400",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true"},Io=s("path",{"fill-rule":"evenodd",d:"M10 18a8 8 0 100-16 8 8 0 000 16zM8.28 7.22a.75.75 0 00-1.06 1.06L8.94 10l-1.72 1.72a.75.75 0 101.06 1.06L10 11.06l1.72 1.72a.75.75 0 101.06-1.06L11.06 10l1.72-1.72a.75.75 0 00-1.06-1.06L10 8.94 8.28 7.22z","clip-rule":"evenodd"},null,-1),Do=[Io],jo={key:2,class:"h-5 w-5 text-blue-400",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true"},Oo=s("path",{"fill-rule":"evenodd",d:"M19 10.5a8.5 8.5 0 11-17 0 8.5 8.5 0 0117 0zM8.25 9.75A.75.75 0 019 9h.253a1.75 1.75 0 011.709 2.13l-.46 2.066a.25.25 0 00.245.304H11a.75.75 0 010 1.5h-.253a1.75 1.75 0 01-1.709-2.13l.46-2.066a.25.25 0 00-.245-.304H9a.75.75 0 01-.75-.75zM10 7a1 1 0 100-2 1 1 0 000 2z","clip-rule":"evenodd"},null,-1),Po=[Oo],Bo={key:3,class:"h-5 w-5 text-green-400",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true"},Ro=s("path",{"fill-rule":"evenodd",d:"M10 18a8 8 0 100-16 8 8 0 000 16zm3.857-9.809a.75.75 0 00-1.214-.882l-3.483 4.79-1.88-1.88a.75.75 0 10-1.06 1.061l2.5 2.5a.75.75 0 001.137-.089l4-5.5z","clip-rule":"evenodd"},null,-1),Eo=[Ro],Ho=ce({__name:"Alert",props:{type:{default:"warn"},hideIcon:{type:Boolean}},setup(l){const e=l,n=f(()=>"info"==e.type?"bg-blue-50 dark:bg-blue-200":"error"==e.type?"bg-red-50 dark:bg-red-200":"success"==e.type?"bg-green-50 dark:bg-green-200":"bg-yellow-50 dark:bg-yellow-200"),r=f(()=>"info"==e.type?"border-blue-400":"error"==e.type?"border-red-400":"success"==e.type?"border-green-400":"border-yellow-400"),i=f(()=>"info"==e.type?"text-blue-700":"error"==e.type?"text-red-700":"success"==e.type?"text-green-700":"text-yellow-700");return(e,t)=>(a(),u("div",{class:w([o(n),o(r),"border-l-4 p-4"])},[s("div",Vo,[l.hideIcon?k("",!0):(a(),u("div",So,["warn"==l.type?(a(),u("svg",Mo,To)):"error"==l.type?(a(),u("svg",Fo,Do)):"info"==l.type?(a(),u("svg",jo,Po)):"success"==l.type?(a(),u("svg",Bo,Eo)):k("",!0)])),s("div",null,[s("p",{class:w([o(i),"text-sm"])},[Z(e.$slots,"default")],2)])])],2))}}),zo={key:0,class:"rounded-md bg-green-50 dark:bg-green-200 p-4",role:"alert"},No={class:"flex"},Uo=s("div",{class:"flex-shrink-0"},[s("svg",{class:"h-5 w-5 text-green-400 dark:text-green-500",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},[s("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M5 13l4 4L19 7"})])],-1),qo={class:"ml-3"},Qo={class:"text-sm font-medium text-green-800"},Ko={key:0},Zo={class:"ml-auto pl-3"},Go={class:"-mx-1.5 -my-1.5"},Wo=s("span",{class:"sr-only"},"Dismiss",-1),Jo=s("svg",{class:"h-5 w-5",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true"},[s("path",{d:"M6.28 5.22a.75.75 0 00-1.06 1.06L8.94 10l-3.72 3.72a.75.75 0 101.06 1.06L10 11.06l3.72 3.72a.75.75 0 101.06-1.06L11.06 10l3.72-3.72a.75.75 0 00-1.06-1.06L10 8.94 6.28 5.22z"})],-1),Xo=[Wo,Jo],Yo=ce({__name:"AlertSuccess",props:{message:null},setup(l){const n=A(!1);return(e,t)=>n.value?k("",!0):(a(),u("div",zo,[s("div",No,[Uo,s("div",qo,[s("h3",Qo,[l.message?(a(),u("span",Ko,T(l.message),1)):Z(e.$slots,"default",{key:1})])]),s("div",Zo,[s("div",Go,[s("button",{type:"button",class:"inline-flex rounded-md bg-green-50 dark:bg-green-200 p-1.5 text-green-500 dark:text-green-600 hover:bg-green-100 dark:hover:bg-green-700 dark:hover:text-white focus:outline-none focus:ring-2 focus:ring-green-600 focus:ring-offset-2 focus:ring-offset-green-50 dark:ring-offset-green-200",onClick:t[0]||(t[0]=e=>n.value=!0)},Xo)])])])]))}}),ea={class:"flex"},ta=s("div",{class:"flex-shrink-0"},[s("svg",{class:"h-5 w-5 text-red-400",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},[s("path",{fill:"currentColor",d:"M12 2c5.53 0 10 4.47 10 10s-4.47 10-10 10S2 17.53 2 12S6.47 2 12 2m3.59 5L12 10.59L8.41 7L7 8.41L10.59 12L7 15.59L8.41 17L12 13.41L15.59 17L17 15.59L13.41 12L17 8.41L15.59 7Z"})])],-1),la={class:"ml-3"},na={class:"text-sm text-red-700 dark:text-red-200"},sa=ce({__name:"ErrorSummary",props:{status:null,except:null,class:null},setup(e){const t=e;let l=Ne("ApiState",void 0);const n=f(()=>t.status||null!=l&&l.error.value?uo.call({responseStatus:t.status??(null==l?void 0:l.error.value)},t.except??[]):null);return(e,t)=>o(n)?(a(),u("div",{key:0,class:w("bg-red-50 dark:bg-red-900 border-l-4 border-red-400 p-4 "+e.$props.class)},[s("div",ea,[ta,s("div",la,[s("p",na,T(o(n)),1)])])],2)):k("",!0)}}),oa=["id","aria-describedby"],aa=ce({__name:"InputDescription",props:{id:null,description:null},setup(l){return(e,t)=>l.description?(a(),u("div",{key:"description",class:"mt-2 text-sm text-gray-500",id:l.id+"-description","aria-describedby":l.id+"-description"},[s("div",null,T(l.description),1)],8,oa)):k("",!0)}});function $l(e){return Xn(e).replace(/\//g,"-")}function ls(e){return null==e?"":co(e)}function ns(e,t){e.value=null,xt(()=>e.value=t)}function Tt(l){return Object.keys(l).forEach(e=>{var t=l[e];l[e]=Gn(t)?o(t):t}),l}function Ct(e,t,l){l?(t.value=e.entering.cls+" "+e.entering.from,setTimeout(()=>t.value=e.entering.cls+" "+e.entering.to,0)):(t.value=e.leaving.cls+" "+e.leaving.from,setTimeout(()=>t.value=e.leaving.cls+" "+e.leaving.to,0))}function cl(l){if(!("u"0":"<"+e+Ul(l)+`>${t||""}`}function Ul(l){return Object.keys(l).reduce((e,t)=>`${e} ${t}="${Hl(l[t])}"`,"")}function Cl(e){return Object.assign({target:"_blank",rel:"noopener",class:"text-blue-600"},e)}function Dt(e){return kn(e)}let ia=["string","number","boolean","null","undefined"];function _t(e){return 0<=ia.indexOf(typeof e)||e instanceof Date}function Zt(e){return!_t(e)}class ss{get length(){return"u"",";"].some(e=>t.includes(e)))throw new Error(`Unsafe script: '${t}'`);e=Object.assign(Object.keys(globalThis).reduce((e,t)=>(e[t]=void 0,e),{}),e);return new Function("with(this) { return ("+t+") }").call(e)}function ql(e){typeof navigator<"u"&&navigator.clipboard.writeText(e)}function on(e){e=ne.config.storage.getItem(e);return e?JSON.parse(e):null}function _l(e,t){return Kt("swr."+mo(e),t?Object.assign({},e,t):e)}function ra(e){e.request&&(e=_l(e.request,e.args),ne.config.storage.removeItem(e))}async function os(e,t,l,a,s){var n=_l(t,a),e=(l(new Je({response:on(n)})),await e.api(t,a,s));return e.succeeded&&e.response&&(e.response._date=(new Date).valueOf(),t=JSON.stringify(e.response),ne.config.storage.setItem(n,t),l(e)),e}function as(t,l){let a=null;return(...e)=>{a&&clearTimeout(a),a=setTimeout(()=>{t(...e)},l||100)}}function pt(e){return"string"==typeof e?e.split(","):e||[]}function wt(e,t){const l=pt(t);return e.reduce((e,t)=>(e[t]=!l.includes(t),e),{})}function is(){return{LocalStore:ss,dateInputFormat:$l,timeInputFormat:ls,setRef:ns,unRefs:Tt,transition:Ct,focusNextElement:cl,getTypeName:Et,htmlTag:rt,htmlAttrs:Ul,linkAttrs:Cl,toAppUrl:Dt,isPrimitive:_t,isComplexType:Zt,pushState:nn,scopedExpr:sn,copyText:ql,fromCache:on,swrCacheKey:_l,swrClear:ra,swrApi:os,asStrings:pt,asOptions:wt,createDebounce:as}}const rs="png,jpg,jpeg,jfif,gif,svg,webp".split(","),us={img:"png,jpg,jpeg,gif,svg,webp,png,jpg,jpeg,gif,bmp,tif,tiff,webp,ai,psd,ps".split(","),vid:"avi,m4v,mov,mp4,mpg,mpeg,wmv,webm".split(","),aud:"mp3,mpa,ogg,wav,wma,mid,webm".split(","),ppt:"key,odp,pps,ppt,pptx".split(","),xls:"xls,xlsm,xlsx,ods,csv,tsv".split(","),doc:"doc,docx,pdf,rtf,tex,txt,md,rst,xls,xlsm,xlsx,ods,key,odp,pps,ppt,pptx".split(","),zip:"zip,tar,gz,7z,rar,gzip,deflate,br,iso,dmg,z,lz,lz4,lzh,s7z,apl,arg,jar,war".split(","),exe:"exe,bat,sh,cmd,com,app,msi,run,vb,vbs,js,ws,wsh".split(","),att:"bin,oct,dat".split(",")},qn=Object.keys(us),ft=(e,t)=>``,fl={img:ft("4 4 16 16",""),vid:ft("0 0 24 24",""),aud:ft("0 0 24 24",""),ppt:ft("0 0 48 48",""),xls:ft("0 0 256 256",""),doc:ft("0 0 32 32",""),zip:ft("0 0 16 16",""),exe:ft("0 0 16 16",""),att:ft("0 0 24 24","")},ua=/[\r\n%#()<>?[\\\]^`{|}]/g,Qn=1024,da=["Bytes","KB","MB","GB","TB"],ca=(()=>{const t="application/",e=t+"vnd.openxmlformats-officedocument.",l="image/",a="text/",s="video/",n={jpg:l+"jpeg",tif:l+"tiff",svg:l+"svg+xml",ico:l+"x-icon",ts:a+"typescript",py:a+"x-python",sh:a+"x-sh",mp3:"audio/mpeg3",mpg:s+"mpeg",ogv:s+"ogg",xlsx:e+"spreadsheetml.sheet",xltx:e+"spreadsheetml.template",docx:e+"wordprocessingml.document",dotx:e+"wordprocessingml.template",pptx:e+"presentationml.presentation",potx:e+"presentationml.template",ppsx:e+"presentationml.slideshow",mdb:t+"vnd.ms-access"};function o(e,t){e.split(",").forEach(e=>n[e]=t)}function r(e,t){e.split(",").forEach(e=>n[e]=t(e))}return r("jpeg,gif,png,tiff,bmp,webp",e=>l+e),r("jsx,csv,css",e=>a+e),r("aac,ac3,aiff,m4a,m4b,m4p,mid,midi,wav",e=>"audio/"+e),r("3gpp,avi,dv,divx,ogg,mp4,webm",e=>s+e),r("rtf,pdf",e=>t+e),o("htm,html,shtm",a+"html"),o("js,mjs,cjs",a+"javascript"),o("yml,yaml",t+"yaml"),o("bat,cmd",t+"bat"),o("xml,csproj,fsproj,vbproj",a+"xml"),o("txt,ps1",a+"plain"),o("qt,mov",s+"quicktime"),o("doc,dot",t+"msword"),o("xls,xlt,xla",t+"excel"),o("ppt,oit,pps,ppa",t+"vnd.ms-powerpoint"),o("cer,crt,der",t+"x-x509-ca-cert"),o("gz,tgz,zip,rar,lzh,z",t+"x-compressed"),o("aaf,aca,asd,bin,cab,chm,class,cur,db,dat,deploy,dll,dsp,exe,fla,ics,inf,mix,msi,mso,obj,ocx,prm,prx,psd,psp,qxd,sea,snp,so,sqlite,toc,ttf,u32,xmp,xsn,xtp",t+"octet-stream"),n})();let Ql=[];function ds(e){return(e=(e=(e=e.replace(/"/g,"'")).replace(/>\s+<")).replace(/\s{2,}/g," ")).replace(ua,encodeURIComponent)}function an(e){return"data:image/svg+xml;utf8,"+ds(e)}function cs(e){e=URL.createObjectURL(e);return Ql.push(e),e}function fs(){Ql.forEach(e=>{try{URL.revokeObjectURL(e)}catch(e){console.error("URL.revokeObjectURL",e)}}),Ql=[]}function rn(e){return e?(e=xl(e,"?"),$t(e,"/")):null}function Yt(e){e=rn(e);return null==e||-1===e.indexOf(".")?null:$t(e,".").toLowerCase()}function un(e){var t=Yt(e.name);return t&&0<=rs.indexOf(t)?cs(e):yt(e.name)}function dn(e){return e&&(!(!e.startsWith("blob:")&&!e.startsWith("data:"))||(e=Yt(e))&&0<=rs.indexOf(e))||!1}function yt(e){var t;return e?null==(t=Yt(e))||dn(e)?e:Qt(t)||an(fl.doc):null}function Qt(e){e=ms(e);return e&&an(e)||null}function ms(t){if(fl[t])return fl[t];for(let e=0;e({fileName:e.name,contentLength:e.size,filePath:un(e)}))}function Ll(e,t){e.onerror=null,e.src=fn(e.src,t)||""}function fn(e,t){return Qt($t(e,".").toLowerCase())||(t?Qt(t)||t:null)||Qt("doc")}function Kl(e){if(e)return e=$t(e,".").toLowerCase(),ca[e]||"application/"+e;throw new Error("fileNameOrExt required")}function Ch(){return{extSvg:ms,extSrc:Qt,getExt:Yt,encodeSvg:ds,canPreview:dn,getFileName:rn,getMimeType:Kl,formatBytes:cn,filePathUri:yt,svgToDataUri:an,fileImageUri:un,objectUrl:cs,flush:fs,inputFiles:fa,iconOnError:Ll,iconFallbackSrc:fn}}class ma{constructor(e){Ce(this,"view"),Ce(this,"includeTypes"),Object.assign(this,e)}getTypeName(){return"MetadataApp"}getMethod(){return"GET"}createResponse(){return{}}}const Ot="/metadata/app.json",va={Boolean:"checkbox",DateTime:"date",DateOnly:"date",DateTimeOffset:"date",TimeSpan:"time",TimeOnly:"time",Byte:"number",Short:"number",Int64:"number",Int32:"number",UInt16:"number",UInt32:"number",UInt64:"number",Single:"number",Double:"number",Decimal:"number",String:"text",Guid:"text",Uri:"text"},ha={number:"Int32",checkbox:"Boolean",date:"DateTime","datetime-local":"DateTime",time:"TimeSpan"},Zl={Byte:"byte",Int16:"short",Int32:"int",Int64:"long",UInt16:"ushort",Unt32:"uint",UInt64:"ulong",Single:"float",Double:"double",Decimal:"decimal"},ga=([...Object.keys(Zl),...Object.values(Zl)],{String:"string",Boolean:"bool",...Zl});function rl(e){return ga[e]||e}function vs(e,t){return e?(t=t||[],"Nullable`1"===e?rl(t[0])+"?":e.endsWith("[]")?`List<${rl(e.substring(0,e.length-2))}>`:0===t.length?rl(e):xl(rl(e),"`")+"<"+t.join(",")+">"):""}function pa(e){return e&&vs(e.name,e.genericArgs)}class Pt{constructor(){Ce(this,"Query"),Ce(this,"QueryInto"),Ce(this,"Create"),Ce(this,"Update"),Ce(this,"Patch"),Ce(this,"Delete")}get AnyQuery(){return this.Query||this.QueryInto}get AnyUpdate(){return this.Patch||this.Update}toArray(){return[this.Query,this.QueryInto,this.Create,this.Update,this.Patch,this.Delete].filter(e=>!!e).map(e=>e)}get empty(){return!(this.Query||this.QueryInto||this.Create||this.Update||this.Patch||this.Delete)}add(e){ze.isQueryInto(e)&&!this.QueryInto?this.QueryInto=e:ze.isQuery(e)&&!this.Query?this.Query=e:ze.isCreate(e)&&!this.Create?this.Create=e:ze.isUpdate(e)&&!this.Update?this.Update=e:ze.isPatch(e)&&!this.Patch?this.Patch=e:ze.isDelete(e)&&!this.Delete&&(this.Delete=e)}static from(e){const t=new Pt;return e.forEach(e=>{t.add(e)}),t}static forType(l,e){var t;let a=new Pt;return l&&(null!=(e=e??(null==(t=ne.metadata.value)?void 0:t.api))&&e.operations.forEach(e=>{var t;(null==(t=e.dataModel)?void 0:t.name)==l&&a.add(e)})),a}}const ze={Create:"ICreateDb`1",Update:"IUpdateDb`1",Patch:"IPatchDb`1",Delete:"IDeleteDb`1",AnyRead:["QueryDb`1","QueryDb`2"],AnyWrite:["ICreateDb`1","IUpdateDb`1","IPatchDb`1","IDeleteDb`1"],isAnyQuery:e=>qe(e.request.inherits,e=>0<=ze.AnyRead.indexOf(e.name)),isQuery:e=>qe(e.request.inherits,e=>"QueryDb`1"===e.name),isQueryInto:e=>qe(e.request.inherits,e=>"QueryDb`2"===e.name),isCrud:e=>{return null==(e=e.request.implements)?void 0:e.some(e=>0<=ze.AnyWrite.indexOf(e.name))},isCreate:e=>ul(e,ze.Create),isUpdate:e=>ul(e,ze.Update),isPatch:e=>ul(e,ze.Patch),isDelete:e=>ul(e,ze.Delete),model:e=>{var t;return e?qe(e.inherits,e=>0<=ze.AnyRead.indexOf(e.name))?null==(t=e.inherits)?void 0:t.genericArgs[0]:null==(e=null==(t=e.implements)?void 0:t.find(e=>0<=ze.AnyWrite.indexOf(e.name)))?void 0:e.genericArgs[0]:null}};function ya(e){var t;return(null==(t=e.input)?void 0:t.type)||Vl(mn(e))}function hs(e){return e.endsWith("?")?go(e,1):e}function Vl(e){return va[hs(e)]}function ba(e){return e&&ha[e]||"String"}function mn(e){return"Nullable`1"===e.type?e.genericArgs[0]:e.type}function Gl(e){return e&&"number"==Vl(e)||!1}function gs(e){return e&&"string"==e.toLowerCase()||!1}function wa(e){return"List`1"==e||e.startsWith("List<")||e.endsWith("[]")}function ps(e){var t;return!(null==e||!e.type||(t=mn(e),e.isValueType&&-1==t.indexOf("`"))||e.isEnum||null!=Vl(e.type))}function ys(e){var t;return!!(null!=e&&e.type&&(t=mn(e),e.isValueType&&-1==t.indexOf("`")||e.isEnum||"hidden"==(null==(t=e.input)?void 0:t.type)||"file"==(null==(t=e.input)?void 0:t.type)||"tag"==(null==(t=e.input)?void 0:t.type)||"combobox"==(null==(t=e.input)?void 0:t.type)||null!=Vl(e.type)))}function Gt(e,t){let l="string"==typeof e?Sl(e):e,a=(l||(console.warn("Metadata not found for: "+e),l={request:{name:e}}),function(e){Object.assign(this,e)}),s=(n.prototype.createResponse=function(){return l.returnsVoid?void 0:new a},n.prototype.getTypeName=function(){return l.request.name},n.prototype.getMethod=function(){return l.method||"POST"},n);function n(e){Object.assign(this,e)}return new s(t)}function xa(e,t,l={}){let a=function(e){Object.assign(this,e)},s=(n.prototype.createResponse=function(){return"function"==typeof l.createResponse?l.createResponse():new a},n.prototype.getTypeName=function(){return e},n.prototype.getMethod=function(){return l.method||"POST"},n);function n(e){Object.assign(this,e)}return new s(t)}function ml(l,e){return l?(Object.keys(l).forEach(e=>{var t=l[e];"string"==typeof t?t.startsWith("/Date")&&(l[e]=$l(Vt(t))):null!=t&&"object"==typeof t&&(Array.isArray(t)?l[e]=Array.from(t):l[e]=Object.assign({},t))}),l):{}}function ka(e,r){let i={};return Array.from(e.elements).forEach(a=>{var s;if(a.id&&null!=a.value&&""!==a.value){const n=a.id.toLowerCase(),o=r&&r.find(e=>e.name.toLowerCase()==n);let e=null==o?void 0:o.type,t=null==(s=null==o?void 0:o.genericArgs)?void 0:s[0],l="checkbox"===a.type?a.checked:a.value;Gl(e)?l=Number(l):"List`1"===e&&"string"==typeof l&&(l=l.split(",").map(e=>Gl(t)?Number(e):e)),i[a.id]=l}}),i}function vn(e){var t;return(null==(t=null==e?void 0:e.api)?void 0:t.operations)&&0e)?!1:a)){if((t||l)&&(await Kn(t||Ot,l),null!=ne.metadata.value))return;var s=Ne("client");if(null!=s&&(e=await s.api(new ma)).succeeded&&Wt(e.response),null!=ne.metadata.value)return;await Kn(Ot)}return ne.metadata.value}function ot(t,l){var e,a=null==(a=ne.metadata.value)?void 0:a.api;return a&&t?a.types.find(e=>e.name.toLowerCase()===t.toLowerCase()&&(!l||e.namespace==l))||((e=Sl(t))?e.request:(e=a.operations.find(e=>e.response&&e.response.name.toLowerCase()===t.toLowerCase()&&(!l||e.response.namespace==l)))?e.response:null):null}function Sl(t){var e=null==(e=ne.metadata.value)?void 0:e.api;return e?e.operations.find(e=>e.request.name.toLowerCase()===t.toLowerCase()):null}function La({dataModel:e}){var t=null==(t=ne.metadata.value)?void 0:t.api;if(!t)return[];let l=t.operations;if(e){const a="string"==typeof e?ot(e):e;l=l.filter(e=>bs(e.dataModel,a))}return l}function gn(e){return e?ot(e.name,e.namespace):null}function bs(e,t){return e&&t&&e.name===t.name&&(!e.namespace||!t.namespace||e.namespace===t.namespace)}function Va(e,t){e=ot(e);return e&&e.properties&&e.properties.find(e=>e.name.toLowerCase()===t.toLowerCase())}function ws(e){return xs(ot(e))}function xs(t){if(t&&t.isEnum&&null!=t.enumNames){var l={};for(let e=0;el.push({key:e,value:t[e]})),l}}function Sa(e,t){a=e.name,l=(null==t?void 0:t.type)||ya(e)||"text";var l,a=Object.assign({id:a,name:a,type:l},t);return e.isEnum&&(a.type="select",a.allowableEntries=pn(ks(e))),a}function Ma(e){let n=[];if(e){const o=et(e),t=Sl(e.name),r=gn(null==t?void 0:t.dataModel);o.forEach(t=>{var e;if(ys(t)){const l=Sa(t,t.input);if(l.id=ho(l.id),"file"==l.type&&t.uploadTo&&!l.accept&&(e=null==(e=null==(e=ne.metadata.value)?void 0:e.plugins.filesUpload)?void 0:e.locations.find(e=>e.name==t.uploadTo))&&!l.accept&&e.allowExtensions&&(l.accept=e.allowExtensions.map(e=>e.startsWith(".")?e:"."+e).join(",")),r&&(e=null==(e=r.properties)?void 0:e.find(e=>e.name==t.name),t.ref||(t.ref=null==e?void 0:e.ref)),l.options)try{const a={input:l,$typeFields:o.map(e=>e.name),$dataModelFields:r?et(r).map(e=>e.name):[],...ne.config.scopeWhitelist},s=sn(l.options,a);Object.keys(s).forEach(e=>{l[e]=s[e]})}catch{console.error(`failed to evaluate '${l.options}'`)}n.push(l)}})}return n}function yn(t,e){if(!e.type)return console.error("enumDescriptions missing {type:'EnumType'} options"),[""+t];var l=ot(e.type);if(null==l||!l.enumValues)return console.error("Could not find metadata for "+e.type),[""+t];var a=[];for(let e=0;e"number"==typeof e?yn(e,{type:t}):e}function et(e){if(!e)return[];let t=[],l={};for(;e;)e.properties&&e.properties.forEach(e=>{l[e.name]||(l[e.name]=1,t.push(e))}),e=e.inherits?gn(e.inherits):null;return t.map(e=>e.type.endsWith("[]")?{...e,type:"List`1",genericArgs:[e.type.substring(0,e.type.length-2)]}:e)}function ul(e,t){return(null==(e=e.request.implements)?void 0:e.some(e=>e.name===t))||!1}function el(e){return e?Cs(e,et(e)):null}function Cs(e,t){var l=t.find(e=>"id"===e.name.toLowerCase());if(l&&l.isPrimaryKey)return l;t=t.find(e=>e.isPrimaryKey)||l;if(!t){l=ze.model(e);if(l)return qe(ot(l),e=>el(e));console.error("Primary Key not found in "+e.name)}return t||null}function Aa(e,t){return qe(el(e),e=>ye(t,e.name))}function _s(e,t,l){return e&&"none"===e.valueType?"":"%In"===l.key||"%Between"===l.key?`(${l.value})`:Ta(t,l.value)}function Ta(e,t){return!e||Gl(e=hs(e))||"Boolean"===e?t:wa(e)?`[${t}]`:`'${t}'`}function at(){var e=f(()=>{var e;return(null==(e=ne.metadata.value)?void 0:e.app)||null}),t=f(()=>{var e;return(null==(e=ne.metadata.value)?void 0:e.api)||null}),l=f(()=>{var e;return(null==(e=ne.metadata.value)?void 0:e.plugins.autoQuery.viewerConventions)||[]});return hn(),{loadMetadata:_a,getMetadata:$a,setMetadata:Wt,clearMetadata:Ca,metadataApp:e,metadataApi:t,filterDefinitions:l,typeOf:ot,typeOfRef:gn,typeEquals:bs,apiOf:Sl,findApis:La,typeName:pa,typeName2:vs,property:Va,enumOptions:ws,propertyOptions:ks,createFormLayout:Ma,typeProperties:et,supportsProp:ys,Crud:ze,Apis:Pt,getPrimaryKey:el,getPrimaryKeyByProps:Cs,getId:Aa,createDto:Gt,makeDto:xa,toFormValues:ml,formValues:ka,isComplexProp:ps,asKvps:pn,expandEnumFlags:yn,enumFlagsConverter:$s}}const Xe=class Xe{static async getOrFetchValue(e,t,l,a,s,n,o){return Xe.getValue(l,o,s)??(await Xe.fetchLookupIds(e,t,l,a,s,n,[o]),Xe.getValue(l,o,s))}static getValue(e,t,l){e=Xe.Lookup[e];if(e){e=e[t];if(e)return e[l=l.toLowerCase()]}}static setValue(e,t,l,a){e=Xe.Lookup[e]??(Xe.Lookup[e]={});(e[t]??(e[t]={}))[l=l.toLowerCase()]=a}static setRefValue(e,t){var l=ye(t,e.refId);return null==l||null==e.refLabel?null:(t=ye(t,e.refLabel),Xe.setValue(e.model,l,e.refLabel,t),t)}static async fetchLookupIds(e,t,l,a,s,n,o){t=t.operations.find(e=>{return ze.isAnyQuery(e)&&(null==(e=e.dataModel)?void 0:e.name)==l});if(t){const r=Xe.Lookup[l]??(Xe.Lookup[l]={}),i=[];Object.keys(r).forEach(e=>{var t=r[e];ye(t,s)&&i.push(e)});var o=o.filter(e=>!i.includes(e));0!=o.length&&(n=n?null:a+","+s,o={[a+"In"]:o.join(",")},n&&(o.fields=n),n=Gt(t,o),(o=await e.api(n,{jsconfig:"edv,eccn"})).succeeded?(ye(o.response,"results")||[]).forEach(e=>{var t,l;ye(e,a)?(t=""+ye(e,a),l=ye(e,s),s=s.toLowerCase(),(r[t]??(r[t]={}))[s]=""+l):console.error(`result[${a}] == null`,e)}):console.error("Failed to call "+t.request.name))}}};Ce(Xe,"Lookup",{});let Ft=Xe,Wl=()=>(new Date).getTime(),Fa=["/","T",":","-"],ut={assumeUtc:!0,date:{method:"Intl.DateTimeFormat",options:"{dateStyle:'medium'}"},maxFieldLength:150,maxNestedFields:2,maxNestedFieldLength:30},Ia=new Intl.RelativeTimeFormat(ut.locale,{}),Zn=31536e6,Rl={year:Zn,month:Zn/12,day:864e5,hour:36e5,minute:6e4,second:1e3},bt={currency:Vs,bytes:Ss,link:Ms,linkTel:As,linkMailTo:Ts,icon:Fs,iconRounded:Is,attachment:Ds,hidden:js,time:Os,relativeTime:wn,relativeTimeFromMs:Ml,enumFlags:Bs,formatDate:Ht,formatNumber:bn};"iconOnError"in globalThis||(globalThis.iconOnError=Ll);class Ke{}function Da(e){ut=Object.assign({},ut,e)}function ja(t){Object.keys(t||{}).forEach(e=>{"function"==typeof t[e]&&(bt[e]=t[e])})}function Ls(){return bt}function tl(e,t){return t?rt("span",e,t):e}function Vs(e,t){var l=dt(t,["currency"]);return tl(new Intl.NumberFormat(void 0,{style:"currency",currency:(null==t?void 0:t.currency)||"USD"}).format(e),l)}function Ss(e,t){return tl(cn(e),t)}function Ms(e,t){return rt("a",e,Cl({...t,href:e}))}function As(e,t){return rt("a",e,Cl({...t,href:"tel:"+e}))}function Ts(e,t){var{subject:l,body:a}=t=t||{},t=dt(t,["subject","body"]),s={};return l&&(s.subject=l),a&&(s.body=a),rt("a",e,Cl({...t,href:"mailto:"+Kt(e,s)}))}function Fs(e,t){return rt("img",void 0,Object.assign({class:"w-6 h-6",title:e,src:Dt(e),onerror:"iconOnError(this)"},t))}function Is(e,t){return rt("img",void 0,Object.assign({class:"w-8 h-8 rounded-full",title:e,src:Dt(e),onerror:"iconOnError(this)"},t))}function Ds(e,t){var l=rn(e),a=(null==Yt(l)||dn(e)?Dt:fn)(e),a=Dt(a),s=t&&(t["icon-class"]||t.iconClass),a=rt("img",void 0,Object.assign({class:"w-6 h-6",src:a,onerror:"iconOnError(this,'att')"},s?{class:s}:null));return rt("a",a+`${l}`,Object.assign({class:"flex",href:Dt(e),title:e},t?dt(t,["icon-class","iconClass"]):null))}function js(e){return""}function Os(e,t){var l="string"==typeof e?new Date(1e3*Yn(e)):kl(e)?Vt(e):null;return tl(l?po(l):e,t)}function Ht(e,t){var l,a;return null==e?"":(l="number"==typeof e?new Date(e):"string"==typeof e?Vt(e):e,kl(l)?tl(("function"==typeof(a=ut.date?Al(ut.date):null)?a:Xn)(l),t):(console.warn(l+" is not a Date value"),null==e?"":""+e))}function bn(e,t){if("number"!=typeof e)return e;let l=ut.number?Al(ut.number):null,a="function"==typeof l?l(e):""+e;return""===a&&(console.warn(`formatNumber(${e}) => `+a,l),a=""+e),tl(a,t)}function Ps(t,l,a){var e=yo(t),s=l?Al(l):null;if("function"!=typeof s)return(null!=e?kl(e)?Ht(e,a):"number"==typeof e?bn(e,a):e:null)??"";{let e=a;if(null!=l&&l.options)try{e=sn(l.options,a)}catch(e){console.error(`Could not evaluate '${l.options}'`,e,", with scope:",a)}return s(t,e)}}function Jt(e,t,l){return(_t(e)?Ps:Ea)(e,t,l)}function Oa(e){if(null!=e){if("number"==typeof e)return e;if(kl(e))return e.getTime()-Wl();if("string"==typeof e){var t=Number(e);if(!isNaN(t))return t;if("P"===e[0]||e.startsWith("-P"))return 1e3*Yn(e)*-1;if(0<=bo(e,Fa))return Vt(e).getTime()-Wl()}}return NaN}function Ml(e,t){for(var l in Rl)if(Math.abs(e)>Rl[l]||"second"===l)return(t||Ia).format(Math.round(e/Rl[l]),l)}function wn(e,t){e=Oa(e);return isNaN(e)?"":Ml(e,t)}function Pa(e,t){return Ml(e.getTime()-(t?t.getTime():Wl()))}function Bs(e,t){return yn(e,t).join(", ")}function Al(l){if(l){let{method:e,options:a}=l,s=e+`(${a})`,n=bt[s]||bt[e];if("function"==typeof n)return n;let o=l.locale||ut.locale;if(e.startsWith("Intl.")){l=o?`'${o}'`:"undefined",l=`return new ${e}(${l},${a||"undefined"})`;try{let t=Function(l)();return n="Intl.DateTimeFormat"===e?e=>t.format(Vt(e)):"Intl.NumberFormat"===e?e=>t.format(Number(e)):"Intl.RelativeTimeFormat"===e?e=>wn(e,t):e=>t.format(e),bt[s]=n}catch(e){console.error("Invalid format: "+l,e)}}else{let l=globalThis[e];if("function"==typeof l){let t=null!=a?Function("return "+a)():void 0;return n=e=>l(e,t,o),bt[s]=n}console.error(`No '${e}' function exists`,Object.keys(bt))}}return null}function Rs(e,t){return e?e.length>t?e.substring(0,t)+"...":e:""}function Es(e){return"/Date("===e.substring(0,6)?Ht(Vt(e)):e}function Ba(e){return xn(Bt(e)).replace(/"/g,"")}function Hs(e){if(null==e||""===e)return"";if("string"==typeof e)try{return JSON.parse(e)}catch{console.warn("couldn't parse as JSON",e)}return e}function xn(e,t=4){return"object"!=typeof(e=Hs(e))?"string"==typeof e?e:""+e:JSON.stringify(e,void 0,t)}function Ra(e){return"object"!=typeof(e=Hs(e))?"string"==typeof e?e:""+e:xn(e=Bt(e=Object.assign({},e)))}function Bt(l){if(null==l)return null;if("string"==typeof l)return Es(l);if(_t(l))return l;if(l instanceof Date)return Ht(l);if(Array.isArray(l))return l.map(Bt);if("object"!=typeof l)return l;{let t={};return Object.keys(l).forEach(e=>{"__type"!=e&&(t[e]=Bt(l[e]))}),t}}function Ea(e,t,l){let a=e;if(Array.isArray(e)){if(_t(e[0]))return a.join(",");null!=e[0]&&(a=e[0])}if(null==a)return"";if(a instanceof Date)return Ht(a,l);var s=Object.keys(a),n=[];for(let e=0;e${o}: `+Hl(Rs(Es(r),ut.maxNestedFieldLength)))}return 2t.value.navigate(e.to??"/");return(e,t)=>(a(),u("a",Me({onClick:Ue(s,["prevent"]),title:l.to,href:"javascript:void(0)"},e.$attrs),[Z(e.$slots,"default")],16,Ha))}});class Na{constructor(){Ce(this,"callbacks",{})}register(e,t){this.callbacks[e]=t}has(e){return!!this.callbacks[e]}invoke(e,t){var l=this.callbacks[e];"function"==typeof l&&l(e,t)}}const Ye=class Ye{static component(e){var t=Ye.components[e];if(t)return t;const l=Nn(e),a=Object.keys(Ye.components).find(e=>Nn(e)===l);return a&&Ye.components[a]||null}};Ce(Ye,"config",{redirectSignIn:"/signin",redirectSignOut:"/auth/logout",navigate:e=>location.href=e,assetsPathResolver:e=>e,fallbackPathResolver:e=>e,storage:new ss,tableIcon:{svg:""},scopeWhitelist:{enumFlagsConverter:$s,...Ls()}}),Ce(Ye,"autoQueryGridDefaults",{deny:[],hide:[],toolbarButtonClass:void 0,tableStyle:"stripedRows",take:25,maxFieldLength:150}),Ce(Ye,"events",wo()),Ce(Ye,"user",A(null)),Ce(Ye,"metadata",A(null)),Ce(Ye,"components",{RouterLink:za}),Ce(Ye,"interceptors",new Na);let ne=Ye;function Ua(e){ne.config=Object.assign(ne.config,e)}function qa(e){ne.autoQueryGridDefaults=Object.assign(ne.autoQueryGridDefaults,e)}function kn(e){return e&&ne.config.assetsPathResolver?ne.config.assetsPathResolver(e):e}function Qa(e){return e&&ne.config.fallbackPathResolver?ne.config.fallbackPathResolver(e):e}function Ka(e,t){ne.interceptors.register(e,t)}function St(){var e=f(()=>ne.config),t=f(()=>ne.autoQueryGridDefaults);return{config:e,setConfig:Ua,events:ne.events,autoQueryGridDefaults:t,setAutoQueryGridDefaults:qa,assetsPathResolver:kn,fallbackPathResolver:Qa,registerInterceptor:Ka}}const zs=ce({inheritAttrs:!1,props:{image:Object,svg:String,src:String,alt:String,type:String},setup(s,{attrs:n}){return()=>{let e=s.image;var t,l;s.type&&(l=at()["typeOf"],(l=l(s.type))||console.warn(`Type ${s.type} does not exist`),null!=l&&l.icon?e=null==l?void 0:l.icon:console.warn(`Type ${s.type} does not have a [Svg] icon`));let a=s.svg||(null==e?void 0:e.svg)||"";return a.startsWith("").indexOf("class="),t=`${(null==e?void 0:e.cls)||""} `+(n.class||""),a=-1==l?`Ll(e.target)})}}}),Za={class:"text-2xl font-semibold text-gray-900 dark:text-gray-300"},Ga={class:"flex"},Wa=s("path",{d:"M100 50.5908C100 78.2051 77.6142 100.591 50 100.591C22.3858 100.591 0 78.2051 0 50.5908C0 22.9766 22.3858 0.59082 50 0.59082C77.6142 0.59082 100 22.9766 100 50.5908ZM9.08144 50.5908C9.08144 73.1895 27.4013 91.5094 50 91.5094C72.5987 91.5094 90.9186 73.1895 90.9186 50.5908C90.9186 27.9921 72.5987 9.67226 50 9.67226C27.4013 9.67226 9.08144 27.9921 9.08144 50.5908Z",fill:"currentColor"},null,-1),Ja=s("path",{d:"M93.9676 39.0409C96.393 38.4038 97.8624 35.9116 97.0079 33.5539C95.2932 28.8227 92.871 24.3692 89.8167 20.348C85.8452 15.1192 80.8826 10.7238 75.2124 7.41289C69.5422 4.10194 63.2754 1.94025 56.7698 1.05124C51.7666 0.367541 46.6976 0.446843 41.7345 1.27873C39.2613 1.69328 37.813 4.19778 38.4501 6.62326C39.0873 9.04874 41.5694 10.4717 44.0505 10.1071C47.8511 9.54855 51.7191 9.52689 55.5402 10.0491C60.8642 10.7766 65.9928 12.5457 70.6331 15.2552C75.2735 17.9648 79.3347 21.5619 82.5849 25.841C84.9175 28.9121 86.7997 32.2913 88.1811 35.8758C89.083 38.2158 91.5421 39.6781 93.9676 39.0409Z",fill:"currentFill"},null,-1),Xa=[Wa,Ja],Ya=ce({__name:"Loading",props:{imageClass:{default:"w-6 h-6"}},setup(l){return(e,t)=>(a(),u("div",Za,[s("div",Ga,[(a(),u("svg",{class:w(["self-center inline mr-2 text-gray-200 animate-spin dark:text-gray-600 fill-gray-600 dark:fill-gray-300",l.imageClass]),role:"status",viewBox:"0 0 100 101",fill:"none",xmlns:"http://www.w3.org/2000/svg"},Xa,2)),s("span",null,[Z(e.$slots,"default")])])]))}}),ei=["href","onClick"],ti=["type"],li=ce({__name:"OutlineButton",props:{type:{default:"submit"},href:null},setup(n){const o="inline-flex items-center px-4 py-2 border border-gray-300 dark:border-gray-600 shadow-sm text-sm font-medium rounded-md text-gray-700 dark:text-gray-200 disabled:text-gray-400 bg-white dark:bg-black hover:bg-gray-50 hover:dark:bg-gray-900 disabled:hover:bg-white dark:disabled:hover:bg-black focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500 dark:ring-offset-black";return(t,e)=>{var l=X("router-link");return n.href?(a(),se(l,{key:0,to:n.href},{default:ke(({navigate:e})=>[s("button",{class:w(o),href:n.href,onClick:e},[Z(t.$slots,"default")],8,ei)]),_:3},8,["to"])):(a(),u("button",Me({key:1,type:n.type,class:o},t.$attrs),[Z(t.$slots,"default")],16,ti))}}}),ni=["href","onClick"],si=["type"],oi=ce({__name:"PrimaryButton",props:{type:{default:"submit"},href:null,color:{default:"indigo"}},setup(n){const e=n,t={blue:"text-white bg-blue-600 hover:bg-blue-700 disabled:bg-blue-400 disabled:hover:bg-blue-400 focus:ring-indigo-500 dark:bg-blue-600 dark:hover:bg-blue-700 dark:focus:ring-blue-800",purple:"text-white bg-purple-600 hover:bg-purple-700 disabled:bg-purple-400 disabled:hover:bg-purple-400 focus:ring-indigo-500 dark:bg-blue-600 dark:hover:bg-blue-700 dark:focus:ring-blue-800",red:"focus:ring-red-500 text-white bg-red-600 hover:bg-red-700 disabled:bg-red-400 disabled:hover:bg-red-400 focus:ring-red-500 dark:bg-red-600 dark:hover:bg-red-700 dark:focus:ring-red-500",green:"focus:ring-green-300 text-white bg-green-600 hover:bg-green-700 disabled:bg-green-400 disabled:hover:bg-green-400 focus:ring-green-500 dark:bg-green-600 dark:hover:bg-green-700 dark:focus:ring-green-500",sky:"focus:ring-sky-300 text-white bg-sky-600 hover:bg-sky-700 disabled:bg-sky-400 disabled:hover:bg-sky-400 focus:ring-sky-500 dark:bg-sky-600 dark:hover:bg-sky-700 dark:focus:ring-sky-500",cyan:"focus:ring-cyan-300 text-white bg-cyan-600 hover:bg-cyan-700 disabled:bg-cyan-400 disabled:hover:bg-cyan-400 focus:ring-cyan-500 dark:bg-cyan-600 dark:hover:bg-cyan-700 dark:focus:ring-cyan-500",indigo:"focus:ring-2 focus:ring-offset-2 text-white bg-indigo-600 hover:bg-indigo-700 disabled:bg-indigo-400 disabled:hover:bg-indigo-400 focus:ring-indigo-500 dark:bg-blue-600 dark:hover:bg-blue-700 dark:focus:ring-blue-800"},r=f(()=>"inline-flex justify-center rounded-md border border-transparent py-2 px-4 text-sm font-medium shadow-sm focus:outline-none focus:ring-2 focus:ring-offset-2 dark:ring-offset-black "+(t[e.color]||t.indigo));return(t,e)=>{var l=X("router-link");return n.href?(a(),se(l,{key:0,to:n.href},{default:ke(({navigate:e})=>[s("button",{class:w(o(r)),href:n.href,onClick:e},[Z(t.$slots,"default")],10,ni)]),_:3},8,["to"])):(a(),u("button",Me({key:1,type:n.type,class:o(r)},t.$attrs),[Z(t.$slots,"default")],16,si))}}}),ai=["type","href","onClick"],ii=["type"],ri=ce({__name:"SecondaryButton",props:{type:null,href:null},setup(n){const o="inline-flex justify-center rounded-md border border-gray-300 py-2 px-4 text-sm font-medium shadow-sm focus:outline-none focus:ring-2 focus:ring-offset-2 bg-white dark:bg-gray-800 border-gray-300 dark:border-gray-600 text-gray-700 dark:text-gray-400 dark:hover:text-white hover:bg-gray-50 dark:hover:bg-gray-700 focus:ring-indigo-500 dark:focus:ring-indigo-600 dark:ring-offset-black";return(t,e)=>{var l=X("router-link");return n.href?(a(),se(l,{key:0,to:n.href},{default:ke(({navigate:e})=>[s("button",{type:n.type??"button",class:w(o),href:n.href,onClick:e},[Z(t.$slots,"default")],8,ai)]),_:3},8,["to"])):(a(),u("button",Me({key:1,type:n.type??"button",class:o},t.$attrs),[Z(t.$slots,"default")],16,ii))}}});function We(e,t){return Array.isArray(e)?0<=e.indexOf(t):e==t||e.includes(t)}const bl={blue:"text-blue-600 dark:text-blue-400 hover:text-blue-800 dark:hover:text-blue-200",purple:"text-purple-600 dark:text-purple-400 hover:text-purple-800 dark:hover:text-purple-200",red:"text-red-700 dark:text-red-400 hover:text-red-900 dark:hover:text-red-200",green:"text-green-600 dark:text-green-400 hover:text-green-800 dark:hover:text-green-200",sky:"text-sky-600 dark:text-sky-400 hover:text-sky-800 dark:hover:text-sky-200",cyan:"text-cyan-600 dark:text-cyan-400 hover:text-cyan-800 dark:hover:text-cyan-200",indigo:"text-indigo-600 dark:text-indigo-400 hover:text-indigo-800 dark:hover:text-indigo-200"},nt={base:"block w-full sm:text-sm rounded-md dark:text-white dark:bg-gray-900 disabled:bg-slate-50 disabled:text-slate-500 disabled:border-slate-200 disabled:shadow-none",invalid:"pr-10 border-red-300 text-red-900 placeholder-red-300 focus:outline-none focus:ring-red-500 focus:border-red-500",valid:"shadow-sm focus:ring-indigo-500 focus:border-indigo-500 border-gray-300 dark:border-gray-600"},qt={panelClass:"shadow sm:rounded-md",formClass:"space-y-6 bg-white dark:bg-black py-6 px-4 sm:p-6",headingClass:"text-lg font-medium leading-6 text-gray-900 dark:text-gray-100",subHeadingClass:"mt-1 text-sm text-gray-500 dark:text-gray-400"},It={panelClass:"pointer-events-auto w-screen xl:max-w-3xl md:max-w-xl max-w-lg",formClass:"flex h-full flex-col divide-y divide-gray-200 dark:divide-gray-700 shadow-xl bg-white dark:bg-black",titlebarClass:"bg-gray-50 dark:bg-gray-900 px-4 py-6 sm:px-6",headingClass:"text-lg font-medium text-gray-900 dark:text-gray-100",subHeadingClass:"mt-1 text-sm text-gray-500 dark:text-gray-400",closeButtonClass:"rounded-md bg-gray-50 dark:bg-gray-900 text-gray-400 dark:text-gray-500 hover:text-gray-500 dark:hover:text-gray-400 focus:outline-none focus:ring-2 focus:ring-indigo-500 dark:ring-offset-black"},Jl={modalClass:"relative transform overflow-hidden rounded-lg bg-white dark:bg-black text-left shadow-xl transition-all sm:my-8",sizeClass:"sm:max-w-prose lg:max-w-screen-md xl:max-w-screen-lg 2xl:max-w-screen-xl sm:w-full"},Ze={panelClass(e="slideOver"){return("card"==e?qt:It).panelClass},formClass(e="slideOver"){return("card"==e?qt:It).formClass},headingClass(e="slideOver"){return("card"==e?qt:It).headingClass},subHeadingClass(e="slideOver"){return("card"==e?qt:It).subHeadingClass},buttonsClass:"mt-4 px-4 py-3 bg-gray-50 dark:bg-gray-900 sm:px-6 flex flex-wrap justify-between",legendClass:"text-base font-medium text-gray-900 dark:text-gray-100 text-center mb-4"},ge={getGridClass(e=0){return ge.gridClass},getGrid2Class(e="stripedRows"){return We(e,"fullWidth")?"overflow-x-auto":ge.grid2Class},getGrid3Class(e="stripedRows"){return We(e,"fullWidth")?"inline-block min-w-full py-2 align-middle":ge.grid3Class},getGrid4Class(e="stripedRows"){return We(e,"whiteBackground")?"":We(e,"fullWidth")?"overflow-hidden shadow-sm ring-1 ring-black ring-opacity-5":ge.grid4Class},getTableClass(e="stripedRows"){return We(e,"fullWidth")||We(e,"verticalLines")?"min-w-full divide-y divide-gray-300":ge.tableClass},getTheadClass(e="stripedRows"){return We(e,"whiteBackground")?"":ge.theadClass},getTheadRowClass(e="stripedRows"){return ge.theadRowClass+(We(e,"verticalLines")?" divide-x divide-gray-200 dark:divide-gray-700":"")},getTheadCellClass(e="stripedRows"){return ge.theadCellClass+(We(e,"uppercaseHeadings")?" uppercase":"")},getTbodyClass(e="stripedRows"){return(We(e,"whiteBackground")||We(e,"verticalLines")?"divide-y divide-gray-200 dark:divide-gray-800":ge.tableClass)+(We(e,"verticalLines")?" bg-white":"")},getTableRowClass(e="stripedRows",t,l,a){return(a?"cursor-pointer ":"")+(l?"bg-indigo-100 dark:bg-blue-800":(a?"hover:bg-yellow-50 dark:hover:bg-blue-900 ":"")+(!We(e,"stripedRows")||t%2==0?"bg-white dark:bg-black":"bg-gray-50 dark:bg-gray-800"))+(We(e,"verticalLines")?" divide-x divide-gray-200 dark:divide-gray-700":"")},gridClass:"flex flex-col",grid2Class:"",grid3Class:"inline-block min-w-full py-2 align-middle",grid4Class:"overflow-hidden shadow ring-1 ring-black ring-opacity-5 md:rounded-lg",tableClass:"min-w-full divide-y divide-gray-200 dark:divide-gray-700",theadClass:"bg-gray-50 dark:bg-gray-900",tableCellClass:"px-6 py-4 whitespace-nowrap text-sm text-gray-500 dark:text-gray-400",theadRowClass:"select-none",theadCellClass:"px-6 py-4 text-left text-sm font-medium tracking-wider whitespace-nowrap",toolbarButtonClass:"inline-flex items-center px-2.5 py-1.5 border border-gray-300 dark:border-gray-700 shadow-sm text-sm font-medium rounded text-gray-700 dark:text-gray-300 bg-white dark:bg-black hover:bg-gray-50 dark:hover:bg-gray-900 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500 dark:ring-offset-black"},ui={colspans:"col-span-3 sm:col-span-3"},Lh=Object.freeze(Object.defineProperty({__proto__:null,a:bl,card:qt,dummy:ui,form:Ze,grid:ge,input:nt,modal:Jl,slideOver:It},Symbol.toStringTag,{value:"Module"})),di=ce({__name:"TextLink",props:{color:{default:"blue"}},setup(e){const t=e,l=so(),s=f(()=>(bl[t.color]||bl.blue)+(l.href?"":" cursor-pointer"));return(e,t)=>(a(),u("a",{class:w(o(s))},[Z(e.$slots,"default")],2))}}),ci={class:"flex","aria-label":"Breadcrumb"},fi={role:"list",class:"flex items-center space-x-4"},mi=["href","title"],vi=s("svg",{class:"h-6 w-6 flex-shrink-0",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true"},[s("path",{"fill-rule":"evenodd",d:"M9.293 2.293a1 1 0 011.414 0l7 7A1 1 0 0117 11h-1v6a1 1 0 01-1 1h-2a1 1 0 01-1-1v-3a1 1 0 00-1-1H9a1 1 0 00-1 1v3a1 1 0 01-1 1H5a1 1 0 01-1-1v-6H3a1 1 0 01-.707-1.707l7-7z","clip-rule":"evenodd"})],-1),hi={class:"sr-only"},gi=ce({__name:"Breadcrumbs",props:{homeHref:{default:"/"},homeLabel:{default:"Home"}},setup(l){return(e,t)=>(a(),u("nav",ci,[s("ol",fi,[s("li",null,[s("div",null,[s("a",{href:l.homeHref,class:"text-gray-400 dark:text-gray-500 hover:text-gray-500 dark:hover:text-gray-400",title:l.homeLabel},[vi,s("span",hi,T(l.homeLabel),1)],8,mi)])]),Z(e.$slots,"default")])]))}}),pi={class:"flex items-center"},yi=s("svg",{class:"h-6 w-6 flex-shrink-0 text-gray-400 dark:text-gray-500",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true"},[s("path",{"fill-rule":"evenodd",d:"M7.21 14.77a.75.75 0 01.02-1.06L11.168 10 7.23 6.29a.75.75 0 111.04-1.08l4.5 4.25a.75.75 0 010 1.08l-4.5 4.25a.75.75 0 01-1.06-.02z","clip-rule":"evenodd"})],-1),bi=["href","title"],wi=["title"],xi=ce({__name:"Breadcrumb",props:{href:null,title:null},setup(l){return(e,t)=>(a(),u("li",null,[s("div",pi,[yi,l.href?(a(),u("a",{key:0,href:l.href,class:"ml-4 text-lg font-medium text-gray-500 dark:text-gray-400 hover:text-gray-700 dark:hover:text-gray-300",title:l.title},[Z(e.$slots,"default")],8,bi)):(a(),u("span",{key:1,class:"ml-4 text-lg font-medium text-gray-700 dark:text-gray-300",title:l.title},[Z(e.$slots,"default")],8,wi))])]))}}),ki={key:0,class:"text-base font-semibold text-gray-500 dark:text-gray-400"},$i={role:"list",class:"mt-4 divide-y divide-gray-200 dark:divide-gray-800 border-t border-b border-gray-200 dark:border-gray-800"},Ci=ce({__name:"NavList",props:{title:null},setup(l){return(e,t)=>(a(),u("div",null,[l.title?(a(),u("h2",ki,T(l.title),1)):k("",!0),s("ul",$i,[Z(e.$slots,"default")])]))}}),_i={class:"relative flex items-start space-x-4 py-6"},Li={class:"flex-shrink-0"},Vi={class:"flex h-12 w-12 items-center justify-center rounded-lg bg-indigo-50 dark:bg-indigo-900"},Si={class:"min-w-0 flex-1"},Mi={class:"text-base font-medium text-gray-900 dark:text-gray-100"},Ai={class:"rounded-sm focus-within:ring-2 focus-within:ring-indigo-500 focus-within:ring-offset-2"},Ti=["href"],Fi=s("span",{class:"absolute inset-0","aria-hidden":"true"},null,-1),Ii={class:"text-base text-gray-500"},Di=s("div",{class:"flex-shrink-0 self-center"},[s("svg",{class:"h-5 w-5 text-gray-400",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true"},[s("path",{"fill-rule":"evenodd",d:"M7.21 14.77a.75.75 0 01.02-1.06L11.168 10 7.23 6.29a.75.75 0 111.04-1.08l4.5 4.25a.75.75 0 010 1.08l-4.5 4.25a.75.75 0 01-1.06-.02z","clip-rule":"evenodd"})])],-1),ji=ce({__name:"NavListItem",props:{title:null,href:null,icon:null,iconSvg:null,iconSrc:null,iconAlt:null},setup(n){return(e,t)=>{var l=X("Icon");return a(),u("li",_i,[s("div",Li,[s("span",Vi,[$e(l,{class:"w-6 h-6 text-indigo-700 dark:text-indigo-300",image:n.icon,src:n.iconSrc,svg:n.iconSvg,alt:n.iconAlt},null,8,["image","src","svg","alt"])])]),s("div",Si,[s("h3",Mi,[s("span",Ai,[s("a",{href:n.href,class:"focus:outline-none"},[Fi,we(" "+T(n.title),1)],8,Ti)])]),s("p",Ii,[Z(e.$slots,"default")])]),Di])}}});function Ns(e){return e&&e.SessionId?xo(e):e}function Oi(e){ne.user.value=Ns(e),ne.events.publish("signIn",e)}function Pi(){ne.user.value=null,ne.events.publish("signOut",null)}const $n=e=>(null==e?void 0:e.roles)||[],Cn=e=>(null==e?void 0:e.permissions)||[];function Us(e){return 0<=$n(ne.user.value).indexOf(e)}function Bi(e){return 0<=Cn(ne.user.value).indexOf(e)}function _n(){return Us("Admin")}function vl(e){if(!e)return!1;if(!e.requiresAuth)return!0;var t=ne.user.value;if(!t)return!1;if(_n())return!0;let[l,a]=[$n(t),Cn(t)],[s,n,o,r]=[e.requiredRoles||[],e.requiredPermissions||[],e.requiresAnyRole||[],e.requiresAnyPermission||[]];return!(!s.every(e=>0<=l.indexOf(e))||00<=l.indexOf(e))||!n.every(e=>0<=a.indexOf(e))||00<=a.indexOf(e)))}function Ri(e){if(!e||!e.requiresAuth)return null;var t=ne.user.value;if(!t)return`${e.request.name} requires Authentication`;if(_n())return null;let[l,a]=[$n(t),Cn(t)],[s,n,o,r]=[e.requiredRoles||[],e.requiredPermissions||[],e.requiresAnyRole||[],e.requiresAnyPermission||[]],i=s.filter(e=>l.indexOf(e)<0);return 0""+e+"").join(", ")} Role`+(1a.indexOf(e)<0)).length?`Requires ${t.map(e=>""+e+"").join(", ")} Permission`+(10<=l.indexOf(e))?`Requires any ${o.filter(e=>l.indexOf(e)<0).map(e=>""+e+"").join(", ")} Role`+(10<=a.indexOf(e))?`Requires any ${r.filter(e=>a.indexOf(e)<0).map(e=>""+e+"").join(", ")} Permission`+(1ne.user.value||null),toAuth:Ns,isAuthenticated:f(()=>null!=ne.user.value),hasRole:Us,hasPermission:Bi,isAdmin:_n,canAccess:vl,invalidAccessMessage:Ri}}const Ei={key:0},Hi={class:"md:p-4"},qs=ce({__name:"EnsureAccess",props:{invalidAccess:null,alertClass:null},emits:["done"],setup(r){const i=Ln()["isAuthenticated"],t=St()["config"],d=()=>{var e=location.href.substring(location.origin.length)||"/",e=Kt(t.value.redirectSignIn,{redirect:e});t.value.navigate(e)},c=()=>{var e=location.href.substring(location.origin.length)||"/",e=Kt(t.value.redirectSignOut,{ReturnUrl:e});t.value.navigate(e)};return(e,t)=>{var l=X("Alert"),n=X("SecondaryButton");return r.invalidAccess?(a(),u("div",Ei,[$e(l,{class:w(r.alertClass),innerHTML:r.invalidAccess},null,8,["class","innerHTML"]),s("div",Hi,[o(i)?(a(),se(n,{key:1,onClick:c},{default:ke(()=>[we("Sign Out")]),_:1})):(a(),se(n,{key:0,onClick:d},{default:ke(()=>[we("Sign In")]),_:1}))])])):k("",!0)}}}),zi={class:"absolute top-0 right-0 bg-white dark:bg-black border dark:border-gray-800 rounded normal-case text-sm shadow w-80"},Ni={class:"p-4"},Ui=s("h3",{class:"text-base font-medium mb-3 dark:text-gray-100"},"Sort",-1),qi={class:"flex w-full justify-center"},Qi=s("svg",{class:"w-6 h-6",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 16 16"},[s("g",{fill:"currentColor"},[s("path",{"fill-rule":"evenodd",d:"M10.082 5.629L9.664 7H8.598l1.789-5.332h1.234L13.402 7h-1.12l-.419-1.371h-1.781zm1.57-.785L11 2.687h-.047l-.652 2.157h1.351z"}),s("path",{d:"M12.96 14H9.028v-.691l2.579-3.72v-.054H9.098v-.867h3.785v.691l-2.567 3.72v.054h2.645V14zm-8.46-.5a.5.5 0 0 1-1 0V3.707L2.354 4.854a.5.5 0 1 1-.708-.708l2-1.999l.007-.007a.498.498 0 0 1 .7.006l2 2a.5.5 0 1 1-.707.708L4.5 3.707V13.5z"})])],-1),Ki=s("span",null,"ASC",-1),Zi=[Qi,Ki],Gi=wl('DESC',2),Wi=[Gi],Ji=s("h3",{class:"text-base font-medium mt-4 mb-2"}," Filter ",-1),Xi={key:0},Yi=["id","value"],er=["for"],tr={key:1},lr={class:"mb-2"},nr={class:"inline-flex rounded-full items-center py-0.5 pl-2.5 pr-1 text-sm font-medium bg-indigo-100 text-indigo-700"},sr=["onClick"],or=s("svg",{class:"h-2 w-2",stroke:"currentColor",fill:"none",viewBox:"0 0 8 8"},[s("path",{"stroke-linecap":"round","stroke-width":"1.5",d:"M1 1l6 6m0-6L1 7"})],-1),ar=[or],ir={class:"flex"},rr=s("svg",{class:"h-6 w-6",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true"},[s("path",{"fill-rule":"evenodd",d:"M10 5a1 1 0 011 1v3h3a1 1 0 110 2h-3v3a1 1 0 11-2 0v-3H6a1 1 0 110-2h3V6a1 1 0 011-1z","clip-rule":"evenodd"})],-1),ur=[rr],dr={class:"bg-gray-50 dark:bg-gray-900 px-4 py-3 sm:px-6 sm:flex sm:flex-row-reverse"},Vn=ce({__name:"FilterColumn",props:{definitions:null,column:null,topLeft:null},emits:["done","save"],setup(d,{emit:l}){const c=d,v=A(),p=A(""),m=A(""),g=A([]),y=f(()=>1==c.column.meta.isEnum),n=f(()=>ot("Nullable`1"===c.column.meta.type?c.column.meta.genericArgs[0]:c.column.meta.type)),h=f(()=>1==c.column.meta.isEnum?pn(ws(n.value.name)):[]),b=f(()=>{var e;return(null==(e=r(c.column.type))?void 0:e.map(e=>({key:e.value,value:e.name})))||[]}),x=A({filters:[]}),C=f(()=>x.value.filters);function r(e){let t=c.definitions;return t=gs(e)?t:t.filter(e=>"string"!==e.types)}function L(e,t){return r(e).find(e=>e.value===t)}function V(){var e;p.value&&(e=null==(e=L(c.column.type,p.value))?void 0:e.name)&&(x.value.filters.push({key:p.value,name:e,value:m.value}),p.value=m.value="")}function M(){l("done")}function S(){var e;p.value="%",null!=(e=v.value)&&e.focus()}function I(){var e,t;m.value&&V(),y.value&&(t=Object.values(g.value).filter(e=>e),x.value.filters=0parseInt(e)).reduce((e,t)=>e+t,0).toString()}]:[{key:"%In",name:"In",value:t.join(",")}]:[]),l("save",x.value),l("done")}function $(e){x.value.sort=e===x.value.sort?void 0:e,xt(I)}return hl(()=>x.value=Object.assign({},c.column.settings,{filters:Array.from(c.column.settings.filters)})),hl(()=>{var e;let t=(null==(e=null==(e=null==(e=c.column.settings.filters)?void 0:e[0])?void 0:e.value)?void 0:e.split(","))||[];if(00<(l&parseInt(e))))||[]}g.value=t}),(e,t)=>{var l=X("SelectInput"),n=X("TextInput"),r=X("PrimaryButton"),i=X("SecondaryButton");return a(),u("div",{class:"fixed z-20 inset-0 overflow-y-auto",onClick:M,onVnodeMounted:S},[s("div",{class:"absolute",style:Xl(`top:${d.topLeft.y}px;left:${d.topLeft.x}px`),onClick:t[5]||(t[5]=Ue(()=>{},["stop"]))},[s("div",zi,[s("div",Ni,[Ui,s("div",qi,[s("button",{type:"button",title:"Sort Ascending",onClick:t[0]||(t[0]=e=>$("ASC")),class:w(`${"ASC"===x.value.sort?"bg-indigo-100 border-indigo-500":"bg-white hover:bg-gray-50 border-gray-300"} mr-1 inline-flex items-center px-2.5 py-1.5 border shadow-sm text-sm font-medium rounded text-gray-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500`)},Zi,2),s("button",{type:"button",title:"Sort Descending",onClick:t[1]||(t[1]=e=>$("DESC")),class:w(`${"DESC"===x.value.sort?"bg-indigo-100 border-indigo-500":"bg-white hover:bg-gray-50 border-gray-300"} ml-1 inline-flex items-center px-2.5 py-1.5 border shadow-sm text-sm font-medium rounded text-gray-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500`)},Wi,2)]),Ji,o(y)?(a(),u("div",Xi,[(a(!0),u(Te,null,Ie(o(h),e=>(a(),u("div",{key:e.key,class:"flex items-center"},[kt(s("input",{type:"checkbox",id:e.key,value:e.key,"onUpdate:modelValue":t[2]||(t[2]=e=>g.value=e),class:"h-4 w-4 border-gray-300 rounded text-indigo-600 focus:ring-indigo-500"},null,8,Yi),[[Yl,g.value]]),s("label",{for:e.key,class:"ml-3"},T(e.value),9,er)]))),128))])):(a(),u("div",tr,[(a(!0),u(Te,null,Ie(o(C),(e,l)=>{return a(),u("div",lr,[s("span",nr,[we(T(d.column.name)+" "+T(e.name)+" "+T((e=e,_s(L(c.column.type,e.key),c.column.type,e)))+" ",1),s("button",{type:"button",onClick:e=>{var t;t=l,x.value.filters.splice(t,1)},class:"flex-shrink-0 ml-0.5 h-4 w-4 rounded-full inline-flex items-center justify-center text-indigo-400 hover:bg-indigo-200 hover:text-indigo-500 focus:outline-none focus:bg-indigo-500 focus:text-white"},ar,8,sr)])])}),256)),s("div",ir,[$e(l,{id:"filterRule",class:"w-32 mr-1",modelValue:p.value,"onUpdate:modelValue":t[3]||(t[3]=e=>p.value=e),entries:o(b),label:"",placeholder:""},null,8,["modelValue","entries"]),"none"!==(null==(l=L(d.column.type,p.value))?void 0:l.valueType)?(a(),se(n,{key:0,ref_key:"txtFilter",ref:v,id:"filterValue",class:"w-32 mr-1",type:"text",modelValue:m.value,"onUpdate:modelValue":t[4]||(t[4]=e=>m.value=e),onKeyup:Wn(V,["enter"]),label:"",placeholder:""},null,8,["modelValue","onKeyup"])):k("",!0),s("div",{class:"pt-1"},[s("button",{type:"button",onClick:V,class:"inline-flex items-center p-1 border border-transparent rounded-full shadow-sm text-white bg-indigo-600 hover:bg-indigo-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500"},ur)])])]))]),s("div",dr,[$e(r,{onClick:I,color:"red",class:"ml-2"},{default:ke(()=>[we(" Save ")]),_:1}),$e(i,{onClick:M},{default:ke(()=>[we(" Cancel ")]),_:1})])])],4)],512)}}}),cr={class:"px-4 sm:px-6 lg:px-8 text-sm"},fr={class:"flex flex-wrap"},mr={class:"group pr-4 sm:pr-6 lg:pr-8"},vr={class:"flex justify-between w-full font-medium"},hr={class:"w-6 flex justify-end"},gr={class:"hidden group-hover:inline"},pr=["onClick","title"],yr=s("svg",{class:"h-2 w-2",stroke:"currentColor",fill:"none",viewBox:"0 0 8 8"},[s("path",{"stroke-linecap":"round","stroke-width":"1.5",d:"M1 1l6 6m0-6L1 7"})],-1),br=[yr],wr={key:0,class:"pt-2"},xr={class:"ml-2"},kr={key:1},$r={class:"pt-2"},Cr={class:"inline-flex rounded-full items-center py-0.5 pl-2.5 pr-1 text-sm font-medium bg-indigo-100 text-indigo-700"},_r=["onClick"],Lr=s("svg",{class:"h-2 w-2",stroke:"currentColor",fill:"none",viewBox:"0 0 8 8"},[s("path",{"stroke-linecap":"round","stroke-width":"1.5",d:"M1 1l6 6m0-6L1 7"})],-1),Vr=[Lr],Sr=s("span",null,"Clear All",-1),Mr=[Sr],Sn=ce({__name:"FilterViews",props:{definitions:null,columns:null},emits:["done","change"],setup(e,{emit:r}){const l=e,n=f(()=>l.columns.filter(e=>0"string"!==e.types)}(e).find(e=>e.value===t)}function d(){l.columns.forEach(e=>{e.settings.filters=[],r("change",e)}),r("done")}return(e,t)=>(a(),u("div",cr,[s("div",fr,[(a(!0),u(Te,null,Ie(o(n),n=>{return a(),u("fieldset",mr,[s("legend",vr,[s("span",null,T(o(He)(n.name)),1),s("span",hr,[s("span",gr,[s("button",{onClick:e=>{var t;(t=n).settings.filters=[],r("change",t)},title:`Clear all ${o(He)(n.name)} filters`,class:"flex-shrink-0 ml-0.5 h-4 w-4 rounded-full inline-flex items-center justify-center text-red-600 hover:bg-red-200 hover:text-red-500 focus:outline-none focus:bg-red-500 focus:text-white"},br,8,pr)])])]),n.meta.isEnum?(a(),u("div",wr,[(a(!0),u(Te,null,Ie(null==(e=null==(e=null==(e=n.settings.filters)?void 0:e[0])?void 0:e.value)?void 0:e.split(","),e=>(a(),u("div",{key:e,class:"flex items-center"},[s("label",xr,T(e),1)]))),128))])):(a(),u("div",kr,[(a(!0),u(Te,null,Ie(n.settings.filters,(e,l)=>{return a(),u("div",$r,[s("span",Cr,[we(T(n.name)+" "+T(e.name)+" "+T((e=e,_s(i((t=n).type,e.value),t.type,e)))+" ",1),s("button",{type:"button",onClick:e=>{var t;(t=n).settings.filters.splice(l,1),r("change",t)},class:"flex-shrink-0 ml-0.5 h-4 w-4 rounded-full inline-flex items-center justify-center text-indigo-400 hover:bg-indigo-200 hover:text-indigo-500 focus:outline-none focus:bg-indigo-500 focus:text-white"},Vr,8,_r)])]);var t}),256))]))]);var e}),256))]),s("div",{class:"flex justify-center pt-4"},[s("button",{type:"button",onClick:d,class:"inline-flex items-center px-2.5 py-1.5 border border-gray-300 shadow-sm text-sm font-medium rounded text-gray-700 bg-white hover:bg-gray-50 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500"},Mr)])]))}}),Ar={class:"bg-white dark:bg-black px-4 pt-5 pb-4 sm:p-6 sm:pb-4"},Tr={class:""},Fr={class:"mt-3 text-center sm:mt-0 sm:mx-4 sm:text-left"},Ir=s("h3",{class:"text-lg leading-6 font-medium text-gray-900 dark:text-gray-100"},"Query Preferences",-1),Dr={class:"mt-4"},jr=["for"],Or=["id"],Pr=["value","selected"],Br={class:"mt-4 flex items-center py-4 border-b border-gray-200 dark:border-gray-800"},Rr=["id","checked"],Er=["for"],Hr={class:"mt-4"},zr={class:"pb-2 px-4"},Nr={class:""},Ur=["id","value"],qr=["for"],Qr={class:"bg-gray-50 dark:bg-gray-900 px-4 py-3 sm:px-6 sm:flex sm:flex-row-reverse"},Mn=ce({__name:"QueryPrefs",props:{id:{default:"QueryPrefs"},columns:null,prefs:null,maxLimit:null},emits:["done","save"],setup(r,{emit:e}){const i=r,t=St()["autoQueryGridDefaults"],d=A({}),c=(hl(()=>d.value=Object.assign({take:t.value.take,selectedColumns:[]},i.prefs)),[10,25,50,100,250,500,1e3]);function v(){e("done")}function f(){e("save",d.value)}return(e,t)=>{const l=X("PrimaryButton"),n=X("SecondaryButton"),o=X("ModalDialog");return a(),se(o,{id:r.id,onDone:v,"size-class":"w-full sm:max-w-prose"},{default:ke(()=>[s("div",Ar,[s("div",Tr,[s("div",Fr,[Ir,s("div",Dr,[s("label",{for:r.id+"-take",class:"block text-sm font-medium text-gray-700 dark:text-gray-300"},"Results per page",8,jr),kt(s("select",{id:r.id+"-take","onUpdate:modelValue":t[0]||(t[0]=e=>d.value.take=e),class:"mt-1 block w-full pl-3 pr-10 py-2 text-base bg-white dark:bg-black border-gray-300 dark:border-gray-700 focus:outline-none focus:ring-indigo-500 focus:border-indigo-500 sm:text-sm rounded-md"},[(a(!0),u(Te,null,Ie(c.filter(e=>null==i.maxLimit||e<=i.maxLimit),e=>(a(),u("option",{value:e,selected:e===d.value.take},T(e),9,Pr))),256))],8,Or),[[oo,d.value.take]])]),s("div",Br,[s("input",{type:"radio",id:r.id+"-allColumns",onClick:t[1]||(t[1]=e=>d.value.selectedColumns=[]),checked:0===d.value.selectedColumns.length,class:"focus:ring-indigo-500 h-4 w-4 bg-white dark:bg-black text-indigo-600 dark:text-indigo-400 border-gray-300 dark:border-gray-700"},null,8,Rr),s("label",{class:"ml-3 block text-gray-700 dark:text-gray-300",for:r.id+"-allColumns"},"View all columns",8,Er)]),s("div",Hr,[s("div",zr,[s("div",Nr,[(a(!0),u(Te,null,Ie(r.columns,e=>(a(),u("div",{key:e.name,class:"flex items-center"},[kt(s("input",{type:"checkbox",id:e.name,value:e.name,"onUpdate:modelValue":t[2]||(t[2]=e=>d.value.selectedColumns=e),class:"h-4 w-4 bg-white dark:bg-black border-gray-300 dark:border-gray-700 rounded text-indigo-600 dark:text-indigo-400 focus:ring-indigo-500"},null,8,Ur),[[Yl,d.value.selectedColumns]]),s("label",{for:e.name,class:"ml-3"},T(e.name),9,qr)]))),128))])])])])])]),s("div",Qr,[$e(l,{onClick:f,color:"red",class:"ml-2"},{default:ke(()=>[we(" Save ")]),_:1}),$e(n,{onClick:v},{default:ke(()=>[we(" Cancel ")]),_:1})])]),_:1},8,["id"])}}}),Kr={key:0},Zr={key:1},Gr={key:2,class:"pt-1"},Wr={key:0},Jr={key:1},Xr={key:3},Yr={class:"pl-1 pt-1 flex flex-wrap"},eu={class:"flex mt-1"},tu=["title"],lu=s("svg",{class:"w-8 h-8",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},[s("g",{"stroke-width":"1.5",fill:"none"},[s("path",{d:"M9 3H3.6a.6.6 0 0 0-.6.6v16.8a.6.6 0 0 0 .6.6H9M9 3v18M9 3h6M9 21h6m0-18h5.4a.6.6 0 0 1 .6.6v16.8a.6.6 0 0 1-.6.6H15m0-18v18",stroke:"currentColor"})])],-1),nu=[lu],su=["disabled"],ou=s("svg",{class:"w-8 h-8",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},[s("path",{d:"M18.41 16.59L13.82 12l4.59-4.59L17 6l-6 6l6 6zM6 6h2v12H6z",fill:"currentColor"})],-1),au=[ou],iu=["disabled"],ru=s("svg",{class:"w-8 h-8",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},[s("path",{d:"M15.41 7.41L14 6l-6 6l6 6l1.41-1.41L10.83 12z",fill:"currentColor"})],-1),uu=[ru],du=["disabled"],cu=s("svg",{class:"w-8 h-8",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},[s("path",{d:"M10 6L8.59 7.41L13.17 12l-4.58 4.59L10 18l6-6z",fill:"currentColor"})],-1),fu=[cu],mu=["disabled"],vu=s("svg",{class:"w-8 h-8",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},[s("path",{d:"M5.59 7.41L10.18 12l-4.59 4.59L7 18l6-6l-6-6zM16 6h2v12h-2z",fill:"currentColor"})],-1),hu=[vu],gu={key:0,class:"flex mt-1"},pu={class:"px-4 text-lg text-black dark:text-white"},yu={key:0},bu={key:1},wu=s("span",{class:"hidden xl:inline"}," Showing Results ",-1),xu={key:2},ku={class:"flex flex-wrap"},$u={key:0,class:"pl-2 mt-1"},Cu=s("svg",{class:"w-5 h-5",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},[s("path",{fill:"none",stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M20 20v-5h-5M4 4v5h5m10.938 2A8.001 8.001 0 0 0 5.07 8m-1.008 5a8.001 8.001 0 0 0 14.868 3"})],-1),_u=[Cu],Lu={key:1,class:"pl-2 mt-1"},Vu=wl('Excel',2),Su=[Vu],Mu={key:2,class:"pl-2 mt-1"},Au={key:0,class:"w-5 h-5 mr-1 text-green-600 dark:text-green-400",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Tu=s("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M5 13l4 4L19 7"},null,-1),Fu=[Tu],Iu={key:1,class:"w-5 h-5 mr-1",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Du=s("g",{fill:"none"},[s("path",{d:"M8 4v12a2 2 0 0 0 2 2h8a2 2 0 0 0 2-2V7.242a2 2 0 0 0-.602-1.43L16.083 2.57A2 2 0 0 0 14.685 2H10a2 2 0 0 0-2 2z",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"}),s("path",{d:"M16 18v2a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V9a2 2 0 0 1 2-2h2",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"})],-1),ju=[Du],Ou=s("span",{class:"whitespace-nowrap"},"Copy URL",-1),Pu={key:3,class:"pl-2 mt-1"},Bu=s("svg",{class:"w-5 h-5",xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true",viewBox:"0 0 24 24"},[s("path",{fill:"currentColor",d:"M6.78 2.72a.75.75 0 0 1 0 1.06L4.56 6h8.69a7.75 7.75 0 1 1-7.75 7.75a.75.75 0 0 1 1.5 0a6.25 6.25 0 1 0 6.25-6.25H4.56l2.22 2.22a.75.75 0 1 1-1.06 1.06l-3.5-3.5a.75.75 0 0 1 0-1.06l3.5-3.5a.75.75 0 0 1 1.06 0Z"})],-1),Ru=[Bu],Eu={key:4,class:"pl-2 mt-1"},Hu=s("svg",{class:"flex-none w-5 h-5 mr-2 text-gray-400 dark:text-gray-500 group-hover:text-gray-500","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor"},[s("path",{"fill-rule":"evenodd",d:"M3 3a1 1 0 011-1h12a1 1 0 011 1v3a1 1 0 01-.293.707L12 11.414V15a1 1 0 01-.293.707l-2 2A1 1 0 018 17v-5.586L3.293 6.707A1 1 0 013 6V3z","clip-rule":"evenodd"})],-1),zu={class:"mr-1"},Nu={key:0,class:"h-5 w-5 text-gray-400 dark:text-gray-500 group-hover:text-gray-500",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true"},Uu=s("path",{"fill-rule":"evenodd",d:"M10 5a1 1 0 011 1v3h3a1 1 0 110 2h-3v3a1 1 0 11-2 0v-3H6a1 1 0 110-2h3V6a1 1 0 011-1z","clip-rule":"evenodd"},null,-1),qu=[Uu],Qu={key:1,class:"h-5 w-5 text-gray-400 dark:text-gray-500 group-hover:text-gray-500",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true"},Ku=s("path",{"fill-rule":"evenodd",d:"M5 10a1 1 0 011-1h8a1 1 0 110 2H6a1 1 0 01-1-1z","clip-rule":"evenodd"},null,-1),Zu=[Ku],Gu={key:5,class:"pl-2 mt-1"},Wu=["title"],Ju=s("svg",{class:"w-5 h-5 mr-1 text-gray-500 dark:text-gray-400 hover:text-gray-900 dark:hover:text-gray-50",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},[s("path",{d:"M19 13h-6v6h-2v-6H5v-2h6V5h2v6h6v2z",fill:"currentColor"})],-1),Xu={class:"whitespace-nowrap"},Yu={key:7},ed={key:0,class:"cursor-pointer flex justify-between items-center hover:text-gray-900 dark:hover:text-gray-50"},td={class:"mr-1 select-none"},ld={key:1,class:"flex justify-between items-center"},nd={class:"mr-1 select-none"},sd=ce({__name:"AutoQueryGrid",props:{filterDefinitions:null,id:{default:"AutoQueryGrid"},apis:null,type:null,prefs:null,deny:null,hide:null,selectedColumns:null,toolbarButtonClass:null,tableStyle:null,gridClass:null,grid2Class:null,grid3Class:null,grid4Class:null,tableClass:null,theadClass:null,tbodyClass:null,theadRowClass:null,theadCellClass:null,headerTitle:null,headerTitles:null,visibleFrom:null,rowClass:null,rowStyle:null,apiPrefs:null,canFilter:null,disableKeyBindings:null,configureField:null,skip:{default:0},create:{type:Boolean},edit:null,filters:null},emits:["headerSelected","rowSelected"],setup(p,{expose:e,emit:v}){const r=p,{config:t,autoQueryGridDefaults:W}=St(),G=W,J=Ne("client"),l=t.value.storage,Y="filtering,queryString,queryFilters".split(","),ee="copyApiUrl,downloadCsv,filtersView,newItem,pagingInfo,pagingNav,preferences,refresh,resetPreferences,toolbar".split(","),te=f(()=>r.deny?wt(Y,r.deny):wt(Y,G.value.deny)),le=f(()=>r.hide?wt(ee,r.hide):wt(ee,G.value.hide));function m(e){return te.value[e]}function g(e){return le.value[e]}const y=f(()=>r.tableStyle??G.value.tableStyle),ae=f(()=>r.gridClass??ge.getGridClass(y.value)),oe=f(()=>r.grid2Class??ge.getGrid2Class(y.value)),re=f(()=>r.grid3Class??ge.getGrid3Class(y.value)),ie=f(()=>r.grid4Class??ge.getGrid4Class(y.value)),ue=f(()=>r.tableClass??ge.getTableClass(y.value)),de=f(()=>r.theadClass??ge.getTheadClass(y.value)),ce=f(()=>r.theadRowClass??ge.getTheadRowClass(y.value)),ve=f(()=>r.theadCellClass??ge.getTheadCellClass(y.value)),h=f(()=>r.toolbarButtonClass??ge.toolbarButtonClass);function fe(e,t){var l,a;return r.rowClass?r.rowClass(e,t):(l=!!q.value.AnyUpdate,a=(null!=(a=i.value)&&a.name?ye(e,i.value.name):null)==S.value,ge.getTableRowClass(r.tableStyle,t,a,l))}const b=en(),pe=f(()=>{var e;return st((null==(e=q.value.AnyQuery.viewModel)?void 0:e.name)||q.value.AnyQuery.dataModel.name)}),me=f(()=>{const t=Object.keys(b).map(e=>e.toLowerCase());return et(pe.value).filter(e=>t.includes(e.name.toLowerCase())||t.includes(e.name.toLowerCase()+"-header")).map(e=>e.name)});const x=f(()=>{var e=(0<(e=pt(r.selectedColumns)).length?e:0e.toLowerCase());const l=et(pe.value);return 0l.find(e=>e.name.toLowerCase()===t)).filter(e=>null!=e):l}),he=f(()=>{let e=x.value.map(e=>e.name),t=pt(O.value.selectedColumns).map(e=>e.toLowerCase());return 0t.includes(e.toLowerCase())):e}),C=A([]),L=A(new Je),be=A(new Je),V=A(),M=A(!1),S=A(),I=A(),$=A(!1),F=A(),B=A(r.skip),j=A(!1),O=A({take:25}),H=A(!1),xe=f(()=>C.value.some(e=>0C.value.map(e=>e.settings.filters.length).reduce((e,t)=>e+t,0)),Le=f(()=>{var e;return et(st(d.value||(null==(e=q.value.AnyQuery)?void 0:e.dataModel.name)))}),i=f(()=>{var e;return el(st(d.value||(null==(e=q.value.AnyQuery)?void 0:e.dataModel.name)))}),D=f(()=>O.value.take??25),E=f(()=>L.value.response?ye(L.value.response,"results"):[]),z=f(()=>{var e;return(null==(e=L.value.response)?void 0:e.total)??E.value.length??0}),Te=f(()=>00E.value.length>=D.value),Me=f(()=>E.value.length>=D.value),_=A(),R=A(),Se={NoQuery:"No Query API was found"};function Fe(t){if(t){if(r.canFilter)return r.canFilter(t);var e=Le.value.find(e=>e.name.toLowerCase()==t.toLowerCase());if(e)return!ps(e)}}function n(e){m("queryString")&&nn(e)}async function N(e){B.value+=e,B.value<0&&(B.value=0);e=Math.floor(z.value/D.value)*D.value;B.value>e&&(B.value=e),n({skip:B.value||void 0}),await P()}async function je(e,t){var l,a;I.value=null,S.value=t,e&&t&&(a=Gt(q.value.AnyQuery,{[e]:t}),(a=await J.api(a)).succeeded)&&((a=null==(a=ye(a.response,"results"))?void 0:a[0])||console.warn(`API ${null==(l=q.value.AnyQuery)?void 0:l.request.name}(${e}:${t}) returned no results`),I.value=a)}async function Oe(e,t){v("rowSelected",e,t);t=null==(t=i.value)?void 0:t.name,e=t?ye(e,t):null;t&&e&&(n({edit:e}),je(t,e))}function He(t,e){var l,a,s;m("filtering")&&(l=e.target,Fe(t)&&"TD"!==(null==l?void 0:l.tagName)&&(l=null==(l=null==l?void 0:l.closest("TABLE"))?void 0:l.getBoundingClientRect(),a=C.value.find(e=>e.name.toLowerCase()==t.toLowerCase()))&&l&&(s=l.x+318+10,F.value={column:a,topLeft:{x:Math.max(Math.floor(e.clientX+159),s),y:l.y+45}}),v("headerSelected",t,e))}function De(){F.value=null}async function Ee(e){var t=null==(t=F.value)?void 0:t.column;t&&(t.settings=e,l.setItem(c(t.name),JSON.stringify(t.settings)),await P()),F.value=null}async function ze(e){l.setItem(c(e.name),JSON.stringify(e.settings)),await P()}async function _e(e){$.value=!1,O.value=e,l.setItem(Ye(),JSON.stringify(e)),await P()}function Re(e){Object.assign(I.value,e),Pe()}function Pe(){null!=(e=_.value)&&e.forceUpdate(),null!=(e=R.value)&&e.forceUpdate();var e=Be();null!=(e=null==e?void 0:e.proxy)&&e.$forceUpdate()}async function P(){await Ue(qe())}async function Ze(){await P()}async function Ue(a){var s=q.value.AnyQuery;if(s){let e=Gt(s,a),t=es(e=>{L.value.response=L.value.error=void 0,H.value=e}),l=await J.api(e);t(),xt(()=>L.value=l);s=ye(l.response,"results")||[];l.succeeded&&s.label}else console.error(Se.NoQuery)}function qe(){let a={include:"total",take:D.value},t=pt(O.value.selectedColumns||r.selectedColumns);if(0{var e,l=s.find(e=>e.name.toLowerCase()==t.toLowerCase());null!=(e=null==l?void 0:l.ref)&&e.selfId&&n.push(l.ref.selfId),ye(b,t)&&n.push(...s.filter(e=>{return(null==(e=null==(e=e.ref)?void 0:e.selfId)?void 0:e.toLowerCase())==t.toLowerCase()}).map(e=>e.name))}),n.forEach(e=>{t.includes(e)||t.push(e)}),a.fields=t.join(",")}let e=[];if(C.value.forEach(l=>{l.settings.sort&&e.push(("DESC"===l.settings.sort?"-":"")+l.name),l.settings.filters.forEach(e=>{var t=e.key.replace("%",l.name);a[t]=e.value})}),r.filters&&Object.keys(r.filters).forEach(e=>{a[e]=r.filters[e]}),m("queryString")&&m("queryFilters")){var l=location.search||(location.hash.includes("?")?"?"+dl(location.hash,"?"):"");let e=zl(l);Object.keys(e).forEach(t=>{x.value.find(e=>e.name.toLowerCase()===t.toLowerCase())&&(a[t]=e[t])}),typeof e.skip<"u"&&(l=parseInt(e.skip),isNaN(l)||(B.value=a.skip=l))}return"u"j.value=!1,3e3)}function Ke(e="json"){var t=qe(),l="/api/"+(null==(l=q.value.AnyQuery)?void 0:l.request.name),l=ko(J.baseUrl,Kt(l,{...t,jsconfig:"edv"}));return 0<=l.indexOf("?")?xl(l,"?")+"."+e+"?"+dl(l,"?"):l+".json"}async function We(){C.value.forEach(e=>{e.settings={filters:[]},l.removeItem(c(e.name))}),O.value={take:25},l.removeItem(Ye()),await P()}function Ge(){M.value=!0,n({create:null})}e({update:P,search:Ue,createRequestArgs:qe,reset:bt,createDone:K,createSave:ht,editDone:Q,editSave:yt,forceUpdate:Pe,setEdit:Re,edit:I}),ne.interceptors.has("AutoQueryGrid.new")&&ne.interceptors.invoke("AutoQueryGrid.new",{props:r});const d=f(()=>Et(r.type)),U=f(()=>{var e;return d.value||(null==(e=q.value.AnyQuery)?void 0:e.dataModel.name)}),Ye=()=>{var e;return r.id+"/ApiPrefs/"+(d.value||(null==(e=q.value.AnyQuery)?void 0:e.dataModel.name))},c=e=>{var t;return`Column/${r.id}:${d.value||(null==(t=q.value.AnyQuery)?void 0:t.dataModel.name)}.`+e},{metadataApi:lt,typeOf:st,apiOf:nt,filterDefinitions:ot}=at(),rt=Ln()["invalidAccessMessage"],it=f(()=>r.filterDefinitions||ot.value),q=f(()=>{var e=pt(r.apis);return 0nt(e)).filter(e=>null!=e).map(e=>e)):Pt.forType(d.value,lt.value)}),ut=e=>`${e}`,dt=f(()=>{var e;return lt.value?0<(e=pt(r.apis).map(e=>null==nt(e)?e:null).filter(e=>null!=e)).length?ut(`Unknown API${1useMetadata()`)}),ct=f(()=>q.value.AnyQuery&&rt(q.value.AnyQuery)),vt=f(()=>q.value.Create&&rt(q.value.Create)),ft=f(()=>q.value.AnyUpdate&&rt(q.value.AnyUpdate)),mt=f(()=>vl(q.value.Create)),gt=(f(()=>vl(q.value.AnyUpdate)),f(()=>vl(q.value.Delete)));function Q(){I.value=null,S.value=null,n({edit:void 0})}function K(){M.value=!1,n({create:void 0})}async function yt(){await P(),Q()}async function ht(){await P(),K()}function bt(){L.value=new Je,be.value=new Je,M.value=!1,S.value=null,I.value=null,$.value=!1,F.value=null,B.value=r.skip,j.value=!1,O.value={take:25},H.value=!1;var e,t=r.prefs||yl(l.getItem(Ye())),t=(t&&(O.value=t),C.value=x.value.map(e=>({name:e.name,type:e.type,meta:e,settings:Object.assign({filters:[]},yl(l.getItem(c(e.name))))})),isNaN(r.skip)||(B.value=r.skip),null==(t=i.value)?void 0:t.name);m("queryString")&&(e=location.search||(location.hash.includes("?")?"?"+dl(location.hash,"?"):""),typeof(e=zl(e)).create<"u"?M.value=typeof e.create<"u":!t||"string"!=typeof e.edit&&"number"!=typeof e.edit||je(t,e.edit)),!0===r.create&&(M.value=!0),t&&null!=r.edit&&je(t,r.edit)}return tt(async()=>{bt(),await P()}),(l,e)=>{const t=X("Alert"),n=X("EnsureAccessDialog"),r=X("AutoCreateForm"),i=X("AutoEditForm"),d=X("ErrorSummary"),c=X("Loading"),v=X("SettingsIcons"),f=X("DataGrid");return o(dt)?(a(),u("div",Kr,[$e(t,{innerHTML:o(dt)},null,8,["innerHTML"])])):o(ct)?(a(),u("div",Zr,[$e(qs,{"invalid-access":o(ct)},null,8,["invalid-access"])])):(a(),u("div",Gr,[M.value&&o(q).Create?(a(),u("div",Wr,[o(vt)?(a(),se(n,{key:0,title:"Create "+o(U),"invalid-access":o(vt),"alert-class":"text-yellow-700",onDone:K},null,8,["title","invalid-access"])):o(b).createform?Z(l.$slots,"createform",{key:1,type:o(q).Create.request.name,configure:p.configureField,done:K,save:ht}):(a(),se(r,{key:2,ref_key:"createForm",ref:_,type:o(q).Create.request.name,configure:p.configureField,onDone:K,onSave:ht},{header:ke(()=>[Z(l.$slots,"formheader",{form:"create",formInstance:_.value,apis:o(q),type:o(U)})]),footer:ke(()=>[Z(l.$slots,"formfooter",{form:"create",formInstance:_.value,apis:o(q),type:o(U)})]),_:3},8,["type","configure"]))])):I.value&&o(q).AnyUpdate?(a(),u("div",Jr,[o(ft)?(a(),se(n,{key:0,title:"Update "+o(U),"invalid-access":o(ft),"alert-class":"text-yellow-700",onDone:Q},null,8,["title","invalid-access"])):o(b).editform?Z(l.$slots,"editform",{key:1,model:I.value,type:o(q).AnyUpdate.request.name,deleteType:o(gt)?o(q).Delete.request.name:null,configure:p.configureField,done:Q,save:yt}):(a(),se(i,{key:2,ref_key:"editForm",ref:R,modelValue:I.value,"onUpdate:modelValue":e[0]||(e[0]=e=>I.value=e),type:o(q).AnyUpdate.request.name,deleteType:o(gt)?o(q).Delete.request.name:null,configure:p.configureField,onDone:Q,onSave:yt,onDelete:yt},{header:ke(()=>[Z(l.$slots,"formheader",{form:"edit",formInstance:R.value,apis:o(q),type:o(U),model:I.value,id:S.value,updateModel:Re})]),footer:ke(()=>[Z(l.$slots,"formfooter",{form:"edit",formInstance:R.value,apis:o(q),type:o(U),model:I.value,id:S.value,updateModel:Re})]),_:3},8,["modelValue","type","deleteType","configure"]))])):k("",!0),o(b).toolbar?Z(l.$slots,"toolbar",{key:2}):g("toolbar")?(a(),u("div",Xr,[$.value?(a(),se(Mn,{key:0,columns:o(x),prefs:O.value,onDone:e[1]||(e[1]=e=>$.value=!1),onSave:_e},null,8,["columns","prefs"])):k("",!0),s("div",Yr,[s("div",eu,[g("preferences")?(a(),u("button",{key:0,type:"button",class:"text-gray-700 dark:text-gray-300 hover:text-indigo-600 dark:hover:text-indigo-400",title:o(U)+" Preferences",onClick:e[2]||(e[2]=e=>$.value=!$.value)},nu,8,tu)):k("",!0),g("pagingNav")?(a(),u("button",{key:1,type:"button",class:w(["pl-2",o(Te)?"text-gray-700 dark:text-gray-300 hover:text-indigo-600 dark:hover:text-indigo-400":"text-gray-400 dark:text-gray-500"]),title:"First page",disabled:!o(Te),onClick:e[3]||(e[3]=e=>N(-o(z)))},au,10,su)):k("",!0),g("pagingNav")?(a(),u("button",{key:2,type:"button",class:w(["pl-2",o(Ae)?"text-gray-700 dark:text-gray-300 hover:text-indigo-600 dark:hover:text-indigo-400":"text-gray-400 dark:text-gray-500"]),title:"Previous page",disabled:!o(Ae),onClick:e[4]||(e[4]=e=>N(-o(D)))},uu,10,iu)):k("",!0),g("pagingNav")?(a(),u("button",{key:3,type:"button",class:w(["pl-2",o(Ve)?"text-gray-700 dark:text-gray-300 hover:text-indigo-600 dark:hover:text-indigo-400":"text-gray-400 dark:text-gray-500"]),title:"Next page",disabled:!o(Ve),onClick:e[5]||(e[5]=e=>N(o(D)))},fu,10,du)):k("",!0),g("pagingNav")?(a(),u("button",{key:4,type:"button",class:w(["pl-2",o(Me)?"text-gray-700 dark:text-gray-300 hover:text-indigo-600 dark:hover:text-indigo-400":"text-gray-400 dark:text-gray-500"]),title:"Last page",disabled:!o(Me),onClick:e[6]||(e[6]=e=>N(o(z)))},hu,10,mu)):k("",!0)]),g("pagingInfo")?(a(),u("div",gu,[s("div",pu,[H.value?(a(),u("span",yu,"Querying...")):k("",!0),o(E).length?(a(),u("span",bu,[wu,we(" "+T(B.value+1)+" - "+T(Math.min(B.value+o(E).length,o(z)))+" ",1),s("span",null," of "+T(o(z)),1)])):L.value.completed?(a(),u("span",xu,"No Results")):k("",!0)])])):k("",!0),s("div",ku,[g("refresh")?(a(),u("div",$u,[s("button",{type:"button",onClick:Ze,title:"Refresh",class:w(o(h))},_u,2)])):k("",!0),g("downloadCsv")?(a(),u("div",Lu,[s("button",{type:"button",onClick:Xe,title:"Download CSV",class:w(o(h))},Su,2)])):k("",!0),g("copyApiUrl")?(a(),u("div",Mu,[s("button",{type:"button",onClick:Qe,title:"Copy API URL",class:w(o(h))},[j.value?(a(),u("svg",Au,Fu)):(a(),u("svg",Iu,ju)),Ou],2)])):k("",!0),o(xe)&&g("resetPreferences")?(a(),u("div",Pu,[s("button",{type:"button",onClick:We,title:"Reset Preferences & Filters",class:w(o(h))},Ru,2)])):k("",!0),g("filtersView")&&0V.value="filters"==V.value?null:"filters"),class:w(o(h)),"aria-expanded":"false"},[Hu,s("span",zu,T(o(Ce))+" "+T(1==o(Ce)?"Filter":"Filters"),1),"filters"!=V.value?(a(),u("svg",Nu,qu)):(a(),u("svg",Qu,Zu))],2)])):k("",!0),g("newItem")&&o(q).Create&&o(mt)?(a(),u("div",Gu,[s("button",{type:"button",onClick:Ge,title:o(U),class:w(o(h))},[Ju,s("span",Xu,"New "+T(o(U)),1)],10,Wu)])):k("",!0),o(b).toolbarbuttons?Z(l.$slots,"toolbarbuttons",{key:6,toolbarButtonClass:o(h)}):k("",!0)])])])):k("",!0),"filters"==V.value?(a(),se(Sn,{key:4,class:"border-y border-gray-200 dark:border-gray-800 py-8 my-2",definitions:o(it),columns:C.value,onDone:e[8]||(e[8]=e=>V.value=null),onChange:ze},null,8,["definitions","columns"])):k("",!0),be.value.error??L.value.error?(a(),se(d,{key:5,status:be.value.error??L.value.error},null,8,["status"])):H.value?(a(),se(c,{key:6,class:"p-2"})):k("",!0),F.value?(a(),u("div",Yu,[$e(Vn,{definitions:o(it),column:F.value.column,"top-left":F.value.topLeft,onDone:De,onSave:Ee},null,8,["definitions","column","top-left"])])):k("",!0),o(E).length?(a(),se(f,{key:8,id:p.id,items:o(E),type:p.type,"selected-columns":o(he),class:"mt-1",onFiltersChanged:P,tableStyle:o(y),gridClass:o(ae),grid2Class:o(oe),grid3Class:o(re),grid4Class:o(ie),tableClass:o(ue),theadClass:o(de),theadRowClass:o(ce),theadCellClass:o(ve),tbodyClass:p.tbodyClass,rowClass:fe,onRowSelected:Oe,rowStyle:p.rowStyle,headerTitle:p.headerTitle,headerTitles:p.headerTitles,visibleFrom:p.visibleFrom,onHeaderSelected:He},tn({header:ke(({column:t,label:e})=>{var l;return[m("filtering")&&Fe(t)?(a(),u("div",ed,[s("span",td,T(e),1),$e(v,{column:C.value.find(e=>e.name.toLowerCase()===t.toLowerCase()),"is-open":(null==(l=F.value)?void 0:l.column.name)===t},null,8,["column","is-open"])])):(a(),u("div",ld,[s("span",nd,T(e),1)]))]}),_:2},[Ie(Object.keys(o(b)),t=>({name:t,fn:ke(e=>[Z(l.$slots,t,jt(gl(e)))])}))]),1032,["id","items","type","selected-columns","tableStyle","gridClass","grid2Class","grid3Class","grid4Class","tableClass","theadClass","theadRowClass","theadCellClass","tbodyClass","rowStyle","headerTitle","headerTitles","visibleFrom"])):k("",!0)]))}}}),od={class:"flex"},ad={key:0,class:"w-4 h-4",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},id=s("g",{fill:"none"},[s("path",{d:"M3 4a1 1 0 0 1 1-1h16a1 1 0 0 1 1 1v2.586a1 1 0 0 1-.293.707l-6.414 6.414a1 1 0 0 0-.293.707V17l-4 4v-6.586a1 1 0 0 0-.293-.707L3.293 7.293A1 1 0 0 1 3 6.586V4z",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"})],-1),rd=[id],ud=s("path",{d:"M505.5 658.7c3.2 4.4 9.7 4.4 12.9 0l178-246c3.8-5.3 0-12.7-6.5-12.7H643c-10.2 0-19.9 4.9-25.9 13.2L512 558.6L406.8 413.2c-6-8.3-15.6-13.2-25.9-13.2H334c-6.5 0-10.3 7.4-6.5 12.7l178 246z",fill:"currentColor"},null,-1),dd=s("path",{d:"M880 112H144c-17.7 0-32 14.3-32 32v736c0 17.7 14.3 32 32 32h736c17.7 0 32-14.3 32-32V144c0-17.7-14.3-32-32-32zm-40 728H184V184h656v656z",fill:"currentColor"},null,-1),cd=[ud,dd],fd={key:2,class:"w-4 h-4",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20"},md=s("g",{fill:"none"},[s("path",{d:"M8.998 4.71L6.354 7.354a.5.5 0 1 1-.708-.707L9.115 3.18A.499.499 0 0 1 9.498 3H9.5a.5.5 0 0 1 .354.147l.01.01l3.49 3.49a.5.5 0 1 1-.707.707l-2.65-2.649V16.5a.5.5 0 0 1-1 0V4.71z",fill:"currentColor"})],-1),vd=[md],hd={key:3,class:"w-4 h-4",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20"},gd=s("g",{fill:"none"},[s("path",{d:"M10.002 15.29l2.645-2.644a.5.5 0 0 1 .707.707L9.886 16.82a.5.5 0 0 1-.384.179h-.001a.5.5 0 0 1-.354-.147l-.01-.01l-3.49-3.49a.5.5 0 1 1 .707-.707l2.648 2.649V3.5a.5.5 0 0 1 1 0v11.79z",fill:"currentColor"})],-1),pd=[gd],yd=ce({__name:"SettingsIcons",props:{column:null,isOpen:{type:Boolean}},setup(s){return(e,t)=>{var l;return a(),u("div",od,[null!=(l=null==(l=null==(l=s.column)?void 0:l.settings)?void 0:l.filters)&&l.length?(a(),u("svg",ad,rd)):(a(),u("svg",{key:1,class:w(["w-4 h-4 transition-transform",s.isOpen?"rotate-180":""]),xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},cd,2)),"ASC"===(null==(l=null==(l=s.column)?void 0:l.settings)?void 0:l.sort)?(a(),u("svg",fd,vd)):"DESC"===(null==(l=null==(l=s.column)?void 0:l.settings)?void 0:l.sort)?(a(),u("svg",hd,pd)):k("",!0)])}}}),bd=ce({__name:"EnsureAccessDialog",props:{title:null,subtitle:null,invalidAccess:null,alertClass:null},emits:["done"],setup(n){return(t,e)=>{const l=X("EnsureAccess"),s=X("SlideOver");return n.invalidAccess?(a(),se(s,{key:0,title:n.title,onDone:e[0]||(e[0]=e=>t.$emit("done")),"content-class":"relative flex-1"},tn({default:ke(()=>[$e(l,{alertClass:n.alertClass,invalidAccess:n.invalidAccess},null,8,["alertClass","invalidAccess"])]),_:2},[n.subtitle?{name:"subtitle",fn:ke(()=>[we(T(n.subtitle),1)]),key:"0"}:void 0]),1032,["title"])):k("",!0)}}}),wd=["for"],xd={class:"mt-1 relative rounded-md shadow-sm"},kd=["type","name","id","placeholder","value","aria-invalid","aria-describedby"],$d={key:0,class:"absolute inset-y-0 right-0 pr-3 flex items-center pointer-events-none"},Cd=s("svg",{class:"h-5 w-5 text-red-500",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true"},[s("path",{"fill-rule":"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7 4a1 1 0 11-2 0 1 1 0 012 0zm-1-9a1 1 0 00-1 1v4a1 1 0 102 0V6a1 1 0 00-1-1z","clip-rule":"evenodd"})],-1),_d=[Cd],Ld=["id"],Vd=["id"],Sd={inheritAttrs:!1},Md=ce({...Sd,__name:"TextInput",props:{status:null,id:null,type:null,inputClass:null,label:null,labelClass:null,help:null,placeholder:null,modelValue:null},setup(l,{expose:e}){const t=l,n=(e({focus:function(){var e;null!=(e=n.value)&&e.focus()}}),A());const r=f(()=>t.type||"text"),i=f(()=>t.label??He(st(t.id))),d=f(()=>t.placeholder??i.value);let c=Ne("ApiState",void 0);const v=f(()=>mt.call({responseStatus:t.status??(null==c?void 0:c.error.value)},t.id)),p=f(()=>[nt.base,v.value?nt.invalid:nt.valid,t.inputClass]);return(t,e)=>(a(),u("div",{class:w([t.$attrs.class])},[Z(t.$slots,"header",Me({inputElement:n.value,id:l.id,modelValue:l.modelValue,status:l.status},t.$attrs)),o(i)?(a(),u("label",{key:0,for:l.id,class:w("block text-sm font-medium text-gray-700 dark:text-gray-300 "+(l.labelClass??""))},T(o(i)),11,wd)):k("",!0),s("div",xd,[s("input",Me({ref_key:"inputElement",ref:n,type:o(r),name:l.id,id:l.id,class:o(p),placeholder:o(d),value:l.modelValue,onInput:e[0]||(e[0]=e=>t.$emit("update:modelValue",e.target.value)),"aria-invalid":null!=o(v),"aria-describedby":l.id+"-error",step:"any"},o(dt)(t.$attrs,["class"])),null,16,kd),o(v)?(a(),u("div",$d,_d)):k("",!0)]),o(v)?(a(),u("p",{key:1,class:"mt-2 text-sm text-red-500",id:l.id+"-error"},T(o(v)),9,Ld)):l.help?(a(),u("p",{key:2,class:"mt-2 text-sm text-gray-500",id:l.id+"-description"},T(l.help),9,Vd)):k("",!0),Z(t.$slots,"footer",Me({inputElement:n.value,id:l.id,modelValue:l.modelValue,status:l.status},t.$attrs))],2))}}),Ad=["for"],Td={class:"mt-1 relative rounded-md shadow-sm"},Fd=["name","id","placeholder","aria-invalid","aria-describedby"],Id=["id"],Dd=["id"],jd={inheritAttrs:!1},Od=ce({...jd,__name:"TextareaInput",props:{status:null,id:null,inputClass:null,label:null,labelClass:null,help:null,placeholder:null,modelValue:null},setup(l){const e=l,n=f(()=>e.label??He(st(e.id))),r=f(()=>e.placeholder??n.value);let t=Ne("ApiState",void 0);const i=f(()=>mt.call({responseStatus:e.status??(null==t?void 0:t.error.value)},e.id)),d=f(()=>["shadow-sm "+nt.base,i.value?"text-red-900 focus:ring-red-500 focus:border-red-500 border-red-300":"text-gray-900 "+nt.valid,e.inputClass]);return(t,e)=>(a(),u("div",{class:w([t.$attrs.class])},[o(n)?(a(),u("label",{key:0,for:l.id,class:w("block text-sm font-medium text-gray-700 dark:text-gray-300 "+(l.labelClass??""))},T(o(n)),11,Ad)):k("",!0),s("div",Td,[s("textarea",Me({name:l.id,id:l.id,class:o(d),placeholder:o(r),onInput:e[0]||(e[0]=e=>t.$emit("update:modelValue",e.target.value)),"aria-invalid":null!=o(i),"aria-describedby":l.id+"-error"},o(dt)(t.$attrs,["class"])),T(l.modelValue),17,Fd)]),o(i)?(a(),u("p",{key:1,class:"mt-2 text-sm text-red-500",id:l.id+"-error"},T(o(i)),9,Id)):l.help?(a(),u("p",{key:2,class:"mt-2 text-sm text-gray-500",id:l.id+"-description"},T(l.help),9,Dd)):k("",!0)],2))}}),Pd=["for"],Bd=["id","name","value","aria-invalid","aria-describedby"],Rd=["value"],Ed=["id"],Hd={inheritAttrs:!1},zd=ce({...Hd,__name:"SelectInput",props:{status:null,id:null,modelValue:null,inputClass:null,label:null,labelClass:null,options:null,values:null,entries:null},setup(l){const t=l,n=f(()=>t.label??He(st(t.id)));let e=Ne("ApiState",void 0);const r=f(()=>mt.call({responseStatus:t.status??(null==e?void 0:e.error.value)},t.id)),i=f(()=>t.entries||(t.values?t.values.map(e=>({key:e,value:e})):t.options?Object.keys(t.options).map(e=>({key:e,value:t.options[e]})):[]));return(t,e)=>(a(),u("div",{class:w([t.$attrs.class])},[o(n)?(a(),u("label",{key:0,for:l.id,class:w("block text-sm font-medium text-gray-700 dark:text-gray-300 "+(l.labelClass??""))},T(o(n)),11,Pd)):k("",!0),s("select",Me({id:l.id,name:l.id,class:["mt-1 block w-full pl-3 pr-10 py-2 text-base focus:outline-none sm:text-sm rounded-md dark:text-white dark:bg-gray-900 dark:border-gray-600",o(r)?"border-red-300 text-red-900 focus:ring-red-500 focus:border-red-500":"border-gray-300 text-gray-900 focus:ring-indigo-500 focus:border-indigo-500",l.inputClass],value:l.modelValue,onInput:e[0]||(e[0]=e=>t.$emit("update:modelValue",e.target.value)),"aria-invalid":null!=o(r),"aria-describedby":l.id+"-error"},o(dt)(t.$attrs,["class"])),[(a(!0),u(Te,null,Ie(o(i),e=>(a(),u("option",{value:e.key},T(e.value),9,Rd))),256))],16,Bd),o(r)?(a(),u("p",{key:1,class:"mt-2 text-sm text-red-500",id:l.id+"-error"},T(o(r)),9,Ed)):k("",!0)],2))}}),Nd={class:"flex items-center h-5"},Ud=["id","name","checked"],qd={class:"ml-3 text-sm"},Qd=["for"],Kd={key:0,class:"mt-2 text-sm text-red-500",id:"`${id}-error`"},Zd={key:1,class:"mt-2 text-sm text-gray-500",id:"`${id}-description`"},Gd={inheritAttrs:!1},Wd=ce({...Gd,__name:"CheckboxInput",props:{modelValue:{type:Boolean},status:null,id:null,inputClass:null,label:null,labelClass:null,help:null},emits:["update:modelValue"],setup(l,{}){const e=l,n=f(()=>e.label??He(st(e.id)));let t=Ne("ApiState",void 0);const r=f(()=>mt.call({responseStatus:e.status??(null==t?void 0:t.error.value)},e.id));return(t,e)=>(a(),u("div",{class:w(["relative flex items-start",t.$attrs.class])},[s("div",Nd,[s("input",Me({id:l.id,name:l.id,type:"checkbox",checked:l.modelValue,onInput:e[0]||(e[0]=e=>t.$emit("update:modelValue",e.target.checked)),class:["focus:ring-indigo-500 h-4 w-4 text-indigo-600 rounded border-gray-300 dark:border-gray-600 dark:bg-gray-800",l.inputClass]},o(dt)(t.$attrs,["class"])),null,16,Ud)]),s("div",qd,[s("label",{for:l.id,class:w("font-medium text-gray-700 dark:text-gray-300 "+(l.labelClass??""))},T(o(n)),11,Qd),o(r)?(a(),u("p",Kd,T(o(r)),1)):l.help?(a(),u("p",Zd,T(l.help),1)):k("",!0)])],2))}}),Jd=["id"],Xd=["for"],Yd={class:"mt-1 relative rounded-md shadow-sm"},ec=["id","name","value"],tc=["onClick"],lc={class:"flex flex-wrap pb-1.5"},nc={class:"pt-1.5 pl-1"},sc={class:"inline-flex rounded-full items-center py-0.5 pl-2.5 pr-1 text-sm font-medium bg-indigo-100 dark:bg-indigo-800 text-indigo-700 dark:text-indigo-300"},oc=["onClick"],ac=s("svg",{class:"h-2 w-2",stroke:"currentColor",fill:"none",viewBox:"0 0 8 8"},[s("path",{"stroke-linecap":"round","stroke-width":"1.5",d:"M1 1l6 6m0-6L1 7"})],-1),ic=[ac],rc={class:"pt-1.5 pl-1 shrink"},uc=["type","name","id","aria-invalid","aria-describedby","onPaste"],dc=["id"],cc=["onMouseover","onClick"],fc={class:"block truncate"},mc={key:1,class:"absolute inset-y-0 right-0 pr-3 flex items-center pointer-events-none"},vc=s("svg",{class:"h-5 w-5 text-red-500",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true"},[s("path",{"fill-rule":"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7 4a1 1 0 11-2 0 1 1 0 012 0zm-1-9a1 1 0 00-1 1v4a1 1 0 102 0V6a1 1 0 00-1-1z","clip-rule":"evenodd"})],-1),hc=[vc],gc=["id"],pc=["id"],yc={inheritAttrs:!1},bc=ce({...yc,__name:"TagInput",props:{status:null,id:null,type:null,inputClass:null,label:null,labelClass:null,help:null,modelValue:{default:()=>[]},delimiters:{default:()=>[","]},allowableValues:null,string:{type:Boolean},converter:null},emits:["update:modelValue"],setup(l,{emit:t}){const n=l;const r=f(()=>{return qe((e=n.modelValue,n.converter?n.converter(e):e),e=>"string"==typeof e?0==e.trim().length?[]:e.split(","):e)||[];var e}),i=A(),d=A(!1),c=f(()=>n.allowableValues&&0!=n.allowableValues.length?n.allowableValues.filter(e=>!r.value.includes(e)&&e.toLowerCase().includes(p.value.toLowerCase())):[]);const v=A(null),p=A(""),m=f(()=>n.type||"text"),g=f(()=>n.label??He(st(n.id)));let e=Ne("ApiState",void 0);const y=f(()=>mt.call({responseStatus:n.status??(null==e?void 0:e.error.value)},n.id)),h=f(()=>["w-full cursor-text flex flex-wrap sm:text-sm rounded-md dark:text-white dark:bg-gray-900 border focus-within:border-transparent focus-within:ring-1 focus-within:outline-none",y.value?"pr-10 border-red-300 text-red-900 placeholder-red-300 focus-within:outline-none focus-within:ring-red-500 focus-within:border-red-500":"shadow-sm border-gray-300 dark:border-gray-600 focus-within:ring-indigo-500 focus-within:border-indigo-500",n.inputClass]),b=t=>M(r.value.filter(e=>e!=t));function x(e){document.activeElement===e.target&&null!=(e=v.value)&&e.focus()}const C=A();function L(){d.value=!0,C.value=!0}function V(){O(I()),C.value=!1,setTimeout(()=>{C.value||(d.value=!1)},200)}function M(e){e=n.string?e.join(","):e;t("update:modelValue",e)}function S(e){var t;"Backspace"==e.key&&0==p.value.length&&0e==t.key))&&t.preventDefault(),"Enter"==t.key||"NumpadEnter"==t.key||1==t.key.length&&e)&&O(l)}const F={behavior:"smooth",block:"nearest",inline:"nearest",scrollMode:"if-needed"};function B(){setTimeout(()=>{var e=pl(`#${n.id}-tag li.active`);e&&e.scrollIntoView(F)},0)}function j(){setTimeout(()=>{var e=pl(`#${n.id}-tag li.active`);e&&("scrollIntoViewIfNeeded"in e?e.scrollIntoViewIfNeeded(F):e.scrollIntoView(F))},0)}function O(e){var t;0!==e.length&&(-1==(t=Array.from(r.value)).indexOf(e)&&t.push(e),M(t),p.value="",d.value=!1)}function H(e){e=null==(e=e.clipboardData)?void 0:e.getData("Text");if(e){const t=new RegExp("\\n|\\t|"+n.delimiters.join("|")),l=Array.from(r.value);e.split(t).map(e=>e.trim()).forEach(e=>{-1==l.indexOf(e)&&l.push(e)}),M(l),p.value=""}}return(e,t)=>(a(),u("div",{class:w([e.$attrs.class]),id:l.id+"-tag",onmousemove:"cancelBlur=true"},[o(g)?(a(),u("label",{key:0,for:l.id,class:w("block text-sm font-medium text-gray-700 dark:text-gray-300 "+(l.labelClass??""))},T(o(g)),11,Xd)):k("",!0),s("div",Yd,[s("input",{type:"hidden",id:l.id,name:l.id,value:o(r).join(",")},null,8,ec),s("button",{class:w(o(h)),onClick:Ue(x,["prevent"]),onFocus:t[2]||(t[2]=e=>d.value=!0),tabindex:"-1"},[s("div",lc,[(a(!0),u(Te,null,Ie(o(r),t=>(a(),u("div",nc,[s("span",sc,[we(T(t)+" ",1),s("button",{type:"button",onClick:e=>b(t),class:"flex-shrink-0 ml-1 h-4 w-4 rounded-full inline-flex items-center justify-center text-indigo-400 dark:text-indigo-500 hover:bg-indigo-200 dark:hover:bg-indigo-800 hover:text-indigo-500 dark:hover:text-indigo-400 focus:outline-none focus:bg-indigo-500 focus:text-white dark:focus:text-black"},ic,8,oc)])]))),256)),s("div",rc,[kt(s("input",Me({ref_key:"txtInput",ref:v,type:o(m),role:"combobox","aria-controls":"options","aria-expanded":"false",autocomplete:"off",spellcheck:"false",name:l.id+"-txt",id:l.id+"-txt",class:"p-0 dark:bg-transparent rounded-md border-none focus:!border-none focus:!outline-none",style:`box-shadow:none !important;width:${p.value.length+1}ch`,"onUpdate:modelValue":t[0]||(t[0]=e=>p.value=e),"aria-invalid":null!=o(y),"aria-describedby":l.id+"-error",onKeydown:S,onKeypress:$,onPaste:Ue(H,["prevent","stop"]),onFocus:L,onBlur:V,onClick:t[1]||(t[1]=e=>d.value=!0)},o(dt)(e.$attrs,["class","required"])),null,16,uc),[[ao,p.value]])])])],42,tc),d.value&&o(c).length?(a(),u("ul",{key:0,class:"absolute z-10 mt-1 max-h-60 w-full overflow-auto rounded-md bg-white dark:bg-black py-1 text-base shadow-lg ring-1 ring-black ring-opacity-5 focus:outline-none sm:text-sm",onKeydown:S,id:l.id+"-options",role:"listbox"},[(a(!0),u(Te,null,Ie(o(c),l=>(a(),u("li",{class:w([l===i.value?"active bg-indigo-600 text-white":"text-gray-900 dark:text-gray-100","relative cursor-default select-none py-2 pl-3 pr-9"]),onMouseover:e=>{var t;t=l,i.value=t},onClick:e=>O(l),role:"option",tabindex:"-1"},[s("span",fc,T(l),1)],42,cc))),256))],40,dc)):k("",!0),o(y)?(a(),u("div",mc,hc)):k("",!0)]),o(y)?(a(),u("p",{key:1,class:"mt-2 text-sm text-red-500",id:l.id+"-error"},T(o(y)),9,gc)):l.help?(a(),u("p",{key:2,class:"mt-2 text-sm text-gray-500",id:l.id+"-description"},T(l.help),9,pc)):k("",!0)],10,Jd))}}),wc={class:"relative flex-grow mr-2 sm:mr-4"},xc=["for"],kc={class:"block mt-2"},$c={class:"sr-only"},Cc=["multiple","name","id","placeholder","aria-invalid","aria-describedby"],_c={key:0,class:"absolute inset-y-0 right-0 pr-3 flex items-center pointer-events-none"},Lc=s("svg",{class:"h-5 w-5 text-red-500",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true"},[s("path",{"fill-rule":"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7 4a1 1 0 11-2 0 1 1 0 012 0zm-1-9a1 1 0 00-1 1v4a1 1 0 102 0V6a1 1 0 00-1-1z","clip-rule":"evenodd"})],-1),Vc=[Lc],Sc=["id"],Mc=["id"],Ac={key:0},Tc=["title"],Fc=["alt","src"],Ic={key:1,class:"mt-3"},Dc={class:"w-full"},jc={class:"pr-6 align-bottom pb-2"},Oc=["title"],Pc=["src","onError"],Bc=["href"],Rc={key:1,class:"overflow-hidden"},Ec={class:"align-top pb-2 whitespace-nowrap"},Hc={key:0,class:"text-gray-500 dark:text-gray-400 text-sm bg-white dark:bg-black"},zc=ce({__name:"FileInput",props:{multiple:{type:Boolean},status:null,id:null,inputClass:null,label:null,labelClass:null,help:null,placeholder:null,modelValue:null,values:null,files:null},setup(l){var e;const t=l,n=A(null),{assetsPathResolver:r,fallbackPathResolver:i}=St(),d={},c=A(),v=A((null==(e=t.files)?void 0:e.map(p))||[]);function p(e){return e.filePath=r(e.filePath),e}t.values&&0{e=e.replace(/\\/g,"/");return{fileName:Co($t(e,"/"),"."),filePath:e,contentType:Kl(e)}}).map(p));const m=f(()=>t.label??He(st(t.id))),g=f(()=>t.placeholder??m.value);let y=Ne("ApiState",void 0);const h=f(()=>mt.call({responseStatus:t.status??(null==y?void 0:y.error.value)},t.id)),b=f(()=>["block w-full sm:text-sm rounded-md dark:text-white dark:bg-gray-900 file:mr-4 file:py-2 file:px-4 file:rounded-full file:border-0 file:text-sm file:font-semibold file:bg-violet-50 dark:file:bg-violet-900 file:text-violet-700 dark:file:text-violet-200 hover:file:bg-violet-100 dark:hover:file:bg-violet-800",h.value?"pr-10 border-red-300 text-red-900 placeholder-red-300 focus:outline-none focus:ring-red-500 focus:border-red-500":"text-slate-500 dark:text-slate-400",t.inputClass]),x=e=>{e=e.target;c.value="",v.value=Array.from(e.files||[]).map(e=>({fileName:e.name,filePath:un(e),contentLength:e.size,contentType:e.type||Kl(e.name)}))},C=()=>{var e;return null==(e=n.value)?void 0:e.click()},L=e=>null!=e&&(e.startsWith("data:")||e.startsWith("blob:")),V=f(()=>{var e;return 0!e||e.startsWith("data:")||e.endsWith(".svg")?"":"rounded-full object-cover";function S(e){c.value=i(V.value)}return Rt(fs),(e,t)=>(a(),u("div",{class:w(["flex",l.multiple?"flex-col":"justify-between"])},[s("div",wc,[o(m)?(a(),u("label",{key:0,for:l.id,class:w("block text-sm font-medium text-gray-700 dark:text-gray-300 "+(l.labelClass??""))},T(o(m)),11,xc)):k("",!0),s("div",kc,[s("span",$c,T(l.help??o(m)),1),s("input",Me({ref_key:"input",ref:n,type:"file",multiple:l.multiple,name:l.id,id:l.id,class:o(b),placeholder:o(g),"aria-invalid":null!=o(h),"aria-describedby":l.id+"-error"},e.$attrs,{onChange:x}),null,16,Cc),o(h)?(a(),u("div",_c,Vc)):k("",!0)]),o(h)?(a(),u("p",{key:1,class:"mt-2 text-sm text-red-500",id:l.id+"-error"},T(o(h)),9,Sc)):l.help?(a(),u("p",{key:2,class:"mt-2 text-sm text-gray-500",id:l.id+"-description"},T(l.help),9,Mc)):k("",!0)]),l.multiple?(a(),u("div",Ic,[s("table",Dc,[(a(!0),u(Te,null,Ie(v.value,t=>(a(),u("tr",null,[s("td",jc,[s("div",{class:"flex w-full",title:L(t.filePath)?"":t.filePath},[s("img",{src:d[o(yt)(t.filePath)]||o(r)(o(yt)(t.filePath)),class:w(["mr-2 h-8 w-8",M(t.filePath)]),onError:e=>d[o(yt)(t.filePath)]=o(i)(o(yt)(t.filePath))},null,42,Pc),L(t.filePath)?(a(),u("span",Rc,T(t.fileName),1)):(a(),u("a",{key:0,href:o(r)(t.filePath||""),target:"_blank",class:"overflow-hidden"},T(t.fileName),9,Bc))],8,Oc)]),s("td",Ec,[t.contentLength&&0[]},modelValue:null,match:null,viewCount:{default:100},pageSize:{default:8}},emits:["update:modelValue"],setup(l,{expose:e,emit:n}){const r=l,i=A(!1);function d(e){return Array.isArray(r.modelValue)&&0<=r.modelValue.indexOf(e)}e({toggle:B});const c=f(()=>r.label??He(st(r.id)));let t=Ne("ApiState",void 0);const v=f(()=>mt.call({responseStatus:r.status??(null==t?void 0:t.error.value)},r.id)),p=f(()=>[nt.base,v.value?nt.invalid:nt.valid]),m=A(null),g=A(""),y=A(null),h=A(r.viewCount),b=A([]),x=f(()=>g.value?r.options.filter(e=>r.match(e,g.value)).slice(0,h.value):r.options),C=["Tab","Escape","ArrowDown","ArrowUp","Enter","PageUp","PageDown","Home","End"];const L=[",",` `,"\t"];function V(t){var l=null==(t=t.clipboardData)?void 0:t.getData("Text");if(l){t=L.some(e=>l.includes(e));if(r.multiple&&t){if(t){t=new RegExp("\\r|\\n|\\t|,"),t=l.split(t).filter(e=>e.trim()).map(t=>r.options.find(e=>r.match(e,t))).filter(e=>!!e);if(0{d(t)?e=e.filter(e=>e!=t):e.push(t)}),n("update:modelValue",e),cl()}}}else{t=r.options.filter(e=>r.match(e,l));1==t.length&&(O(t[0]),i.value=!1,cl())}}}function M(e){C.indexOf(e.code)||j()}function S(e){var t;e.shiftKey||e.ctrlKey||e.altKey||(i.value?"Escape"==e.code?i.value&&(e.stopPropagation(),i.value=!1):"Tab"==e.code?i.value=!1:"Home"==e.code?(y.value=b.value[0],$()):"End"==e.code?(y.value=b.value[b.value.length-1],$()):"ArrowDown"==e.code?(y.value?(t=b.value.indexOf(y.value),y.value=t+1{var e=pl(`#${r.id}-autocomplete li.active`);e&&e.scrollIntoView(I)},0)}function F(){setTimeout(()=>{var e=pl(`#${r.id}-autocomplete li.active`);e&&("scrollIntoViewIfNeeded"in e?e.scrollIntoViewIfNeeded(I):e.scrollIntoView(I))},0)}function B(e){(i.value=e)&&(j(),null!=(e=m.value))&&e.focus()}function j(){i.value=!0,H()}function O(t){if(g.value="",i.value=!1,r.multiple){let e=Array.from(r.modelValue||[]);d(t)?e=e.filter(e=>e!=t):e.push(t),y.value=null,n("update:modelValue",e)}else{let e=t;r.modelValue==t&&(e=null),n("update:modelValue",e)}}function H(){b.value=x.value}return Lt(g,H),(e,t)=>(a(),u("div",{id:l.id+"-autocomplete"},[o(c)?(a(),u("label",{key:0,for:l.id+"-text",class:"block text-sm font-medium text-gray-700 dark:text-gray-300"},T(o(c)),9,Uc)):k("",!0),s("div",qc,[kt(s("input",Me({ref_key:"txtInput",ref:m,id:l.id+"-text",type:"text",role:"combobox","aria-controls":"options","aria-expanded":"false",autocomplete:"off",spellcheck:"false","onUpdate:modelValue":t[0]||(t[0]=e=>g.value=e),class:o(p),placeholder:l.multiple||!l.modelValue?l.placeholder:"",onFocus:j,onKeydown:S,onKeyup:M,onClick:j,onPaste:V,required:!1},e.$attrs),null,16,Qc),[[io,g.value]]),s("button",{type:"button",onClick:t[1]||(t[1]=e=>B(!i.value)),class:"absolute inset-y-0 right-0 flex items-center rounded-r-md px-2 focus:outline-none",tabindex:"-1"},Zc),i.value?(a(),u("ul",{key:0,class:"absolute z-10 mt-1 max-h-60 w-full overflow-auto rounded-md bg-white dark:bg-black py-1 text-base shadow-lg ring-1 ring-black ring-opacity-5 focus:outline-none sm:text-sm",onKeydown:S,id:l.id+"-options",role:"listbox"},[(a(!0),u(Te,null,Ie(b.value,l=>(a(),u("li",{class:w([l===y.value?"active bg-indigo-600 text-white":"text-gray-900 dark:text-gray-100","relative cursor-default select-none py-2 pl-3 pr-9"]),onMouseover:e=>{return t=l,y.value=t,void(b.value.indexOf(t)>Math.floor(.9*h.value)&&(h.value+=r.viewCount,H()));var t},onClick:e=>O(l),role:"option",tabindex:"-1"},[Z(e.$slots,"item",jt(gl(l))),d(l)?(a(),u("span",{key:0,class:w(["absolute inset-y-0 right-0 flex items-center pr-4",l===y.value?"text-white":"text-indigo-600"])},Xc,2)):k("",!0)],42,Wc))),256))],40,Gc)):!l.multiple&&l.modelValue?(a(),u("div",{key:1,onKeydown:S,onClick:t[2]||(t[2]=e=>B(!i.value)),class:"h-8 -mt-8 ml-3 pt-0.5"},[Z(e.$slots,"item",jt(gl(l.modelValue)))],32)):k("",!0),o(v)?(a(),u("div",Yc,t0)):k("",!0)]),o(v)?(a(),u("p",{key:1,class:"mt-2 text-sm text-red-500",id:l.id+"-error"},T(o(v)),9,l0)):l.help?(a(),u("p",{key:2,class:"mt-2 text-sm text-gray-500",id:l.id+"-description"},T(l.help),9,n0)):k("",!0)],8,Nc))}}),o0=["id","name","value"],a0={class:"block truncate"},i0=ce({__name:"Combobox",props:{id:null,modelValue:null,multiple:{type:Boolean},options:null,values:null,entries:null},emits:["update:modelValue"],setup(n,{expose:e,emit:t}){const l=n;function r(e){t("update:modelValue",e)}e({toggle(e){var t;null!=(t=d.value)&&t.toggle(e)}});const i=f(()=>null!=l.multiple?l.multiple:Array.isArray(l.modelValue)),d=A();function c(e,t){return!t||e.value.toLowerCase().includes(t.toLowerCase())}const v=f(()=>l.entries||(l.values?l.values.map(e=>({key:e,value:e})):l.options?Object.keys(l.options).map(e=>({key:e,value:l.options[e]})):[])),p=A(i.value?[]:null);tt(function(){let t=l.modelValue&&"object"==typeof l.modelValue?l.modelValue.key:l.modelValue;null==t||""===t?p.value=i.value?[]:null:"string"==typeof t?p.value=v.value.find(e=>e.key===t)||null:Array.isArray(t)&&(p.value=v.value.filter(e=>t.includes(e.key)))});const m=f(()=>null==p.value?"":Array.isArray(p.value)?p.value.map(e=>encodeURIComponent(e.key)).join(","):p.value.key);return(e,t)=>{var l=X("Autocomplete");return a(),u(Te,null,[s("input",{type:"hidden",id:n.id,name:n.id,value:o(m)},null,8,o0),$e(l,Me({ref_key:"input",ref:d,id:n.id,options:o(v),match:c,multiple:o(i)},e.$attrs,{modelValue:p.value,"onUpdate:modelValue":[t[0]||(t[0]=e=>p.value=e),r]}),{item:ke(({value:e})=>[s("span",a0,T(e),1)]),_:1},16,["id","options","multiple","modelValue"])],64)}}}),r0=ce({__name:"DynamicInput",props:{input:null,modelValue:null,api:null},emits:["update:modelValue"],setup(p,{emit:e}){const l=p,m=f(()=>l.input.type||"text"),t="ignore,css,options,meta,allowableValues,allowableEntries,op,prop,type,id,name".split(","),g=f(()=>dt(l.input,t)),y=A(qe(l.modelValue[l.input.id],e=>"file"===l.input.type?null:"date"===l.input.type&&e instanceof Date?$l(e):"time"===l.input.type?ls(e):e)),h=(Lt(y,()=>{l.modelValue[l.input.id]=y.value,e("update:modelValue",l.modelValue)}),f(()=>{var e=l.modelValue[l.input.id];if("file"!==l.input.type||!e)return[];if("string"==typeof e)return[{filePath:e,fileName:$t(e,"/")}];if(!Array.isArray(e)&&"object"==typeof e)return e;if(Array.isArray(e)){const t=[];return e.forEach(e=>{"string"==typeof e?t.push({filePath:e,fileName:$t(e,"/")}):"object"==typeof e&&t.push(e)}),t}}));return(e,t)=>{var l,s=X("SelectInput"),n=X("CheckboxInput"),r=X("TagInput"),i=X("Combobox"),u=X("FileInput"),d=X("TextareaInput"),c=X("MarkdownInput"),v=X("TextInput");return o(ne).component(o(m))?(a(),se(Jn(o(ne).component(o(m))),Me({key:0,id:p.input.id,modelValue:y.value,"onUpdate:modelValue":t[0]||(t[0]=e=>y.value=e),status:null==(l=p.api)?void 0:l.error,"input-class":null==(l=p.input.css)?void 0:l.input,"label-class":null==(l=p.input.css)?void 0:l.label},o(g)),null,16,["id","modelValue","status","input-class","label-class"])):"select"==o(m)?(a(),se(s,Me({key:1,id:p.input.id,modelValue:y.value,"onUpdate:modelValue":t[1]||(t[1]=e=>y.value=e),status:null==(l=p.api)?void 0:l.error,"input-class":null==(s=p.input.css)?void 0:s.input,"label-class":null==(l=p.input.css)?void 0:l.label,entries:p.input.allowableEntries,values:p.input.allowableValues},o(g)),null,16,["id","modelValue","status","input-class","label-class","entries","values"])):"checkbox"==o(m)?(a(),se(n,Me({key:2,id:p.input.id,modelValue:y.value,"onUpdate:modelValue":t[2]||(t[2]=e=>y.value=e),status:null==(s=p.api)?void 0:s.error,"input-class":null==(l=p.input.css)?void 0:l.input,"label-class":null==(n=p.input.css)?void 0:n.label},o(g)),null,16,["id","modelValue","status","input-class","label-class"])):"tag"==o(m)?(a(),se(r,Me({key:3,id:p.input.id,modelValue:y.value,"onUpdate:modelValue":t[3]||(t[3]=e=>y.value=e),status:null==(s=p.api)?void 0:s.error,"input-class":null==(l=p.input.css)?void 0:l.input,"label-class":null==(n=p.input.css)?void 0:n.label,allowableValues:p.input.allowableValues,string:"String"==(null==(r=p.input.prop)?void 0:r.type)},o(g)),null,16,["id","modelValue","status","input-class","label-class","allowableValues","string"])):"combobox"==o(m)?(a(),se(i,Me({key:4,id:p.input.id,modelValue:y.value,"onUpdate:modelValue":t[4]||(t[4]=e=>y.value=e),status:null==(s=p.api)?void 0:s.error,"input-class":null==(l=p.input.css)?void 0:l.input,"label-class":null==(n=p.input.css)?void 0:n.label,entries:p.input.allowableEntries,values:p.input.allowableValues},o(g)),null,16,["id","modelValue","status","input-class","label-class","entries","values"])):"file"==o(m)?(a(),se(u,Me({key:5,id:p.input.id,status:null==(r=p.api)?void 0:r.error,modelValue:y.value,"onUpdate:modelValue":t[5]||(t[5]=e=>y.value=e),"input-class":null==(i=p.input.css)?void 0:i.input,"label-class":null==(s=p.input.css)?void 0:s.label,files:o(h)},o(g)),null,16,["id","status","modelValue","input-class","label-class","files"])):"textarea"==o(m)?(a(),se(d,Me({key:6,id:p.input.id,modelValue:y.value,"onUpdate:modelValue":t[6]||(t[6]=e=>y.value=e),status:null==(l=p.api)?void 0:l.error,"input-class":null==(n=p.input.css)?void 0:n.input,"label-class":null==(u=p.input.css)?void 0:u.label},o(g)),null,16,["id","modelValue","status","input-class","label-class"])):"MarkdownInput"==o(m)?(a(),se(c,Me({key:7,id:p.input.id,modelValue:y.value,"onUpdate:modelValue":t[7]||(t[7]=e=>y.value=e),status:null==(r=p.api)?void 0:r.error,"input-class":null==(i=p.input.css)?void 0:i.input,"label-class":null==(s=p.input.css)?void 0:s.label},o(g)),null,16,["id","modelValue","status","input-class","label-class"])):(a(),se(v,Me({key:8,type:o(m),id:p.input.id,modelValue:y.value,"onUpdate:modelValue":t[8]||(t[8]=e=>y.value=e),status:null==(d=p.api)?void 0:d.error,"input-class":null==(l=p.input.css)?void 0:l.input,"label-class":null==(n=p.input.css)?void 0:n.label},o(g)),null,16,["type","id","modelValue","status","input-class","label-class"]))}}}),u0={class:"lookup-field"},d0=["name","value"],c0={key:0,class:"flex justify-between"},f0=["for"],m0={key:0,class:"flex items-center"},v0={class:"text-sm text-gray-500 dark:text-gray-400 pr-1"},h0=s("span",{class:"sr-only"},"Clear",-1),g0=s("svg",{class:"h-4 w-4",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor","aria-hidden":"true"},[s("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M6 18L18 6M6 6l12 12"})],-1),p0=[h0,g0],y0={key:1,class:"mt-1 relative"},b0={class:"w-full inline-flex truncate"},w0={class:"text-blue-700 dark:text-blue-300 flex cursor-pointer"},x0=s("span",{class:"absolute inset-y-0 right-0 flex items-center pr-2 pointer-events-none"},[s("svg",{class:"h-5 w-5 text-gray-400 dark:text-gray-500",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true"},[s("path",{"fill-rule":"evenodd",d:"M10 3a1 1 0 01.707.293l3 3a1 1 0 01-1.414 1.414L10 5.414 7.707 7.707a1 1 0 01-1.414-1.414l3-3A1 1 0 0110 3zm-3.707 9.293a1 1 0 011.414 0L10 14.586l2.293-2.293a1 1 0 011.414 1.414l-3 3a1 1 0 01-1.414 0l-3-3a1 1 0 010-1.414z","clip-rule":"evenodd"})])],-1),k0=["id"],$0=["id"],C0=ce({__name:"LookupInput",props:{id:null,status:null,input:null,metadataType:null,modelValue:null,label:null,labelClass:null,help:null},emits:["update:modelValue"],setup(r,{emit:i}){const d=r,t=St()["config"],n=at()["metadataApi"],c=f(()=>d.id||d.input.id),v=f(()=>d.label??He(st(c.value)));let e=Ne("ApiState",void 0);const p=Ne("client"),m=f(()=>mt.call({responseStatus:d.status??(null==e?void 0:e.error.value)},c.value)),g=A(""),y=A(""),h=f(()=>ye(d.modelValue,c.value)),b=f(()=>et(d.metadataType).find(e=>e.name.toLowerCase()==c.value.toLowerCase())),x=f(()=>{var e;return(null==(e=ot(null==(e=null==(e=b.value)?void 0:e.ref)?void 0:e.model))?void 0:e.icon)||t.value.tableIcon});let C;function L(){d.modelValue[c.value]=null,g.value=""}return tt(async()=>{C=Ne("ModalProvider",void 0);var t,l=d.modelValue;d.modelValue[c.value]||(d.modelValue[c.value]=null);const a=b.value,s=null==a?void 0:a.ref;if(s){g.value="";let e=null==s.selfId?ye(l,a.name):ye(l,s.selfId);null==(e=Zt(e)?ye(l,s.refId):e)||null==(null==(t=n.value)?void 0:t.operations.find(e=>{return(null==(e=e.dataModel)?void 0:e.name)==s.model}))||Zt(t=ye(l,a.name))||(g.value=""+t,y.value=a.name,null!=s.refLabel&&(null==(t=et(d.metadataType).find(e=>e.type==s.model))&&console.warn(`Could not find ${s.model} Property on `+d.metadataType.name),null!=(l=null!=t?ye(l,t.name):null)?(t=ye(l,s.refLabel))&&(g.value=""+t,Ft.setValue(s.model,e,s.refLabel,t)):(t=1==(null==(l=a.attributes)?void 0:l.some(e=>"Computed"==e.name)),l=await Ft.getOrFetchValue(p,n.value,s.model,s.refId,s.refLabel,t,e),g.value=l||s.model+": "+g.value)))}else console.warn(`No RefInfo for property '${c.value}'`)}),(e,t)=>{var l,n=X("Icon");return a(),u("div",u0,[s("input",{type:"hidden",name:o(c),value:o(h)},null,8,d0),o(v)?(a(),u("div",c0,[s("label",{for:o(c),class:w("block text-sm font-medium text-gray-700 dark:text-gray-300 "+(r.labelClass??""))},T(o(v)),11,f0),o(h)?(a(),u("div",m0,[s("span",v0,T(o(h)),1),s("button",{onClick:L,type:"button",title:"clear",class:"mr-1 rounded-md text-gray-400 dark:text-gray-500 hover:text-gray-500 dark:hover:text-gray-400 focus:outline-none focus:ring-2 focus:ring-indigo-500 dark:ring-offset-black"},p0)])):k("",!0)])):k("",!0),null!=(l=o(b))&&l.ref?(a(),u("div",y0,[s("button",{type:"button",class:"lookup flex relative w-full bg-white dark:bg-black border border-gray-300 dark:border-gray-700 rounded-md shadow-sm pl-3 pr-10 py-2 text-left focus:outline-none focus:ring-1 focus:ring-indigo-500 focus:border-indigo-500 sm:text-sm",onClick:t[0]||(t[0]=e=>{var l;(l=o(b).ref)&&(null==C?console.warn("No ModalProvider required by LookupInput"):C.openModal({name:"ModalLookup",ref:l},e=>{var t;console.debug("openModal",g.value," -> ",e,Ft.setRefValue(l,e),l),e&&(t=ye(e,l.refId),g.value=Ft.setRefValue(l,e)||t,(e=o(d.modelValue))[c.value]=t,i("update:modelValue",e))}))}),"aria-haspopup":"listbox","aria-expanded":"true","aria-labelledby":"listbox-label"},[s("span",b0,[s("span",w0,[$e(n,{class:"mr-1 w-5 h-5",image:o(x)},null,8,["image"]),s("span",null,T(g.value),1)])]),x0])])):k("",!0),o(m)?(a(),u("p",{key:2,class:"mt-2 text-sm text-red-500",id:o(c)+"-error"},T(o(m)),9,k0)):r.help?(a(),u("p",{key:3,class:"mt-2 text-sm text-gray-500",id:o(c)+"-description"},T(r.help),9,$0)):k("",!0)])}}}),_0=ce({__name:"AutoFormFields",props:{modelValue:null,type:null,api:null,formLayout:null,configureField:null,configureFormLayout:null,hideSummary:{type:Boolean},flexClass:{default:"flex flex-1 flex-col justify-between"},divideClass:{default:"divide-y divide-gray-200 px-4 sm:px-6"},spaceClass:{default:"space-y-6 pt-6 pb-5"},fieldsetClass:{default:"grid grid-cols-12 gap-6"}},emits:["update:modelValue"],setup(d,{expose:e,emit:l}){const r=d;function n(){var e=Be();null!=(e=null==e?void 0:e.proxy)&&e.$forceUpdate()}function c(e,t){r.modelValue[e]=t,l("update:modelValue",r.modelValue),n()}e({forceUpdate:n,props:r,updateValue:c});const{metadataApi:t,apiOf:i,typeOf:v,typeOfRef:p,createFormLayout:m}=at(),g=f(()=>r.type||Et(r.modelValue)),y=f(()=>v(g.value)),h=f(()=>{var e;return p(null==(e=null==(e=t.value)?void 0:e.operations.find(e=>e.request.name==g.value))?void 0:e.dataModel)||y.value}),b=f(()=>{var e,t=y.value;if(!t){if(r.formLayout)return e=r.formLayout.map(e=>{var t={name:e.id,type:ba(e.type)},t=Object.assign({prop:t},e);return r.configureField&&r.configureField(t),t}),r.configureFormLayout&&r.configureFormLayout(e),e;throw new Error(`MetadataType for ${g.value} not found`)}const a=et(t),s=h.value,l=r.formLayout||m(t),n=[],o=i(t.name);return l.forEach(t=>{var e,l=a.find(e=>e.name==t.name);t.ignore||(e=(null==(e=null==s?void 0:s.properties)?void 0:e.find(e=>{return e.name.toLowerCase()==(null==(e=t.name)?void 0:e.toLowerCase())}))??l,l=Object.assign({prop:e,op:o},t),r.configureField&&r.configureField(l),n.push(l))}),r.configureFormLayout&&r.configureFormLayout(n),n}),x=f(()=>b.value.filter(e=>"hidden"!=e.type).map(e=>e.id));return(l,n)=>{var e;const t=X("ErrorSummary"),r=X("LookupInput"),i=X("DynamicInput");return a(),u(Te,null,[d.hideSummary?k("",!0):(a(),se(t,{key:0,status:null==(e=d.api)?void 0:e.error,except:o(x)},null,8,["status","except"])),s("div",{class:w(d.flexClass)},[s("div",{class:w(d.divideClass)},[s("div",{class:w(d.spaceClass)},[s("fieldset",{class:w(d.fieldsetClass)},[(a(!0),u(Te,null,Ie(o(b),t=>{var e;return a(),u("div",{key:t.id,class:w(["w-full",(null==(e=t.css)?void 0:e.field)??("textarea"==t.type?"col-span-12":"col-span-12 xl:col-span-6"+("checkbox"==t.type?" flex items-center":"")),"hidden"==t.type?"hidden":""])},[null==(null==(e=t.prop)?void 0:e.ref)||"file"==t.type||t.prop.isPrimaryKey?(a(),se(i,{key:1,input:t,modelValue:d.modelValue,"onUpdate:modelValue":n[0]||(n[0]=e=>l.$emit("update:modelValue",e)),api:d.api},null,8,["input","modelValue","api"])):(a(),se(r,{key:0,metadataType:o(h),input:t,modelValue:d.modelValue,"onUpdate:modelValue":e=>{c(t.id,ye(e,t.id))},status:null==(e=d.api)?void 0:e.error},null,8,["metadataType","input","modelValue","onUpdate:modelValue","status"]))],2)}),128))],2)],2)],2)],2)],64)}}});function Tl(){const s=A(!1),n=A(),o=A(),r=Ne("client");function i({message:e,errorCode:t,fieldName:l,errors:a}){return t=t||"Exception",a=a||[],n.value=new Bl(l?{errorCode:t,message:e,errors:[new Un({fieldName:l,errorCode:t,message:e})]}:{errorCode:t,message:e,errors:a})}var e={setError:i,addFieldError:function({fieldName:t,message:e,errorCode:l}){var a;l=l||"Exception",n.value?((a=new Bl(n.value)).errors=[...(a.errors||[]).filter(e=>{return(null==(e=e.fieldName)?void 0:e.toLowerCase())!==(null==t?void 0:t.toLowerCase())}),new Un({fieldName:t,message:e,errorCode:l})],n.value=a):i({fieldName:t,message:e,errorCode:l})},loading:s,error:n,api:async function(e,t,l){return s.value=!0,e=await r.api(Tt(e),t,l),s.value=!1,o.value=e.response,n.value=e.error,e},apiVoid:async function(e,t,l){return s.value=!0,e=await r.apiVoid(Tt(e),t,l),s.value=!1,o.value=e.response,n.value=e.error,e},apiForm:async function(e,t,l,a){return s.value=!0,e=await r.apiForm(Tt(e),t,l,a),s.value=!1,o.value=e.response,n.value=e.error,e},apiFormVoid:async function(e,t,l,a){return s.value=!0,e=await r.apiFormVoid(Tt(e),t,l,a),s.value=!1,o.value=e.response,n.value=e.error,e},swr:async function(e,t,l,a){return os(r,e,t,l,a)},swrEffect:function(l,a){const s=A(new Je),n=as(async e=>{s.value=await r.api(e)},null==a?void 0:a.delayMs);return hl(async()=>{var e=l(),t=on(_l(e));t&&(s.value=new Je({response:t})),0===(null==a?void 0:a.delayMs)?s.value=await r.api(e):n(e)}),(async()=>s.value=await r.api(l(),null==a?void 0:a.args,null==a?void 0:a.method))(),s},unRefs:Tt,setRef:ns};return Xt("ApiState",e),e}const L0={key:0},V0={class:"text-red-700"},S0=s("b",null,"type",-1),M0={key:0},A0={key:2},T0=["innerHTML"],F0=s("input",{type:"submit",class:"hidden"},null,-1),I0={class:"flex justify-end"},D0=s("div",null,null,-1),j0={key:2,class:"relative z-10","aria-labelledby":"slide-over-title",role:"dialog","aria-modal":"true"},O0=s("div",{class:"fixed inset-0"},null,-1),P0={class:"fixed inset-0 overflow-hidden"},B0={class:"flex min-h-0 flex-1 flex-col overflow-auto"},R0={class:"flex-1"},E0={class:"bg-gray-50 dark:bg-gray-900 px-4 py-6 sm:px-6"},H0={class:"flex items-start justify-between space-x-3"},z0={class:"space-y-1"},N0={key:0},U0={key:2},q0=["innerHTML"],Q0={class:"flex h-7 items-center"},K0={class:"flex justify-end"},Z0=ce({__name:"AutoForm",props:{type:null,modelValue:null,heading:null,subHeading:null,showLoading:{type:Boolean,default:!0},jsconfig:{default:"eccn,edv"},formStyle:{default:"card"},configureField:null,configureFormLayout:null,panelClass:null,bodyClass:null,formClass:null,innerFormClass:null,headerClass:{default:"p-6"},buttonsClass:null,headingClass:null,subHeadingClass:null,submitLabel:{default:"Submit"},allowSubmit:null},emits:["success","error","update:modelValue","done"],setup(p,{expose:e,emit:r}){const i=p,m=A(),g=A(1),y=A();function t(){g.value++,B.value=F();var e=Be();null!=(e=null==e?void 0:e.proxy)&&e.$forceUpdate()}e({forceUpdate:t,props:i,setModel:async function(e){Object.assign(B.value,e),t(),await xt(()=>null)},formFields:m,submit:async function(){D(y.value)},close:P}),Xt("ModalProvider",{openModal:function(e,t){h.value=e,l.value=t}});const h=A(),l=A();async function b(e){l.value&&l.value(e),h.value=void 0,l.value=void 0}const d=Tl(),n=is()["getTypeName"],{typeOf:c,createDto:v}=at(),x=A(new Je),C=f(()=>i.panelClass||Ze.panelClass(i.formStyle)),L=f(()=>i.formClass||"card"==i.formStyle?"shadow sm:rounded-md":It.formClass),V=f(()=>i.headingClass||Ze.headingClass(i.formStyle)),M=f(()=>i.subHeadingClass||Ze.subHeadingClass(i.formStyle)),S=f(()=>("string"==typeof i.buttonsClass?i:Ze).buttonsClass),I=f(()=>{var e;return i.type?n(i.type):null!=(e=i.modelValue)&&e.getTypeName?i.modelValue.getTypeName():null}),$=f(()=>c(I.value)),F=()=>i.modelValue||H(),B=A(F()),j=f(()=>d.loading.value),O=f(()=>{var e;return i.heading||(null==(e=c(I.value))?void 0:e.description)||He(I.value)});function H(){return"string"==typeof i.type?v(i.type):i.type?new i.type:i.modelValue}async function D(e){var t,l,a,s,n;e&&"FORM"==e.tagName?(t=H(),n=qe(null==t?void 0:t.getMethod,e=>"function"==typeof e?e():null)||"POST",l=null==qe(null==t?void 0:t.createResponse,e=>"function"==typeof e?e():null),a=i.jsconfig,ln.hasRequestBody(n)?(n=new t.constructor,s=new FormData(e),console.debug("AutoForm.submitForm",n,s),x.value=l?await d.apiFormVoid(n,s,{jsconfig:a}):await d.apiForm(n,s,{jsconfig:a})):(n=new t.constructor(_o(B.value)),console.debug("AutoForm.submit",n),x.value=l?await d.apiVoid(n,{jsconfig:a}):await d.api(n,{jsconfig:a})),x.value.succeeded?(r("success",x.value.response),P()):r("error",x.value.error)):console.error("Not a valid form",e)}function E(e){r("update:modelValue",e)}function z(){r("done")}const _=A(!1),R=A(""),N={entering:{cls:"transform transition ease-in-out duration-500 sm:duration-700",from:"translate-x-full",to:"translate-x-0"},leaving:{cls:"transform transition ease-in-out duration-500 sm:duration-700",from:"translate-x-0",to:"translate-x-full"}};function P(){"slideOver"==i.formStyle?_.value=!1:z()}Lt(_,()=>{Ct(N,R,_.value),_.value||setTimeout(z,700)}),_.value=!0;const U=e=>{"Escape"===e.key&&P()};return tt(()=>window.addEventListener("keydown",U)),Rt(()=>window.removeEventListener("keydown",U)),(t,e)=>{var l;const n=X("AutoFormFields"),r=X("FormLoading"),i=X("PrimaryButton"),d=X("CloseButton"),c=X("SecondaryButton"),v=X("ModalLookup");return a(),u("div",null,[o($)?"card"==p.formStyle?(a(),u("div",{key:1,class:w(o(C))},[s("form",{ref_key:"elForm",ref:y,onSubmit:e[0]||(e[0]=Ue(e=>D(e.target),["prevent"])),autocomplete:"off",class:w(p.innerFormClass)},[s("div",{class:w(p.bodyClass)},[s("div",{class:w(p.headerClass)},[t.$slots.heading?(a(),u("div",M0,[Z(t.$slots,"heading")])):(a(),u("h3",{key:1,class:w(o(V))},T(o(O)),3)),t.$slots.subheading?(a(),u("div",A0,[Z(t.$slots,"subheading")])):p.subHeading?(a(),u("p",{key:3,class:w(o(M))},T(p.subHeading),3)):null!=(l=o($))&&l.notes?(a(),u("p",{key:4,class:w(["notes",o(M)]),innerHTML:null==(l=o($))?void 0:l.notes},null,10,T0)):k("",!0)],2),Z(t.$slots,"header",{instance:null==(l=Be())?void 0:l.exposed,model:B.value}),F0,(a(),se(n,{ref_key:"formFields",ref:m,key:g.value,type:p.type,modelValue:B.value,"onUpdate:modelValue":E,api:x.value,configureField:p.configureField,configureFormLayout:p.configureFormLayout},null,8,["type","modelValue","api","configureField","configureFormLayout"])),Z(t.$slots,"footer",{instance:null==(l=Be())?void 0:l.exposed,model:B.value})],2),Z(t.$slots,"buttons",{},()=>{var e;return[s("div",{class:w(o(S))},[s("div",null,[Z(t.$slots,"leftbuttons",{instance:null==(e=Be())?void 0:e.exposed,model:B.value})]),s("div",null,[p.showLoading&&o(j)?(a(),se(r,{key:0})):k("",!0)]),s("div",I0,[D0,$e(i,{disabled:!!p.allowSubmit&&!p.allowSubmit(B.value)},{default:ke(()=>[we(T(p.submitLabel),1)]),_:1},8,["disabled"]),Z(t.$slots,"rightbuttons",{instance:null==(e=Be())?void 0:e.exposed,model:B.value})])],2)]})],34)],2)):(a(),u("div",j0,[O0,s("div",P0,[s("div",{onMousedown:P,class:"absolute inset-0 overflow-hidden"},[s("div",{onMousedown:e[2]||(e[2]=Ue(()=>{},["stop"])),class:"pointer-events-none fixed inset-y-0 right-0 flex pl-10"},[s("div",{class:w(["pointer-events-auto w-screen xl:max-w-3xl md:max-w-xl max-w-lg",R.value])},[s("form",{ref_key:"elForm",ref:y,class:w(o(L)),onSubmit:e[1]||(e[1]=Ue(e=>D(e.target),["prevent"]))},[s("div",B0,[s("div",R0,[s("div",E0,[s("div",H0,[s("div",z0,[t.$slots.heading?(a(),u("div",N0,[Z(t.$slots,"heading")])):(a(),u("h3",{key:1,class:w(o(V))},T(o(O)),3)),t.$slots.subheading?(a(),u("div",U0,[Z(t.$slots,"subheading")])):p.subHeading?(a(),u("p",{key:3,class:w(o(M))},T(p.subHeading),3)):null!=(l=o($))&&l.notes?(a(),u("p",{key:4,class:w(["notes",o(M)]),innerHTML:null==(e=o($))?void 0:e.notes},null,10,q0)):k("",!0)]),s("div",Q0,[$e(d,{"button-class":"bg-gray-50 dark:bg-gray-900",onClose:P})])])]),Z(t.$slots,"header",{instance:null==(l=Be())?void 0:l.exposed,model:B.value}),(a(),se(n,{ref_key:"formFields",ref:m,key:g.value,type:p.type,modelValue:B.value,"onUpdate:modelValue":E,api:x.value,configureField:p.configureField,configureFormLayout:p.configureFormLayout},null,8,["type","modelValue","api","configureField","configureFormLayout"])),Z(t.$slots,"footer",{instance:null==(e=Be())?void 0:e.exposed,model:B.value})])]),s("div",{class:w(o(S))},[s("div",null,[Z(t.$slots,"leftbuttons",{instance:null==(l=Be())?void 0:l.exposed,model:B.value})]),s("div",null,[p.showLoading&&o(j)?(a(),se(r,{key:0})):k("",!0)]),s("div",K0,[$e(c,{onClick:P,disabled:o(j)},{default:ke(()=>[we("Cancel")]),_:1},8,["disabled"]),$e(i,{class:"ml-4",disabled:!!p.allowSubmit&&!p.allowSubmit(B.value)},{default:ke(()=>[we(T(p.submitLabel),1)]),_:1},8,["disabled"]),Z(t.$slots,"rightbuttons",{instance:null==(e=Be())?void 0:e.exposed,model:B.value})])],2)],34)],2)],32)],32)])])):(a(),u("div",L0,[s("p",V0,[we("Could not create form for unknown "),S0,we(" "+T(o(I)),1)])])),"ModalLookup"==(null==(l=h.value)?void 0:l.name)&&h.value.ref?(a(),se(v,{key:3,"ref-info":h.value.ref,onDone:b},null,8,["ref-info"])):k("",!0)])}}}),G0={key:0},W0={class:"text-red-700"},J0=s("b",null,"type",-1),X0=["onSubmit"],Y0={key:0},ef={key:2},tf=["innerHTML"],lf={class:"flex justify-end"},nf={key:2,class:"relative z-10","aria-labelledby":"slide-over-title",role:"dialog","aria-modal":"true"},sf=s("div",{class:"fixed inset-0"},null,-1),of={class:"fixed inset-0 overflow-hidden"},af=["onSubmit"],rf={class:"flex min-h-0 flex-1 flex-col overflow-auto"},uf={class:"flex-1"},df={class:"bg-gray-50 dark:bg-gray-900 px-4 py-6 sm:px-6"},cf={class:"flex items-start justify-between space-x-3"},ff={class:"space-y-1"},mf={key:0},vf={key:2},hf=["innerHTML"],gf={class:"flex h-7 items-center"},pf={class:"flex justify-end"},yf=ce({__name:"AutoCreateForm",props:{type:null,formStyle:{default:"slideOver"},panelClass:null,formClass:null,headingClass:null,subHeadingClass:null,buttonsClass:null,heading:null,subHeading:null,autosave:{type:Boolean,default:!0},showLoading:{type:Boolean,default:!0},showCancel:{type:Boolean,default:!0},configureField:null,configureFormLayout:null},emits:["done","save","error"],setup(p,{expose:e,emit:n}){const r=p,m=A(),g=A(1);function t(){g.value++,null!=(e=m.value)&&e.forceUpdate();var e=Be();null!=(e=null==e?void 0:e.proxy)&&e.$forceUpdate()}function y(e){}e({forceUpdate:t,props:r,setModel:function(e){Object.assign(V.value,e),t()},formFields:m}),Xt("ModalProvider",{openModal:function(e,t){h.value=e,l.value=t}});const h=A(),l=A();async function b(e){l.value&&l.value(e),h.value=void 0,l.value=void 0}const{typeOf:i,typeProperties:d,Crud:c,createDto:v,formValues:x}=at(),C=f(()=>Et(r.type)),L=f(()=>i(C.value)),V=A("string"==typeof r.type?v(r.type):r.type?new r.type:null),M=f(()=>r.panelClass||Ze.panelClass(r.formStyle)),S=f(()=>r.formClass||Ze.formClass(r.formStyle)),I=f(()=>r.headingClass||Ze.headingClass(r.formStyle)),$=f(()=>r.subHeadingClass||Ze.subHeadingClass(r.formStyle)),F=f(()=>r.buttonsClass||Ze.buttonsClass),B=f(()=>c.model(L.value)),j=f(()=>{var e;return r.heading||(null==(e=i(C.value))?void 0:e.description)||(B.value?"New "+He(B.value):He(C.value))}),O=A(new Je);let H=Tl(),D=f(()=>H.loading.value);async function E(e){var t,l,a,e=e.target;r.autosave?(l=qe(null==(l=V.value)?void 0:l.getMethod,e=>"function"==typeof e?e():null)||"POST",t=null==qe(null==(t=V.value)?void 0:t.createResponse,e=>"function"==typeof e?e():null),ln.hasRequestBody(l)?(l=new V.value.constructor,a=new FormData(e),O.value=t?await H.apiFormVoid(l,a,{jsconfig:"eccn"}):await H.apiForm(l,a,{jsconfig:"eccn"})):(l=x(e,d(L.value)),a=new V.value.constructor(l),O.value=t?await H.apiVoid(a,{jsconfig:"eccn"}):await H.api(a,{jsconfig:"eccn"})),O.value.succeeded?(e.reset(),n("save",O.value.response)):n("error",O.value.error)):n("save",new V.value.constructor(x(e,d(L.value))))}function z(){n("done")}ne.interceptors.has("AutoCreateForm.new")&&ne.interceptors.invoke("AutoCreateForm.new",{props:r,model:V});const _=A(!1),R=A(""),N={entering:{cls:"transform transition ease-in-out duration-500 sm:duration-700",from:"translate-x-full",to:"translate-x-0"},leaving:{cls:"transform transition ease-in-out duration-500 sm:duration-700",from:"translate-x-0",to:"translate-x-full"}};function P(){"slideOver"==r.formStyle?_.value=!1:z()}Lt(_,()=>{Ct(N,R,_.value),_.value||setTimeout(z,700)}),_.value=!0;const U=e=>{"Escape"===e.key&&P()};return tt(()=>window.addEventListener("keydown",U)),Rt(()=>window.removeEventListener("keydown",U)),(e,t)=>{var l,n=X("AutoFormFields"),r=X("FormLoading"),i=X("SecondaryButton"),d=X("PrimaryButton"),c=X("CloseButton"),v=X("ModalLookup");return a(),u("div",null,[o(L)?"card"==p.formStyle?(a(),u("div",{key:1,class:w(o(M))},[s("form",{onSubmit:Ue(E,["prevent"])},[s("div",{class:w(o(S))},[s("div",null,[e.$slots.heading?(a(),u("div",Y0,[Z(e.$slots,"heading")])):(a(),u("h3",{key:1,class:w(o(I))},T(o(j)),3)),e.$slots.subheading?(a(),u("div",ef,[Z(e.$slots,"subheading")])):p.subHeading?(a(),u("p",{key:3,class:w(o($))},T(p.subHeading),3)):null!=(l=o(L))&&l.notes?(a(),u("p",{key:4,class:w(["notes",o($)]),innerHTML:null==(l=o(L))?void 0:l.notes},null,10,tf)):k("",!0)]),Z(e.$slots,"header",{formInstance:null==(l=Be())?void 0:l.exposed,model:V.value}),(a(),se(n,{ref_key:"formFields",ref:m,key:g.value,modelValue:V.value,"onUpdate:modelValue":y,api:O.value,configureField:p.configureField,configureFormLayout:p.configureFormLayout},null,8,["modelValue","api","configureField","configureFormLayout"])),Z(e.$slots,"footer",{formInstance:null==(l=Be())?void 0:l.exposed,model:V.value})],2),s("div",{class:w(o(F))},[s("div",null,[p.showLoading&&o(D)?(a(),se(r,{key:0})):k("",!0)]),s("div",lf,[p.showCancel?(a(),se(i,{key:0,onClick:P,disabled:o(D)},{default:ke(()=>[we("Cancel")]),_:1},8,["disabled"])):k("",!0),$e(d,{type:"submit",class:"ml-4",disabled:o(D)},{default:ke(()=>[we("Save")]),_:1},8,["disabled"])])],2)],40,X0)],2)):(a(),u("div",nf,[sf,s("div",of,[s("div",{onMousedown:P,class:"absolute inset-0 overflow-hidden"},[s("div",{onMousedown:t[0]||(t[0]=Ue(()=>{},["stop"])),class:"pointer-events-none fixed inset-y-0 right-0 flex pl-10"},[s("div",{class:w(["pointer-events-auto w-screen xl:max-w-3xl md:max-w-xl max-w-lg",R.value])},[s("form",{class:w(o(S)),onSubmit:Ue(E,["prevent"])},[s("div",rf,[s("div",uf,[s("div",df,[s("div",cf,[s("div",ff,[e.$slots.heading?(a(),u("div",mf,[Z(e.$slots,"heading")])):(a(),u("h3",{key:1,class:w(o(I))},T(o(j)),3)),e.$slots.subheading?(a(),u("div",vf,[Z(e.$slots,"subheading")])):p.subHeading?(a(),u("p",{key:3,class:w(o($))},T(p.subHeading),3)):null!=(l=o(L))&&l.notes?(a(),u("p",{key:4,class:w(["notes",o($)]),innerHTML:null==(t=o(L))?void 0:t.notes},null,10,hf)):k("",!0)]),s("div",gf,[$e(c,{"button-class":"bg-gray-50 dark:bg-gray-900",onClose:P})])])]),Z(e.$slots,"header",{formInstance:null==(l=Be())?void 0:l.exposed,model:V.value}),(a(),se(n,{ref_key:"formFields",ref:m,key:g.value,modelValue:V.value,"onUpdate:modelValue":y,api:O.value,configureField:p.configureField,configureFormLayout:p.configureFormLayout},null,8,["modelValue","api","configureField","configureFormLayout"])),Z(e.$slots,"footer",{formInstance:null==(t=Be())?void 0:t.exposed,model:V.value})])]),s("div",{class:w(o(F))},[s("div",null,[p.showLoading&&o(D)?(a(),se(r,{key:0})):k("",!0)]),s("div",pf,[p.showCancel?(a(),se(i,{key:0,onClick:P,disabled:o(D)},{default:ke(()=>[we("Cancel")]),_:1},8,["disabled"])):k("",!0),$e(d,{type:"submit",class:"ml-4",disabled:o(D)},{default:ke(()=>[we("Save")]),_:1},8,["disabled"])])],2)],42,af)],2)],32)],32)])])):(a(),u("div",G0,[s("p",W0,[we("Could not create form for unknown "),J0,we(" "+T(o(C)),1)])])),"ModalLookup"==(null==(c=h.value)?void 0:c.name)&&h.value.ref?(a(),se(v,{key:3,"ref-info":h.value.ref,onDone:b},null,8,["ref-info"])):k("",!0)])}}}),bf={key:0},wf={class:"text-red-700"},xf=s("b",null,"type",-1),kf=["onSubmit"],$f={key:0},Cf={key:2},_f=["innerHTML"],Lf={class:"flex justify-end"},Vf={key:2,class:"relative z-10","aria-labelledby":"slide-over-title",role:"dialog","aria-modal":"true"},Sf=s("div",{class:"fixed inset-0"},null,-1),Mf={class:"fixed inset-0 overflow-hidden"},Af=["onSubmit"],Tf={class:"flex min-h-0 flex-1 flex-col overflow-auto"},Ff={class:"flex-1"},If={class:"bg-gray-50 dark:bg-gray-900 px-4 py-6 sm:px-6"},Df={class:"flex items-start justify-between space-x-3"},jf={class:"space-y-1"},Of={key:0},Pf={key:2},Bf=["innerHTML"],Rf={class:"flex h-7 items-center"},Ef={class:"flex justify-end"},Hf=ce({__name:"AutoEditForm",props:{modelValue:null,type:null,deleteType:null,formStyle:{default:"slideOver"},panelClass:null,formClass:null,headingClass:null,subHeadingClass:null,heading:null,subHeading:null,autosave:{type:Boolean,default:!0},showLoading:{type:Boolean,default:!0},configureField:null,configureFormLayout:null},emits:["done","save","delete","error"],setup(p,{expose:e,emit:n}){const r=p,m=A(),g=A(1);function y(e){}e({forceUpdate:function(){g.value++,V.value=L();var e=Be();null!=(e=null==e?void 0:e.proxy)&&e.$forceUpdate()},props:r,setModel:function(e){Object.assign(V.value,e)},formFields:m}),Xt("ModalProvider",{openModal:function(e,t){h.value=e,l.value=t}});const h=A(),l=A();async function b(e){l.value&&l.value(e),h.value=void 0,l.value=void 0}const{typeOf:t,apiOf:q,typeProperties:i,createFormLayout:Q,getPrimaryKey:K,Crud:c,createDto:d,formValues:v}=at(),x=f(()=>Et(r.type)),C=f(()=>t(x.value)),L=()=>"string"==typeof r.type?d(r.type,ml(r.modelValue)):r.type?new r.type(ml(r.modelValue)):null,V=A(L()),W=f(()=>r.panelClass||Ze.panelClass(r.formStyle)),M=f(()=>r.formClass||Ze.formClass(r.formStyle)),S=f(()=>r.headingClass||Ze.headingClass(r.formStyle)),I=f(()=>r.subHeadingClass||Ze.subHeadingClass(r.formStyle)),$=f(()=>c.model(C.value)),F=f(()=>{var e;return r.heading||(null==(e=t(x.value))?void 0:e.description)||($.value?"Update "+He($.value):He(x.value))}),B=A(new Je);let j=Object.assign({},ml(r.modelValue)),O=(ne.interceptors.has("AutoEditForm.new")&&ne.interceptors.invoke("AutoEditForm.new",{props:r,model:V,origModel:j}),Tl()),H=f(()=>O.loading.value);const D=()=>qe(t(c.model(C.value)),e=>K(e));function G(e){var{op:t,prop:l}=e;t&&(c.isPatch(t)||c.isUpdate(t))&&(e.disabled=null==l?void 0:l.isPrimaryKey),r.configureField&&r.configureField(e)}async function E(a){a=a.target;if(r.autosave){let e=qe(null==(s=V.value)?void 0:s.getMethod,e=>"function"==typeof e?e():null)||"POST",l=null==qe(null==(s=V.value)?void 0:s.createResponse,e=>"function"==typeof e?e():null),d=D();if(ln.hasRequestBody(e)){let e=new V.value.constructor,t=ye(r.modelValue,d.name),i=new FormData(a),u=(d&&!Array.from(i.keys()).some(e=>e.toLowerCase()==d.name.toLowerCase())&&i.append(d.name,t),[]);var s=x.value&&q(x.value);if(s&&c.isPatch(s)){let o=Q(C.value),r={};if(d&&(r[d.name]=t),o.forEach(l=>{var a=l.id,s=ye(j,a);if(!d||d.name.toLowerCase()!==a.toLowerCase()){var n=i.get(a);ne.interceptors.has("AutoEditForm.save.formLayout")&&ne.interceptors.invoke("AutoEditForm.save.formLayout",{origValue:s,formLayout:o,input:l,newValue:n});let e=null!=n,t="checkbox"===l.type?e!=!!s:"file"===l.type?e:n!=s;(t=n||s?t:!1)&&(n?r[a]=n:"file"!==l.type&&u.push(a))}}),ne.interceptors.has("AutoEditForm.save")&&ne.interceptors.invoke("AutoEditForm.save",{origModel:j,formLayout:o,dirtyValues:r}),Array.from(i.keys()).filter(e=>!r[e]).forEach(e=>i.delete(e)),0==Array.from(i.keys()).filter(e=>e.toLowerCase()!=d.name.toLowerCase()).length&&0==u.length)return void P()}s=0"function"==typeof e?e():null)?B.value=await O.apiVoid(l):B.value=await O.api(l),B.value.succeeded?n("delete",B.value.response):n("error",B.value.error)):console.error(`Could not find Primary Key for Type ${x.value} (${$.value})`)}function _(){n("done")}const R=A(!1),N=A(""),J={entering:{cls:"transform transition ease-in-out duration-500 sm:duration-700",from:"translate-x-full",to:"translate-x-0"},leaving:{cls:"transform transition ease-in-out duration-500 sm:duration-700",from:"translate-x-0",to:"translate-x-full"}};function P(){"slideOver"==r.formStyle?R.value=!1:_()}Lt(R,()=>{Ct(J,N,R.value),R.value||setTimeout(_,700)}),R.value=!0;const U=e=>{"Escape"===e.key&&P()};return tt(()=>window.addEventListener("keydown",U)),Rt(()=>window.removeEventListener("keydown",U)),(e,t)=>{var l,n=X("AutoFormFields"),r=X("ConfirmDelete"),i=X("FormLoading"),d=X("SecondaryButton"),c=X("PrimaryButton"),v=X("CloseButton"),f=X("ModalLookup");return a(),u("div",null,[o(C)?"card"==p.formStyle?(a(),u("div",{key:1,class:w(o(W))},[s("form",{onSubmit:Ue(E,["prevent"])},[s("div",{class:w(o(M))},[s("div",null,[e.$slots.heading?(a(),u("div",$f,[Z(e.$slots,"heading")])):(a(),u("h3",{key:1,class:w(o(S))},T(o(F)),3)),e.$slots.subheading?(a(),u("div",Cf,[Z(e.$slots,"subheading")])):p.subHeading?(a(),u("p",{key:3,class:w(o(I))},T(p.subHeading),3)):null!=(l=o(C))&&l.notes?(a(),u("p",{key:4,class:w(["notes",o(I)]),innerHTML:null==(l=o(C))?void 0:l.notes},null,10,_f)):k("",!0)]),Z(e.$slots,"header",{formInstance:null==(l=Be())?void 0:l.exposed,model:V.value}),(a(),se(n,{ref_key:"formFields",ref:m,key:g.value,modelValue:V.value,"onUpdate:modelValue":y,api:B.value,configureField:p.configureField,configureFormLayout:p.configureFormLayout},null,8,["modelValue","api","configureField","configureFormLayout"])),Z(e.$slots,"footer",{formInstance:null==(l=Be())?void 0:l.exposed,model:V.value})],2),s("div",{class:w(o(Ze).buttonsClass)},[s("div",null,[p.deleteType?(a(),se(r,{key:0,onDelete:z})):k("",!0)]),s("div",null,[p.showLoading&&o(H)?(a(),se(i,{key:0})):k("",!0)]),s("div",Lf,[$e(d,{onClick:P,disabled:o(H)},{default:ke(()=>[we("Cancel")]),_:1},8,["disabled"]),$e(c,{type:"submit",class:"ml-4",disabled:o(H)},{default:ke(()=>[we("Save")]),_:1},8,["disabled"])])],2)],40,kf)],2)):(a(),u("div",Vf,[Sf,s("div",Mf,[s("div",{onMousedown:P,class:"absolute inset-0 overflow-hidden"},[s("div",{onMousedown:t[0]||(t[0]=Ue(()=>{},["stop"])),class:"pointer-events-none fixed inset-y-0 right-0 flex pl-10"},[s("div",{class:w(["pointer-events-auto w-screen xl:max-w-3xl md:max-w-xl max-w-lg",N.value])},[s("form",{class:w(o(M)),onSubmit:Ue(E,["prevent"])},[s("div",Tf,[s("div",Ff,[s("div",If,[s("div",Df,[s("div",jf,[e.$slots.heading?(a(),u("div",Of,[Z(e.$slots,"heading")])):(a(),u("h3",{key:1,class:w(o(S))},T(o(F)),3)),e.$slots.subheading?(a(),u("div",Pf,[Z(e.$slots,"subheading")])):p.subHeading?(a(),u("p",{key:3,class:w(o(I))},T(p.subHeading),3)):null!=(l=o(C))&&l.notes?(a(),u("p",{key:4,class:w(["notes",o(I)]),innerHTML:null==(t=o(C))?void 0:t.notes},null,10,Bf)):k("",!0)]),s("div",Rf,[$e(v,{"button-class":"bg-gray-50 dark:bg-gray-900",onClose:P})])])]),Z(e.$slots,"header",{formInstance:null==(l=Be())?void 0:l.exposed,model:V.value}),(a(),se(n,{ref_key:"formFields",ref:m,key:g.value,modelValue:V.value,"onUpdate:modelValue":y,api:B.value,configureField:G,configureFormLayout:p.configureFormLayout},null,8,["modelValue","api","configureFormLayout"])),Z(e.$slots,"footer",{formInstance:null==(t=Be())?void 0:t.exposed,model:V.value})])]),s("div",{class:w(o(Ze).buttonsClass)},[s("div",null,[p.deleteType?(a(),se(r,{key:0,onDelete:z})):k("",!0)]),s("div",null,[p.showLoading&&o(H)?(a(),se(i,{key:0})):k("",!0)]),s("div",Ef,[$e(d,{onClick:P,disabled:o(H)},{default:ke(()=>[we("Cancel")]),_:1},8,["disabled"]),$e(c,{type:"submit",class:"ml-4",disabled:o(H)},{default:ke(()=>[we("Save")]),_:1},8,["disabled"])])],2)],42,Af)],2)],32)],32)])])):(a(),u("div",bf,[s("p",wf,[we("Could not create form for unknown "),xf,we(" "+T(o(x)),1)])])),"ModalLookup"==(null==(v=h.value)?void 0:v.name)&&h.value.ref?(a(),se(f,{key:3,"ref-info":h.value.ref,onDone:b},null,8,["ref-info"])):k("",!0)])}}}),zf=s("label",{for:"confirmDelete",class:"ml-2 mr-2 select-none"},"confirm",-1),Nf=["onClick"],Uf=ce({__name:"ConfirmDelete",emits:["delete"],setup(e,{emit:t}){let l=A(!1);const n=()=>{l.value&&t("delete")},r=f(()=>["select-none inline-flex justify-center py-2 px-4 border border-transparent shadow-sm text-sm font-medium rounded-md text-white",l.value?"cursor-pointer bg-red-600 hover:bg-red-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-red-500":"bg-red-400"]);return(e,t)=>(a(),u(Te,null,[kt(s("input",{id:"confirmDelete",type:"checkbox",class:"focus:ring-indigo-500 h-4 w-4 text-indigo-600 rounded border-gray-300 dark:border-gray-600 dark:bg-gray-800 dark:ring-offset-black","onUpdate:modelValue":t[0]||(t[0]=e=>Gn(l)?l.value=e:l=e)},null,512),[[Yl,o(l)]]),zf,s("span",Me({onClick:Ue(n,["prevent"]),class:o(r)},e.$attrs),[Z(e.$slots,"default",{},()=>[we("Delete")])],16,Nf)],64))}}),qf={class:"flex",title:"loading..."},Qf={key:0,xmlns:"http://www.w3.org/2000/svg",x:"0px",y:"0px",width:"24px",height:"30px",viewBox:"0 0 24 30"},Kf=wl('',3),Zf=[Kf],Gf={class:"ml-2 mt-1 text-gray-400"},Wf=ce({__name:"FormLoading",props:{icon:{type:Boolean,default:!0},text:{default:"loading..."}},setup(l){return Ne("ApiState",void 0),(e,t)=>(a(),u("div",qf,[l.icon?(a(),u("svg",Qf,Zf)):k("",!0),s("span",Gf,T(l.text),1)]))}}),Jf=["onClick"],Xf={key:3,class:"flex justify-between items-center"},Yf={class:"mr-1 select-none"},e1=["onClick"],t1=ce({__name:"DataGrid",props:{items:{default:()=>[]},id:{default:"DataGrid"},type:null,tableStyle:{default:"stripedRows"},selectedColumns:null,gridClass:null,grid2Class:null,grid3Class:null,grid4Class:null,tableClass:null,theadClass:null,tbodyClass:null,theadRowClass:null,theadCellClass:null,isSelected:null,headerTitle:null,headerTitles:null,visibleFrom:null,rowClass:null,rowStyle:null},emits:["headerSelected","rowSelected"],setup(t,{emit:d}){const c=t,l=A(),v=A(null),p=en(),m=t=>Object.keys(p).find(e=>e.toLowerCase()==t.toLowerCase()+"-header"),g=t=>Object.keys(p).find(e=>e.toLowerCase()==t.toLowerCase()),n=f(()=>Nl(c.items).filter(e=>!(!p[e]&&!p[e+"-header"]))),{typeOf:e,typeProperties:r}=at(),i=f(()=>Et(c.type)),y=f(()=>e(i.value)),h=f(()=>r(y.value));function b(e){e=c.headerTitles&&ye(c.headerTitles,e)||e;return c.headerTitle?c.headerTitle(e):ts(e)}function x(e){const t=e.toLowerCase();return h.value.find(e=>e.name.toLowerCase()==t)}const C={xs:"xs:table-cell",sm:"sm:table-cell",md:"md:table-cell",lg:"lg:table-cell",xl:"xl:table-cell","2xl":"2xl:table-cell",never:""};function L(e){e=c.visibleFrom&&ye(c.visibleFrom,e);return e&&qe(C[e],e=>"hidden "+e)}const V=f(()=>c.gridClass??ge.getGridClass(c.tableStyle)),M=f(()=>c.grid2Class??ge.getGrid2Class(c.tableStyle)),S=f(()=>c.grid3Class??ge.getGrid3Class(c.tableStyle)),I=f(()=>c.grid4Class??ge.getGrid4Class(c.tableStyle)),$=f(()=>c.tableClass??ge.getTableClass(c.tableStyle)),F=f(()=>c.tbodyClass??ge.getTbodyClass(c.tbodyClass)),B=f(()=>c.theadClass??ge.getTheadClass(c.tableStyle)),j=f(()=>c.theadRowClass??ge.getTheadRowClass(c.tableStyle)),O=f(()=>c.theadCellClass??ge.getTheadCellClass(c.tableStyle));const H=f(()=>{const e=("string"==typeof c.selectedColumns?c.selectedColumns.split(","):c.selectedColumns)||(0(e[t.name.toLowerCase()]=t.format,e),{});return e.filter(e=>{return"hidden"!=(null==(e=t[e.toLowerCase()])?void 0:e.method)})});return(n,e)=>{const r=X("CellFormat"),i=X("PreviewFormat");return t.items.length?(a(),u("div",{key:0,ref_key:"refResults",ref:l,class:w(o(V))},[s("div",{class:w(o(M))},[s("div",{class:w(o(S))},[s("div",{class:w(o(I))},[s("table",{class:w(o($))},[s("thead",{class:w(o(B))},[s("tr",{class:w(o(j))},[(a(!0),u(Te,null,Ie(o(H),t=>{return a(),u("td",{class:w([L(t),o(O),(e=t,v.value===e?"text-gray-900 dark:text-gray-50":"text-gray-500 dark:text-gray-400")])},[s("div",{onClick:e=>{d("headerSelected",t,e)}},[o(p)[t+"-header"]?Z(n.$slots,t+"-header",{key:0,column:t}):m(t)?Z(n.$slots,m(t),{key:1,column:t}):o(p).header?Z(n.$slots,"header",{key:2,column:t,label:b(t)}):(a(),u("div",Xf,[s("span",Yf,T(b(t)),1)]))],8,Jf)],2);var e}),256))],2)],2),s("tbody",{class:w(o(F))},[(a(!0),u(Te,null,Ie(t.items,(t,e)=>{return a(),u("tr",{class:w((l=t,s=e,c.rowClass?c.rowClass(l,s):ge.getTableRowClass(c.tableStyle,s,!(!c.isSelected||!c.isSelected(l)),null!=c.isSelected))),style:Xl((s=t,l=e,c.rowStyle?c.rowStyle(s,l):void 0)),onClick:e=>{d("rowSelected",t,e)}},[(a(!0),u(Te,null,Ie(o(H),e=>{return a(),u("td",{class:w([L(e),o(ge).tableCellClass])},[o(p)[e]?Z(n.$slots,e,jt(Me({key:0},t))):g(e)?Z(n.$slots,g(e),jt(Me({key:1},t))):x(e)?(a(),se(r,{key:2,type:o(y),propType:x(e),modelValue:t},null,8,["type","propType","modelValue"])):(a(),se(i,{key:3,value:o(ye)(t,e),format:null!=(e=x(e=e))&&e.format?e.format:"TimeSpan"==(null==e?void 0:e.type)||"TimeOnly"==(null==e?void 0:e.type)?{method:"time"}:null},null,8,["value","format"]))],2)}),256))],14,e1);var l,s}),256))],2)],2)],2)],2)],2)],2)):k("",!0)}}}),l1=ce({props:{type:Object,propType:Object,modelValue:Object},setup(i,{attrs:u}){const d=at()["typeOf"];return()=>{var e,t;const l=null!=(e=i.propType)&&e.format?e.format:"TimeSpan"==(null==e?void 0:e.type)||"TimeOnly"==(null==e?void 0:e.type)?{method:"time"}:null,a=ye(i.modelValue,i.propType.name),s=Object.assign({},i,u),n=gt("span",{innerHTML:Jt(a,l,s)}),o=Zt(a)&&Array.isArray(a)?gt("span",{},[gt("span",{class:"mr-2"},""+a.length),n]):n,r=null==(e=i.propType)?void 0:e.ref;return r&&(e=et(i.type).find(e=>e.type===r.model))&&(e=(e=ye(i.modelValue,e.name))&&r.refLabel&&ye(e,r.refLabel))?(t=(t=null==(t=d(r.model))?void 0:t.icon)?gt(zs,{image:t,class:"w-5 h-5 mr-1"}):null,gt("span",{class:"flex",title:r.model+" "+a},[t,e])):o}}}),n1={key:0},s1={key:0,class:"mr-2"},o1=["innerHTML"],a1=["innerHTML"],i1={inheritAttrs:!1},r1=ce({...i1,__name:"PreviewFormat",props:{value:null,format:null,includeIcon:{type:Boolean,default:!0},includeCount:{type:Boolean,default:!0},maxFieldLength:{default:150},maxNestedFields:{default:2},maxNestedFieldLength:{default:30}},setup(l){const e=l,n=f(()=>Array.isArray(e.value));return(e,t)=>o(Zt)(l.value)?(a(),u("span",n1,[l.includeCount&&o(n)?(a(),u("span",s1,T(l.value.length),1)):k("",!0),s("span",{innerHTML:o(Jt)(l.value,l.format,e.$attrs)},null,8,o1)])):(a(),u("span",{key:1,innerHTML:o(Jt)(l.value,l.format,e.$attrs)},null,8,a1))}}),u1=["innerHTML"],d1={key:0},c1=s("b",null,null,-1),f1={key:2},m1=ce({__name:"HtmlFormat",props:{value:null,depth:{default:0},fieldAttrs:null,classes:{type:Function,default:(e,t,l,a,s)=>a}},setup(r){const t=r,i=f(()=>_t(t.value)),d=f(()=>Array.isArray(t.value)),c=e=>ts(e),v=e=>t.fieldAttrs?t.fieldAttrs(e):null,p=f(()=>Nl(t.value));return(e,t)=>{const l=X("HtmlFormat",!0);return a(),u("div",{class:w(0==r.depth?"prose html-format":"")},[o(i)?(a(),u("div",{key:0,innerHTML:o(Jt)(r.value)},null,8,u1)):o(d)?(a(),u("div",{key:1,class:w(r.classes("array","div",r.depth,o(ge).gridClass))},[o(_t)(r.value[0])?(a(),u("div",d1,"[ "+T(r.value.join(", "))+" ]",1)):(a(),u("div",{key:1,class:w(r.classes("array","div",r.depth,o(ge).grid2Class))},[s("div",{class:w(r.classes("array","div",r.depth,o(ge).grid3Class))},[s("div",{class:w(r.classes("array","div",r.depth,o(ge).grid4Class))},[s("table",{class:w(r.classes("object","table",r.depth,o(ge).tableClass))},[s("thead",{class:w(r.classes("array","thead",r.depth,o(ge).theadClass))},[s("tr",null,[(a(!0),u(Te,null,Ie(o(p),e=>(a(),u("th",{class:w(r.classes("array","th",r.depth,o(ge).theadCellClass+" whitespace-nowrap"))},[c1,we(T(c(e)),1)],2))),256))])],2),s("tbody",null,[(a(!0),u(Te,null,Ie(r.value,(t,e)=>(a(),u("tr",{class:w(r.classes("array","tr",r.depth,e%2==0?"bg-white":"bg-gray-50",e))},[(a(!0),u(Te,null,Ie(o(p),e=>(a(),u("td",{class:w(r.classes("array","td",r.depth,o(ge).tableCellClass))},[$e(l,Me({value:t[e],"field-attrs":r.fieldAttrs,depth:r.depth+1,classes:r.classes},v(e)),null,16,["value","field-attrs","depth","classes"])],2))),256))],2))),256))])],2)],2)],2)],2))],2)):(a(),u("div",f1,[s("table",{class:w(r.classes("object","table",r.depth,"table-object"))},[(a(!0),u(Te,null,Ie((n=r.value)?Object.keys(n).map(e=>({key:c(e),val:n[e]})):[],e=>(a(),u("tr",{class:w(r.classes("object","tr",r.depth,""))},[s("th",{class:w(r.classes("object","th",r.depth,"align-top py-2 px-4 text-left text-sm font-medium tracking-wider whitespace-nowrap"))},T(e.key),3),s("td",{class:w(r.classes("object","td",r.depth,"align-top py-2 px-4 text-sm"))},[$e(l,Me({value:e.val,"field-attrs":r.fieldAttrs,depth:r.depth+1,classes:r.classes},v(e.key)),null,16,["value","field-attrs","depth","classes"])],2)],2))),256))],2)]))],2);var n}}}),v1={class:"absolute top-0 right-0 pt-4 pr-4"},h1=s("span",{class:"sr-only"},"Close",-1),g1=s("svg",{class:"h-6 w-6",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor","aria-hidden":"true"},[s("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M6 18L18 6M6 6l12 12"})],-1),p1=[h1,g1],y1=ce({__name:"CloseButton",props:{buttonClass:{default:"bg-white dark:bg-black"}},emits:["close"],setup(l,{}){return(t,e)=>(a(),u("div",v1,[s("button",{type:"button",onClick:e[0]||(e[0]=e=>t.$emit("close")),class:w([l.buttonClass,"rounded-md text-gray-400 hover:text-gray-500 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500 dark:ring-offset-black"])},p1,2)]))}}),b1=["id","aria-labelledby"],w1=s("div",{class:"fixed inset-0"},null,-1),x1={class:"fixed inset-0 overflow-hidden"},k1={class:"flex h-full flex-col bg-white dark:bg-black shadow-xl"},$1={class:"flex min-h-0 flex-1 flex-col overflow-auto"},C1={class:"flex-1"},_1={class:"bg-gray-50 dark:bg-gray-900 px-4 py-6 sm:px-6"},L1={class:"flex items-start justify-between space-x-3"},V1={class:"space-y-1"},S1=["id"],M1={key:1,class:"text-sm text-gray-500"},A1={class:"flex h-7 items-center"},T1={class:"flex-shrink-0 border-t border-gray-200 dark:border-gray-700 px-4 py-5 sm:px-6"},F1=ce({__name:"SlideOver",props:{id:{default:"SlideOver"},title:null,contentClass:{default:"relative mt-6 flex-1 px-4 sm:px-6"}},emits:["done"],setup(n,{emit:e}){const t=A(!1),o=A(""),l={entering:{cls:"transform transition ease-in-out duration-500 sm:duration-700",from:"translate-x-full",to:"translate-x-0"},leaving:{cls:"transform transition ease-in-out duration-500 sm:duration-700",from:"translate-x-0",to:"translate-x-full"}},r=(Lt(t,()=>{Ct(l,o,t.value),t.value||setTimeout(()=>e("done"),700)}),t.value=!0,()=>t.value=!1),i=e=>{"Escape"===e.key&&r()};return tt(()=>window.addEventListener("keydown",i)),Rt(()=>window.removeEventListener("keydown",i)),(e,t)=>{var l=X("CloseButton");return a(),u("div",{id:n.id,class:"relative z-10","aria-labelledby":n.id+"-title",role:"dialog","aria-modal":"true"},[w1,s("div",x1,[s("div",{onMousedown:r,class:"absolute inset-0 overflow-hidden"},[s("div",{onMousedown:t[0]||(t[0]=Ue(()=>{},["stop"])),class:"pointer-events-none fixed inset-y-0 right-0 flex pl-10"},[s("div",{class:w(["pointer-events-auto w-screen xl:max-w-3xl md:max-w-xl max-w-lg",o.value])},[s("div",k1,[s("div",$1,[s("div",C1,[s("div",_1,[s("div",L1,[s("div",V1,[n.title?(a(),u("h2",{key:0,class:"text-lg font-medium text-gray-900 dark:text-gray-50",id:n.id+"-title"},T(n.title),9,S1)):k("",!0),e.$slots.subtitle?(a(),u("p",M1,[Z(e.$slots,"subtitle")])):k("",!0)]),s("div",A1,[$e(l,{"button-class":"bg-gray-50 dark:bg-gray-900",onClose:r})])])]),s("div",{class:w(n.contentClass)},[Z(e.$slots,"default")],2)])]),s("div",T1,[Z(e.$slots,"footer")])])],2)],32)],32)])],8,b1)}}}),I1=["id","data-transition-for","aria-labelledby"],D1={class:"fixed inset-0 z-10 overflow-y-auto"},j1={class:"flex min-h-full items-end justify-center p-4 text-center sm:items-center sm:p-0"},O1=s("span",{class:"sr-only"},"Close",-1),P1=s("svg",{class:"h-6 w-6",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor","aria-hidden":"true"},[s("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M6 18L18 6M6 6l12 12"})],-1),B1=[O1,P1],R1=ce({__name:"ModalDialog",props:{id:{default:"ModalDialog"},modalClass:{default:Jl.modalClass},sizeClass:{default:Jl.sizeClass}},emits:["done"],setup(n,{emit:e}){const t=A(!1),o=A(""),l={entering:{cls:"ease-out duration-300",from:"opacity-0",to:"opacity-100"},leaving:{cls:"ease-in duration-200",from:"opacity-100",to:"opacity-0"}},r=A(""),i={entering:{cls:"ease-out duration-300",from:"opacity-0 translate-y-4 sm:translate-y-0 sm:scale-95",to:"opacity-100 translate-y-0 sm:scale-100"},leaving:{cls:"ease-in duration-200",from:"opacity-100 translate-y-0 sm:scale-100",to:"opacity-0 translate-y-4 sm:translate-y-0 sm:scale-95"}},d=(Lt(t,()=>{Ct(l,o,t.value),Ct(i,r,t.value),t.value||setTimeout(()=>e("done"),200)}),t.value=!0,()=>t.value=!1),c=(Xt("ModalProvider",{openModal:function(e,t){c.value=e,v.value=t}}),A()),v=A();async function f(e){v.value&&v.value(e),c.value=void 0,v.value=void 0}const p=e=>{"Escape"===e.key&&d()};return tt(()=>window.addEventListener("keydown",p)),Rt(()=>window.removeEventListener("keydown",p)),(e,t)=>{var l=X("ModalLookup");return a(),u("div",{id:n.id,"data-transition-for":n.id,onMousedown:d,class:"relative z-10","aria-labelledby":n.id+"-title",role:"dialog","aria-modal":"true"},[s("div",{class:w(["fixed inset-0 bg-gray-500 bg-opacity-75 transition-opacity",o.value])},null,2),s("div",D1,[s("div",j1,[s("div",{class:w([n.modalClass,n.sizeClass,r.value]),onMousedown:t[0]||(t[0]=Ue(()=>{},["stop"]))},[s("div",null,[s("div",{class:"hidden sm:block absolute top-0 right-0 pt-4 pr-4 z-10"},[s("button",{type:"button",onClick:d,class:"bg-white dark:bg-black rounded-md text-gray-400 hover:text-gray-500 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500 dark:ring-offset-black"},B1)]),Z(e.$slots,"default")])],34)])]),"ModalLookup"==(null==(t=c.value)?void 0:t.name)&&c.value.ref?(a(),se(l,{key:0,"ref-info":c.value.ref,onDone:f},null,8,["ref-info"])):k("",!0)],40,I1)}}}),E1={class:"pt-2 overflow-auto",style:{"min-height":"620px"}},H1={class:"mt-3 pl-5 flex flex-wrap items-center"},z1={class:"hidden sm:block text-xl leading-6 font-medium text-gray-900 dark:text-gray-50 mr-3"},N1={class:"hidden md:inline"},U1={class:"flex pb-1 sm:pb-0"},q1=["title"],Q1=s("svg",{class:"w-8 h-8",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},[s("g",{"stroke-width":"1.5",fill:"none"},[s("path",{d:"M9 3H3.6a.6.6 0 0 0-.6.6v16.8a.6.6 0 0 0 .6.6H9M9 3v18M9 3h6M9 21h6m0-18h5.4a.6.6 0 0 1 .6.6v16.8a.6.6 0 0 1-.6.6H15m0-18v18",stroke:"currentColor"})])],-1),K1=[Q1],Z1=["disabled"],G1=s("svg",{class:"w-8 h-8",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},[s("path",{d:"M18.41 16.59L13.82 12l4.59-4.59L17 6l-6 6l6 6zM6 6h2v12H6z",fill:"currentColor"})],-1),W1=[G1],J1=["disabled"],X1=s("svg",{class:"w-8 h-8",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},[s("path",{d:"M15.41 7.41L14 6l-6 6l6 6l1.41-1.41L10.83 12z",fill:"currentColor"})],-1),Y1=[X1],em=["disabled"],tm=s("svg",{class:"w-8 h-8",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},[s("path",{d:"M10 6L8.59 7.41L13.17 12l-4.58 4.59L10 18l6-6z",fill:"currentColor"})],-1),lm=[tm],nm=["disabled"],sm=s("svg",{class:"w-8 h-8",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},[s("path",{d:"M5.59 7.41L10.18 12l-4.59 4.59L7 18l6-6l-6-6zM16 6h2v12h-2z",fill:"currentColor"})],-1),om=[sm],am={key:0,class:"flex pb-1 sm:pb-0"},im={class:"px-4 text-lg text-black dark:text-white"},rm={key:0},um={key:1},dm=s("span",{class:"hidden xl:inline"}," Showing Results ",-1),cm={key:2},fm={key:1,class:"pl-2"},mm=s("svg",{class:"w-5 h-5",xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true",viewBox:"0 0 24 24"},[s("path",{fill:"currentColor",d:"M6.78 2.72a.75.75 0 0 1 0 1.06L4.56 6h8.69a7.75 7.75 0 1 1-7.75 7.75a.75.75 0 0 1 1.5 0a6.25 6.25 0 1 0 6.25-6.25H4.56l2.22 2.22a.75.75 0 1 1-1.06 1.06l-3.5-3.5a.75.75 0 0 1 0-1.06l3.5-3.5a.75.75 0 0 1 1.06 0Z"})],-1),vm=[mm],hm={class:"flex pb-1 sm:pb-0"},gm={key:0,class:"pl-2"},pm=s("svg",{class:"flex-none w-5 h-5 mr-2 text-gray-400 dark:text-gray-500 group-hover:text-gray-500","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor"},[s("path",{"fill-rule":"evenodd",d:"M3 3a1 1 0 011-1h12a1 1 0 011 1v3a1 1 0 01-.293.707L12 11.414V15a1 1 0 01-.293.707l-2 2A1 1 0 018 17v-5.586L3.293 6.707A1 1 0 013 6V3z","clip-rule":"evenodd"})],-1),ym={class:"mr-1"},bm={key:0,class:"h-5 w-5 text-gray-400 dark:text-gray-500 group-hover:text-gray-500",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true"},wm=s("path",{"fill-rule":"evenodd",d:"M10 5a1 1 0 011 1v3h3a1 1 0 110 2h-3v3a1 1 0 11-2 0v-3H6a1 1 0 110-2h3V6a1 1 0 011-1z","clip-rule":"evenodd"},null,-1),xm=[wm],km={key:1,class:"h-5 w-5 text-gray-400 dark:text-gray-500 group-hover:text-gray-500",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true"},$m=s("path",{"fill-rule":"evenodd",d:"M5 10a1 1 0 011-1h8a1 1 0 110 2H6a1 1 0 01-1-1z","clip-rule":"evenodd"},null,-1),Cm=[$m],_m={key:1},Lm={key:4},Vm={key:0},Sm={key:0,class:"cursor-pointer flex justify-between items-center hover:text-gray-900 dark:hover:text-gray-50"},Mm={class:"mr-1 select-none"},Am={key:1,class:"flex justify-between items-center"},Tm={class:"mr-1 select-none"},Fm=ce({__name:"ModalLookup",props:{id:{default:"ModalLookup"},refInfo:null,skip:{default:0},prefs:null,selectedColumns:null,allowFiltering:{type:[Boolean,null],default:!0},showPreferences:{type:[Boolean,null],default:!0},showPagingNav:{type:[Boolean,null],default:!0},showPagingInfo:{type:[Boolean,null],default:!0},showResetPreferences:{type:[Boolean,null],default:!0},showFiltersView:{type:[Boolean,null],default:!0},toolbarButtonClass:null,canFilter:null},emits:["done"],setup(c,{emit:l}){const v=c,p=en(),e=St()["config"],{metadataApi:t,filterDefinitions:n}=at(),r=Ne("client"),i=e.value.storage,m=f(()=>v.toolbarButtonClass??ge.toolbarButtonClass),g=f(()=>n.value),y=A({take:25}),h=A(new Je),b=A(v.skip),x=A(!1),C=A(),d=e=>"string"==typeof e?e.split(","):e||[];function L(e,t){return ge.getTableRowClass("fullWidth",t,!1,!0)}const V=f(()=>ot(v.refInfo.model)),M=f(()=>{var e=(0<(e=d(v.selectedColumns)).length?e:[]).map(e=>e.toLowerCase());const l=et(V.value);return 0l.find(e=>e.name.toLowerCase()===t)).filter(e=>null!=e):l}),S=f(()=>{let e=M.value.map(e=>e.name),t=d(y.value.selectedColumns).map(e=>e.toLowerCase());return 0t.includes(e.toLowerCase())):e}),I=f(()=>y.value.take??25),$=f(()=>h.value.response?ye(h.value.response,"results"):[]),F=f(()=>{var e;return(null==(e=h.value.response)?void 0:e.total)??$.value.length??0}),B=f(()=>00$.value.length>=I.value),H=f(()=>$.value.length>=I.value),D=A([]),q=f(()=>D.value.some(e=>0D.value.map(e=>e.settings.filters.length).reduce((e,t)=>e+t,0)),Q=f(()=>el(V.value)),K=f(()=>{var e;return null==(e=t.value)?void 0:e.operations.find(e=>{var t;return(null==(t=e.dataModel)?void 0:t.name)==v.refInfo.model&&ze.isAnyQuery(e)})}),W=A(),z=A(!1),_=A(),R=()=>v.id+"/ApiPrefs/"+v.refInfo.model,N=e=>`Column/${v.id}:${v.refInfo.model}.`+e;async function P(e){b.value+=e,b.value<0&&(b.value=0);e=Math.floor(F.value/I.value)*I.value;b.value>e&&(b.value=e),await U()}async function G(e,t){l("done",e)}function J(){l("done",null)}function Y(t,e){var l,a=e.target;"TD"!==(null==a?void 0:a.tagName)&&(a=null==(a=null==a?void 0:a.closest("TABLE"))?void 0:a.getBoundingClientRect(),l=D.value.find(e=>e.name.toLowerCase()==t.toLowerCase()))&&a&&(e=("DIV"===(null==(a=e.target)?void 0:a.tagName)?e.target:null==(a=e.target)?void 0:a.closest("DIV")).getBoundingClientRect(),_.value={column:l,topLeft:{x:Math.max(Math.floor(e.x+25),343),y:Math.floor(115)}})}function ee(){_.value=null}async function te(e){var t=null==(t=_.value)?void 0:t.column;t&&(t.settings=e,i.setItem(N(t.name),JSON.stringify(t.settings)),await U()),_.value=null}async function le(e){i.setItem(N(e.name),JSON.stringify(e.settings)),await U()}async function ae(e){z.value=!1,y.value=e,i.setItem(R(),JSON.stringify(e)),await U()}async function U(){(async function(a){var s=K.value;if(s){let e=Gt(s,a),t=es(e=>{h.value.response=h.value.error=void 0,x.value=e}),l=await r.api(e);t(),xt(()=>h.value=l);s=ye(l.response,"results")||[];l.succeeded&&s.label}else console.error("No Query API was found for "+v.refInfo.model)})(function(){let a={include:"total",take:I.value},e=d(y.value.selectedColumns||v.selectedColumns);{var t;0{l.settings.sort&&s.push(("DESC"===l.settings.sort?"-":"")+l.name),l.settings.filters.forEach(e=>{var t=e.key.replace("%",l.name);a[t]=e.value})}),"u"{e.settings={filters:[]},i.removeItem(N(e.name))}),await U()}return tt(async()=>{var e=v.prefs||yl(i.getItem(R()));e&&(y.value=e),D.value=M.value.map(e=>({name:e.name,type:e.type,meta:e,settings:Object.assign({filters:[]},yl(i.getItem(N(e.name))))})),isNaN(v.skip)||(b.value=v.skip),await U()}),(l,e)=>{const t=X("ErrorSummary"),n=X("Loading"),r=X("SettingsIcons"),i=X("DataGrid"),d=X("ModalDialog");return a(),u(Te,null,[c.refInfo?(a(),se(d,{key:0,ref_key:"modalDialog",ref:W,id:c.id,onDone:J},{default:ke(()=>[s("div",E1,[s("div",H1,[s("h3",z1,[we(" Select "),s("span",N1,T(o(He)(c.refInfo.model)),1)]),s("div",U1,[c.showPreferences?(a(),u("button",{key:0,type:"button",class:"pl-2 text-gray-700 dark:text-gray-300 hover:text-indigo-600 dark:hover:text-indigo-400",title:c.refInfo.model+" Preferences",onClick:e[0]||(e[0]=e=>z.value=!z.value)},K1,8,q1)):k("",!0),c.showPagingNav?(a(),u("button",{key:1,type:"button",class:w(["pl-2",o(B)?"text-gray-700 dark:text-gray-300 hover:text-indigo-600 dark:hover:text-indigo-400":"text-gray-400 dark:text-gray-500"]),title:"First page",disabled:!o(B),onClick:e[1]||(e[1]=e=>P(-o(F)))},W1,10,Z1)):k("",!0),c.showPagingNav?(a(),u("button",{key:2,type:"button",class:w(["pl-2",o(j)?"text-gray-700 dark:text-gray-300 hover:text-indigo-600 dark:hover:text-indigo-400":"text-gray-400 dark:text-gray-500"]),title:"Previous page",disabled:!o(j),onClick:e[2]||(e[2]=e=>P(-o(I)))},Y1,10,J1)):k("",!0),c.showPagingNav?(a(),u("button",{key:3,type:"button",class:w(["pl-2",o(O)?"text-gray-700 dark:text-gray-300 hover:text-indigo-600 dark:hover:text-indigo-400":"text-gray-400 dark:text-gray-500"]),title:"Next page",disabled:!o(O),onClick:e[3]||(e[3]=e=>P(o(I)))},lm,10,em)):k("",!0),c.showPagingNav?(a(),u("button",{key:4,type:"button",class:w(["pl-2",o(H)?"text-gray-700 dark:text-gray-300 hover:text-indigo-600 dark:hover:text-indigo-400":"text-gray-400 dark:text-gray-500"]),title:"Last page",disabled:!o(H),onClick:e[4]||(e[4]=e=>P(o(F)))},om,10,nm)):k("",!0)]),c.showPagingInfo?(a(),u("div",am,[s("div",im,[x.value?(a(),u("span",rm,"Querying...")):k("",!0),o($).length?(a(),u("span",um,[dm,we(" "+T(b.value+1)+" - "+T(Math.min(b.value+o($).length,o(F)))+" ",1),s("span",null," of "+T(o(F)),1)])):h.value.completed?(a(),u("span",cm,"No Results")):k("",!0)])])):k("",!0),o(q)&&c.showResetPreferences?(a(),u("div",fm,[s("button",{type:"button",onClick:ne,title:"Reset Preferences & Filters",class:w(o(m))},vm,2)])):k("",!0),s("div",hm,[c.showFiltersView&&0C.value="filters"==C.value?null:"filters"),class:w(o(m)),"aria-expanded":"false"},[pm,s("span",ym,T(o(E))+" "+T(1==o(E)?"Filter":"Filters"),1),"filters"!=C.value?(a(),u("svg",bm,xm)):(a(),u("svg",km,Cm))],2)])):k("",!0)])]),"filters"==C.value?(a(),se(Sn,{key:0,class:"border-y border-gray-200 dark:border-gray-800 py-8 my-2",definitions:o(g),columns:D.value,onDone:e[6]||(e[6]=e=>C.value=null),onChange:le},null,8,["definitions","columns"])):k("",!0),_.value?(a(),u("div",_m,[$e(Vn,{definitions:o(g),column:_.value.column,"top-left":_.value.topLeft,onDone:ee,onSave:te},null,8,["definitions","column","top-left"])])):k("",!0),h.value.error?(a(),se(t,{key:2,status:h.value.error},null,8,["status"])):x.value?(a(),se(n,{key:3})):(a(),u("div",Lm,[o($).length?(a(),u("div",Vm,[$e(i,{id:c.id,items:o($),type:c.refInfo.model,"selected-columns":o(S),onFiltersChanged:U,tableStyle:"fullWidth",rowClass:L,onRowSelected:G,onHeaderSelected:Y},tn({header:ke(({column:t,label:e})=>{return[!c.allowFiltering||v.canFilter&&!v.canFilter(t)?(a(),u("div",Am,[s("span",Tm,T(e),1)])):(a(),u("div",Sm,[s("span",Mm,T(e),1),$e(r,{column:D.value.find(e=>e.name.toLowerCase()===t.toLowerCase()),"is-open":(null==(e=_.value)?void 0:e.column.name)===t},null,8,["column","is-open"])]))]}),_:2},[Ie(Object.keys(o(p)),t=>({name:t,fn:ke(e=>[Z(l.$slots,t,jt(gl(e)))])}))]),1032,["id","items","type","selected-columns"])])):k("",!0)]))])]),_:3},8,["id"])):k("",!0),z.value?(a(),se(Mn,{key:1,columns:o(M),prefs:y.value,onDone:e[7]||(e[7]=e=>z.value=!1),onSave:ae},null,8,["columns","prefs"])):k("",!0)],64)}}}),Im={class:"sm:hidden"},Dm=["for"],jm=["id","name"],Om=["value"],Pm={class:"hidden sm:block"},Bm={class:"border-b border-gray-200"},Rm={class:"-mb-px flex","aria-label":"Tabs"},Em=["onClick"],Hm=ce({__name:"Tabs",props:{tabs:null,id:{default:"tabs"},param:{default:"tab"},label:{type:Function,default:e=>He(e)},selected:null,tabClass:null,bodyClass:{default:"p-4"},url:{type:Boolean,default:!0}},setup(l){const t=l,n=f(()=>Object.keys(t.tabs)),r=e=>t.label?t.label(e):He(e),i=f(()=>t.id||"tabs"),d=f(()=>t.param||"tab"),c=A();function v(e){c.value=e,t.url&&nn({tab:e===n.value[0]?void 0:e})}const p=f(()=>100/Object.keys(t.tabs).length+"%");return tt(()=>{var e;c.value=t.selected||Object.keys(t.tabs)[0],t.url&&(e=location.search||(location.hash.includes("?")?"?"+dl(location.hash,"?"):""),e=zl(e)[d.value])&&(c.value=e)}),(e,t)=>(a(),u("div",null,[s("div",Im,[s("label",{for:o(i),class:"sr-only"},"Select a tab",8,Dm),s("select",{id:o(i),name:o(i),class:"block w-full rounded-md border-gray-300 focus:border-indigo-500 focus:ring-indigo-500",onChange:t[0]||(t[0]=e=>{return v(null==(e=e.target)?void 0:e.value)})},[(a(!0),u(Te,null,Ie(o(n),e=>(a(),u("option",{key:e,value:e},T(r(e)),9,Om))),128))],40,jm)]),s("div",Pm,[s("div",Bm,[s("nav",Rm,[(a(!0),u(Te,null,Ie(o(n),t=>{return a(),u("a",{href:"#",onClick:Ue(e=>v(t),["prevent"]),style:Xl({width:o(p)}),class:w([(e=t,c.value===e?"border-indigo-500 text-indigo-600 py-4 px-1 text-center border-b-2 font-medium text-sm":"border-transparent text-gray-500 hover:text-gray-700 hover:border-gray-300 py-4 px-1 text-center border-b-2 font-medium text-sm"),l.tabClass])},T(r(t)),15,Em);var e}),256))])])]),s("div",{class:w(l.bodyClass)},[(a(),se(Jn(l.tabs[c.value])))],2)]))}}),zm=s("svg",{xmlns:"http://www.w3.org/2000/svg",class:"h-4 w-4 text-gray-400",preserveAspectRatio:"xMidYMid meet",viewBox:"0 0 32 32"},[s("path",{fill:"currentColor",d:"M13.502 5.414a15.075 15.075 0 0 0 11.594 18.194a11.113 11.113 0 0 1-7.975 3.39c-.138 0-.278.005-.418 0a11.094 11.094 0 0 1-3.2-21.584M14.98 3a1.002 1.002 0 0 0-.175.016a13.096 13.096 0 0 0 1.825 25.981c.164.006.328 0 .49 0a13.072 13.072 0 0 0 10.703-5.555a1.01 1.01 0 0 0-.783-1.565A13.08 13.08 0 0 1 15.89 4.38A1.015 1.015 0 0 0 14.98 3Z"})],-1),Nm=[zm],Um=s("svg",{xmlns:"http://www.w3.org/2000/svg",class:"h-4 w-4 text-indigo-600",preserveAspectRatio:"xMidYMid meet",viewBox:"0 0 32 32"},[s("path",{fill:"currentColor",d:"M16 12.005a4 4 0 1 1-4 4a4.005 4.005 0 0 1 4-4m0-2a6 6 0 1 0 6 6a6 6 0 0 0-6-6ZM5.394 6.813L6.81 5.399l3.505 3.506L8.9 10.319zM2 15.005h5v2H2zm3.394 10.193L8.9 21.692l1.414 1.414l-3.505 3.506zM15 25.005h2v5h-2zm6.687-1.9l1.414-1.414l3.506 3.506l-1.414 1.414zm3.313-8.1h5v2h-5zm-3.313-6.101l3.506-3.506l1.414 1.414l-3.506 3.506zM15 2.005h2v5h-2z"})],-1),qm=[Um],Qm=ce({__name:"DarkModeToggle",setup(e){const l=typeof document<"u"?document.documentElement:null,n=()=>!(null==l||!l.classList.contains("dark")),o=A("dark"==localStorage.getItem("color-scheme"));return(e,t)=>(a(),u("button",{type:"button",class:"bg-gray-200 dark:bg-gray-700 relative inline-flex flex-shrink-0 h-6 w-11 border-2 border-transparent rounded-full cursor-pointer transition-colors ease-in-out duration-200 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500 dark:ring-offset-black",role:"switch","aria-checked":"false",onClick:t[0]||(t[0]=e=>{n()?null!=l&&l.classList.remove("dark"):null!=l&&l.classList.add("dark"),o.value=n(),localStorage.setItem("color-scheme",o.value?"dark":"light")})},[s("span",{class:w(`${o.value?"translate-x-0":"translate-x-5"} pointer-events-none relative inline-block h-5 w-5 rounded-full bg-white dark:bg-black shadow transform ring-0 transition ease-in-out duration-200`)},[s("span",{class:w(`${o.value?"opacity-100 ease-in duration-200":"opacity-0 ease-out duration-100"} absolute inset-0 h-full w-full flex items-center justify-center transition-opacity`),"aria-hidden":"true"},Nm,2),s("span",{class:w(`${o.value?"opacity-0 ease-out duration-100":"opacity-100 ease-in duration-200"} absolute inset-0 h-full w-full flex items-center justify-center transition-opacity`),"aria-hidden":"true"},qm,2)],2)]))}}),Km={key:0},Zm={key:1,class:"min-h-full flex flex-col justify-center py-12 sm:px-6 lg:px-8"},Gm={class:"sm:mx-auto sm:w-full sm:max-w-md"},Wm={class:"mt-6 text-center text-3xl font-extrabold text-gray-900"},Jm={key:0,class:"mt-4 text-center text-sm text-gray-600"},Xm={class:"relative z-0 inline-flex shadow-sm rounded-md"},Ym=["onClick"],ev={class:"mt-8 sm:mx-auto sm:w-full sm:max-w-md"},tv={class:"bg-white py-8 px-4 shadow sm:rounded-lg sm:px-10"},lv=["onSubmit"],nv={class:"mt-8"},sv={key:1,class:"mt-6"},ov=wl('
Or continue with
',1),av={class:"mt-6 grid grid-cols-3 gap-3"},iv=["href","title"],rv={key:1,class:"h-5 w-5 text-gray-700",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32"},uv=s("path",{d:"M16 8a5 5 0 1 0 5 5a5 5 0 0 0-5-5z",fill:"currentColor"},null,-1),dv=s("path",{d:"M16 2a14 14 0 1 0 14 14A14.016 14.016 0 0 0 16 2zm7.992 22.926A5.002 5.002 0 0 0 19 20h-6a5.002 5.002 0 0 0-4.992 4.926a12 12 0 1 1 15.985 0z",fill:"currentColor"},null,-1),cv=[uv,dv],fv=ce({__name:"SignIn",props:{provider:null,title:{default:"Sign In"},tabs:{type:[Boolean,String],default:!0},oauth:{type:[Boolean,String],default:!0}},emits:["login"],setup(c,{emit:t}){const l=c,{getMetadata:e,createDto:n}=at(),r=Tl(),i=Ne("client"),d=Ln()["signIn"],v=e({assert:!0}),p=v.plugins.auth,m=document.baseURI,g=v.app.baseUrl,y=A(n("Authenticate")),h=A(new Je),b=A(l.provider),x=(tt(()=>{null!=p&&p.authProviders.map(e=>e.formLayout).filter(e=>e).forEach(e=>e.forEach(e=>y.value[e.id]=""))}),f(()=>(null==p?void 0:p.authProviders.filter(e=>e.formLayout))||[])),C=f(()=>x.value[0]||{}),L=f(()=>x.value[Math.max(x.value.length-1,0)]||{}),V=f(()=>(b.value?null==p?void 0:p.authProviders.find(e=>e.name===b.value):null)??C.value),M=e=>!1===e||"false"===e;function S(e){return e.label||e.navItem&&e.navItem.label}const I=f(()=>{var e;return((null==(e=V.value)?void 0:e.formLayout)||[]).map(e=>{var t;return Object.assign({},e,{type:null==(t=e.type)?void 0:t.toLowerCase(),autocomplete:e.autocomplete||("password"===(null==(t=e.type)?void 0:t.toLowerCase())?"current-password":void 0)||("username"===e.id.toLowerCase()?"username":void 0),css:Object.assign({field:"col-span-12"},e.css)})})}),$=f(()=>!M(l.oauth)&&(null==p?void 0:p.authProviders.filter(e=>"oauth"===e.type))||[]),F=f(()=>{let e=Lo(null==p?void 0:p.authProviders.filter(e=>e.formLayout&&0{e[S(t)||st(t.name)]=t.name===C.value.name?"":t.name});var t=V.value;return e=t&&M(l.tabs)?{[S(t)||st(t.name)]:t}:e}),B=f(()=>{var e=I.value.map(e=>e.id).filter(e=>e);return h.value.summaryMessage(e)});async function j(){var e;y.value.provider=V.value.name,"authsecret"===V.value.name?(i.headers.set("authsecret",y.value.authsecret),y.value=n("Authenticate")):"basic"===V.value.name&&(i.setCredentials(y.value.UserName,y.value.Password),y.value=n("Authenticate"),y.value.UserName=null,y.value.Password=null),h.value=await r.api(y.value),h.value.succeeded&&(e=h.value.response,d(e),t("login",e),h.value=new Je,y.value=n("Authenticate"))}return(e,t)=>{const l=X("ErrorSummary"),n=X("AutoFormFields"),r=X("PrimaryButton"),i=X("Icon"),d=ro("href");return o(p)?(a(),u("div",Zm,[s("div",Gm,[s("h2",Wm,T(c.title),1),1kt((a(),u("a",{onClick:e=>b.value=t,class:w([""===t||t===o(C).name?"rounded-l-md":t===o(L).name?"rounded-r-md -ml-px":"-ml-px",b.value===t?"z-10 outline-none ring-1 ring-indigo-500 border-indigo-500":"","cursor-pointer relative inline-flex items-center px-4 py-1 border border-gray-300 bg-white text-sm font-medium text-gray-700 hover:bg-gray-50"])},[we(T(e),1)],10,Ym)),[[d,{provider:t}]])),256))])])):k("",!0)]),s("div",ev,[o(B)?(a(),se(l,{key:0,class:"mb-3",errorSummary:o(B)},null,8,["errorSummary"])):k("",!0),s("div",tv,[o(I).length?(a(),u("form",{key:0,onSubmit:Ue(j,["prevent"])},[$e(n,{modelValue:y.value,formLayout:o(I),api:h.value,hideSummary:!0,"divide-class":"","space-class":"space-y-6"},null,8,["modelValue","formLayout","api"]),s("div",nv,[$e(r,{class:"w-full"},{default:ke(()=>[we("Sign In")]),_:1})])],40,lv)):k("",!0),o($).length?(a(),u("div",sv,[ov,s("div",av,[(a(!0),u(Te,null,Ie(o($),e=>(a(),u("div",null,[s("a",{href:o(g)+e.navItem.href+"?continue="+o(m),title:S(e),class:"w-full inline-flex justify-center py-2 px-4 border border-gray-300 rounded-md shadow-sm bg-white text-sm font-medium text-gray-500 hover:bg-gray-50"},[e.icon?(a(),se(i,{key:0,image:e.icon,class:"h-5 w-5 text-gray-700"},null,8,["image"])):(a(),u("svg",rv,cv))],8,iv)]))),256))])])):k("",!0)])])])):(a(),u("div",Km,"No Auth Plugin"))}}}),mv=["for"],vv={key:1,class:"border border-gray-200 flex justify-between"},hv={class:"p-2 flex flex-wrap gap-x-4"},gv=s("title",null,"Bold text (CTRL+B)",-1),pv=s("path",{fill:"currentColor",d:"M15.6 10.79c.97-.67 1.65-1.77 1.65-2.79c0-2.26-1.75-4-4-4H7v14h7.04c2.09 0 3.71-1.7 3.71-3.79c0-1.52-.86-2.82-2.15-3.42zM10 6.5h3c.83 0 1.5.67 1.5 1.5s-.67 1.5-1.5 1.5h-3v-3zm3.5 9H10v-3h3.5c.83 0 1.5.67 1.5 1.5s-.67 1.5-1.5 1.5z"},null,-1),yv=[gv,pv],bv=s("title",null,"Italics (CTRL+I)",-1),wv=s("path",{fill:"currentColor",d:"M10 4v3h2.21l-3.42 8H6v3h8v-3h-2.21l3.42-8H18V4h-8z"},null,-1),xv=[bv,wv],kv=s("title",null,"Insert Link (CTRL+K)",-1),$v=s("path",{fill:"currentColor",d:"M3.9 12c0-1.71 1.39-3.1 3.1-3.1h4V7H7a5 5 0 0 0-5 5a5 5 0 0 0 5 5h4v-1.9H7c-1.71 0-3.1-1.39-3.1-3.1M8 13h8v-2H8v2m9-6h-4v1.9h4c1.71 0 3.1 1.39 3.1 3.1c0 1.71-1.39 3.1-3.1 3.1h-4V17h4a5 5 0 0 0 5-5a5 5 0 0 0-5-5Z"},null,-1),Cv=[kv,$v],_v=s("title",null,"Blockquote (CTRL+Q)",-1),Lv=s("path",{fill:"currentColor",d:"m15 17l2-4h-4V6h7v7l-2 4h-3Zm-9 0l2-4H4V6h7v7l-2 4H6Z"},null,-1),Vv=[_v,Lv],Sv=s("title",null,"Insert Image (CTRL+SHIFT+L)",-1),Mv=s("path",{fill:"currentColor",d:"M2.992 21A.993.993 0 0 1 2 20.007V3.993A1 1 0 0 1 2.992 3h18.016c.548 0 .992.445.992.993v16.014a1 1 0 0 1-.992.993H2.992ZM20 15V5H4v14L14 9l6 6Zm0 2.828l-6-6L6.828 19H20v-1.172ZM8 11a2 2 0 1 1 0-4a2 2 0 0 1 0 4Z"},null,-1),Av=[Sv,Mv],Tv=s("title",null,"Insert Code (CTRL+<)",-1),Fv=s("path",{fill:"currentColor",d:"m8 18l-6-6l6-6l1.425 1.425l-4.6 4.6L9.4 16.6L8 18Zm8 0l-1.425-1.425l4.6-4.6L14.6 7.4L16 6l6 6l-6 6Z"},null,-1),Iv=[Tv,Fv],Dv=s("title",null,"H2 Heading (CTRL+H)",-1),jv=s("path",{fill:"currentColor",d:"M7 20V7H2V4h13v3h-5v13H7Zm9 0v-8h-3V9h9v3h-3v8h-3Z"},null,-1),Ov=[Dv,jv],Pv=s("title",null,"Numbered List (ALT+1)",-1),Bv=s("path",{fill:"currentColor",d:"M3 22v-1.5h2.5v-.75H4v-1.5h1.5v-.75H3V16h3q.425 0 .713.288T7 17v1q0 .425-.288.713T6 19q.425 0 .713.288T7 20v1q0 .425-.288.713T6 22H3Zm0-7v-2.75q0-.425.288-.713T4 11.25h1.5v-.75H3V9h3q.425 0 .713.288T7 10v1.75q0 .425-.288.713T6 12.75H4.5v.75H7V15H3Zm1.5-7V3.5H3V2h3v6H4.5ZM9 19v-2h12v2H9Zm0-6v-2h12v2H9Zm0-6V5h12v2H9Z"},null,-1),Rv=[Pv,Bv],Ev=s("title",null,"Bulleted List (ALT+-)",-1),Hv=s("path",{fill:"currentColor",d:"M9 19v-2h12v2H9Zm0-6v-2h12v2H9Zm0-6V5h12v2H9ZM5 20q-.825 0-1.413-.588T3 18q0-.825.588-1.413T5 16q.825 0 1.413.588T7 18q0 .825-.588 1.413T5 20Zm0-6q-.825 0-1.413-.588T3 12q0-.825.588-1.413T5 10q.825 0 1.413.588T7 12q0 .825-.588 1.413T5 14Zm0-6q-.825 0-1.413-.588T3 6q0-.825.588-1.413T5 4q.825 0 1.413.588T7 6q0 .825-.588 1.413T5 8Z"},null,-1),zv=[Ev,Hv],Nv=s("title",null,"Strike Through (ALT+S)",-1),Uv=s("path",{fill:"currentColor",d:"M10 19h4v-3h-4v3zM5 4v3h5v3h4V7h5V4H5zM3 14h18v-2H3v2z"},null,-1),qv=[Nv,Uv],Qv=s("title",null,"Undo (CTRL+Z)",-1),Kv=s("path",{fill:"currentColor",d:"M12.5 8c-2.65 0-5.05.99-6.9 2.6L2 7v9h9l-3.62-3.62c1.39-1.16 3.16-1.88 5.12-1.88c3.54 0 6.55 2.31 7.6 5.5l2.37-.78C21.08 11.03 17.15 8 12.5 8z"},null,-1),Zv=[Qv,Kv],Gv=s("title",null,"Redo (CTRL+SHIFT+Z)",-1),Wv=s("path",{fill:"currentColor",d:"M18.4 10.6C16.55 8.99 14.15 8 11.5 8c-4.65 0-8.58 3.03-9.96 7.22L3.9 16a8.002 8.002 0 0 1 7.6-5.5c1.95 0 3.73.72 5.12 1.88L13 16h9V7l-3.6 3.6z"},null,-1),Jv=[Gv,Wv],Xv={key:0,class:"p-2 flex flex-wrap gap-x-4"},Yv=["href"],eh=s("path",{fill:"currentColor",d:"M11 18h2v-2h-2v2zm1-16C6.48 2 2 6.48 2 12s4.48 10 10 10s10-4.48 10-10S17.52 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8s8 3.59 8 8s-3.59 8-8 8zm0-14c-2.21 0-4 1.79-4 4h2c0-1.1.9-2 2-2s2 .9 2 2c0 2-3 1.75-3 5h2c0-2.25 3-2.5 3-5c0-2.21-1.79-4-4-4z"},null,-1),th=[eh],lh={class:""},nh=["name","id","label","value","rows","disabled","onKeydown"],sh=["id"],oh=["id"],ah=ce({__name:"MarkdownInput",props:{status:null,id:null,inputClass:null,label:null,labelClass:null,help:null,placeholder:null,modelValue:null,counter:{type:Boolean},rows:null,errorMessages:null,lang:null,autoFocus:{type:Boolean},disabled:{type:Boolean},helpUrl:{default:"https://guides.github.com/features/mastering-markdown/"},hide:null},emits:["update:modelValue","close"],setup(n,{expose:e,emit:l}){const r=n;let g=[],y=[],t=Ne("ApiState",void 0);const i=f(()=>mt.call({responseStatus:r.status??(null==t?void 0:t.error.value)},r.id)),d=f(()=>r.label??He(st(r.id))),c="bold,italics,link,image,blockquote,code,heading,orderedList,unorderedList,strikethrough,undo,redo,help".split(","),v=f(()=>r.hide?wt(c,r.hide):wt(c,[]));function p(e){return v.value[e]}const m=f(()=>["shadow-sm font-mono"+nt.base.replace("rounded-md",""),i.value?"text-red-900 focus:ring-red-500 focus:border-red-500 border-red-300":"text-gray-900 "+nt.valid,r.inputClass]),h="w-5 h-5 cursor-pointer select-none text-gray-700 dark:text-gray-300 hover:text-indigo-600 dark:hover:text-indigo-400",b=A();function x(e){l("update:modelValue",e)}function C(){return b.value.selectionStart!==b.value.selectionEnd}function L(){var e=b.value;return e.value.substring(e.selectionStart,e.selectionEnd)||""}function V(){var e=b.value,t=e.value,l=e.selectionStart,e=t.substring(l,e.selectionEnd)||"",a=t.substring(0,l),s=a.lastIndexOf(` `);return{value:t,sel:e,selPos:l,beforeSel:a,afterSel:t.substring(l),prevCRPos:s,beforeCR:0<=s?a.substring(0,s+1):"",afterCR:0<=s?a.substring(s+1):""}}function M({value:e,selectionStart:t,selectionEnd:l}){null==l&&(l=t),x(e),xt(()=>{b.value.focus(),b.value.setSelectionRange(t,l)})}function S(e,t,l="",{selectionAtEnd:a,offsetStart:s,offsetEnd:n,filterValue:o,filterSelection:r}={}){const i=b.value;let u=i.value,d=i.selectionEnd;g.push({value:u,selectionStart:i.selectionStart,selectionEnd:i.selectionEnd}),y=[];var c=i.selectionStart,v=i.selectionEnd,f=u.substring(0,c),p=u.substring(v),m=e&&f.endsWith(e)&&p.startsWith(t);c==v?(m?(u=f.substring(0,f.length-e.length)+p.substring(t.length),d+=-t.length):(u=f+e+l+t+p,d+=e.length,s=0,n=(null==l?void 0:l.length)||0,a&&(d+=n,n=0)),o&&(l={pos:d},u=o(u,l),d=l.pos)):(a=u.substring(c,v),r&&(a=r(a)),m?(u=f.substring(0,f.length-e.length)+a+p.substring(t.length),s=-a.length-e.length,n=a.length):(u=f+e+a+t+p,s?d+=(e+t).length:(d=c,s=e.length,n=a.length))),x(u),xt(()=>{i.focus(),s=d+(s||0),n=(s||0)+(n||0),i.setSelectionRange(s,n)})}e({props:r,textarea:b,updateModelValue:x,selection:L,hasSelection:C,selectionInfo:V,insert:S,replace:M});const I=()=>S("**","**","bold"),$=()=>S("_","_","italics"),F=()=>S("~~","~~","strikethrough"),B=()=>S("[","](https://)","",{offsetStart:-9,offsetEnd:8}),j=()=>S(` > `,` diff --git a/MyApp/wwwroot/lib/mjs/servicestack-vue.mjs b/MyApp/wwwroot/lib/mjs/servicestack-vue.mjs index 98bb60d..d7ae4df 100644 --- a/MyApp/wwwroot/lib/mjs/servicestack-vue.mjs +++ b/MyApp/wwwroot/lib/mjs/servicestack-vue.mjs @@ -1948,7 +1948,7 @@ function Oi(e) { function Pi() { ne.user.value = null, ne.events.publish("signOut", null); } -const $n = (e) => e.roles || [], Cn = (e) => e.permissions || []; +const $n = (e) => (e == null ? void 0 : e.roles) || [], Cn = (e) => (e == null ? void 0 : e.permissions) || []; function Us(e) { return $n(ne.user.value).indexOf(e) >= 0; } diff --git a/MyApp/wwwroot/lib/mjs/vue.min.mjs b/MyApp/wwwroot/lib/mjs/vue.min.mjs index 166594d..ffbe425 100644 --- a/MyApp/wwwroot/lib/mjs/vue.min.mjs +++ b/MyApp/wwwroot/lib/mjs/vue.min.mjs @@ -1,6 +1,11 @@ -function e(e,t){const n=Object.create(null),o=e.split(",");for(let r=0;r!!n[e.toLowerCase()]:e=>!!n[e]}const t={},n=[],o=()=>{},r=()=>!1,s=/^on[^a-z]/,i=e=>s.test(e),l=e=>e.startsWith("onUpdate:"),c=Object.assign,a=(e,t)=>{const n=e.indexOf(t);n>-1&&e.splice(n,1)},u=Object.prototype.hasOwnProperty,p=(e,t)=>u.call(e,t),f=Array.isArray,d=e=>"[object Map]"===x(e),h=e=>"[object Set]"===x(e),m=e=>"[object Date]"===x(e),g=e=>"function"==typeof e,v=e=>"string"==typeof e,y=e=>"symbol"==typeof e,b=e=>null!==e&&"object"==typeof e,_=e=>(b(e)||g(e))&&g(e.then)&&g(e.catch),S=Object.prototype.toString,x=e=>S.call(e),C=e=>x(e).slice(8,-1),w=e=>"[object Object]"===x(e),k=e=>v(e)&&"NaN"!==e&&"-"!==e[0]&&""+parseInt(e,10)===e,T=e(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),E=e("bind,cloak,else-if,else,for,html,if,model,on,once,pre,show,slot,text,memo"),N=e=>{const t=Object.create(null);return n=>t[n]||(t[n]=e(n))},O=/-(\w)/g,$=N((e=>e.replace(O,((e,t)=>t?t.toUpperCase():"")))),P=/\B([A-Z])/g,R=N((e=>e.replace(P,"-$1").toLowerCase())),A=N((e=>e.charAt(0).toUpperCase()+e.slice(1))),F=N((e=>e?`on${A(e)}`:"")),M=(e,t)=>!Object.is(e,t),V=(e,t)=>{for(let n=0;n{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,value:n})},B=e=>{const t=parseFloat(e);return isNaN(t)?e:t},L=e=>{const t=v(e)?Number(e):NaN;return isNaN(t)?e:t};let j;const U=()=>j||(j="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:"undefined"!=typeof global?global:{}),D=e("Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt,console");function H(e){if(f(e)){const t={};for(let n=0;n{if(e){const n=e.split(z);n.length>1&&(t[n[0].trim()]=n[1].trim())}})),t}function q(e){let t="";if(v(e))t=e;else if(f(e))for(let n=0;nte(e,t)))}const oe=e=>v(e)?e:null==e?"":f(e)||b(e)&&(e.toString===S||!g(e.toString))?JSON.stringify(e,re,2):String(e),re=(e,t)=>t&&t.__v_isRef?re(e,t.value):d(t)?{[`Map(${t.size})`]:[...t.entries()].reduce(((e,[t,n])=>(e[`${t} =>`]=n,e)),{})}:h(t)?{[`Set(${t.size})`]:[...t.values()]}:!b(t)||f(t)||w(t)?t:String(t);let se;class ie{constructor(e=!1){this.detached=e,this._active=!0,this.effects=[],this.cleanups=[],this.parent=se,!e&&se&&(this.index=(se.scopes||(se.scopes=[])).push(this)-1)}get active(){return this._active}run(e){if(this._active){const t=se;try{return se=this,e()}finally{se=t}}}on(){se=this}off(){se=this.parent}stop(e){if(this._active){let t,n;for(t=0,n=this.effects.length;t{const t=new Set(e);return t.w=0,t.n=0,t},fe=e=>(e.w&ge)>0,de=e=>(e.n&ge)>0,he=new WeakMap;let me=0,ge=1;const ve=30;let ye;const be=Symbol(""),_e=Symbol("");class Se{constructor(e,t=null,n){this.fn=e,this.scheduler=t,this.active=!0,this.deps=[],this.parent=void 0,ce(this,n)}run(){if(!this.active)return this.fn();let e=ye,t=ke;for(;e;){if(e===this)return;e=e.parent}try{return this.parent=ye,ye=this,ke=!0,ge=1<<++me,me<=ve?(({deps:e})=>{if(e.length)for(let t=0;t{const{deps:t}=e;if(t.length){let n=0;for(let o=0;o{("length"===n||!y(n)&&n>=e)&&l.push(t)}))}else switch(void 0!==n&&l.push(i.get(n)),t){case"add":f(e)?k(n)&&l.push(i.get("length")):(l.push(i.get(be)),d(e)&&l.push(i.get(_e)));break;case"delete":f(e)||(l.push(i.get(be)),d(e)&&l.push(i.get(_e)));break;case"set":d(e)&&l.push(i.get(be))}if(1===l.length)l[0]&&Re(l[0]);else{const e=[];for(const t of l)t&&e.push(...t);Re(pe(e))}}function Re(e,t){const n=f(e)?e:[...e];for(const o of n)o.computed&&Ae(o);for(const o of n)o.computed||Ae(o)}function Ae(e,t){(e!==ye||e.allowRecurse)&&(e.scheduler?e.scheduler():e.run())}const Fe=e("__proto__,__v_isRef,__isVue"),Me=new Set(Object.getOwnPropertyNames(Symbol).filter((e=>"arguments"!==e&&"caller"!==e)).map((e=>Symbol[e])).filter(y)),Ve=Ie();function Ie(){const e={};return["includes","indexOf","lastIndexOf"].forEach((t=>{e[t]=function(...e){const n=Et(this);for(let t=0,r=this.length;t{e[t]=function(...e){Ee();const n=Et(this)[t].apply(this,e);return Ne(),n}})),e}function Be(e){const t=Et(this);return Oe(t,0,e),t.hasOwnProperty(e)}class Le{constructor(e=!1,t=!1){this._isReadonly=e,this._shallow=t}get(e,t,n){const o=this._isReadonly,r=this._shallow;if("__v_isReactive"===t)return!o;if("__v_isReadonly"===t)return o;if("__v_isShallow"===t)return r;if("__v_raw"===t&&n===(o?r?vt:gt:r?mt:ht).get(e))return e;const s=f(e);if(!o){if(s&&p(Ve,t))return Reflect.get(Ve,t,n);if("hasOwnProperty"===t)return Be}const i=Reflect.get(e,t,n);return(y(t)?Me.has(t):Fe(t))?i:(o||Oe(e,0,t),r?i:At(i)?s&&k(t)?i:i.value:b(i)?o?_t(i):yt(i):i)}}class je extends Le{constructor(e=!1){super(!1,e)}set(e,t,n,o){let r=e[t];if(wt(r)&&At(r)&&!At(n))return!1;if(!this._shallow&&(kt(n)||wt(n)||(r=Et(r),n=Et(n)),!f(e)&&At(r)&&!At(n)))return r.value=n,!0;const s=f(e)&&k(t)?Number(t)e,Ge=e=>Reflect.getPrototypeOf(e);function qe(e,t,n=!1,o=!1){const r=Et(e=e.__v_raw),s=Et(t);n||(M(t,s)&&Oe(r,0,t),Oe(r,0,s));const{has:i}=Ge(r),l=o?Ke:n?$t:Ot;return i.call(r,t)?l(e.get(t)):i.call(r,s)?l(e.get(s)):void(e!==r&&e.get(t))}function Je(e,t=!1){const n=this.__v_raw,o=Et(n),r=Et(e);return t||(M(e,r)&&Oe(o,0,e),Oe(o,0,r)),e===r?n.has(e):n.has(e)||n.has(r)}function Ze(e,t=!1){return e=e.__v_raw,!t&&Oe(Et(e),0,be),Reflect.get(e,"size",e)}function Ye(e){e=Et(e);const t=Et(this);return Ge(t).has.call(t,e)||(t.add(e),Pe(t,"add",e,e)),this}function Qe(e,t){t=Et(t);const n=Et(this),{has:o,get:r}=Ge(n);let s=o.call(n,e);s||(e=Et(e),s=o.call(n,e));const i=r.call(n,e);return n.set(e,t),s?M(t,i)&&Pe(n,"set",e,t):Pe(n,"add",e,t),this}function Xe(e){const t=Et(this),{has:n,get:o}=Ge(t);let r=n.call(t,e);r||(e=Et(e),r=n.call(t,e)),o&&o.call(t,e);const s=t.delete(e);return r&&Pe(t,"delete",e,void 0),s}function et(){const e=Et(this),t=0!==e.size,n=e.clear();return t&&Pe(e,"clear",void 0,void 0),n}function tt(e,t){return function(n,o){const r=this,s=r.__v_raw,i=Et(s),l=t?Ke:e?$t:Ot;return!e&&Oe(i,0,be),s.forEach(((e,t)=>n.call(o,l(e),l(t),r)))}}function nt(e,t,n){return function(...o){const r=this.__v_raw,s=Et(r),i=d(s),l="entries"===e||e===Symbol.iterator&&i,c="keys"===e&&i,a=r[e](...o),u=n?Ke:t?$t:Ot;return!t&&Oe(s,0,c?_e:be),{next(){const{value:e,done:t}=a.next();return t?{value:e,done:t}:{value:l?[u(e[0]),u(e[1])]:u(e),done:t}},[Symbol.iterator](){return this}}}}function ot(e){return function(...t){return"delete"!==e&&this}}function rt(){const e={get(e){return qe(this,e)},get size(){return Ze(this)},has:Je,add:Ye,set:Qe,delete:Xe,clear:et,forEach:tt(!1,!1)},t={get(e){return qe(this,e,!1,!0)},get size(){return Ze(this)},has:Je,add:Ye,set:Qe,delete:Xe,clear:et,forEach:tt(!1,!0)},n={get(e){return qe(this,e,!0)},get size(){return Ze(this,!0)},has(e){return Je.call(this,e,!0)},add:ot("add"),set:ot("set"),delete:ot("delete"),clear:ot("clear"),forEach:tt(!0,!1)},o={get(e){return qe(this,e,!0,!0)},get size(){return Ze(this,!0)},has(e){return Je.call(this,e,!0)},add:ot("add"),set:ot("set"),delete:ot("delete"),clear:ot("clear"),forEach:tt(!0,!0)};return["keys","values","entries",Symbol.iterator].forEach((r=>{e[r]=nt(r,!1,!1),n[r]=nt(r,!0,!1),t[r]=nt(r,!1,!0),o[r]=nt(r,!0,!0)})),[e,n,t,o]}const[st,it,lt,ct]=rt();function at(e,t){const n=t?e?ct:lt:e?it:st;return(t,o,r)=>"__v_isReactive"===o?!e:"__v_isReadonly"===o?e:"__v_raw"===o?t:Reflect.get(p(n,o)&&o in t?n:t,o,r)}const ut={get:at(!1,!1)},pt={get:at(!1,!0)},ft={get:at(!0,!1)},dt={get:at(!0,!0)},ht=new WeakMap,mt=new WeakMap,gt=new WeakMap,vt=new WeakMap;function yt(e){return wt(e)?e:xt(e,!1,De,ut,ht)}function bt(e){return xt(e,!1,We,pt,mt)}function _t(e){return xt(e,!0,He,ft,gt)}function St(e){return xt(e,!0,ze,dt,vt)}function xt(e,t,n,o,r){if(!b(e))return e;if(e.__v_raw&&(!t||!e.__v_isReactive))return e;const s=r.get(e);if(s)return s;const i=(l=e).__v_skip||!Object.isExtensible(l)?0:function(e){switch(e){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}(C(l));var l;if(0===i)return e;const c=new Proxy(e,2===i?o:n);return r.set(e,c),c}function Ct(e){return wt(e)?Ct(e.__v_raw):!(!e||!e.__v_isReactive)}function wt(e){return!(!e||!e.__v_isReadonly)}function kt(e){return!(!e||!e.__v_isShallow)}function Tt(e){return Ct(e)||wt(e)}function Et(e){const t=e&&e.__v_raw;return t?Et(t):e}function Nt(e){return I(e,"__v_skip",!0),e}const Ot=e=>b(e)?yt(e):e,$t=e=>b(e)?_t(e):e;function Pt(e){ke&&ye&&$e((e=Et(e)).dep||(e.dep=pe()))}function Rt(e,t){const n=(e=Et(e)).dep;n&&Re(n)}function At(e){return!(!e||!0!==e.__v_isRef)}function Ft(e){return Vt(e,!1)}function Mt(e){return Vt(e,!0)}function Vt(e,t){return At(e)?e:new It(e,t)}class It{constructor(e,t){this.__v_isShallow=t,this.dep=void 0,this.__v_isRef=!0,this._rawValue=t?e:Et(e),this._value=t?e:Ot(e)}get value(){return Pt(this),this._value}set value(e){const t=this.__v_isShallow||kt(e)||wt(e);e=t?e:Et(e),M(e,this._rawValue)&&(this._rawValue=e,this._value=t?e:Ot(e),Rt(this))}}function Bt(e){Rt(e)}function Lt(e){return At(e)?e.value:e}function jt(e){return g(e)?e():Lt(e)}const Ut={get:(e,t,n)=>Lt(Reflect.get(e,t,n)),set:(e,t,n,o)=>{const r=e[t];return At(r)&&!At(n)?(r.value=n,!0):Reflect.set(e,t,n,o)}};function Dt(e){return Ct(e)?e:new Proxy(e,Ut)}class Ht{constructor(e){this.dep=void 0,this.__v_isRef=!0;const{get:t,set:n}=e((()=>Pt(this)),(()=>Rt(this)));this._get=t,this._set=n}get value(){return this._get()}set value(e){this._set(e)}}function Wt(e){return new Ht(e)}function zt(e){const t=f(e)?new Array(e.length):{};for(const n in e)t[n]=Jt(e,n);return t}class Kt{constructor(e,t,n){this._object=e,this._key=t,this._defaultValue=n,this.__v_isRef=!0}get value(){const e=this._object[this._key];return void 0===e?this._defaultValue:e}set value(e){this._object[this._key]=e}get dep(){return e=Et(this._object),t=this._key,null==(n=he.get(e))?void 0:n.get(t);var e,t,n}}class Gt{constructor(e){this._getter=e,this.__v_isRef=!0,this.__v_isReadonly=!0}get value(){return this._getter()}}function qt(e,t,n){return At(e)?e:g(e)?new Gt(e):b(e)&&arguments.length>1?Jt(e,t,n):Ft(e)}function Jt(e,t,n){const o=e[t];return At(o)?o:new Kt(e,t,n)}class Zt{constructor(e,t,n,o){this._setter=t,this.dep=void 0,this.__v_isRef=!0,this.__v_isReadonly=!1,this._dirty=!0,this.effect=new Se(e,(()=>{this._dirty||(this._dirty=!0,Rt(this))})),this.effect.computed=this,this.effect.active=this._cacheable=!o,this.__v_isReadonly=n}get value(){const e=Et(this);return Pt(e),!e._dirty&&e._cacheable||(e._dirty=!1,e._value=e.effect.run()),e._value}set value(e){this._setter(e)}}function Yt(e,...t){}function Qt(e,t){}function Xt(e,t,n,o){let r;try{r=o?e(...o):e()}catch(s){tn(s,t,n)}return r}function en(e,t,n,o){if(g(e)){const r=Xt(e,t,n,o);return r&&_(r)&&r.catch((e=>{tn(e,t,n)})),r}const r=[];for(let s=0;s>>1,r=rn[o],s=yn(r);syn(e)-yn(t))),an=0;annull==e.id?1/0:e.id,bn=(e,t)=>{const n=yn(e)-yn(t);if(0===n){if(e.pre&&!t.pre)return-1;if(t.pre&&!e.pre)return 1}return n};function _n(e){on=!1,nn=!0,rn.sort(bn);try{for(sn=0;snSn.emit(e,...t))),xn=[];else if("undefined"!=typeof window&&window.HTMLElement&&!(null==(o=null==(n=window.navigator)?void 0:n.userAgent)?void 0:o.includes("jsdom"))){(t.__VUE_DEVTOOLS_HOOK_REPLAY__=t.__VUE_DEVTOOLS_HOOK_REPLAY__||[]).push((e=>{Cn(e,t)})),setTimeout((()=>{Sn||(t.__VUE_DEVTOOLS_HOOK_REPLAY__=null,xn=[])}),3e3)}else xn=[]}function wn(e,n,...o){if(e.isUnmounted)return;const r=e.vnode.props||t;let s=o;const i=n.startsWith("update:"),l=i&&n.slice(7);if(l&&l in r){const e=`${"modelValue"===l?"model":l}Modifiers`,{number:n,trim:i}=r[e]||t;i&&(s=o.map((e=>v(e)?e.trim():e))),n&&(s=o.map(B))}let c,a=r[c=F(n)]||r[c=F($(n))];!a&&i&&(a=r[c=F(R(n))]),a&&en(a,e,6,s);const u=r[c+"Once"];if(u){if(e.emitted){if(e.emitted[c])return}else e.emitted={};e.emitted[c]=!0,en(u,e,6,s)}}function kn(e,t,n=!1){const o=t.emitsCache,r=o.get(e);if(void 0!==r)return r;const s=e.emits;let i={},l=!1;if(!g(e)){const o=e=>{const n=kn(e,t,!0);n&&(l=!0,c(i,n))};!n&&t.mixins.length&&t.mixins.forEach(o),e.extends&&o(e.extends),e.mixins&&e.mixins.forEach(o)}return s||l?(f(s)?s.forEach((e=>i[e]=null)):c(i,s),b(e)&&o.set(e,i),i):(b(e)&&o.set(e,null),null)}function Tn(e,t){return!(!e||!i(t))&&(t=t.slice(2).replace(/Once$/,""),p(e,t[0].toLowerCase()+t.slice(1))||p(e,R(t))||p(e,t))}let En=null,Nn=null;function On(e){const t=En;return En=e,Nn=e&&e.type.__scopeId||null,t}function $n(e){Nn=e}function Pn(){Nn=null}const Rn=e=>An;function An(e,t=En,n){if(!t)return e;if(e._n)return e;const o=(...n)=>{o._d&&Ts(-1);const r=On(t);let s;try{s=e(...n)}finally{On(r),o._d&&Ts(1)}return s};return o._n=!0,o._c=!0,o._d=!0,o}function Fn(e){const{type:t,vnode:n,proxy:o,withProxy:r,props:s,propsOptions:[i],slots:c,attrs:a,emit:u,render:p,renderCache:f,data:d,setupState:h,ctx:m,inheritAttrs:g}=e;let v,y;const b=On(e);try{if(4&n.shapeFlag){const e=r||o;v=Hs(p.call(e,e,f,s,h,d,m)),y=a}else{const e=t;0,v=Hs(e(s,e.length>1?{attrs:a,slots:c,emit:u}:null)),y=t.props?a:Mn(a)}}catch(S){Ss.length=0,tn(S,e,1),v=Is(bs)}let _=v;if(y&&!1!==g){const e=Object.keys(y),{shapeFlag:t}=_;e.length&&7&t&&(i&&e.some(l)&&(y=Vn(y,i)),_=Ls(_,y))}return n.dirs&&(_=Ls(_),_.dirs=_.dirs?_.dirs.concat(n.dirs):n.dirs),n.transition&&(_.transition=n.transition),v=_,On(b),v}const Mn=e=>{let t;for(const n in e)("class"===n||"style"===n||i(n))&&((t||(t={}))[n]=e[n]);return t},Vn=(e,t)=>{const n={};for(const o in e)l(o)&&o.slice(9)in t||(n[o]=e[o]);return n};function In(e,t,n){const o=Object.keys(t);if(o.length!==Object.keys(e).length)return!0;for(let r=0;re.__isSuspense,jn={name:"Suspense",__isSuspense:!0,process(e,t,n,o,r,s,i,l,c,a){null==e?function(e,t,n,o,r,s,i,l,c){const{p:a,o:{createElement:u}}=c,p=u("div"),f=e.suspense=Dn(e,r,o,t,p,n,s,i,l,c);a(null,f.pendingBranch=e.ssContent,p,null,o,f,s,i),f.deps>0?(Un(e,"onPending"),Un(e,"onFallback"),a(null,e.ssFallback,t,n,o,null,s,i),zn(f,e.ssFallback)):f.resolve(!1,!0)}(t,n,o,r,s,i,l,c,a):function(e,t,n,o,r,s,i,l,{p:c,um:a,o:{createElement:u}}){const p=t.suspense=e.suspense;p.vnode=t,t.el=e.el;const f=t.ssContent,d=t.ssFallback,{activeBranch:h,pendingBranch:m,isInFallback:g,isHydrating:v}=p;if(m)p.pendingBranch=f,Ps(f,m)?(c(m,f,p.hiddenContainer,null,r,p,s,i,l),p.deps<=0?p.resolve():g&&(c(h,d,n,o,r,null,s,i,l),zn(p,d))):(p.pendingId++,v?(p.isHydrating=!1,p.activeBranch=m):a(m,r,p),p.deps=0,p.effects.length=0,p.hiddenContainer=u("div"),g?(c(null,f,p.hiddenContainer,null,r,p,s,i,l),p.deps<=0?p.resolve():(c(h,d,n,o,r,null,s,i,l),zn(p,d))):h&&Ps(f,h)?(c(h,f,n,o,r,p,s,i,l),p.resolve(!0)):(c(null,f,p.hiddenContainer,null,r,p,s,i,l),p.deps<=0&&p.resolve()));else if(h&&Ps(f,h))c(h,f,n,o,r,p,s,i,l),zn(p,f);else if(Un(t,"onPending"),p.pendingBranch=f,p.pendingId++,c(null,f,p.hiddenContainer,null,r,p,s,i,l),p.deps<=0)p.resolve();else{const{timeout:e,pendingId:t}=p;e>0?setTimeout((()=>{p.pendingId===t&&p.fallback(d)}),e):0===e&&p.fallback(d)}}(e,t,n,o,r,i,l,c,a)},hydrate:function(e,t,n,o,r,s,i,l,c){const a=t.suspense=Dn(t,o,n,e.parentNode,document.createElement("div"),null,r,s,i,l,!0),u=c(e,a.pendingBranch=t.ssContent,n,a,s,i);0===a.deps&&a.resolve(!1,!0);return u},create:Dn,normalize:function(e){const{shapeFlag:t,children:n}=e,o=32&t;e.ssContent=Hn(o?n.default:n),e.ssFallback=o?Hn(n.fallback):Is(bs)}};function Un(e,t){const n=e.props&&e.props[t];g(n)&&n()}function Dn(e,t,n,o,r,s,i,l,c,a,u=!1){const{p:p,m:f,um:d,n:h,o:{parentNode:m,remove:g}}=a;let v;const y=function(e){var t;return null!=(null==(t=e.props)?void 0:t.suspensible)&&!1!==e.props.suspensible}(e);y&&(null==t?void 0:t.pendingBranch)&&(v=t.pendingId,t.deps++);const b=e.props?L(e.props.timeout):void 0,_={vnode:e,parent:t,parentComponent:n,isSVG:i,container:o,hiddenContainer:r,anchor:s,deps:0,pendingId:0,timeout:"number"==typeof b?b:-1,activeBranch:null,pendingBranch:null,isInFallback:!0,isHydrating:u,isUnmounted:!1,effects:[],resolve(e=!1,n=!1){const{vnode:o,activeBranch:r,pendingBranch:s,pendingId:i,effects:l,parentComponent:c,container:a}=_;let u=!1;if(_.isHydrating)_.isHydrating=!1;else if(!e){u=r&&s.transition&&"out-in"===s.transition.mode,u&&(r.transition.afterLeave=()=>{i===_.pendingId&&(f(s,a,e,0),mn(l))});let{anchor:e}=_;r&&(e=h(r),d(r,c,_,!0)),u||f(s,a,e,0)}zn(_,s),_.pendingBranch=null,_.isInFallback=!1;let p=_.parent,m=!1;for(;p;){if(p.pendingBranch){p.effects.push(...l),m=!0;break}p=p.parent}m||u||mn(l),_.effects=[],y&&t&&t.pendingBranch&&v===t.pendingId&&(t.deps--,0!==t.deps||n||t.resolve()),Un(o,"onResolve")},fallback(e){if(!_.pendingBranch)return;const{vnode:t,activeBranch:n,parentComponent:o,container:r,isSVG:s}=_;Un(t,"onFallback");const i=h(n),a=()=>{_.isInFallback&&(p(null,e,r,i,o,null,s,l,c),zn(_,e))},u=e.transition&&"out-in"===e.transition.mode;u&&(n.transition.afterLeave=a),_.isInFallback=!0,d(n,o,null,!0),u||a()},move(e,t,n){_.activeBranch&&f(_.activeBranch,e,t,n),_.container=e},next:()=>_.activeBranch&&h(_.activeBranch),registerDep(e,t){const n=!!_.pendingBranch;n&&_.deps++;const o=e.vnode.el;e.asyncDep.catch((t=>{tn(t,e,0)})).then((r=>{if(e.isUnmounted||_.isUnmounted||_.pendingId!==e.suspenseId)return;e.asyncResolved=!0;const{vnode:s}=e;si(e,r,!1),o&&(s.el=o);const l=!o&&e.subTree.el;t(e,s,m(o||e.subTree.el),o?null:h(e.subTree),_,i,c),l&&g(l),Bn(e,s.el),n&&0==--_.deps&&_.resolve()}))},unmount(e,t){_.isUnmounted=!0,_.activeBranch&&d(_.activeBranch,n,e,t),_.pendingBranch&&d(_.pendingBranch,n,e,t)}};return _}function Hn(e){let t;if(g(e)){const n=ks&&e._c;n&&(e._d=!1,Cs()),e=e(),n&&(e._d=!0,t=xs,ws())}if(f(e)){const t=function(e){let t;for(let n=0;nt!==e))),e}function Wn(e,t){t&&t.pendingBranch?f(e)?t.effects.push(...e):t.effects.push(e):mn(e)}function zn(e,t){e.activeBranch=t;const{vnode:n,parentComponent:o}=e,r=n.el=t.el;o&&o.subTree===n&&(o.vnode.el=r,Bn(o,r))}function Kn(e,t){return Yn(e,null,t)}function Gn(e,t){return Yn(e,null,{flush:"post"})}function qn(e,t){return Yn(e,null,{flush:"sync"})}const Jn={};function Zn(e,t,n){return Yn(e,t,n)}function Yn(e,n,{immediate:r,deep:s,flush:i}=t){var l;const c=ae()===(null==(l=Zs)?void 0:l.scope)?Zs:null;let u,p,d=!1,h=!1;if(At(e)?(u=()=>e.value,d=kt(e)):Ct(e)?(u=()=>e,s=!0):f(e)?(h=!0,d=e.some((e=>Ct(e)||kt(e))),u=()=>e.map((e=>At(e)?e.value:Ct(e)?eo(e):g(e)?Xt(e,c,2):void 0))):u=g(e)?n?()=>Xt(e,c,2):()=>{if(!c||!c.isUnmounted)return p&&p(),en(e,c,3,[m])}:o,n&&s){const e=u;u=()=>eo(e())}let m=e=>{p=_.onStop=()=>{Xt(e,c,4)}},v=h?new Array(e.length).fill(Jn):Jn;const y=()=>{if(_.active)if(n){const e=_.run();(s||d||(h?e.some(((e,t)=>M(e,v[t]))):M(e,v)))&&(p&&p(),en(n,c,3,[e,v===Jn?void 0:h&&v[0]===Jn?[]:v,m]),v=e)}else _.run()};let b;y.allowRecurse=!!n,"sync"===i?b=y:"post"===i?b=()=>rs(y,c&&c.suspense):(y.pre=!0,c&&(y.id=c.uid),b=()=>dn(y));const _=new Se(u,b);n?r?y():v=_.run():"post"===i?rs(_.run.bind(_),c&&c.suspense):_.run();return()=>{_.stop(),c&&c.scope&&a(c.scope.effects,_)}}function Qn(e,t,n){const o=this.proxy,r=v(e)?e.includes(".")?Xn(o,e):()=>o[e]:e.bind(o,o);let s;g(t)?s=t:(s=t.handler,n=t);const i=Zs;Xs(this);const l=Yn(r,s.bind(o),n);return i?Xs(i):ei(),l}function Xn(e,t){const n=t.split(".");return()=>{let t=e;for(let e=0;e{eo(e,t)}));else if(w(e))for(const n in e)eo(e[n],t);return e}function to(e,n){const o=En;if(null===o)return e;const r=ui(o)||o.proxy,s=e.dirs||(e.dirs=[]);for(let i=0;i{e.isMounted=!0})),Mo((()=>{e.isUnmounting=!0})),e}const io=[Function,Array],lo={mode:String,appear:Boolean,persisted:Boolean,onBeforeEnter:io,onEnter:io,onAfterEnter:io,onEnterCancelled:io,onBeforeLeave:io,onLeave:io,onAfterLeave:io,onLeaveCancelled:io,onBeforeAppear:io,onAppear:io,onAfterAppear:io,onAppearCancelled:io},co={name:"BaseTransition",props:lo,setup(e,{slots:t}){const n=Ys(),o=so();let r;return()=>{const s=t.default&&mo(t.default(),!0);if(!s||!s.length)return;let i=s[0];if(s.length>1)for(const e of s)if(e.type!==bs){i=e;break}const l=Et(e),{mode:c}=l;if(o.isLeaving)return po(i);const a=fo(i);if(!a)return po(i);const u=uo(a,l,o,n);ho(a,u);const p=n.subTree,f=p&&fo(p);let d=!1;const{getTransitionKey:h}=a.type;if(h){const e=h();void 0===r?r=e:e!==r&&(r=e,d=!0)}if(f&&f.type!==bs&&(!Ps(a,f)||d)){const e=uo(f,l,o,n);if(ho(f,e),"out-in"===c)return o.isLeaving=!0,e.afterLeave=()=>{o.isLeaving=!1,!1!==n.update.active&&n.update()},po(i);"in-out"===c&&a.type!==bs&&(e.delayLeave=(e,t,n)=>{ao(o,f)[String(f.key)]=f,e[oo]=()=>{t(),e[oo]=void 0,delete u.delayedLeave},u.delayedLeave=n})}return i}}};function ao(e,t){const{leavingVNodes:n}=e;let o=n.get(t.type);return o||(o=Object.create(null),n.set(t.type,o)),o}function uo(e,t,n,o){const{appear:r,mode:s,persisted:i=!1,onBeforeEnter:l,onEnter:c,onAfterEnter:a,onEnterCancelled:u,onBeforeLeave:p,onLeave:d,onAfterLeave:h,onLeaveCancelled:m,onBeforeAppear:g,onAppear:v,onAfterAppear:y,onAppearCancelled:b}=t,_=String(e.key),S=ao(n,e),x=(e,t)=>{e&&en(e,o,9,t)},C=(e,t)=>{const n=t[1];x(e,t),f(e)?e.every((e=>e.length<=1))&&n():e.length<=1&&n()},w={mode:s,persisted:i,beforeEnter(t){let o=l;if(!n.isMounted){if(!r)return;o=g||l}t[oo]&&t[oo](!0);const s=S[_];s&&Ps(e,s)&&s.el[oo]&&s.el[oo](),x(o,[t])},enter(e){let t=c,o=a,s=u;if(!n.isMounted){if(!r)return;t=v||c,o=y||a,s=b||u}let i=!1;const l=e[ro]=t=>{i||(i=!0,x(t?s:o,[e]),w.delayedLeave&&w.delayedLeave(),e[ro]=void 0)};t?C(t,[e,l]):l()},leave(t,o){const r=String(e.key);if(t[ro]&&t[ro](!0),n.isUnmounting)return o();x(p,[t]);let s=!1;const i=t[oo]=n=>{s||(s=!0,o(),x(n?m:h,[t]),t[oo]=void 0,S[r]===e&&delete S[r])};S[r]=e,d?C(d,[t,i]):i()},clone:e=>uo(e,t,n,o)};return w}function po(e){if(_o(e))return(e=Ls(e)).children=null,e}function fo(e){return _o(e)?e.children?e.children[0]:void 0:e}function ho(e,t){6&e.shapeFlag&&e.component?ho(e.component.subTree,t):128&e.shapeFlag?(e.ssContent.transition=t.clone(e.ssContent),e.ssFallback.transition=t.clone(e.ssFallback)):e.transition=t}function mo(e,t=!1,n){let o=[],r=0;for(let s=0;s1)for(let s=0;sc({name:e.name},t,{setup:e}))():e}const vo=e=>!!e.type.__asyncLoader -/*! #__NO_SIDE_EFFECTS__ */;function yo(e){g(e)&&(e={loader:e});const{loader:t,loadingComponent:n,errorComponent:o,delay:r=200,timeout:s,suspensible:i=!0,onError:l}=e;let c,a=null,u=0;const p=()=>{let e;return a||(e=a=t().catch((e=>{if(e=e instanceof Error?e:new Error(String(e)),l)return new Promise(((t,n)=>{l(e,(()=>t((u++,a=null,p()))),(()=>n(e)),u+1)}));throw e})).then((t=>e!==a&&a?a:(t&&(t.__esModule||"Module"===t[Symbol.toStringTag])&&(t=t.default),c=t,t))))};return go({name:"AsyncComponentWrapper",__asyncLoader:p,get __asyncResolved(){return c},setup(){const e=Zs;if(c)return()=>bo(c,e);const t=t=>{a=null,tn(t,e,13,!o)};if(i&&e.suspense)return p().then((t=>()=>bo(t,e))).catch((e=>(t(e),()=>o?Is(o,{error:e}):null)));const l=Ft(!1),u=Ft(),f=Ft(!!r);return r&&setTimeout((()=>{f.value=!1}),r),null!=s&&setTimeout((()=>{if(!l.value&&!u.value){const e=new Error(`Async component timed out after ${s}ms.`);t(e),u.value=e}}),s),p().then((()=>{l.value=!0,e.parent&&_o(e.parent.vnode)&&dn(e.parent.update)})).catch((e=>{t(e),u.value=e})),()=>l.value&&c?bo(c,e):u.value&&o?Is(o,{error:u.value}):n&&!f.value?Is(n):void 0}})}function bo(e,t){const{ref:n,props:o,children:r,ce:s}=t.vnode,i=Is(e,o,r);return i.ref=n,i.ce=s,delete t.vnode.ce,i}const _o=e=>e.type.__isKeepAlive,So={name:"KeepAlive",__isKeepAlive:!0,props:{include:[String,RegExp,Array],exclude:[String,RegExp,Array],max:[String,Number]},setup(e,{slots:t}){const n=Ys(),o=n.ctx,r=new Map,s=new Set;let i=null;const l=n.suspense,{renderer:{p:c,m:a,um:u,o:{createElement:p}}}=o,f=p("div");function d(e){Eo(e),u(e,n,l,!0)}function h(e){r.forEach(((t,n)=>{const o=pi(t.type);!o||e&&e(o)||m(n)}))}function m(e){const t=r.get(e);i&&Ps(t,i)?i&&Eo(i):d(t),r.delete(e),s.delete(e)}o.activate=(e,t,n,o,r)=>{const s=e.component;a(e,t,n,0,l),c(s.vnode,e,t,n,s,l,o,e.slotScopeIds,r),rs((()=>{s.isDeactivated=!1,s.a&&V(s.a);const t=e.props&&e.props.onVnodeMounted;t&&Gs(t,s.parent,e)}),l)},o.deactivate=e=>{const t=e.component;a(e,f,null,1,l),rs((()=>{t.da&&V(t.da);const n=e.props&&e.props.onVnodeUnmounted;n&&Gs(n,t.parent,e),t.isDeactivated=!0}),l)},Zn((()=>[e.include,e.exclude]),(([e,t])=>{e&&h((t=>xo(e,t))),t&&h((e=>!xo(t,e)))}),{flush:"post",deep:!0});let g=null;const v=()=>{null!=g&&r.set(g,No(n.subTree))};return Ro(v),Fo(v),Mo((()=>{r.forEach((e=>{const{subTree:t,suspense:o}=n,r=No(t);if(e.type!==r.type||e.key!==r.key)d(e);else{Eo(r);const e=r.component.da;e&&rs(e,o)}}))})),()=>{if(g=null,!t.default)return null;const n=t.default(),o=n[0];if(n.length>1)return i=null,n;if(!($s(o)&&(4&o.shapeFlag||128&o.shapeFlag)))return i=null,o;let l=No(o);const c=l.type,a=pi(vo(l)?l.type.__asyncResolved||{}:c),{include:u,exclude:p,max:f}=e;if(u&&(!a||!xo(u,a))||p&&a&&xo(p,a))return i=l,o;const d=null==l.key?c:l.key,h=r.get(d);return l.el&&(l=Ls(l),128&o.shapeFlag&&(o.ssContent=l)),g=d,h?(l.el=h.el,l.component=h.component,l.transition&&ho(l,l.transition),l.shapeFlag|=512,s.delete(d),s.add(d)):(s.add(d),f&&s.size>parseInt(f,10)&&m(s.values().next().value)),l.shapeFlag|=256,i=l,Ln(o.type)?o:l}}};function xo(e,t){return f(e)?e.some((e=>xo(e,t))):v(e)?e.split(",").includes(t):"[object RegExp]"===x(e)&&e.test(t)}function Co(e,t){ko(e,"a",t)}function wo(e,t){ko(e,"da",t)}function ko(e,t,n=Zs){const o=e.__wdc||(e.__wdc=()=>{let t=n;for(;t;){if(t.isDeactivated)return;t=t.parent}return e()});if(Oo(t,o,n),n){let e=n.parent;for(;e&&e.parent;)_o(e.parent.vnode)&&To(o,t,n,e),e=e.parent}}function To(e,t,n,o){const r=Oo(t,e,o,!0);Vo((()=>{a(o[t],r)}),n)}function Eo(e){e.shapeFlag&=-257,e.shapeFlag&=-513}function No(e){return 128&e.shapeFlag?e.ssContent:e}function Oo(e,t,n=Zs,o=!1){if(n){const r=n[e]||(n[e]=[]),s=t.__weh||(t.__weh=(...o)=>{if(n.isUnmounted)return;Ee(),Xs(n);const r=en(t,n,e,o);return ei(),Ne(),r});return o?r.unshift(s):r.push(s),s}}const $o=e=>(t,n=Zs)=>(!ri||"sp"===e)&&Oo(e,((...e)=>t(...e)),n),Po=$o("bm"),Ro=$o("m"),Ao=$o("bu"),Fo=$o("u"),Mo=$o("bum"),Vo=$o("um"),Io=$o("sp"),Bo=$o("rtg"),Lo=$o("rtc");function jo(e,t=Zs){Oo("ec",e,t)}const Uo="components";function Do(e,t){return Ko(Uo,e,!0,t)||e}const Ho=Symbol.for("v-ndc");function Wo(e){return v(e)?Ko(Uo,e,!1)||e:e||Ho}function zo(e){return Ko("directives",e)}function Ko(e,t,n=!0,o=!1){const r=En||Zs;if(r){const n=r.type;if(e===Uo){const e=pi(n,!1);if(e&&(e===t||e===$(t)||e===A($(t))))return n}const s=Go(r[e]||n[e],t)||Go(r.appContext[e],t);return!s&&o?n:s}}function Go(e,t){return e&&(e[t]||e[$(t)]||e[A($(t))])}function qo(e,t,n,o){let r;const s=n&&n[o];if(f(e)||v(e)){r=new Array(e.length);for(let n=0,o=e.length;nt(e,n,void 0,s&&s[n])));else{const n=Object.keys(e);r=new Array(n.length);for(let o=0,i=n.length;o{const t=o.fn(...e);return t&&(t.key=o.key),t}:o.fn)}return e}function Zo(e,t,n={},o,r){if(En.isCE||En.parent&&vo(En.parent)&&En.parent.isCE)return"default"!==t&&(n.name=t),Is("slot",n,o&&o());let s=e[t];s&&s._c&&(s._d=!1),Cs();const i=s&&Yo(s(n)),l=Os(vs,{key:n.key||i&&i.key||`_${t}`},i||(o?o():[]),i&&1===e._?64:-2);return!r&&l.scopeId&&(l.slotScopeIds=[l.scopeId+"-s"]),s&&s._c&&(s._d=!0),l}function Yo(e){return e.some((e=>!$s(e)||e.type!==bs&&!(e.type===vs&&!Yo(e.children))))?e:null}function Qo(e,t){const n={};for(const o in e)n[t&&/[A-Z]/.test(o)?`on:${o}`:F(o)]=e[o];return n}const Xo=e=>e?ti(e)?ui(e)||e.proxy:Xo(e.parent):null,er=c(Object.create(null),{$:e=>e,$el:e=>e.vnode.el,$data:e=>e.data,$props:e=>e.props,$attrs:e=>e.attrs,$slots:e=>e.slots,$refs:e=>e.refs,$parent:e=>Xo(e.parent),$root:e=>Xo(e.root),$emit:e=>e.emit,$options:e=>wr(e),$forceUpdate:e=>e.f||(e.f=()=>dn(e.update)),$nextTick:e=>e.n||(e.n=fn.bind(e.proxy)),$watch:e=>Qn.bind(e)}),tr=(e,n)=>e!==t&&!e.__isScriptSetup&&p(e,n),nr={get({_:e},n){const{ctx:o,setupState:r,data:s,props:i,accessCache:l,type:c,appContext:a}=e;let u;if("$"!==n[0]){const c=l[n];if(void 0!==c)switch(c){case 1:return r[n];case 2:return s[n];case 4:return o[n];case 3:return i[n]}else{if(tr(r,n))return l[n]=1,r[n];if(s!==t&&p(s,n))return l[n]=2,s[n];if((u=e.propsOptions[0])&&p(u,n))return l[n]=3,i[n];if(o!==t&&p(o,n))return l[n]=4,o[n];_r&&(l[n]=0)}}const f=er[n];let d,h;return f?("$attrs"===n&&Oe(e,0,n),f(e)):(d=c.__cssModules)&&(d=d[n])?d:o!==t&&p(o,n)?(l[n]=4,o[n]):(h=a.config.globalProperties,p(h,n)?h[n]:void 0)},set({_:e},n,o){const{data:r,setupState:s,ctx:i}=e;return tr(s,n)?(s[n]=o,!0):r!==t&&p(r,n)?(r[n]=o,!0):!p(e.props,n)&&(("$"!==n[0]||!(n.slice(1)in e))&&(i[n]=o,!0))},has({_:{data:e,setupState:n,accessCache:o,ctx:r,appContext:s,propsOptions:i}},l){let c;return!!o[l]||e!==t&&p(e,l)||tr(n,l)||(c=i[0])&&p(c,l)||p(r,l)||p(er,l)||p(s.config.globalProperties,l)},defineProperty(e,t,n){return null!=n.get?e._.accessCache[t]=0:p(n,"value")&&this.set(e,t,n.value,null),Reflect.defineProperty(e,t,n)}},or=c({},nr,{get(e,t){if(t!==Symbol.unscopables)return nr.get(e,t,e)},has:(e,t)=>"_"!==t[0]&&!D(t)});function rr(){return null}function sr(){return null}function ir(e){}function lr(e){}function cr(){return null}function ar(){}function ur(e,t){return null}function pr(){return hr().slots}function fr(){return hr().attrs}function dr(e,t,n){const o=Ys();if(n&&n.local){const n=Ft(e[t]);return Zn((()=>e[t]),(e=>n.value=e)),Zn(n,(n=>{n!==e[t]&&o.emit(`update:${t}`,n)})),n}return{__v_isRef:!0,get value(){return e[t]},set value(e){o.emit(`update:${t}`,e)}}}function hr(){const e=Ys();return e.setupContext||(e.setupContext=ai(e))}function mr(e){return f(e)?e.reduce(((e,t)=>(e[t]=null,e)),{}):e}function gr(e,t){const n=mr(e);for(const o in t){if(o.startsWith("__skip"))continue;let e=n[o];e?f(e)||g(e)?e=n[o]={type:e,default:t[o]}:e.default=t[o]:null===e&&(e=n[o]={default:t[o]}),e&&t[`__skip_${o}`]&&(e.skipFactory=!0)}return n}function vr(e,t){return e&&t?f(e)&&f(t)?e.concat(t):c({},mr(e),mr(t)):e||t}function yr(e,t){const n={};for(const o in e)t.includes(o)||Object.defineProperty(n,o,{enumerable:!0,get:()=>e[o]});return n}function br(e){const t=Ys();let n=e();return ei(),_(n)&&(n=n.catch((e=>{throw Xs(t),e}))),[n,()=>Xs(t)]}let _r=!0;function Sr(e){const t=wr(e),n=e.proxy,r=e.ctx;_r=!1,t.beforeCreate&&xr(t.beforeCreate,e,"bc");const{data:s,computed:i,methods:l,watch:c,provide:a,inject:u,created:p,beforeMount:d,mounted:h,beforeUpdate:m,updated:v,activated:y,deactivated:_,beforeUnmount:S,unmounted:x,render:C,renderTracked:w,renderTriggered:k,errorCaptured:T,serverPrefetch:E,expose:N,inheritAttrs:O,components:$,directives:P}=t;if(u&&function(e,t,n=o){f(e)&&(e=Nr(e));for(const o in e){const n=e[o];let r;r=b(n)?"default"in n?Ir(n.from||o,n.default,!0):Ir(n.from||o):Ir(n),At(r)?Object.defineProperty(t,o,{enumerable:!0,configurable:!0,get:()=>r.value,set:e=>r.value=e}):t[o]=r}}(u,r,null),l)for(const o in l){const e=l[o];g(e)&&(r[o]=e.bind(n))}if(s){const t=s.call(n,n);b(t)&&(e.data=yt(t))}if(_r=!0,i)for(const f in i){const e=i[f],t=g(e)?e.bind(n,n):g(e.get)?e.get.bind(n,n):o,s=!g(e)&&g(e.set)?e.set.bind(n):o,l=fi({get:t,set:s});Object.defineProperty(r,f,{enumerable:!0,configurable:!0,get:()=>l.value,set:e=>l.value=e})}if(c)for(const o in c)Cr(c[o],r,n,o);if(a){const e=g(a)?a.call(n):a;Reflect.ownKeys(e).forEach((t=>{Vr(t,e[t])}))}function R(e,t){f(t)?t.forEach((t=>e(t.bind(n)))):t&&e(t.bind(n))}if(p&&xr(p,e,"c"),R(Po,d),R(Ro,h),R(Ao,m),R(Fo,v),R(Co,y),R(wo,_),R(jo,T),R(Lo,w),R(Bo,k),R(Mo,S),R(Vo,x),R(Io,E),f(N))if(N.length){const t=e.exposed||(e.exposed={});N.forEach((e=>{Object.defineProperty(t,e,{get:()=>n[e],set:t=>n[e]=t})}))}else e.exposed||(e.exposed={});C&&e.render===o&&(e.render=C),null!=O&&(e.inheritAttrs=O),$&&(e.components=$),P&&(e.directives=P)}function xr(e,t,n){en(f(e)?e.map((e=>e.bind(t.proxy))):e.bind(t.proxy),t,n)}function Cr(e,t,n,o){const r=o.includes(".")?Xn(n,o):()=>n[o];if(v(e)){const n=t[e];g(n)&&Zn(r,n)}else if(g(e))Zn(r,e.bind(n));else if(b(e))if(f(e))e.forEach((e=>Cr(e,t,n,o)));else{const o=g(e.handler)?e.handler.bind(n):t[e.handler];g(o)&&Zn(r,o,e)}}function wr(e){const t=e.type,{mixins:n,extends:o}=t,{mixins:r,optionsCache:s,config:{optionMergeStrategies:i}}=e.appContext,l=s.get(t);let c;return l?c=l:r.length||n||o?(c={},r.length&&r.forEach((e=>kr(c,e,i,!0))),kr(c,t,i)):c=t,b(t)&&s.set(t,c),c}function kr(e,t,n,o=!1){const{mixins:r,extends:s}=t;s&&kr(e,s,n,!0),r&&r.forEach((t=>kr(e,t,n,!0)));for(const i in t)if(o&&"expose"===i);else{const o=Tr[i]||n&&n[i];e[i]=o?o(e[i],t[i]):t[i]}return e}const Tr={data:Er,props:Pr,emits:Pr,methods:$r,computed:$r,beforeCreate:Or,created:Or,beforeMount:Or,mounted:Or,beforeUpdate:Or,updated:Or,beforeDestroy:Or,beforeUnmount:Or,destroyed:Or,unmounted:Or,activated:Or,deactivated:Or,errorCaptured:Or,serverPrefetch:Or,components:$r,directives:$r,watch:function(e,t){if(!e)return t;if(!t)return e;const n=c(Object.create(null),e);for(const o in t)n[o]=Or(e[o],t[o]);return n},provide:Er,inject:function(e,t){return $r(Nr(e),Nr(t))}};function Er(e,t){return t?e?function(){return c(g(e)?e.call(this,this):e,g(t)?t.call(this,this):t)}:t:e}function Nr(e){if(f(e)){const t={};for(let n=0;n(s.has(e)||(e&&g(e.install)?(s.add(e),e.install(l,...t)):g(e)&&(s.add(e),e(l,...t))),l),mixin:e=>(r.mixins.includes(e)||r.mixins.push(e),l),component:(e,t)=>t?(r.components[e]=t,l):r.components[e],directive:(e,t)=>t?(r.directives[e]=t,l):r.directives[e],mount(s,c,a){if(!i){const u=Is(n,o);return u.appContext=r,c&&t?t(u,s):e(u,s,a),i=!0,l._container=s,s.__vue_app__=l,ui(u.component)||u.component.proxy}},unmount(){i&&(e(null,l._container),delete l._container.__vue_app__)},provide:(e,t)=>(r.provides[e]=t,l),runWithContext(e){Mr=l;try{return e()}finally{Mr=null}}};return l}}let Mr=null;function Vr(e,t){if(Zs){let n=Zs.provides;const o=Zs.parent&&Zs.parent.provides;o===n&&(n=Zs.provides=Object.create(o)),n[e]=t}else;}function Ir(e,t,n=!1){const o=Zs||En;if(o||Mr){const r=o?null==o.parent?o.vnode.appContext&&o.vnode.appContext.provides:o.parent.provides:Mr._context.provides;if(r&&e in r)return r[e];if(arguments.length>1)return n&&g(t)?t.call(o&&o.proxy):t}}function Br(){return!!(Zs||En||Mr)}function Lr(e,n,o,r){const[s,i]=e.propsOptions;let l,c=!1;if(n)for(let t in n){if(T(t))continue;const a=n[t];let u;s&&p(s,u=$(t))?i&&i.includes(u)?(l||(l={}))[u]=a:o[u]=a:Tn(e.emitsOptions,t)||t in r&&a===r[t]||(r[t]=a,c=!0)}if(i){const n=Et(o),r=l||t;for(let t=0;t{d=!0;const[t,n]=Ur(e,o,!0);c(a,t),n&&u.push(...n)};!r&&o.mixins.length&&o.mixins.forEach(t),e.extends&&t(e.extends),e.mixins&&e.mixins.forEach(t)}if(!l&&!d)return b(e)&&s.set(e,n),n;if(f(l))for(let n=0;n-1,o[1]=n<0||t-1||p(o,"default"))&&u.push(e)}}}const h=[a,u];return b(e)&&s.set(e,h),h}function Dr(e){return"$"!==e[0]}function Hr(e){const t=e&&e.toString().match(/^\s*(function|class) (\w+)/);return t?t[2]:null===e?"null":""}function Wr(e,t){return Hr(e)===Hr(t)}function zr(e,t){return f(t)?t.findIndex((t=>Wr(t,e))):g(t)&&Wr(t,e)?0:-1}const Kr=e=>"_"===e[0]||"$stable"===e,Gr=e=>f(e)?e.map(Hs):[Hs(e)],qr=(e,t,n)=>{if(t._n)return t;const o=An(((...e)=>Gr(t(...e))),n);return o._c=!1,o},Jr=(e,t,n)=>{const o=e._ctx;for(const r in e){if(Kr(r))continue;const n=e[r];if(g(n))t[r]=qr(0,n,o);else if(null!=n){const e=Gr(n);t[r]=()=>e}}},Zr=(e,t)=>{const n=Gr(t);e.slots.default=()=>n},Yr=(e,t)=>{if(32&e.vnode.shapeFlag){const n=t._;n?(e.slots=Et(t),I(t,"_",n)):Jr(t,e.slots={})}else e.slots={},t&&Zr(e,t);I(e.slots,As,1)},Qr=(e,n,o)=>{const{vnode:r,slots:s}=e;let i=!0,l=t;if(32&r.shapeFlag){const e=n._;e?o&&1===e?i=!1:(c(s,n),o||1!==e||delete s._):(i=!n.$stable,Jr(n,s)),l=n}else n&&(Zr(e,n),l={default:1});if(i)for(const t in s)Kr(t)||null!=l[t]||delete s[t]};function Xr(e,n,o,r,s=!1){if(f(e))return void e.forEach(((e,t)=>Xr(e,n&&(f(n)?n[t]:n),o,r,s)));if(vo(r)&&!s)return;const i=4&r.shapeFlag?ui(r.component)||r.component.proxy:r.el,l=s?null:i,{i:c,r:u}=e,d=n&&n.r,h=c.refs===t?c.refs={}:c.refs,m=c.setupState;if(null!=d&&d!==u&&(v(d)?(h[d]=null,p(m,d)&&(m[d]=null)):At(d)&&(d.value=null)),g(u))Xt(u,c,12,[l,h]);else{const t=v(u),n=At(u);if(t||n){const r=()=>{if(e.f){const n=t?p(m,u)?m[u]:h[u]:u.value;s?f(n)&&a(n,i):f(n)?n.includes(i)||n.push(i):t?(h[u]=[i],p(m,u)&&(m[u]=h[u])):(u.value=[i],e.k&&(h[e.k]=u.value))}else t?(h[u]=l,p(m,u)&&(m[u]=l)):n&&(u.value=l,e.k&&(h[e.k]=l))};l?(r.id=-1,rs(r,o)):r()}}}let es=!1;const ts=e=>/svg/.test(e.namespaceURI)&&"foreignObject"!==e.tagName,ns=e=>8===e.nodeType;function os(e){const{mt:t,p:n,o:{patchProp:o,createText:r,nextSibling:s,parentNode:l,remove:c,insert:a,createComment:u}}=e,p=(n,o,i,c,u,b=!1)=>{const _=ns(n)&&"["===n.data,S=()=>m(n,o,i,c,u,_),{type:x,ref:C,shapeFlag:w,patchFlag:k}=o;let T=n.nodeType;o.el=n,-2===k&&(b=!1,o.dynamicChildren=null);let E=null;switch(x){case ys:3!==T?""===o.children?(a(o.el=r(""),l(n),n),E=n):E=S():(n.data!==o.children&&(es=!0,n.data=o.children),E=s(n));break;case bs:if(8!==T||_)if("template"===n.tagName.toLowerCase()){const e=o.el.content.firstChild;v(e,n,i),o.el=n=e,E=s(n)}else E=S();else E=s(n);break;case _s:if(_&&(T=(n=s(n)).nodeType),1===T||3===T){E=n;const e=!o.children.length;for(let t=0;t{l=l||!!t.dynamicChildren;const{type:a,props:u,patchFlag:p,shapeFlag:f,dirs:h,transition:m}=t,g="input"===a&&h||"option"===a;if(g||-1!==p){if(h&&no(t,null,n,"created"),u)if(g||!l||48&p)for(const t in u)(g&&t.endsWith("value")||i(t)&&!T(t))&&o(e,t,null,u[t],!1,void 0,n);else u.onClick&&o(e,"onClick",null,u.onClick,!1,void 0,n);let a;(a=u&&u.onVnodeBeforeMount)&&Gs(a,n,t);let b=!1;if(y(e)){b=as(r,m)&&n&&n.vnode.props&&n.vnode.props.appear;const o=e.content.firstChild;b&&m.beforeEnter(o),v(o,e,n),t.el=e=o}if(h&&no(t,null,n,"beforeMount"),((a=u&&u.onVnodeMounted)||h||b)&&Wn((()=>{a&&Gs(a,n,t),b&&m.enter(e),h&&no(t,null,n,"mounted")}),r),16&f&&(!u||!u.innerHTML&&!u.textContent)){let o=d(e.firstChild,t,e,n,r,s,l);for(;o;){es=!0;const e=o;o=o.nextSibling,c(e)}}else 8&f&&e.textContent!==t.children&&(es=!0,e.textContent=t.children)}return e.nextSibling},d=(e,t,o,r,s,i,l)=>{l=l||!!t.dynamicChildren;const c=t.children,a=c.length;for(let u=0;u{const{slotScopeIds:c}=t;c&&(r=r?r.concat(c):c);const p=l(e),f=d(s(e),t,p,n,o,r,i);return f&&ns(f)&&"]"===f.data?s(t.anchor=f):(es=!0,a(t.anchor=u("]"),p,f),f)},m=(e,t,o,r,i,a)=>{if(es=!0,t.el=null,a){const t=g(e);for(;;){const n=s(e);if(!n||n===t)break;c(n)}}const u=s(e),p=l(e);return c(e),n(null,t,p,u,o,r,ts(p),i),u},g=(e,t="[",n="]")=>{let o=0;for(;e;)if((e=s(e))&&ns(e)&&(e.data===t&&o++,e.data===n)){if(0===o)return s(e);o--}return e},v=(e,t,n)=>{const o=t.parentNode;o&&o.replaceChild(e,t);let r=n;for(;r;)r.vnode.el===t&&(r.vnode.el=e,r.subTree.el=e),r=r.parent},y=e=>1===e.nodeType&&"template"===e.tagName.toLowerCase();return[(e,t)=>{if(!t.hasChildNodes())return n(null,e,t),vn(),void(t._vnode=e);es=!1,p(t.firstChild,e,null,null,null),vn(),t._vnode=e,es&&console.error("Hydration completed but contains mismatches.")},p]}const rs=Wn;function ss(e){return ls(e)}function is(e){return ls(e,os)}function ls(e,r){U().__VUE__=!0;const{insert:s,remove:i,patchProp:l,createElement:c,createText:a,createComment:u,setText:f,setElementText:d,parentNode:h,nextSibling:m,setScopeId:g=o,insertStaticContent:v}=e,y=(e,t,n,o=null,r=null,s=null,i=!1,l=null,c=!!t.dynamicChildren)=>{if(e===t)return;e&&!Ps(e,t)&&(o=Y(e),K(e,r,s,!0),e=null),-2===t.patchFlag&&(c=!1,t.dynamicChildren=null);const{type:a,ref:u,shapeFlag:p}=t;switch(a){case ys:b(e,t,n,o);break;case bs:S(e,t,n,o);break;case _s:null==e&&x(t,n,o,i);break;case vs:A(e,t,n,o,r,s,i,l,c);break;default:1&p?C(e,t,n,o,r,s,i,l,c):6&p?F(e,t,n,o,r,s,i,l,c):(64&p||128&p)&&a.process(e,t,n,o,r,s,i,l,c,X)}null!=u&&r&&Xr(u,e&&e.ref,s,t||e,!t)},b=(e,t,n,o)=>{if(null==e)s(t.el=a(t.children),n,o);else{const n=t.el=e.el;t.children!==e.children&&f(n,t.children)}},S=(e,t,n,o)=>{null==e?s(t.el=u(t.children||""),n,o):t.el=e.el},x=(e,t,n,o)=>{[e.el,e.anchor]=v(e.children,t,n,o,e.el,e.anchor)},C=(e,t,n,o,r,s,i,l,c)=>{i=i||"svg"===t.type,null==e?w(t,n,o,r,s,i,l,c):N(e,t,r,s,i,l,c)},w=(e,t,n,o,r,i,a,u)=>{let p,f;const{type:h,props:m,shapeFlag:g,transition:v,dirs:y}=e;if(p=e.el=c(e.type,i,m&&m.is,m),8&g?d(p,e.children):16&g&&E(e.children,p,null,o,r,i&&"foreignObject"!==h,a,u),y&&no(e,null,o,"created"),k(p,e,e.scopeId,a,o),m){for(const t in m)"value"===t||T(t)||l(p,t,null,m[t],i,e.children,o,r,Z);"value"in m&&l(p,"value",null,m.value),(f=m.onVnodeBeforeMount)&&Gs(f,o,e)}y&&no(e,null,o,"beforeMount");const b=as(r,v);b&&v.beforeEnter(p),s(p,t,n),((f=m&&m.onVnodeMounted)||b||y)&&rs((()=>{f&&Gs(f,o,e),b&&v.enter(p),y&&no(e,null,o,"mounted")}),r)},k=(e,t,n,o,r)=>{if(n&&g(e,n),o)for(let s=0;s{for(let a=c;a{const a=n.el=e.el;let{patchFlag:u,dynamicChildren:p,dirs:f}=n;u|=16&e.patchFlag;const h=e.props||t,m=n.props||t;let g;o&&cs(o,!1),(g=m.onVnodeBeforeUpdate)&&Gs(g,o,n,e),f&&no(n,e,o,"beforeUpdate"),o&&cs(o,!0);const v=s&&"foreignObject"!==n.type;if(p?O(e.dynamicChildren,p,a,o,r,v,i):c||D(e,n,a,null,o,r,v,i,!1),u>0){if(16&u)P(a,n,h,m,o,r,s);else if(2&u&&h.class!==m.class&&l(a,"class",null,m.class,s),4&u&&l(a,"style",h.style,m.style,s),8&u){const t=n.dynamicProps;for(let n=0;n{g&&Gs(g,o,n,e),f&&no(n,e,o,"updated")}),r)},O=(e,t,n,o,r,s,i)=>{for(let l=0;l{if(o!==r){if(o!==t)for(const t in o)T(t)||t in r||l(e,t,o[t],null,c,n.children,s,i,Z);for(const t in r){if(T(t))continue;const a=r[t],u=o[t];a!==u&&"value"!==t&&l(e,t,u,a,c,n.children,s,i,Z)}"value"in r&&l(e,"value",o.value,r.value)}},A=(e,t,n,o,r,i,l,c,u)=>{const p=t.el=e?e.el:a(""),f=t.anchor=e?e.anchor:a("");let{patchFlag:d,dynamicChildren:h,slotScopeIds:m}=t;m&&(c=c?c.concat(m):m),null==e?(s(p,n,o),s(f,n,o),E(t.children,n,f,r,i,l,c,u)):d>0&&64&d&&h&&e.dynamicChildren?(O(e.dynamicChildren,h,n,r,i,l,c),(null!=t.key||r&&t===r.subTree)&&us(e,t,!0)):D(e,t,n,f,r,i,l,c,u)},F=(e,t,n,o,r,s,i,l,c)=>{t.slotScopeIds=l,null==e?512&t.shapeFlag?r.ctx.activate(t,n,o,i,c):M(t,n,o,r,s,i,c):B(e,t,c)},M=(e,n,o,r,s,i,l)=>{const c=e.component=function(e,n,o){const r=e.type,s=(n?n.appContext:e.appContext)||qs,i={uid:Js++,vnode:e,type:r,parent:n,appContext:s,root:null,next:null,subTree:null,effect:null,update:null,scope:new ie(!0),render:null,proxy:null,exposed:null,exposeProxy:null,withProxy:null,provides:n?n.provides:Object.create(s.provides),accessCache:null,renderCache:[],components:null,directives:null,propsOptions:Ur(r,s),emitsOptions:kn(r,s),emit:null,emitted:null,propsDefaults:t,inheritAttrs:r.inheritAttrs,ctx:t,data:t,props:t,attrs:t,slots:t,refs:t,setupState:t,setupContext:null,attrsProxy:null,slotsProxy:null,suspense:o,suspenseId:o?o.pendingId:0,asyncDep:null,asyncResolved:!1,isMounted:!1,isUnmounted:!1,isDeactivated:!1,bc:null,c:null,bm:null,m:null,bu:null,u:null,um:null,bum:null,da:null,a:null,rtg:null,rtc:null,ec:null,sp:null};i.ctx={_:i},i.root=n?n.root:i,i.emit=wn.bind(null,i),e.ce&&e.ce(i);return i}(e,r,s);if(_o(e)&&(c.ctx.renderer=X),function(e,t=!1){ri=t;const{props:n,children:o}=e.vnode,r=ti(e);(function(e,t,n,o=!1){const r={},s={};I(s,As,1),e.propsDefaults=Object.create(null),Lr(e,t,r,s);for(const i in e.propsOptions[0])i in r||(r[i]=void 0);e.props=n?o?r:bt(r):e.type.props?r:s,e.attrs=s})(e,n,r,t),Yr(e,o);const s=r?function(e,t){const n=e.type;e.accessCache=Object.create(null),e.proxy=Nt(new Proxy(e.ctx,nr));const{setup:o}=n;if(o){const n=e.setupContext=o.length>1?ai(e):null;Xs(e),Ee();const r=Xt(o,e,0,[e.props,n]);if(Ne(),ei(),_(r)){if(r.then(ei,ei),t)return r.then((n=>{si(e,n,t)})).catch((t=>{tn(t,e,0)}));e.asyncDep=r}else si(e,r,t)}else ci(e,t)}(e,t):void 0;ri=!1}(c),c.asyncDep){if(s&&s.registerDep(c,L),!e.el){const e=c.subTree=Is(bs);S(null,e,n,o)}}else L(c,e,n,o,s,i,l)},B=(e,t,n)=>{const o=t.component=e.component;if(function(e,t,n){const{props:o,children:r,component:s}=e,{props:i,children:l,patchFlag:c}=t,a=s.emitsOptions;if(t.dirs||t.transition)return!0;if(!(n&&c>=0))return!(!r&&!l||l&&l.$stable)||o!==i&&(o?!i||In(o,i,a):!!i);if(1024&c)return!0;if(16&c)return o?In(o,i,a):!!i;if(8&c){const e=t.dynamicProps;for(let t=0;tsn&&rn.splice(t,1)}(o.update),o.update()}else t.el=e.el,o.vnode=t},L=(e,t,n,o,r,s,i)=>{const l=e.effect=new Se((()=>{if(e.isMounted){let t,{next:n,bu:o,u:l,parent:c,vnode:a}=e,u=n;cs(e,!1),n?(n.el=a.el,j(e,n,i)):n=a,o&&V(o),(t=n.props&&n.props.onVnodeBeforeUpdate)&&Gs(t,c,n,a),cs(e,!0);const p=Fn(e),f=e.subTree;e.subTree=p,y(f,p,h(f.el),Y(f),e,r,s),n.el=p.el,null===u&&Bn(e,p.el),l&&rs(l,r),(t=n.props&&n.props.onVnodeUpdated)&&rs((()=>Gs(t,c,n,a)),r)}else{let i;const{el:l,props:c}=t,{bm:a,m:u,parent:p}=e,f=vo(t);if(cs(e,!1),a&&V(a),!f&&(i=c&&c.onVnodeBeforeMount)&&Gs(i,p,t),cs(e,!0),l&&te){const n=()=>{e.subTree=Fn(e),te(l,e.subTree,e,r,null)};f?t.type.__asyncLoader().then((()=>!e.isUnmounted&&n())):n()}else{const i=e.subTree=Fn(e);y(null,i,n,o,e,r,s),t.el=i.el}if(u&&rs(u,r),!f&&(i=c&&c.onVnodeMounted)){const e=t;rs((()=>Gs(i,p,e)),r)}(256&t.shapeFlag||p&&vo(p.vnode)&&256&p.vnode.shapeFlag)&&e.a&&rs(e.a,r),e.isMounted=!0,t=n=o=null}}),(()=>dn(c)),e.scope),c=e.update=()=>l.run();c.id=e.uid,cs(e,!0),c()},j=(e,t,n)=>{t.component=e;const o=e.vnode.props;e.vnode=t,e.next=null,function(e,t,n,o){const{props:r,attrs:s,vnode:{patchFlag:i}}=e,l=Et(r),[c]=e.propsOptions;let a=!1;if(!(o||i>0)||16&i){let o;Lr(e,t,r,s)&&(a=!0);for(const s in l)t&&(p(t,s)||(o=R(s))!==s&&p(t,o))||(c?!n||void 0===n[s]&&void 0===n[o]||(r[s]=jr(c,l,s,void 0,e,!0)):delete r[s]);if(s!==l)for(const e in s)t&&p(t,e)||(delete s[e],a=!0)}else if(8&i){const n=e.vnode.dynamicProps;for(let o=0;o{const a=e&&e.children,u=e?e.shapeFlag:0,p=t.children,{patchFlag:f,shapeFlag:h}=t;if(f>0){if(128&f)return void W(a,p,n,o,r,s,i,l,c);if(256&f)return void H(a,p,n,o,r,s,i,l,c)}8&h?(16&u&&Z(a,r,s),p!==a&&d(n,p)):16&u?16&h?W(a,p,n,o,r,s,i,l,c):Z(a,r,s,!0):(8&u&&d(n,""),16&h&&E(p,n,o,r,s,i,l,c))},H=(e,t,o,r,s,i,l,c,a)=>{const u=(e=e||n).length,p=(t=t||n).length,f=Math.min(u,p);let d;for(d=0;dp?Z(e,s,i,!0,!1,f):E(t,o,r,s,i,l,c,a,f)},W=(e,t,o,r,s,i,l,c,a)=>{let u=0;const p=t.length;let f=e.length-1,d=p-1;for(;u<=f&&u<=d;){const n=e[u],r=t[u]=a?Ws(t[u]):Hs(t[u]);if(!Ps(n,r))break;y(n,r,o,null,s,i,l,c,a),u++}for(;u<=f&&u<=d;){const n=e[f],r=t[d]=a?Ws(t[d]):Hs(t[d]);if(!Ps(n,r))break;y(n,r,o,null,s,i,l,c,a),f--,d--}if(u>f){if(u<=d){const e=d+1,n=ed)for(;u<=f;)K(e[u],s,i,!0),u++;else{const h=u,m=u,g=new Map;for(u=m;u<=d;u++){const e=t[u]=a?Ws(t[u]):Hs(t[u]);null!=e.key&&g.set(e.key,u)}let v,b=0;const _=d-m+1;let S=!1,x=0;const C=new Array(_);for(u=0;u<_;u++)C[u]=0;for(u=h;u<=f;u++){const n=e[u];if(b>=_){K(n,s,i,!0);continue}let r;if(null!=n.key)r=g.get(n.key);else for(v=m;v<=d;v++)if(0===C[v-m]&&Ps(n,t[v])){r=v;break}void 0===r?K(n,s,i,!0):(C[r-m]=u+1,r>=x?x=r:S=!0,y(n,t[r],o,null,s,i,l,c,a),b++)}const w=S?function(e){const t=e.slice(),n=[0];let o,r,s,i,l;const c=e.length;for(o=0;o>1,e[n[l]]0&&(t[o]=n[s-1]),n[s]=o)}}s=n.length,i=n[s-1];for(;s-- >0;)n[s]=i,i=t[i];return n}(C):n;for(v=w.length-1,u=_-1;u>=0;u--){const e=m+u,n=t[e],f=e+1{const{el:i,type:l,transition:c,children:a,shapeFlag:u}=e;if(6&u)return void z(e.component.subTree,t,n,o);if(128&u)return void e.suspense.move(t,n,o);if(64&u)return void l.move(e,t,n,X);if(l===vs){s(i,t,n);for(let e=0;e{let r;for(;e&&e!==t;)r=m(e),s(e,n,o),e=r;s(t,n,o)})(e,t,n);if(2!==o&&1&u&&c)if(0===o)c.beforeEnter(i),s(i,t,n),rs((()=>c.enter(i)),r);else{const{leave:e,delayLeave:o,afterLeave:r}=c,l=()=>s(i,t,n),a=()=>{e(i,(()=>{l(),r&&r()}))};o?o(i,l,a):a()}else s(i,t,n)},K=(e,t,n,o=!1,r=!1)=>{const{type:s,props:i,ref:l,children:c,dynamicChildren:a,shapeFlag:u,patchFlag:p,dirs:f}=e;if(null!=l&&Xr(l,null,n,e,!0),256&u)return void t.ctx.deactivate(e);const d=1&u&&f,h=!vo(e);let m;if(h&&(m=i&&i.onVnodeBeforeUnmount)&&Gs(m,t,e),6&u)J(e.component,n,o);else{if(128&u)return void e.suspense.unmount(n,o);d&&no(e,null,t,"beforeUnmount"),64&u?e.type.remove(e,t,n,r,X,o):a&&(s!==vs||p>0&&64&p)?Z(a,t,n,!1,!0):(s===vs&&384&p||!r&&16&u)&&Z(c,t,n),o&&G(e)}(h&&(m=i&&i.onVnodeUnmounted)||d)&&rs((()=>{m&&Gs(m,t,e),d&&no(e,null,t,"unmounted")}),n)},G=e=>{const{type:t,el:n,anchor:o,transition:r}=e;if(t===vs)return void q(n,o);if(t===_s)return void(({el:e,anchor:t})=>{let n;for(;e&&e!==t;)n=m(e),i(e),e=n;i(t)})(e);const s=()=>{i(n),r&&!r.persisted&&r.afterLeave&&r.afterLeave()};if(1&e.shapeFlag&&r&&!r.persisted){const{leave:t,delayLeave:o}=r,i=()=>t(n,s);o?o(e.el,s,i):i()}else s()},q=(e,t)=>{let n;for(;e!==t;)n=m(e),i(e),e=n;i(t)},J=(e,t,n)=>{const{bum:o,scope:r,update:s,subTree:i,um:l}=e;o&&V(o),r.stop(),s&&(s.active=!1,K(i,e,t,n)),l&&rs(l,t),rs((()=>{e.isUnmounted=!0}),t),t&&t.pendingBranch&&!t.isUnmounted&&e.asyncDep&&!e.asyncResolved&&e.suspenseId===t.pendingId&&(t.deps--,0===t.deps&&t.resolve())},Z=(e,t,n,o=!1,r=!1,s=0)=>{for(let i=s;i6&e.shapeFlag?Y(e.component.subTree):128&e.shapeFlag?e.suspense.next():m(e.anchor||e.el),Q=(e,t,n)=>{null==e?t._vnode&&K(t._vnode,null,null,!0):y(t._vnode||null,e,t,null,null,null,n),gn(),vn(),t._vnode=e},X={p:y,um:K,m:z,r:G,mt:M,mc:E,pc:D,pbc:O,n:Y,o:e};let ee,te;return r&&([ee,te]=r(X)),{render:Q,hydrate:ee,createApp:Fr(Q,ee)}}function cs({effect:e,update:t},n){e.allowRecurse=t.allowRecurse=n}function as(e,t){return(!e||e&&!e.pendingBranch)&&t&&!t.persisted}function us(e,t,n=!1){const o=e.children,r=t.children;if(f(o)&&f(r))for(let s=0;se&&(e.disabled||""===e.disabled),fs=e=>"undefined"!=typeof SVGElement&&e instanceof SVGElement,ds=(e,t)=>{const n=e&&e.to;if(v(n)){if(t){return t(n)}return null}return n};function hs(e,t,n,{o:{insert:o},m:r},s=2){0===s&&o(e.targetAnchor,t,n);const{el:i,anchor:l,shapeFlag:c,children:a,props:u}=e,p=2===s;if(p&&o(i,t,n),(!p||ps(u))&&16&c)for(let f=0;f{16&v&&u(y,e,t,r,s,i,l,c)};g?b(n,a):p&&b(p,f)}else{t.el=e.el;const o=t.anchor=e.anchor,u=t.target=e.target,d=t.targetAnchor=e.targetAnchor,m=ps(e.props),v=m?n:u,y=m?o:d;if(i=i||fs(u),b?(f(e.dynamicChildren,b,v,r,s,i,l),us(e,t,!0)):c||p(e,t,v,y,r,s,i,l,!1),g)m?t.props&&e.props&&t.props.to!==e.props.to&&(t.props.to=e.props.to):hs(t,n,o,a,1);else if((t.props&&t.props.to)!==(e.props&&e.props.to)){const e=t.target=ds(t.props,h);e&&hs(t,e,null,a,0)}else m&&hs(t,u,d,a,1)}gs(t)},remove(e,t,n,o,{um:r,o:{remove:s}},i){const{shapeFlag:l,children:c,anchor:a,targetAnchor:u,target:p,props:f}=e;if(p&&s(u),i&&s(a),16&l){const e=i||!ps(f);for(let o=0;o0?xs||n:null,ws(),ks>0&&xs&&xs.push(e),e}function Ns(e,t,n,o,r,s){return Es(Vs(e,t,n,o,r,s,!0))}function Os(e,t,n,o,r){return Es(Is(e,t,n,o,r,!0))}function $s(e){return!!e&&!0===e.__v_isVNode}function Ps(e,t){return e.type===t.type&&e.key===t.key}function Rs(e){}const As="__vInternal",Fs=({key:e})=>null!=e?e:null,Ms=({ref:e,ref_key:t,ref_for:n})=>("number"==typeof e&&(e=""+e),null!=e?v(e)||At(e)||g(e)?{i:En,r:e,k:t,f:!!n}:e:null);function Vs(e,t=null,n=null,o=0,r=null,s=(e===vs?0:1),i=!1,l=!1){const c={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&Fs(t),ref:t&&Ms(t),scopeId:Nn,slotScopeIds:null,children:n,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetAnchor:null,staticCount:0,shapeFlag:s,patchFlag:o,dynamicProps:r,dynamicChildren:null,appContext:null,ctx:En};return l?(zs(c,n),128&s&&e.normalize(c)):n&&(c.shapeFlag|=v(n)?8:16),ks>0&&!i&&xs&&(c.patchFlag>0||6&s)&&32!==c.patchFlag&&xs.push(c),c}const Is=function(e,t=null,n=null,o=0,r=null,s=!1){e&&e!==Ho||(e=bs);if($s(e)){const o=Ls(e,t,!0);return n&&zs(o,n),ks>0&&!s&&xs&&(6&o.shapeFlag?xs[xs.indexOf(e)]=o:xs.push(o)),o.patchFlag|=-2,o}i=e,g(i)&&"__vccOpts"in i&&(e=e.__vccOpts);var i;if(t){t=Bs(t);let{class:e,style:n}=t;e&&!v(e)&&(t.class=q(e)),b(n)&&(Tt(n)&&!f(n)&&(n=c({},n)),t.style=H(n))}const l=v(e)?1:Ln(e)?128:(e=>e.__isTeleport)(e)?64:b(e)?4:g(e)?2:0;return Vs(e,t,n,o,r,l,s,!0)};function Bs(e){return e?Tt(e)||As in e?c({},e):e:null}function Ls(e,t,n=!1){const{props:o,ref:r,patchFlag:s,children:i}=e,l=t?Ks(o||{},t):o;return{__v_isVNode:!0,__v_skip:!0,type:e.type,props:l,key:l&&Fs(l),ref:t&&t.ref?n&&r?f(r)?r.concat(Ms(t)):[r,Ms(t)]:Ms(t):r,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:i,target:e.target,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==vs?-1===s?16:16|s:s,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:e.transition,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&Ls(e.ssContent),ssFallback:e.ssFallback&&Ls(e.ssFallback),el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce}}function js(e=" ",t=0){return Is(ys,null,e,t)}function Us(e,t){const n=Is(_s,null,e);return n.staticCount=t,n}function Ds(e="",t=!1){return t?(Cs(),Os(bs,null,e)):Is(bs,null,e)}function Hs(e){return null==e||"boolean"==typeof e?Is(bs):f(e)?Is(vs,null,e.slice()):"object"==typeof e?Ws(e):Is(ys,null,String(e))}function Ws(e){return null===e.el&&-1!==e.patchFlag||e.memo?e:Ls(e)}function zs(e,t){let n=0;const{shapeFlag:o}=e;if(null==t)t=null;else if(f(t))n=16;else if("object"==typeof t){if(65&o){const n=t.default;return void(n&&(n._c&&(n._d=!1),zs(e,n()),n._c&&(n._d=!0)))}{n=32;const o=t._;o||As in t?3===o&&En&&(1===En.slots._?t._=1:(t._=2,e.patchFlag|=1024)):t._ctx=En}}else g(t)?(t={default:t,_ctx:En},n=32):(t=String(t),64&o?(n=16,t=[js(t)]):n=8);e.children=t,e.shapeFlag|=n}function Ks(...e){const t={};for(let n=0;nZs||En;let Qs;Qs=e=>{Zs=e};const Xs=e=>{Qs(e),e.scope.on()},ei=()=>{Zs&&Zs.scope.off(),Qs(null)};function ti(e){return 4&e.vnode.shapeFlag}let ni,oi,ri=!1;function si(e,t,n){g(t)?e.render=t:b(t)&&(e.setupState=Dt(t)),ci(e,n)}function ii(e){ni=e,oi=e=>{e.render._rc&&(e.withProxy=new Proxy(e.ctx,or))}}const li=()=>!ni;function ci(e,t,n){const r=e.type;if(!e.render){if(!t&&ni&&!r.render){const t=r.template||wr(e).template;if(t){const{isCustomElement:n,compilerOptions:o}=e.appContext.config,{delimiters:s,compilerOptions:i}=r,l=c(c({isCustomElement:n,delimiters:s},o),i);r.render=ni(t,l)}}e.render=r.render||o,oi&&oi(e)}Xs(e),Ee();try{Sr(e)}finally{Ne(),ei()}}function ai(e){const t=t=>{e.exposed=t||{}};return{get attrs(){return function(e){return e.attrsProxy||(e.attrsProxy=new Proxy(e.attrs,{get:(t,n)=>(Oe(e,0,"$attrs"),t[n])}))}(e)},slots:e.slots,emit:e.emit,expose:t}}function ui(e){if(e.exposed)return e.exposeProxy||(e.exposeProxy=new Proxy(Dt(Nt(e.exposed)),{get:(t,n)=>n in t?t[n]:n in er?er[n](e):void 0,has:(e,t)=>t in e||t in er}))}function pi(e,t=!0){return g(e)?e.displayName||e.name:e.name||t&&e.__name}const fi=(e,t)=>function(e,t,n=!1){let r,s;const i=g(e);return i?(r=e,s=o):(r=e.get,s=e.set),new Zt(r,s,i||!s,n)}(e,0,ri);function di(e,t,n){const o=arguments.length;return 2===o?b(t)&&!f(t)?$s(t)?Is(e,null,[t]):Is(e,t):Is(e,null,t):(o>3?n=Array.prototype.slice.call(arguments,2):3===o&&$s(n)&&(n=[n]),Is(e,t,n))}const hi=Symbol.for("v-scx"),mi=()=>Ir(hi);function gi(){}function vi(e,t,n,o){const r=n[o];if(r&&yi(r,e))return r;const s=t();return s.memo=e.slice(),n[o]=s}function yi(e,t){const n=e.memo;if(n.length!=t.length)return!1;for(let o=0;o0&&xs&&xs.push(e),!0}const bi="3.3.7",_i=null,Si=null,xi=null,Ci="undefined"!=typeof document?document:null,wi=Ci&&Ci.createElement("template"),ki={insert:(e,t,n)=>{t.insertBefore(e,n||null)},remove:e=>{const t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,n,o)=>{const r=t?Ci.createElementNS("http://www.w3.org/2000/svg",e):Ci.createElement(e,n?{is:n}:void 0);return"select"===e&&o&&null!=o.multiple&&r.setAttribute("multiple",o.multiple),r},createText:e=>Ci.createTextNode(e),createComment:e=>Ci.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>Ci.querySelector(e),setScopeId(e,t){e.setAttribute(t,"")},insertStaticContent(e,t,n,o,r,s){const i=n?n.previousSibling:t.lastChild;if(r&&(r===s||r.nextSibling))for(;t.insertBefore(r.cloneNode(!0),n),r!==s&&(r=r.nextSibling););else{wi.innerHTML=o?`${e}`:e;const r=wi.content;if(o){const e=r.firstChild;for(;e.firstChild;)r.appendChild(e.firstChild);r.removeChild(e)}t.insertBefore(r,n)}return[i?i.nextSibling:t.firstChild,n?n.previousSibling:t.lastChild]}},Ti="transition",Ei="animation",Ni=Symbol("_vtc"),Oi=(e,{slots:t})=>di(co,Fi(e),t);Oi.displayName="Transition";const $i={name:String,type:String,css:{type:Boolean,default:!0},duration:[String,Number,Object],enterFromClass:String,enterActiveClass:String,enterToClass:String,appearFromClass:String,appearActiveClass:String,appearToClass:String,leaveFromClass:String,leaveActiveClass:String,leaveToClass:String},Pi=Oi.props=c({},lo,$i),Ri=(e,t=[])=>{f(e)?e.forEach((e=>e(...t))):e&&e(...t)},Ai=e=>!!e&&(f(e)?e.some((e=>e.length>1)):e.length>1);function Fi(e){const t={};for(const c in e)c in $i||(t[c]=e[c]);if(!1===e.css)return t;const{name:n="v",type:o,duration:r,enterFromClass:s=`${n}-enter-from`,enterActiveClass:i=`${n}-enter-active`,enterToClass:l=`${n}-enter-to`,appearFromClass:a=s,appearActiveClass:u=i,appearToClass:p=l,leaveFromClass:f=`${n}-leave-from`,leaveActiveClass:d=`${n}-leave-active`,leaveToClass:h=`${n}-leave-to`}=e,m=function(e){if(null==e)return null;if(b(e))return[Mi(e.enter),Mi(e.leave)];{const t=Mi(e);return[t,t]}}(r),g=m&&m[0],v=m&&m[1],{onBeforeEnter:y,onEnter:_,onEnterCancelled:S,onLeave:x,onLeaveCancelled:C,onBeforeAppear:w=y,onAppear:k=_,onAppearCancelled:T=S}=t,E=(e,t,n)=>{Ii(e,t?p:l),Ii(e,t?u:i),n&&n()},N=(e,t)=>{e._isLeaving=!1,Ii(e,f),Ii(e,h),Ii(e,d),t&&t()},O=e=>(t,n)=>{const r=e?k:_,i=()=>E(t,e,n);Ri(r,[t,i]),Bi((()=>{Ii(t,e?a:s),Vi(t,e?p:l),Ai(r)||ji(t,o,g,i)}))};return c(t,{onBeforeEnter(e){Ri(y,[e]),Vi(e,s),Vi(e,i)},onBeforeAppear(e){Ri(w,[e]),Vi(e,a),Vi(e,u)},onEnter:O(!1),onAppear:O(!0),onLeave(e,t){e._isLeaving=!0;const n=()=>N(e,t);Vi(e,f),Wi(),Vi(e,d),Bi((()=>{e._isLeaving&&(Ii(e,f),Vi(e,h),Ai(x)||ji(e,o,v,n))})),Ri(x,[e,n])},onEnterCancelled(e){E(e,!1),Ri(S,[e])},onAppearCancelled(e){E(e,!0),Ri(T,[e])},onLeaveCancelled(e){N(e),Ri(C,[e])}})}function Mi(e){return L(e)}function Vi(e,t){t.split(/\s+/).forEach((t=>t&&e.classList.add(t))),(e[Ni]||(e[Ni]=new Set)).add(t)}function Ii(e,t){t.split(/\s+/).forEach((t=>t&&e.classList.remove(t)));const n=e[Ni];n&&(n.delete(t),n.size||(e[Ni]=void 0))}function Bi(e){requestAnimationFrame((()=>{requestAnimationFrame(e)}))}let Li=0;function ji(e,t,n,o){const r=e._endId=++Li,s=()=>{r===e._endId&&o()};if(n)return setTimeout(s,n);const{type:i,timeout:l,propCount:c}=Ui(e,t);if(!i)return o();const a=i+"end";let u=0;const p=()=>{e.removeEventListener(a,f),s()},f=t=>{t.target===e&&++u>=c&&p()};setTimeout((()=>{u(n[e]||"").split(", "),r=o(`${Ti}Delay`),s=o(`${Ti}Duration`),i=Di(r,s),l=o(`${Ei}Delay`),c=o(`${Ei}Duration`),a=Di(l,c);let u=null,p=0,f=0;t===Ti?i>0&&(u=Ti,p=i,f=s.length):t===Ei?a>0&&(u=Ei,p=a,f=c.length):(p=Math.max(i,a),u=p>0?i>a?Ti:Ei:null,f=u?u===Ti?s.length:c.length:0);return{type:u,timeout:p,propCount:f,hasTransform:u===Ti&&/\b(transform|all)(,|$)/.test(o(`${Ti}Property`).toString())}}function Di(e,t){for(;e.lengthHi(t)+Hi(e[n]))))}function Hi(e){return"auto"===e?0:1e3*Number(e.slice(0,-1).replace(",","."))}function Wi(){return document.body.offsetHeight}const zi=Symbol("_vod"),Ki={beforeMount(e,{value:t},{transition:n}){e[zi]="none"===e.style.display?"":e.style.display,n&&t?n.beforeEnter(e):Gi(e,t)},mounted(e,{value:t},{transition:n}){n&&t&&n.enter(e)},updated(e,{value:t,oldValue:n},{transition:o}){!t!=!n&&(o?t?(o.beforeEnter(e),Gi(e,!0),o.enter(e)):o.leave(e,(()=>{Gi(e,!1)})):Gi(e,t))},beforeUnmount(e,{value:t}){Gi(e,t)}};function Gi(e,t){e.style.display=t?e[zi]:"none"}const qi=/\s*!important$/;function Ji(e,t,n){if(f(n))n.forEach((n=>Ji(e,t,n)));else if(null==n&&(n=""),t.startsWith("--"))e.setProperty(t,n);else{const o=function(e,t){const n=Yi[t];if(n)return n;let o=$(t);if("filter"!==o&&o in e)return Yi[t]=o;o=A(o);for(let r=0;r{if(e._vts){if(e._vts<=n.attached)return}else e._vts=Date.now();en(function(e,t){if(f(t)){const n=e.stopImmediatePropagation;return e.stopImmediatePropagation=()=>{n.call(e),e._stopped=!0},t.map((e=>t=>!t._stopped&&e&&e(t)))}return t}(e,n.value),t,5,[e])};return n.value=e,n.attached=sl(),n}(o,r);Xi(e,n,i,l)}else i&&(!function(e,t,n,o){e.removeEventListener(t,n,o)}(e,n,i,l),s[t]=void 0)}}const nl=/(?:Once|Passive|Capture)$/;let ol=0;const rl=Promise.resolve(),sl=()=>ol||(rl.then((()=>ol=0)),ol=Date.now());const il=/^on[a-z]/; +/** +* vue v3.4.15 +* (c) 2018-present Yuxi (Evan) You and Vue contributors +* @license MIT +**/ +function e(e,t){const n=new Set(e.split(","));return t?e=>n.has(e.toLowerCase()):e=>n.has(e)}const t={},n=[],s=()=>{},o=()=>!1,r=e=>111===e.charCodeAt(0)&&110===e.charCodeAt(1)&&(e.charCodeAt(2)>122||e.charCodeAt(2)<97),i=e=>e.startsWith("onUpdate:"),l=Object.assign,c=(e,t)=>{const n=e.indexOf(t);n>-1&&e.splice(n,1)},a=Object.prototype.hasOwnProperty,u=(e,t)=>a.call(e,t),d=Array.isArray,p=e=>"[object Map]"===S(e),h=e=>"[object Set]"===S(e),f=e=>"[object Date]"===S(e),m=e=>"function"==typeof e,g=e=>"string"==typeof e,v=e=>"symbol"==typeof e,y=e=>null!==e&&"object"==typeof e,b=e=>(y(e)||m(e))&&m(e.then)&&m(e.catch),_=Object.prototype.toString,S=e=>_.call(e),x=e=>S(e).slice(8,-1),C=e=>"[object Object]"===S(e),k=e=>g(e)&&"NaN"!==e&&"-"!==e[0]&&""+parseInt(e,10)===e,T=e(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),w=e("bind,cloak,else-if,else,for,html,if,model,on,once,pre,show,slot,text,memo"),N=e=>{const t=Object.create(null);return n=>t[n]||(t[n]=e(n))},A=/-(\w)/g,E=N((e=>e.replace(A,((e,t)=>t?t.toUpperCase():"")))),I=/\B([A-Z])/g,R=N((e=>e.replace(I,"-$1").toLowerCase())),O=N((e=>e.charAt(0).toUpperCase()+e.slice(1))),F=N((e=>e?`on${O(e)}`:"")),L=(e,t)=>!Object.is(e,t),M=(e,t)=>{for(let n=0;n{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,value:n})},$=e=>{const t=parseFloat(e);return isNaN(t)?e:t},B=e=>{const t=g(e)?Number(e):NaN;return isNaN(t)?e:t};let V;const D=()=>V||(V="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:"undefined"!=typeof global?global:{}),U=e("Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt,console,Error");function j(e){if(d(e)){const t={};for(let n=0;n{if(e){const n=e.split(q);n.length>1&&(t[n[0].trim()]=n[1].trim())}})),t}function z(e){let t="";if(g(e))t=e;else if(d(e))for(let n=0;nte(e,t)))}const se=e=>g(e)?e:null==e?"":d(e)||y(e)&&(e.toString===_||!m(e.toString))?JSON.stringify(e,oe,2):String(e),oe=(e,t)=>t&&t.__v_isRef?oe(e,t.value):p(t)?{[`Map(${t.size})`]:[...t.entries()].reduce(((e,[t,n],s)=>(e[re(t,s)+" =>"]=n,e)),{})}:h(t)?{[`Set(${t.size})`]:[...t.values()].map((e=>re(e)))}:v(t)?re(t):!y(t)||d(t)||C(t)?t:String(t),re=(e,t="")=>{var n;return v(e)?`Symbol(${null!=(n=e.description)?n:t})`:e};let ie,le;class ce{constructor(e=!1){this.detached=e,this._active=!0,this.effects=[],this.cleanups=[],this.parent=ie,!e&&ie&&(this.index=(ie.scopes||(ie.scopes=[])).push(this)-1)}get active(){return this._active}run(e){if(this._active){const t=ie;try{return ie=this,e()}finally{ie=t}}}on(){ie=this}off(){ie=this.parent}stop(e){if(this._active){let t,n;for(t=0,n=this.effects.length;t=2))break}this._dirtyLevel<2&&(this._dirtyLevel=0),ke()}return this._dirtyLevel>=2}set dirty(e){this._dirtyLevel=e?2:0}run(){if(this._dirtyLevel=0,!this.active)return this.fn();let e=_e,t=le;try{return _e=!0,le=this,this._runnings++,me(this),this.fn()}finally{ge(this),this._runnings--,le=t,_e=e}}stop(){var e;this.active&&(me(this),ge(this),null==(e=this.onStop)||e.call(this),this.active=!1)}}function fe(e){return e.value}function me(e){e._trackId++,e._depsLength=0}function ge(e){if(e.deps&&e.deps.length>e._depsLength){for(let t=e._depsLength;t{n.dirty&&n.run()}));t&&(l(n,t),t.scope&&ue(n,t.scope)),t&&t.lazy||n.run();const o=n.run.bind(n);return o.effect=n,o}function be(e){e.effect.stop()}let _e=!0,Se=0;const xe=[];function Ce(){xe.push(_e),_e=!1}function ke(){const e=xe.pop();_e=void 0===e||e}function Te(){Se++}function we(){for(Se--;!Se&&Ae.length;)Ae.shift()()}function Ne(e,t,n){if(t.get(e)!==e._trackId){t.set(e,e._trackId);const n=e.deps[e._depsLength];n!==t?(n&&ve(n,e),e.deps[e._depsLength++]=t):e._depsLength++}}const Ae=[];function Ee(e,t,n){Te();for(const s of e.keys())if(s._dirtyLevel{const n=new Map;return n.cleanup=e,n.computed=t,n},Oe=new WeakMap,Fe=Symbol(""),Le=Symbol("");function Me(e,t,n){if(_e&&le){let t=Oe.get(e);t||Oe.set(e,t=new Map);let s=t.get(n);s||t.set(n,s=Re((()=>t.delete(n)))),Ne(le,s)}}function Pe(e,t,n,s,o,r){const i=Oe.get(e);if(!i)return;let l=[];if("clear"===t)l=[...i.values()];else if("length"===n&&d(e)){const e=Number(s);i.forEach(((t,n)=>{("length"===n||!v(n)&&n>=e)&&l.push(t)}))}else switch(void 0!==n&&l.push(i.get(n)),t){case"add":d(e)?k(n)&&l.push(i.get("length")):(l.push(i.get(Fe)),p(e)&&l.push(i.get(Le)));break;case"delete":d(e)||(l.push(i.get(Fe)),p(e)&&l.push(i.get(Le)));break;case"set":p(e)&&l.push(i.get(Fe))}Te();for(const c of l)c&&Ee(c,2);we()}const $e=e("__proto__,__v_isRef,__isVue"),Be=new Set(Object.getOwnPropertyNames(Symbol).filter((e=>"arguments"!==e&&"caller"!==e)).map((e=>Symbol[e])).filter(v)),Ve=De();function De(){const e={};return["includes","indexOf","lastIndexOf"].forEach((t=>{e[t]=function(...e){const n=It(this);for(let t=0,o=this.length;t{e[t]=function(...e){Ce(),Te();const n=It(this)[t].apply(this,e);return we(),ke(),n}})),e}function Ue(e){const t=It(this);return Me(t,0,e),t.hasOwnProperty(e)}class je{constructor(e=!1,t=!1){this._isReadonly=e,this._shallow=t}get(e,t,n){const s=this._isReadonly,o=this._shallow;if("__v_isReactive"===t)return!s;if("__v_isReadonly"===t)return s;if("__v_isShallow"===t)return o;if("__v_raw"===t)return n===(s?o?_t:bt:o?yt:vt).get(e)||Object.getPrototypeOf(e)===Object.getPrototypeOf(n)?e:void 0;const r=d(e);if(!s){if(r&&u(Ve,t))return Reflect.get(Ve,t,n);if("hasOwnProperty"===t)return Ue}const i=Reflect.get(e,t,n);return(v(t)?Be.has(t):$e(t))?i:(s||Me(e,0,t),o?i:$t(i)?r&&k(t)?i:i.value:y(i)?s?Ct(i):St(i):i)}}class He extends je{constructor(e=!1){super(!1,e)}set(e,t,n,s){let o=e[t];if(!this._shallow){const t=Nt(o);if(At(n)||Nt(n)||(o=It(o),n=It(n)),!d(e)&&$t(o)&&!$t(n))return!t&&(o.value=n,!0)}const r=d(e)&&k(t)?Number(t)e,Xe=e=>Reflect.getPrototypeOf(e);function Qe(e,t,n=!1,s=!1){const o=It(e=e.__v_raw),r=It(t);n||(L(t,r)&&Me(o,0,t),Me(o,0,r));const{has:i}=Xe(o),l=s?Je:n?Ft:Ot;return i.call(o,t)?l(e.get(t)):i.call(o,r)?l(e.get(r)):void(e!==o&&e.get(t))}function Ze(e,t=!1){const n=this.__v_raw,s=It(n),o=It(e);return t||(L(e,o)&&Me(s,0,e),Me(s,0,o)),e===o?n.has(e):n.has(e)||n.has(o)}function Ye(e,t=!1){return e=e.__v_raw,!t&&Me(It(e),0,Fe),Reflect.get(e,"size",e)}function et(e){e=It(e);const t=It(this);return Xe(t).has.call(t,e)||(t.add(e),Pe(t,"add",e,e)),this}function tt(e,t){t=It(t);const n=It(this),{has:s,get:o}=Xe(n);let r=s.call(n,e);r||(e=It(e),r=s.call(n,e));const i=o.call(n,e);return n.set(e,t),r?L(t,i)&&Pe(n,"set",e,t):Pe(n,"add",e,t),this}function nt(e){const t=It(this),{has:n,get:s}=Xe(t);let o=n.call(t,e);o||(e=It(e),o=n.call(t,e)),s&&s.call(t,e);const r=t.delete(e);return o&&Pe(t,"delete",e,void 0),r}function st(){const e=It(this),t=0!==e.size,n=e.clear();return t&&Pe(e,"clear",void 0,void 0),n}function ot(e,t){return function(n,s){const o=this,r=o.__v_raw,i=It(r),l=t?Je:e?Ft:Ot;return!e&&Me(i,0,Fe),r.forEach(((e,t)=>n.call(s,l(e),l(t),o)))}}function rt(e,t,n){return function(...s){const o=this.__v_raw,r=It(o),i=p(r),l="entries"===e||e===Symbol.iterator&&i,c="keys"===e&&i,a=o[e](...s),u=n?Je:t?Ft:Ot;return!t&&Me(r,0,c?Le:Fe),{next(){const{value:e,done:t}=a.next();return t?{value:e,done:t}:{value:l?[u(e[0]),u(e[1])]:u(e),done:t}},[Symbol.iterator](){return this}}}}function it(e){return function(...t){return"delete"!==e&&("clear"===e?void 0:this)}}function lt(){const e={get(e){return Qe(this,e)},get size(){return Ye(this)},has:Ze,add:et,set:tt,delete:nt,clear:st,forEach:ot(!1,!1)},t={get(e){return Qe(this,e,!1,!0)},get size(){return Ye(this)},has:Ze,add:et,set:tt,delete:nt,clear:st,forEach:ot(!1,!0)},n={get(e){return Qe(this,e,!0)},get size(){return Ye(this,!0)},has(e){return Ze.call(this,e,!0)},add:it("add"),set:it("set"),delete:it("delete"),clear:it("clear"),forEach:ot(!0,!1)},s={get(e){return Qe(this,e,!0,!0)},get size(){return Ye(this,!0)},has(e){return Ze.call(this,e,!0)},add:it("add"),set:it("set"),delete:it("delete"),clear:it("clear"),forEach:ot(!0,!0)};return["keys","values","entries",Symbol.iterator].forEach((o=>{e[o]=rt(o,!1,!1),n[o]=rt(o,!0,!1),t[o]=rt(o,!1,!0),s[o]=rt(o,!0,!0)})),[e,n,t,s]}const[ct,at,ut,dt]=lt();function pt(e,t){const n=t?e?dt:ut:e?at:ct;return(t,s,o)=>"__v_isReactive"===s?!e:"__v_isReadonly"===s?e:"__v_raw"===s?t:Reflect.get(u(n,s)&&s in t?n:t,s,o)}const ht={get:pt(!1,!1)},ft={get:pt(!1,!0)},mt={get:pt(!0,!1)},gt={get:pt(!0,!0)},vt=new WeakMap,yt=new WeakMap,bt=new WeakMap,_t=new WeakMap;function St(e){return Nt(e)?e:Tt(e,!1,We,ht,vt)}function xt(e){return Tt(e,!1,ze,ft,yt)}function Ct(e){return Tt(e,!0,Ke,mt,bt)}function kt(e){return Tt(e,!0,Ge,gt,_t)}function Tt(e,t,n,s,o){if(!y(e))return e;if(e.__v_raw&&(!t||!e.__v_isReactive))return e;const r=o.get(e);if(r)return r;const i=(l=e).__v_skip||!Object.isExtensible(l)?0:function(e){switch(e){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}(x(l));var l;if(0===i)return e;const c=new Proxy(e,2===i?s:n);return o.set(e,c),c}function wt(e){return Nt(e)?wt(e.__v_raw):!(!e||!e.__v_isReactive)}function Nt(e){return!(!e||!e.__v_isReadonly)}function At(e){return!(!e||!e.__v_isShallow)}function Et(e){return wt(e)||Nt(e)}function It(e){const t=e&&e.__v_raw;return t?It(t):e}function Rt(e){return P(e,"__v_skip",!0),e}const Ot=e=>y(e)?St(e):e,Ft=e=>y(e)?Ct(e):e;class Lt{constructor(e,t,n,s){this._setter=t,this.dep=void 0,this.__v_isRef=!0,this.__v_isReadonly=!1,this.effect=new he((()=>e(this._value)),(()=>Pt(this,1)),(()=>this.dep&&Ie(this.dep))),this.effect.computed=this,this.effect.active=this._cacheable=!s,this.__v_isReadonly=n}get value(){const e=It(this);return e._cacheable&&!e.effect.dirty||L(e._value,e._value=e.effect.run())&&Pt(e,2),Mt(e),e.effect._dirtyLevel>=1&&Pt(e,1),e._value}set value(e){this._setter(e)}get _dirty(){return this.effect.dirty}set _dirty(e){this.effect.dirty=e}}function Mt(e){_e&&le&&(e=It(e),Ne(le,e.dep||(e.dep=Re((()=>e.dep=void 0),e instanceof Lt?e:void 0))))}function Pt(e,t=2,n){const s=(e=It(e)).dep;s&&Ee(s,t)}function $t(e){return!(!e||!0!==e.__v_isRef)}function Bt(e){return Dt(e,!1)}function Vt(e){return Dt(e,!0)}function Dt(e,t){return $t(e)?e:new Ut(e,t)}class Ut{constructor(e,t){this.__v_isShallow=t,this.dep=void 0,this.__v_isRef=!0,this._rawValue=t?e:It(e),this._value=t?e:Ot(e)}get value(){return Mt(this),this._value}set value(e){const t=this.__v_isShallow||At(e)||Nt(e);e=t?e:It(e),L(e,this._rawValue)&&(this._rawValue=e,this._value=t?e:Ot(e),Pt(this,2))}}function jt(e){Pt(e,2)}function Ht(e){return $t(e)?e.value:e}function qt(e){return m(e)?e():Ht(e)}const Wt={get:(e,t,n)=>Ht(Reflect.get(e,t,n)),set:(e,t,n,s)=>{const o=e[t];return $t(o)&&!$t(n)?(o.value=n,!0):Reflect.set(e,t,n,s)}};function Kt(e){return wt(e)?e:new Proxy(e,Wt)}class zt{constructor(e){this.dep=void 0,this.__v_isRef=!0;const{get:t,set:n}=e((()=>Mt(this)),(()=>Pt(this)));this._get=t,this._set=n}get value(){return this._get()}set value(e){this._set(e)}}function Gt(e){return new zt(e)}function Jt(e){const t=d(e)?new Array(e.length):{};for(const n in e)t[n]=Yt(e,n);return t}class Xt{constructor(e,t,n){this._object=e,this._key=t,this._defaultValue=n,this.__v_isRef=!0}get value(){const e=this._object[this._key];return void 0===e?this._defaultValue:e}set value(e){this._object[this._key]=e}get dep(){return e=It(this._object),t=this._key,null==(n=Oe.get(e))?void 0:n.get(t);var e,t,n}}class Qt{constructor(e){this._getter=e,this.__v_isRef=!0,this.__v_isReadonly=!0}get value(){return this._getter()}}function Zt(e,t,n){return $t(e)?e:m(e)?new Qt(e):y(e)&&arguments.length>1?Yt(e,t,n):Bt(e)}function Yt(e,t,n){const s=e[t];return $t(s)?s:new Xt(e,t,n)}const en={GET:"get",HAS:"has",ITERATE:"iterate"},tn={SET:"set",ADD:"add",DELETE:"delete",CLEAR:"clear"};function nn(e,t){}const sn={SETUP_FUNCTION:0,0:"SETUP_FUNCTION",RENDER_FUNCTION:1,1:"RENDER_FUNCTION",WATCH_GETTER:2,2:"WATCH_GETTER",WATCH_CALLBACK:3,3:"WATCH_CALLBACK",WATCH_CLEANUP:4,4:"WATCH_CLEANUP",NATIVE_EVENT_HANDLER:5,5:"NATIVE_EVENT_HANDLER",COMPONENT_EVENT_HANDLER:6,6:"COMPONENT_EVENT_HANDLER",VNODE_HOOK:7,7:"VNODE_HOOK",DIRECTIVE_HOOK:8,8:"DIRECTIVE_HOOK",TRANSITION_HOOK:9,9:"TRANSITION_HOOK",APP_ERROR_HANDLER:10,10:"APP_ERROR_HANDLER",APP_WARN_HANDLER:11,11:"APP_WARN_HANDLER",FUNCTION_REF:12,12:"FUNCTION_REF",ASYNC_COMPONENT_LOADER:13,13:"ASYNC_COMPONENT_LOADER",SCHEDULER:14,14:"SCHEDULER"};function on(e,t,n,s){let o;try{o=s?e(...s):e()}catch(r){ln(r,t,n)}return o}function rn(e,t,n,s){if(m(e)){const o=on(e,t,n,s);return o&&b(o)&&o.catch((e=>{ln(e,t,n)})),o}const o=[];for(let r=0;r>>1,o=un[s],r=Cn(o);rCn(e)-Cn(t)));if(pn.length=0,hn)return void hn.push(...e);for(hn=e,fn=0;fnnull==e.id?1/0:e.id,kn=(e,t)=>{const n=Cn(e)-Cn(t);if(0===n){if(e.pre&&!t.pre)return-1;if(t.pre&&!e.pre)return 1}return n};function Tn(e){an=!1,cn=!0,un.sort(kn);try{for(dn=0;dng(e)?e.trim():e))),n&&(r=s.map($))}let c,a=o[c=F(n)]||o[c=F(E(n))];!a&&i&&(a=o[c=F(R(n))]),a&&rn(a,e,6,r);const u=o[c+"Once"];if(u){if(e.emitted){if(e.emitted[c])return}else e.emitted={};e.emitted[c]=!0,rn(u,e,6,r)}}function Nn(e,t,n=!1){const s=t.emitsCache,o=s.get(e);if(void 0!==o)return o;const r=e.emits;let i={},c=!1;if(!m(e)){const s=e=>{const n=Nn(e,t,!0);n&&(c=!0,l(i,n))};!n&&t.mixins.length&&t.mixins.forEach(s),e.extends&&s(e.extends),e.mixins&&e.mixins.forEach(s)}return r||c?(d(r)?r.forEach((e=>i[e]=null)):l(i,r),y(e)&&s.set(e,i),i):(y(e)&&s.set(e,null),null)}function An(e,t){return!(!e||!r(t))&&(t=t.slice(2).replace(/Once$/,""),u(e,t[0].toLowerCase()+t.slice(1))||u(e,R(t))||u(e,t))}let En=null,In=null;function Rn(e){const t=En;return En=e,In=e&&e.type.__scopeId||null,t}function On(e){In=e}function Fn(){In=null}const Ln=e=>Mn;function Mn(e,t=En,n){if(!t)return e;if(e._n)return e;const s=(...n)=>{s._d&&Fr(-1);const o=Rn(t);let r;try{r=e(...n)}finally{Rn(o),s._d&&Fr(1)}return r};return s._n=!0,s._c=!0,s._d=!0,s}function Pn(e){const{type:t,vnode:n,proxy:s,withProxy:o,props:r,propsOptions:[l],slots:c,attrs:a,emit:u,render:d,renderCache:p,data:h,setupState:f,ctx:m,inheritAttrs:g}=e;let v,y;const b=Rn(e);try{if(4&n.shapeFlag){const e=o||s;v=Xr(d.call(e,e,p,r,f,h,m)),y=a}else{const e=t;0,v=Xr(e(r,e.length>1?{attrs:a,slots:c,emit:u}:null)),y=t.props?a:$n(a)}}catch(S){Ar.length=0,ln(S,e,1),v=qr(wr)}let _=v;if(y&&!1!==g){const e=Object.keys(y),{shapeFlag:t}=_;e.length&&7&t&&(l&&e.some(i)&&(y=Bn(y,l)),_=Kr(_,y))}return n.dirs&&(_=Kr(_),_.dirs=_.dirs?_.dirs.concat(n.dirs):n.dirs),n.transition&&(_.transition=n.transition),v=_,Rn(b),v}const $n=e=>{let t;for(const n in e)("class"===n||"style"===n||r(n))&&((t||(t={}))[n]=e[n]);return t},Bn=(e,t)=>{const n={};for(const s in e)i(s)&&s.slice(9)in t||(n[s]=e[s]);return n};function Vn(e,t,n){const s=Object.keys(t);if(s.length!==Object.keys(e).length)return!0;for(let o=0;oe.__isSuspense;let Jn=0;const Xn={name:"Suspense",__isSuspense:!0,process(e,t,n,s,o,r,i,l,c,a){if(null==e)!function(e,t,n,s,o,r,i,l,c){const{p:a,o:{createElement:u}}=c,d=u("div"),p=e.suspense=Zn(e,o,s,t,d,n,r,i,l,c);a(null,p.pendingBranch=e.ssContent,d,null,s,p,r,i),p.deps>0?(Qn(e,"onPending"),Qn(e,"onFallback"),a(null,e.ssFallback,t,n,s,null,r,i),ts(p,e.ssFallback)):p.resolve(!1,!0)}(t,n,s,o,r,i,l,c,a);else{if(r&&r.deps>0)return void(t.suspense=e.suspense);!function(e,t,n,s,o,r,i,l,{p:c,um:a,o:{createElement:u}}){const d=t.suspense=e.suspense;d.vnode=t,t.el=e.el;const p=t.ssContent,h=t.ssFallback,{activeBranch:f,pendingBranch:m,isInFallback:g,isHydrating:v}=d;if(m)d.pendingBranch=p,Br(p,m)?(c(m,p,d.hiddenContainer,null,o,d,r,i,l),d.deps<=0?d.resolve():g&&(v||(c(f,h,n,s,o,null,r,i,l),ts(d,h)))):(d.pendingId=Jn++,v?(d.isHydrating=!1,d.activeBranch=m):a(m,o,d),d.deps=0,d.effects.length=0,d.hiddenContainer=u("div"),g?(c(null,p,d.hiddenContainer,null,o,d,r,i,l),d.deps<=0?d.resolve():(c(f,h,n,s,o,null,r,i,l),ts(d,h))):f&&Br(p,f)?(c(f,p,n,s,o,d,r,i,l),d.resolve(!0)):(c(null,p,d.hiddenContainer,null,o,d,r,i,l),d.deps<=0&&d.resolve()));else if(f&&Br(p,f))c(f,p,n,s,o,d,r,i,l),ts(d,p);else if(Qn(t,"onPending"),d.pendingBranch=p,d.pendingId=512&p.shapeFlag?p.component.suspenseId:Jn++,c(null,p,d.hiddenContainer,null,o,d,r,i,l),d.deps<=0)d.resolve();else{const{timeout:e,pendingId:t}=d;e>0?setTimeout((()=>{d.pendingId===t&&d.fallback(h)}),e):0===e&&d.fallback(h)}}(e,t,n,s,o,i,l,c,a)}},hydrate:function(e,t,n,s,o,r,i,l,c){const a=t.suspense=Zn(t,s,n,e.parentNode,document.createElement("div"),null,o,r,i,l,!0),u=c(e,a.pendingBranch=t.ssContent,n,a,r,i);0===a.deps&&a.resolve(!1,!0);return u},create:Zn,normalize:function(e){const{shapeFlag:t,children:n}=e,s=32&t;e.ssContent=Yn(s?n.default:n),e.ssFallback=s?Yn(n.fallback):qr(wr)}};function Qn(e,t){const n=e.props&&e.props[t];m(n)&&n()}function Zn(e,t,n,s,o,r,i,l,c,a,u=!1){const{p:d,m:p,um:h,n:f,o:{parentNode:m,remove:g}}=a;let v;const y=function(e){var t;return null!=(null==(t=e.props)?void 0:t.suspensible)&&!1!==e.props.suspensible}(e);y&&(null==t?void 0:t.pendingBranch)&&(v=t.pendingId,t.deps++);const b=e.props?B(e.props.timeout):void 0,_=r,S={vnode:e,parent:t,parentComponent:n,namespace:i,container:s,hiddenContainer:o,deps:0,pendingId:Jn++,timeout:"number"==typeof b?b:-1,activeBranch:null,pendingBranch:null,isInFallback:!u,isHydrating:u,isUnmounted:!1,effects:[],resolve(e=!1,n=!1){const{vnode:s,activeBranch:o,pendingBranch:i,pendingId:l,effects:c,parentComponent:a,container:u}=S;let d=!1;S.isHydrating?S.isHydrating=!1:e||(d=o&&i.transition&&"out-in"===i.transition.mode,d&&(o.transition.afterLeave=()=>{l===S.pendingId&&(p(i,u,r===_?f(o):r,0),_n(c))}),o&&(m(o.el)!==S.hiddenContainer&&(r=f(o)),h(o,a,S,!0)),d||p(i,u,r,0)),ts(S,i),S.pendingBranch=null,S.isInFallback=!1;let g=S.parent,b=!1;for(;g;){if(g.pendingBranch){g.effects.push(...c),b=!0;break}g=g.parent}b||d||_n(c),S.effects=[],y&&t&&t.pendingBranch&&v===t.pendingId&&(t.deps--,0!==t.deps||n||t.resolve()),Qn(s,"onResolve")},fallback(e){if(!S.pendingBranch)return;const{vnode:t,activeBranch:n,parentComponent:s,container:o,namespace:r}=S;Qn(t,"onFallback");const i=f(n),a=()=>{S.isInFallback&&(d(null,e,o,i,s,null,r,l,c),ts(S,e))},u=e.transition&&"out-in"===e.transition.mode;u&&(n.transition.afterLeave=a),S.isInFallback=!0,h(n,s,null,!0),u||a()},move(e,t,n){S.activeBranch&&p(S.activeBranch,e,t,n),S.container=e},next:()=>S.activeBranch&&f(S.activeBranch),registerDep(e,t){const n=!!S.pendingBranch;n&&S.deps++;const s=e.vnode.el;e.asyncDep.catch((t=>{ln(t,e,0)})).then((o=>{if(e.isUnmounted||S.isUnmounted||S.pendingId!==e.suspenseId)return;e.asyncResolved=!0;const{vnode:r}=e;hi(e,o,!1),s&&(r.el=s);const l=!s&&e.subTree.el;t(e,r,m(s||e.subTree.el),s?null:f(e.subTree),S,i,c),l&&g(l),Dn(e,r.el),n&&0==--S.deps&&S.resolve()}))},unmount(e,t){S.isUnmounted=!0,S.activeBranch&&h(S.activeBranch,n,e,t),S.pendingBranch&&h(S.pendingBranch,n,e,t)}};return S}function Yn(e){let t;if(m(e)){const n=Or&&e._c;n&&(e._d=!1,Ir()),e=e(),n&&(e._d=!0,t=Er,Rr())}if(d(e)){const t=function(e,t=!0){let n;for(let s=0;st!==e))),e}function es(e,t){t&&t.pendingBranch?d(e)?t.effects.push(...e):t.effects.push(e):_n(e)}function ts(e,t){e.activeBranch=t;const{vnode:n,parentComponent:s}=e;let o=t.el;for(;!o&&t.component;)o=(t=t.component.subTree).el;n.el=o,s&&s.subTree===n&&(s.vnode.el=o,Dn(s,o))}const ns=Symbol.for("v-scx"),ss=()=>Uo(ns);function os(e,t){return as(e,null,t)}function rs(e,t){return as(e,null,{flush:"post"})}function is(e,t){return as(e,null,{flush:"sync"})}const ls={};function cs(e,t,n){return as(e,t,n)}function as(e,n,{immediate:o,deep:r,flush:i,once:l}=t){if(n&&l){const e=n;n=(...t)=>{e(...t),C()}}const a=si,u=e=>!0===r?e:ps(e,!1===r?1:void 0);let p,h,f=!1,g=!1;if($t(e)?(p=()=>e.value,f=At(e)):wt(e)?(p=()=>u(e),f=!0):d(e)?(g=!0,f=e.some((e=>wt(e)||At(e))),p=()=>e.map((e=>$t(e)?e.value:wt(e)?u(e):m(e)?on(e,a,2):void 0))):p=m(e)?n?()=>on(e,a,2):()=>(h&&h(),rn(e,a,3,[v])):s,n&&r){const e=p;p=()=>ps(e())}let v=e=>{h=S.onStop=()=>{on(e,a,4),h=S.onStop=void 0}},y=g?new Array(e.length).fill(ls):ls;const b=()=>{if(S.active&&S.dirty)if(n){const e=S.run();(r||f||(g?e.some(((e,t)=>L(e,y[t]))):L(e,y)))&&(h&&h(),rn(n,a,3,[e,y===ls?void 0:g&&y[0]===ls?[]:y,v]),y=e)}else S.run()};let _;b.allowRecurse=!!n,"sync"===i?_=b:"post"===i?_=()=>cr(b,a&&a.suspense):(b.pre=!0,a&&(b.id=a.uid),_=()=>yn(b));const S=new he(p,s,_),x=de(),C=()=>{S.stop(),x&&c(x.effects,S)};return n?o?b():y=S.run():"post"===i?cr(S.run.bind(S),a&&a.suspense):S.run(),C}function us(e,t,n){const s=this.proxy,o=g(e)?e.includes(".")?ds(s,e):()=>s[e]:e.bind(s,s);let r;m(t)?r=t:(r=t.handler,n=t);const i=li(this),l=as(o,r.bind(s),n);return i(),l}function ds(e,t){const n=t.split(".");return()=>{let t=e;for(let e=0;e0){if(n>=t)return e;n++}if((s=s||new Set).has(e))return e;if(s.add(e),$t(e))ps(e.value,t,n,s);else if(d(e))for(let o=0;o{ps(e,t,n,s)}));else if(C(e))for(const o in e)ps(e[o],t,n,s);return e}function hs(e,n){if(null===En)return e;const s=yi(En)||En.proxy,o=e.dirs||(e.dirs=[]);for(let r=0;r{e.isMounted=!0})),Ks((()=>{e.isUnmounting=!0})),e}const ys=[Function,Array],bs={mode:String,appear:Boolean,persisted:Boolean,onBeforeEnter:ys,onEnter:ys,onAfterEnter:ys,onEnterCancelled:ys,onBeforeLeave:ys,onLeave:ys,onAfterLeave:ys,onLeaveCancelled:ys,onBeforeAppear:ys,onAppear:ys,onAfterAppear:ys,onAppearCancelled:ys},_s={name:"BaseTransition",props:bs,setup(e,{slots:t}){const n=oi(),s=vs();let o;return()=>{const r=t.default&&ws(t.default(),!0);if(!r||!r.length)return;let i=r[0];if(r.length>1)for(const e of r)if(e.type!==wr){i=e;break}const l=It(e),{mode:c}=l;if(s.isLeaving)return Cs(i);const a=ks(i);if(!a)return Cs(i);const u=xs(a,l,s,n);Ts(a,u);const d=n.subTree,p=d&&ks(d);let h=!1;const{getTransitionKey:f}=a.type;if(f){const e=f();void 0===o?o=e:e!==o&&(o=e,h=!0)}if(p&&p.type!==wr&&(!Br(a,p)||h)){const e=xs(p,l,s,n);if(Ts(p,e),"out-in"===c)return s.isLeaving=!0,e.afterLeave=()=>{s.isLeaving=!1,!1!==n.update.active&&(n.effect.dirty=!0,n.update())},Cs(i);"in-out"===c&&a.type!==wr&&(e.delayLeave=(e,t,n)=>{Ss(s,p)[String(p.key)]=p,e[ms]=()=>{t(),e[ms]=void 0,delete u.delayedLeave},u.delayedLeave=n})}return i}}};function Ss(e,t){const{leavingVNodes:n}=e;let s=n.get(t.type);return s||(s=Object.create(null),n.set(t.type,s)),s}function xs(e,t,n,s){const{appear:o,mode:r,persisted:i=!1,onBeforeEnter:l,onEnter:c,onAfterEnter:a,onEnterCancelled:u,onBeforeLeave:p,onLeave:h,onAfterLeave:f,onLeaveCancelled:m,onBeforeAppear:g,onAppear:v,onAfterAppear:y,onAppearCancelled:b}=t,_=String(e.key),S=Ss(n,e),x=(e,t)=>{e&&rn(e,s,9,t)},C=(e,t)=>{const n=t[1];x(e,t),d(e)?e.every((e=>e.length<=1))&&n():e.length<=1&&n()},k={mode:r,persisted:i,beforeEnter(t){let s=l;if(!n.isMounted){if(!o)return;s=g||l}t[ms]&&t[ms](!0);const r=S[_];r&&Br(e,r)&&r.el[ms]&&r.el[ms](),x(s,[t])},enter(e){let t=c,s=a,r=u;if(!n.isMounted){if(!o)return;t=v||c,s=y||a,r=b||u}let i=!1;const l=e[gs]=t=>{i||(i=!0,x(t?r:s,[e]),k.delayedLeave&&k.delayedLeave(),e[gs]=void 0)};t?C(t,[e,l]):l()},leave(t,s){const o=String(e.key);if(t[gs]&&t[gs](!0),n.isUnmounting)return s();x(p,[t]);let r=!1;const i=t[ms]=n=>{r||(r=!0,s(),x(n?m:f,[t]),t[ms]=void 0,S[o]===e&&delete S[o])};S[o]=e,h?C(h,[t,i]):i()},clone:e=>xs(e,t,n,s)};return k}function Cs(e){if(Rs(e))return(e=Kr(e)).children=null,e}function ks(e){return Rs(e)?e.children?e.children[0]:void 0:e}function Ts(e,t){6&e.shapeFlag&&e.component?Ts(e.component.subTree,t):128&e.shapeFlag?(e.ssContent.transition=t.clone(e.ssContent),e.ssFallback.transition=t.clone(e.ssFallback)):e.transition=t}function ws(e,t=!1,n){let s=[],o=0;for(let r=0;r1)for(let r=0;rl({name:e.name},t,{setup:e}))():e}const As=e=>!!e.type.__asyncLoader +/*! #__NO_SIDE_EFFECTS__ */;function Es(e){m(e)&&(e={loader:e});const{loader:t,loadingComponent:n,errorComponent:s,delay:o=200,timeout:r,suspensible:i=!0,onError:l}=e;let c,a=null,u=0;const d=()=>{let e;return a||(e=a=t().catch((e=>{if(e=e instanceof Error?e:new Error(String(e)),l)return new Promise(((t,n)=>{l(e,(()=>t((u++,a=null,d()))),(()=>n(e)),u+1)}));throw e})).then((t=>e!==a&&a?a:(t&&(t.__esModule||"Module"===t[Symbol.toStringTag])&&(t=t.default),c=t,t))))};return Ns({name:"AsyncComponentWrapper",__asyncLoader:d,get __asyncResolved(){return c},setup(){const e=si;if(c)return()=>Is(c,e);const t=t=>{a=null,ln(t,e,13,!s)};if(i&&e.suspense)return d().then((t=>()=>Is(t,e))).catch((e=>(t(e),()=>s?qr(s,{error:e}):null)));const l=Bt(!1),u=Bt(),p=Bt(!!o);return o&&setTimeout((()=>{p.value=!1}),o),null!=r&&setTimeout((()=>{if(!l.value&&!u.value){const e=new Error(`Async component timed out after ${r}ms.`);t(e),u.value=e}}),r),d().then((()=>{l.value=!0,e.parent&&Rs(e.parent.vnode)&&(e.parent.effect.dirty=!0,yn(e.parent.update))})).catch((e=>{t(e),u.value=e})),()=>l.value&&c?Is(c,e):u.value&&s?qr(s,{error:u.value}):n&&!p.value?qr(n):void 0}})}function Is(e,t){const{ref:n,props:s,children:o,ce:r}=t.vnode,i=qr(e,s,o);return i.ref=n,i.ce=r,delete t.vnode.ce,i}const Rs=e=>e.type.__isKeepAlive,Os={name:"KeepAlive",__isKeepAlive:!0,props:{include:[String,RegExp,Array],exclude:[String,RegExp,Array],max:[String,Number]},setup(e,{slots:t}){const n=oi(),s=n.ctx,o=new Map,r=new Set;let i=null;const l=n.suspense,{renderer:{p:c,m:a,um:u,o:{createElement:d}}}=s,p=d("div");function h(e){Bs(e),u(e,n,l,!0)}function f(e){o.forEach(((t,n)=>{const s=bi(t.type);!s||e&&e(s)||m(n)}))}function m(e){const t=o.get(e);i&&Br(t,i)?i&&Bs(i):h(t),o.delete(e),r.delete(e)}s.activate=(e,t,n,s,o)=>{const r=e.component;a(e,t,n,0,l),c(r.vnode,e,t,n,r,l,s,e.slotScopeIds,o),cr((()=>{r.isDeactivated=!1,r.a&&M(r.a);const t=e.props&&e.props.onVnodeMounted;t&&ei(t,r.parent,e)}),l)},s.deactivate=e=>{const t=e.component;a(e,p,null,1,l),cr((()=>{t.da&&M(t.da);const n=e.props&&e.props.onVnodeUnmounted;n&&ei(n,t.parent,e),t.isDeactivated=!0}),l)},cs((()=>[e.include,e.exclude]),(([e,t])=>{e&&f((t=>Fs(e,t))),t&&f((e=>!Fs(t,e)))}),{flush:"post",deep:!0});let g=null;const v=()=>{null!=g&&o.set(g,Vs(n.subTree))};return Hs(v),Ws(v),Ks((()=>{o.forEach((e=>{const{subTree:t,suspense:s}=n,o=Vs(t);if(e.type!==o.type||e.key!==o.key)h(e);else{Bs(o);const e=o.component.da;e&&cr(e,s)}}))})),()=>{if(g=null,!t.default)return null;const n=t.default(),s=n[0];if(n.length>1)return i=null,n;if(!($r(s)&&(4&s.shapeFlag||128&s.shapeFlag)))return i=null,s;let l=Vs(s);const c=l.type,a=bi(As(l)?l.type.__asyncResolved||{}:c),{include:u,exclude:d,max:p}=e;if(u&&(!a||!Fs(u,a))||d&&a&&Fs(d,a))return i=l,s;const h=null==l.key?c:l.key,f=o.get(h);return l.el&&(l=Kr(l),128&s.shapeFlag&&(s.ssContent=l)),g=h,f?(l.el=f.el,l.component=f.component,l.transition&&Ts(l,l.transition),l.shapeFlag|=512,r.delete(h),r.add(h)):(r.add(h),p&&r.size>parseInt(p,10)&&m(r.values().next().value)),l.shapeFlag|=256,i=l,Gn(s.type)?s:l}}};function Fs(e,t){return d(e)?e.some((e=>Fs(e,t))):g(e)?e.split(",").includes(t):"[object RegExp]"===S(e)&&e.test(t)}function Ls(e,t){Ps(e,"a",t)}function Ms(e,t){Ps(e,"da",t)}function Ps(e,t,n=si){const s=e.__wdc||(e.__wdc=()=>{let t=n;for(;t;){if(t.isDeactivated)return;t=t.parent}return e()});if(Ds(t,s,n),n){let e=n.parent;for(;e&&e.parent;)Rs(e.parent.vnode)&&$s(s,t,n,e),e=e.parent}}function $s(e,t,n,s){const o=Ds(t,e,s,!0);zs((()=>{c(s[t],o)}),n)}function Bs(e){e.shapeFlag&=-257,e.shapeFlag&=-513}function Vs(e){return 128&e.shapeFlag?e.ssContent:e}function Ds(e,t,n=si,s=!1){if(n){const o=n[e]||(n[e]=[]),r=t.__weh||(t.__weh=(...s)=>{if(n.isUnmounted)return;Ce();const o=li(n),r=rn(t,n,e,s);return o(),ke(),r});return s?o.unshift(r):o.push(r),r}}const Us=e=>(t,n=si)=>(!pi||"sp"===e)&&Ds(e,((...e)=>t(...e)),n),js=Us("bm"),Hs=Us("m"),qs=Us("bu"),Ws=Us("u"),Ks=Us("bum"),zs=Us("um"),Gs=Us("sp"),Js=Us("rtg"),Xs=Us("rtc");function Qs(e,t=si){Ds("ec",e,t)}function Zs(e,t,n,s){let o;const r=n&&n[s];if(d(e)||g(e)){o=new Array(e.length);for(let n=0,s=e.length;nt(e,n,void 0,r&&r[n])));else{const n=Object.keys(e);o=new Array(n.length);for(let s=0,i=n.length;s{const t=s.fn(...e);return t&&(t.key=s.key),t}:s.fn)}return e}function eo(e,t,n={},s,o){if(En.isCE||En.parent&&As(En.parent)&&En.parent.isCE)return"default"!==t&&(n.name=t),qr("slot",n,s&&s());let r=e[t];r&&r._c&&(r._d=!1),Ir();const i=r&&to(r(n)),l=Pr(kr,{key:n.key||i&&i.key||`_${t}`},i||(s?s():[]),i&&1===e._?64:-2);return!o&&l.scopeId&&(l.slotScopeIds=[l.scopeId+"-s"]),r&&r._c&&(r._d=!0),l}function to(e){return e.some((e=>!$r(e)||e.type!==wr&&!(e.type===kr&&!to(e.children))))?e:null}function no(e,t){const n={};for(const s in e)n[t&&/[A-Z]/.test(s)?`on:${s}`:F(s)]=e[s];return n}const so=e=>e?ai(e)?yi(e)||e.proxy:so(e.parent):null,oo=l(Object.create(null),{$:e=>e,$el:e=>e.vnode.el,$data:e=>e.data,$props:e=>e.props,$attrs:e=>e.attrs,$slots:e=>e.slots,$refs:e=>e.refs,$parent:e=>so(e.parent),$root:e=>so(e.root),$emit:e=>e.emit,$options:e=>Ao(e),$forceUpdate:e=>e.f||(e.f=()=>{e.effect.dirty=!0,yn(e.update)}),$nextTick:e=>e.n||(e.n=vn.bind(e.proxy)),$watch:e=>us.bind(e)}),ro=(e,n)=>e!==t&&!e.__isScriptSetup&&u(e,n),io={get({_:e},n){const{ctx:s,setupState:o,data:r,props:i,accessCache:l,type:c,appContext:a}=e;let d;if("$"!==n[0]){const c=l[n];if(void 0!==c)switch(c){case 1:return o[n];case 2:return r[n];case 4:return s[n];case 3:return i[n]}else{if(ro(o,n))return l[n]=1,o[n];if(r!==t&&u(r,n))return l[n]=2,r[n];if((d=e.propsOptions[0])&&u(d,n))return l[n]=3,i[n];if(s!==t&&u(s,n))return l[n]=4,s[n];ko&&(l[n]=0)}}const p=oo[n];let h,f;return p?("$attrs"===n&&Me(e,0,n),p(e)):(h=c.__cssModules)&&(h=h[n])?h:s!==t&&u(s,n)?(l[n]=4,s[n]):(f=a.config.globalProperties,u(f,n)?f[n]:void 0)},set({_:e},n,s){const{data:o,setupState:r,ctx:i}=e;return ro(r,n)?(r[n]=s,!0):o!==t&&u(o,n)?(o[n]=s,!0):!u(e.props,n)&&(("$"!==n[0]||!(n.slice(1)in e))&&(i[n]=s,!0))},has({_:{data:e,setupState:n,accessCache:s,ctx:o,appContext:r,propsOptions:i}},l){let c;return!!s[l]||e!==t&&u(e,l)||ro(n,l)||(c=i[0])&&u(c,l)||u(o,l)||u(oo,l)||u(r.config.globalProperties,l)},defineProperty(e,t,n){return null!=n.get?e._.accessCache[t]=0:u(n,"value")&&this.set(e,t,n.value,null),Reflect.defineProperty(e,t,n)}},lo=l({},io,{get(e,t){if(t!==Symbol.unscopables)return io.get(e,t,e)},has:(e,t)=>"_"!==t[0]&&!U(t)});function co(){return null}function ao(){return null}function uo(e){}function po(e){}function ho(){return null}function fo(){}function mo(e,t){return null}function go(){return yo().slots}function vo(){return yo().attrs}function yo(){const e=oi();return e.setupContext||(e.setupContext=vi(e))}function bo(e){return d(e)?e.reduce(((e,t)=>(e[t]=null,e)),{}):e}function _o(e,t){const n=bo(e);for(const s in t){if(s.startsWith("__skip"))continue;let e=n[s];e?d(e)||m(e)?e=n[s]={type:e,default:t[s]}:e.default=t[s]:null===e&&(e=n[s]={default:t[s]}),e&&t[`__skip_${s}`]&&(e.skipFactory=!0)}return n}function So(e,t){return e&&t?d(e)&&d(t)?e.concat(t):l({},bo(e),bo(t)):e||t}function xo(e,t){const n={};for(const s in e)t.includes(s)||Object.defineProperty(n,s,{enumerable:!0,get:()=>e[s]});return n}function Co(e){const t=oi();let n=e();return ci(),b(n)&&(n=n.catch((e=>{throw li(t),e}))),[n,()=>li(t)]}let ko=!0;function To(e){const t=Ao(e),n=e.proxy,o=e.ctx;ko=!1,t.beforeCreate&&wo(t.beforeCreate,e,"bc");const{data:r,computed:i,methods:l,watch:c,provide:a,inject:u,created:p,beforeMount:h,mounted:f,beforeUpdate:g,updated:v,activated:b,deactivated:_,beforeUnmount:S,unmounted:x,render:C,renderTracked:k,renderTriggered:T,errorCaptured:w,serverPrefetch:N,expose:A,inheritAttrs:E,components:I,directives:R}=t;if(u&&function(e,t,n=s){d(e)&&(e=Oo(e));for(const s in e){const n=e[s];let o;o=y(n)?"default"in n?Uo(n.from||s,n.default,!0):Uo(n.from||s):Uo(n),$t(o)?Object.defineProperty(t,s,{enumerable:!0,configurable:!0,get:()=>o.value,set:e=>o.value=e}):t[s]=o}}(u,o,null),l)for(const s in l){const e=l[s];m(e)&&(o[s]=e.bind(n))}if(r){const t=r.call(n,n);y(t)&&(e.data=St(t))}if(ko=!0,i)for(const d in i){const e=i[d],t=m(e)?e.bind(n,n):m(e.get)?e.get.bind(n,n):s,r=!m(e)&&m(e.set)?e.set.bind(n):s,l=_i({get:t,set:r});Object.defineProperty(o,d,{enumerable:!0,configurable:!0,get:()=>l.value,set:e=>l.value=e})}if(c)for(const s in c)No(c[s],o,n,s);if(a){const e=m(a)?a.call(n):a;Reflect.ownKeys(e).forEach((t=>{Do(t,e[t])}))}function O(e,t){d(t)?t.forEach((t=>e(t.bind(n)))):t&&e(t.bind(n))}if(p&&wo(p,e,"c"),O(js,h),O(Hs,f),O(qs,g),O(Ws,v),O(Ls,b),O(Ms,_),O(Qs,w),O(Xs,k),O(Js,T),O(Ks,S),O(zs,x),O(Gs,N),d(A))if(A.length){const t=e.exposed||(e.exposed={});A.forEach((e=>{Object.defineProperty(t,e,{get:()=>n[e],set:t=>n[e]=t})}))}else e.exposed||(e.exposed={});C&&e.render===s&&(e.render=C),null!=E&&(e.inheritAttrs=E),I&&(e.components=I),R&&(e.directives=R)}function wo(e,t,n){rn(d(e)?e.map((e=>e.bind(t.proxy))):e.bind(t.proxy),t,n)}function No(e,t,n,s){const o=s.includes(".")?ds(n,s):()=>n[s];if(g(e)){const n=t[e];m(n)&&cs(o,n)}else if(m(e))cs(o,e.bind(n));else if(y(e))if(d(e))e.forEach((e=>No(e,t,n,s)));else{const s=m(e.handler)?e.handler.bind(n):t[e.handler];m(s)&&cs(o,s,e)}}function Ao(e){const t=e.type,{mixins:n,extends:s}=t,{mixins:o,optionsCache:r,config:{optionMergeStrategies:i}}=e.appContext,l=r.get(t);let c;return l?c=l:o.length||n||s?(c={},o.length&&o.forEach((e=>Eo(c,e,i,!0))),Eo(c,t,i)):c=t,y(t)&&r.set(t,c),c}function Eo(e,t,n,s=!1){const{mixins:o,extends:r}=t;r&&Eo(e,r,n,!0),o&&o.forEach((t=>Eo(e,t,n,!0)));for(const i in t)if(s&&"expose"===i);else{const s=Io[i]||n&&n[i];e[i]=s?s(e[i],t[i]):t[i]}return e}const Io={data:Ro,props:Mo,emits:Mo,methods:Lo,computed:Lo,beforeCreate:Fo,created:Fo,beforeMount:Fo,mounted:Fo,beforeUpdate:Fo,updated:Fo,beforeDestroy:Fo,beforeUnmount:Fo,destroyed:Fo,unmounted:Fo,activated:Fo,deactivated:Fo,errorCaptured:Fo,serverPrefetch:Fo,components:Lo,directives:Lo,watch:function(e,t){if(!e)return t;if(!t)return e;const n=l(Object.create(null),e);for(const s in t)n[s]=Fo(e[s],t[s]);return n},provide:Ro,inject:function(e,t){return Lo(Oo(e),Oo(t))}};function Ro(e,t){return t?e?function(){return l(m(e)?e.call(this,this):e,m(t)?t.call(this,this):t)}:t:e}function Oo(e){if(d(e)){const t={};for(let n=0;n(r.has(e)||(e&&m(e.install)?(r.add(e),e.install(c,...t)):m(e)&&(r.add(e),e(c,...t))),c),mixin:e=>(o.mixins.includes(e)||o.mixins.push(e),c),component:(e,t)=>t?(o.components[e]=t,c):o.components[e],directive:(e,t)=>t?(o.directives[e]=t,c):o.directives[e],mount(r,l,a){if(!i){const u=qr(n,s);return u.appContext=o,!0===a?a="svg":!1===a&&(a=void 0),l&&t?t(u,r):e(u,r,a),i=!0,c._container=r,r.__vue_app__=c,yi(u.component)||u.component.proxy}},unmount(){i&&(e(null,c._container),delete c._container.__vue_app__)},provide:(e,t)=>(o.provides[e]=t,c),runWithContext(e){Vo=c;try{return e()}finally{Vo=null}}};return c}}let Vo=null;function Do(e,t){if(si){let n=si.provides;const s=si.parent&&si.parent.provides;s===n&&(n=si.provides=Object.create(s)),n[e]=t}else;}function Uo(e,t,n=!1){const s=si||En;if(s||Vo){const o=s?null==s.parent?s.vnode.appContext&&s.vnode.appContext.provides:s.parent.provides:Vo._context.provides;if(o&&e in o)return o[e];if(arguments.length>1)return n&&m(t)?t.call(s&&s.proxy):t}}function jo(){return!!(si||En||Vo)}function Ho(e,n,s,o){const[r,i]=e.propsOptions;let l,c=!1;if(n)for(let t in n){if(T(t))continue;const a=n[t];let d;r&&u(r,d=E(t))?i&&i.includes(d)?(l||(l={}))[d]=a:s[d]=a:An(e.emitsOptions,t)||t in o&&a===o[t]||(o[t]=a,c=!0)}if(i){const n=It(s),o=l||t;for(let t=0;t{h=!0;const[t,n]=Wo(e,s,!0);l(a,t),n&&p.push(...n)};!o&&s.mixins.length&&s.mixins.forEach(t),e.extends&&t(e.extends),e.mixins&&e.mixins.forEach(t)}if(!c&&!h)return y(e)&&r.set(e,n),n;if(d(c))for(let n=0;n-1,s[1]=n<0||t-1||u(s,"default"))&&p.push(e)}}}const f=[a,p];return y(e)&&r.set(e,f),f}function Ko(e){return"$"!==e[0]}function zo(e){const t=e&&e.toString().match(/^\s*(function|class) (\w+)/);return t?t[2]:null===e?"null":""}function Go(e,t){return zo(e)===zo(t)}function Jo(e,t){return d(t)?t.findIndex((t=>Go(t,e))):m(t)&&Go(t,e)?0:-1}const Xo=e=>"_"===e[0]||"$stable"===e,Qo=e=>d(e)?e.map(Xr):[Xr(e)],Zo=(e,t,n)=>{if(t._n)return t;const s=Mn(((...e)=>Qo(t(...e))),n);return s._c=!1,s},Yo=(e,t,n)=>{const s=e._ctx;for(const o in e){if(Xo(o))continue;const n=e[o];if(m(n))t[o]=Zo(0,n,s);else if(null!=n){const e=Qo(n);t[o]=()=>e}}},er=(e,t)=>{const n=Qo(t);e.slots.default=()=>n},tr=(e,t)=>{if(32&e.vnode.shapeFlag){const n=t._;n?(e.slots=It(t),P(t,"_",n)):Yo(t,e.slots={})}else e.slots={},t&&er(e,t);P(e.slots,Dr,1)},nr=(e,n,s)=>{const{vnode:o,slots:r}=e;let i=!0,c=t;if(32&o.shapeFlag){const e=n._;e?s&&1===e?i=!1:(l(r,n),s||1!==e||delete r._):(i=!n.$stable,Yo(n,r)),c=n}else n&&(er(e,n),c={default:1});if(i)for(const t in r)Xo(t)||null!=c[t]||delete r[t]};function sr(e,n,s,o,r=!1){if(d(e))return void e.forEach(((e,t)=>sr(e,n&&(d(n)?n[t]:n),s,o,r)));if(As(o)&&!r)return;const i=4&o.shapeFlag?yi(o.component)||o.component.proxy:o.el,l=r?null:i,{i:a,r:p}=e,h=n&&n.r,f=a.refs===t?a.refs={}:a.refs,v=a.setupState;if(null!=h&&h!==p&&(g(h)?(f[h]=null,u(v,h)&&(v[h]=null)):$t(h)&&(h.value=null)),m(p))on(p,a,12,[l,f]);else{const t=g(p),n=$t(p),o=e.f;if(t||n){const a=()=>{if(o){const n=t?u(v,p)?v[p]:f[p]:p.value;r?d(n)&&c(n,i):d(n)?n.includes(i)||n.push(i):t?(f[p]=[i],u(v,p)&&(v[p]=f[p])):(p.value=[i],e.k&&(f[e.k]=p.value))}else t?(f[p]=l,u(v,p)&&(v[p]=l)):n&&(p.value=l,e.k&&(f[e.k]=l))};r||o?a():(a.id=-1,cr(a,s))}}}let or=!1;const rr=e=>(e=>e.namespaceURI.includes("svg")&&"foreignObject"!==e.tagName)(e)?"svg":(e=>e.namespaceURI.includes("MathML"))(e)?"mathml":void 0,ir=e=>8===e.nodeType;function lr(e){const{mt:t,p:n,o:{patchProp:s,createText:o,nextSibling:i,parentNode:l,remove:c,insert:a,createComment:u}}=e,d=(n,s,r,c,u,b=!1)=>{const _=ir(n)&&"["===n.data,S=()=>m(n,s,r,c,u,_),{type:x,ref:C,shapeFlag:k,patchFlag:T}=s;let w=n.nodeType;s.el=n,-2===T&&(b=!1,s.dynamicChildren=null);let N=null;switch(x){case Tr:3!==w?""===s.children?(a(s.el=o(""),l(n),n),N=n):N=S():(n.data!==s.children&&(or=!0,n.data=s.children),N=i(n));break;case wr:y(n)?(N=i(n),v(s.el=n.content.firstChild,n,r)):N=8!==w||_?S():i(n);break;case Nr:if(_&&(w=(n=i(n)).nodeType),1===w||3===w){N=n;const e=!s.children.length;for(let t=0;t{l=l||!!t.dynamicChildren;const{type:a,props:u,patchFlag:d,shapeFlag:p,dirs:f,transition:m}=t,g="input"===a||"option"===a;if(g||-1!==d){f&&fs(t,null,n,"created");let a,b=!1;if(y(e)){b=fr(o,m)&&n&&n.vnode.props&&n.vnode.props.appear;const s=e.content.firstChild;b&&m.beforeEnter(s),v(s,e,n),t.el=e=s}if(16&p&&(!u||!u.innerHTML&&!u.textContent)){let s=h(e.firstChild,t,e,n,o,i,l);for(;s;){or=!0;const e=s;s=s.nextSibling,c(e)}}else 8&p&&e.textContent!==t.children&&(or=!0,e.textContent=t.children);if(u)if(g||!l||48&d)for(const t in u)(g&&(t.endsWith("value")||"indeterminate"===t)||r(t)&&!T(t)||"."===t[0])&&s(e,t,null,u[t],void 0,void 0,n);else u.onClick&&s(e,"onClick",null,u.onClick,void 0,void 0,n);(a=u&&u.onVnodeBeforeMount)&&ei(a,n,t),f&&fs(t,null,n,"beforeMount"),((a=u&&u.onVnodeMounted)||f||b)&&es((()=>{a&&ei(a,n,t),b&&m.enter(e),f&&fs(t,null,n,"mounted")}),o)}return e.nextSibling},h=(e,t,s,o,r,i,l)=>{l=l||!!t.dynamicChildren;const c=t.children,a=c.length;for(let u=0;u{const{slotScopeIds:c}=t;c&&(o=o?o.concat(c):c);const d=l(e),p=h(i(e),t,d,n,s,o,r);return p&&ir(p)&&"]"===p.data?i(t.anchor=p):(or=!0,a(t.anchor=u("]"),d,p),p)},m=(e,t,s,o,r,a)=>{if(or=!0,t.el=null,a){const t=g(e);for(;;){const n=i(e);if(!n||n===t)break;c(n)}}const u=i(e),d=l(e);return c(e),n(null,t,d,u,s,o,rr(d),r),u},g=(e,t="[",n="]")=>{let s=0;for(;e;)if((e=i(e))&&ir(e)&&(e.data===t&&s++,e.data===n)){if(0===s)return i(e);s--}return e},v=(e,t,n)=>{const s=t.parentNode;s&&s.replaceChild(e,t);let o=n;for(;o;)o.vnode.el===t&&(o.vnode.el=o.subTree.el=e),o=o.parent},y=e=>1===e.nodeType&&"template"===e.tagName.toLowerCase();return[(e,t)=>{if(!t.hasChildNodes())return n(null,e,t),xn(),void(t._vnode=e);or=!1,d(t.firstChild,e,null,null,null),xn(),t._vnode=e,or&&console.error("Hydration completed but contains mismatches.")},d]}const cr=es;function ar(e){return dr(e)}function ur(e){return dr(e,lr)}function dr(e,o){D().__VUE__=!0;const{insert:r,remove:i,patchProp:l,createElement:c,createText:a,createComment:d,setText:p,setElementText:h,parentNode:f,nextSibling:m,setScopeId:g=s,insertStaticContent:v}=e,y=(e,t,n,s=null,o=null,r=null,i=void 0,l=null,c=!!t.dynamicChildren)=>{if(e===t)return;e&&!Br(e,t)&&(s=Q(e),K(e,o,r,!0),e=null),-2===t.patchFlag&&(c=!1,t.dynamicChildren=null);const{type:a,ref:u,shapeFlag:d}=t;switch(a){case Tr:_(e,t,n,s);break;case wr:S(e,t,n,s);break;case Nr:null==e&&x(t,n,s,i);break;case kr:F(e,t,n,s,o,r,i,l,c);break;default:1&d?C(e,t,n,s,o,r,i,l,c):6&d?L(e,t,n,s,o,r,i,l,c):(64&d||128&d)&&a.process(e,t,n,s,o,r,i,l,c,ee)}null!=u&&o&&sr(u,e&&e.ref,r,t||e,!t)},_=(e,t,n,s)=>{if(null==e)r(t.el=a(t.children),n,s);else{const n=t.el=e.el;t.children!==e.children&&p(n,t.children)}},S=(e,t,n,s)=>{null==e?r(t.el=d(t.children||""),n,s):t.el=e.el},x=(e,t,n,s)=>{[e.el,e.anchor]=v(e.children,t,n,s,e.el,e.anchor)},C=(e,t,n,s,o,r,i,l,c)=>{"svg"===t.type?i="svg":"math"===t.type&&(i="mathml"),null==e?k(t,n,s,o,r,i,l,c):A(e,t,o,r,i,l,c)},k=(e,t,n,s,o,i,a,u)=>{let d,p;const{props:f,shapeFlag:m,transition:g,dirs:v}=e;if(d=e.el=c(e.type,i,f&&f.is,f),8&m?h(d,e.children):16&m&&N(e.children,d,null,s,o,pr(e,i),a,u),v&&fs(e,null,s,"created"),w(d,e,e.scopeId,a,s),f){for(const t in f)"value"===t||T(t)||l(d,t,null,f[t],i,e.children,s,o,X);"value"in f&&l(d,"value",null,f.value,i),(p=f.onVnodeBeforeMount)&&ei(p,s,e)}v&&fs(e,null,s,"beforeMount");const y=fr(o,g);y&&g.beforeEnter(d),r(d,t,n),((p=f&&f.onVnodeMounted)||y||v)&&cr((()=>{p&&ei(p,s,e),y&&g.enter(d),v&&fs(e,null,s,"mounted")}),o)},w=(e,t,n,s,o)=>{if(n&&g(e,n),s)for(let r=0;r{for(let a=c;a{const a=n.el=e.el;let{patchFlag:u,dynamicChildren:d,dirs:p}=n;u|=16&e.patchFlag;const f=e.props||t,m=n.props||t;let g;if(s&&hr(s,!1),(g=m.onVnodeBeforeUpdate)&&ei(g,s,n,e),p&&fs(n,e,s,"beforeUpdate"),s&&hr(s,!0),d?I(e.dynamicChildren,d,a,s,o,pr(n,r),i):c||j(e,n,a,null,s,o,pr(n,r),i,!1),u>0){if(16&u)O(a,n,f,m,s,o,r);else if(2&u&&f.class!==m.class&&l(a,"class",null,m.class,r),4&u&&l(a,"style",f.style,m.style,r),8&u){const t=n.dynamicProps;for(let n=0;n{g&&ei(g,s,n,e),p&&fs(n,e,s,"updated")}),o)},I=(e,t,n,s,o,r,i)=>{for(let l=0;l{if(s!==o){if(s!==t)for(const t in s)T(t)||t in o||l(e,t,s[t],null,c,n.children,r,i,X);for(const t in o){if(T(t))continue;const a=o[t],u=s[t];a!==u&&"value"!==t&&l(e,t,u,a,c,n.children,r,i,X)}"value"in o&&l(e,"value",s.value,o.value,c)}},F=(e,t,n,s,o,i,l,c,u)=>{const d=t.el=e?e.el:a(""),p=t.anchor=e?e.anchor:a("");let{patchFlag:h,dynamicChildren:f,slotScopeIds:m}=t;m&&(c=c?c.concat(m):m),null==e?(r(d,n,s),r(p,n,s),N(t.children||[],n,p,o,i,l,c,u)):h>0&&64&h&&f&&e.dynamicChildren?(I(e.dynamicChildren,f,n,o,i,l,c),(null!=t.key||o&&t===o.subTree)&&mr(e,t,!0)):j(e,t,n,p,o,i,l,c,u)},L=(e,t,n,s,o,r,i,l,c)=>{t.slotScopeIds=l,null==e?512&t.shapeFlag?o.ctx.activate(t,n,s,i,c):$(t,n,s,o,r,i,c):B(e,t,c)},$=(e,n,s,o,r,i,l)=>{const c=e.component=function(e,n,s){const o=e.type,r=(n?n.appContext:e.appContext)||ti,i={uid:ni++,vnode:e,type:o,parent:n,appContext:r,root:null,next:null,subTree:null,effect:null,update:null,scope:new ce(!0),render:null,proxy:null,exposed:null,exposeProxy:null,withProxy:null,provides:n?n.provides:Object.create(r.provides),accessCache:null,renderCache:[],components:null,directives:null,propsOptions:Wo(o,r),emitsOptions:Nn(o,r),emit:null,emitted:null,propsDefaults:t,inheritAttrs:o.inheritAttrs,ctx:t,data:t,props:t,attrs:t,slots:t,refs:t,setupState:t,setupContext:null,attrsProxy:null,slotsProxy:null,suspense:s,suspenseId:s?s.pendingId:0,asyncDep:null,asyncResolved:!1,isMounted:!1,isUnmounted:!1,isDeactivated:!1,bc:null,c:null,bm:null,m:null,bu:null,u:null,um:null,bum:null,da:null,a:null,rtg:null,rtc:null,ec:null,sp:null};i.ctx={_:i},i.root=n?n.root:i,i.emit=wn.bind(null,i),e.ce&&e.ce(i);return i}(e,o,r);if(Rs(e)&&(c.ctx.renderer=ee),function(e,t=!1){t&&ii(t);const{props:n,children:s}=e.vnode,o=ai(e);(function(e,t,n,s=!1){const o={},r={};P(r,Dr,1),e.propsDefaults=Object.create(null),Ho(e,t,o,r);for(const i in e.propsOptions[0])i in o||(o[i]=void 0);e.props=n?s?o:xt(o):e.type.props?o:r,e.attrs=r})(e,n,o,t),tr(e,s);const r=o?function(e,t){const n=e.type;e.accessCache=Object.create(null),e.proxy=Rt(new Proxy(e.ctx,io));const{setup:s}=n;if(s){const n=e.setupContext=s.length>1?vi(e):null,o=li(e);Ce();const r=on(s,e,0,[e.props,n]);if(ke(),o(),b(r)){if(r.then(ci,ci),t)return r.then((n=>{hi(e,n,t)})).catch((t=>{ln(t,e,0)}));e.asyncDep=r}else hi(e,r,t)}else gi(e,t)}(e,t):void 0;t&&ii(!1)}(c),c.asyncDep){if(r&&r.registerDep(c,V),!e.el){const e=c.subTree=qr(wr);S(null,e,n,s)}}else V(c,e,n,s,r,i,l)},B=(e,t,n)=>{const s=t.component=e.component;if(function(e,t,n){const{props:s,children:o,component:r}=e,{props:i,children:l,patchFlag:c}=t,a=r.emitsOptions;if(t.dirs||t.transition)return!0;if(!(n&&c>=0))return!(!o&&!l||l&&l.$stable)||s!==i&&(s?!i||Vn(s,i,a):!!i);if(1024&c)return!0;if(16&c)return s?Vn(s,i,a):!!i;if(8&c){const e=t.dynamicProps;for(let t=0;tdn&&un.splice(t,1)}(s.update),s.effect.dirty=!0,s.update()}else t.el=e.el,s.vnode=t},V=(e,t,n,o,r,i,l)=>{const c=()=>{if(e.isMounted){let{next:t,bu:n,u:s,parent:o,vnode:a}=e;{const n=gr(e);if(n)return t&&(t.el=a.el,U(e,t,l)),void n.asyncDep.then((()=>{e.isUnmounted||c()}))}let u,d=t;hr(e,!1),t?(t.el=a.el,U(e,t,l)):t=a,n&&M(n),(u=t.props&&t.props.onVnodeBeforeUpdate)&&ei(u,o,t,a),hr(e,!0);const p=Pn(e),h=e.subTree;e.subTree=p,y(h,p,f(h.el),Q(h),e,r,i),t.el=p.el,null===d&&Dn(e,p.el),s&&cr(s,r),(u=t.props&&t.props.onVnodeUpdated)&&cr((()=>ei(u,o,t,a)),r)}else{let s;const{el:l,props:c}=t,{bm:a,m:u,parent:d}=e,p=As(t);if(hr(e,!1),a&&M(a),!p&&(s=c&&c.onVnodeBeforeMount)&&ei(s,d,t),hr(e,!0),l&&ne){const n=()=>{e.subTree=Pn(e),ne(l,e.subTree,e,r,null)};p?t.type.__asyncLoader().then((()=>!e.isUnmounted&&n())):n()}else{const s=e.subTree=Pn(e);y(null,s,n,o,e,r,i),t.el=s.el}if(u&&cr(u,r),!p&&(s=c&&c.onVnodeMounted)){const e=t;cr((()=>ei(s,d,e)),r)}(256&t.shapeFlag||d&&As(d.vnode)&&256&d.vnode.shapeFlag)&&e.a&&cr(e.a,r),e.isMounted=!0,t=n=o=null}},a=e.effect=new he(c,s,(()=>yn(u)),e.scope),u=e.update=()=>{a.dirty&&a.run()};u.id=e.uid,hr(e,!0),u()},U=(e,t,n)=>{t.component=e;const s=e.vnode.props;e.vnode=t,e.next=null,function(e,t,n,s){const{props:o,attrs:r,vnode:{patchFlag:i}}=e,l=It(o),[c]=e.propsOptions;let a=!1;if(!(s||i>0)||16&i){let s;Ho(e,t,o,r)&&(a=!0);for(const r in l)t&&(u(t,r)||(s=R(r))!==r&&u(t,s))||(c?!n||void 0===n[r]&&void 0===n[s]||(o[r]=qo(c,l,r,void 0,e,!0)):delete o[r]);if(r!==l)for(const e in r)t&&u(t,e)||(delete r[e],a=!0)}else if(8&i){const n=e.vnode.dynamicProps;for(let s=0;s{const a=e&&e.children,u=e?e.shapeFlag:0,d=t.children,{patchFlag:p,shapeFlag:f}=t;if(p>0){if(128&p)return void q(a,d,n,s,o,r,i,l,c);if(256&p)return void H(a,d,n,s,o,r,i,l,c)}8&f?(16&u&&X(a,o,r),d!==a&&h(n,d)):16&u?16&f?q(a,d,n,s,o,r,i,l,c):X(a,o,r,!0):(8&u&&h(n,""),16&f&&N(d,n,s,o,r,i,l,c))},H=(e,t,s,o,r,i,l,c,a)=>{const u=(e=e||n).length,d=(t=t||n).length,p=Math.min(u,d);let h;for(h=0;hd?X(e,r,i,!0,!1,p):N(t,s,o,r,i,l,c,a,p)},q=(e,t,s,o,r,i,l,c,a)=>{let u=0;const d=t.length;let p=e.length-1,h=d-1;for(;u<=p&&u<=h;){const n=e[u],o=t[u]=a?Qr(t[u]):Xr(t[u]);if(!Br(n,o))break;y(n,o,s,null,r,i,l,c,a),u++}for(;u<=p&&u<=h;){const n=e[p],o=t[h]=a?Qr(t[h]):Xr(t[h]);if(!Br(n,o))break;y(n,o,s,null,r,i,l,c,a),p--,h--}if(u>p){if(u<=h){const e=h+1,n=eh)for(;u<=p;)K(e[u],r,i,!0),u++;else{const f=u,m=u,g=new Map;for(u=m;u<=h;u++){const e=t[u]=a?Qr(t[u]):Xr(t[u]);null!=e.key&&g.set(e.key,u)}let v,b=0;const _=h-m+1;let S=!1,x=0;const C=new Array(_);for(u=0;u<_;u++)C[u]=0;for(u=f;u<=p;u++){const n=e[u];if(b>=_){K(n,r,i,!0);continue}let o;if(null!=n.key)o=g.get(n.key);else for(v=m;v<=h;v++)if(0===C[v-m]&&Br(n,t[v])){o=v;break}void 0===o?K(n,r,i,!0):(C[o-m]=u+1,o>=x?x=o:S=!0,y(n,t[o],s,null,r,i,l,c,a),b++)}const k=S?function(e){const t=e.slice(),n=[0];let s,o,r,i,l;const c=e.length;for(s=0;s>1,e[n[l]]0&&(t[s]=n[r-1]),n[r]=s)}}r=n.length,i=n[r-1];for(;r-- >0;)n[r]=i,i=t[i];return n}(C):n;for(v=k.length-1,u=_-1;u>=0;u--){const e=m+u,n=t[e],p=e+1{const{el:i,type:l,transition:c,children:a,shapeFlag:u}=e;if(6&u)return void W(e.component.subTree,t,n,s);if(128&u)return void e.suspense.move(t,n,s);if(64&u)return void l.move(e,t,n,ee);if(l===kr){r(i,t,n);for(let e=0;e{let o;for(;e&&e!==t;)o=m(e),r(e,n,s),e=o;r(t,n,s)})(e,t,n);if(2!==s&&1&u&&c)if(0===s)c.beforeEnter(i),r(i,t,n),cr((()=>c.enter(i)),o);else{const{leave:e,delayLeave:s,afterLeave:o}=c,l=()=>r(i,t,n),a=()=>{e(i,(()=>{l(),o&&o()}))};s?s(i,l,a):a()}else r(i,t,n)},K=(e,t,n,s=!1,o=!1)=>{const{type:r,props:i,ref:l,children:c,dynamicChildren:a,shapeFlag:u,patchFlag:d,dirs:p}=e;if(null!=l&&sr(l,null,n,e,!0),256&u)return void t.ctx.deactivate(e);const h=1&u&&p,f=!As(e);let m;if(f&&(m=i&&i.onVnodeBeforeUnmount)&&ei(m,t,e),6&u)J(e.component,n,s);else{if(128&u)return void e.suspense.unmount(n,s);h&&fs(e,null,t,"beforeUnmount"),64&u?e.type.remove(e,t,n,o,ee,s):a&&(r!==kr||d>0&&64&d)?X(a,t,n,!1,!0):(r===kr&&384&d||!o&&16&u)&&X(c,t,n),s&&z(e)}(f&&(m=i&&i.onVnodeUnmounted)||h)&&cr((()=>{m&&ei(m,t,e),h&&fs(e,null,t,"unmounted")}),n)},z=e=>{const{type:t,el:n,anchor:s,transition:o}=e;if(t===kr)return void G(n,s);if(t===Nr)return void(({el:e,anchor:t})=>{let n;for(;e&&e!==t;)n=m(e),i(e),e=n;i(t)})(e);const r=()=>{i(n),o&&!o.persisted&&o.afterLeave&&o.afterLeave()};if(1&e.shapeFlag&&o&&!o.persisted){const{leave:t,delayLeave:s}=o,i=()=>t(n,r);s?s(e.el,r,i):i()}else r()},G=(e,t)=>{let n;for(;e!==t;)n=m(e),i(e),e=n;i(t)},J=(e,t,n)=>{const{bum:s,scope:o,update:r,subTree:i,um:l}=e;s&&M(s),o.stop(),r&&(r.active=!1,K(i,e,t,n)),l&&cr(l,t),cr((()=>{e.isUnmounted=!0}),t),t&&t.pendingBranch&&!t.isUnmounted&&e.asyncDep&&!e.asyncResolved&&e.suspenseId===t.pendingId&&(t.deps--,0===t.deps&&t.resolve())},X=(e,t,n,s=!1,o=!1,r=0)=>{for(let i=r;i6&e.shapeFlag?Q(e.component.subTree):128&e.shapeFlag?e.suspense.next():m(e.anchor||e.el);let Z=!1;const Y=(e,t,n)=>{null==e?t._vnode&&K(t._vnode,null,null,!0):y(t._vnode||null,e,t,null,null,null,n),Z||(Z=!0,Sn(),xn(),Z=!1),t._vnode=e},ee={p:y,um:K,m:W,r:z,mt:$,mc:N,pc:j,pbc:I,n:Q,o:e};let te,ne;return o&&([te,ne]=o(ee)),{render:Y,hydrate:te,createApp:Bo(Y,te)}}function pr({type:e,props:t},n){return"svg"===n&&"foreignObject"===e||"mathml"===n&&"annotation-xml"===e&&t&&t.encoding&&t.encoding.includes("html")?void 0:n}function hr({effect:e,update:t},n){e.allowRecurse=t.allowRecurse=n}function fr(e,t){return(!e||e&&!e.pendingBranch)&&t&&!t.persisted}function mr(e,t,n=!1){const s=e.children,o=t.children;if(d(s)&&d(o))for(let r=0;re&&(e.disabled||""===e.disabled),yr=e=>"undefined"!=typeof SVGElement&&e instanceof SVGElement,br=e=>"function"==typeof MathMLElement&&e instanceof MathMLElement,_r=(e,t)=>{const n=e&&e.to;if(g(n)){if(t){return t(n)}return null}return n};function Sr(e,t,n,{o:{insert:s},m:o},r=2){0===r&&s(e.targetAnchor,t,n);const{el:i,anchor:l,shapeFlag:c,children:a,props:u}=e,d=2===r;if(d&&s(i,t,n),(!d||vr(u))&&16&c)for(let p=0;p{16&v&&u(y,e,t,o,r,i,l,c)};g?b(n,a):d&&b(d,p)}else{t.el=e.el;const s=t.anchor=e.anchor,u=t.target=e.target,h=t.targetAnchor=e.targetAnchor,m=vr(e.props),v=m?n:u,y=m?s:h;if("svg"===i||yr(u)?i="svg":("mathml"===i||br(u))&&(i="mathml"),b?(p(e.dynamicChildren,b,v,o,r,i,l),mr(e,t,!0)):c||d(e,t,v,y,o,r,i,l,!1),g)m?t.props&&e.props&&t.props.to!==e.props.to&&(t.props.to=e.props.to):Sr(t,n,s,a,1);else if((t.props&&t.props.to)!==(e.props&&e.props.to)){const e=t.target=_r(t.props,f);e&&Sr(t,e,null,a,0)}else m&&Sr(t,u,h,a,1)}Cr(t)},remove(e,t,n,s,{um:o,o:{remove:r}},i){const{shapeFlag:l,children:c,anchor:a,targetAnchor:u,target:d,props:p}=e;if(d&&r(u),i&&r(a),16&l){const e=i||!vr(p);for(let s=0;s0?Er||n:null,Rr(),Or>0&&Er&&Er.push(e),e}function Mr(e,t,n,s,o,r){return Lr(Hr(e,t,n,s,o,r,!0))}function Pr(e,t,n,s,o){return Lr(qr(e,t,n,s,o,!0))}function $r(e){return!!e&&!0===e.__v_isVNode}function Br(e,t){return e.type===t.type&&e.key===t.key}function Vr(e){}const Dr="__vInternal",Ur=({key:e})=>null!=e?e:null,jr=({ref:e,ref_key:t,ref_for:n})=>("number"==typeof e&&(e=""+e),null!=e?g(e)||$t(e)||m(e)?{i:En,r:e,k:t,f:!!n}:e:null);function Hr(e,t=null,n=null,s=0,o=null,r=(e===kr?0:1),i=!1,l=!1){const c={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&Ur(t),ref:t&&jr(t),scopeId:In,slotScopeIds:null,children:n,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetAnchor:null,staticCount:0,shapeFlag:r,patchFlag:s,dynamicProps:o,dynamicChildren:null,appContext:null,ctx:En};return l?(Zr(c,n),128&r&&e.normalize(c)):n&&(c.shapeFlag|=g(n)?8:16),Or>0&&!i&&Er&&(c.patchFlag>0||6&r)&&32!==c.patchFlag&&Er.push(c),c}const qr=function(e,t=null,n=null,s=0,o=null,r=!1){e&&e!==Hn||(e=wr);if($r(e)){const s=Kr(e,t,!0);return n&&Zr(s,n),Or>0&&!r&&Er&&(6&s.shapeFlag?Er[Er.indexOf(e)]=s:Er.push(s)),s.patchFlag|=-2,s}i=e,m(i)&&"__vccOpts"in i&&(e=e.__vccOpts);var i;if(t){t=Wr(t);let{class:e,style:n}=t;e&&!g(e)&&(t.class=z(e)),y(n)&&(Et(n)&&!d(n)&&(n=l({},n)),t.style=j(n))}const c=g(e)?1:Gn(e)?128:(e=>e.__isTeleport)(e)?64:y(e)?4:m(e)?2:0;return Hr(e,t,n,s,o,c,r,!0)};function Wr(e){return e?Et(e)||Dr in e?l({},e):e:null}function Kr(e,t,n=!1){const{props:s,ref:o,patchFlag:r,children:i}=e,l=t?Yr(s||{},t):s;return{__v_isVNode:!0,__v_skip:!0,type:e.type,props:l,key:l&&Ur(l),ref:t&&t.ref?n&&o?d(o)?o.concat(jr(t)):[o,jr(t)]:jr(t):o,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:i,target:e.target,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==kr?-1===r?16:16|r:r,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:e.transition,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&Kr(e.ssContent),ssFallback:e.ssFallback&&Kr(e.ssFallback),el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce}}function zr(e=" ",t=0){return qr(Tr,null,e,t)}function Gr(e,t){const n=qr(Nr,null,e);return n.staticCount=t,n}function Jr(e="",t=!1){return t?(Ir(),Pr(wr,null,e)):qr(wr,null,e)}function Xr(e){return null==e||"boolean"==typeof e?qr(wr):d(e)?qr(kr,null,e.slice()):"object"==typeof e?Qr(e):qr(Tr,null,String(e))}function Qr(e){return null===e.el&&-1!==e.patchFlag||e.memo?e:Kr(e)}function Zr(e,t){let n=0;const{shapeFlag:s}=e;if(null==t)t=null;else if(d(t))n=16;else if("object"==typeof t){if(65&s){const n=t.default;return void(n&&(n._c&&(n._d=!1),Zr(e,n()),n._c&&(n._d=!0)))}{n=32;const s=t._;s||Dr in t?3===s&&En&&(1===En.slots._?t._=1:(t._=2,e.patchFlag|=1024)):t._ctx=En}}else m(t)?(t={default:t,_ctx:En},n=32):(t=String(t),64&s?(n=16,t=[zr(t)]):n=8);e.children=t,e.shapeFlag|=n}function Yr(...e){const t={};for(let n=0;nsi||En;let ri,ii;ri=e=>{si=e},ii=e=>{pi=e};const li=e=>{const t=si;return ri(e),e.scope.on(),()=>{e.scope.off(),ri(t)}},ci=()=>{si&&si.scope.off(),ri(null)};function ai(e){return 4&e.vnode.shapeFlag}let ui,di,pi=!1;function hi(e,t,n){m(t)?e.render=t:y(t)&&(e.setupState=Kt(t)),gi(e,n)}function fi(e){ui=e,di=e=>{e.render._rc&&(e.withProxy=new Proxy(e.ctx,lo))}}const mi=()=>!ui;function gi(e,t,n){const o=e.type;if(!e.render){if(!t&&ui&&!o.render){const t=o.template||Ao(e).template;if(t){const{isCustomElement:n,compilerOptions:s}=e.appContext.config,{delimiters:r,compilerOptions:i}=o,c=l(l({isCustomElement:n,delimiters:r},s),i);o.render=ui(t,c)}}e.render=o.render||s,di&&di(e)}{const t=li(e);Ce();try{To(e)}finally{ke(),t()}}}function vi(e){const t=t=>{e.exposed=t||{}};return{get attrs(){return function(e){return e.attrsProxy||(e.attrsProxy=new Proxy(e.attrs,{get:(t,n)=>(Me(e,0,"$attrs"),t[n])}))}(e)},slots:e.slots,emit:e.emit,expose:t}}function yi(e){if(e.exposed)return e.exposeProxy||(e.exposeProxy=new Proxy(Kt(Rt(e.exposed)),{get:(t,n)=>n in t?t[n]:n in oo?oo[n](e):void 0,has:(e,t)=>t in e||t in oo}))}function bi(e,t=!0){return m(e)?e.displayName||e.name:e.name||t&&e.__name}const _i=(e,t)=>function(e,t,n=!1){let o,r;const i=m(e);return i?(o=e,r=s):(o=e.get,r=e.set),new Lt(o,r,i||!r,n)}(e,0,pi);function Si(e,n,s=t){const o=oi(),r=E(n),i=R(n),l=Gt(((t,l)=>{let c;return is((()=>{const t=e[n];L(c,t)&&(c=t,l())})),{get:()=>(t(),s.get?s.get(c):c),set(e){const t=o.vnode.props;t&&(n in t||r in t||i in t)&&(`onUpdate:${n}`in t||`onUpdate:${r}`in t||`onUpdate:${i}`in t)||!L(e,c)||(c=e,l()),o.emit(`update:${n}`,s.set?s.set(e):e)}}})),c="modelValue"===n?"modelModifiers":`${n}Modifiers`;return l[Symbol.iterator]=()=>{let t=0;return{next:()=>t<2?{value:t++?e[c]||{}:l,done:!1}:{done:!0}}},l}function xi(e,t,n){const s=arguments.length;return 2===s?y(t)&&!d(t)?$r(t)?qr(e,null,[t]):qr(e,t):qr(e,null,t):(s>3?n=Array.prototype.slice.call(arguments,2):3===s&&$r(n)&&(n=[n]),qr(e,t,n))}function Ci(){}function ki(e,t,n,s){const o=n[s];if(o&&Ti(o,e))return o;const r=t();return r.memo=e.slice(),n[s]=r}function Ti(e,t){const n=e.memo;if(n.length!=t.length)return!1;for(let s=0;s0&&Er&&Er.push(e),!0}const wi="3.4.15",Ni=s,Ai=null,Ei=void 0,Ii=s,Ri=null,Oi=null,Fi=null,Li=null,Mi="undefined"!=typeof document?document:null,Pi=Mi&&Mi.createElement("template"),$i={insert:(e,t,n)=>{t.insertBefore(e,n||null)},remove:e=>{const t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,n,s)=>{const o="svg"===t?Mi.createElementNS("http://www.w3.org/2000/svg",e):"mathml"===t?Mi.createElementNS("http://www.w3.org/1998/Math/MathML",e):Mi.createElement(e,n?{is:n}:void 0);return"select"===e&&s&&null!=s.multiple&&o.setAttribute("multiple",s.multiple),o},createText:e=>Mi.createTextNode(e),createComment:e=>Mi.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>Mi.querySelector(e),setScopeId(e,t){e.setAttribute(t,"")},insertStaticContent(e,t,n,s,o,r){const i=n?n.previousSibling:t.lastChild;if(o&&(o===r||o.nextSibling))for(;t.insertBefore(o.cloneNode(!0),n),o!==r&&(o=o.nextSibling););else{Pi.innerHTML="svg"===s?`${e}`:"mathml"===s?`${e}`:e;const o=Pi.content;if("svg"===s||"mathml"===s){const e=o.firstChild;for(;e.firstChild;)o.appendChild(e.firstChild);o.removeChild(e)}t.insertBefore(o,n)}return[i?i.nextSibling:t.firstChild,n?n.previousSibling:t.lastChild]}},Bi="transition",Vi="animation",Di=Symbol("_vtc"),Ui=(e,{slots:t})=>xi(_s,Ki(e),t);Ui.displayName="Transition";const ji={name:String,type:String,css:{type:Boolean,default:!0},duration:[String,Number,Object],enterFromClass:String,enterActiveClass:String,enterToClass:String,appearFromClass:String,appearActiveClass:String,appearToClass:String,leaveFromClass:String,leaveActiveClass:String,leaveToClass:String},Hi=Ui.props=l({},bs,ji),qi=(e,t=[])=>{d(e)?e.forEach((e=>e(...t))):e&&e(...t)},Wi=e=>!!e&&(d(e)?e.some((e=>e.length>1)):e.length>1);function Ki(e){const t={};for(const l in e)l in ji||(t[l]=e[l]);if(!1===e.css)return t;const{name:n="v",type:s,duration:o,enterFromClass:r=`${n}-enter-from`,enterActiveClass:i=`${n}-enter-active`,enterToClass:c=`${n}-enter-to`,appearFromClass:a=r,appearActiveClass:u=i,appearToClass:d=c,leaveFromClass:p=`${n}-leave-from`,leaveActiveClass:h=`${n}-leave-active`,leaveToClass:f=`${n}-leave-to`}=e,m=function(e){if(null==e)return null;if(y(e))return[zi(e.enter),zi(e.leave)];{const t=zi(e);return[t,t]}}(o),g=m&&m[0],v=m&&m[1],{onBeforeEnter:b,onEnter:_,onEnterCancelled:S,onLeave:x,onLeaveCancelled:C,onBeforeAppear:k=b,onAppear:T=_,onAppearCancelled:w=S}=t,N=(e,t,n)=>{Ji(e,t?d:c),Ji(e,t?u:i),n&&n()},A=(e,t)=>{e._isLeaving=!1,Ji(e,p),Ji(e,f),Ji(e,h),t&&t()},E=e=>(t,n)=>{const o=e?T:_,i=()=>N(t,e,n);qi(o,[t,i]),Xi((()=>{Ji(t,e?a:r),Gi(t,e?d:c),Wi(o)||Zi(t,s,g,i)}))};return l(t,{onBeforeEnter(e){qi(b,[e]),Gi(e,r),Gi(e,i)},onBeforeAppear(e){qi(k,[e]),Gi(e,a),Gi(e,u)},onEnter:E(!1),onAppear:E(!0),onLeave(e,t){e._isLeaving=!0;const n=()=>A(e,t);Gi(e,p),nl(),Gi(e,h),Xi((()=>{e._isLeaving&&(Ji(e,p),Gi(e,f),Wi(x)||Zi(e,s,v,n))})),qi(x,[e,n])},onEnterCancelled(e){N(e,!1),qi(S,[e])},onAppearCancelled(e){N(e,!0),qi(w,[e])},onLeaveCancelled(e){A(e),qi(C,[e])}})}function zi(e){return B(e)}function Gi(e,t){t.split(/\s+/).forEach((t=>t&&e.classList.add(t))),(e[Di]||(e[Di]=new Set)).add(t)}function Ji(e,t){t.split(/\s+/).forEach((t=>t&&e.classList.remove(t)));const n=e[Di];n&&(n.delete(t),n.size||(e[Di]=void 0))}function Xi(e){requestAnimationFrame((()=>{requestAnimationFrame(e)}))}let Qi=0;function Zi(e,t,n,s){const o=e._endId=++Qi,r=()=>{o===e._endId&&s()};if(n)return setTimeout(r,n);const{type:i,timeout:l,propCount:c}=Yi(e,t);if(!i)return s();const a=i+"end";let u=0;const d=()=>{e.removeEventListener(a,p),r()},p=t=>{t.target===e&&++u>=c&&d()};setTimeout((()=>{u(n[e]||"").split(", "),o=s(`${Bi}Delay`),r=s(`${Bi}Duration`),i=el(o,r),l=s(`${Vi}Delay`),c=s(`${Vi}Duration`),a=el(l,c);let u=null,d=0,p=0;t===Bi?i>0&&(u=Bi,d=i,p=r.length):t===Vi?a>0&&(u=Vi,d=a,p=c.length):(d=Math.max(i,a),u=d>0?i>a?Bi:Vi:null,p=u?u===Bi?r.length:c.length:0);return{type:u,timeout:d,propCount:p,hasTransform:u===Bi&&/\b(transform|all)(,|$)/.test(s(`${Bi}Property`).toString())}}function el(e,t){for(;e.lengthtl(t)+tl(e[n]))))}function tl(e){return"auto"===e?0:1e3*Number(e.slice(0,-1).replace(",","."))}function nl(){return document.body.offsetHeight}const sl=Symbol("_vod"),ol={beforeMount(e,{value:t},{transition:n}){e[sl]="none"===e.style.display?"":e.style.display,n&&t?n.beforeEnter(e):rl(e,t)},mounted(e,{value:t},{transition:n}){n&&t&&n.enter(e)},updated(e,{value:t,oldValue:n},{transition:s}){!t!=!n&&(s?t?(s.beforeEnter(e),rl(e,!0),s.enter(e)):s.leave(e,(()=>{rl(e,!1)})):rl(e,t))},beforeUnmount(e,{value:t}){rl(e,t)}};function rl(e,t){e.style.display=t?e[sl]:"none"}const il=Symbol("");function ll(e){const t=oi();if(!t)return;const n=t.ut=(n=e(t.proxy))=>{Array.from(document.querySelectorAll(`[data-v-owner="${t.uid}"]`)).forEach((e=>al(e,n)))},s=()=>{const s=e(t.proxy);cl(t.subTree,s),n(s)};rs(s),Hs((()=>{const e=new MutationObserver(s);e.observe(t.subTree.el.parentNode,{childList:!0}),zs((()=>e.disconnect()))}))}function cl(e,t){if(128&e.shapeFlag){const n=e.suspense;e=n.activeBranch,n.pendingBranch&&!n.isHydrating&&n.effects.push((()=>{cl(n.activeBranch,t)}))}for(;e.component;)e=e.component.subTree;if(1&e.shapeFlag&&e.el)al(e.el,t);else if(e.type===kr)e.children.forEach((e=>cl(e,t)));else if(e.type===Nr){let{el:n,anchor:s}=e;for(;n&&(al(n,t),n!==s);)n=n.nextSibling}}function al(e,t){if(1===e.nodeType){const n=e.style;let s="";for(const e in t)n.setProperty(`--${e}`,t[e]),s+=`--${e}: ${t[e]};`;n[il]=s}}const ul=/\s*!important$/;function dl(e,t,n){if(d(n))n.forEach((n=>dl(e,t,n)));else if(null==n&&(n=""),t.startsWith("--"))e.setProperty(t,n);else{const s=function(e,t){const n=hl[t];if(n)return n;let s=E(t);if("filter"!==s&&s in e)return hl[t]=s;s=O(s);for(let o=0;o{if(e._vts){if(e._vts<=n.attached)return}else e._vts=Date.now();rn(function(e,t){if(d(t)){const n=e.stopImmediatePropagation;return e.stopImmediatePropagation=()=>{n.call(e),e._stopped=!0},t.map((e=>t=>!t._stopped&&e&&e(t)))}return t}(e,n.value),t,5,[e])};return n.value=e,n.attached=Sl(),n}(s,o);ml(e,n,i,l)}else i&&(!function(e,t,n,s){e.removeEventListener(t,n,s)}(e,n,i,l),r[t]=void 0)}}const yl=/(?:Once|Passive|Capture)$/;let bl=0;const _l=Promise.resolve(),Sl=()=>bl||(_l.then((()=>bl=0)),bl=Date.now());const xl=e=>111===e.charCodeAt(0)&&110===e.charCodeAt(1)&&e.charCodeAt(2)>96&&e.charCodeAt(2)<123; /*! #__NO_SIDE_EFFECTS__ */ -function ll(e,t){const n=go(e);class o extends ul{constructor(e){super(n,e,t)}}return o.def=n,o} -/*! #__NO_SIDE_EFFECTS__ */const cl=e=>ll(e,Jl),al="undefined"!=typeof HTMLElement?HTMLElement:class{};class ul extends al{constructor(e,t={},n){super(),this._def=e,this._props=t,this._instance=null,this._connected=!1,this._resolved=!1,this._numberProps=null,this._ob=null,this.shadowRoot&&n?n(this._createVNode(),this.shadowRoot):(this.attachShadow({mode:"open"}),this._def.__asyncLoader||this._resolveProps(this._def))}connectedCallback(){this._connected=!0,this._instance||(this._resolved?this._update():this._resolveDef())}disconnectedCallback(){this._connected=!1,this._ob&&(this._ob.disconnect(),this._ob=null),fn((()=>{this._connected||(ql(null,this.shadowRoot),this._instance=null)}))}_resolveDef(){this._resolved=!0;for(let n=0;n{for(const t of e)this._setAttr(t.attributeName)})),this._ob.observe(this,{attributes:!0});const e=(e,t=!1)=>{const{props:n,styles:o}=e;let r;if(n&&!f(n))for(const s in n){const e=n[s];(e===Number||e&&e.type===Number)&&(s in this._props&&(this._props[s]=L(this._props[s])),(r||(r=Object.create(null)))[$(s)]=!0)}this._numberProps=r,t&&this._resolveProps(e),this._applyStyles(o),this._update()},t=this._def.__asyncLoader;t?t().then((t=>e(t,!0))):e(this._def)}_resolveProps(e){const{props:t}=e,n=f(t)?t:Object.keys(t||{});for(const o of Object.keys(this))"_"!==o[0]&&n.includes(o)&&this._setProp(o,this[o],!0,!1);for(const o of n.map($))Object.defineProperty(this,o,{get(){return this._getProp(o)},set(e){this._setProp(o,e)}})}_setAttr(e){let t=this.getAttribute(e);const n=$(e);this._numberProps&&this._numberProps[n]&&(t=L(t)),this._setProp(n,t,!1)}_getProp(e){return this._props[e]}_setProp(e,t,n=!0,o=!0){t!==this._props[e]&&(this._props[e]=t,o&&this._instance&&this._update(),n&&(!0===t?this.setAttribute(R(e),""):"string"==typeof t||"number"==typeof t?this.setAttribute(R(e),t+""):t||this.removeAttribute(R(e))))}_update(){ql(this._createVNode(),this.shadowRoot)}_createVNode(){const e=Is(this._def,c({},this._props));return this._instance||(e.ce=e=>{this._instance=e,e.isCE=!0;const t=(e,t)=>{this.dispatchEvent(new CustomEvent(e,{detail:t}))};e.emit=(e,...n)=>{t(e,n),R(e)!==e&&t(R(e),n)};let n=this;for(;n=n&&(n.parentNode||n.host);)if(n instanceof ul){e.parent=n._instance,e.provides=n._instance.provides;break}}),e}_applyStyles(e){e&&e.forEach((e=>{const t=document.createElement("style");t.textContent=e,this.shadowRoot.appendChild(t)}))}}function pl(e="$style"){{const n=Ys();if(!n)return t;const o=n.type.__cssModules;if(!o)return t;const r=o[e];return r||t}}function fl(e){const t=Ys();if(!t)return;const n=t.ut=(n=e(t.proxy))=>{Array.from(document.querySelectorAll(`[data-v-owner="${t.uid}"]`)).forEach((e=>hl(e,n)))},o=()=>{const o=e(t.proxy);dl(t.subTree,o),n(o)};Gn(o),Ro((()=>{const e=new MutationObserver(o);e.observe(t.subTree.el.parentNode,{childList:!0}),Vo((()=>e.disconnect()))}))}function dl(e,t){if(128&e.shapeFlag){const n=e.suspense;e=n.activeBranch,n.pendingBranch&&!n.isHydrating&&n.effects.push((()=>{dl(n.activeBranch,t)}))}for(;e.component;)e=e.component.subTree;if(1&e.shapeFlag&&e.el)hl(e.el,t);else if(e.type===vs)e.children.forEach((e=>dl(e,t)));else if(e.type===_s){let{el:n,anchor:o}=e;for(;n&&(hl(n,t),n!==o);)n=n.nextSibling}}function hl(e,t){if(1===e.nodeType){const n=e.style;for(const e in t)n.setProperty(`--${e}`,t[e])}}const ml=new WeakMap,gl=new WeakMap,vl=Symbol("_moveCb"),yl=Symbol("_enterCb"),bl={name:"TransitionGroup",props:c({},Pi,{tag:String,moveClass:String}),setup(e,{slots:t}){const n=Ys(),o=so();let r,s;return Fo((()=>{if(!r.length)return;const t=e.moveClass||`${e.name||"v"}-move`;if(!function(e,t,n){const o=e.cloneNode(),r=e[Ni];r&&r.forEach((e=>{e.split(/\s+/).forEach((e=>e&&o.classList.remove(e)))}));n.split(/\s+/).forEach((e=>e&&o.classList.add(e))),o.style.display="none";const s=1===t.nodeType?t:t.parentNode;s.appendChild(o);const{hasTransform:i}=Ui(o);return s.removeChild(o),i}(r[0].el,n.vnode.el,t))return;r.forEach(Sl),r.forEach(xl);const o=r.filter(Cl);Wi(),o.forEach((e=>{const n=e.el,o=n.style;Vi(n,t),o.transform=o.webkitTransform=o.transitionDuration="";const r=n[vl]=e=>{e&&e.target!==n||e&&!/transform$/.test(e.propertyName)||(n.removeEventListener("transitionend",r),n[vl]=null,Ii(n,t))};n.addEventListener("transitionend",r)}))})),()=>{const i=Et(e),l=Fi(i);let c=i.tag||vs;r=s,s=t.default?mo(t.default()):[];for(let e=0;e{const t=e.props["onUpdate:modelValue"]||!1;return f(t)?e=>V(t,e):t};function kl(e){e.target.composing=!0}function Tl(e){const t=e.target;t.composing&&(t.composing=!1,t.dispatchEvent(new Event("input")))}const El=Symbol("_assign"),Nl={created(e,{modifiers:{lazy:t,trim:n,number:o}},r){e[El]=wl(r);const s=o||r.props&&"number"===r.props.type;Xi(e,t?"change":"input",(t=>{if(t.target.composing)return;let o=e.value;n&&(o=o.trim()),s&&(o=B(o)),e[El](o)})),n&&Xi(e,"change",(()=>{e.value=e.value.trim()})),t||(Xi(e,"compositionstart",kl),Xi(e,"compositionend",Tl),Xi(e,"change",Tl))},mounted(e,{value:t}){e.value=null==t?"":t},beforeUpdate(e,{value:t,modifiers:{lazy:n,trim:o,number:r}},s){if(e[El]=wl(s),e.composing)return;if(document.activeElement===e&&"range"!==e.type){if(n)return;if(o&&e.value.trim()===t)return;if((r||"number"===e.type)&&B(e.value)===t)return}const i=null==t?"":t;e.value!==i&&(e.value=i)}},Ol={deep:!0,created(e,t,n){e[El]=wl(n),Xi(e,"change",(()=>{const t=e._modelValue,n=Fl(e),o=e.checked,r=e[El];if(f(t)){const e=ne(t,n),s=-1!==e;if(o&&!s)r(t.concat(n));else if(!o&&s){const n=[...t];n.splice(e,1),r(n)}}else if(h(t)){const e=new Set(t);o?e.add(n):e.delete(n),r(e)}else r(Ml(e,o))}))},mounted:$l,beforeUpdate(e,t,n){e[El]=wl(n),$l(e,t,n)}};function $l(e,{value:t,oldValue:n},o){e._modelValue=t,f(t)?e.checked=ne(t,o.props.value)>-1:h(t)?e.checked=t.has(o.props.value):t!==n&&(e.checked=te(t,Ml(e,!0)))}const Pl={created(e,{value:t},n){e.checked=te(t,n.props.value),e[El]=wl(n),Xi(e,"change",(()=>{e[El](Fl(e))}))},beforeUpdate(e,{value:t,oldValue:n},o){e[El]=wl(o),t!==n&&(e.checked=te(t,o.props.value))}},Rl={deep:!0,created(e,{value:t,modifiers:{number:n}},o){const r=h(t);Xi(e,"change",(()=>{const t=Array.prototype.filter.call(e.options,(e=>e.selected)).map((e=>n?B(Fl(e)):Fl(e)));e[El](e.multiple?r?new Set(t):t:t[0])})),e[El]=wl(o)},mounted(e,{value:t}){Al(e,t)},beforeUpdate(e,t,n){e[El]=wl(n)},updated(e,{value:t}){Al(e,t)}};function Al(e,t){const n=e.multiple;if(!n||f(t)||h(t)){for(let o=0,r=e.options.length;o-1:t.has(s);else if(te(Fl(r),t))return void(e.selectedIndex!==o&&(e.selectedIndex=o))}n||-1===e.selectedIndex||(e.selectedIndex=-1)}}function Fl(e){return"_value"in e?e._value:e.value}function Ml(e,t){const n=t?"_trueValue":"_falseValue";return n in e?e[n]:t}const Vl={created(e,t,n){Il(e,t,n,null,"created")},mounted(e,t,n){Il(e,t,n,null,"mounted")},beforeUpdate(e,t,n,o){Il(e,t,n,o,"beforeUpdate")},updated(e,t,n,o){Il(e,t,n,o,"updated")}};function Il(e,t,n,o,r){const s=function(e,t){switch(e){case"SELECT":return Rl;case"TEXTAREA":return Nl;default:switch(t){case"checkbox":return Ol;case"radio":return Pl;default:return Nl}}}(e.tagName,n.props&&n.props.type)[r];s&&s(e,t,n,o)}const Bl=["ctrl","shift","alt","meta"],Ll={stop:e=>e.stopPropagation(),prevent:e=>e.preventDefault(),self:e=>e.target!==e.currentTarget,ctrl:e=>!e.ctrlKey,shift:e=>!e.shiftKey,alt:e=>!e.altKey,meta:e=>!e.metaKey,left:e=>"button"in e&&0!==e.button,middle:e=>"button"in e&&1!==e.button,right:e=>"button"in e&&2!==e.button,exact:(e,t)=>Bl.some((n=>e[`${n}Key`]&&!t.includes(n)))},jl=(e,t)=>(n,...o)=>{for(let e=0;en=>{if(!("key"in n))return;const o=R(n.key);return t.some((e=>e===o||Ul[e]===o))?e(n):void 0},Hl=c({patchProp:(e,t,n,o,r=!1,s,c,a,u)=>{"class"===t?function(e,t,n){const o=e[Ni];o&&(t=(t?[t,...o]:[...o]).join(" ")),null==t?e.removeAttribute("class"):n?e.setAttribute("class",t):e.className=t}(e,o,r):"style"===t?function(e,t,n){const o=e.style,r=v(n);if(n&&!r){if(t&&!v(t))for(const e in t)null==n[e]&&Ji(o,e,"");for(const e in n)Ji(o,e,n[e])}else{const s=o.display;r?t!==n&&(o.cssText=n):t&&e.removeAttribute("style"),zi in e&&(o.display=s)}}(e,n,o):i(t)?l(t)||tl(e,t,0,o,c):("."===t[0]?(t=t.slice(1),1):"^"===t[0]?(t=t.slice(1),0):function(e,t,n,o){if(o)return"innerHTML"===t||"textContent"===t||!!(t in e&&il.test(t)&&g(n));if("spellcheck"===t||"draggable"===t||"translate"===t)return!1;if("form"===t)return!1;if("list"===t&&"INPUT"===e.tagName)return!1;if("type"===t&&"TEXTAREA"===e.tagName)return!1;if(il.test(t)&&v(n))return!1;return t in e}(e,t,o,r))?function(e,t,n,o,r,s,i){if("innerHTML"===t||"textContent"===t)return o&&i(o,r,s),void(e[t]=null==n?"":n);const l=e.tagName;if("value"===t&&"PROGRESS"!==l&&!l.includes("-")){e._value=n;const o=null==n?"":n;return("OPTION"===l?e.getAttribute("value"):e.value)!==o&&(e.value=o),void(null==n&&e.removeAttribute(t))}let c=!1;if(""===n||null==n){const o=typeof e[t];"boolean"===o?n=ee(n):null==n&&"string"===o?(n="",c=!0):"number"===o&&(n=0,c=!0)}try{e[t]=n}catch(a){}c&&e.removeAttribute(t)}(e,t,o,s,c,a,u):("true-value"===t?e._trueValue=o:"false-value"===t&&(e._falseValue=o),function(e,t,n,o,r){if(o&&t.startsWith("xlink:"))null==n?e.removeAttributeNS(Qi,t.slice(6,t.length)):e.setAttributeNS(Qi,t,n);else{const o=X(t);null==n||o&&!ee(n)?e.removeAttribute(t):e.setAttribute(t,o?"":n)}}(e,t,o,r))}},ki);let Wl,zl=!1;function Kl(){return Wl||(Wl=ss(Hl))}function Gl(){return Wl=zl?Wl:is(Hl),zl=!0,Wl}const ql=(...e)=>{Kl().render(...e)},Jl=(...e)=>{Gl().hydrate(...e)},Zl=(...e)=>{const t=Kl().createApp(...e),{mount:n}=t;return t.mount=e=>{const o=Ql(e);if(!o)return;const r=t._component;g(r)||r.render||r.template||(r.template=o.innerHTML),o.innerHTML="";const s=n(o,!1,o instanceof SVGElement);return o instanceof Element&&(o.removeAttribute("v-cloak"),o.setAttribute("data-v-app","")),s},t},Yl=(...e)=>{const t=Gl().createApp(...e),{mount:n}=t;return t.mount=e=>{const t=Ql(e);if(t)return n(t,!0,t instanceof SVGElement)},t};function Ql(e){if(v(e)){return document.querySelector(e)}return e}const Xl=o;var ec=Object.freeze({__proto__:null,BaseTransition:co,BaseTransitionPropsValidators:lo,Comment:bs,EffectScope:ie,Fragment:vs,KeepAlive:So,ReactiveEffect:Se,Static:_s,Suspense:jn,Teleport:ms,Text:ys,Transition:Oi,TransitionGroup:_l,VueElement:ul,assertNumber:Qt,callWithAsyncErrorHandling:en,callWithErrorHandling:Xt,camelize:$,capitalize:A,cloneVNode:Ls,compatUtils:null,computed:fi,createApp:Zl,createBlock:Os,createCommentVNode:Ds,createElementBlock:Ns,createElementVNode:Vs,createHydrationRenderer:is,createPropsRestProxy:yr,createRenderer:ss,createSSRApp:Yl,createSlots:Jo,createStaticVNode:Us,createTextVNode:js,createVNode:Is,customRef:Wt,defineAsyncComponent:yo,defineComponent:go,defineCustomElement:ll,defineEmits:sr,defineExpose:ir,defineModel:ar,defineOptions:lr,defineProps:rr,defineSSRCustomElement:cl,defineSlots:cr,get devtools(){return Sn},effect:Ce,effectScope:le,getCurrentInstance:Ys,getCurrentScope:ae,getTransitionRawChildren:mo,guardReactiveProps:Bs,h:di,handleError:tn,hasInjectionContext:Br,hydrate:Jl,initCustomFormatter:gi,initDirectivesForSSR:Xl,inject:Ir,isMemoSame:yi,isProxy:Tt,isReactive:Ct,isReadonly:wt,isRef:At,isRuntimeOnly:li,isShallow:kt,isVNode:$s,markRaw:Nt,mergeDefaults:gr,mergeModels:vr,mergeProps:Ks,nextTick:fn,normalizeClass:q,normalizeProps:J,normalizeStyle:H,onActivated:Co,onBeforeMount:Po,onBeforeUnmount:Mo,onBeforeUpdate:Ao,onDeactivated:wo,onErrorCaptured:jo,onMounted:Ro,onRenderTracked:Lo,onRenderTriggered:Bo,onScopeDispose:ue,onServerPrefetch:Io,onUnmounted:Vo,onUpdated:Fo,openBlock:Cs,popScopeId:Pn,provide:Vr,proxyRefs:Dt,pushScopeId:$n,queuePostFlushCb:mn,reactive:yt,readonly:_t,ref:Ft,registerRuntimeCompiler:ii,render:ql,renderList:qo,renderSlot:Zo,resolveComponent:Do,resolveDirective:zo,resolveDynamicComponent:Wo,resolveFilter:null,resolveTransitionHooks:uo,setBlockTracking:Ts,setDevtoolsHook:Cn,setTransitionHooks:ho,shallowReactive:bt,shallowReadonly:St,shallowRef:Mt,ssrContextKey:hi,ssrUtils:null,stop:we,toDisplayString:oe,toHandlerKey:F,toHandlers:Qo,toRaw:Et,toRef:qt,toRefs:zt,toValue:jt,transformVNodeArgs:Rs,triggerRef:Bt,unref:Lt,useAttrs:fr,useCssModule:pl,useCssVars:fl,useModel:dr,useSSRContext:mi,useSlots:pr,useTransitionState:so,vModelCheckbox:Ol,vModelDynamic:Vl,vModelRadio:Pl,vModelSelect:Rl,vModelText:Nl,vShow:Ki,version:bi,warn:Yt,watch:Zn,watchEffect:Kn,watchPostEffect:Gn,watchSyncEffect:qn,withAsyncContext:br,withCtx:An,withDefaults:ur,withDirectives:to,withKeys:Dl,withMemo:vi,withModifiers:jl,withScopeId:Rn});function tc(e){throw e}function nc(e){}function oc(e,t,n,o){const r=new SyntaxError(String(e));return r.code=e,r.loc=t,r}const rc=Symbol(""),sc=Symbol(""),ic=Symbol(""),lc=Symbol(""),cc=Symbol(""),ac=Symbol(""),uc=Symbol(""),pc=Symbol(""),fc=Symbol(""),dc=Symbol(""),hc=Symbol(""),mc=Symbol(""),gc=Symbol(""),vc=Symbol(""),yc=Symbol(""),bc=Symbol(""),_c=Symbol(""),Sc=Symbol(""),xc=Symbol(""),Cc=Symbol(""),wc=Symbol(""),kc=Symbol(""),Tc=Symbol(""),Ec=Symbol(""),Nc=Symbol(""),Oc=Symbol(""),$c=Symbol(""),Pc=Symbol(""),Rc=Symbol(""),Ac=Symbol(""),Fc=Symbol(""),Mc=Symbol(""),Vc=Symbol(""),Ic=Symbol(""),Bc=Symbol(""),Lc=Symbol(""),jc=Symbol(""),Uc=Symbol(""),Dc=Symbol(""),Hc={[rc]:"Fragment",[sc]:"Teleport",[ic]:"Suspense",[lc]:"KeepAlive",[cc]:"BaseTransition",[ac]:"openBlock",[uc]:"createBlock",[pc]:"createElementBlock",[fc]:"createVNode",[dc]:"createElementVNode",[hc]:"createCommentVNode",[mc]:"createTextVNode",[gc]:"createStaticVNode",[vc]:"resolveComponent",[yc]:"resolveDynamicComponent",[bc]:"resolveDirective",[_c]:"resolveFilter",[Sc]:"withDirectives",[xc]:"renderList",[Cc]:"renderSlot",[wc]:"createSlots",[kc]:"toDisplayString",[Tc]:"mergeProps",[Ec]:"normalizeClass",[Nc]:"normalizeStyle",[Oc]:"normalizeProps",[$c]:"guardReactiveProps",[Pc]:"toHandlers",[Rc]:"camelize",[Ac]:"capitalize",[Fc]:"toHandlerKey",[Mc]:"setBlockTracking",[Vc]:"pushScopeId",[Ic]:"popScopeId",[Bc]:"withCtx",[Lc]:"unref",[jc]:"isRef",[Uc]:"withMemo",[Dc]:"isMemoSame"};const Wc={source:"",start:{line:1,column:1,offset:0},end:{line:1,column:1,offset:0}};function zc(e,t,n,o,r,s,i,l=!1,c=!1,a=!1,u=Wc){return e&&(l?(e.helper(ac),e.helper(ta(e.inSSR,a))):e.helper(ea(e.inSSR,a)),i&&e.helper(Sc)),{type:13,tag:t,props:n,children:o,patchFlag:r,dynamicProps:s,directives:i,isBlock:l,disableTracking:c,isComponent:a,loc:u}}function Kc(e,t=Wc){return{type:17,loc:t,elements:e}}function Gc(e,t=Wc){return{type:15,loc:t,properties:e}}function qc(e,t){return{type:16,loc:Wc,key:v(e)?Jc(e,!0):e,value:t}}function Jc(e,t=!1,n=Wc,o=0){return{type:4,loc:n,content:e,isStatic:t,constType:t?3:o}}function Zc(e,t=Wc){return{type:8,loc:t,children:e}}function Yc(e,t=[],n=Wc){return{type:14,loc:n,callee:e,arguments:t}}function Qc(e,t=void 0,n=!1,o=!1,r=Wc){return{type:18,params:e,returns:t,newline:n,isSlot:o,loc:r}}function Xc(e,t,n,o=!0){return{type:19,test:e,consequent:t,alternate:n,newline:o,loc:Wc}}function ea(e,t){return e||t?fc:dc}function ta(e,t){return e||t?uc:pc}function na(e,{helper:t,removeHelper:n,inSSR:o}){e.isBlock||(e.isBlock=!0,n(ea(o,e.isComponent)),t(ac),t(ta(o,e.isComponent)))}const oa=e=>4===e.type&&e.isStatic,ra=(e,t)=>e===t||e===R(t);function sa(e){return ra(e,"Teleport")?sc:ra(e,"Suspense")?ic:ra(e,"KeepAlive")?lc:ra(e,"BaseTransition")?cc:void 0}const ia=/^\d|[^\$\w]/,la=e=>!ia.test(e),ca=/[A-Za-z_$\xA0-\uFFFF]/,aa=/[\.\?\w$\xA0-\uFFFF]/,ua=/\s+[.[]\s*|\s*[.[]\s+/g,pa=e=>{e=e.trim().replace(ua,(e=>e.trim()));let t=0,n=[],o=0,r=0,s=null;for(let i=0;i4===e.key.type&&e.key.content===o))}return n}function Ta(e,t){return`_${t}_${e.replace(/[^\w]/g,((t,n)=>"-"===t?"_":e.charCodeAt(n).toString()))}`}const Ea=/&(gt|lt|amp|apos|quot);/g,Na={gt:">",lt:"<",amp:"&",apos:"'",quot:'"'},Oa={delimiters:["{{","}}"],getNamespace:()=>0,getTextMode:()=>0,isVoidTag:r,isPreTag:r,isCustomElement:r,decodeEntities:e=>e.replace(Ea,((e,t)=>Na[t])),onError:tc,onWarn:nc,comments:!1};function $a(e,t={}){const n=function(e,t){const n=c({},Oa);let o;for(o in t)n[o]=void 0===t[o]?Oa[o]:t[o];return{options:n,column:1,line:1,offset:0,originalSource:e,source:e,inPre:!1,inVPre:!1,onWarn:n.onWarn}}(e,t),o=Wa(n);return function(e,t=Wc){return{type:0,children:e,helpers:new Set,components:[],directives:[],hoists:[],imports:[],cached:0,temps:0,codegenNode:void 0,loc:t}}(Pa(n,0,[]),za(n,o))}function Pa(e,t,n){const o=Ka(n),r=o?o.ns:0,s=[];for(;!Qa(e,t,n);){const i=e.source;let l;if(0===t||1===t)if(!e.inVPre&&Ga(i,e.options.delimiters[0]))l=Ua(e,t);else if(0===t&&"<"===i[0])if(1===i.length);else if("!"===i[1])l=Ga(i,"\x3c!--")?Fa(e):Ga(i,""===i[2]){qa(e,3);continue}if(/[a-z]/i.test(i[2])){Ba(e,1,o);continue}Ya(e,12,2),l=Ma(e)}else/[a-z]/i.test(i[1])?l=Va(e,n):"?"===i[1]&&(Ya(e,21,1),l=Ma(e));if(l||(l=Da(e,t)),f(l))for(let e=0;e/.exec(e.source);if(o){n=e.source.slice(4,o.index);const t=e.source.slice(0,o.index);let r=1,s=0;for(;-1!==(s=t.indexOf("\x3c!--",r));)qa(e,s-r+1),r=s+1;qa(e,o.index+o[0].length-r+1)}else n=e.source.slice(4),qa(e,e.source.length);return{type:3,content:n,loc:za(e,t)}}function Ma(e){const t=Wa(e),n="?"===e.source[1]?1:2;let o;const r=e.source.indexOf(">");return-1===r?(o=e.source.slice(n),qa(e,e.source.length)):(o=e.source.slice(n,r),qa(e,r+1)),{type:3,content:o,loc:za(e,t)}}function Va(e,t){const n=e.inPre,o=e.inVPre,r=Ka(t),s=Ba(e,0,r),i=e.inPre&&!n,l=e.inVPre&&!o;if(s.isSelfClosing||e.options.isVoidTag(s.tag))return i&&(e.inPre=!1),l&&(e.inVPre=!1),s;t.push(s);const c=e.options.getTextMode(s,r),a=Pa(e,c,t);if(t.pop(),s.children=a,Xa(e.source,s.tag))Ba(e,1,r);else if(0===e.source.length&&"script"===s.tag.toLowerCase()){const e=a[0];e&&Ga(e.loc.source,"\x3c!--")}return s.loc=za(e,s.loc.start),i&&(e.inPre=!1),l&&(e.inVPre=!1),s}const Ia=e("if,else,else-if,for,slot");function Ba(e,t,n){const o=Wa(e),r=/^<\/?([a-z][^\t\r\n\f />]*)/i.exec(e.source),s=r[1],i=e.options.getNamespace(s,n);qa(e,r[0].length),Ja(e);const l=Wa(e),a=e.source;e.options.isPreTag(s)&&(e.inPre=!0);let u=La(e,t);0===t&&!e.inVPre&&u.some((e=>7===e.type&&"pre"===e.name))&&(e.inVPre=!0,c(e,l),e.source=a,u=La(e,t).filter((e=>"v-pre"!==e.name)));let p=!1;if(0===e.source.length||(p=Ga(e.source,"/>"),qa(e,p?2:1)),1===t)return;let f=0;return e.inVPre||("slot"===s?f=2:"template"===s?u.some((e=>7===e.type&&Ia(e.name)))&&(f=3):function(e,t,n){const o=n.options;if(o.isCustomElement(e))return!1;if("component"===e||/^[A-Z]/.test(e)||sa(e)||o.isBuiltInComponent&&o.isBuiltInComponent(e)||o.isNativeTag&&!o.isNativeTag(e))return!0;for(let r=0;r0&&!Ga(e.source,">")&&!Ga(e.source,"/>");){if(Ga(e.source,"/")){qa(e,1),Ja(e);continue}const r=ja(e,o);6===r.type&&r.value&&"class"===r.name&&(r.value.content=r.value.content.replace(/\s+/g," ").trim()),0===t&&n.push(r),/^[^\t\r\n\f />]/.test(e.source),Ja(e)}return n}function ja(e,t){var n;const o=Wa(e),r=/^[^\t\r\n\f />][^\t\r\n\f />=]*/.exec(e.source)[0];t.has(r),t.add(r);{const t=/["'<]/g;let n;for(;n=t.exec(r);)Ya(e,17,n.index)}let s;qa(e,r.length),/^[\t\r\n\f ]*=/.test(e.source)&&(Ja(e),qa(e,1),Ja(e),s=function(e){const t=Wa(e);let n;const o=e.source[0],r='"'===o||"'"===o;if(r){qa(e,1);const t=e.source.indexOf(o);-1===t?n=Ha(e,e.source.length,4):(n=Ha(e,t,4),qa(e,1))}else{const t=/^[^\t\r\n\f >]+/.exec(e.source);if(!t)return;const o=/["'<=`]/g;let r;for(;r=o.exec(t[0]);)Ya(e,18,r.index);n=Ha(e,t[0].length,4)}return{content:n,isQuoted:r,loc:za(e,t)}}(e));const i=za(e,o);if(!e.inVPre&&/^(v-[A-Za-z0-9-]|:|\.|@|#)/.test(r)){const t=/(?:^v-([a-z0-9-]+))?(?:(?::|^\.|^@|^#)(\[[^\]]+\]|[^\.]+))?(.+)?$/i.exec(r);let l,c=Ga(r,"."),a=t[1]||(c||Ga(r,":")?"bind":Ga(r,"@")?"on":"slot");if(t[2]){const s="slot"===a,i=r.lastIndexOf(t[2],r.length-((null==(n=t[3])?void 0:n.length)||0)),c=za(e,Za(e,o,i),Za(e,o,i+t[2].length+(s&&t[3]||"").length));let u=t[2],p=!0;u.startsWith("[")?(p=!1,u.endsWith("]")?u=u.slice(1,u.length-1):(Ya(e,27),u=u.slice(1))):s&&(u+=t[3]||""),l={type:4,content:u,isStatic:p,constType:p?3:0,loc:c}}if(s&&s.isQuoted){const e=s.loc;e.start.offset++,e.start.column++,e.end=da(e.start,s.content),e.source=e.source.slice(1,-1)}const u=t[3]?t[3].slice(1).split("."):[];return c&&u.push("prop"),{type:7,name:a,exp:s&&{type:4,content:s.content,isStatic:!1,constType:0,loc:s.loc},arg:l,modifiers:u,loc:i}}return!e.inVPre&&Ga(r,"v-"),{type:6,name:r,value:s&&{type:2,content:s.content,loc:s.loc},loc:i}}function Ua(e,t){const[n,o]=e.options.delimiters,r=e.source.indexOf(o,n.length);if(-1===r)return;const s=Wa(e);qa(e,n.length);const i=Wa(e),l=Wa(e),c=r-n.length,a=e.source.slice(0,c),u=Ha(e,c,t),p=u.trim(),f=u.indexOf(p);f>0&&ha(i,a,f);return ha(l,a,c-(u.length-p.length-f)),qa(e,o.length),{type:5,content:{type:4,isStatic:!1,constType:0,content:p,loc:za(e,i,l)},loc:za(e,s)}}function Da(e,t){const n=3===t?["]]>"]:["<",e.options.delimiters[0]];let o=e.source.length;for(let s=0;st&&(o=t)}const r=Wa(e);return{type:2,content:Ha(e,o,t),loc:za(e,r)}}function Ha(e,t,n){const o=e.source.slice(0,t);return qa(e,t),2!==n&&3!==n&&o.includes("&")?e.options.decodeEntities(o,4===n):o}function Wa(e){const{column:t,line:n,offset:o}=e;return{column:t,line:n,offset:o}}function za(e,t,n){return{start:t,end:n=n||Wa(e),source:e.originalSource.slice(t.offset,n.offset)}}function Ka(e){return e[e.length-1]}function Ga(e,t){return e.startsWith(t)}function qa(e,t){const{source:n}=e;ha(e,n,t),e.source=n.slice(t)}function Ja(e){const t=/^[\t\r\n\f ]+/.exec(e.source);t&&qa(e,t[0].length)}function Za(e,t,n){return da(t,e.originalSource.slice(t.offset,n),n)}function Ya(e,t,n,o=Wa(e)){n&&(o.offset+=n,o.column+=n),e.options.onError(oc(t,{start:o,end:o,source:""}))}function Qa(e,t,n){const o=e.source;switch(t){case 0:if(Ga(o,"=0;--e)if(Xa(o,n[e].tag))return!0;break;case 1:case 2:{const e=Ka(n);if(e&&Xa(o,e.tag))return!0;break}case 3:if(Ga(o,"]]>"))return!0}return!o}function Xa(e,t){return Ga(e,"]/.test(e[2+t.length]||">")}function eu(e,t){nu(e,t,tu(e,e.children[0]))}function tu(e,t){const{children:n}=e;return 1===n.length&&1===t.type&&!Sa(t)}function nu(e,t,n=!1){const{children:o}=e,r=o.length;let s=0;for(let i=0;i0){if(o>=2){e.codegenNode.patchFlag="-1",e.codegenNode=t.hoist(e.codegenNode),s++;continue}}else{const n=e.codegenNode;if(13===n.type){const o=cu(n);if((!o||512===o||1===o)&&iu(e,t)>=2){const o=lu(e);o&&(n.props=t.hoist(o))}n.dynamicProps&&(n.dynamicProps=t.hoist(n.dynamicProps))}}}if(1===e.type){const n=1===e.tagType;n&&t.scopes.vSlot++,nu(e,t),n&&t.scopes.vSlot--}else if(11===e.type)nu(e,t,1===e.children.length);else if(9===e.type)for(let n=0;n1)for(let r=0;r`_${Hc[E.helper(e)]}`,replaceNode(e){E.parent.children[E.childIndex]=E.currentNode=e},removeNode(e){const t=e?E.parent.children.indexOf(e):E.currentNode?E.childIndex:-1;e&&e!==E.currentNode?E.childIndex>t&&(E.childIndex--,E.onNodeRemoved()):(E.currentNode=null,E.onNodeRemoved()),E.parent.children.splice(t,1)},onNodeRemoved:()=>{},addIdentifiers(e){},removeIdentifiers(e){},hoist(e){v(e)&&(e=Jc(e)),E.hoists.push(e);const t=Jc(`_hoisted_${E.hoists.length}`,!1,e.loc,2);return t.hoisted=e,t},cache:(e,t=!1)=>function(e,t,n=!1){return{type:20,index:e,value:t,isVNode:n,loc:Wc}}(E.cached++,e,t)};return E}function uu(e,t){const n=au(e,t);pu(e,n),t.hoistStatic&&eu(e,n),t.ssr||function(e,t){const{helper:n}=t,{children:o}=e;if(1===o.length){const n=o[0];if(tu(e,n)&&n.codegenNode){const o=n.codegenNode;13===o.type&&na(o,t),e.codegenNode=o}else e.codegenNode=n}else if(o.length>1){let o=64;e.codegenNode=zc(t,n(rc),void 0,e.children,o+"",void 0,void 0,!0,void 0,!1)}}(e,n),e.helpers=new Set([...n.helpers.keys()]),e.components=[...n.components],e.directives=[...n.directives],e.imports=n.imports,e.hoists=n.hoists,e.temps=n.temps,e.cached=n.cached}function pu(e,t){t.currentNode=e;const{nodeTransforms:n}=t,o=[];for(let s=0;s{n--};for(;nt===e:t=>e.test(t);return(e,o)=>{if(1===e.type){const{props:r}=e;if(3===e.tagType&&r.some(ba))return;const s=[];for(let i=0;i`${Hc[e]}: _${Hc[e]}`;function mu(e,{mode:t="function",prefixIdentifiers:n="module"===t,sourceMap:o=!1,filename:r="template.vue.html",scopeId:s=null,optimizeImports:i=!1,runtimeGlobalName:l="Vue",runtimeModuleName:c="vue",ssrRuntimeModuleName:a="vue/server-renderer",ssr:u=!1,isTS:p=!1,inSSR:f=!1}){const d={mode:t,prefixIdentifiers:n,sourceMap:o,filename:r,scopeId:s,optimizeImports:i,runtimeGlobalName:l,runtimeModuleName:c,ssrRuntimeModuleName:a,ssr:u,isTS:p,inSSR:f,source:e.loc.source,code:"",column:1,line:1,offset:0,indentLevel:0,pure:!1,map:void 0,helper:e=>`_${Hc[e]}`,push(e,t){d.code+=e},indent(){h(++d.indentLevel)},deindent(e=!1){e?--d.indentLevel:h(--d.indentLevel)},newline(){h(d.indentLevel)}};function h(e){d.push("\n"+" ".repeat(e))}return d}function gu(e,t={}){const n=mu(e,t);t.onContextCreated&&t.onContextCreated(n);const{mode:o,push:r,prefixIdentifiers:s,indent:i,deindent:l,newline:c,ssr:a}=n,u=Array.from(e.helpers),p=u.length>0,f=!s&&"module"!==o,d=n;!function(e,t){const{push:n,newline:o,runtimeGlobalName:r}=t,s=r,i=Array.from(e.helpers);if(i.length>0&&(n(`const _Vue = ${s}\n`),e.hoists.length)){n(`const { ${[fc,dc,hc,mc,gc].filter((e=>i.includes(e))).map(hu).join(", ")} } = _Vue\n`)}(function(e,t){if(!e.length)return;t.pure=!0;const{push:n,newline:o}=t;o();for(let r=0;r0)&&c()),e.directives.length&&(vu(e.directives,"directive",n),e.temps>0&&c()),e.temps>0){r("let ");for(let t=0;t0?", ":""}_temp${t}`)}return(e.components.length||e.directives.length||e.temps)&&(r("\n"),c()),a||r("return "),e.codegenNode?_u(e.codegenNode,n):r("null"),f&&(l(),r("}")),l(),r("}"),{ast:e,code:n.code,preamble:"",map:n.map?n.map.toJSON():void 0}}function vu(e,t,{helper:n,push:o,newline:r,isTS:s}){const i=n("component"===t?vc:bc);for(let l=0;l3||!1;t.push("["),n&&t.indent(),bu(e,t,n),n&&t.deindent(),t.push("]")}function bu(e,t,n=!1,o=!0){const{push:r,newline:s}=t;for(let i=0;ie||"null"))}([s,i,l,c,a]),t),n(")"),p&&n(")");u&&(n(", "),_u(u,t),n(")"))}(e,t);break;case 14:!function(e,t){const{push:n,helper:o,pure:r}=t,s=v(e.callee)?e.callee:o(e.callee);r&&n(du);n(s+"(",e),bu(e.arguments,t),n(")")}(e,t);break;case 15:!function(e,t){const{push:n,indent:o,deindent:r,newline:s}=t,{properties:i}=e;if(!i.length)return void n("{}",e);const l=i.length>1||!1;n(l?"{":"{ "),l&&o();for(let c=0;c "),(c||l)&&(n("{"),o());i?(c&&n("return "),f(i)?yu(i,t):_u(i,t)):l&&_u(l,t);(c||l)&&(r(),n("}"));a&&n(")")}(e,t);break;case 19:!function(e,t){const{test:n,consequent:o,alternate:r,newline:s}=e,{push:i,indent:l,deindent:c,newline:a}=t;if(4===n.type){const e=!la(n.content);e&&i("("),Su(n,t),e&&i(")")}else i("("),_u(n,t),i(")");s&&l(),t.indentLevel++,s||i(" "),i("? "),_u(o,t),t.indentLevel--,s&&a(),s||i(" "),i(": ");const u=19===r.type;u||t.indentLevel++;_u(r,t),u||t.indentLevel--;s&&c(!0)}(e,t);break;case 20:!function(e,t){const{push:n,helper:o,indent:r,deindent:s,newline:i}=t;n(`_cache[${e.index}] || (`),e.isVNode&&(r(),n(`${o(Mc)}(-1),`),i());n(`_cache[${e.index}] = `),_u(e.value,t),e.isVNode&&(n(","),i(),n(`${o(Mc)}(1),`),i(),n(`_cache[${e.index}]`),s());n(")")}(e,t);break;case 21:bu(e.body,t,!0,!1)}}function Su(e,t){const{content:n,isStatic:o}=e;t.push(o?JSON.stringify(n):n,e)}function xu(e,t){for(let n=0;nfunction(e,t,n,o){if(!("else"===t.name||t.exp&&t.exp.content.trim())){const o=t.exp?t.exp.loc:e.loc;n.onError(oc(28,t.loc)),t.exp=Jc("true",!1,o)}if("if"===t.name){const r=ku(e,t),s={type:9,loc:e.loc,branches:[r]};if(n.replaceNode(s),o)return o(s,r,!0)}else{const r=n.parent.children;let s=r.indexOf(e);for(;s-- >=-1;){const i=r[s];if(i&&3===i.type)n.removeNode(i);else{if(!i||2!==i.type||i.content.trim().length){if(i&&9===i.type){"else-if"===t.name&&void 0===i.branches[i.branches.length-1].condition&&n.onError(oc(30,e.loc)),n.removeNode();const r=ku(e,t);i.branches.push(r);const s=o&&o(i,r,!1);pu(r,n),s&&s(),n.currentNode=null}else n.onError(oc(30,e.loc));break}n.removeNode(i)}}}}(e,t,n,((e,t,o)=>{const r=n.parent.children;let s=r.indexOf(e),i=0;for(;s-- >=0;){const e=r[s];e&&9===e.type&&(i+=e.branches.length)}return()=>{if(o)e.codegenNode=Tu(t,i,n);else{const o=function(e){for(;;)if(19===e.type){if(19!==e.alternate.type)return e;e=e.alternate}else 20===e.type&&(e=e.value)}(e.codegenNode);o.alternate=Tu(t,i+e.branches.length-1,n)}}}))));function ku(e,t){const n=3===e.tagType;return{type:10,loc:e.loc,condition:"else"===t.name?void 0:t.exp,children:n&&!ma(e,"for")?e.children:[e],userKey:ga(e,"key"),isTemplateIf:n}}function Tu(e,t,n){return e.condition?Xc(e.condition,Eu(e,t,n),Yc(n.helper(hc),['""',"true"])):Eu(e,t,n)}function Eu(e,t,n){const{helper:o}=n,r=qc("key",Jc(`${t}`,!1,Wc,2)),{children:s}=e,i=s[0];if(1!==s.length||1!==i.type){if(1===s.length&&11===i.type){const e=i.codegenNode;return wa(e,r,n),e}{let t=64;return zc(n,o(rc),Gc([r]),s,t+"",void 0,void 0,!0,!1,!1,e.loc)}}{const e=i.codegenNode,t=14===(l=e).type&&l.callee===Uc?l.arguments[1].returns:l;return 13===t.type&&na(t,n),wa(t,r,n),e}var l}const Nu=fu("for",((e,t,n)=>{const{helper:o,removeHelper:r}=n;return function(e,t,n,o){if(!t.exp)return void n.onError(oc(31,t.loc));const r=Ru(t.exp);if(!r)return void n.onError(oc(32,t.loc));const{scopes:s}=n,{source:i,value:l,key:c,index:a}=r,u={type:11,loc:t.loc,source:i,valueAlias:l,keyAlias:c,objectIndexAlias:a,parseResult:r,children:_a(e)?e.children:[e]};n.replaceNode(u),s.vFor++;const p=o&&o(u);return()=>{s.vFor--,p&&p()}}(e,t,n,(t=>{const s=Yc(o(xc),[t.source]),i=_a(e),l=ma(e,"memo"),c=ga(e,"key"),a=c&&(6===c.type?Jc(c.value.content,!0):c.exp),u=c?qc("key",a):null,p=4===t.source.type&&t.source.constType>0,f=p?64:c?128:256;return t.codegenNode=zc(n,o(rc),void 0,s,f+"",void 0,void 0,!0,!p,!1,e.loc),()=>{let c;const{children:f}=t,d=1!==f.length||1!==f[0].type,h=Sa(e)?e:i&&1===e.children.length&&Sa(e.children[0])?e.children[0]:null;if(h?(c=h.codegenNode,i&&u&&wa(c,u,n)):d?c=zc(n,o(rc),u?Gc([u]):void 0,e.children,"64",void 0,void 0,!0,void 0,!1):(c=f[0].codegenNode,i&&u&&wa(c,u,n),c.isBlock!==!p&&(c.isBlock?(r(ac),r(ta(n.inSSR,c.isComponent))):r(ea(n.inSSR,c.isComponent))),c.isBlock=!p,c.isBlock?(o(ac),o(ta(n.inSSR,c.isComponent))):o(ea(n.inSSR,c.isComponent))),l){const e=Qc(Fu(t.parseResult,[Jc("_cached")]));e.body={type:21,body:[Zc(["const _memo = (",l.exp,")"]),Zc(["if (_cached",...a?[" && _cached.key === ",a]:[],` && ${n.helperString(Dc)}(_cached, _memo)) return _cached`]),Zc(["const _item = ",c]),Jc("_item.memo = _memo"),Jc("return _item")],loc:Wc},s.arguments.push(e,Jc("_cache"),Jc(String(n.cached++)))}else s.arguments.push(Qc(Fu(t.parseResult),c,!0))}}))}));const Ou=/([\s\S]*?)\s+(?:in|of)\s+([\s\S]*)/,$u=/,([^,\}\]]*)(?:,([^,\}\]]*))?$/,Pu=/^\(|\)$/g;function Ru(e,t){const n=e.loc,o=e.content,r=o.match(Ou);if(!r)return;const[,s,i]=r,l={source:Au(n,i.trim(),o.indexOf(i,s.length)),value:void 0,key:void 0,index:void 0};let c=s.trim().replace(Pu,"").trim();const a=s.indexOf(c),u=c.match($u);if(u){c=c.replace($u,"").trim();const e=u[1].trim();let t;if(e&&(t=o.indexOf(e,a+c.length),l.key=Au(n,e,t)),u[2]){const r=u[2].trim();r&&(l.index=Au(n,r,o.indexOf(r,l.key?t+e.length:a+c.length)))}}return c&&(l.value=Au(n,c,a)),l}function Au(e,t,n){return Jc(t,!1,fa(e,n,t.length))}function Fu({value:e,key:t,index:n},o=[]){return function(e){let t=e.length;for(;t--&&!e[t];);return e.slice(0,t+1).map(((e,t)=>e||Jc("_".repeat(t+1),!1)))}([e,t,n,...o])}const Mu=Jc("undefined",!1),Vu=(e,t)=>{if(1===e.type&&(1===e.tagType||3===e.tagType)){const n=ma(e,"slot");if(n)return t.scopes.vSlot++,()=>{t.scopes.vSlot--}}},Iu=(e,t,n,o)=>Qc(e,n,!1,!0,n.length?n[0].loc:o);function Bu(e,t,n=Iu){t.helper(Bc);const{children:o,loc:r}=e,s=[],i=[];let l=t.scopes.vSlot>0||t.scopes.vFor>0;const c=ma(e,"slot",!0);if(c){const{arg:e,exp:t}=c;e&&!oa(e)&&(l=!0),s.push(qc(e||Jc("default",!0),n(t,void 0,o,r)))}let a=!1,u=!1;const p=[],f=new Set;let d=0;for(let g=0;gqc("default",n(e,void 0,t,r));a?p.length&&p.some((e=>Uu(e)))&&(u?t.onError(oc(39,p[0].loc)):s.push(e(void 0,p))):s.push(e(void 0,o))}const h=l?2:ju(e.children)?3:1;let m=Gc(s.concat(qc("_",Jc(h+"",!1))),r);return i.length&&(m=Yc(t.helper(wc),[m,Kc(i)])),{slots:m,hasDynamicSlots:l}}function Lu(e,t,n){const o=[qc("name",e),qc("fn",t)];return null!=n&&o.push(qc("key",Jc(String(n),!0))),Gc(o)}function ju(e){for(let t=0;tfunction(){if(1!==(e=t.currentNode).type||0!==e.tagType&&1!==e.tagType)return;const{tag:n,props:o}=e,r=1===e.tagType;let s=r?function(e,t,n=!1){let{tag:o}=e;const r=Gu(o),s=ga(e,"is");if(s)if(r){const e=6===s.type?s.value&&Jc(s.value.content,!0):s.exp;if(e)return Yc(t.helper(yc),[e])}else 6===s.type&&s.value.content.startsWith("vue:")&&(o=s.value.content.slice(4));const i=!r&&ma(e,"is");if(i&&i.exp)return Yc(t.helper(yc),[i.exp]);const l=sa(o)||t.isBuiltInComponent(o);if(l)return n||t.helper(l),l;return t.helper(vc),t.components.add(o),Ta(o,"component")}(e,t):`"${n}"`;const i=b(s)&&s.callee===yc;let l,c,a,u,p,f,d=0,h=i||s===sc||s===ic||!r&&("svg"===n||"foreignObject"===n);if(o.length>0){const n=Wu(e,t,void 0,r,i);l=n.props,d=n.patchFlag,p=n.dynamicPropNames;const o=n.directives;f=o&&o.length?Kc(o.map((e=>function(e,t){const n=[],o=Du.get(e);o?n.push(t.helperString(o)):(t.helper(bc),t.directives.add(e.name),n.push(Ta(e.name,"directive")));const{loc:r}=e;e.exp&&n.push(e.exp);e.arg&&(e.exp||n.push("void 0"),n.push(e.arg));if(Object.keys(e.modifiers).length){e.arg||(e.exp||n.push("void 0"),n.push("void 0"));const t=Jc("true",!1,r);n.push(Gc(e.modifiers.map((e=>qc(e,t))),r))}return Kc(n,e.loc)}(e,t)))):void 0,n.shouldUseBlock&&(h=!0)}if(e.children.length>0){s===lc&&(h=!0,d|=1024);if(r&&s!==sc&&s!==lc){const{slots:n,hasDynamicSlots:o}=Bu(e,t);c=n,o&&(d|=1024)}else if(1===e.children.length&&s!==sc){const n=e.children[0],o=n.type,r=5===o||8===o;r&&0===ou(n,t)&&(d|=1),c=r||2===o?n:e.children}else c=e.children}0!==d&&(a=String(d),p&&p.length&&(u=function(e){let t="[";for(let n=0,o=e.length;n0;let h=!1,m=0,g=!1,v=!1,b=!1,_=!1,S=!1,x=!1;const C=[],w=e=>{u.length&&(p.push(Gc(zu(u),c)),u=[]),e&&p.push(e)},k=({key:e,value:n})=>{if(oa(e)){const s=e.content,l=i(s);if(!l||o&&!r||"onclick"===s.toLowerCase()||"onUpdate:modelValue"===s||T(s)||(_=!0),l&&T(s)&&(x=!0),20===n.type||(4===n.type||8===n.type)&&ou(n,t)>0)return;"ref"===s?g=!0:"class"===s?v=!0:"style"===s?b=!0:"key"===s||C.includes(s)||C.push(s),!o||"class"!==s&&"style"!==s||C.includes(s)||C.push(s)}else S=!0};for(let i=0;i0&&u.push(qc(Jc("ref_for",!0),Jc("true")))),"is"===n&&(Gu(l)||o&&o.content.startsWith("vue:")))continue;u.push(qc(Jc(n,!0,fa(e,0,n.length)),Jc(o?o.content:"",s,o?o.loc:e)))}else{const{name:n,arg:i,exp:a,loc:m}=r,g="bind"===n,v="on"===n;if("slot"===n){o||t.onError(oc(40,m));continue}if("once"===n||"memo"===n)continue;if("is"===n||g&&va(i,"is")&&Gu(l))continue;if(v&&s)continue;if((g&&va(i,"key")||v&&d&&va(i,"vue:before-update"))&&(h=!0),g&&va(i,"ref")&&t.scopes.vFor>0&&u.push(qc(Jc("ref_for",!0),Jc("true"))),!i&&(g||v)){S=!0,a?g?(w(),p.push(a)):w({type:14,loc:m,callee:t.helper(Pc),arguments:o?[a]:[a,"true"]}):t.onError(oc(g?34:35,m));continue}const b=t.directiveTransforms[n];if(b){const{props:n,needRuntime:o}=b(r,e,t);!s&&n.forEach(k),v&&i&&!oa(i)?w(Gc(n,c)):u.push(...n),o&&(f.push(r),y(o)&&Du.set(r,o))}else E(n)||(f.push(r),d&&(h=!0))}}let N;if(p.length?(w(),N=p.length>1?Yc(t.helper(Tc),p,c):p[0]):u.length&&(N=Gc(zu(u),c)),S?m|=16:(v&&!o&&(m|=2),b&&!o&&(m|=4),C.length&&(m|=8),_&&(m|=32)),h||0!==m&&32!==m||!(g||x||f.length>0)||(m|=512),!t.inSSR&&N)switch(N.type){case 15:let e=-1,n=-1,o=!1;for(let t=0;t{if(Sa(e)){const{children:n,loc:o}=e,{slotName:r,slotProps:s}=function(e,t){let n,o='"default"';const r=[];for(let s=0;s0){const{props:o,directives:s}=Wu(e,t,r,!1,!1);n=o,s.length&&t.onError(oc(36,s[0].loc))}return{slotName:o,slotProps:n}}(e,t),i=[t.prefixIdentifiers?"_ctx.$slots":"$slots",r,"{}","undefined","true"];let l=2;s&&(i[2]=s,l=3),n.length&&(i[3]=Qc([],n,!1,!1,o),l=4),t.scopeId&&!t.slotted&&(l=5),i.splice(l),e.codegenNode=Yc(t.helper(Cc),i,o)}};const Ju=/^\s*([\w$_]+|(async\s*)?\([^)]*?\))\s*(:[^=]+)?=>|^\s*(async\s+)?function(?:\s+[\w$]+)?\s*\(/,Zu=(e,t,n,o)=>{const{loc:r,modifiers:s,arg:i}=e;let l;if(4===i.type)if(i.isStatic){let e=i.content;e.startsWith("vue:")&&(e=`vnode-${e.slice(4)}`);l=Jc(0!==t.tagType||e.startsWith("vnode")||!/[A-Z]/.test(e)?F($(e)):`on:${e}`,!0,i.loc)}else l=Zc([`${n.helperString(Fc)}(`,i,")"]);else l=i,l.children.unshift(`${n.helperString(Fc)}(`),l.children.push(")");let c=e.exp;c&&!c.content.trim()&&(c=void 0);let a=n.cacheHandlers&&!c&&!n.inVOnce;if(c){const e=pa(c.content),t=!(e||Ju.test(c.content)),n=c.content.includes(";");(t||a&&e)&&(c=Zc([`${t?"$event":"(...args)"} => ${n?"{":"("}`,c,n?"}":")"]))}let u={props:[qc(l,c||Jc("() => {}",!1,r))]};return o&&(u=o(u)),a&&(u.props[0].value=n.cache(u.props[0].value)),u.props.forEach((e=>e.key.isHandlerKey=!0)),u},Yu=(e,t,n)=>{const{exp:o,modifiers:r,loc:s}=e,i=e.arg;return 4!==i.type?(i.children.unshift("("),i.children.push(') || ""')):i.isStatic||(i.content=`${i.content} || ""`),r.includes("camel")&&(4===i.type?i.content=i.isStatic?$(i.content):`${n.helperString(Rc)}(${i.content})`:(i.children.unshift(`${n.helperString(Rc)}(`),i.children.push(")"))),n.inSSR||(r.includes("prop")&&Qu(i,"."),r.includes("attr")&&Qu(i,"^")),!o||4===o.type&&!o.content.trim()?{props:[qc(i,Jc("",!0,s))]}:{props:[qc(i,o)]}},Qu=(e,t)=>{4===e.type?e.content=e.isStatic?t+e.content:`\`${t}\${${e.content}}\``:(e.children.unshift(`'${t}' + (`),e.children.push(")"))},Xu=(e,t)=>{if(0===e.type||1===e.type||11===e.type||10===e.type)return()=>{const n=e.children;let o,r=!1;for(let e=0;e7===e.type&&!t.directiveTransforms[e.name])))))for(let e=0;e{if(1===e.type&&ma(e,"once",!0)){if(ep.has(e)||t.inVOnce||t.inSSR)return;return ep.add(e),t.inVOnce=!0,t.helper(Mc),()=>{t.inVOnce=!1;const e=t.currentNode;e.codegenNode&&(e.codegenNode=t.cache(e.codegenNode,!0))}}},np=(e,t,n)=>{const{exp:o,arg:r}=e;if(!o)return n.onError(oc(41,e.loc)),op();const s=o.loc.source,i=4===o.type?o.content:s,l=n.bindingMetadata[s];if("props"===l||"props-aliased"===l)return op();if(!i.trim()||!pa(i))return n.onError(oc(42,o.loc)),op();const c=r||Jc("modelValue",!0),a=r?oa(r)?`onUpdate:${$(r.content)}`:Zc(['"onUpdate:" + ',r]):"onUpdate:modelValue";let u;u=Zc([`${n.isTS?"($event: any)":"$event"} => ((`,o,") = $event)"]);const p=[qc(c,e.exp),qc(a,u)];if(e.modifiers.length&&1===t.tagType){const t=e.modifiers.map((e=>(la(e)?e:JSON.stringify(e))+": true")).join(", "),n=r?oa(r)?`${r.content}Modifiers`:Zc([r,' + "Modifiers"']):"modelModifiers";p.push(qc(n,Jc(`{ ${t} }`,!1,e.loc,2)))}return op(p)};function op(e=[]){return{props:e}}const rp=new WeakSet,sp=(e,t)=>{if(1===e.type){const n=ma(e,"memo");if(!n||rp.has(e))return;return rp.add(e),()=>{const o=e.codegenNode||t.currentNode.codegenNode;o&&13===o.type&&(1!==e.tagType&&na(o,t),e.codegenNode=Yc(t.helper(Uc),[n.exp,Qc(void 0,o),"_cache",String(t.cached++)]))}}};function ip(e,t={}){const n=t.onError||tc,o="module"===t.mode;!0===t.prefixIdentifiers?n(oc(47)):o&&n(oc(48));t.cacheHandlers&&n(oc(49)),t.scopeId&&!o&&n(oc(50));const r=v(e)?$a(e,t):e,[s,i]=[[tp,wu,sp,Nu,qu,Hu,Vu,Xu],{on:Zu,bind:Yu,model:np}];return uu(r,c({},t,{prefixIdentifiers:false,nodeTransforms:[...s,...t.nodeTransforms||[]],directiveTransforms:c({},i,t.directiveTransforms||{})})),gu(r,c({},t,{prefixIdentifiers:false}))}const lp=Symbol(""),cp=Symbol(""),ap=Symbol(""),up=Symbol(""),pp=Symbol(""),fp=Symbol(""),dp=Symbol(""),hp=Symbol(""),mp=Symbol(""),gp=Symbol("");var vp;let yp;vp={[lp]:"vModelRadio",[cp]:"vModelCheckbox",[ap]:"vModelText",[up]:"vModelSelect",[pp]:"vModelDynamic",[fp]:"withModifiers",[dp]:"withKeys",[hp]:"vShow",[mp]:"Transition",[gp]:"TransitionGroup"},Object.getOwnPropertySymbols(vp).forEach((e=>{Hc[e]=vp[e]}));const bp=e("style,iframe,script,noscript",!0),_p={isVoidTag:Q,isNativeTag:e=>Z(e)||Y(e),isPreTag:e=>"pre"===e,decodeEntities:function(e,t=!1){return yp||(yp=document.createElement("div")),t?(yp.innerHTML=`
`,yp.children[0].getAttribute("foo")):(yp.innerHTML=e,yp.textContent)},isBuiltInComponent:e=>ra(e,"Transition")?mp:ra(e,"TransitionGroup")?gp:void 0,getNamespace(e,t){let n=t?t.ns:0;if(t&&2===n)if("annotation-xml"===t.tag){if("svg"===e)return 1;t.props.some((e=>6===e.type&&"encoding"===e.name&&null!=e.value&&("text/html"===e.value.content||"application/xhtml+xml"===e.value.content)))&&(n=0)}else/^m(?:[ions]|text)$/.test(t.tag)&&"mglyph"!==e&&"malignmark"!==e&&(n=0);else t&&1===n&&("foreignObject"!==t.tag&&"desc"!==t.tag&&"title"!==t.tag||(n=0));if(0===n){if("svg"===e)return 1;if("math"===e)return 2}return n},getTextMode({tag:e,ns:t}){if(0===t){if("textarea"===e||"title"===e)return 1;if(bp(e))return 2}return 0}},Sp=(e,t)=>{const n=G(e);return Jc(JSON.stringify(n),!1,t,3)};function xp(e,t){return oc(e,t)}const Cp=e("passive,once,capture"),wp=e("stop,prevent,self,ctrl,shift,alt,meta,exact,middle"),kp=e("left,right"),Tp=e("onkeyup,onkeydown,onkeypress",!0),Ep=(e,t)=>oa(e)&&"onclick"===e.content.toLowerCase()?Jc(t,!0):4!==e.type?Zc(["(",e,`) === "onClick" ? "${t}" : (`,e,")"]):e,Np=(e,t)=>{1!==e.type||0!==e.tagType||"script"!==e.tag&&"style"!==e.tag||t.removeNode()},Op=[e=>{1===e.type&&e.props.forEach(((t,n)=>{6===t.type&&"style"===t.name&&t.value&&(e.props[n]={type:7,name:"bind",arg:Jc("style",!0,t.loc),exp:Sp(t.value.content,t.loc),modifiers:[],loc:t.loc})}))}],$p={cloak:()=>({props:[]}),html:(e,t,n)=>{const{exp:o,loc:r}=e;return o||n.onError(xp(53,r)),t.children.length&&(n.onError(xp(54,r)),t.children.length=0),{props:[qc(Jc("innerHTML",!0,r),o||Jc("",!0))]}},text:(e,t,n)=>{const{exp:o,loc:r}=e;return o||n.onError(xp(55,r)),t.children.length&&(n.onError(xp(56,r)),t.children.length=0),{props:[qc(Jc("textContent",!0),o?ou(o,n)>0?o:Yc(n.helperString(kc),[o],r):Jc("",!0))]}},model:(e,t,n)=>{const o=np(e,t,n);if(!o.props.length||1===t.tagType)return o;e.arg&&n.onError(xp(58,e.arg.loc));const{tag:r}=t,s=n.isCustomElement(r);if("input"===r||"textarea"===r||"select"===r||s){let i=ap,l=!1;if("input"===r||s){const o=ga(t,"type");if(o){if(7===o.type)i=pp;else if(o.value)switch(o.value.content){case"radio":i=lp;break;case"checkbox":i=cp;break;case"file":l=!0,n.onError(xp(59,e.loc))}}else(function(e){return e.props.some((e=>!(7!==e.type||"bind"!==e.name||e.arg&&4===e.arg.type&&e.arg.isStatic)))})(t)&&(i=pp)}else"select"===r&&(i=up);l||(o.needRuntime=n.helper(i))}else n.onError(xp(57,e.loc));return o.props=o.props.filter((e=>!(4===e.key.type&&"modelValue"===e.key.content))),o},on:(e,t,n)=>Zu(e,t,n,(t=>{const{modifiers:o}=e;if(!o.length)return t;let{key:r,value:s}=t.props[0];const{keyModifiers:i,nonKeyModifiers:l,eventOptionModifiers:c}=((e,t,n,o)=>{const r=[],s=[],i=[];for(let l=0;l{const{exp:o,loc:r}=e;return o||n.onError(xp(61,r)),{props:[],needRuntime:n.helper(hp)}}};const Pp=Object.create(null);function Rp(e,t){if(!v(e)){if(!e.nodeType)return o;e=e.innerHTML}const n=e,r=Pp[n];if(r)return r;if("#"===e[0]){const t=document.querySelector(e);e=t?t.innerHTML:""}const s=c({hoistStatic:!0,onError:void 0,onWarn:o},t);s.isCustomElement||"undefined"==typeof customElements||(s.isCustomElement=e=>!!customElements.get(e));const{code:i}=function(e,t={}){return ip(e,c({},_p,t,{nodeTransforms:[Np,...Op,...t.nodeTransforms||[]],directiveTransforms:c({},$p,t.directiveTransforms||{}),transformHoist:null}))}(e,s),l=new Function("Vue",i)(ec);return l._rc=!0,Pp[n]=l}ii(Rp);export{co as BaseTransition,lo as BaseTransitionPropsValidators,bs as Comment,ie as EffectScope,vs as Fragment,So as KeepAlive,Se as ReactiveEffect,_s as Static,jn as Suspense,ms as Teleport,ys as Text,Oi as Transition,_l as TransitionGroup,ul as VueElement,Qt as assertNumber,en as callWithAsyncErrorHandling,Xt as callWithErrorHandling,$ as camelize,A as capitalize,Ls as cloneVNode,xi as compatUtils,Rp as compile,fi as computed,Zl as createApp,Os as createBlock,Ds as createCommentVNode,Ns as createElementBlock,Vs as createElementVNode,is as createHydrationRenderer,yr as createPropsRestProxy,ss as createRenderer,Yl as createSSRApp,Jo as createSlots,Us as createStaticVNode,js as createTextVNode,Is as createVNode,Wt as customRef,yo as defineAsyncComponent,go as defineComponent,ll as defineCustomElement,sr as defineEmits,ir as defineExpose,ar as defineModel,lr as defineOptions,rr as defineProps,cl as defineSSRCustomElement,cr as defineSlots,Sn as devtools,Ce as effect,le as effectScope,Ys as getCurrentInstance,ae as getCurrentScope,mo as getTransitionRawChildren,Bs as guardReactiveProps,di as h,tn as handleError,Br as hasInjectionContext,Jl as hydrate,gi as initCustomFormatter,Xl as initDirectivesForSSR,Ir as inject,yi as isMemoSame,Tt as isProxy,Ct as isReactive,wt as isReadonly,At as isRef,li as isRuntimeOnly,kt as isShallow,$s as isVNode,Nt as markRaw,gr as mergeDefaults,vr as mergeModels,Ks as mergeProps,fn as nextTick,q as normalizeClass,J as normalizeProps,H as normalizeStyle,Co as onActivated,Po as onBeforeMount,Mo as onBeforeUnmount,Ao as onBeforeUpdate,wo as onDeactivated,jo as onErrorCaptured,Ro as onMounted,Lo as onRenderTracked,Bo as onRenderTriggered,ue as onScopeDispose,Io as onServerPrefetch,Vo as onUnmounted,Fo as onUpdated,Cs as openBlock,Pn as popScopeId,Vr as provide,Dt as proxyRefs,$n as pushScopeId,mn as queuePostFlushCb,yt as reactive,_t as readonly,Ft as ref,ii as registerRuntimeCompiler,ql as render,qo as renderList,Zo as renderSlot,Do as resolveComponent,zo as resolveDirective,Wo as resolveDynamicComponent,Si as resolveFilter,uo as resolveTransitionHooks,Ts as setBlockTracking,Cn as setDevtoolsHook,ho as setTransitionHooks,bt as shallowReactive,St as shallowReadonly,Mt as shallowRef,hi as ssrContextKey,_i as ssrUtils,we as stop,oe as toDisplayString,F as toHandlerKey,Qo as toHandlers,Et as toRaw,qt as toRef,zt as toRefs,jt as toValue,Rs as transformVNodeArgs,Bt as triggerRef,Lt as unref,fr as useAttrs,pl as useCssModule,fl as useCssVars,dr as useModel,mi as useSSRContext,pr as useSlots,so as useTransitionState,Ol as vModelCheckbox,Vl as vModelDynamic,Pl as vModelRadio,Rl as vModelSelect,Nl as vModelText,Ki as vShow,bi as version,Yt as warn,Zn as watch,Kn as watchEffect,Gn as watchPostEffect,qn as watchSyncEffect,br as withAsyncContext,An as withCtx,ur as withDefaults,to as withDirectives,Dl as withKeys,vi as withMemo,jl as withModifiers,Rn as withScopeId}; +function Cl(e,t){const n=Ns(e);class s extends wl{constructor(e){super(n,e,t)}}return s.def=n,s} +/*! #__NO_SIDE_EFFECTS__ */const kl=e=>Cl(e,cc),Tl="undefined"!=typeof HTMLElement?HTMLElement:class{};class wl extends Tl{constructor(e,t={},n){super(),this._def=e,this._props=t,this._instance=null,this._connected=!1,this._resolved=!1,this._numberProps=null,this._ob=null,this.shadowRoot&&n?n(this._createVNode(),this.shadowRoot):(this.attachShadow({mode:"open"}),this._def.__asyncLoader||this._resolveProps(this._def))}connectedCallback(){this._connected=!0,this._instance||(this._resolved?this._update():this._resolveDef())}disconnectedCallback(){this._connected=!1,this._ob&&(this._ob.disconnect(),this._ob=null),vn((()=>{this._connected||(lc(null,this.shadowRoot),this._instance=null)}))}_resolveDef(){this._resolved=!0;for(let n=0;n{for(const t of e)this._setAttr(t.attributeName)})),this._ob.observe(this,{attributes:!0});const e=(e,t=!1)=>{const{props:n,styles:s}=e;let o;if(n&&!d(n))for(const r in n){const e=n[r];(e===Number||e&&e.type===Number)&&(r in this._props&&(this._props[r]=B(this._props[r])),(o||(o=Object.create(null)))[E(r)]=!0)}this._numberProps=o,t&&this._resolveProps(e),this._applyStyles(s),this._update()},t=this._def.__asyncLoader;t?t().then((t=>e(t,!0))):e(this._def)}_resolveProps(e){const{props:t}=e,n=d(t)?t:Object.keys(t||{});for(const s of Object.keys(this))"_"!==s[0]&&n.includes(s)&&this._setProp(s,this[s],!0,!1);for(const s of n.map(E))Object.defineProperty(this,s,{get(){return this._getProp(s)},set(e){this._setProp(s,e)}})}_setAttr(e){let t=this.getAttribute(e);const n=E(e);this._numberProps&&this._numberProps[n]&&(t=B(t)),this._setProp(n,t,!1)}_getProp(e){return this._props[e]}_setProp(e,t,n=!0,s=!0){t!==this._props[e]&&(this._props[e]=t,s&&this._instance&&this._update(),n&&(!0===t?this.setAttribute(R(e),""):"string"==typeof t||"number"==typeof t?this.setAttribute(R(e),t+""):t||this.removeAttribute(R(e))))}_update(){lc(this._createVNode(),this.shadowRoot)}_createVNode(){const e=qr(this._def,l({},this._props));return this._instance||(e.ce=e=>{this._instance=e,e.isCE=!0;const t=(e,t)=>{this.dispatchEvent(new CustomEvent(e,{detail:t}))};e.emit=(e,...n)=>{t(e,n),R(e)!==e&&t(R(e),n)};let n=this;for(;n=n&&(n.parentNode||n.host);)if(n instanceof wl){e.parent=n._instance,e.provides=n._instance.provides;break}}),e}_applyStyles(e){e&&e.forEach((e=>{const t=document.createElement("style");t.textContent=e,this.shadowRoot.appendChild(t)}))}}function Nl(e="$style"){{const n=oi();if(!n)return t;const s=n.type.__cssModules;if(!s)return t;const o=s[e];return o||t}}const Al=new WeakMap,El=new WeakMap,Il=Symbol("_moveCb"),Rl=Symbol("_enterCb"),Ol={name:"TransitionGroup",props:l({},Hi,{tag:String,moveClass:String}),setup(e,{slots:t}){const n=oi(),s=vs();let o,r;return Ws((()=>{if(!o.length)return;const t=e.moveClass||`${e.name||"v"}-move`;if(!function(e,t,n){const s=e.cloneNode(),o=e[Di];o&&o.forEach((e=>{e.split(/\s+/).forEach((e=>e&&s.classList.remove(e)))}));n.split(/\s+/).forEach((e=>e&&s.classList.add(e))),s.style.display="none";const r=1===t.nodeType?t:t.parentNode;r.appendChild(s);const{hasTransform:i}=Yi(s);return r.removeChild(s),i}(o[0].el,n.vnode.el,t))return;o.forEach(Ll),o.forEach(Ml);const s=o.filter(Pl);nl(),s.forEach((e=>{const n=e.el,s=n.style;Gi(n,t),s.transform=s.webkitTransform=s.transitionDuration="";const o=n[Il]=e=>{e&&e.target!==n||e&&!/transform$/.test(e.propertyName)||(n.removeEventListener("transitionend",o),n[Il]=null,Ji(n,t))};n.addEventListener("transitionend",o)}))})),()=>{const i=It(e),l=Ki(i);let c=i.tag||kr;o=r,r=t.default?ws(t.default()):[];for(let e=0;e{const t=e.props["onUpdate:modelValue"]||!1;return d(t)?e=>M(t,e):t};function Bl(e){e.target.composing=!0}function Vl(e){const t=e.target;t.composing&&(t.composing=!1,t.dispatchEvent(new Event("input")))}const Dl=Symbol("_assign"),Ul={created(e,{modifiers:{lazy:t,trim:n,number:s}},o){e[Dl]=$l(o);const r=s||o.props&&"number"===o.props.type;ml(e,t?"change":"input",(t=>{if(t.target.composing)return;let s=e.value;n&&(s=s.trim()),r&&(s=$(s)),e[Dl](s)})),n&&ml(e,"change",(()=>{e.value=e.value.trim()})),t||(ml(e,"compositionstart",Bl),ml(e,"compositionend",Vl),ml(e,"change",Vl))},mounted(e,{value:t}){e.value=null==t?"":t},beforeUpdate(e,{value:t,modifiers:{lazy:n,trim:s,number:o}},r){if(e[Dl]=$l(r),e.composing)return;const i=null==t?"":t;if((o||"number"===e.type?$(e.value):e.value)!==i){if(document.activeElement===e&&"range"!==e.type){if(n)return;if(s&&e.value.trim()===i)return}e.value=i}}},jl={deep:!0,created(e,t,n){e[Dl]=$l(n),ml(e,"change",(()=>{const t=e._modelValue,n=zl(e),s=e.checked,o=e[Dl];if(d(t)){const e=ne(t,n),r=-1!==e;if(s&&!r)o(t.concat(n));else if(!s&&r){const n=[...t];n.splice(e,1),o(n)}}else if(h(t)){const e=new Set(t);s?e.add(n):e.delete(n),o(e)}else o(Gl(e,s))}))},mounted:Hl,beforeUpdate(e,t,n){e[Dl]=$l(n),Hl(e,t,n)}};function Hl(e,{value:t,oldValue:n},s){e._modelValue=t,d(t)?e.checked=ne(t,s.props.value)>-1:h(t)?e.checked=t.has(s.props.value):t!==n&&(e.checked=te(t,Gl(e,!0)))}const ql={created(e,{value:t},n){e.checked=te(t,n.props.value),e[Dl]=$l(n),ml(e,"change",(()=>{e[Dl](zl(e))}))},beforeUpdate(e,{value:t,oldValue:n},s){e[Dl]=$l(s),t!==n&&(e.checked=te(t,s.props.value))}},Wl={deep:!0,created(e,{value:t,modifiers:{number:n}},s){const o=h(t);ml(e,"change",(()=>{const t=Array.prototype.filter.call(e.options,(e=>e.selected)).map((e=>n?$(zl(e)):zl(e)));e[Dl](e.multiple?o?new Set(t):t:t[0]),e._assigning=!0,vn((()=>{e._assigning=!1}))})),e[Dl]=$l(s)},mounted(e,{value:t,oldValue:n,modifiers:{number:s}}){Kl(e,t,n,s)},beforeUpdate(e,t,n){e[Dl]=$l(n)},updated(e,{value:t,oldValue:n,modifiers:{number:s}}){e._assigning||Kl(e,t,n,s)}};function Kl(e,t,n,s){const o=e.multiple,r=d(t);if((!o||r||h(t))&&(!r||!te(t,n))){for(let n=0,i=e.options.length;n-1}else i.selected=t.has(l);else if(te(zl(i),t))return void(e.selectedIndex!==n&&(e.selectedIndex=n))}o||-1===e.selectedIndex||(e.selectedIndex=-1)}}function zl(e){return"_value"in e?e._value:e.value}function Gl(e,t){const n=t?"_trueValue":"_falseValue";return n in e?e[n]:t}const Jl={created(e,t,n){Xl(e,t,n,null,"created")},mounted(e,t,n){Xl(e,t,n,null,"mounted")},beforeUpdate(e,t,n,s){Xl(e,t,n,s,"beforeUpdate")},updated(e,t,n,s){Xl(e,t,n,s,"updated")}};function Xl(e,t,n,s,o){const r=function(e,t){switch(e){case"SELECT":return Wl;case"TEXTAREA":return Ul;default:switch(t){case"checkbox":return jl;case"radio":return ql;default:return Ul}}}(e.tagName,n.props&&n.props.type)[o];r&&r(e,t,n,s)}const Ql=["ctrl","shift","alt","meta"],Zl={stop:e=>e.stopPropagation(),prevent:e=>e.preventDefault(),self:e=>e.target!==e.currentTarget,ctrl:e=>!e.ctrlKey,shift:e=>!e.shiftKey,alt:e=>!e.altKey,meta:e=>!e.metaKey,left:e=>"button"in e&&0!==e.button,middle:e=>"button"in e&&1!==e.button,right:e=>"button"in e&&2!==e.button,exact:(e,t)=>Ql.some((n=>e[`${n}Key`]&&!t.includes(n)))},Yl=(e,t)=>{const n=e._withMods||(e._withMods={}),s=t.join(".");return n[s]||(n[s]=(n,...s)=>{for(let e=0;e{const n=e._withKeys||(e._withKeys={}),s=t.join(".");return n[s]||(n[s]=n=>{if(!("key"in n))return;const s=R(n.key);return t.some((e=>e===s||ec[e]===s))?e(n):void 0})},nc=l({patchProp:(e,t,n,s,o,l,c,a,u)=>{const d="svg"===o;"class"===t?function(e,t,n){const s=e[Di];s&&(t=(t?[t,...s]:[...s]).join(" ")),null==t?e.removeAttribute("class"):n?e.setAttribute("class",t):e.className=t}(e,s,d):"style"===t?function(e,t,n){const s=e.style,o=s.display,r=g(n);if(n&&!r){if(t&&!g(t))for(const e in t)null==n[e]&&dl(s,e,"");for(const e in n)dl(s,e,n[e])}else if(r){if(t!==n){const e=s[il];e&&(n+=";"+e),s.cssText=n}}else t&&e.removeAttribute("style");sl in e&&(s.display=o)}(e,n,s):r(t)?i(t)||vl(e,t,0,s,c):("."===t[0]?(t=t.slice(1),1):"^"===t[0]?(t=t.slice(1),0):function(e,t,n,s){if(s)return"innerHTML"===t||"textContent"===t||!!(t in e&&xl(t)&&m(n));if("spellcheck"===t||"draggable"===t||"translate"===t)return!1;if("form"===t)return!1;if("list"===t&&"INPUT"===e.tagName)return!1;if("type"===t&&"TEXTAREA"===e.tagName)return!1;if("width"===t||"height"===t){const t=e.tagName;if("IMG"===t||"VIDEO"===t||"CANVAS"===t||"SOURCE"===t)return!1}if(xl(t)&&g(n))return!1;return t in e}(e,t,s,d))?function(e,t,n,s,o,r,i){if("innerHTML"===t||"textContent"===t)return s&&i(s,o,r),void(e[t]=null==n?"":n);const l=e.tagName;if("value"===t&&"PROGRESS"!==l&&!l.includes("-")){e._value=n;const s=null==n?"":n;return("OPTION"===l?e.getAttribute("value"):e.value)!==s&&(e.value=s),void(null==n&&e.removeAttribute(t))}let c=!1;if(""===n||null==n){const s=typeof e[t];"boolean"===s?n=ee(n):null==n&&"string"===s?(n="",c=!0):"number"===s&&(n=0,c=!0)}try{e[t]=n}catch(a){}c&&e.removeAttribute(t)}(e,t,s,l,c,a,u):("true-value"===t?e._trueValue=s:"false-value"===t&&(e._falseValue=s),function(e,t,n,s,o){if(s&&t.startsWith("xlink:"))null==n?e.removeAttributeNS(fl,t.slice(6,t.length)):e.setAttributeNS(fl,t,n);else{const s=Y(t);null==n||s&&!ee(n)?e.removeAttribute(t):e.setAttribute(t,s?"":n)}}(e,t,s,d))}},$i);let sc,oc=!1;function rc(){return sc||(sc=ar(nc))}function ic(){return sc=oc?sc:ur(nc),oc=!0,sc}const lc=(...e)=>{rc().render(...e)},cc=(...e)=>{ic().hydrate(...e)},ac=(...e)=>{const t=rc().createApp(...e),{mount:n}=t;return t.mount=e=>{const s=pc(e);if(!s)return;const o=t._component;m(o)||o.render||o.template||(o.template=s.innerHTML),s.innerHTML="";const r=n(s,!1,dc(s));return s instanceof Element&&(s.removeAttribute("v-cloak"),s.setAttribute("data-v-app","")),r},t},uc=(...e)=>{const t=ic().createApp(...e),{mount:n}=t;return t.mount=e=>{const t=pc(e);if(t)return n(t,!0,dc(t))},t};function dc(e){return e instanceof SVGElement?"svg":"function"==typeof MathMLElement&&e instanceof MathMLElement?"mathml":void 0}function pc(e){if(g(e)){return document.querySelector(e)}return e}const hc=s;var fc=Object.freeze({__proto__:null,BaseTransition:_s,BaseTransitionPropsValidators:bs,Comment:wr,DeprecationTypes:null,EffectScope:ce,ErrorCodes:sn,ErrorTypeStrings:null,Fragment:kr,KeepAlive:Os,ReactiveEffect:he,Static:Nr,Suspense:Xn,Teleport:xr,Text:Tr,TrackOpTypes:en,Transition:Ui,TransitionGroup:Fl,TriggerOpTypes:tn,VueElement:wl,assertNumber:nn,callWithAsyncErrorHandling:rn,callWithErrorHandling:on,camelize:E,capitalize:O,cloneVNode:Kr,compatUtils:null,computed:_i,createApp:ac,createBlock:Pr,createCommentVNode:Jr,createElementBlock:Mr,createElementVNode:Hr,createHydrationRenderer:ur,createPropsRestProxy:xo,createRenderer:ar,createSSRApp:uc,createSlots:Ys,createStaticVNode:Gr,createTextVNode:zr,createVNode:qr,customRef:Gt,defineAsyncComponent:Es,defineComponent:Ns,defineCustomElement:Cl,defineEmits:ao,defineExpose:uo,defineModel:fo,defineOptions:po,defineProps:co,defineSSRCustomElement:kl,defineSlots:ho,devtools:Ei,effect:ye,effectScope:ae,getCurrentInstance:oi,getCurrentScope:de,getTransitionRawChildren:ws,guardReactiveProps:Wr,h:xi,handleError:ln,hasInjectionContext:jo,hydrate:cc,initCustomFormatter:Ci,initDirectivesForSSR:hc,inject:Uo,isMemoSame:Ti,isProxy:Et,isReactive:wt,isReadonly:Nt,isRef:$t,isRuntimeOnly:mi,isShallow:At,isVNode:$r,markRaw:Rt,mergeDefaults:_o,mergeModels:So,mergeProps:Yr,nextTick:vn,normalizeClass:z,normalizeProps:G,normalizeStyle:j,onActivated:Ls,onBeforeMount:js,onBeforeUnmount:Ks,onBeforeUpdate:qs,onDeactivated:Ms,onErrorCaptured:Qs,onMounted:Hs,onRenderTracked:Xs,onRenderTriggered:Js,onScopeDispose:pe,onServerPrefetch:Gs,onUnmounted:zs,onUpdated:Ws,openBlock:Ir,popScopeId:Fn,provide:Do,proxyRefs:Kt,pushScopeId:On,queuePostFlushCb:_n,reactive:St,readonly:Ct,ref:Bt,registerRuntimeCompiler:fi,render:lc,renderList:Zs,renderSlot:eo,resolveComponent:jn,resolveDirective:Wn,resolveDynamicComponent:qn,resolveFilter:null,resolveTransitionHooks:xs,setBlockTracking:Fr,setDevtoolsHook:Ii,setTransitionHooks:Ts,shallowReactive:xt,shallowReadonly:kt,shallowRef:Vt,ssrContextKey:ns,ssrUtils:null,stop:be,toDisplayString:se,toHandlerKey:F,toHandlers:no,toRaw:It,toRef:Zt,toRefs:Jt,toValue:qt,transformVNodeArgs:Vr,triggerRef:jt,unref:Ht,useAttrs:vo,useCssModule:Nl,useCssVars:ll,useModel:Si,useSSRContext:ss,useSlots:go,useTransitionState:vs,vModelCheckbox:jl,vModelDynamic:Jl,vModelRadio:ql,vModelSelect:Wl,vModelText:Ul,vShow:ol,version:wi,warn:Ni,watch:cs,watchEffect:os,watchPostEffect:rs,watchSyncEffect:is,withAsyncContext:Co,withCtx:Mn,withDefaults:mo,withDirectives:hs,withKeys:tc,withMemo:ki,withModifiers:Yl,withScopeId:Ln});const mc=Symbol(""),gc=Symbol(""),vc=Symbol(""),yc=Symbol(""),bc=Symbol(""),_c=Symbol(""),Sc=Symbol(""),xc=Symbol(""),Cc=Symbol(""),kc=Symbol(""),Tc=Symbol(""),wc=Symbol(""),Nc=Symbol(""),Ac=Symbol(""),Ec=Symbol(""),Ic=Symbol(""),Rc=Symbol(""),Oc=Symbol(""),Fc=Symbol(""),Lc=Symbol(""),Mc=Symbol(""),Pc=Symbol(""),$c=Symbol(""),Bc=Symbol(""),Vc=Symbol(""),Dc=Symbol(""),Uc=Symbol(""),jc=Symbol(""),Hc=Symbol(""),qc=Symbol(""),Wc=Symbol(""),Kc=Symbol(""),zc=Symbol(""),Gc=Symbol(""),Jc=Symbol(""),Xc=Symbol(""),Qc=Symbol(""),Zc=Symbol(""),Yc=Symbol(""),ea={[mc]:"Fragment",[gc]:"Teleport",[vc]:"Suspense",[yc]:"KeepAlive",[bc]:"BaseTransition",[_c]:"openBlock",[Sc]:"createBlock",[xc]:"createElementBlock",[Cc]:"createVNode",[kc]:"createElementVNode",[Tc]:"createCommentVNode",[wc]:"createTextVNode",[Nc]:"createStaticVNode",[Ac]:"resolveComponent",[Ec]:"resolveDynamicComponent",[Ic]:"resolveDirective",[Rc]:"resolveFilter",[Oc]:"withDirectives",[Fc]:"renderList",[Lc]:"renderSlot",[Mc]:"createSlots",[Pc]:"toDisplayString",[$c]:"mergeProps",[Bc]:"normalizeClass",[Vc]:"normalizeStyle",[Dc]:"normalizeProps",[Uc]:"guardReactiveProps",[jc]:"toHandlers",[Hc]:"camelize",[qc]:"capitalize",[Wc]:"toHandlerKey",[Kc]:"setBlockTracking",[zc]:"pushScopeId",[Gc]:"popScopeId",[Jc]:"withCtx",[Xc]:"unref",[Qc]:"isRef",[Zc]:"withMemo",[Yc]:"isMemoSame"};const ta={start:{line:1,column:1,offset:0},end:{line:1,column:1,offset:0},source:""};function na(e,t,n,s,o,r,i,l=!1,c=!1,a=!1,u=ta){return e&&(l?(e.helper(_c),e.helper(pa(e.inSSR,a))):e.helper(da(e.inSSR,a)),i&&e.helper(Oc)),{type:13,tag:t,props:n,children:s,patchFlag:o,dynamicProps:r,directives:i,isBlock:l,disableTracking:c,isComponent:a,loc:u}}function sa(e,t=ta){return{type:17,loc:t,elements:e}}function oa(e,t=ta){return{type:15,loc:t,properties:e}}function ra(e,t){return{type:16,loc:ta,key:g(e)?ia(e,!0):e,value:t}}function ia(e,t=!1,n=ta,s=0){return{type:4,loc:n,content:e,isStatic:t,constType:t?3:s}}function la(e,t=ta){return{type:8,loc:t,children:e}}function ca(e,t=[],n=ta){return{type:14,loc:n,callee:e,arguments:t}}function aa(e,t=void 0,n=!1,s=!1,o=ta){return{type:18,params:e,returns:t,newline:n,isSlot:s,loc:o}}function ua(e,t,n,s=!0){return{type:19,test:e,consequent:t,alternate:n,newline:s,loc:ta}}function da(e,t){return e||t?Cc:kc}function pa(e,t){return e||t?Sc:xc}function ha(e,{helper:t,removeHelper:n,inSSR:s}){e.isBlock||(e.isBlock=!0,n(da(s,e.isComponent)),t(_c),t(pa(s,e.isComponent)))}const fa=new Uint8Array([123,123]),ma=new Uint8Array([125,125]);function ga(e){return e>=97&&e<=122||e>=65&&e<=90}function va(e){return 32===e||10===e||9===e||12===e||13===e}function ya(e){return 47===e||62===e||va(e)}function ba(e){const t=new Uint8Array(e.length);for(let n=0;n4===e.type&&e.isStatic;function Ta(e){switch(e){case"Teleport":case"teleport":return gc;case"Suspense":case"suspense":return vc;case"KeepAlive":case"keep-alive":return yc;case"BaseTransition":case"base-transition":return bc}}const wa=/^\d|[^\$\w]/,Na=e=>!wa.test(e),Aa=/[A-Za-z_$\xA0-\uFFFF]/,Ea=/[\.\?\w$\xA0-\uFFFF]/,Ia=/\s+[.[]\s*|\s*[.[]\s+/g,Ra=e=>{e=e.trim().replace(Ia,(e=>e.trim()));let t=0,n=[],s=0,o=0,r=null;for(let i=0;i4===e.key.type&&e.key.content===s))}return n}function Ha(e,t){return`_${t}_${e.replace(/[^\w]/g,((t,n)=>"-"===t?"_":e.charCodeAt(n).toString()))}`}const qa=/([\s\S]*?)\s+(?:in|of)\s+([\s\S]*)/,Wa={parseMode:"base",ns:0,delimiters:["{{","}}"],getNamespace:()=>0,isVoidTag:o,isPreTag:o,isCustomElement:o,onError:Sa,onWarn:xa,comments:!1,prefixIdentifiers:!1};let Ka=Wa,za=null,Ga="",Ja=null,Xa=null,Qa="",Za=-1,Ya=-1,eu=0,tu=!1,nu=null;const su=[],ou=new class{constructor(e,t){this.stack=e,this.cbs=t,this.state=1,this.buffer="",this.sectionStart=0,this.index=0,this.entityStart=0,this.baseState=1,this.inRCDATA=!1,this.inXML=!1,this.inVPre=!1,this.newlines=[],this.mode=0,this.delimiterOpen=fa,this.delimiterClose=ma,this.delimiterIndex=-1,this.currentSequence=void 0,this.sequenceIndex=0}get inSFCRoot(){return 2===this.mode&&0===this.stack.length}reset(){this.state=1,this.mode=0,this.buffer="",this.sectionStart=0,this.index=0,this.baseState=1,this.inRCDATA=!1,this.currentSequence=void 0,this.newlines.length=0,this.delimiterOpen=fa,this.delimiterClose=ma}getPos(e){let t=1,n=e+1;for(let s=this.newlines.length-1;s>=0;s--){const o=this.newlines[s];if(e>o){t=s+2,n=e-o;break}}return{column:n,line:t,offset:e}}peek(){return this.buffer.charCodeAt(this.index+1)}stateText(e){60===e?(this.index>this.sectionStart&&this.cbs.ontext(this.sectionStart,this.index),this.state=5,this.sectionStart=this.index):this.inVPre||e!==this.delimiterOpen[0]||(this.state=2,this.delimiterIndex=0,this.stateInterpolationOpen(e))}stateInterpolationOpen(e){if(e===this.delimiterOpen[this.delimiterIndex])if(this.delimiterIndex===this.delimiterOpen.length-1){const e=this.index+1-this.delimiterOpen.length;e>this.sectionStart&&this.cbs.ontext(this.sectionStart,e),this.state=3,this.sectionStart=e}else this.delimiterIndex++;else this.inRCDATA?(this.state=32,this.stateInRCDATA(e)):(this.state=1,this.stateText(e))}stateInterpolation(e){e===this.delimiterClose[0]&&(this.state=4,this.delimiterIndex=0,this.stateInterpolationClose(e))}stateInterpolationClose(e){e===this.delimiterClose[this.delimiterIndex]?this.delimiterIndex===this.delimiterClose.length-1?(this.cbs.oninterpolation(this.sectionStart,this.index+1),this.state=this.inRCDATA?32:1,this.sectionStart=this.index+1):this.delimiterIndex++:(this.state=3,this.stateInterpolation(e))}stateSpecialStartSequence(e){const t=this.sequenceIndex===this.currentSequence.length;if(t?ya(e):(32|e)===this.currentSequence[this.sequenceIndex]){if(!t)return void this.sequenceIndex++}else this.inRCDATA=!1;this.sequenceIndex=0,this.state=6,this.stateInTagName(e)}stateInRCDATA(e){if(this.sequenceIndex===this.currentSequence.length){if(62===e||va(e)){const t=this.index-this.currentSequence.length;if(this.sectionStart=e||(28===this.state?this.currentSequence===_a.CdataEnd?this.cbs.oncdata(this.sectionStart,e):this.cbs.oncomment(this.sectionStart,e):6===this.state||11===this.state||18===this.state||17===this.state||12===this.state||13===this.state||14===this.state||15===this.state||16===this.state||20===this.state||19===this.state||21===this.state||9===this.state||this.cbs.ontext(this.sectionStart,e))}emitCodePoint(e,t){}}(su,{onerr:Cu,ontext(e,t){au(lu(e,t),e,t)},ontextentity(e,t,n){au(e,t,n)},oninterpolation(e,t){if(tu)return au(lu(e,t),e,t);let n=e+ou.delimiterOpen.length,s=t-ou.delimiterClose.length;for(;va(Ga.charCodeAt(n));)n++;for(;va(Ga.charCodeAt(s-1));)s--;let o=lu(n,s);o.includes("&")&&(o=Ka.decodeEntities(o,!1)),yu({type:5,content:xu(o,!1,bu(n,s)),loc:bu(e,t)})},onopentagname(e,t){const n=lu(e,t);Ja={type:1,tag:n,ns:Ka.getNamespace(n,su[0],Ka.ns),tagType:0,props:[],children:[],loc:bu(e-1,t),codegenNode:void 0}},onopentagend(e){cu(e)},onclosetag(e,t){const n=lu(e,t);if(!Ka.isVoidTag(n)){let s=!1;for(let e=0;e(7===e.type?e.rawName:e.name)===t))},onattribend(e,t){if(Ja&&Xa){if(_u(Xa.loc,t),0!==e)if(Qa.includes("&")&&(Qa=Ka.decodeEntities(Qa,!0)),6===Xa.type)"class"===Xa.name&&(Qa=vu(Qa).trim()),Xa.value={type:2,content:Qa,loc:1===e?bu(Za,Ya):bu(Za-1,Ya+1)},ou.inSFCRoot&&"template"===Ja.tag&&"lang"===Xa.name&&Qa&&"html"!==Qa&&ou.enterRCDATA(ba("{const o=t.start.offset+n;return xu(e,!1,bu(o,o+e.length),0,s?1:0)},l={source:i(r.trim(),n.indexOf(r,o.length)),value:void 0,key:void 0,index:void 0,finalized:!1};let c=o.trim().replace(iu,"").trim();const a=o.indexOf(c),u=c.match(ru);if(u){c=c.replace(ru,"").trim();const e=u[1].trim();let t;if(e&&(t=n.indexOf(e,a+c.length),l.key=i(e,t,!0)),u[2]){const s=u[2].trim();s&&(l.index=i(s,n.indexOf(s,l.key?t+e.length:a+c.length),!0))}}c&&(l.value=i(c,a,!0));return l}(Xa.exp))}7===Xa.type&&"pre"===Xa.name||Ja.props.push(Xa)}Qa="",Za=Ya=-1},oncomment(e,t){Ka.comments&&yu({type:3,content:lu(e,t),loc:bu(e-4,t+3)})},onend(){const e=Ga.length;for(let t=0;t64&&s<91)||Ta(e)||(null==(n=Ka.isBuiltInComponent)?void 0:n.call(Ka,e))||Ka.isNativeTag&&!Ka.isNativeTag(e))return!0;var s;for(let o=0;o=0;)n--;return n}const pu=new Set(["if","else","else-if","for","slot"]);const hu=/\r\n/g;function fu(e,t){var n,s;const o="preserve"!==Ka.whitespace;let r=!1;for(let i=0;i0){if(s>=2){e.codegenNode.patchFlag="-1",e.codegenNode=t.hoist(e.codegenNode),r++;continue}}else{const n=e.codegenNode;if(13===n.type){const s=Fu(n);if((!s||512===s||1===s)&&Ru(e,t)>=2){const s=Ou(e);s&&(n.props=t.hoist(s))}n.dynamicProps&&(n.dynamicProps=t.hoist(n.dynamicProps))}}}if(1===e.type){const n=1===e.tagType;n&&t.scopes.vSlot++,Nu(e,t),n&&t.scopes.vSlot--}else if(11===e.type)Nu(e,t,1===e.children.length);else if(9===e.type)for(let n=0;n1)for(let o=0;o`_${ea[N.helper(e)]}`,replaceNode(e){N.parent.children[N.childIndex]=N.currentNode=e},removeNode(e){const t=e?N.parent.children.indexOf(e):N.currentNode?N.childIndex:-1;e&&e!==N.currentNode?N.childIndex>t&&(N.childIndex--,N.onNodeRemoved()):(N.currentNode=null,N.onNodeRemoved()),N.parent.children.splice(t,1)},onNodeRemoved:s,addIdentifiers(e){},removeIdentifiers(e){},hoist(e){g(e)&&(e=ia(e)),N.hoists.push(e);const t=ia(`_hoisted_${N.hoists.length}`,!1,e.loc,2);return t.hoisted=e,t},cache:(e,t=!1)=>function(e,t,n=!1){return{type:20,index:e,value:t,isVNode:n,loc:ta}}(N.cached++,e,t)};return N}function Mu(e,t){const n=Lu(e,t);Pu(e,n),t.hoistStatic&&Tu(e,n),t.ssr||function(e,t){const{helper:n}=t,{children:s}=e;if(1===s.length){const n=s[0];if(wu(e,n)&&n.codegenNode){const s=n.codegenNode;13===s.type&&ha(s,t),e.codegenNode=s}else e.codegenNode=n}else if(s.length>1){let s=64;e.codegenNode=na(t,n(mc),void 0,e.children,s+"",void 0,void 0,!0,void 0,!1)}}(e,n),e.helpers=new Set([...n.helpers.keys()]),e.components=[...n.components],e.directives=[...n.directives],e.imports=n.imports,e.hoists=n.hoists,e.temps=n.temps,e.cached=n.cached,e.transformed=!0}function Pu(e,t){t.currentNode=e;const{nodeTransforms:n}=t,s=[];for(let r=0;r{n--};for(;nt===e:t=>e.test(t);return(e,s)=>{if(1===e.type){const{props:o}=e;if(3===e.tagType&&o.some(Pa))return;const r=[];for(let i=0;i`${ea[e]}: _${ea[e]}`;function Du(e,{mode:t="function",prefixIdentifiers:n="module"===t,sourceMap:s=!1,filename:o="template.vue.html",scopeId:r=null,optimizeImports:i=!1,runtimeGlobalName:l="Vue",runtimeModuleName:c="vue",ssrRuntimeModuleName:a="vue/server-renderer",ssr:u=!1,isTS:d=!1,inSSR:p=!1}){const h={mode:t,prefixIdentifiers:n,sourceMap:s,filename:o,scopeId:r,optimizeImports:i,runtimeGlobalName:l,runtimeModuleName:c,ssrRuntimeModuleName:a,ssr:u,isTS:d,inSSR:p,source:e.source,code:"",column:1,line:1,offset:0,indentLevel:0,pure:!1,map:void 0,helper:e=>`_${ea[e]}`,push(e,t=-2,n){h.code+=e},indent(){f(++h.indentLevel)},deindent(e=!1){e?--h.indentLevel:f(--h.indentLevel)},newline(){f(h.indentLevel)}};function f(e){h.push("\n"+" ".repeat(e),0)}return h}function Uu(e,t={}){const n=Du(e,t);t.onContextCreated&&t.onContextCreated(n);const{mode:s,push:o,prefixIdentifiers:r,indent:i,deindent:l,newline:c,ssr:a}=n,u=Array.from(e.helpers),d=u.length>0,p=!r&&"module"!==s,h=n;!function(e,t){const{push:n,newline:s,runtimeGlobalName:o}=t,r=o,i=Array.from(e.helpers);if(i.length>0&&(n(`const _Vue = ${r}\n`,-1),e.hoists.length)){n(`const { ${[Cc,kc,Tc,wc,Nc].filter((e=>i.includes(e))).map(Vu).join(", ")} } = _Vue\n`,-1)}(function(e,t){if(!e.length)return;t.pure=!0;const{push:n,newline:s}=t;s();for(let o=0;o0)&&c()),e.directives.length&&(ju(e.directives,"directive",n),e.temps>0&&c()),e.temps>0){o("let ");for(let t=0;t0?", ":""}_temp${t}`)}return(e.components.length||e.directives.length||e.temps)&&(o("\n",0),c()),a||o("return "),e.codegenNode?Wu(e.codegenNode,n):o("null"),p&&(l(),o("}")),l(),o("}"),{ast:e,code:n.code,preamble:"",map:n.map?n.map.toJSON():void 0}}function ju(e,t,{helper:n,push:s,newline:o,isTS:r}){const i=n("component"===t?Ac:Ic);for(let l=0;l3||!1;t.push("["),n&&t.indent(),qu(e,t,n),n&&t.deindent(),t.push("]")}function qu(e,t,n=!1,s=!0){const{push:o,newline:r}=t;for(let i=0;ie||"null"))}([r,i,l,c,a]),t),n(")"),d&&n(")");u&&(n(", "),Wu(u,t),n(")"))}(e,t);break;case 14:!function(e,t){const{push:n,helper:s,pure:o}=t,r=g(e.callee)?e.callee:s(e.callee);o&&n(Bu);n(r+"(",-2,e),qu(e.arguments,t),n(")")}(e,t);break;case 15:!function(e,t){const{push:n,indent:s,deindent:o,newline:r}=t,{properties:i}=e;if(!i.length)return void n("{}",-2,e);const l=i.length>1||!1;n(l?"{":"{ "),l&&s();for(let c=0;c "),(c||l)&&(n("{"),s());i?(c&&n("return "),d(i)?Hu(i,t):Wu(i,t)):l&&Wu(l,t);(c||l)&&(o(),n("}"));a&&n(")")}(e,t);break;case 19:!function(e,t){const{test:n,consequent:s,alternate:o,newline:r}=e,{push:i,indent:l,deindent:c,newline:a}=t;if(4===n.type){const e=!Na(n.content);e&&i("("),Ku(n,t),e&&i(")")}else i("("),Wu(n,t),i(")");r&&l(),t.indentLevel++,r||i(" "),i("? "),Wu(s,t),t.indentLevel--,r&&a(),r||i(" "),i(": ");const u=19===o.type;u||t.indentLevel++;Wu(o,t),u||t.indentLevel--;r&&c(!0)}(e,t);break;case 20:!function(e,t){const{push:n,helper:s,indent:o,deindent:r,newline:i}=t;n(`_cache[${e.index}] || (`),e.isVNode&&(o(),n(`${s(Kc)}(-1),`),i());n(`_cache[${e.index}] = `),Wu(e.value,t),e.isVNode&&(n(","),i(),n(`${s(Kc)}(1),`),i(),n(`_cache[${e.index}]`),r());n(")")}(e,t);break;case 21:qu(e.body,t,!0,!1)}}function Ku(e,t){const{content:n,isStatic:s}=e;t.push(s?JSON.stringify(n):n,-3,e)}function zu(e,t){for(let n=0;nfunction(e,t,n,s){if(!("else"===t.name||t.exp&&t.exp.content.trim())){const s=t.exp?t.exp.loc:e.loc;n.onError(Ca(28,t.loc)),t.exp=ia("true",!1,s)}if("if"===t.name){const o=Xu(e,t),r={type:9,loc:e.loc,branches:[o]};if(n.replaceNode(r),s)return s(r,o,!0)}else{const o=n.parent.children;let r=o.indexOf(e);for(;r-- >=-1;){const i=o[r];if(i&&3===i.type)n.removeNode(i);else{if(!i||2!==i.type||i.content.trim().length){if(i&&9===i.type){"else-if"===t.name&&void 0===i.branches[i.branches.length-1].condition&&n.onError(Ca(30,e.loc)),n.removeNode();const o=Xu(e,t);i.branches.push(o);const r=s&&s(i,o,!1);Pu(o,n),r&&r(),n.currentNode=null}else n.onError(Ca(30,e.loc));break}n.removeNode(i)}}}}(e,t,n,((e,t,s)=>{const o=n.parent.children;let r=o.indexOf(e),i=0;for(;r-- >=0;){const e=o[r];e&&9===e.type&&(i+=e.branches.length)}return()=>{if(s)e.codegenNode=Qu(t,i,n);else{const s=function(e){for(;;)if(19===e.type){if(19!==e.alternate.type)return e;e=e.alternate}else 20===e.type&&(e=e.value)}(e.codegenNode);s.alternate=Qu(t,i+e.branches.length-1,n)}}}))));function Xu(e,t){const n=3===e.tagType;return{type:10,loc:e.loc,condition:"else"===t.name?void 0:t.exp,children:n&&!Oa(e,"for")?e.children:[e],userKey:Fa(e,"key"),isTemplateIf:n}}function Qu(e,t,n){return e.condition?ua(e.condition,Zu(e,t,n),ca(n.helper(Tc),['""',"true"])):Zu(e,t,n)}function Zu(e,t,n){const{helper:s}=n,o=ra("key",ia(`${t}`,!1,ta,2)),{children:r}=e,i=r[0];if(1!==r.length||1!==i.type){if(1===r.length&&11===i.type){const e=i.codegenNode;return Ua(e,o,n),e}{let t=64;return na(n,s(mc),oa([o]),r,t+"",void 0,void 0,!0,!1,!1,e.loc)}}{const e=i.codegenNode,t=14===(l=e).type&&l.callee===Zc?l.arguments[1].returns:l;return 13===t.type&&ha(t,n),Ua(t,o,n),e}var l}const Yu=$u("for",((e,t,n)=>{const{helper:s,removeHelper:o}=n;return function(e,t,n,s){if(!t.exp)return void n.onError(Ca(31,t.loc));const o=t.forParseResult;if(!o)return void n.onError(Ca(32,t.loc));ed(o);const{scopes:r}=n,{source:i,value:l,key:c,index:a}=o,u={type:11,loc:t.loc,source:i,valueAlias:l,keyAlias:c,objectIndexAlias:a,parseResult:o,children:$a(e)?e.children:[e]};n.replaceNode(u),r.vFor++;const d=s&&s(u);return()=>{r.vFor--,d&&d()}}(e,t,n,(t=>{const r=ca(s(Fc),[t.source]),i=$a(e),l=Oa(e,"memo"),c=Fa(e,"key"),a=c&&(6===c.type?ia(c.value.content,!0):c.exp),u=c?ra("key",a):null,d=4===t.source.type&&t.source.constType>0,p=d?64:c?128:256;return t.codegenNode=na(n,s(mc),void 0,r,p+"",void 0,void 0,!0,!d,!1,e.loc),()=>{let c;const{children:p}=t,h=1!==p.length||1!==p[0].type,f=Ba(e)?e:i&&1===e.children.length&&Ba(e.children[0])?e.children[0]:null;if(f?(c=f.codegenNode,i&&u&&Ua(c,u,n)):h?c=na(n,s(mc),u?oa([u]):void 0,e.children,"64",void 0,void 0,!0,void 0,!1):(c=p[0].codegenNode,i&&u&&Ua(c,u,n),c.isBlock!==!d&&(c.isBlock?(o(_c),o(pa(n.inSSR,c.isComponent))):o(da(n.inSSR,c.isComponent))),c.isBlock=!d,c.isBlock?(s(_c),s(pa(n.inSSR,c.isComponent))):s(da(n.inSSR,c.isComponent))),l){const e=aa(td(t.parseResult,[ia("_cached")]));e.body={type:21,body:[la(["const _memo = (",l.exp,")"]),la(["if (_cached",...a?[" && _cached.key === ",a]:[],` && ${n.helperString(Yc)}(_cached, _memo)) return _cached`]),la(["const _item = ",c]),ia("_item.memo = _memo"),ia("return _item")],loc:ta},r.arguments.push(e,ia("_cache"),ia(String(n.cached++)))}else r.arguments.push(aa(td(t.parseResult),c,!0))}}))}));function ed(e,t){e.finalized||(e.finalized=!0)}function td({value:e,key:t,index:n},s=[]){return function(e){let t=e.length;for(;t--&&!e[t];);return e.slice(0,t+1).map(((e,t)=>e||ia("_".repeat(t+1),!1)))}([e,t,n,...s])}const nd=ia("undefined",!1),sd=(e,t)=>{if(1===e.type&&(1===e.tagType||3===e.tagType)){const n=Oa(e,"slot");if(n)return t.scopes.vSlot++,()=>{t.scopes.vSlot--}}},od=(e,t,n,s)=>aa(e,n,!1,!0,n.length?n[0].loc:s);function rd(e,t,n=od){t.helper(Jc);const{children:s,loc:o}=e,r=[],i=[];let l=t.scopes.vSlot>0||t.scopes.vFor>0;const c=Oa(e,"slot",!0);if(c){const{arg:e,exp:t}=c;e&&!ka(e)&&(l=!0),r.push(ra(e||ia("default",!0),n(t,void 0,s,o)))}let a=!1,u=!1;const d=[],p=new Set;let h=0;for(let g=0;gra("default",n(e,void 0,t,o));a?d.length&&d.some((e=>cd(e)))&&(u?t.onError(Ca(39,d[0].loc)):r.push(e(void 0,d))):r.push(e(void 0,s))}const f=l?2:ld(e.children)?3:1;let m=oa(r.concat(ra("_",ia(f+"",!1))),o);return i.length&&(m=ca(t.helper(Mc),[m,sa(i)])),{slots:m,hasDynamicSlots:l}}function id(e,t,n){const s=[ra("name",e),ra("fn",t)];return null!=n&&s.push(ra("key",ia(String(n),!0))),oa(s)}function ld(e){for(let t=0;tfunction(){if(1!==(e=t.currentNode).type||0!==e.tagType&&1!==e.tagType)return;const{tag:n,props:s}=e,o=1===e.tagType;let r=o?function(e,t,n=!1){let{tag:s}=e;const o=fd(s),r=Fa(e,"is");if(r)if(o){const e=6===r.type?r.value&&ia(r.value.content,!0):r.exp;if(e)return ca(t.helper(Ec),[e])}else 6===r.type&&r.value.content.startsWith("vue:")&&(s=r.value.content.slice(4));const i=Ta(s)||t.isBuiltInComponent(s);if(i)return n||t.helper(i),i;return t.helper(Ac),t.components.add(s),Ha(s,"component")}(e,t):`"${n}"`;const i=y(r)&&r.callee===Ec;let l,c,a,u,d,p,h=0,f=i||r===gc||r===vc||!o&&("svg"===n||"foreignObject"===n);if(s.length>0){const n=dd(e,t,void 0,o,i);l=n.props,h=n.patchFlag,d=n.dynamicPropNames;const s=n.directives;p=s&&s.length?sa(s.map((e=>function(e,t){const n=[],s=ad.get(e);s?n.push(t.helperString(s)):(t.helper(Ic),t.directives.add(e.name),n.push(Ha(e.name,"directive")));const{loc:o}=e;e.exp&&n.push(e.exp);e.arg&&(e.exp||n.push("void 0"),n.push(e.arg));if(Object.keys(e.modifiers).length){e.arg||(e.exp||n.push("void 0"),n.push("void 0"));const t=ia("true",!1,o);n.push(oa(e.modifiers.map((e=>ra(e,t))),o))}return sa(n,e.loc)}(e,t)))):void 0,n.shouldUseBlock&&(f=!0)}if(e.children.length>0){r===yc&&(f=!0,h|=1024);if(o&&r!==gc&&r!==yc){const{slots:n,hasDynamicSlots:s}=rd(e,t);c=n,s&&(h|=1024)}else if(1===e.children.length&&r!==gc){const n=e.children[0],s=n.type,o=5===s||8===s;o&&0===Au(n,t)&&(h|=1),c=o||2===s?n:e.children}else c=e.children}0!==h&&(a=String(h),d&&d.length&&(u=function(e){let t="[";for(let n=0,s=e.length;n0;let f=!1,m=0,g=!1,y=!1,b=!1,_=!1,S=!1,x=!1;const C=[],k=e=>{u.length&&(d.push(oa(pd(u),c)),u=[]),e&&d.push(e)},N=({key:e,value:n})=>{if(ka(e)){const i=e.content,l=r(i);if(!l||s&&!o||"onclick"===i.toLowerCase()||"onUpdate:modelValue"===i||T(i)||(_=!0),l&&T(i)&&(x=!0),l&&14===n.type&&(n=n.arguments[0]),20===n.type||(4===n.type||8===n.type)&&Au(n,t)>0)return;"ref"===i?g=!0:"class"===i?y=!0:"style"===i?b=!0:"key"===i||C.includes(i)||C.push(i),!s||"class"!==i&&"style"!==i||C.includes(i)||C.push(i)}else S=!0};for(let r=0;r0&&u.push(ra(ia("ref_for",!0),ia("true")))),"is"===n&&(fd(l)||r&&r.content.startsWith("vue:")))continue;u.push(ra(ia(n,!0,s),ia(r?r.content:"",i,r?r.loc:e)))}else{const{name:n,arg:r,exp:a,loc:g,modifiers:y}=o,b="bind"===n,_="on"===n;if("slot"===n){s||t.onError(Ca(40,g));continue}if("once"===n||"memo"===n)continue;if("is"===n||b&&La(r,"is")&&fd(l))continue;if(_&&i)continue;if((b&&La(r,"key")||_&&h&&La(r,"vue:before-update"))&&(f=!0),b&&La(r,"ref")&&t.scopes.vFor>0&&u.push(ra(ia("ref_for",!0),ia("true"))),!r&&(b||_)){S=!0,a?b?(k(),d.push(a)):k({type:14,loc:g,callee:t.helper(jc),arguments:s?[a]:[a,"true"]}):t.onError(Ca(b?34:35,g));continue}b&&y.includes("prop")&&(m|=32);const x=t.directiveTransforms[n];if(x){const{props:n,needRuntime:s}=x(o,e,t);!i&&n.forEach(N),_&&r&&!ka(r)?k(oa(n,c)):u.push(...n),s&&(p.push(o),v(s)&&ad.set(o,s))}else w(n)||(p.push(o),h&&(f=!0))}}let A;if(d.length?(k(),A=d.length>1?ca(t.helper($c),d,c):d[0]):u.length&&(A=oa(pd(u),c)),S?m|=16:(y&&!s&&(m|=2),b&&!s&&(m|=4),C.length&&(m|=8),_&&(m|=32)),f||0!==m&&32!==m||!(g||x||p.length>0)||(m|=512),!t.inSSR&&A)switch(A.type){case 15:let e=-1,n=-1,s=!1;for(let t=0;t{if(Ba(e)){const{children:n,loc:s}=e,{slotName:o,slotProps:r}=function(e,t){let n,s='"default"';const o=[];for(let r=0;r0){const{props:s,directives:r}=dd(e,t,o,!1,!1);n=s,r.length&&t.onError(Ca(36,r[0].loc))}return{slotName:s,slotProps:n}}(e,t),i=[t.prefixIdentifiers?"_ctx.$slots":"$slots",o,"{}","undefined","true"];let l=2;r&&(i[2]=r,l=3),n.length&&(i[3]=aa([],n,!1,!1,s),l=4),t.scopeId&&!t.slotted&&(l=5),i.splice(l),e.codegenNode=ca(t.helper(Lc),i,s)}};const gd=/^\s*([\w$_]+|(async\s*)?\([^)]*?\))\s*(:[^=]+)?=>|^\s*(async\s+)?function(?:\s+[\w$]+)?\s*\(/,vd=(e,t,n,s)=>{const{loc:o,modifiers:r,arg:i}=e;let l;if(4===i.type)if(i.isStatic){let e=i.content;e.startsWith("vue:")&&(e=`vnode-${e.slice(4)}`);l=ia(0!==t.tagType||e.startsWith("vnode")||!/[A-Z]/.test(e)?F(E(e)):`on:${e}`,!0,i.loc)}else l=la([`${n.helperString(Wc)}(`,i,")"]);else l=i,l.children.unshift(`${n.helperString(Wc)}(`),l.children.push(")");let c=e.exp;c&&!c.content.trim()&&(c=void 0);let a=n.cacheHandlers&&!c&&!n.inVOnce;if(c){const e=Ra(c.content),t=!(e||gd.test(c.content)),n=c.content.includes(";");(t||a&&e)&&(c=la([`${t?"$event":"(...args)"} => ${n?"{":"("}`,c,n?"}":")"]))}let u={props:[ra(l,c||ia("() => {}",!1,o))]};return s&&(u=s(u)),a&&(u.props[0].value=n.cache(u.props[0].value)),u.props.forEach((e=>e.key.isHandlerKey=!0)),u},yd=(e,t,n)=>{const{modifiers:s,loc:o}=e,r=e.arg;let{exp:i}=e;if(!i&&4===r.type){const t=E(r.content);i=e.exp=ia(t,!1,r.loc)}return 4!==r.type?(r.children.unshift("("),r.children.push(') || ""')):r.isStatic||(r.content=`${r.content} || ""`),s.includes("camel")&&(4===r.type?r.content=r.isStatic?E(r.content):`${n.helperString(Hc)}(${r.content})`:(r.children.unshift(`${n.helperString(Hc)}(`),r.children.push(")"))),n.inSSR||(s.includes("prop")&&bd(r,"."),s.includes("attr")&&bd(r,"^")),!i||4===i.type&&!i.content.trim()?{props:[ra(r,ia("",!0,o))]}:{props:[ra(r,i)]}},bd=(e,t)=>{4===e.type?e.content=e.isStatic?t+e.content:`\`${t}\${${e.content}}\``:(e.children.unshift(`'${t}' + (`),e.children.push(")"))},_d=(e,t)=>{if(0===e.type||1===e.type||11===e.type||10===e.type)return()=>{const n=e.children;let s,o=!1;for(let e=0;e7===e.type&&!t.directiveTransforms[e.name])))))for(let e=0;e{if(1===e.type&&Oa(e,"once",!0)){if(Sd.has(e)||t.inVOnce||t.inSSR)return;return Sd.add(e),t.inVOnce=!0,t.helper(Kc),()=>{t.inVOnce=!1;const e=t.currentNode;e.codegenNode&&(e.codegenNode=t.cache(e.codegenNode,!0))}}},Cd=(e,t,n)=>{const{exp:s,arg:o}=e;if(!s)return n.onError(Ca(41,e.loc)),kd();const r=s.loc.source,i=4===s.type?s.content:r,l=n.bindingMetadata[r];if("props"===l||"props-aliased"===l)return kd();if(!i.trim()||!Ra(i))return n.onError(Ca(42,s.loc)),kd();const c=o||ia("modelValue",!0),a=o?ka(o)?`onUpdate:${E(o.content)}`:la(['"onUpdate:" + ',o]):"onUpdate:modelValue";let u;u=la([`${n.isTS?"($event: any)":"$event"} => ((`,s,") = $event)"]);const d=[ra(c,e.exp),ra(a,u)];if(e.modifiers.length&&1===t.tagType){const t=e.modifiers.map((e=>(Na(e)?e:JSON.stringify(e))+": true")).join(", "),n=o?ka(o)?`${o.content}Modifiers`:la([o,' + "Modifiers"']):"modelModifiers";d.push(ra(n,ia(`{ ${t} }`,!1,e.loc,2)))}return kd(d)};function kd(e=[]){return{props:e}}const Td=new WeakSet,wd=(e,t)=>{if(1===e.type){const n=Oa(e,"memo");if(!n||Td.has(e))return;return Td.add(e),()=>{const s=e.codegenNode||t.currentNode.codegenNode;s&&13===s.type&&(1!==e.tagType&&ha(s,t),e.codegenNode=ca(t.helper(Zc),[n.exp,aa(void 0,s),"_cache",String(t.cached++)]))}}};function Nd(e,t={}){const n=t.onError||Sa,s="module"===t.mode;!0===t.prefixIdentifiers?n(Ca(47)):s&&n(Ca(48));t.cacheHandlers&&n(Ca(49)),t.scopeId&&!s&&n(Ca(50));const o=l({},t,{prefixIdentifiers:!1}),r=g(e)?ku(e,o):e,[i,c]=[[xd,Ju,wd,Yu,md,ud,sd,_d],{on:vd,bind:yd,model:Cd}];return Mu(r,l({},o,{nodeTransforms:[...i,...t.nodeTransforms||[]],directiveTransforms:l({},c,t.directiveTransforms||{})})),Uu(r,o)}const Ad=Symbol(""),Ed=Symbol(""),Id=Symbol(""),Rd=Symbol(""),Od=Symbol(""),Fd=Symbol(""),Ld=Symbol(""),Md=Symbol(""),Pd=Symbol(""),$d=Symbol("");var Bd;let Vd;Bd={[Ad]:"vModelRadio",[Ed]:"vModelCheckbox",[Id]:"vModelText",[Rd]:"vModelSelect",[Od]:"vModelDynamic",[Fd]:"withModifiers",[Ld]:"withKeys",[Md]:"vShow",[Pd]:"Transition",[$d]:"TransitionGroup"},Object.getOwnPropertySymbols(Bd).forEach((e=>{ea[e]=Bd[e]}));const Dd={parseMode:"html",isVoidTag:Z,isNativeTag:e=>J(e)||X(e)||Q(e),isPreTag:e=>"pre"===e,decodeEntities:function(e,t=!1){return Vd||(Vd=document.createElement("div")),t?(Vd.innerHTML=`
`,Vd.children[0].getAttribute("foo")):(Vd.innerHTML=e,Vd.textContent)},isBuiltInComponent:e=>"Transition"===e||"transition"===e?Pd:"TransitionGroup"===e||"transition-group"===e?$d:void 0,getNamespace(e,t,n){let s=t?t.ns:n;if(t&&2===s)if("annotation-xml"===t.tag){if("svg"===e)return 1;t.props.some((e=>6===e.type&&"encoding"===e.name&&null!=e.value&&("text/html"===e.value.content||"application/xhtml+xml"===e.value.content)))&&(s=0)}else/^m(?:[ions]|text)$/.test(t.tag)&&"mglyph"!==e&&"malignmark"!==e&&(s=0);else t&&1===s&&("foreignObject"!==t.tag&&"desc"!==t.tag&&"title"!==t.tag||(s=0));if(0===s){if("svg"===e)return 1;if("math"===e)return 2}return s}},Ud=(e,t)=>{const n=K(e);return ia(JSON.stringify(n),!1,t,3)};function jd(e,t){return Ca(e,t)}const Hd=e("passive,once,capture"),qd=e("stop,prevent,self,ctrl,shift,alt,meta,exact,middle"),Wd=e("left,right"),Kd=e("onkeyup,onkeydown,onkeypress",!0),zd=(e,t)=>ka(e)&&"onclick"===e.content.toLowerCase()?ia(t,!0):4!==e.type?la(["(",e,`) === "onClick" ? "${t}" : (`,e,")"]):e,Gd=(e,t)=>{1!==e.type||0!==e.tagType||"script"!==e.tag&&"style"!==e.tag||t.removeNode()},Jd=[e=>{1===e.type&&e.props.forEach(((t,n)=>{6===t.type&&"style"===t.name&&t.value&&(e.props[n]={type:7,name:"bind",arg:ia("style",!0,t.loc),exp:Ud(t.value.content,t.loc),modifiers:[],loc:t.loc})}))}],Xd={cloak:()=>({props:[]}),html:(e,t,n)=>{const{exp:s,loc:o}=e;return s||n.onError(jd(53,o)),t.children.length&&(n.onError(jd(54,o)),t.children.length=0),{props:[ra(ia("innerHTML",!0,o),s||ia("",!0))]}},text:(e,t,n)=>{const{exp:s,loc:o}=e;return s||n.onError(jd(55,o)),t.children.length&&(n.onError(jd(56,o)),t.children.length=0),{props:[ra(ia("textContent",!0),s?Au(s,n)>0?s:ca(n.helperString(Pc),[s],o):ia("",!0))]}},model:(e,t,n)=>{const s=Cd(e,t,n);if(!s.props.length||1===t.tagType)return s;e.arg&&n.onError(jd(58,e.arg.loc));const{tag:o}=t,r=n.isCustomElement(o);if("input"===o||"textarea"===o||"select"===o||r){let i=Id,l=!1;if("input"===o||r){const s=Fa(t,"type");if(s){if(7===s.type)i=Od;else if(s.value)switch(s.value.content){case"radio":i=Ad;break;case"checkbox":i=Ed;break;case"file":l=!0,n.onError(jd(59,e.loc))}}else(function(e){return e.props.some((e=>!(7!==e.type||"bind"!==e.name||e.arg&&4===e.arg.type&&e.arg.isStatic)))})(t)&&(i=Od)}else"select"===o&&(i=Rd);l||(s.needRuntime=n.helper(i))}else n.onError(jd(57,e.loc));return s.props=s.props.filter((e=>!(4===e.key.type&&"modelValue"===e.key.content))),s},on:(e,t,n)=>vd(e,t,n,(t=>{const{modifiers:s}=e;if(!s.length)return t;let{key:o,value:r}=t.props[0];const{keyModifiers:i,nonKeyModifiers:l,eventOptionModifiers:c}=((e,t,n,s)=>{const o=[],r=[],i=[];for(let l=0;l{const{exp:s,loc:o}=e;return s||n.onError(jd(61,o)),{props:[],needRuntime:n.helper(Md)}}};const Qd=new WeakMap;function Zd(e,n){if(!g(e)){if(!e.nodeType)return s;e=e.innerHTML}const o=e,r=function(e){let n=Qd.get(null!=e?e:t);return n||(n=Object.create(null),Qd.set(null!=e?e:t,n)),n}(n),i=r[o];if(i)return i;if("#"===e[0]){const t=document.querySelector(e);e=t?t.innerHTML:""}const c=l({hoistStatic:!0,onError:void 0,onWarn:s},n);c.isCustomElement||"undefined"==typeof customElements||(c.isCustomElement=e=>!!customElements.get(e));const{code:a}=function(e,t={}){return Nd(e,l({},Dd,t,{nodeTransforms:[Gd,...Jd,...t.nodeTransforms||[]],directiveTransforms:l({},Xd,t.directiveTransforms||{}),transformHoist:null}))}(e,c),u=new Function("Vue",a)(fc);return u._rc=!0,r[o]=u}fi(Zd);export{_s as BaseTransition,bs as BaseTransitionPropsValidators,wr as Comment,Li as DeprecationTypes,ce as EffectScope,sn as ErrorCodes,Ai as ErrorTypeStrings,kr as Fragment,Os as KeepAlive,he as ReactiveEffect,Nr as Static,Xn as Suspense,xr as Teleport,Tr as Text,en as TrackOpTypes,Ui as Transition,Fl as TransitionGroup,tn as TriggerOpTypes,wl as VueElement,nn as assertNumber,rn as callWithAsyncErrorHandling,on as callWithErrorHandling,E as camelize,O as capitalize,Kr as cloneVNode,Fi as compatUtils,Zd as compile,_i as computed,ac as createApp,Pr as createBlock,Jr as createCommentVNode,Mr as createElementBlock,Hr as createElementVNode,ur as createHydrationRenderer,xo as createPropsRestProxy,ar as createRenderer,uc as createSSRApp,Ys as createSlots,Gr as createStaticVNode,zr as createTextVNode,qr as createVNode,Gt as customRef,Es as defineAsyncComponent,Ns as defineComponent,Cl as defineCustomElement,ao as defineEmits,uo as defineExpose,fo as defineModel,po as defineOptions,co as defineProps,kl as defineSSRCustomElement,ho as defineSlots,Ei as devtools,ye as effect,ae as effectScope,oi as getCurrentInstance,de as getCurrentScope,ws as getTransitionRawChildren,Wr as guardReactiveProps,xi as h,ln as handleError,jo as hasInjectionContext,cc as hydrate,Ci as initCustomFormatter,hc as initDirectivesForSSR,Uo as inject,Ti as isMemoSame,Et as isProxy,wt as isReactive,Nt as isReadonly,$t as isRef,mi as isRuntimeOnly,At as isShallow,$r as isVNode,Rt as markRaw,_o as mergeDefaults,So as mergeModels,Yr as mergeProps,vn as nextTick,z as normalizeClass,G as normalizeProps,j as normalizeStyle,Ls as onActivated,js as onBeforeMount,Ks as onBeforeUnmount,qs as onBeforeUpdate,Ms as onDeactivated,Qs as onErrorCaptured,Hs as onMounted,Xs as onRenderTracked,Js as onRenderTriggered,pe as onScopeDispose,Gs as onServerPrefetch,zs as onUnmounted,Ws as onUpdated,Ir as openBlock,Fn as popScopeId,Do as provide,Kt as proxyRefs,On as pushScopeId,_n as queuePostFlushCb,St as reactive,Ct as readonly,Bt as ref,fi as registerRuntimeCompiler,lc as render,Zs as renderList,eo as renderSlot,jn as resolveComponent,Wn as resolveDirective,qn as resolveDynamicComponent,Oi as resolveFilter,xs as resolveTransitionHooks,Fr as setBlockTracking,Ii as setDevtoolsHook,Ts as setTransitionHooks,xt as shallowReactive,kt as shallowReadonly,Vt as shallowRef,ns as ssrContextKey,Ri as ssrUtils,be as stop,se as toDisplayString,F as toHandlerKey,no as toHandlers,It as toRaw,Zt as toRef,Jt as toRefs,qt as toValue,Vr as transformVNodeArgs,jt as triggerRef,Ht as unref,vo as useAttrs,Nl as useCssModule,ll as useCssVars,Si as useModel,ss as useSSRContext,go as useSlots,vs as useTransitionState,jl as vModelCheckbox,Jl as vModelDynamic,ql as vModelRadio,Wl as vModelSelect,Ul as vModelText,ol as vShow,wi as version,Ni as warn,cs as watch,os as watchEffect,rs as watchPostEffect,is as watchSyncEffect,Co as withAsyncContext,Mn as withCtx,mo as withDefaults,hs as withDirectives,tc as withKeys,ki as withMemo,Yl as withModifiers,Ln as withScopeId}; diff --git a/MyApp/wwwroot/lib/mjs/vue.mjs b/MyApp/wwwroot/lib/mjs/vue.mjs index 87cc0a4..a02c7bc 100644 --- a/MyApp/wwwroot/lib/mjs/vue.mjs +++ b/MyApp/wwwroot/lib/mjs/vue.mjs @@ -1,10 +1,11 @@ +/** +* vue v3.4.15 +* (c) 2018-present Yuxi (Evan) You and Vue contributors +* @license MIT +**/ function makeMap(str, expectsLowerCase) { - const map = /* @__PURE__ */ Object.create(null); - const list = str.split(","); - for (let i = 0; i < list.length; i++) { - map[list[i]] = true; - } - return expectsLowerCase ? (val) => !!map[val.toLowerCase()] : (val) => !!map[val]; + const set = new Set(str.split(",")); + return expectsLowerCase ? (val) => set.has(val.toLowerCase()) : (val) => set.has(val); } const EMPTY_OBJ = Object.freeze({}) ; @@ -12,8 +13,8 @@ const EMPTY_ARR = Object.freeze([]) ; const NOOP = () => { }; const NO = () => false; -const onRE = /^on[^a-z]/; -const isOn = (key) => onRE.test(key); +const isOn = (key) => key.charCodeAt(0) === 111 && key.charCodeAt(1) === 110 && // uppercase letter +(key.charCodeAt(2) > 122 || key.charCodeAt(2) < 97); const isModelListener = (key) => key.startsWith("onUpdate:"); const extend = Object.assign; const remove = (arr, el) => { @@ -104,7 +105,7 @@ const PatchFlagNames = { [4]: `STYLE`, [8]: `PROPS`, [16]: `FULL_PROPS`, - [32]: `HYDRATE_EVENTS`, + [32]: `NEED_HYDRATION`, [64]: `STABLE_FRAGMENT`, [128]: `KEYED_FRAGMENT`, [256]: `UNKEYED_FRAGMENT`, @@ -121,7 +122,7 @@ const slotFlagsText = { [3]: "FORWARDED" }; -const GLOBALS_ALLOWED = "Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt,console"; +const GLOBALS_ALLOWED = "Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt,console,Error"; const isGloballyAllowed = /* @__PURE__ */ makeMap(GLOBALS_ALLOWED); const range = 2; @@ -194,6 +195,20 @@ function parseStringStyle(cssText) { }); return ret; } +function stringifyStyle(styles) { + let ret = ""; + if (!styles || isString(styles)) { + return ret; + } + for (const key in styles) { + const value = styles[key]; + const normalizedKey = key.startsWith(`--`) ? key : hyphenate(key); + if (isString(value) || typeof value === "number") { + ret += `${normalizedKey}:${value};`; + } + } + return ret; +} function normalizeClass(value) { let res = ""; if (isString(value)) { @@ -229,16 +244,34 @@ function normalizeProps(props) { const HTML_TAGS = "html,body,base,head,link,meta,style,title,address,article,aside,footer,header,hgroup,h1,h2,h3,h4,h5,h6,nav,section,div,dd,dl,dt,figcaption,figure,picture,hr,img,li,main,ol,p,pre,ul,a,b,abbr,bdi,bdo,br,cite,code,data,dfn,em,i,kbd,mark,q,rp,rt,ruby,s,samp,small,span,strong,sub,sup,time,u,var,wbr,area,audio,map,track,video,embed,object,param,source,canvas,script,noscript,del,ins,caption,col,colgroup,table,thead,tbody,td,th,tr,button,datalist,fieldset,form,input,label,legend,meter,optgroup,option,output,progress,select,textarea,details,dialog,menu,summary,template,blockquote,iframe,tfoot"; const SVG_TAGS = "svg,animate,animateMotion,animateTransform,circle,clipPath,color-profile,defs,desc,discard,ellipse,feBlend,feColorMatrix,feComponentTransfer,feComposite,feConvolveMatrix,feDiffuseLighting,feDisplacementMap,feDistantLight,feDropShadow,feFlood,feFuncA,feFuncB,feFuncG,feFuncR,feGaussianBlur,feImage,feMerge,feMergeNode,feMorphology,feOffset,fePointLight,feSpecularLighting,feSpotLight,feTile,feTurbulence,filter,foreignObject,g,hatch,hatchpath,image,line,linearGradient,marker,mask,mesh,meshgradient,meshpatch,meshrow,metadata,mpath,path,pattern,polygon,polyline,radialGradient,rect,set,solidcolor,stop,switch,symbol,text,textPath,title,tspan,unknown,use,view"; +const MATH_TAGS = "annotation,annotation-xml,maction,maligngroup,malignmark,math,menclose,merror,mfenced,mfrac,mfraction,mglyph,mi,mlabeledtr,mlongdiv,mmultiscripts,mn,mo,mover,mpadded,mphantom,mprescripts,mroot,mrow,ms,mscarries,mscarry,msgroup,msline,mspace,msqrt,msrow,mstack,mstyle,msub,msubsup,msup,mtable,mtd,mtext,mtr,munder,munderover,none,semantics"; const VOID_TAGS = "area,base,br,col,embed,hr,img,input,link,meta,param,source,track,wbr"; const isHTMLTag = /* @__PURE__ */ makeMap(HTML_TAGS); const isSVGTag = /* @__PURE__ */ makeMap(SVG_TAGS); +const isMathMLTag = /* @__PURE__ */ makeMap(MATH_TAGS); const isVoidTag = /* @__PURE__ */ makeMap(VOID_TAGS); const specialBooleanAttrs = `itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly`; const isSpecialBooleanAttr = /* @__PURE__ */ makeMap(specialBooleanAttrs); +const isBooleanAttr = /* @__PURE__ */ makeMap( + specialBooleanAttrs + `,async,autofocus,autoplay,controls,default,defer,disabled,hidden,inert,loop,open,required,reversed,scoped,seamless,checked,muted,multiple,selected` +); function includeBooleanAttr(value) { return !!value || value === ""; } +const isKnownHtmlAttr = /* @__PURE__ */ makeMap( + `accept,accept-charset,accesskey,action,align,allow,alt,async,autocapitalize,autocomplete,autofocus,autoplay,background,bgcolor,border,buffered,capture,challenge,charset,checked,cite,class,code,codebase,color,cols,colspan,content,contenteditable,contextmenu,controls,coords,crossorigin,csp,data,datetime,decoding,default,defer,dir,dirname,disabled,download,draggable,dropzone,enctype,enterkeyhint,for,form,formaction,formenctype,formmethod,formnovalidate,formtarget,headers,height,hidden,high,href,hreflang,http-equiv,icon,id,importance,inert,integrity,ismap,itemprop,keytype,kind,label,lang,language,loading,list,loop,low,manifest,max,maxlength,minlength,media,min,multiple,muted,name,novalidate,open,optimum,pattern,ping,placeholder,poster,preload,radiogroup,readonly,referrerpolicy,rel,required,reversed,rows,rowspan,sandbox,scope,scoped,selected,shape,size,sizes,slot,span,spellcheck,src,srcdoc,srclang,srcset,start,step,style,summary,tabindex,target,title,translate,type,usemap,value,width,wrap` +); +const isKnownSvgAttr = /* @__PURE__ */ makeMap( + `xmlns,accent-height,accumulate,additive,alignment-baseline,alphabetic,amplitude,arabic-form,ascent,attributeName,attributeType,azimuth,baseFrequency,baseline-shift,baseProfile,bbox,begin,bias,by,calcMode,cap-height,class,clip,clipPathUnits,clip-path,clip-rule,color,color-interpolation,color-interpolation-filters,color-profile,color-rendering,contentScriptType,contentStyleType,crossorigin,cursor,cx,cy,d,decelerate,descent,diffuseConstant,direction,display,divisor,dominant-baseline,dur,dx,dy,edgeMode,elevation,enable-background,end,exponent,fill,fill-opacity,fill-rule,filter,filterRes,filterUnits,flood-color,flood-opacity,font-family,font-size,font-size-adjust,font-stretch,font-style,font-variant,font-weight,format,from,fr,fx,fy,g1,g2,glyph-name,glyph-orientation-horizontal,glyph-orientation-vertical,glyphRef,gradientTransform,gradientUnits,hanging,height,href,hreflang,horiz-adv-x,horiz-origin-x,id,ideographic,image-rendering,in,in2,intercept,k,k1,k2,k3,k4,kernelMatrix,kernelUnitLength,kerning,keyPoints,keySplines,keyTimes,lang,lengthAdjust,letter-spacing,lighting-color,limitingConeAngle,local,marker-end,marker-mid,marker-start,markerHeight,markerUnits,markerWidth,mask,maskContentUnits,maskUnits,mathematical,max,media,method,min,mode,name,numOctaves,offset,opacity,operator,order,orient,orientation,origin,overflow,overline-position,overline-thickness,panose-1,paint-order,path,pathLength,patternContentUnits,patternTransform,patternUnits,ping,pointer-events,points,pointsAtX,pointsAtY,pointsAtZ,preserveAlpha,preserveAspectRatio,primitiveUnits,r,radius,referrerPolicy,refX,refY,rel,rendering-intent,repeatCount,repeatDur,requiredExtensions,requiredFeatures,restart,result,rotate,rx,ry,scale,seed,shape-rendering,slope,spacing,specularConstant,specularExponent,speed,spreadMethod,startOffset,stdDeviation,stemh,stemv,stitchTiles,stop-color,stop-opacity,strikethrough-position,strikethrough-thickness,string,stroke,stroke-dasharray,stroke-dashoffset,stroke-linecap,stroke-linejoin,stroke-miterlimit,stroke-opacity,stroke-width,style,surfaceScale,systemLanguage,tabindex,tableValues,target,targetX,targetY,text-anchor,text-decoration,text-rendering,textLength,to,transform,transform-origin,type,u1,u2,underline-position,underline-thickness,unicode,unicode-bidi,unicode-range,units-per-em,v-alphabetic,v-hanging,v-ideographic,v-mathematical,values,vector-effect,version,vert-adv-y,vert-origin-x,vert-origin-y,viewBox,viewTarget,visibility,width,widths,word-spacing,writing-mode,x,x-height,x1,x2,xChannelSelector,xlink:actuate,xlink:arcrole,xlink:href,xlink:role,xlink:show,xlink:title,xlink:type,xmlns:xlink,xml:base,xml:lang,xml:space,y,y1,y2,yChannelSelector,z,zoomAndPan` +); +function isRenderableAttrValue(value) { + if (value == null) { + return false; + } + const type = typeof value; + return type === "string" || type === "number" || type === "boolean"; +} function looseCompareArrays(a, b) { if (a.length !== b.length) @@ -300,22 +333,31 @@ const replacer = (_key, val) => { return replacer(_key, val.value); } else if (isMap(val)) { return { - [`Map(${val.size})`]: [...val.entries()].reduce((entries, [key, val2]) => { - entries[`${key} =>`] = val2; - return entries; - }, {}) + [`Map(${val.size})`]: [...val.entries()].reduce( + (entries, [key, val2], i) => { + entries[stringifySymbol(key, i) + " =>"] = val2; + return entries; + }, + {} + ) }; } else if (isSet(val)) { return { - [`Set(${val.size})`]: [...val.values()] + [`Set(${val.size})`]: [...val.values()].map((v) => stringifySymbol(v)) }; + } else if (isSymbol(val)) { + return stringifySymbol(val); } else if (isObject(val) && !isArray(val) && !isPlainObject(val)) { return String(val); } return val; }; +const stringifySymbol = (v, i = "") => { + var _a; + return isSymbol(v) ? `Symbol(${(_a = v.description) != null ? _a : i})` : v; +}; -function warn$1(msg, ...args) { +function warn$2(msg, ...args) { console.warn(`[Vue warn] ${msg}`, ...args); } @@ -355,7 +397,7 @@ class EffectScope { activeEffectScope = currentEffectScope; } } else { - warn$1(`cannot run an inactive effect scope.`); + warn$2(`cannot run an inactive effect scope.`); } } /** @@ -413,123 +455,127 @@ function onScopeDispose(fn) { if (activeEffectScope) { activeEffectScope.cleanups.push(fn); } else { - warn$1( + warn$2( `onScopeDispose() is called when there is no active effect scope to be associated with.` ); } } -const createDep = (effects) => { - const dep = new Set(effects); - dep.w = 0; - dep.n = 0; - return dep; -}; -const wasTracked = (dep) => (dep.w & trackOpBit) > 0; -const newTracked = (dep) => (dep.n & trackOpBit) > 0; -const initDepMarkers = ({ deps }) => { - if (deps.length) { - for (let i = 0; i < deps.length; i++) { - deps[i].w |= trackOpBit; - } - } -}; -const finalizeDepMarkers = (effect) => { - const { deps } = effect; - if (deps.length) { - let ptr = 0; - for (let i = 0; i < deps.length; i++) { - const dep = deps[i]; - if (wasTracked(dep) && !newTracked(dep)) { - dep.delete(effect); - } else { - deps[ptr++] = dep; - } - dep.w &= ~trackOpBit; - dep.n &= ~trackOpBit; - } - deps.length = ptr; - } -}; - -const targetMap = /* @__PURE__ */ new WeakMap(); -let effectTrackDepth = 0; -let trackOpBit = 1; -const maxMarkerBits = 30; let activeEffect; -const ITERATE_KEY = Symbol("iterate" ); -const MAP_KEY_ITERATE_KEY = Symbol("Map key iterate" ); class ReactiveEffect { - constructor(fn, scheduler = null, scope) { + constructor(fn, trigger, scheduler, scope) { this.fn = fn; + this.trigger = trigger; this.scheduler = scheduler; this.active = true; this.deps = []; - this.parent = void 0; + /** + * @internal + */ + this._dirtyLevel = 2; + /** + * @internal + */ + this._trackId = 0; + /** + * @internal + */ + this._runnings = 0; + /** + * @internal + */ + this._shouldSchedule = false; + /** + * @internal + */ + this._depsLength = 0; recordEffectScope(this, scope); } + get dirty() { + if (this._dirtyLevel === 1) { + pauseTracking(); + for (let i = 0; i < this._depsLength; i++) { + const dep = this.deps[i]; + if (dep.computed) { + triggerComputed(dep.computed); + if (this._dirtyLevel >= 2) { + break; + } + } + } + if (this._dirtyLevel < 2) { + this._dirtyLevel = 0; + } + resetTracking(); + } + return this._dirtyLevel >= 2; + } + set dirty(v) { + this._dirtyLevel = v ? 2 : 0; + } run() { + this._dirtyLevel = 0; if (!this.active) { return this.fn(); } - let parent = activeEffect; let lastShouldTrack = shouldTrack; - while (parent) { - if (parent === this) { - return; - } - parent = parent.parent; - } + let lastEffect = activeEffect; try { - this.parent = activeEffect; - activeEffect = this; shouldTrack = true; - trackOpBit = 1 << ++effectTrackDepth; - if (effectTrackDepth <= maxMarkerBits) { - initDepMarkers(this); - } else { - cleanupEffect(this); - } + activeEffect = this; + this._runnings++; + preCleanupEffect(this); return this.fn(); } finally { - if (effectTrackDepth <= maxMarkerBits) { - finalizeDepMarkers(this); - } - trackOpBit = 1 << --effectTrackDepth; - activeEffect = this.parent; + postCleanupEffect(this); + this._runnings--; + activeEffect = lastEffect; shouldTrack = lastShouldTrack; - this.parent = void 0; - if (this.deferStop) { - this.stop(); - } } } stop() { - if (activeEffect === this) { - this.deferStop = true; - } else if (this.active) { - cleanupEffect(this); - if (this.onStop) { - this.onStop(); - } + var _a; + if (this.active) { + preCleanupEffect(this); + postCleanupEffect(this); + (_a = this.onStop) == null ? void 0 : _a.call(this); this.active = false; } } } -function cleanupEffect(effect2) { - const { deps } = effect2; - if (deps.length) { - for (let i = 0; i < deps.length; i++) { - deps[i].delete(effect2); +function triggerComputed(computed) { + return computed.value; +} +function preCleanupEffect(effect2) { + effect2._trackId++; + effect2._depsLength = 0; +} +function postCleanupEffect(effect2) { + if (effect2.deps && effect2.deps.length > effect2._depsLength) { + for (let i = effect2._depsLength; i < effect2.deps.length; i++) { + cleanupDepEffect(effect2.deps[i], effect2); + } + effect2.deps.length = effect2._depsLength; + } +} +function cleanupDepEffect(dep, effect2) { + const trackId = dep.get(effect2); + if (trackId !== void 0 && effect2._trackId !== trackId) { + dep.delete(effect2); + if (dep.size === 0) { + dep.cleanup(); } - deps.length = 0; } } function effect(fn, options) { if (fn.effect instanceof ReactiveEffect) { fn = fn.effect.fn; } - const _effect = new ReactiveEffect(fn); + const _effect = new ReactiveEffect(fn, NOOP, () => { + if (_effect.dirty) { + _effect.run(); + } + }); if (options) { extend(_effect, options); if (options.scope) @@ -546,6 +592,7 @@ function stop(runner) { runner.effect.stop(); } let shouldTrack = true; +let pauseScheduleStack = 0; const trackStack = []; function pauseTracking() { trackStack.push(shouldTrack); @@ -555,6 +602,72 @@ function resetTracking() { const last = trackStack.pop(); shouldTrack = last === void 0 ? true : last; } +function pauseScheduling() { + pauseScheduleStack++; +} +function resetScheduling() { + pauseScheduleStack--; + while (!pauseScheduleStack && queueEffectSchedulers.length) { + queueEffectSchedulers.shift()(); + } +} +function trackEffect(effect2, dep, debuggerEventExtraInfo) { + var _a; + if (dep.get(effect2) !== effect2._trackId) { + dep.set(effect2, effect2._trackId); + const oldDep = effect2.deps[effect2._depsLength]; + if (oldDep !== dep) { + if (oldDep) { + cleanupDepEffect(oldDep, effect2); + } + effect2.deps[effect2._depsLength++] = dep; + } else { + effect2._depsLength++; + } + { + (_a = effect2.onTrack) == null ? void 0 : _a.call(effect2, extend({ effect: effect2 }, debuggerEventExtraInfo)); + } + } +} +const queueEffectSchedulers = []; +function triggerEffects(dep, dirtyLevel, debuggerEventExtraInfo) { + var _a; + pauseScheduling(); + for (const effect2 of dep.keys()) { + if (effect2._dirtyLevel < dirtyLevel && dep.get(effect2) === effect2._trackId) { + const lastDirtyLevel = effect2._dirtyLevel; + effect2._dirtyLevel = dirtyLevel; + if (lastDirtyLevel === 0) { + effect2._shouldSchedule = true; + { + (_a = effect2.onTrigger) == null ? void 0 : _a.call(effect2, extend({ effect: effect2 }, debuggerEventExtraInfo)); + } + effect2.trigger(); + } + } + } + scheduleEffects(dep); + resetScheduling(); +} +function scheduleEffects(dep) { + for (const effect2 of dep.keys()) { + if (effect2.scheduler && effect2._shouldSchedule && (!effect2._runnings || effect2.allowRecurse) && dep.get(effect2) === effect2._trackId) { + effect2._shouldSchedule = false; + queueEffectSchedulers.push(effect2.scheduler); + } + } +} + +const createDep = (cleanup, computed) => { + const dep = /* @__PURE__ */ new Map(); + dep.cleanup = cleanup; + dep.computed = computed; + return dep; +}; + +const targetMap = /* @__PURE__ */ new WeakMap(); +const ITERATE_KEY = Symbol("iterate" ); +const MAP_KEY_ITERATE_KEY = Symbol("Map key iterate" ); function track(target, type, key) { if (shouldTrack && activeEffect) { let depsMap = targetMap.get(target); @@ -563,35 +676,17 @@ function track(target, type, key) { } let dep = depsMap.get(key); if (!dep) { - depsMap.set(key, dep = createDep()); - } - const eventInfo = { effect: activeEffect, target, type, key } ; - trackEffects(dep, eventInfo); - } -} -function trackEffects(dep, debuggerEventExtraInfo) { - let shouldTrack2 = false; - if (effectTrackDepth <= maxMarkerBits) { - if (!newTracked(dep)) { - dep.n |= trackOpBit; - shouldTrack2 = !wasTracked(dep); - } - } else { - shouldTrack2 = !dep.has(activeEffect); - } - if (shouldTrack2) { - dep.add(activeEffect); - activeEffect.deps.push(dep); - if (activeEffect.onTrack) { - activeEffect.onTrack( - extend( - { - effect: activeEffect - }, - debuggerEventExtraInfo - ) - ); + depsMap.set(key, dep = createDep(() => depsMap.delete(key))); } + trackEffect( + activeEffect, + dep, + { + target, + type, + key + } + ); } } function trigger(target, type, key, newValue, oldValue, oldTarget) { @@ -639,49 +734,24 @@ function trigger(target, type, key, newValue, oldValue, oldTarget) { break; } } - const eventInfo = { target, type, key, newValue, oldValue, oldTarget } ; - if (deps.length === 1) { - if (deps[0]) { - { - triggerEffects(deps[0], eventInfo); - } - } - } else { - const effects = []; - for (const dep of deps) { - if (dep) { - effects.push(...dep); - } - } - { - triggerEffects(createDep(effects), eventInfo); - } - } -} -function triggerEffects(dep, debuggerEventExtraInfo) { - const effects = isArray(dep) ? dep : [...dep]; - for (const effect2 of effects) { - if (effect2.computed) { - triggerEffect(effect2, debuggerEventExtraInfo); - } - } - for (const effect2 of effects) { - if (!effect2.computed) { - triggerEffect(effect2, debuggerEventExtraInfo); - } - } -} -function triggerEffect(effect2, debuggerEventExtraInfo) { - if (effect2 !== activeEffect || effect2.allowRecurse) { - if (effect2.onTrigger) { - effect2.onTrigger(extend({ effect: effect2 }, debuggerEventExtraInfo)); - } - if (effect2.scheduler) { - effect2.scheduler(); - } else { - effect2.run(); + pauseScheduling(); + for (const dep of deps) { + if (dep) { + triggerEffects( + dep, + 2, + { + target, + type, + key, + newValue, + oldValue, + oldTarget + } + ); } } + resetScheduling(); } function getDepFromReactive(object, key) { var _a; @@ -712,7 +782,9 @@ function createArrayInstrumentations() { ["push", "pop", "shift", "unshift", "splice"].forEach((key) => { instrumentations[key] = function(...args) { pauseTracking(); + pauseScheduling(); const res = toRaw(this)[key].apply(this, args); + resetScheduling(); resetTracking(); return res; }; @@ -737,8 +809,13 @@ class BaseReactiveHandler { return isReadonly2; } else if (key === "__v_isShallow") { return shallow; - } else if (key === "__v_raw" && receiver === (isReadonly2 ? shallow ? shallowReadonlyMap : readonlyMap : shallow ? shallowReactiveMap : reactiveMap).get(target)) { - return target; + } else if (key === "__v_raw") { + if (receiver === (isReadonly2 ? shallow ? shallowReadonlyMap : readonlyMap : shallow ? shallowReactiveMap : reactiveMap).get(target) || // receiver is not the reactive proxy, but has the same prototype + // this means the reciever is a user proxy of the reactive proxy + Object.getPrototypeOf(target) === Object.getPrototypeOf(receiver)) { + return target; + } + return; } const targetIsArray = isArray(target); if (!isReadonly2) { @@ -774,17 +851,19 @@ class MutableReactiveHandler extends BaseReactiveHandler { } set(target, key, value, receiver) { let oldValue = target[key]; - if (isReadonly(oldValue) && isRef(oldValue) && !isRef(value)) { - return false; - } if (!this._shallow) { + const isOldValueReadonly = isReadonly(oldValue); if (!isShallow(value) && !isReadonly(value)) { oldValue = toRaw(oldValue); value = toRaw(value); } if (!isArray(target) && isRef(oldValue) && !isRef(value)) { - oldValue.value = value; - return true; + if (isOldValueReadonly) { + return false; + } else { + oldValue.value = value; + return true; + } } } const hadKey = isArray(target) && isIntegerKey(key) ? Number(key) < target.length : hasOwn(target, key); @@ -829,7 +908,7 @@ class ReadonlyReactiveHandler extends BaseReactiveHandler { } set(target, key) { { - warn$1( + warn$2( `Set operation on key "${String(key)}" failed: target is readonly.`, target ); @@ -838,7 +917,7 @@ class ReadonlyReactiveHandler extends BaseReactiveHandler { } deleteProperty(target, key) { { - warn$1( + warn$2( `Delete operation on key "${String(key)}" failed: target is readonly.`, target ); @@ -1001,7 +1080,7 @@ function createReadonlyMethod(type) { toRaw(this) ); } - return type === "delete" ? false : this; + return type === "delete" ? false : type === "clear" ? void 0 : this; }; } function createInstrumentations() { @@ -1251,30 +1330,98 @@ function markRaw(value) { const toReactive = (value) => isObject(value) ? reactive(value) : value; const toReadonly = (value) => isObject(value) ? readonly(value) : value; +class ComputedRefImpl { + constructor(getter, _setter, isReadonly, isSSR) { + this._setter = _setter; + this.dep = void 0; + this.__v_isRef = true; + this["__v_isReadonly"] = false; + this.effect = new ReactiveEffect( + () => getter(this._value), + () => triggerRefValue(this, 1), + () => this.dep && scheduleEffects(this.dep) + ); + this.effect.computed = this; + this.effect.active = this._cacheable = !isSSR; + this["__v_isReadonly"] = isReadonly; + } + get value() { + const self = toRaw(this); + if (!self._cacheable || self.effect.dirty) { + if (hasChanged(self._value, self._value = self.effect.run())) { + triggerRefValue(self, 2); + } + } + trackRefValue(self); + if (self.effect._dirtyLevel >= 1) { + triggerRefValue(self, 1); + } + return self._value; + } + set value(newValue) { + this._setter(newValue); + } + // #region polyfill _dirty for backward compatibility third party code for Vue <= 3.3.x + get _dirty() { + return this.effect.dirty; + } + set _dirty(v) { + this.effect.dirty = v; + } + // #endregion +} +function computed$1(getterOrOptions, debugOptions, isSSR = false) { + let getter; + let setter; + const onlyGetter = isFunction(getterOrOptions); + if (onlyGetter) { + getter = getterOrOptions; + setter = () => { + console.warn("Write operation failed: computed value is readonly"); + } ; + } else { + getter = getterOrOptions.get; + setter = getterOrOptions.set; + } + const cRef = new ComputedRefImpl(getter, setter, onlyGetter || !setter, isSSR); + if (debugOptions && !isSSR) { + cRef.effect.onTrack = debugOptions.onTrack; + cRef.effect.onTrigger = debugOptions.onTrigger; + } + return cRef; +} + function trackRefValue(ref2) { if (shouldTrack && activeEffect) { ref2 = toRaw(ref2); - { - trackEffects(ref2.dep || (ref2.dep = createDep()), { + trackEffect( + activeEffect, + ref2.dep || (ref2.dep = createDep( + () => ref2.dep = void 0, + ref2 instanceof ComputedRefImpl ? ref2 : void 0 + )), + { target: ref2, type: "get", key: "value" - }); - } + } + ); } } -function triggerRefValue(ref2, newVal) { +function triggerRefValue(ref2, dirtyLevel = 2, newVal) { ref2 = toRaw(ref2); const dep = ref2.dep; if (dep) { - { - triggerEffects(dep, { + triggerEffects( + dep, + dirtyLevel, + { target: ref2, type: "set", key: "value", newValue: newVal - }); - } + } + ); } } function isRef(r) { @@ -1310,12 +1457,12 @@ class RefImpl { if (hasChanged(newVal, this._rawValue)) { this._rawValue = newVal; this._value = useDirectValue ? newVal : toReactive(newVal); - triggerRefValue(this, newVal); + triggerRefValue(this, 2, newVal); } } } function triggerRef(ref2) { - triggerRefValue(ref2, ref2.value ); + triggerRefValue(ref2, 2, ref2.value ); } function unref(ref2) { return isRef(ref2) ? ref2.value : ref2; @@ -1413,67 +1560,28 @@ function propertyToRef(source, key, defaultValue) { return isRef(val) ? val : new ObjectRefImpl(source, key, defaultValue); } -class ComputedRefImpl { - constructor(getter, _setter, isReadonly, isSSR) { - this._setter = _setter; - this.dep = void 0; - this.__v_isRef = true; - this["__v_isReadonly"] = false; - this._dirty = true; - this.effect = new ReactiveEffect(getter, () => { - if (!this._dirty) { - this._dirty = true; - triggerRefValue(this); - } - }); - this.effect.computed = this; - this.effect.active = this._cacheable = !isSSR; - this["__v_isReadonly"] = isReadonly; - } - get value() { - const self = toRaw(this); - trackRefValue(self); - if (self._dirty || !self._cacheable) { - self._dirty = false; - self._value = self.effect.run(); - } - return self._value; - } - set value(newValue) { - this._setter(newValue); - } -} -function computed$1(getterOrOptions, debugOptions, isSSR = false) { - let getter; - let setter; - const onlyGetter = isFunction(getterOrOptions); - if (onlyGetter) { - getter = getterOrOptions; - setter = () => { - console.warn("Write operation failed: computed value is readonly"); - } ; - } else { - getter = getterOrOptions.get; - setter = getterOrOptions.set; - } - const cRef = new ComputedRefImpl(getter, setter, onlyGetter || !setter, isSSR); - if (debugOptions && !isSSR) { - cRef.effect.onTrack = debugOptions.onTrack; - cRef.effect.onTrigger = debugOptions.onTrigger; - } - return cRef; -} +const TrackOpTypes = { + "GET": "get", + "HAS": "has", + "ITERATE": "iterate" +}; +const TriggerOpTypes = { + "SET": "set", + "ADD": "add", + "DELETE": "delete", + "CLEAR": "clear" +}; -const stack = []; +const stack$1 = []; function pushWarningContext(vnode) { - stack.push(vnode); + stack$1.push(vnode); } function popWarningContext() { - stack.pop(); + stack$1.pop(); } -function warn(msg, ...args) { +function warn$1(msg, ...args) { pauseTracking(); - const instance = stack.length ? stack[stack.length - 1].component : null; + const instance = stack$1.length ? stack$1[stack$1.length - 1].component : null; const appWarnHandler = instance && instance.appContext.config.warnHandler; const trace = getComponentTrace(); if (appWarnHandler) { @@ -1502,7 +1610,7 @@ function warn(msg, ...args) { resetTracking(); } function getComponentTrace() { - let currentVNode = stack[stack.length - 1]; + let currentVNode = stack$1[stack$1.length - 1]; if (!currentVNode) { return []; } @@ -1572,13 +1680,45 @@ function assertNumber(val, type) { if (val === void 0) { return; } else if (typeof val !== "number") { - warn(`${type} is not a valid number - got ${JSON.stringify(val)}.`); + warn$1(`${type} is not a valid number - got ${JSON.stringify(val)}.`); } else if (isNaN(val)) { - warn(`${type} is NaN - the duration expression might be incorrect.`); + warn$1(`${type} is NaN - the duration expression might be incorrect.`); } } -const ErrorTypeStrings = { +const ErrorCodes = { + "SETUP_FUNCTION": 0, + "0": "SETUP_FUNCTION", + "RENDER_FUNCTION": 1, + "1": "RENDER_FUNCTION", + "WATCH_GETTER": 2, + "2": "WATCH_GETTER", + "WATCH_CALLBACK": 3, + "3": "WATCH_CALLBACK", + "WATCH_CLEANUP": 4, + "4": "WATCH_CLEANUP", + "NATIVE_EVENT_HANDLER": 5, + "5": "NATIVE_EVENT_HANDLER", + "COMPONENT_EVENT_HANDLER": 6, + "6": "COMPONENT_EVENT_HANDLER", + "VNODE_HOOK": 7, + "7": "VNODE_HOOK", + "DIRECTIVE_HOOK": 8, + "8": "DIRECTIVE_HOOK", + "TRANSITION_HOOK": 9, + "9": "TRANSITION_HOOK", + "APP_ERROR_HANDLER": 10, + "10": "APP_ERROR_HANDLER", + "APP_WARN_HANDLER": 11, + "11": "APP_WARN_HANDLER", + "FUNCTION_REF": 12, + "12": "FUNCTION_REF", + "ASYNC_COMPONENT_LOADER": 13, + "13": "ASYNC_COMPONENT_LOADER", + "SCHEDULER": 14, + "14": "SCHEDULER" +}; +const ErrorTypeStrings$1 = { ["sp"]: "serverPrefetch hook", ["bc"]: "beforeCreate hook", ["c"]: "created hook", @@ -1607,7 +1747,7 @@ const ErrorTypeStrings = { [11]: "app warnHandler", [12]: "ref function", [13]: "async component loader", - [14]: "scheduler flush. This is likely a Vue internals bug. Please open an issue at https://new-issue.vuejs.org/?repo=vuejs/core" + [14]: "scheduler flush. This is likely a Vue internals bug. Please open an issue at https://github.com/vuejs/core ." }; function callWithErrorHandling(fn, instance, type, args) { let res; @@ -1639,7 +1779,7 @@ function handleError(err, instance, type, throwInDev = true) { if (instance) { let cur = instance.parent; const exposedInstance = instance.proxy; - const errorInfo = ErrorTypeStrings[type] ; + const errorInfo = ErrorTypeStrings$1[type] ; while (cur) { const errorCapturedHooks = cur.ec; if (errorCapturedHooks) { @@ -1666,11 +1806,11 @@ function handleError(err, instance, type, throwInDev = true) { } function logError(err, type, contextVNode, throwInDev = true) { { - const info = ErrorTypeStrings[type]; + const info = ErrorTypeStrings$1[type]; if (contextVNode) { pushWarningContext(contextVNode); } - warn(`Unhandled error${info ? ` during execution of ${info}` : ``}`); + warn$1(`Unhandled error${info ? ` during execution of ${info}` : ``}`); if (contextVNode) { popWarningContext(); } @@ -1749,13 +1889,16 @@ function queuePostFlushCb(cb) { } queueFlush(); } -function flushPreFlushCbs(seen, i = isFlushing ? flushIndex + 1 : 0) { +function flushPreFlushCbs(instance, seen, i = isFlushing ? flushIndex + 1 : 0) { { seen = seen || /* @__PURE__ */ new Map(); } for (; i < queue.length; i++) { const cb = queue[i]; if (cb && cb.pre) { + if (instance && cb.id !== instance.uid) { + continue; + } if (checkRecursiveUpdates(seen, cb)) { continue; } @@ -1767,7 +1910,9 @@ function flushPreFlushCbs(seen, i = isFlushing ? flushIndex + 1 : 0) { } function flushPostFlushCbs(seen) { if (pendingPostFlushCbs.length) { - const deduped = [...new Set(pendingPostFlushCbs)]; + const deduped = [...new Set(pendingPostFlushCbs)].sort( + (a, b) => getId(a) - getId(b) + ); pendingPostFlushCbs.length = 0; if (activePostFlushCbs) { activePostFlushCbs.push(...deduped); @@ -1777,7 +1922,6 @@ function flushPostFlushCbs(seen) { { seen = seen || /* @__PURE__ */ new Map(); } - activePostFlushCbs.sort((a, b) => getId(a) - getId(b)); for (postFlushIndex = 0; postFlushIndex < activePostFlushCbs.length; postFlushIndex++) { if (checkRecursiveUpdates(seen, activePostFlushCbs[postFlushIndex])) { continue; @@ -1836,8 +1980,10 @@ function checkRecursiveUpdates(seen, fn) { if (count > RECURSION_LIMIT) { const instance = fn.ownerInstance; const componentName = instance && getComponentName(instance.type); - warn( - `Maximum recursive updates exceeded${componentName ? ` in component <${componentName}>` : ``}. This means you have a reactive effect that is mutating its own dependencies and thus recursively triggering itself. Possible sources include component template, render function, updated hook or watcher source function.` + handleError( + `Maximum recursive updates exceeded${componentName ? ` in component <${componentName}>` : ``}. This means you have a reactive effect that is mutating its own dependencies and thus recursively triggering itself. Possible sources include component template, render function, updated hook or watcher source function.`, + null, + 10 ); return true; } else { @@ -1894,6 +2040,7 @@ function rerender(id, newRender) { } instance.renderCache = []; isHmrUpdating = true; + instance.effect.dirty = true; instance.update(); isHmrUpdating = false; }); @@ -1921,6 +2068,7 @@ function reload(id, newComp) { instance.ceReload(newComp.styles); hmrDirtyComponents.delete(oldComp); } else if (instance.parent) { + instance.parent.effect.dirty = true; queueJob(instance.parent.update); } else if (instance.appContext.reload) { instance.appContext.reload(); @@ -1961,22 +2109,22 @@ function tryWrap(fn) { }; } -let devtools; +let devtools$1; let buffer = []; let devtoolsNotInstalled = false; function emit$1(event, ...args) { - if (devtools) { - devtools.emit(event, ...args); + if (devtools$1) { + devtools$1.emit(event, ...args); } else if (!devtoolsNotInstalled) { buffer.push({ event, args }); } } -function setDevtoolsHook(hook, target) { +function setDevtoolsHook$1(hook, target) { var _a, _b; - devtools = hook; - if (devtools) { - devtools.enabled = true; - buffer.forEach(({ event, args }) => devtools.emit(event, ...args)); + devtools$1 = hook; + if (devtools$1) { + devtools$1.enabled = true; + buffer.forEach(({ event, args }) => devtools$1.emit(event, ...args)); buffer = []; } else if ( // handle late devtools injection - only do this if we are in an actual @@ -1988,10 +2136,10 @@ function setDevtoolsHook(hook, target) { ) { const replay = target.__VUE_DEVTOOLS_HOOK_REPLAY__ = target.__VUE_DEVTOOLS_HOOK_REPLAY__ || []; replay.push((newHook) => { - setDevtoolsHook(newHook, target); + setDevtoolsHook$1(newHook, target); }); setTimeout(() => { - if (!devtools) { + if (!devtools$1) { target.__VUE_DEVTOOLS_HOOK_REPLAY__ = null; devtoolsNotInstalled = true; buffer = []; @@ -2021,8 +2169,8 @@ const _devtoolsComponentRemoved = /* @__PURE__ */ createDevtoolsComponentHook( "component:removed" /* COMPONENT_REMOVED */ ); const devtoolsComponentRemoved = (component) => { - if (devtools && typeof devtools.cleanupBuffer === "function" && // remove the component if it wasn't buffered - !devtools.cleanupBuffer(component)) { + if (devtools$1 && typeof devtools$1.cleanupBuffer === "function" && // remove the component if it wasn't buffered + !devtools$1.cleanupBuffer(component)) { _devtoolsComponentRemoved(component); } }; @@ -2070,7 +2218,7 @@ function emit(instance, event, ...rawArgs) { if (emitsOptions) { if (!(event in emitsOptions) && true) { if (!propsOptions || !(toHandlerKey(event) in propsOptions)) { - warn( + warn$1( `Component emitted event "${event}" but it is neither declared in the emits option nor as an "${toHandlerKey(event)}" prop.` ); } @@ -2079,7 +2227,7 @@ function emit(instance, event, ...rawArgs) { if (isFunction(validator)) { const isValid = validator(...rawArgs); if (!isValid) { - warn( + warn$1( `Invalid event arguments: event validation failed for event "${event}".` ); } @@ -2106,11 +2254,13 @@ function emit(instance, event, ...rawArgs) { { const lowerCaseEvent = event.toLowerCase(); if (lowerCaseEvent !== event && props[toHandlerKey(lowerCaseEvent)]) { - warn( + warn$1( `Event "${lowerCaseEvent}" is emitted in component ${formatComponentName( instance, instance.type - )} but the handler is registered for "${event}". Note that HTML attributes are case-insensitive and you cannot use v-on to listen to camelCase events when using in-DOM templates. You should probably use "${hyphenate(event)}" instead of "${event}".` + )} but the handler is registered for "${event}". Note that HTML attributes are case-insensitive and you cannot use v-on to listen to camelCase events when using in-DOM templates. You should probably use "${hyphenate( + event + )}" instead of "${event}".` ); } } @@ -2272,9 +2422,19 @@ function renderComponentRoot(instance) { try { if (vnode.shapeFlag & 4) { const proxyToUse = withProxy || proxy; + const thisProxy = setupState.__isScriptSetup ? new Proxy(proxyToUse, { + get(target, key, receiver) { + warn$1( + `Property '${String( + key + )}' was accessed via 'this'. Avoid using 'this' in templates.` + ); + return Reflect.get(target, key, receiver); + } + }) : proxyToUse; result = normalizeVNode( render.call( - proxyToUse, + thisProxy, proxyToUse, renderCache, props, @@ -2345,12 +2505,12 @@ function renderComponentRoot(instance) { } } if (extraAttrs.length) { - warn( + warn$1( `Extraneous non-props attributes (${extraAttrs.join(", ")}) were passed to component but could not be automatically inherited because component renders fragment or text root nodes.` ); } if (eventAttrs.length) { - warn( + warn$1( `Extraneous non-emits event listeners (${eventAttrs.join(", ")}) were passed to component but could not be automatically inherited because component renders fragment or text root nodes. If the listener is intended to be a component custom event listener only, declare it using the "emits" option.` ); } @@ -2359,7 +2519,7 @@ function renderComponentRoot(instance) { } if (vnode.dirs) { if (!isElementRoot(root)) { - warn( + warn$1( `Runtime directive used on component with non-element root node. The directives will not function as intended.` ); } @@ -2368,7 +2528,7 @@ function renderComponentRoot(instance) { } if (vnode.transition) { if (!isElementRoot(root)) { - warn( + warn$1( `Component inside renders non-element root node that cannot be animated.` ); } @@ -2385,9 +2545,11 @@ function renderComponentRoot(instance) { const getChildRoot = (vnode) => { const rawChildren = vnode.children; const dynamicChildren = vnode.dynamicChildren; - const childRoot = filterSingleRoot(rawChildren); + const childRoot = filterSingleRoot(rawChildren, false); if (!childRoot) { return [vnode, void 0]; + } else if (childRoot.patchFlag > 0 && childRoot.patchFlag & 2048) { + return getChildRoot(childRoot); } const index = rawChildren.indexOf(childRoot); const dynamicIndex = dynamicChildren ? dynamicChildren.indexOf(childRoot) : -1; @@ -2403,7 +2565,7 @@ const getChildRoot = (vnode) => { }; return [normalizeVNode(childRoot), setRoot]; }; -function filterSingleRoot(children) { +function filterSingleRoot(children, recurse = true) { let singleRoot; for (let i = 0; i < children.length; i++) { const child = children[i]; @@ -2413,6 +2575,9 @@ function filterSingleRoot(children) { return; } else { singleRoot = child; + if (recurse && singleRoot.patchFlag > 0 && singleRoot.patchFlag & 2048) { + return filterSingleRoot(singleRoot.children); + } } } } else { @@ -2503,13 +2668,76 @@ function hasPropsChanged(prevProps, nextProps, emitsOptions) { return false; } function updateHOCHostEl({ vnode, parent }, el) { - while (parent && parent.subTree === vnode) { - (vnode = parent.vnode).el = el; - parent = parent.parent; + while (parent) { + const root = parent.subTree; + if (root.suspense && root.suspense.activeBranch === vnode) { + root.el = vnode.el; + } + if (root === vnode) { + (vnode = parent.vnode).el = el; + parent = parent.parent; + } else { + break; + } + } +} + +const COMPONENTS = "components"; +const DIRECTIVES = "directives"; +function resolveComponent(name, maybeSelfReference) { + return resolveAsset(COMPONENTS, name, true, maybeSelfReference) || name; +} +const NULL_DYNAMIC_COMPONENT = Symbol.for("v-ndc"); +function resolveDynamicComponent(component) { + if (isString(component)) { + return resolveAsset(COMPONENTS, component, false) || component; + } else { + return component || NULL_DYNAMIC_COMPONENT; + } +} +function resolveDirective(name) { + return resolveAsset(DIRECTIVES, name); +} +function resolveAsset(type, name, warnMissing = true, maybeSelfReference = false) { + const instance = currentRenderingInstance || currentInstance; + if (instance) { + const Component = instance.type; + if (type === COMPONENTS) { + const selfName = getComponentName( + Component, + false + ); + if (selfName && (selfName === name || selfName === camelize(name) || selfName === capitalize(camelize(name)))) { + return Component; + } + } + const res = ( + // local registration + // check instance[type] first which is resolved for options API + resolve(instance[type] || Component[type], name) || // global registration + resolve(instance.appContext[type], name) + ); + if (!res && maybeSelfReference) { + return Component; + } + if (warnMissing && !res) { + const extra = type === COMPONENTS ? ` +If this is a native custom element, make sure to exclude it from component resolution via compilerOptions.isCustomElement.` : ``; + warn$1(`Failed to resolve ${type.slice(0, -1)}: ${name}${extra}`); + } + return res; + } else { + warn$1( + `resolve${capitalize(type.slice(0, -1))} can only be used in render() or setup().` + ); } } +function resolve(registry, name) { + return registry && (registry[name] || registry[camelize(name)] || registry[capitalize(camelize(name))]); +} const isSuspense = (type) => type.__isSuspense; +let suspenseId = 0; const SuspenseImpl = { name: "Suspense", // In order to make Suspense tree-shakable, we need to avoid importing it @@ -2517,7 +2745,7 @@ const SuspenseImpl = { // on a vnode's type and calls the `process` method, passing in renderer // internals. __isSuspense: true, - process(n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, rendererInternals) { + process(n1, n2, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized, rendererInternals) { if (n1 == null) { mountSuspense( n2, @@ -2525,19 +2753,23 @@ const SuspenseImpl = { anchor, parentComponent, parentSuspense, - isSVG, + namespace, slotScopeIds, optimized, rendererInternals ); } else { + if (parentSuspense && parentSuspense.deps > 0) { + n2.suspense = n1.suspense; + return; + } patchSuspense( n1, n2, container, anchor, parentComponent, - isSVG, + namespace, slotScopeIds, optimized, rendererInternals @@ -2555,7 +2787,7 @@ function triggerEvent(vnode, name) { eventListener(); } } -function mountSuspense(vnode, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, rendererInternals) { +function mountSuspense(vnode, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized, rendererInternals) { const { p: patch, o: { createElement } @@ -2568,7 +2800,7 @@ function mountSuspense(vnode, container, anchor, parentComponent, parentSuspense container, hiddenContainer, anchor, - isSVG, + namespace, slotScopeIds, optimized, rendererInternals @@ -2580,7 +2812,7 @@ function mountSuspense(vnode, container, anchor, parentComponent, parentSuspense null, parentComponent, suspense, - isSVG, + namespace, slotScopeIds ); if (suspense.deps > 0) { @@ -2594,7 +2826,7 @@ function mountSuspense(vnode, container, anchor, parentComponent, parentSuspense parentComponent, null, // fallback tree will not have suspense context - isSVG, + namespace, slotScopeIds ); setActiveBranch(suspense, vnode.ssFallback); @@ -2602,7 +2834,7 @@ function mountSuspense(vnode, container, anchor, parentComponent, parentSuspense suspense.resolve(false, true); } } -function patchSuspense(n1, n2, container, anchor, parentComponent, isSVG, slotScopeIds, optimized, { p: patch, um: unmount, o: { createElement } }) { +function patchSuspense(n1, n2, container, anchor, parentComponent, namespace, slotScopeIds, optimized, { p: patch, um: unmount, o: { createElement } }) { const suspense = n2.suspense = n1.suspense; suspense.vnode = n2; n2.el = n1.el; @@ -2619,29 +2851,31 @@ function patchSuspense(n1, n2, container, anchor, parentComponent, isSVG, slotSc null, parentComponent, suspense, - isSVG, + namespace, slotScopeIds, optimized ); if (suspense.deps <= 0) { suspense.resolve(); } else if (isInFallback) { - patch( - activeBranch, - newFallback, - container, - anchor, - parentComponent, - null, - // fallback tree will not have suspense context - isSVG, - slotScopeIds, - optimized - ); - setActiveBranch(suspense, newFallback); + if (!isHydrating) { + patch( + activeBranch, + newFallback, + container, + anchor, + parentComponent, + null, + // fallback tree will not have suspense context + namespace, + slotScopeIds, + optimized + ); + setActiveBranch(suspense, newFallback); + } } } else { - suspense.pendingId++; + suspense.pendingId = suspenseId++; if (isHydrating) { suspense.isHydrating = false; suspense.activeBranch = pendingBranch; @@ -2659,7 +2893,7 @@ function patchSuspense(n1, n2, container, anchor, parentComponent, isSVG, slotSc null, parentComponent, suspense, - isSVG, + namespace, slotScopeIds, optimized ); @@ -2674,7 +2908,7 @@ function patchSuspense(n1, n2, container, anchor, parentComponent, isSVG, slotSc parentComponent, null, // fallback tree will not have suspense context - isSVG, + namespace, slotScopeIds, optimized ); @@ -2688,7 +2922,7 @@ function patchSuspense(n1, n2, container, anchor, parentComponent, isSVG, slotSc anchor, parentComponent, suspense, - isSVG, + namespace, slotScopeIds, optimized ); @@ -2701,7 +2935,7 @@ function patchSuspense(n1, n2, container, anchor, parentComponent, isSVG, slotSc null, parentComponent, suspense, - isSVG, + namespace, slotScopeIds, optimized ); @@ -2719,7 +2953,7 @@ function patchSuspense(n1, n2, container, anchor, parentComponent, isSVG, slotSc anchor, parentComponent, suspense, - isSVG, + namespace, slotScopeIds, optimized ); @@ -2727,7 +2961,11 @@ function patchSuspense(n1, n2, container, anchor, parentComponent, isSVG, slotSc } else { triggerEvent(n2, "onPending"); suspense.pendingBranch = newBranch; - suspense.pendingId++; + if (newBranch.shapeFlag & 512) { + suspense.pendingId = newBranch.component.suspenseId; + } else { + suspense.pendingId = suspenseId++; + } patch( null, newBranch, @@ -2735,7 +2973,7 @@ function patchSuspense(n1, n2, container, anchor, parentComponent, isSVG, slotSc null, parentComponent, suspense, - isSVG, + namespace, slotScopeIds, optimized ); @@ -2757,7 +2995,7 @@ function patchSuspense(n1, n2, container, anchor, parentComponent, isSVG, slotSc } } let hasWarned = false; -function createSuspenseBoundary(vnode, parentSuspense, parentComponent, container, hiddenContainer, anchor, isSVG, slotScopeIds, optimized, rendererInternals, isHydrating = false) { +function createSuspenseBoundary(vnode, parentSuspense, parentComponent, container, hiddenContainer, anchor, namespace, slotScopeIds, optimized, rendererInternals, isHydrating = false) { if (!hasWarned) { hasWarned = true; console[console.info ? "info" : "log"]( @@ -2783,20 +3021,20 @@ function createSuspenseBoundary(vnode, parentSuspense, parentComponent, containe { assertNumber(timeout, `Suspense timeout`); } + const initialAnchor = anchor; const suspense = { vnode, parent: parentSuspense, parentComponent, - isSVG, + namespace, container, hiddenContainer, - anchor, deps: 0, - pendingId: 0, + pendingId: suspenseId++, timeout: typeof timeout === "number" ? timeout : -1, activeBranch: null, pendingBranch: null, - isInFallback: true, + isInFallback: !isHydrating, isHydrating, isUnmounted: false, effects: [], @@ -2830,18 +3068,24 @@ function createSuspenseBoundary(vnode, parentSuspense, parentComponent, containe if (delayEnter) { activeBranch.transition.afterLeave = () => { if (pendingId === suspense.pendingId) { - move(pendingBranch, container2, anchor2, 0); + move( + pendingBranch, + container2, + anchor === initialAnchor ? next(activeBranch) : anchor, + 0 + ); queuePostFlushCb(effects); } }; } - let { anchor: anchor2 } = suspense; if (activeBranch) { - anchor2 = next(activeBranch); + if (parentNode(activeBranch.el) !== suspense.hiddenContainer) { + anchor = next(activeBranch); + } unmount(activeBranch, parentComponent2, suspense, true); } if (!delayEnter) { - move(pendingBranch, container2, anchor2, 0); + move(pendingBranch, container2, anchor, 0); } } setActiveBranch(suspense, pendingBranch); @@ -2875,7 +3119,7 @@ function createSuspenseBoundary(vnode, parentSuspense, parentComponent, containe if (!suspense.pendingBranch) { return; } - const { vnode: vnode2, activeBranch, parentComponent: parentComponent2, container: container2, isSVG: isSVG2 } = suspense; + const { vnode: vnode2, activeBranch, parentComponent: parentComponent2, container: container2, namespace: namespace2 } = suspense; triggerEvent(vnode2, "onFallback"); const anchor2 = next(activeBranch); const mountFallback = () => { @@ -2890,7 +3134,7 @@ function createSuspenseBoundary(vnode, parentSuspense, parentComponent, containe parentComponent2, null, // fallback tree will not have suspense context - isSVG2, + namespace2, slotScopeIds, optimized ); @@ -2953,7 +3197,7 @@ function createSuspenseBoundary(vnode, parentSuspense, parentComponent, containe // consider the comment placeholder case. hydratedEl ? null : next(instance.subTree), suspense, - isSVG, + namespace, optimized ); if (placeholder) { @@ -2990,20 +3234,20 @@ function createSuspenseBoundary(vnode, parentSuspense, parentComponent, containe }; return suspense; } -function hydrateSuspense(node, vnode, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, rendererInternals, hydrateNode) { +function hydrateSuspense(node, vnode, parentComponent, parentSuspense, namespace, slotScopeIds, optimized, rendererInternals, hydrateNode) { const suspense = vnode.suspense = createSuspenseBoundary( vnode, parentSuspense, parentComponent, node.parentNode, + // eslint-disable-next-line no-restricted-globals document.createElement("div"), null, - isSVG, + namespace, slotScopeIds, optimized, rendererInternals, true - /* hydrating */ ); const result = hydrateNode( node, @@ -3043,8 +3287,8 @@ function normalizeSuspenseSlot(s) { } if (isArray(s)) { const singleChild = filterSingleRoot(s); - if (!singleChild) { - warn(` slots expect a single root node.`); + if (!singleChild && s.filter((child) => child !== NULL_DYNAMIC_COMPONENT).length > 0) { + warn$1(` slots expect a single root node.`); } s = singleChild; } @@ -3068,7 +3312,12 @@ function queueEffectWithSuspense(fn, suspense) { function setActiveBranch(suspense, branch) { suspense.activeBranch = branch; const { vnode, parentComponent } = suspense; - const el = vnode.el = branch.el; + let el = branch.el; + while (!el && branch.component) { + branch = branch.component.subTree; + el = branch.el; + } + vnode.el = el; if (parentComponent && parentComponent.subTree === vnode) { parentComponent.vnode.el = el; updateHOCHostEl(parentComponent, el); @@ -3079,6 +3328,19 @@ function isVNodeSuspensible(vnode) { return ((_a = vnode.props) == null ? void 0 : _a.suspensible) != null && vnode.props.suspensible !== false; } +const ssrContextKey = Symbol.for("v-scx"); +const useSSRContext = () => { + { + const ctx = inject(ssrContextKey); + if (!ctx) { + warn$1( + `Server rendering context not provided. Make sure to only call useSSRContext() conditionally in the server build.` + ); + } + return ctx; + } +}; + function watchEffect(effect, options) { return doWatch(effect, null, options); } @@ -3099,34 +3361,61 @@ function watchSyncEffect(effect, options) { const INITIAL_WATCHER_VALUE = {}; function watch(source, cb, options) { if (!isFunction(cb)) { - warn( + warn$1( `\`watch(fn, options?)\` signature has been moved to a separate API. Use \`watchEffect(fn, options?)\` instead. \`watch\` now only supports \`watch(source, cb, options?) signature.` ); } return doWatch(source, cb, options); } -function doWatch(source, cb, { immediate, deep, flush, onTrack, onTrigger } = EMPTY_OBJ) { - var _a; +function doWatch(source, cb, { + immediate, + deep, + flush, + once, + onTrack, + onTrigger +} = EMPTY_OBJ) { + if (cb && once) { + const _cb = cb; + cb = (...args) => { + _cb(...args); + unwatch(); + }; + } + if (deep !== void 0 && typeof deep === "number") { + warn$1( + `watch() "deep" option with number value will be used as watch depth in future versions. Please use a boolean instead to avoid potential breakage.` + ); + } if (!cb) { if (immediate !== void 0) { - warn( + warn$1( `watch() "immediate" option is only respected when using the watch(source, callback, options?) signature.` ); } if (deep !== void 0) { - warn( + warn$1( `watch() "deep" option is only respected when using the watch(source, callback, options?) signature.` ); } + if (once !== void 0) { + warn$1( + `watch() "once" option is only respected when using the watch(source, callback, options?) signature.` + ); + } } const warnInvalidSource = (s) => { - warn( + warn$1( `Invalid watch source: `, s, `A watch source can only be a getter/effect function, a ref, a reactive object, or an array of these types.` ); }; - const instance = getCurrentScope() === ((_a = currentInstance) == null ? void 0 : _a.scope) ? currentInstance : null; + const instance = currentInstance; + const reactiveGetter = (source2) => deep === true ? source2 : ( + // for deep: false, only traverse root-level properties + traverse(source2, deep === false ? 1 : void 0) + ); let getter; let forceTrigger = false; let isMultiSource = false; @@ -3134,8 +3423,8 @@ function doWatch(source, cb, { immediate, deep, flush, onTrack, onTrigger } = EM getter = () => source.value; forceTrigger = isShallow(source); } else if (isReactive(source)) { - getter = () => source; - deep = true; + getter = () => reactiveGetter(source); + forceTrigger = true; } else if (isArray(source)) { isMultiSource = true; forceTrigger = source.some((s) => isReactive(s) || isShallow(s)); @@ -3143,7 +3432,7 @@ function doWatch(source, cb, { immediate, deep, flush, onTrack, onTrigger } = EM if (isRef(s)) { return s.value; } else if (isReactive(s)) { - return traverse(s); + return reactiveGetter(s); } else if (isFunction(s)) { return callWithErrorHandling(s, instance, 2); } else { @@ -3155,9 +3444,6 @@ function doWatch(source, cb, { immediate, deep, flush, onTrack, onTrigger } = EM getter = () => callWithErrorHandling(source, instance, 2); } else { getter = () => { - if (instance && instance.isUnmounted) { - return; - } if (cleanup) { cleanup(); } @@ -3181,11 +3467,12 @@ function doWatch(source, cb, { immediate, deep, flush, onTrack, onTrigger } = EM let onCleanup = (fn) => { cleanup = effect.onStop = () => { callWithErrorHandling(fn, instance, 4); + cleanup = effect.onStop = void 0; }; }; let oldValue = isMultiSource ? new Array(source.length).fill(INITIAL_WATCHER_VALUE) : INITIAL_WATCHER_VALUE; const job = () => { - if (!effect.active) { + if (!effect.active || !effect.dirty) { return; } if (cb) { @@ -3218,7 +3505,14 @@ function doWatch(source, cb, { immediate, deep, flush, onTrack, onTrigger } = EM job.id = instance.uid; scheduler = () => queueJob(job); } - const effect = new ReactiveEffect(getter, scheduler); + const effect = new ReactiveEffect(getter, NOOP, scheduler); + const scope = getCurrentScope(); + const unwatch = () => { + effect.stop(); + if (scope) { + remove(scope.effects, effect); + } + }; { effect.onTrack = onTrack; effect.onTrigger = onTrigger; @@ -3237,12 +3531,6 @@ function doWatch(source, cb, { immediate, deep, flush, onTrack, onTrigger } = EM } else { effect.run(); } - const unwatch = () => { - effect.stop(); - if (instance && instance.scope) { - remove(instance.scope.effects, effect); - } - }; return unwatch; } function instanceWatch(source, value, options) { @@ -3255,14 +3543,9 @@ function instanceWatch(source, value, options) { cb = value.handler; options = value; } - const cur = currentInstance; - setCurrentInstance(this); + const reset = setCurrentInstance(this); const res = doWatch(getter, cb.bind(publicThis), options); - if (cur) { - setCurrentInstance(cur); - } else { - unsetCurrentInstance(); - } + reset(); return res; } function createPathGetter(ctx, path) { @@ -3275,28 +3558,34 @@ function createPathGetter(ctx, path) { return cur; }; } -function traverse(value, seen) { +function traverse(value, depth, currentDepth = 0, seen) { if (!isObject(value) || value["__v_skip"]) { return value; } + if (depth && depth > 0) { + if (currentDepth >= depth) { + return value; + } + currentDepth++; + } seen = seen || /* @__PURE__ */ new Set(); if (seen.has(value)) { return value; } seen.add(value); if (isRef(value)) { - traverse(value.value, seen); + traverse(value.value, depth, currentDepth, seen); } else if (isArray(value)) { for (let i = 0; i < value.length; i++) { - traverse(value[i], seen); + traverse(value[i], depth, currentDepth, seen); } } else if (isSet(value) || isMap(value)) { value.forEach((v) => { - traverse(v, seen); + traverse(v, depth, currentDepth, seen); }); } else if (isPlainObject(value)) { for (const key in value) { - traverse(value[key], seen); + traverse(value[key], depth, currentDepth, seen); } } return value; @@ -3304,16 +3593,15 @@ function traverse(value, seen) { function validateDirectiveName(name) { if (isBuiltInDirective(name)) { - warn("Do not use built-in directive ids as custom directive id: " + name); + warn$1("Do not use built-in directive ids as custom directive id: " + name); } } function withDirectives(vnode, directives) { - const internalInstance = currentRenderingInstance; - if (internalInstance === null) { - warn(`withDirectives can only be used inside render functions.`); + if (currentRenderingInstance === null) { + warn$1(`withDirectives can only be used inside render functions.`); return vnode; } - const instance = getExposeProxy(internalInstance) || internalInstance.proxy; + const instance = getExposeProxy(currentRenderingInstance) || currentRenderingInstance.proxy; const bindings = vnode.dirs || (vnode.dirs = []); for (let i = 0; i < directives.length; i++) { let [dir, value, arg, modifiers = EMPTY_OBJ] = directives[i]; @@ -3417,7 +3705,7 @@ const BaseTransitionImpl = { for (const c of children) { if (c.type !== Comment) { if (hasFound) { - warn( + warn$1( " can only be used on a single element or component. Use for lists." ); break; @@ -3430,7 +3718,7 @@ const BaseTransitionImpl = { const rawProps = toRaw(props); const { mode } = rawProps; if (mode && mode !== "in-out" && mode !== "out-in" && mode !== "default") { - warn(`invalid mode: ${mode}`); + warn$1(`invalid mode: ${mode}`); } if (state.isLeaving) { return emptyPlaceholder(child); @@ -3472,6 +3760,7 @@ const BaseTransitionImpl = { leavingHooks.afterLeave = () => { state.isLeaving = false; if (instance.update.active !== false) { + instance.effect.dirty = true; instance.update(); } }; @@ -3651,7 +3940,11 @@ function emptyPlaceholder(vnode) { } } function getKeepAliveChild(vnode) { - return isKeepAlive(vnode) ? vnode.children ? vnode.children[0] : void 0 : vnode; + return isKeepAlive(vnode) ? ( + // #7121 ensure get the child component subtree in case + // it's been replaced during HMR + vnode.component ? vnode.component.subTree : vnode.children ? vnode.children[0] : void 0 + ) : vnode; } function setTransitionHooks(vnode, hooks) { if (vnode.shapeFlag & 6 && vnode.component) { @@ -3740,7 +4033,7 @@ function defineAsyncComponent(source) { return pendingRequest; } if (!comp) { - warn( + warn$1( `Async component loader resolved to undefined. If you are using retry(), make sure to return its return value.` ); } @@ -3772,7 +4065,6 @@ function defineAsyncComponent(source) { instance, 13, !errorComponent - /* do not throw in dev if user provided error component */ ); }; if (suspensible && instance.suspense || false) { @@ -3807,6 +4099,7 @@ function defineAsyncComponent(source) { load().then(() => { loaded.value = true; if (instance.parent && isKeepAlive(instance.parent.vnode)) { + instance.parent.effect.dirty = true; queueJob(instance.parent.update); } }).catch((err) => { @@ -3867,7 +4160,7 @@ const KeepAliveImpl = { } } = sharedContext; const storageContainer = createElement("div"); - sharedContext.activate = (vnode, container, anchor, isSVG, optimized) => { + sharedContext.activate = (vnode, container, anchor, namespace, optimized) => { const instance2 = vnode.component; move(vnode, container, anchor, 0, parentSuspense); patch( @@ -3877,7 +4170,7 @@ const KeepAliveImpl = { anchor, instance2, parentSuspense, - isSVG, + namespace, vnode.slotScopeIds, optimized ); @@ -3973,7 +4266,7 @@ const KeepAliveImpl = { const rawVNode = children[0]; if (children.length > 1) { { - warn(`KeepAlive should contain exactly one component child.`); + warn$1(`KeepAlive should contain exactly one component child.`); } current = null; return children; @@ -4088,9 +4381,9 @@ function injectHook(type, hook, target = currentInstance, prepend = false) { return; } pauseTracking(); - setCurrentInstance(target); + const reset = setCurrentInstance(target); const res = callWithAsyncErrorHandling(hook, target, type, args); - unsetCurrentInstance(); + reset(); resetTracking(); return res; }); @@ -4101,8 +4394,8 @@ function injectHook(type, hook, target = currentInstance, prepend = false) { } return wrappedHook; } else { - const apiName = toHandlerKey(ErrorTypeStrings[type].replace(/ hook$/, "")); - warn( + const apiName = toHandlerKey(ErrorTypeStrings$1[type].replace(/ hook$/, "")); + warn$1( `${apiName} is called when there is no active component instance to be associated with. Lifecycle injection APIs can only be used during execution of setup().` + (` If you are using async setup(), make sure to register lifecycle hooks before the first await statement.` ) ); } @@ -4128,61 +4421,6 @@ function onErrorCaptured(hook, target = currentInstance) { injectHook("ec", hook, target); } -const COMPONENTS = "components"; -const DIRECTIVES = "directives"; -function resolveComponent(name, maybeSelfReference) { - return resolveAsset(COMPONENTS, name, true, maybeSelfReference) || name; -} -const NULL_DYNAMIC_COMPONENT = Symbol.for("v-ndc"); -function resolveDynamicComponent(component) { - if (isString(component)) { - return resolveAsset(COMPONENTS, component, false) || component; - } else { - return component || NULL_DYNAMIC_COMPONENT; - } -} -function resolveDirective(name) { - return resolveAsset(DIRECTIVES, name); -} -function resolveAsset(type, name, warnMissing = true, maybeSelfReference = false) { - const instance = currentRenderingInstance || currentInstance; - if (instance) { - const Component = instance.type; - if (type === COMPONENTS) { - const selfName = getComponentName( - Component, - false - /* do not include inferred name to avoid breaking existing code */ - ); - if (selfName && (selfName === name || selfName === camelize(name) || selfName === capitalize(camelize(name)))) { - return Component; - } - } - const res = ( - // local registration - // check instance[type] first which is resolved for options API - resolve(instance[type] || Component[type], name) || // global registration - resolve(instance.appContext[type], name) - ); - if (!res && maybeSelfReference) { - return Component; - } - if (warnMissing && !res) { - const extra = type === COMPONENTS ? ` -If this is a native custom element, make sure to exclude it from component resolution via compilerOptions.isCustomElement.` : ``; - warn(`Failed to resolve ${type.slice(0, -1)}: ${name}${extra}`); - } - return res; - } else { - warn( - `resolve${capitalize(type.slice(0, -1))} can only be used in render() or setup().` - ); - } -} -function resolve(registry, name) { - return registry && (registry[name] || registry[camelize(name)] || registry[capitalize(camelize(name))]); -} - function renderList(source, renderItem, cache, index) { let ret; const cached = cache && cache[index]; @@ -4193,7 +4431,7 @@ function renderList(source, renderItem, cache, index) { } } else if (typeof source === "number") { if (!Number.isInteger(source)) { - warn(`The v-for range expect an integer value but got ${source}.`); + warn$1(`The v-for range expect an integer value but got ${source}.`); } ret = new Array(source); for (let i = 0; i < source; i++) { @@ -4249,7 +4487,7 @@ function renderSlot(slots, name, props = {}, fallback, noSlotted) { } let slot = slots[name]; if (slot && slot.length > 1) { - warn( + warn$1( `SSR-optimized slot function detected in a non-SSR-optimized render function. You need to mark this component with $dynamic-slots in the parent template.` ); slot = () => []; @@ -4292,7 +4530,7 @@ function ensureValidVNode(vnodes) { function toHandlers(obj, preserveCaseIfNecessary) { const ret = {}; if (!isObject(obj)) { - warn(`v-on with no argument expects an object value.`); + warn$1(`v-on with no argument expects an object value.`); return ret; } for (const key in obj) { @@ -4323,7 +4561,10 @@ const publicPropertiesMap = ( $root: (i) => getPublicInstance(i.root), $emit: (i) => i.emit, $options: (i) => resolveMergedOptions(i) , - $forceUpdate: (i) => i.f || (i.f = () => queueJob(i.update)), + $forceUpdate: (i) => i.f || (i.f = () => { + i.effect.dirty = true; + queueJob(i.update); + }), $nextTick: (i) => i.n || (i.n = nextTick.bind(i.proxy)), $watch: (i) => instanceWatch.bind(i) }) @@ -4399,13 +4640,13 @@ const PublicInstanceProxyHandlers = { // to infinite warning loop key.indexOf("__v") !== 0)) { if (data !== EMPTY_OBJ && isReservedPrefix(key[0]) && hasOwn(data, key)) { - warn( + warn$1( `Property ${JSON.stringify( key )} must be accessed via $data because it starts with a reserved character ("$" or "_") and is not proxied on the render context.` ); } else if (instance === currentRenderingInstance) { - warn( + warn$1( `Property ${JSON.stringify(key)} was accessed during render but is not defined on instance.` ); } @@ -4417,17 +4658,17 @@ const PublicInstanceProxyHandlers = { setupState[key] = value; return true; } else if (setupState.__isScriptSetup && hasOwn(setupState, key)) { - warn(`Cannot mutate