cecomponent 1.0.186 → 1.0.187
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/ce-component-lib.js
CHANGED
|
@@ -35,7 +35,7 @@ Please change the parent <Route path="${C}"> to <Route path="${C==="/"?"*":`${C}
|
|
|
35
35
|
`)}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(t){return t instanceof this?t:new this(t)}static concat(t,...n){const i=new this(t);return n.forEach(o=>i.set(o)),i}static accessor(t){const i=(this[$internals]=this[$internals]={accessors:{}}).accessors,o=this.prototype;function l(u){const f=normalizeHeader(u);i[f]||(buildAccessors(o,u),i[f]=!0)}return utils$2.isArray(t)?t.forEach(l):l(t),this}};AxiosHeaders$1.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);utils$2.reduceDescriptors(AxiosHeaders$1.prototype,({value:e},t)=>{let n=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(i){this[n]=i}}});utils$2.freezeMethods(AxiosHeaders$1);function transformData(e,t){const n=this||defaults$1,i=t||n,o=AxiosHeaders$1.from(i.headers);let l=i.data;return utils$2.forEach(e,function(f){l=f.call(n,l,o.normalize(),t?t.status:void 0)}),o.normalize(),l}function isCancel$1(e){return!!(e&&e.__CANCEL__)}function CanceledError$1(e,t,n){AxiosError$1.call(this,e??"canceled",AxiosError$1.ERR_CANCELED,t,n),this.name="CanceledError"}utils$2.inherits(CanceledError$1,AxiosError$1,{__CANCEL__:!0});function settle(e,t,n){const i=n.config.validateStatus;!n.status||!i||i(n.status)?e(n):t(new AxiosError$1("Request failed with status code "+n.status,[AxiosError$1.ERR_BAD_REQUEST,AxiosError$1.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n))}function parseProtocol(e){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}function speedometer(e,t){e=e||10;const n=new Array(e),i=new Array(e);let o=0,l=0,u;return t=t!==void 0?t:1e3,function(p){const d=Date.now(),m=i[l];u||(u=d),n[o]=p,i[o]=d;let g=l,_=0;for(;g!==o;)_+=n[g++],g=g%e;if(o=(o+1)%e,o===l&&(l=(l+1)%e),d-u<t)return;const S=m&&d-m;return S?Math.round(_*1e3/S):void 0}}function throttle$1(e,t){let n=0,i=1e3/t,o,l;const u=(d,m=Date.now())=>{n=m,o=null,l&&(clearTimeout(l),l=null),e.apply(null,d)};return[(...d)=>{const m=Date.now(),g=m-n;g>=i?u(d,m):(o=d,l||(l=setTimeout(()=>{l=null,u(o)},i-g)))},()=>o&&u(o)]}const progressEventReducer=(e,t,n=3)=>{let i=0;const o=speedometer(50,250);return throttle$1(l=>{const u=l.loaded,f=l.lengthComputable?l.total:void 0,p=u-i,d=o(p),m=u<=f;i=u;const g={loaded:u,total:f,progress:f?u/f:void 0,bytes:p,rate:d||void 0,estimated:d&&f&&m?(f-u)/d:void 0,event:l,lengthComputable:f!=null,[t?"download":"upload"]:!0};e(g)},n)},progressEventDecorator=(e,t)=>{const n=e!=null;return[i=>t[0]({lengthComputable:n,total:e,loaded:i}),t[1]]},asyncDecorator=e=>(...t)=>utils$2.asap(()=>e(...t)),isURLSameOrigin=platform.hasStandardBrowserEnv?((e,t)=>n=>(n=new URL(n,platform.origin),e.protocol===n.protocol&&e.host===n.host&&(t||e.port===n.port)))(new URL(platform.origin),platform.navigator&&/(msie|trident)/i.test(platform.navigator.userAgent)):()=>!0,cookies=platform.hasStandardBrowserEnv?{write(e,t,n,i,o,l){const u=[e+"="+encodeURIComponent(t)];utils$2.isNumber(n)&&u.push("expires="+new Date(n).toGMTString()),utils$2.isString(i)&&u.push("path="+i),utils$2.isString(o)&&u.push("domain="+o),l===!0&&u.push("secure"),document.cookie=u.join("; ")},read(e){const t=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return t?decodeURIComponent(t[3]):null},remove(e){this.write(e,"",Date.now()-864e5)}}:{write(){},read(){return null},remove(){}};function isAbsoluteURL(e){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function combineURLs(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}function buildFullPath(e,t,n){let i=!isAbsoluteURL(t);return e&&(i||n==!1)?combineURLs(e,t):t}const headersToObject=e=>e instanceof AxiosHeaders$1?{...e}:e;function mergeConfig$1(e,t){t=t||{};const n={};function i(d,m,g,_){return utils$2.isPlainObject(d)&&utils$2.isPlainObject(m)?utils$2.merge.call({caseless:_},d,m):utils$2.isPlainObject(m)?utils$2.merge({},m):utils$2.isArray(m)?m.slice():m}function o(d,m,g,_){if(utils$2.isUndefined(m)){if(!utils$2.isUndefined(d))return i(void 0,d,g,_)}else return i(d,m,g,_)}function l(d,m){if(!utils$2.isUndefined(m))return i(void 0,m)}function u(d,m){if(utils$2.isUndefined(m)){if(!utils$2.isUndefined(d))return i(void 0,d)}else return i(void 0,m)}function f(d,m,g){if(g in t)return i(d,m);if(g in e)return i(void 0,d)}const p={url:l,method:l,data:l,baseURL:u,transformRequest:u,transformResponse:u,paramsSerializer:u,timeout:u,timeoutMessage:u,withCredentials:u,withXSRFToken:u,adapter:u,responseType:u,xsrfCookieName:u,xsrfHeaderName:u,onUploadProgress:u,onDownloadProgress:u,decompress:u,maxContentLength:u,maxBodyLength:u,beforeRedirect:u,transport:u,httpAgent:u,httpsAgent:u,cancelToken:u,socketPath:u,responseEncoding:u,validateStatus:f,headers:(d,m,g)=>o(headersToObject(d),headersToObject(m),g,!0)};return utils$2.forEach(Object.keys(Object.assign({},e,t)),function(m){const g=p[m]||o,_=g(e[m],t[m],m);utils$2.isUndefined(_)&&g!==f||(n[m]=_)}),n}const resolveConfig=e=>{const t=mergeConfig$1({},e);let{data:n,withXSRFToken:i,xsrfHeaderName:o,xsrfCookieName:l,headers:u,auth:f}=t;t.headers=u=AxiosHeaders$1.from(u),t.url=buildURL(buildFullPath(t.baseURL,t.url,t.allowAbsoluteUrls),e.params,e.paramsSerializer),f&&u.set("Authorization","Basic "+btoa((f.username||"")+":"+(f.password?unescape(encodeURIComponent(f.password)):"")));let p;if(utils$2.isFormData(n)){if(platform.hasStandardBrowserEnv||platform.hasStandardBrowserWebWorkerEnv)u.setContentType(void 0);else if((p=u.getContentType())!==!1){const[d,...m]=p?p.split(";").map(g=>g.trim()).filter(Boolean):[];u.setContentType([d||"multipart/form-data",...m].join("; "))}}if(platform.hasStandardBrowserEnv&&(i&&utils$2.isFunction(i)&&(i=i(t)),i||i!==!1&&isURLSameOrigin(t.url))){const d=o&&l&&cookies.read(l);d&&u.set(o,d)}return t},isXHRAdapterSupported=typeof XMLHttpRequest<"u",xhrAdapter=isXHRAdapterSupported&&function(e){return new Promise(function(n,i){const o=resolveConfig(e);let l=o.data;const u=AxiosHeaders$1.from(o.headers).normalize();let{responseType:f,onUploadProgress:p,onDownloadProgress:d}=o,m,g,_,S,E;function b(){S&&S(),E&&E(),o.cancelToken&&o.cancelToken.unsubscribe(m),o.signal&&o.signal.removeEventListener("abort",m)}let T=new XMLHttpRequest;T.open(o.method.toUpperCase(),o.url,!0),T.timeout=o.timeout;function C(){if(!T)return;const R=AxiosHeaders$1.from("getAllResponseHeaders"in T&&T.getAllResponseHeaders()),O={data:!f||f==="text"||f==="json"?T.responseText:T.response,status:T.status,statusText:T.statusText,headers:R,config:e,request:T};settle(function(M){n(M),b()},function(M){i(M),b()},O),T=null}"onloadend"in T?T.onloadend=C:T.onreadystatechange=function(){!T||T.readyState!==4||T.status===0&&!(T.responseURL&&T.responseURL.indexOf("file:")===0)||setTimeout(C)},T.onabort=function(){T&&(i(new AxiosError$1("Request aborted",AxiosError$1.ECONNABORTED,e,T)),T=null)},T.onerror=function(){i(new AxiosError$1("Network Error",AxiosError$1.ERR_NETWORK,e,T)),T=null},T.ontimeout=function(){let j=o.timeout?"timeout of "+o.timeout+"ms exceeded":"timeout exceeded";const O=o.transitional||transitionalDefaults;o.timeoutErrorMessage&&(j=o.timeoutErrorMessage),i(new AxiosError$1(j,O.clarifyTimeoutError?AxiosError$1.ETIMEDOUT:AxiosError$1.ECONNABORTED,e,T)),T=null},l===void 0&&u.setContentType(null),"setRequestHeader"in T&&utils$2.forEach(u.toJSON(),function(j,O){T.setRequestHeader(O,j)}),utils$2.isUndefined(o.withCredentials)||(T.withCredentials=!!o.withCredentials),f&&f!=="json"&&(T.responseType=o.responseType),d&&([_,E]=progressEventReducer(d,!0),T.addEventListener("progress",_)),p&&T.upload&&([g,S]=progressEventReducer(p),T.upload.addEventListener("progress",g),T.upload.addEventListener("loadend",S)),(o.cancelToken||o.signal)&&(m=R=>{T&&(i(!R||R.type?new CanceledError$1(null,e,T):R),T.abort(),T=null)},o.cancelToken&&o.cancelToken.subscribe(m),o.signal&&(o.signal.aborted?m():o.signal.addEventListener("abort",m)));const A=parseProtocol(o.url);if(A&&platform.protocols.indexOf(A)===-1){i(new AxiosError$1("Unsupported protocol "+A+":",AxiosError$1.ERR_BAD_REQUEST,e));return}T.send(l||null)})},composeSignals=(e,t)=>{const{length:n}=e=e?e.filter(Boolean):[];if(t||n){let i=new AbortController,o;const l=function(d){if(!o){o=!0,f();const m=d instanceof Error?d:this.reason;i.abort(m instanceof AxiosError$1?m:new CanceledError$1(m instanceof Error?m.message:m))}};let u=t&&setTimeout(()=>{u=null,l(new AxiosError$1(`timeout ${t} of ms exceeded`,AxiosError$1.ETIMEDOUT))},t);const f=()=>{e&&(u&&clearTimeout(u),u=null,e.forEach(d=>{d.unsubscribe?d.unsubscribe(l):d.removeEventListener("abort",l)}),e=null)};e.forEach(d=>d.addEventListener("abort",l));const{signal:p}=i;return p.unsubscribe=()=>utils$2.asap(f),p}},streamChunk=function*(e,t){let n=e.byteLength;if(n<t){yield e;return}let i=0,o;for(;i<n;)o=i+t,yield e.slice(i,o),i=o},readBytes=async function*(e,t){for await(const n of readStream(e))yield*streamChunk(n,t)},readStream=async function*(e){if(e[Symbol.asyncIterator]){yield*e;return}const t=e.getReader();try{for(;;){const{done:n,value:i}=await t.read();if(n)break;yield i}}finally{await t.cancel()}},trackStream=(e,t,n,i)=>{const o=readBytes(e,t);let l=0,u,f=p=>{u||(u=!0,i&&i(p))};return new ReadableStream({async pull(p){try{const{done:d,value:m}=await o.next();if(d){f(),p.close();return}let g=m.byteLength;if(n){let _=l+=g;n(_)}p.enqueue(new Uint8Array(m))}catch(d){throw f(d),d}},cancel(p){return f(p),o.return()}},{highWaterMark:2})},isFetchSupported=typeof fetch=="function"&&typeof Request=="function"&&typeof Response=="function",isReadableStreamSupported=isFetchSupported&&typeof ReadableStream=="function",encodeText=isFetchSupported&&(typeof TextEncoder=="function"?(e=>t=>e.encode(t))(new TextEncoder):async e=>new Uint8Array(await new Response(e).arrayBuffer())),test=(e,...t)=>{try{return!!e(...t)}catch{return!1}},supportsRequestStream=isReadableStreamSupported&&test(()=>{let e=!1;const t=new Request(platform.origin,{body:new ReadableStream,method:"POST",get duplex(){return e=!0,"half"}}).headers.has("Content-Type");return e&&!t}),DEFAULT_CHUNK_SIZE=64*1024,supportsResponseStream=isReadableStreamSupported&&test(()=>utils$2.isReadableStream(new Response("").body)),resolvers={stream:supportsResponseStream&&(e=>e.body)};isFetchSupported&&(e=>{["text","arrayBuffer","blob","formData","stream"].forEach(t=>{!resolvers[t]&&(resolvers[t]=utils$2.isFunction(e[t])?n=>n[t]():(n,i)=>{throw new AxiosError$1(`Response type '${t}' is not supported`,AxiosError$1.ERR_NOT_SUPPORT,i)})})})(new Response);const getBodyLength=async e=>{if(e==null)return 0;if(utils$2.isBlob(e))return e.size;if(utils$2.isSpecCompliantForm(e))return(await new Request(platform.origin,{method:"POST",body:e}).arrayBuffer()).byteLength;if(utils$2.isArrayBufferView(e)||utils$2.isArrayBuffer(e))return e.byteLength;if(utils$2.isURLSearchParams(e)&&(e=e+""),utils$2.isString(e))return(await encodeText(e)).byteLength},resolveBodyLength=async(e,t)=>{const n=utils$2.toFiniteNumber(e.getContentLength());return n??getBodyLength(t)},fetchAdapter=isFetchSupported&&(async e=>{let{url:t,method:n,data:i,signal:o,cancelToken:l,timeout:u,onDownloadProgress:f,onUploadProgress:p,responseType:d,headers:m,withCredentials:g="same-origin",fetchOptions:_}=resolveConfig(e);d=d?(d+"").toLowerCase():"text";let S=composeSignals([o,l&&l.toAbortSignal()],u),E;const b=S&&S.unsubscribe&&(()=>{S.unsubscribe()});let T;try{if(p&&supportsRequestStream&&n!=="get"&&n!=="head"&&(T=await resolveBodyLength(m,i))!==0){let O=new Request(t,{method:"POST",body:i,duplex:"half"}),I;if(utils$2.isFormData(i)&&(I=O.headers.get("content-type"))&&m.setContentType(I),O.body){const[M,N]=progressEventDecorator(T,progressEventReducer(asyncDecorator(p)));i=trackStream(O.body,DEFAULT_CHUNK_SIZE,M,N)}}utils$2.isString(g)||(g=g?"include":"omit");const C="credentials"in Request.prototype;E=new Request(t,{..._,signal:S,method:n.toUpperCase(),headers:m.normalize().toJSON(),body:i,duplex:"half",credentials:C?g:void 0});let A=await fetch(E);const R=supportsResponseStream&&(d==="stream"||d==="response");if(supportsResponseStream&&(f||R&&b)){const O={};["status","statusText","headers"].forEach(D=>{O[D]=A[D]});const I=utils$2.toFiniteNumber(A.headers.get("content-length")),[M,N]=f&&progressEventDecorator(I,progressEventReducer(asyncDecorator(f),!0))||[];A=new Response(trackStream(A.body,DEFAULT_CHUNK_SIZE,M,()=>{N&&N(),b&&b()}),O)}d=d||"text";let j=await resolvers[utils$2.findKey(resolvers,d)||"text"](A,e);return!R&&b&&b(),await new Promise((O,I)=>{settle(O,I,{data:j,headers:AxiosHeaders$1.from(A.headers),status:A.status,statusText:A.statusText,config:e,request:E})})}catch(C){throw b&&b(),C&&C.name==="TypeError"&&/fetch/i.test(C.message)?Object.assign(new AxiosError$1("Network Error",AxiosError$1.ERR_NETWORK,e,E),{cause:C.cause||C}):AxiosError$1.from(C,C&&C.code,e,E)}}),knownAdapters={http:httpAdapter,xhr:xhrAdapter,fetch:fetchAdapter};utils$2.forEach(knownAdapters,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch{}Object.defineProperty(e,"adapterName",{value:t})}});const renderReason=e=>`- ${e}`,isResolvedHandle=e=>utils$2.isFunction(e)||e===null||e===!1,adapters={getAdapter:e=>{e=utils$2.isArray(e)?e:[e];const{length:t}=e;let n,i;const o={};for(let l=0;l<t;l++){n=e[l];let u;if(i=n,!isResolvedHandle(n)&&(i=knownAdapters[(u=String(n)).toLowerCase()],i===void 0))throw new AxiosError$1(`Unknown adapter '${u}'`);if(i)break;o[u||"#"+l]=i}if(!i){const l=Object.entries(o).map(([f,p])=>`adapter ${f} `+(p===!1?"is not supported by the environment":"is not available in the build"));let u=t?l.length>1?`since :
|
|
36
36
|
`+l.map(renderReason).join(`
|
|
37
37
|
`):" "+renderReason(l[0]):"as no adapter specified";throw new AxiosError$1("There is no suitable adapter to dispatch the request "+u,"ERR_NOT_SUPPORT")}return i},adapters:knownAdapters};function throwIfCancellationRequested(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new CanceledError$1(null,e)}function dispatchRequest(e){return throwIfCancellationRequested(e),e.headers=AxiosHeaders$1.from(e.headers),e.data=transformData.call(e,e.transformRequest),["post","put","patch"].indexOf(e.method)!==-1&&e.headers.setContentType("application/x-www-form-urlencoded",!1),adapters.getAdapter(e.adapter||defaults$1.adapter)(e).then(function(i){return throwIfCancellationRequested(e),i.data=transformData.call(e,e.transformResponse,i),i.headers=AxiosHeaders$1.from(i.headers),i},function(i){return isCancel$1(i)||(throwIfCancellationRequested(e),i&&i.response&&(i.response.data=transformData.call(e,e.transformResponse,i.response),i.response.headers=AxiosHeaders$1.from(i.response.headers))),Promise.reject(i)})}const VERSION$1="1.8.4",validators$1={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{validators$1[e]=function(i){return typeof i===e||"a"+(t<1?"n ":" ")+e}});const deprecatedWarnings={};validators$1.transitional=function(t,n,i){function o(l,u){return"[Axios v"+VERSION$1+"] Transitional option '"+l+"'"+u+(i?". "+i:"")}return(l,u,f)=>{if(t===!1)throw new AxiosError$1(o(u," has been removed"+(n?" in "+n:"")),AxiosError$1.ERR_DEPRECATED);return n&&!deprecatedWarnings[u]&&(deprecatedWarnings[u]=!0,console.warn(o(u," has been deprecated since v"+n+" and will be removed in the near future"))),t?t(l,u,f):!0}};validators$1.spelling=function(t){return(n,i)=>(console.warn(`${i} is likely a misspelling of ${t}`),!0)};function assertOptions(e,t,n){if(typeof e!="object")throw new AxiosError$1("options must be an object",AxiosError$1.ERR_BAD_OPTION_VALUE);const i=Object.keys(e);let o=i.length;for(;o-- >0;){const l=i[o],u=t[l];if(u){const f=e[l],p=f===void 0||u(f,l,e);if(p!==!0)throw new AxiosError$1("option "+l+" must be "+p,AxiosError$1.ERR_BAD_OPTION_VALUE);continue}if(n!==!0)throw new AxiosError$1("Unknown option "+l,AxiosError$1.ERR_BAD_OPTION)}}const validator$1={assertOptions,validators:validators$1},validators=validator$1.validators;let Axios$1=class{constructor(t){this.defaults=t,this.interceptors={request:new InterceptorManager,response:new InterceptorManager}}async request(t,n){try{return await this._request(t,n)}catch(i){if(i instanceof Error){let o={};Error.captureStackTrace?Error.captureStackTrace(o):o=new Error;const l=o.stack?o.stack.replace(/^.+\n/,""):"";try{i.stack?l&&!String(i.stack).endsWith(l.replace(/^.+\n.+\n/,""))&&(i.stack+=`
|
|
38
|
-
`+l):i.stack=l}catch{}}throw i}}_request(t,n){typeof t=="string"?(n=n||{},n.url=t):n=t||{},n=mergeConfig$1(this.defaults,n);const{transitional:i,paramsSerializer:o,headers:l}=n;i!==void 0&&validator$1.assertOptions(i,{silentJSONParsing:validators.transitional(validators.boolean),forcedJSONParsing:validators.transitional(validators.boolean),clarifyTimeoutError:validators.transitional(validators.boolean)},!1),o!=null&&(utils$2.isFunction(o)?n.paramsSerializer={serialize:o}:validator$1.assertOptions(o,{encode:validators.function,serialize:validators.function},!0)),n.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?n.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:n.allowAbsoluteUrls=!0),validator$1.assertOptions(n,{baseUrl:validators.spelling("baseURL"),withXsrfToken:validators.spelling("withXSRFToken")},!0),n.method=(n.method||this.defaults.method||"get").toLowerCase();let u=l&&utils$2.merge(l.common,l[n.method]);l&&utils$2.forEach(["delete","get","head","post","put","patch","common"],E=>{delete l[E]}),n.headers=AxiosHeaders$1.concat(u,l);const f=[];let p=!0;this.interceptors.request.forEach(function(b){typeof b.runWhen=="function"&&b.runWhen(n)===!1||(p=p&&b.synchronous,f.unshift(b.fulfilled,b.rejected))});const d=[];this.interceptors.response.forEach(function(b){d.push(b.fulfilled,b.rejected)});let m,g=0,_;if(!p){const E=[dispatchRequest.bind(this),void 0];for(E.unshift.apply(E,f),E.push.apply(E,d),_=E.length,m=Promise.resolve(n);g<_;)m=m.then(E[g++],E[g++]);return m}_=f.length;let S=n;for(g=0;g<_;){const E=f[g++],b=f[g++];try{S=E(S)}catch(T){b.call(this,T);break}}try{m=dispatchRequest.call(this,S)}catch(E){return Promise.reject(E)}for(g=0,_=d.length;g<_;)m=m.then(d[g++],d[g++]);return m}getUri(t){t=mergeConfig$1(this.defaults,t);const n=buildFullPath(t.baseURL,t.url,t.allowAbsoluteUrls);return buildURL(n,t.params,t.paramsSerializer)}};utils$2.forEach(["delete","get","head","options"],function(t){Axios$1.prototype[t]=function(n,i){return this.request(mergeConfig$1(i||{},{method:t,url:n,data:(i||{}).data}))}});utils$2.forEach(["post","put","patch"],function(t){function n(i){return function(l,u,f){return this.request(mergeConfig$1(f||{},{method:t,headers:i?{"Content-Type":"multipart/form-data"}:{},url:l,data:u}))}}Axios$1.prototype[t]=n(),Axios$1.prototype[t+"Form"]=n(!0)});let CancelToken$1=class Yt{constructor(t){if(typeof t!="function")throw new TypeError("executor must be a function.");let n;this.promise=new Promise(function(l){n=l});const i=this;this.promise.then(o=>{if(!i._listeners)return;let l=i._listeners.length;for(;l-- >0;)i._listeners[l](o);i._listeners=null}),this.promise.then=o=>{let l;const u=new Promise(f=>{i.subscribe(f),l=f}).then(o);return u.cancel=function(){i.unsubscribe(l)},u},t(function(l,u,f){i.reason||(i.reason=new CanceledError$1(l,u,f),n(i.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(t){if(this.reason){t(this.reason);return}this._listeners?this._listeners.push(t):this._listeners=[t]}unsubscribe(t){if(!this._listeners)return;const n=this._listeners.indexOf(t);n!==-1&&this._listeners.splice(n,1)}toAbortSignal(){const t=new AbortController,n=i=>{t.abort(i)};return this.subscribe(n),t.signal.unsubscribe=()=>this.unsubscribe(n),t.signal}static source(){let t;return{token:new Yt(function(o){t=o}),cancel:t}}};function spread$1(e){return function(n){return e.apply(null,n)}}function isAxiosError$1(e){return utils$2.isObject(e)&&e.isAxiosError===!0}const HttpStatusCode$1={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(HttpStatusCode$1).forEach(([e,t])=>{HttpStatusCode$1[t]=e});function createInstance(e){const t=new Axios$1(e),n=bind(Axios$1.prototype.request,t);return utils$2.extend(n,Axios$1.prototype,t,{allOwnKeys:!0}),utils$2.extend(n,t,null,{allOwnKeys:!0}),n.create=function(o){return createInstance(mergeConfig$1(e,o))},n}const axios=createInstance(defaults$1);axios.Axios=Axios$1;axios.CanceledError=CanceledError$1;axios.CancelToken=CancelToken$1;axios.isCancel=isCancel$1;axios.VERSION=VERSION$1;axios.toFormData=toFormData$1;axios.AxiosError=AxiosError$1;axios.Cancel=axios.CanceledError;axios.all=function(t){return Promise.all(t)};axios.spread=spread$1;axios.isAxiosError=isAxiosError$1;axios.mergeConfig=mergeConfig$1;axios.AxiosHeaders=AxiosHeaders$1;axios.formToJSON=e=>formDataToJSON(utils$2.isHTMLForm(e)?new FormData(e):e);axios.getAdapter=adapters.getAdapter;axios.HttpStatusCode=HttpStatusCode$1;axios.default=axios;const{Axios,AxiosError,CanceledError,isCancel,CancelToken,VERSION,all,Cancel:Cancel$1,isAxiosError,spread,toFormData,AxiosHeaders,HttpStatusCode,formToJSON,getAdapter,mergeConfig}=axios,DrawerItemRecursive=({item:e,depth:t,expandedItems:n,setExpandedItems:i,onSubItemClick:o})=>{const l=e.children&&e.children.length>0,u=`${e.title}-${t}`,f=n[u],p=React.useRef(null),[d,m]=React.useState({maxHeight:0});React.useEffect(()=>{const _=p.current;if(_)if(f){_.style.display="block";const S=_.scrollHeight;m({maxHeight:S});const E=setTimeout(()=>{m({maxHeight:"none"})},300);return()=>clearTimeout(E)}else{const S=_.scrollHeight;m({maxHeight:S});const E=setTimeout(()=>{m({maxHeight:0})},20),b=setTimeout(()=>{_.style.display="none"},300);return()=>{clearTimeout(E),clearTimeout(b)}}},[f]);const g=()=>{i(_=>({..._,[u]:!_[u]}))};return jsxRuntimeExports.jsxs("div",{className:"drawer-item",children:[jsxRuntimeExports.jsxs("div",{className:"drawer-item-header",style:{paddingLeft:`${t*20}px`},onClick:()=>l?g():o(e.title),children:[jsxRuntimeExports.jsx("span",{className:"drawer-icon",children:l?f?"−":"+":""}),jsxRuntimeExports.jsx("span",{className:"drawer-title",children:e.title})]}),l&&jsxRuntimeExports.jsx("div",{className:"drawer-submenu-wrapper",style:{...d,overflow:"hidden",transition:"max-height 0.3s ease-in-out"},children:jsxRuntimeExports.jsx("div",{ref:p,className:"drawer-submenu",children:e.children.map(_=>jsxRuntimeExports.jsx(DrawerItemRecursive,{item:_,depth:t+1,expandedItems:n,setExpandedItems:i,onSubItemClick:o},_.title))})})]})},CEDrawer=({jsonUrl:e,isOpen:t,onClose:n})=>{const i=React.useRef(null),[o,l]=React.useState(),[u,f]=React.useState([]),[p,d]=React.useState({}),[m,g]=React.useState(!0),[_,S]=React.useState(null);React.useEffect(()=>{(async()=>{try{const T=await axios.get(e);l(T.data.headerItem),f(T.data.menuItems||[]),g(!1)}catch{S("Failed to load drawer data."),g(!1)}})()},[e]);const E=b=>{console.log("Clicked:",b)};return m?null:_?jsxRuntimeExports.jsx("div",{className:"drawer-error",children:_}):jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[jsxRuntimeExports.jsx("div",{className:`drawer-overlay ${t?"open":"closed"}`,onClick:n}),jsxRuntimeExports.jsxs("div",{className:`drawer ${t?"open":""}`,ref:i,children:[o&&jsxRuntimeExports.jsxs("div",{className:"drawer-header",children:[o.avatar&&jsxRuntimeExports.jsx("img",{src:o.avatar,alt:"avatar",className:"drawer-avatar"}),jsxRuntimeExports.jsxs("div",{className:"drawer-user-info",children:[jsxRuntimeExports.jsx("div",{className:"drawer-user-title",children:o.title}),o.subtitle&&jsxRuntimeExports.jsx("div",{className:"drawer-user-subtitle",children:o.subtitle})]})]}),u.map(b=>jsxRuntimeExports.jsx(DrawerItemRecursive,{item:b,depth:0,expandedItems:p,setExpandedItems:d,onSubItemClick:E},b.title))]})]})},CEDynamicSearchField=React.forwardRef(({label:e,onSearch:t,onClear:n,error:i=!1,errorMessage:o,fullWidth:l=!1,showClearButton:u=!0,containerClassName:f="",labelClassName:p="",inputClassName:d="",containerStyle:m,className:g,value:_,onChange:S,onKeyDown:E,id:b,...T},C)=>{const[A,R]=React.useState(""),j=b||`ce-search-field-${Math.random().toString(36).substr(2,9)}`,O=()=>jsxRuntimeExports.jsx("svg",{width:"24",height:"25",viewBox:"0 0 24 25",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:jsxRuntimeExports.jsx("path",{d:"M15.5001 14.5H14.7101L14.4301 14.23C15.6301 12.83 16.2501 10.92 15.9101 8.89002C15.4401 6.11002 13.1201 3.89002 10.3201 3.55002C6.09014 3.03002 2.53014 6.59001 3.05014 10.82C3.39014 13.62 5.61014 15.94 8.39014 16.41C10.4201 16.75 12.3301 16.13 13.7301 14.93L14.0001 15.21V16L18.2501 20.25C18.6601 20.66 19.3301 20.66 19.7401 20.25C20.1501 19.84 20.1501 19.17 19.7401 18.76L15.5001 14.5ZM9.50014 14.5C7.01014 14.5 5.00014 12.49 5.00014 10C5.00014 7.51002 7.01014 5.50002 9.50014 5.50002C11.9901 5.50002 14.0001 7.51002 14.0001 10C14.0001 12.49 11.9901 14.5 9.50014 14.5Z",fill:"black",fillOpacity:"0.54"})}),I=_!==void 0?_:A,M=I&&I.toString().length>0,N=W=>{_===void 0&&R(W.target.value),S==null||S(W)},D=W=>{W.key==="Enter"&&t&&t(I.toString()),E==null||E(W)},F=()=>{t&&t(I.toString())},q=()=>{_===void 0&&R(""),n==null||n();const W=document.getElementById(j);if(W&&S){const G=new Event("change",{bubbles:!0});Object.defineProperty(G,"target",{value:W,enumerable:!0}),Object.defineProperty(G,"currentTarget",{value:W,enumerable:!0}),W.value="",S(G)}};return jsxRuntimeExports.jsxs("div",{className:`ce-search-field-container ${l?"full-width":""} ${f}`,style:m,children:[e&&jsxRuntimeExports.jsx("label",{htmlFor:j,className:`ce-search-field-label ${i?"error":""} ${p}`,children:e}),jsxRuntimeExports.jsxs("div",{className:"ce-search-field-wrapper",children:[jsxRuntimeExports.jsx("input",{ref:C,type:"text",id:j,className:`ce-search-field-input ${i?"error":""} ${d} ${g||""}`,value:I,onChange:N,onKeyDown:D,...T}),u&&M&&jsxRuntimeExports.jsx("button",{type:"button",className:"ce-search-field-clear",onClick:q,"aria-label":"Clear search",children:"×"}),jsxRuntimeExports.jsx("button",{type:"button",className:"ce-search-field-button",onClick:F,"aria-label":"Search",children:jsxRuntimeExports.jsx(O,{})})]}),i&&o&&jsxRuntimeExports.jsx("span",{className:"ce-search-field-error-message",children:o})]})});CEDynamicSearchField.displayName="CESearchField";const CEDynamicSelectField=React.forwardRef(({label:e,options:t=[],error:n=!1,errorMessage:i,fullWidth:o=!1,showPlaceholder:l=!0,placeholderText:u="Placeholder",containerClassName:f="",labelClassName:p="",selectClassName:d="",containerStyle:m,className:g,isRequiredLabel:_,id:S,name:E,value:b,...T},C)=>{const A=S||`ce-select-field-${Math.random().toString(36).substr(2,9)}`,R=()=>jsxRuntimeExports.jsx("svg",{width:"24",height:"25",viewBox:"0 0 24 25",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:jsxRuntimeExports.jsx("path",{d:"M8.12021 9.79006L12.0002 13.6701L15.8802 9.79006C16.2702 9.40006 16.9002 9.40006 17.2902 9.79006C17.6802 10.1801 17.6802 10.8101 17.2902 11.2001L12.7002 15.7901C12.3102 16.1801 11.6802 16.1801 11.2902 15.7901L6.70021 11.2001C6.31021 10.8101 6.31021 10.1801 6.70021 9.79006C7.09021 9.41006 7.73021 9.40006 8.12021 9.79006Z",fill:"black",fillOpacity:"0.54"})}),j=b&&t.some(I=>I.value===b),O=l&&t.length>0&&(!b||!j);return jsxRuntimeExports.jsxs("div",{className:`ce-select-field-container ${o?"full-width":""} ${f}`,style:m,children:[e&&jsxRuntimeExports.jsxs("label",{htmlFor:A,className:`ce-select-field-label ${p}`,children:[e,_&&jsxRuntimeExports.jsx("span",{className:"asterisk",children:"*"})]}),jsxRuntimeExports.jsxs("div",{className:"ce-select-field-wrapper",children:[jsxRuntimeExports.jsx("select",{ref:C,id:A,name:E,className:`ce-select-field-select ${n?"error":""} ${d} ${g||""}`,value:b,...T,children:t.length===0?jsxRuntimeExports.jsx("option",{value:"",disabled:!0}):jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[O&&jsxRuntimeExports.jsx("option",{value:"",disabled:T.required,children:u}),t.map(I=>jsxRuntimeExports.jsx("option",{value:I.value,disabled:I.disabled,children:I.label},I.value))]})}),jsxRuntimeExports.jsx("div",{className:"ce-select-field-arrow","aria-hidden":"true",children:jsxRuntimeExports.jsx(R,{})})]}),n&&i&&jsxRuntimeExports.jsx("span",{className:"ce-select-field-error-message",children:i})]})});CEDynamicSelectField.displayName="CESelectField";const CEInputBox=({value:e,onChange:t,placeholder:n="",type:i="text",maxLength:o,required:l=!1,errorMessage:u="Invalid input",showError:f=!0,label:p,labelSuffix:d,disabled:m=!1,style:g={},size:_="medium",onFocus:S,onBlur:E,autoFocus:b=!1,alwaysShowLabel:T,id:C,name:A,onChangeMeta:R,rows:j})=>{const[O,I]=React.useState(!1),M=e==null?"":String(e),N=X=>{I(!0),S==null||S(X)},D=X=>{I(!1),E==null||E(X)},F=X=>{const V=X.target.value;if(!(i==="number"&&!/^-?\d*\.?\d{0,2}%?$/.test(V))&&!(i==="alphanumeric"&&!/^[a-zA-Z0-9]*$/.test(V))){if(i==="number"){if(V===""){t(""),R==null||R("",{id:C,name:A});return}if(V.endsWith("%")){t(V),R==null||R(V,{id:C,name:A});return}if(V==="-"||V==="."||V==="-."||V.endsWith(".")){t(V),R==null||R(V,{id:C,name:A});return}const z=Number(V),L=Number.isNaN(z)?V:z;t(L),R==null||R(L,{id:C,name:A});return}t(V),R==null||R(V,{id:C,name:A})}},q=React.useRef(null);React.useEffect(()=>{i==="textarea"&&q.current&&(q.current.style.height="auto",q.current.style.height=`${q.current.scrollHeight}px`)},[M,i]);const W=getSizeStyle$1(_||"medium"),G=f&&l&&!M,ee={fontSize:W.fontSize,padding:W.padding,...g};return jsxRuntimeExports.jsxs("div",{className:`validated-input-wrapper ${O?"focused":""} ${G?"error":""}`,children:[p&&jsxRuntimeExports.jsxs("label",{className:`validated-input-label ${T||M||O?"shrink":""}`,children:[p,l&&jsxRuntimeExports.jsx("span",{className:"required-asterisk",children:"*"}),d&&jsxRuntimeExports.jsx("span",{style:{marginLeft:4},children:d})]}),i==="textarea"?jsxRuntimeExports.jsx("textarea",{ref:q,rows:j,value:M,onChange:X=>{t(X.target.value),R==null||R(X.target.value,{id:C,name:A})},onFocus:N,onBlur:D,placeholder:n||" ",id:C,name:A,className:`validated-input-field ${G?"input-error":""}`,disabled:m,style:ee}):jsxRuntimeExports.jsx("input",{type:i==="number"?"text":i,inputMode:i==="number"?"decimal":void 0,value:M,onChange:F,onFocus:N,onBlur:D,placeholder:n||" ",id:C,name:A,className:`validated-input-field ${G?"input-error":""}`,disabled:m,style:ee,autoFocus:b,maxLength:o,onKeyDown:X=>{i==="number"&&["e","E"].includes(X.key)&&X.preventDefault()}}),f&&G&&jsxRuntimeExports.jsx("div",{className:"validated-input-error",children:u})]})},CEDynamicTextField=React.forwardRef(({label:e,error:t=!1,errorMessage:n,fullWidth:i=!1,containerClassName:o="",labelClassName:l="",inputClassName:u="",containerStyle:f,className:p,id:d,name:m,multiline:g=!1,rows:_,minHeight:S,width:E,validationType:b,...T},C)=>{function A(G,ee){if(!ee)return G;switch(ee){case"number":let X=G.replace(/[^0-9.]/g,"");const V=X.split(".");return V.length>1&&(X=V.shift()+"."+V.join("")),X;case"alphanumeric":return G.replace(/[^A-Za-z0-9]/g,"");case"alpha":return G.replace(/[^A-Za-z]/g,"");case"alphanumericWithSpecial":return G.replace(/[^A-Za-z0-9\s!@#\$%\^&\*\(\)_\+":><,\.\?\/~`\[\]\\|\-]/g,"");case"alphaWithoutSpecial":return G.replace(/[^A-Za-z\s]/g,"");default:return G}}const[R,j]=React.useState(()=>A(String(T.value??""),b)),O=React.useRef(!1);React.useEffect(()=>{if(T.value!==void 0){const G=A(String(T.value),b);G!==R&&j(G)}},[T.value,b]);const I=(G,ee)=>{if(T.onChange){const X=ee?{...ee,target:{...ee.target,value:G}}:{target:{value:G,name:m}};T.onChange(X)}},M=(G,ee)=>{if(O.current){j(G);return}const X=A(G,b);j(X),I(X,ee)},N=()=>{O.current=!0},D=G=>{O.current=!1;const ee=G.target.value;M(ee,G)},F=G=>{var H;G.preventDefault();const ee=((H=G.clipboardData)==null?void 0:H.getData("text"))??"",X=G.target,V=X.selectionStart??X.value.length,z=X.selectionEnd??V,L=R.slice(0,V),B=R.slice(z),U=L+ee+B;let K=A(U,b);if(b==="number"){const J=K.split(".");J.length>1&&(K=J.shift()+"."+J.join(""))}j(K),I(K,G)},q=d||`ce-text-field-${Math.random().toString(36).substr(2,9)}`,W={};return S!=null&&(W.minHeight=typeof S=="number"?`${S}px`:S),E!=null&&(W.width=typeof E=="number"?`${E}px`:E),jsxRuntimeExports.jsxs("div",{className:`ce-text-field-container ${i?"full-width":""} ${o}`,style:f,children:[e&&jsxRuntimeExports.jsxs("label",{htmlFor:q,className:`ce-text-field-label ${t?"error":""} ${l}`,children:[e,T.required&&jsxRuntimeExports.jsx("span",{className:"required-asterisk",children:"*"})]}),g?jsxRuntimeExports.jsx(CEInputBox,{type:"textarea",value:R,onChange:G=>M(String(G)),id:q,name:m,placeholder:T.placeholder,errorMessage:n,showError:t,label:e,required:T.required,alwaysShowLabel:!0,style:Object.keys(W).length?W:void 0}):jsxRuntimeExports.jsx("input",{ref:C,type:"text",id:q,name:m,className:`ce-text-field-input ${t?"error":""} ${u} ${p||""}`,...T,value:R,onChange:G=>M(G.target.value,G),onCompositionStart:N,onCompositionEnd:D,onPaste:F}),t&&n&&jsxRuntimeExports.jsx("span",{className:"ce-text-field-error-message",children:n})]})});CEDynamicTextField.displayName="CETextField";const uploadWrapper="_uploadWrapper_17z69_1",dropZone="_dropZone_17z69_15",dropZoneActive="_dropZoneActive_17z69_33",uploadButton="_uploadButton_17z69_49",fileTable="_fileTable_17z69_67",note="_note_17z69_105",errorText="_errorText_17z69_119",fileUploadPagination="_fileUploadPagination_17z69_135",styles$1={uploadWrapper,dropZone,dropZoneActive,uploadButton,fileTable,note,errorText,fileUploadPagination},DEFAULT_EXTS$1=[".csv",".xlsx",".xls",".pdf",".docx",".doc",".jpg",".jpeg",".png",".bmp",".txt",".zip"],normalizeExts$1=e=>{const t=(e&&e.length?e:DEFAULT_EXTS$1).map(n=>n.startsWith(".")?n.toLowerCase():`.${n.toLowerCase()}`);return Array.from(new Set(t))},CEFileUploadDocument=({onUpload:e,accept:t,initialFiles:n=[],showPathColumn:i=!1,showType:o=!1,onDelete:l,onDownload:u,showPagination:f=!1,pageSizeOptions:p=[10,20,50,100]})=>{const d=React.useRef(null),[m,g]=React.useState([]),[_,S]=React.useState(null),[E,b]=React.useState(!1),[T,C]=React.useState(10),[A,R]=React.useState(0);React.useEffect(()=>{g(z=>{const L=new Set(z.map(U=>U.id??U.name)),B=n.filter(U=>!L.has(U.id??U.name));return[...z,...B]})},[n]);const j=normalizeExts$1(t),O=j.join(","),I=j.join(", "),M=z=>{const L=z.lastIndexOf(".");return L>=0?z.slice(L).toLowerCase():""},N=z=>j.includes(M(z.name)),D=z=>{const L=new Date().toLocaleDateString(),B=z.filter(N),U=z.filter(H=>!N(H));S(U.length?`Unsupported file(s): ${U.map(H=>H.name).join(", ")}`:null);const K=B.map(H=>({name:H.name,type:H.type,uploadDate:L,file:H}));g(H=>{const J=new Set(H.map(te=>te.name)),Z=K.filter(te=>!J.has(te.name));return[...H,...Z]}),e&&K.length>0&&e(K)},F=z=>{const L=Array.from(z.target.files||[]);D(L),d.current&&(d.current.value="")},q=z=>z.preventDefault(),W=z=>{z.preventDefault(),b(!0)},G=z=>{z.preventDefault(),b(!1)},ee=z=>{z.preventDefault(),b(!1);const L=Array.from(z.dataTransfer.files||[]);D(L),z.dataTransfer.clearData()},X=z=>{g(L=>{let B;const U=L.filter(K=>{const H=K.id===z||K.name===z;return H&&(B=K),!H});return B&&(l==null||l(B)),U})},V=z=>{u==null||u(z)};return jsxRuntimeExports.jsxs("div",{className:styles$1.uploadWrapper,children:[jsxRuntimeExports.jsxs("div",{onDrop:ee,onDragOver:q,onDragEnter:W,onDragLeave:G,className:`${styles$1.dropZone} ${E?styles$1.dropZoneActive:""}`,onClick:()=>{var z;return(z=d.current)==null?void 0:z.click()},role:"button",tabIndex:0,children:[jsxRuntimeExports.jsx("p",{children:"Drop your file here or click to browse"}),jsxRuntimeExports.jsxs("p",{children:["Supported formats: ",I]}),jsxRuntimeExports.jsx("button",{type:"button",className:styles$1.uploadButton,onClick:z=>{var L;z.stopPropagation(),(L=d.current)==null||L.click()},children:"⬆️ Select Document"}),jsxRuntimeExports.jsx("input",{ref:d,type:"file",accept:O,multiple:!0,onChange:F,style:{display:"none"}})]}),_&&jsxRuntimeExports.jsx("p",{className:styles$1.errorText,children:_}),jsxRuntimeExports.jsxs("table",{className:styles$1.fileTable,children:[jsxRuntimeExports.jsx("thead",{children:jsxRuntimeExports.jsxs("tr",{children:[jsxRuntimeExports.jsx("th",{children:"Document Name"}),i&&jsxRuntimeExports.jsx("th",{children:"Path"}),o&&jsxRuntimeExports.jsx("th",{children:"Type"}),jsxRuntimeExports.jsx("th",{children:"Upload Date"}),jsxRuntimeExports.jsx("th",{children:"Actions"})]})}),jsxRuntimeExports.jsx("tbody",{children:m.length===0?jsxRuntimeExports.jsx("tr",{children:jsxRuntimeExports.jsx("td",{colSpan:i?5:4,style:{textAlign:"center"},children:"No records to display."})}):m.slice(A*T,A*T+T).map((z,L)=>jsxRuntimeExports.jsxs("tr",{children:[jsxRuntimeExports.jsx("td",{children:z.name}),i&&jsxRuntimeExports.jsx("td",{children:z.path??"-"}),o&&jsxRuntimeExports.jsx("td",{children:z.type??"-"}),jsxRuntimeExports.jsx("td",{children:z.uploadDate}),jsxRuntimeExports.jsxs("td",{children:[jsxRuntimeExports.jsx("button",{type:"button",onClick:()=>X(z.id??z.name),children:"🗑️"})," ",jsxRuntimeExports.jsx("button",{type:"button",onClick:()=>V(z),children:"⬇️"})]})]},z.id??`${z.name}-${L}`))})]}),f&&jsxRuntimeExports.jsxs("div",{className:styles$1.fileUploadPagination,children:[jsxRuntimeExports.jsxs("div",{children:[jsxRuntimeExports.jsx("label",{htmlFor:"rows-per-page-select",children:"Rows per page: "}),jsxRuntimeExports.jsx("select",{id:"rows-per-page-select",value:T,onChange:z=>C(parseInt(z.target.value,10)),children:p.map(z=>jsxRuntimeExports.jsx("option",{value:z,children:z},z))})]}),jsxRuntimeExports.jsxs("div",{children:[m.length>0&&jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[m.length===0?0:A*T+1," -"," ",Math.min((A+1)*T,m.length)," of"," ",m.length]}),jsxRuntimeExports.jsx("button",{onClick:()=>R(A-1),disabled:A===0,className:"pagination-button",style:{marginLeft:"5px"},children:"Previous"}),jsxRuntimeExports.jsx("button",{onClick:()=>R(A+1),disabled:A>=Math.ceil(m.length/T)-1,className:"pagination-button",children:"Next"})]})]}),jsxRuntimeExports.jsxs("p",{className:styles$1.note,children:[jsxRuntimeExports.jsx("strong",{children:"Note:"})," if the file did not appear, your browser may block pop-ups."]})]})},CECustomModal=({isOpen:e,onClose:t,title:n,children:i,primaryButtonText:o,secondaryButtonText:l,onPrimaryClick:u,onSecondaryClick:f,width:p,height:d,style:m={}})=>{if(React.useEffect(()=>{const _=S=>{S.key==="Escape"&&t()};return document.addEventListener("keydown",_),()=>document.removeEventListener("keydown",_)},[t]),!e)return null;const g={...m};return p!=null&&(g.width=typeof p=="number"?`${p}px`:p),d!=null&&(g.height=typeof d=="number"?`${d}px`:d),ReactDOM.createPortal(jsxRuntimeExports.jsx("div",{className:"modal-overlay",children:jsxRuntimeExports.jsxs("div",{className:"modal-container",style:g,onClick:_=>_.stopPropagation(),children:[jsxRuntimeExports.jsxs("div",{className:"modal-header",children:[jsxRuntimeExports.jsx("span",{className:"modal-title",children:n}),jsxRuntimeExports.jsx("button",{className:"modal-close",onClick:t,"aria-label":"Close modal",children:"×"})]}),jsxRuntimeExports.jsx("div",{className:"modal-content",children:i}),(o||l)&&jsxRuntimeExports.jsxs("div",{className:"modal-footer",children:[l&&jsxRuntimeExports.jsx(CEButton,{variant:"outlinedGreen",onClick:f??(()=>{}),children:l}),o&&jsxRuntimeExports.jsx(CEButton,{className:"modal-button primary",onClick:u??(()=>{}),children:o})]})]})}),document.body)},CEUploadModalWrapper=()=>{const[e,t]=React.useState(!1);return jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[jsxRuntimeExports.jsx("button",{onClick:()=>t(!0),children:"Open Upload Modal"}),jsxRuntimeExports.jsx(CECustomModal,{isOpen:e,onClose:()=>t(!1),title:"Upload File",primaryButtonText:"Close",onPrimaryClick:()=>t(!1),children:jsxRuntimeExports.jsx(CEFileUploadDocument,{onUpload:n=>console.log("Uploaded:",n)})})]})},common={black:"#000",white:"#fff"},red={300:"#e57373",400:"#ef5350",500:"#f44336",700:"#d32f2f",800:"#c62828"},purple={50:"#f3e5f5",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",700:"#7b1fa2"},blue={50:"#e3f2fd",200:"#90caf9",400:"#42a5f5",700:"#1976d2",800:"#1565c0"},lightBlue={300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",700:"#0288d1",900:"#01579b"},green={300:"#81c784",400:"#66bb6a",500:"#4caf50",700:"#388e3c",800:"#2e7d32",900:"#1b5e20"},orange={300:"#ffb74d",400:"#ffa726",500:"#ff9800",700:"#f57c00",900:"#e65100"},grey={50:"#fafafa",100:"#f5f5f5",200:"#eeeeee",300:"#e0e0e0",400:"#bdbdbd",500:"#9e9e9e",600:"#757575",700:"#616161",800:"#424242",900:"#212121",A100:"#f5f5f5",A200:"#eeeeee",A400:"#bdbdbd",A700:"#616161"};function formatMuiErrorMessage(e,...t){const n=new URL(`https://mui.com/production-error/?code=${e}`);return t.forEach(i=>n.searchParams.append("args[]",i)),`Minified MUI error #${e}; visit ${n} for the full message.`}const THEME_ID="$$material";function _extends$z(){return _extends$z=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)({}).hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},_extends$z.apply(null,arguments)}function sheetForTag(e){if(e.sheet)return e.sheet;for(var t=0;t<document.styleSheets.length;t++)if(document.styleSheets[t].ownerNode===e)return document.styleSheets[t]}function createStyleElement(e){var t=document.createElement("style");return t.setAttribute("data-emotion",e.key),e.nonce!==void 0&&t.setAttribute("nonce",e.nonce),t.appendChild(document.createTextNode("")),t.setAttribute("data-s",""),t}var StyleSheet=function(){function e(n){var i=this;this._insertTag=function(o){var l;i.tags.length===0?i.insertionPoint?l=i.insertionPoint.nextSibling:i.prepend?l=i.container.firstChild:l=i.before:l=i.tags[i.tags.length-1].nextSibling,i.container.insertBefore(o,l),i.tags.push(o)},this.isSpeedy=n.speedy===void 0?!0:n.speedy,this.tags=[],this.ctr=0,this.nonce=n.nonce,this.key=n.key,this.container=n.container,this.prepend=n.prepend,this.insertionPoint=n.insertionPoint,this.before=null}var t=e.prototype;return t.hydrate=function(i){i.forEach(this._insertTag)},t.insert=function(i){this.ctr%(this.isSpeedy?65e3:1)===0&&this._insertTag(createStyleElement(this));var o=this.tags[this.tags.length-1];if(this.isSpeedy){var l=sheetForTag(o);try{l.insertRule(i,l.cssRules.length)}catch{}}else o.appendChild(document.createTextNode(i));this.ctr++},t.flush=function(){this.tags.forEach(function(i){var o;return(o=i.parentNode)==null?void 0:o.removeChild(i)}),this.tags=[],this.ctr=0},e}(),MS="-ms-",MOZ="-moz-",WEBKIT="-webkit-",COMMENT="comm",RULESET="rule",DECLARATION="decl",IMPORT="@import",KEYFRAMES="@keyframes",LAYER="@layer",abs=Math.abs,from=String.fromCharCode,assign$1=Object.assign;function hash$2(e,t){return charat(e,0)^45?(((t<<2^charat(e,0))<<2^charat(e,1))<<2^charat(e,2))<<2^charat(e,3):0}function trim(e){return e.trim()}function match(e,t){return(e=t.exec(e))?e[0]:e}function replace(e,t,n){return e.replace(t,n)}function indexof(e,t){return e.indexOf(t)}function charat(e,t){return e.charCodeAt(t)|0}function substr(e,t,n){return e.slice(t,n)}function strlen(e){return e.length}function sizeof(e){return e.length}function append$1(e,t){return t.push(e),e}function combine(e,t){return e.map(t).join("")}var line=1,column=1,length=0,position=0,character=0,characters="";function node(e,t,n,i,o,l,u){return{value:e,root:t,parent:n,type:i,props:o,children:l,line,column,length:u,return:""}}function copy$2(e,t){return assign$1(node("",null,null,"",null,null,0),e,{length:-e.length},t)}function char(){return character}function prev(){return character=position>0?charat(characters,--position):0,column--,character===10&&(column=1,line--),character}function next(){return character=position<length?charat(characters,position++):0,column++,character===10&&(column=1,line++),character}function peek(){return charat(characters,position)}function caret(){return position}function slice(e,t){return substr(characters,e,t)}function token(e){switch(e){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function alloc(e){return line=column=1,length=strlen(characters=e),position=0,[]}function dealloc(e){return characters="",e}function delimit(e){return trim(slice(position-1,delimiter(e===91?e+2:e===40?e+1:e)))}function whitespace(e){for(;(character=peek())&&character<33;)next();return token(e)>2||token(character)>3?"":" "}function escaping(e,t){for(;--t&&next()&&!(character<48||character>102||character>57&&character<65||character>70&&character<97););return slice(e,caret()+(t<6&&peek()==32&&next()==32))}function delimiter(e){for(;next();)switch(character){case e:return position;case 34:case 39:e!==34&&e!==39&&delimiter(character);break;case 40:e===41&&delimiter(e);break;case 92:next();break}return position}function commenter(e,t){for(;next()&&e+character!==57;)if(e+character===84&&peek()===47)break;return"/*"+slice(t,position-1)+"*"+from(e===47?e:next())}function identifier(e){for(;!token(peek());)next();return slice(e,position)}function compile(e){return dealloc(parse("",null,null,null,[""],e=alloc(e),0,[0],e))}function parse(e,t,n,i,o,l,u,f,p){for(var d=0,m=0,g=u,_=0,S=0,E=0,b=1,T=1,C=1,A=0,R="",j=o,O=l,I=i,M=R;T;)switch(E=A,A=next()){case 40:if(E!=108&&charat(M,g-1)==58){indexof(M+=replace(delimit(A),"&","&\f"),"&\f")!=-1&&(C=-1);break}case 34:case 39:case 91:M+=delimit(A);break;case 9:case 10:case 13:case 32:M+=whitespace(E);break;case 92:M+=escaping(caret()-1,7);continue;case 47:switch(peek()){case 42:case 47:append$1(comment(commenter(next(),caret()),t,n),p);break;default:M+="/"}break;case 123*b:f[d++]=strlen(M)*C;case 125*b:case 59:case 0:switch(A){case 0:case 125:T=0;case 59+m:C==-1&&(M=replace(M,/\f/g,"")),S>0&&strlen(M)-g&&append$1(S>32?declaration(M+";",i,n,g-1):declaration(replace(M," ","")+";",i,n,g-2),p);break;case 59:M+=";";default:if(append$1(I=ruleset(M,t,n,d,m,o,f,R,j=[],O=[],g),l),A===123)if(m===0)parse(M,t,I,I,j,l,g,f,O);else switch(_===99&&charat(M,3)===110?100:_){case 100:case 108:case 109:case 115:parse(e,I,I,i&&append$1(ruleset(e,I,I,0,0,o,f,R,o,j=[],g),O),o,O,g,f,i?j:O);break;default:parse(M,I,I,I,[""],O,0,f,O)}}d=m=S=0,b=C=1,R=M="",g=u;break;case 58:g=1+strlen(M),S=E;default:if(b<1){if(A==123)--b;else if(A==125&&b++==0&&prev()==125)continue}switch(M+=from(A),A*b){case 38:C=m>0?1:(M+="\f",-1);break;case 44:f[d++]=(strlen(M)-1)*C,C=1;break;case 64:peek()===45&&(M+=delimit(next())),_=peek(),m=g=strlen(R=M+=identifier(caret())),A++;break;case 45:E===45&&strlen(M)==2&&(b=0)}}return l}function ruleset(e,t,n,i,o,l,u,f,p,d,m){for(var g=o-1,_=o===0?l:[""],S=sizeof(_),E=0,b=0,T=0;E<i;++E)for(var C=0,A=substr(e,g+1,g=abs(b=u[E])),R=e;C<S;++C)(R=trim(b>0?_[C]+" "+A:replace(A,/&\f/g,_[C])))&&(p[T++]=R);return node(e,t,n,o===0?RULESET:f,p,d,m)}function comment(e,t,n){return node(e,t,n,COMMENT,from(char()),substr(e,2,-2),0)}function declaration(e,t,n,i){return node(e,t,n,DECLARATION,substr(e,0,i),substr(e,i+1,-1),i)}function serialize(e,t){for(var n="",i=sizeof(e),o=0;o<i;o++)n+=t(e[o],o,e,t)||"";return n}function stringify(e,t,n,i){switch(e.type){case LAYER:if(e.children.length)break;case IMPORT:case DECLARATION:return e.return=e.return||e.value;case COMMENT:return"";case KEYFRAMES:return e.return=e.value+"{"+serialize(e.children,i)+"}";case RULESET:e.value=e.props.join(",")}return strlen(n=serialize(e.children,i))?e.return=e.value+"{"+n+"}":""}function middleware(e){var t=sizeof(e);return function(n,i,o,l){for(var u="",f=0;f<t;f++)u+=e[f](n,i,o,l)||"";return u}}function rulesheet(e){return function(t){t.root||(t=t.return)&&e(t)}}function memoize$3(e){var t=Object.create(null);return function(n){return t[n]===void 0&&(t[n]=e(n)),t[n]}}var identifierWithPointTracking=function(t,n,i){for(var o=0,l=0;o=l,l=peek(),o===38&&l===12&&(n[i]=1),!token(l);)next();return slice(t,position)},toRules=function(t,n){var i=-1,o=44;do switch(token(o)){case 0:o===38&&peek()===12&&(n[i]=1),t[i]+=identifierWithPointTracking(position-1,n,i);break;case 2:t[i]+=delimit(o);break;case 4:if(o===44){t[++i]=peek()===58?"&\f":"",n[i]=t[i].length;break}default:t[i]+=from(o)}while(o=next());return t},getRules=function(t,n){return dealloc(toRules(alloc(t),n))},fixedElements=new WeakMap,compat=function(t){if(!(t.type!=="rule"||!t.parent||t.length<1)){for(var n=t.value,i=t.parent,o=t.column===i.column&&t.line===i.line;i.type!=="rule";)if(i=i.parent,!i)return;if(!(t.props.length===1&&n.charCodeAt(0)!==58&&!fixedElements.get(i))&&!o){fixedElements.set(t,!0);for(var l=[],u=getRules(n,l),f=i.props,p=0,d=0;p<u.length;p++)for(var m=0;m<f.length;m++,d++)t.props[d]=l[p]?u[p].replace(/&\f/g,f[m]):f[m]+" "+u[p]}}},removeLabel=function(t){if(t.type==="decl"){var n=t.value;n.charCodeAt(0)===108&&n.charCodeAt(2)===98&&(t.return="",t.value="")}};function prefix$1(e,t){switch(hash$2(e,t)){case 5103:return WEBKIT+"print-"+e+e;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return WEBKIT+e+e;case 5349:case 4246:case 4810:case 6968:case 2756:return WEBKIT+e+MOZ+e+MS+e+e;case 6828:case 4268:return WEBKIT+e+MS+e+e;case 6165:return WEBKIT+e+MS+"flex-"+e+e;case 5187:return WEBKIT+e+replace(e,/(\w+).+(:[^]+)/,WEBKIT+"box-$1$2"+MS+"flex-$1$2")+e;case 5443:return WEBKIT+e+MS+"flex-item-"+replace(e,/flex-|-self/,"")+e;case 4675:return WEBKIT+e+MS+"flex-line-pack"+replace(e,/align-content|flex-|-self/,"")+e;case 5548:return WEBKIT+e+MS+replace(e,"shrink","negative")+e;case 5292:return WEBKIT+e+MS+replace(e,"basis","preferred-size")+e;case 6060:return WEBKIT+"box-"+replace(e,"-grow","")+WEBKIT+e+MS+replace(e,"grow","positive")+e;case 4554:return WEBKIT+replace(e,/([^-])(transform)/g,"$1"+WEBKIT+"$2")+e;case 6187:return replace(replace(replace(e,/(zoom-|grab)/,WEBKIT+"$1"),/(image-set)/,WEBKIT+"$1"),e,"")+e;case 5495:case 3959:return replace(e,/(image-set\([^]*)/,WEBKIT+"$1$`$1");case 4968:return replace(replace(e,/(.+:)(flex-)?(.*)/,WEBKIT+"box-pack:$3"+MS+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+WEBKIT+e+e;case 4095:case 3583:case 4068:case 2532:return replace(e,/(.+)-inline(.+)/,WEBKIT+"$1$2")+e;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(strlen(e)-1-t>6)switch(charat(e,t+1)){case 109:if(charat(e,t+4)!==45)break;case 102:return replace(e,/(.+:)(.+)-([^]+)/,"$1"+WEBKIT+"$2-$3$1"+MOZ+(charat(e,t+3)==108?"$3":"$2-$3"))+e;case 115:return~indexof(e,"stretch")?prefix$1(replace(e,"stretch","fill-available"),t)+e:e}break;case 4949:if(charat(e,t+1)!==115)break;case 6444:switch(charat(e,strlen(e)-3-(~indexof(e,"!important")&&10))){case 107:return replace(e,":",":"+WEBKIT)+e;case 101:return replace(e,/(.+:)([^;!]+)(;|!.+)?/,"$1"+WEBKIT+(charat(e,14)===45?"inline-":"")+"box$3$1"+WEBKIT+"$2$3$1"+MS+"$2box$3")+e}break;case 5936:switch(charat(e,t+11)){case 114:return WEBKIT+e+MS+replace(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return WEBKIT+e+MS+replace(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return WEBKIT+e+MS+replace(e,/[svh]\w+-[tblr]{2}/,"lr")+e}return WEBKIT+e+MS+e+e}return e}var prefixer=function(t,n,i,o){if(t.length>-1&&!t.return)switch(t.type){case DECLARATION:t.return=prefix$1(t.value,t.length);break;case KEYFRAMES:return serialize([copy$2(t,{value:replace(t.value,"@","@"+WEBKIT)})],o);case RULESET:if(t.length)return combine(t.props,function(l){switch(match(l,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return serialize([copy$2(t,{props:[replace(l,/:(read-\w+)/,":"+MOZ+"$1")]})],o);case"::placeholder":return serialize([copy$2(t,{props:[replace(l,/:(plac\w+)/,":"+WEBKIT+"input-$1")]}),copy$2(t,{props:[replace(l,/:(plac\w+)/,":"+MOZ+"$1")]}),copy$2(t,{props:[replace(l,/:(plac\w+)/,MS+"input-$1")]})],o)}return""})}},defaultStylisPlugins=[prefixer],createCache=function(t){var n=t.key;if(n==="css"){var i=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(i,function(b){var T=b.getAttribute("data-emotion");T.indexOf(" ")!==-1&&(document.head.appendChild(b),b.setAttribute("data-s",""))})}var o=t.stylisPlugins||defaultStylisPlugins,l={},u,f=[];u=t.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+n+' "]'),function(b){for(var T=b.getAttribute("data-emotion").split(" "),C=1;C<T.length;C++)l[T[C]]=!0;f.push(b)});var p,d=[compat,removeLabel];{var m,g=[stringify,rulesheet(function(b){m.insert(b)})],_=middleware(d.concat(o,g)),S=function(T){return serialize(compile(T),_)};p=function(T,C,A,R){m=A,S(T?T+"{"+C.styles+"}":C.styles),R&&(E.inserted[C.name]=!0)}}var E={key:n,sheet:new StyleSheet({key:n,container:u,nonce:t.nonce,speedy:t.speedy,prepend:t.prepend,insertionPoint:t.insertionPoint}),nonce:t.nonce,inserted:l,registered:{},insert:p};return E.sheet.hydrate(f),E},reactIs$3={exports:{}},reactIs_production_min$2={};/** @license React v16.13.1
|
|
38
|
+
`+l):i.stack=l}catch{}}throw i}}_request(t,n){typeof t=="string"?(n=n||{},n.url=t):n=t||{},n=mergeConfig$1(this.defaults,n);const{transitional:i,paramsSerializer:o,headers:l}=n;i!==void 0&&validator$1.assertOptions(i,{silentJSONParsing:validators.transitional(validators.boolean),forcedJSONParsing:validators.transitional(validators.boolean),clarifyTimeoutError:validators.transitional(validators.boolean)},!1),o!=null&&(utils$2.isFunction(o)?n.paramsSerializer={serialize:o}:validator$1.assertOptions(o,{encode:validators.function,serialize:validators.function},!0)),n.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?n.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:n.allowAbsoluteUrls=!0),validator$1.assertOptions(n,{baseUrl:validators.spelling("baseURL"),withXsrfToken:validators.spelling("withXSRFToken")},!0),n.method=(n.method||this.defaults.method||"get").toLowerCase();let u=l&&utils$2.merge(l.common,l[n.method]);l&&utils$2.forEach(["delete","get","head","post","put","patch","common"],E=>{delete l[E]}),n.headers=AxiosHeaders$1.concat(u,l);const f=[];let p=!0;this.interceptors.request.forEach(function(b){typeof b.runWhen=="function"&&b.runWhen(n)===!1||(p=p&&b.synchronous,f.unshift(b.fulfilled,b.rejected))});const d=[];this.interceptors.response.forEach(function(b){d.push(b.fulfilled,b.rejected)});let m,g=0,_;if(!p){const E=[dispatchRequest.bind(this),void 0];for(E.unshift.apply(E,f),E.push.apply(E,d),_=E.length,m=Promise.resolve(n);g<_;)m=m.then(E[g++],E[g++]);return m}_=f.length;let S=n;for(g=0;g<_;){const E=f[g++],b=f[g++];try{S=E(S)}catch(T){b.call(this,T);break}}try{m=dispatchRequest.call(this,S)}catch(E){return Promise.reject(E)}for(g=0,_=d.length;g<_;)m=m.then(d[g++],d[g++]);return m}getUri(t){t=mergeConfig$1(this.defaults,t);const n=buildFullPath(t.baseURL,t.url,t.allowAbsoluteUrls);return buildURL(n,t.params,t.paramsSerializer)}};utils$2.forEach(["delete","get","head","options"],function(t){Axios$1.prototype[t]=function(n,i){return this.request(mergeConfig$1(i||{},{method:t,url:n,data:(i||{}).data}))}});utils$2.forEach(["post","put","patch"],function(t){function n(i){return function(l,u,f){return this.request(mergeConfig$1(f||{},{method:t,headers:i?{"Content-Type":"multipart/form-data"}:{},url:l,data:u}))}}Axios$1.prototype[t]=n(),Axios$1.prototype[t+"Form"]=n(!0)});let CancelToken$1=class Yt{constructor(t){if(typeof t!="function")throw new TypeError("executor must be a function.");let n;this.promise=new Promise(function(l){n=l});const i=this;this.promise.then(o=>{if(!i._listeners)return;let l=i._listeners.length;for(;l-- >0;)i._listeners[l](o);i._listeners=null}),this.promise.then=o=>{let l;const u=new Promise(f=>{i.subscribe(f),l=f}).then(o);return u.cancel=function(){i.unsubscribe(l)},u},t(function(l,u,f){i.reason||(i.reason=new CanceledError$1(l,u,f),n(i.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(t){if(this.reason){t(this.reason);return}this._listeners?this._listeners.push(t):this._listeners=[t]}unsubscribe(t){if(!this._listeners)return;const n=this._listeners.indexOf(t);n!==-1&&this._listeners.splice(n,1)}toAbortSignal(){const t=new AbortController,n=i=>{t.abort(i)};return this.subscribe(n),t.signal.unsubscribe=()=>this.unsubscribe(n),t.signal}static source(){let t;return{token:new Yt(function(o){t=o}),cancel:t}}};function spread$1(e){return function(n){return e.apply(null,n)}}function isAxiosError$1(e){return utils$2.isObject(e)&&e.isAxiosError===!0}const HttpStatusCode$1={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(HttpStatusCode$1).forEach(([e,t])=>{HttpStatusCode$1[t]=e});function createInstance(e){const t=new Axios$1(e),n=bind(Axios$1.prototype.request,t);return utils$2.extend(n,Axios$1.prototype,t,{allOwnKeys:!0}),utils$2.extend(n,t,null,{allOwnKeys:!0}),n.create=function(o){return createInstance(mergeConfig$1(e,o))},n}const axios=createInstance(defaults$1);axios.Axios=Axios$1;axios.CanceledError=CanceledError$1;axios.CancelToken=CancelToken$1;axios.isCancel=isCancel$1;axios.VERSION=VERSION$1;axios.toFormData=toFormData$1;axios.AxiosError=AxiosError$1;axios.Cancel=axios.CanceledError;axios.all=function(t){return Promise.all(t)};axios.spread=spread$1;axios.isAxiosError=isAxiosError$1;axios.mergeConfig=mergeConfig$1;axios.AxiosHeaders=AxiosHeaders$1;axios.formToJSON=e=>formDataToJSON(utils$2.isHTMLForm(e)?new FormData(e):e);axios.getAdapter=adapters.getAdapter;axios.HttpStatusCode=HttpStatusCode$1;axios.default=axios;const{Axios,AxiosError,CanceledError,isCancel,CancelToken,VERSION,all,Cancel:Cancel$1,isAxiosError,spread,toFormData,AxiosHeaders,HttpStatusCode,formToJSON,getAdapter,mergeConfig}=axios,DrawerItemRecursive=({item:e,depth:t,expandedItems:n,setExpandedItems:i,onSubItemClick:o})=>{const l=e.children&&e.children.length>0,u=`${e.title}-${t}`,f=n[u],p=React.useRef(null),[d,m]=React.useState({maxHeight:0});React.useEffect(()=>{const _=p.current;if(_)if(f){_.style.display="block";const S=_.scrollHeight;m({maxHeight:S});const E=setTimeout(()=>{m({maxHeight:"none"})},300);return()=>clearTimeout(E)}else{const S=_.scrollHeight;m({maxHeight:S});const E=setTimeout(()=>{m({maxHeight:0})},20),b=setTimeout(()=>{_.style.display="none"},300);return()=>{clearTimeout(E),clearTimeout(b)}}},[f]);const g=()=>{i(_=>({..._,[u]:!_[u]}))};return jsxRuntimeExports.jsxs("div",{className:"drawer-item",children:[jsxRuntimeExports.jsxs("div",{className:"drawer-item-header",style:{paddingLeft:`${t*20}px`},onClick:()=>l?g():o(e.title),children:[jsxRuntimeExports.jsx("span",{className:"drawer-icon",children:l?f?"−":"+":""}),jsxRuntimeExports.jsx("span",{className:"drawer-title",children:e.title})]}),l&&jsxRuntimeExports.jsx("div",{className:"drawer-submenu-wrapper",style:{...d,overflow:"hidden",transition:"max-height 0.3s ease-in-out"},children:jsxRuntimeExports.jsx("div",{ref:p,className:"drawer-submenu",children:e.children.map(_=>jsxRuntimeExports.jsx(DrawerItemRecursive,{item:_,depth:t+1,expandedItems:n,setExpandedItems:i,onSubItemClick:o},_.title))})})]})},CEDrawer=({jsonUrl:e,isOpen:t,onClose:n})=>{const i=React.useRef(null),[o,l]=React.useState(),[u,f]=React.useState([]),[p,d]=React.useState({}),[m,g]=React.useState(!0),[_,S]=React.useState(null);React.useEffect(()=>{(async()=>{try{const T=await axios.get(e);l(T.data.headerItem),f(T.data.menuItems||[]),g(!1)}catch{S("Failed to load drawer data."),g(!1)}})()},[e]);const E=b=>{console.log("Clicked:",b)};return m?null:_?jsxRuntimeExports.jsx("div",{className:"drawer-error",children:_}):jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[jsxRuntimeExports.jsx("div",{className:`drawer-overlay ${t?"open":"closed"}`,onClick:n}),jsxRuntimeExports.jsxs("div",{className:`drawer ${t?"open":""}`,ref:i,children:[o&&jsxRuntimeExports.jsxs("div",{className:"drawer-header",children:[o.avatar&&jsxRuntimeExports.jsx("img",{src:o.avatar,alt:"avatar",className:"drawer-avatar"}),jsxRuntimeExports.jsxs("div",{className:"drawer-user-info",children:[jsxRuntimeExports.jsx("div",{className:"drawer-user-title",children:o.title}),o.subtitle&&jsxRuntimeExports.jsx("div",{className:"drawer-user-subtitle",children:o.subtitle})]})]}),u.map(b=>jsxRuntimeExports.jsx(DrawerItemRecursive,{item:b,depth:0,expandedItems:p,setExpandedItems:d,onSubItemClick:E},b.title))]})]})},CEDynamicSearchField=React.forwardRef(({label:e,onSearch:t,onClear:n,error:i=!1,errorMessage:o,fullWidth:l=!1,showClearButton:u=!0,containerClassName:f="",labelClassName:p="",inputClassName:d="",containerStyle:m,className:g,value:_,onChange:S,onKeyDown:E,id:b,...T},C)=>{const[A,R]=React.useState(""),j=b||`ce-search-field-${Math.random().toString(36).substr(2,9)}`,O=()=>jsxRuntimeExports.jsx("svg",{width:"24",height:"25",viewBox:"0 0 24 25",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:jsxRuntimeExports.jsx("path",{d:"M15.5001 14.5H14.7101L14.4301 14.23C15.6301 12.83 16.2501 10.92 15.9101 8.89002C15.4401 6.11002 13.1201 3.89002 10.3201 3.55002C6.09014 3.03002 2.53014 6.59001 3.05014 10.82C3.39014 13.62 5.61014 15.94 8.39014 16.41C10.4201 16.75 12.3301 16.13 13.7301 14.93L14.0001 15.21V16L18.2501 20.25C18.6601 20.66 19.3301 20.66 19.7401 20.25C20.1501 19.84 20.1501 19.17 19.7401 18.76L15.5001 14.5ZM9.50014 14.5C7.01014 14.5 5.00014 12.49 5.00014 10C5.00014 7.51002 7.01014 5.50002 9.50014 5.50002C11.9901 5.50002 14.0001 7.51002 14.0001 10C14.0001 12.49 11.9901 14.5 9.50014 14.5Z",fill:"black",fillOpacity:"0.54"})}),I=_!==void 0?_:A,M=I&&I.toString().length>0,N=W=>{_===void 0&&R(W.target.value),S==null||S(W)},D=W=>{W.key==="Enter"&&t&&t(I.toString()),E==null||E(W)},F=()=>{t&&t(I.toString())},q=()=>{_===void 0&&R(""),n==null||n();const W=document.getElementById(j);if(W&&S){const G=new Event("change",{bubbles:!0});Object.defineProperty(G,"target",{value:W,enumerable:!0}),Object.defineProperty(G,"currentTarget",{value:W,enumerable:!0}),W.value="",S(G)}};return jsxRuntimeExports.jsxs("div",{className:`ce-search-field-container ${l?"full-width":""} ${f}`,style:m,children:[e&&jsxRuntimeExports.jsx("label",{htmlFor:j,className:`ce-search-field-label ${i?"error":""} ${p}`,children:e}),jsxRuntimeExports.jsxs("div",{className:"ce-search-field-wrapper",children:[jsxRuntimeExports.jsx("input",{ref:C,type:"text",id:j,className:`ce-search-field-input ${i?"error":""} ${d} ${g||""}`,value:I,onChange:N,onKeyDown:D,...T}),u&&M&&jsxRuntimeExports.jsx("button",{type:"button",className:"ce-search-field-clear",onClick:q,"aria-label":"Clear search",children:"×"}),jsxRuntimeExports.jsx("button",{type:"button",className:"ce-search-field-button",onClick:F,"aria-label":"Search",children:jsxRuntimeExports.jsx(O,{})})]}),i&&o&&jsxRuntimeExports.jsx("span",{className:"ce-search-field-error-message",children:o})]})});CEDynamicSearchField.displayName="CESearchField";const CEDynamicSelectField=React.forwardRef(({label:e,options:t=[],error:n=!1,errorMessage:i,fullWidth:o=!1,showPlaceholder:l=!0,placeholderText:u="Placeholder",containerClassName:f="",labelClassName:p="",selectClassName:d="",containerStyle:m,className:g,isRequiredLabel:_,id:S,name:E,value:b,...T},C)=>{const A=S||`ce-select-field-${Math.random().toString(36).substr(2,9)}`,R=()=>jsxRuntimeExports.jsx("svg",{width:"24",height:"25",viewBox:"0 0 24 25",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:jsxRuntimeExports.jsx("path",{d:"M8.12021 9.79006L12.0002 13.6701L15.8802 9.79006C16.2702 9.40006 16.9002 9.40006 17.2902 9.79006C17.6802 10.1801 17.6802 10.8101 17.2902 11.2001L12.7002 15.7901C12.3102 16.1801 11.6802 16.1801 11.2902 15.7901L6.70021 11.2001C6.31021 10.8101 6.31021 10.1801 6.70021 9.79006C7.09021 9.41006 7.73021 9.40006 8.12021 9.79006Z",fill:"black",fillOpacity:"0.54"})}),j=b&&t.some(I=>I.value===b),O=l&&t.length>0&&(!b||!j);return jsxRuntimeExports.jsxs("div",{className:`ce-select-field-container ${o?"full-width":""} ${f}`,style:m,children:[e&&jsxRuntimeExports.jsxs("label",{htmlFor:A,className:`ce-select-field-label ${p}`,children:[e,_&&jsxRuntimeExports.jsx("span",{className:"asterisk",children:"*"})]}),jsxRuntimeExports.jsxs("div",{className:"ce-select-field-wrapper",children:[jsxRuntimeExports.jsx("select",{ref:C,id:A,name:E,className:`ce-select-field-select ${n?"error":""} ${d} ${g||""}`,value:b,...T,children:t.length===0?jsxRuntimeExports.jsx("option",{value:"",disabled:!0}):jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[O&&jsxRuntimeExports.jsx("option",{value:"",disabled:T.required,children:u}),t.map(I=>jsxRuntimeExports.jsx("option",{value:I.value,disabled:I.disabled,children:I.label},I.value))]})}),jsxRuntimeExports.jsx("div",{className:"ce-select-field-arrow","aria-hidden":"true",children:jsxRuntimeExports.jsx(R,{})})]}),n&&i&&jsxRuntimeExports.jsx("span",{className:"ce-select-field-error-message",children:i})]})});CEDynamicSelectField.displayName="CESelectField";const CEInputBox=({value:e,onChange:t,placeholder:n="",type:i="text",maxLength:o,required:l=!1,errorMessage:u="Invalid input",showError:f=!0,label:p,labelSuffix:d,disabled:m=!1,style:g={},size:_="medium",onFocus:S,onBlur:E,autoFocus:b=!1,alwaysShowLabel:T,id:C,name:A,onChangeMeta:R,rows:j,decimalScale:O=2})=>{const[I,M]=React.useState(!1),N=e==null?"":String(e),D=V=>{M(!0),S==null||S(V)},F=V=>{M(!1),E==null||E(V)},q=V=>{const z=V.target.value;let L=null;if(i==="number"&&(L=new RegExp(`^-?\\d*\\.?\\d{0,${O}}%?$`)),!(i==="number"&&L&&!L.test(z))&&!(i==="alphanumeric"&&!/^[a-zA-Z0-9]*$/.test(z))){if(i==="number"){if(z===""||z==="-"||z==="."||z==="-."||z.endsWith(".")){t(z),R==null||R(z,{id:C,name:A});return}t(z),R==null||R(z,{id:C,name:A});return}t(z),R==null||R(z,{id:C,name:A})}},W=React.useRef(null);React.useEffect(()=>{i==="textarea"&&W.current&&(W.current.style.height="auto",W.current.style.height=`${W.current.scrollHeight}px`)},[N,i]);const G=getSizeStyle$1(_||"medium"),ee=f&&l&&!N,X={fontSize:G.fontSize,padding:G.padding,...g};return jsxRuntimeExports.jsxs("div",{className:`validated-input-wrapper ${I?"focused":""} ${ee?"error":""}`,children:[p&&jsxRuntimeExports.jsxs("label",{className:`validated-input-label ${T||N||I?"shrink":""}`,children:[p,l&&jsxRuntimeExports.jsx("span",{className:"required-asterisk",children:"*"}),d&&jsxRuntimeExports.jsx("span",{style:{marginLeft:4},children:d})]}),i==="textarea"?jsxRuntimeExports.jsx("textarea",{ref:W,rows:j,value:N,onChange:V=>{t(V.target.value),R==null||R(V.target.value,{id:C,name:A})},onFocus:D,onBlur:F,placeholder:n||" ",id:C,name:A,className:`validated-input-field ${ee?"input-error":""}`,disabled:m,style:X}):jsxRuntimeExports.jsx("input",{type:i==="number"?"text":i,inputMode:i==="number"?"decimal":void 0,value:N,onChange:q,onFocus:D,onBlur:F,placeholder:n||" ",id:C,name:A,className:`validated-input-field ${ee?"input-error":""}`,disabled:m,style:X,autoFocus:b,maxLength:o,onKeyDown:V=>{i==="number"&&["e","E"].includes(V.key)&&V.preventDefault()}}),f&&ee&&jsxRuntimeExports.jsx("div",{className:"validated-input-error",children:u})]})},CEDynamicTextField=React.forwardRef(({label:e,error:t=!1,errorMessage:n,fullWidth:i=!1,containerClassName:o="",labelClassName:l="",inputClassName:u="",containerStyle:f,className:p,id:d,name:m,multiline:g=!1,rows:_,minHeight:S,width:E,validationType:b,...T},C)=>{function A(G,ee){if(!ee)return G;switch(ee){case"number":let X=G.replace(/[^0-9.]/g,"");const V=X.split(".");return V.length>1&&(X=V.shift()+"."+V.join("")),X;case"alphanumeric":return G.replace(/[^A-Za-z0-9]/g,"");case"alpha":return G.replace(/[^A-Za-z]/g,"");case"alphanumericWithSpecial":return G.replace(/[^A-Za-z0-9\s!@#\$%\^&\*\(\)_\+":><,\.\?\/~`\[\]\\|\-]/g,"");case"alphaWithoutSpecial":return G.replace(/[^A-Za-z\s]/g,"");default:return G}}const[R,j]=React.useState(()=>A(String(T.value??""),b)),O=React.useRef(!1);React.useEffect(()=>{if(T.value!==void 0){const G=A(String(T.value),b);G!==R&&j(G)}},[T.value,b]);const I=(G,ee)=>{if(T.onChange){const X=ee?{...ee,target:{...ee.target,value:G}}:{target:{value:G,name:m}};T.onChange(X)}},M=(G,ee)=>{if(O.current){j(G);return}const X=A(G,b);j(X),I(X,ee)},N=()=>{O.current=!0},D=G=>{O.current=!1;const ee=G.target.value;M(ee,G)},F=G=>{var H;G.preventDefault();const ee=((H=G.clipboardData)==null?void 0:H.getData("text"))??"",X=G.target,V=X.selectionStart??X.value.length,z=X.selectionEnd??V,L=R.slice(0,V),B=R.slice(z),U=L+ee+B;let K=A(U,b);if(b==="number"){const J=K.split(".");J.length>1&&(K=J.shift()+"."+J.join(""))}j(K),I(K,G)},q=d||`ce-text-field-${Math.random().toString(36).substr(2,9)}`,W={};return S!=null&&(W.minHeight=typeof S=="number"?`${S}px`:S),E!=null&&(W.width=typeof E=="number"?`${E}px`:E),jsxRuntimeExports.jsxs("div",{className:`ce-text-field-container ${i?"full-width":""} ${o}`,style:f,children:[e&&jsxRuntimeExports.jsxs("label",{htmlFor:q,className:`ce-text-field-label ${t?"error":""} ${l}`,children:[e,T.required&&jsxRuntimeExports.jsx("span",{className:"required-asterisk",children:"*"})]}),g?jsxRuntimeExports.jsx(CEInputBox,{type:"textarea",value:R,onChange:G=>M(String(G)),id:q,name:m,placeholder:T.placeholder,errorMessage:n,showError:t,label:e,required:T.required,alwaysShowLabel:!0,style:Object.keys(W).length?W:void 0}):jsxRuntimeExports.jsx("input",{ref:C,type:"text",id:q,name:m,className:`ce-text-field-input ${t?"error":""} ${u} ${p||""}`,...T,value:R,onChange:G=>M(G.target.value,G),onCompositionStart:N,onCompositionEnd:D,onPaste:F}),t&&n&&jsxRuntimeExports.jsx("span",{className:"ce-text-field-error-message",children:n})]})});CEDynamicTextField.displayName="CETextField";const uploadWrapper="_uploadWrapper_17z69_1",dropZone="_dropZone_17z69_15",dropZoneActive="_dropZoneActive_17z69_33",uploadButton="_uploadButton_17z69_49",fileTable="_fileTable_17z69_67",note="_note_17z69_105",errorText="_errorText_17z69_119",fileUploadPagination="_fileUploadPagination_17z69_135",styles$1={uploadWrapper,dropZone,dropZoneActive,uploadButton,fileTable,note,errorText,fileUploadPagination},DEFAULT_EXTS$1=[".csv",".xlsx",".xls",".pdf",".docx",".doc",".jpg",".jpeg",".png",".bmp",".txt",".zip"],normalizeExts$1=e=>{const t=(e&&e.length?e:DEFAULT_EXTS$1).map(n=>n.startsWith(".")?n.toLowerCase():`.${n.toLowerCase()}`);return Array.from(new Set(t))},CEFileUploadDocument=({onUpload:e,accept:t,initialFiles:n=[],showPathColumn:i=!1,showType:o=!1,onDelete:l,onDownload:u,showPagination:f=!1,pageSizeOptions:p=[10,20,50,100]})=>{const d=React.useRef(null),[m,g]=React.useState([]),[_,S]=React.useState(null),[E,b]=React.useState(!1),[T,C]=React.useState(10),[A,R]=React.useState(0);React.useEffect(()=>{g(z=>{const L=new Set(z.map(U=>U.id??U.name)),B=n.filter(U=>!L.has(U.id??U.name));return[...z,...B]})},[n]);const j=normalizeExts$1(t),O=j.join(","),I=j.join(", "),M=z=>{const L=z.lastIndexOf(".");return L>=0?z.slice(L).toLowerCase():""},N=z=>j.includes(M(z.name)),D=z=>{const L=new Date().toLocaleDateString(),B=z.filter(N),U=z.filter(H=>!N(H));S(U.length?`Unsupported file(s): ${U.map(H=>H.name).join(", ")}`:null);const K=B.map(H=>({name:H.name,type:H.type,uploadDate:L,file:H}));g(H=>{const J=new Set(H.map(te=>te.name)),Z=K.filter(te=>!J.has(te.name));return[...H,...Z]}),e&&K.length>0&&e(K)},F=z=>{const L=Array.from(z.target.files||[]);D(L),d.current&&(d.current.value="")},q=z=>z.preventDefault(),W=z=>{z.preventDefault(),b(!0)},G=z=>{z.preventDefault(),b(!1)},ee=z=>{z.preventDefault(),b(!1);const L=Array.from(z.dataTransfer.files||[]);D(L),z.dataTransfer.clearData()},X=z=>{g(L=>{let B;const U=L.filter(K=>{const H=K.id===z||K.name===z;return H&&(B=K),!H});return B&&(l==null||l(B)),U})},V=z=>{u==null||u(z)};return jsxRuntimeExports.jsxs("div",{className:styles$1.uploadWrapper,children:[jsxRuntimeExports.jsxs("div",{onDrop:ee,onDragOver:q,onDragEnter:W,onDragLeave:G,className:`${styles$1.dropZone} ${E?styles$1.dropZoneActive:""}`,onClick:()=>{var z;return(z=d.current)==null?void 0:z.click()},role:"button",tabIndex:0,children:[jsxRuntimeExports.jsx("p",{children:"Drop your file here or click to browse"}),jsxRuntimeExports.jsxs("p",{children:["Supported formats: ",I]}),jsxRuntimeExports.jsx("button",{type:"button",className:styles$1.uploadButton,onClick:z=>{var L;z.stopPropagation(),(L=d.current)==null||L.click()},children:"⬆️ Select Document"}),jsxRuntimeExports.jsx("input",{ref:d,type:"file",accept:O,multiple:!0,onChange:F,style:{display:"none"}})]}),_&&jsxRuntimeExports.jsx("p",{className:styles$1.errorText,children:_}),jsxRuntimeExports.jsxs("table",{className:styles$1.fileTable,children:[jsxRuntimeExports.jsx("thead",{children:jsxRuntimeExports.jsxs("tr",{children:[jsxRuntimeExports.jsx("th",{children:"Document Name"}),i&&jsxRuntimeExports.jsx("th",{children:"Path"}),o&&jsxRuntimeExports.jsx("th",{children:"Type"}),jsxRuntimeExports.jsx("th",{children:"Upload Date"}),jsxRuntimeExports.jsx("th",{children:"Actions"})]})}),jsxRuntimeExports.jsx("tbody",{children:m.length===0?jsxRuntimeExports.jsx("tr",{children:jsxRuntimeExports.jsx("td",{colSpan:i?5:4,style:{textAlign:"center"},children:"No records to display."})}):m.slice(A*T,A*T+T).map((z,L)=>jsxRuntimeExports.jsxs("tr",{children:[jsxRuntimeExports.jsx("td",{children:z.name}),i&&jsxRuntimeExports.jsx("td",{children:z.path??"-"}),o&&jsxRuntimeExports.jsx("td",{children:z.type??"-"}),jsxRuntimeExports.jsx("td",{children:z.uploadDate}),jsxRuntimeExports.jsxs("td",{children:[jsxRuntimeExports.jsx("button",{type:"button",onClick:()=>X(z.id??z.name),children:"🗑️"})," ",jsxRuntimeExports.jsx("button",{type:"button",onClick:()=>V(z),children:"⬇️"})]})]},z.id??`${z.name}-${L}`))})]}),f&&jsxRuntimeExports.jsxs("div",{className:styles$1.fileUploadPagination,children:[jsxRuntimeExports.jsxs("div",{children:[jsxRuntimeExports.jsx("label",{htmlFor:"rows-per-page-select",children:"Rows per page: "}),jsxRuntimeExports.jsx("select",{id:"rows-per-page-select",value:T,onChange:z=>C(parseInt(z.target.value,10)),children:p.map(z=>jsxRuntimeExports.jsx("option",{value:z,children:z},z))})]}),jsxRuntimeExports.jsxs("div",{children:[m.length>0&&jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[m.length===0?0:A*T+1," -"," ",Math.min((A+1)*T,m.length)," of"," ",m.length]}),jsxRuntimeExports.jsx("button",{onClick:()=>R(A-1),disabled:A===0,className:"pagination-button",style:{marginLeft:"5px"},children:"Previous"}),jsxRuntimeExports.jsx("button",{onClick:()=>R(A+1),disabled:A>=Math.ceil(m.length/T)-1,className:"pagination-button",children:"Next"})]})]}),jsxRuntimeExports.jsxs("p",{className:styles$1.note,children:[jsxRuntimeExports.jsx("strong",{children:"Note:"})," if the file did not appear, your browser may block pop-ups."]})]})},CECustomModal=({isOpen:e,onClose:t,title:n,children:i,primaryButtonText:o,secondaryButtonText:l,onPrimaryClick:u,onSecondaryClick:f,width:p,height:d,style:m={}})=>{if(React.useEffect(()=>{const _=S=>{S.key==="Escape"&&t()};return document.addEventListener("keydown",_),()=>document.removeEventListener("keydown",_)},[t]),!e)return null;const g={...m};return p!=null&&(g.width=typeof p=="number"?`${p}px`:p),d!=null&&(g.height=typeof d=="number"?`${d}px`:d),ReactDOM.createPortal(jsxRuntimeExports.jsx("div",{className:"modal-overlay",children:jsxRuntimeExports.jsxs("div",{className:"modal-container",style:g,onClick:_=>_.stopPropagation(),children:[jsxRuntimeExports.jsxs("div",{className:"modal-header",children:[jsxRuntimeExports.jsx("span",{className:"modal-title",children:n}),jsxRuntimeExports.jsx("button",{className:"modal-close",onClick:t,"aria-label":"Close modal",children:"×"})]}),jsxRuntimeExports.jsx("div",{className:"modal-content",children:i}),(o||l)&&jsxRuntimeExports.jsxs("div",{className:"modal-footer",children:[l&&jsxRuntimeExports.jsx(CEButton,{variant:"outlinedGreen",onClick:f??(()=>{}),children:l}),o&&jsxRuntimeExports.jsx(CEButton,{className:"modal-button primary",onClick:u??(()=>{}),children:o})]})]})}),document.body)},CEUploadModalWrapper=()=>{const[e,t]=React.useState(!1);return jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[jsxRuntimeExports.jsx("button",{onClick:()=>t(!0),children:"Open Upload Modal"}),jsxRuntimeExports.jsx(CECustomModal,{isOpen:e,onClose:()=>t(!1),title:"Upload File",primaryButtonText:"Close",onPrimaryClick:()=>t(!1),children:jsxRuntimeExports.jsx(CEFileUploadDocument,{onUpload:n=>console.log("Uploaded:",n)})})]})},common={black:"#000",white:"#fff"},red={300:"#e57373",400:"#ef5350",500:"#f44336",700:"#d32f2f",800:"#c62828"},purple={50:"#f3e5f5",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",700:"#7b1fa2"},blue={50:"#e3f2fd",200:"#90caf9",400:"#42a5f5",700:"#1976d2",800:"#1565c0"},lightBlue={300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",700:"#0288d1",900:"#01579b"},green={300:"#81c784",400:"#66bb6a",500:"#4caf50",700:"#388e3c",800:"#2e7d32",900:"#1b5e20"},orange={300:"#ffb74d",400:"#ffa726",500:"#ff9800",700:"#f57c00",900:"#e65100"},grey={50:"#fafafa",100:"#f5f5f5",200:"#eeeeee",300:"#e0e0e0",400:"#bdbdbd",500:"#9e9e9e",600:"#757575",700:"#616161",800:"#424242",900:"#212121",A100:"#f5f5f5",A200:"#eeeeee",A400:"#bdbdbd",A700:"#616161"};function formatMuiErrorMessage(e,...t){const n=new URL(`https://mui.com/production-error/?code=${e}`);return t.forEach(i=>n.searchParams.append("args[]",i)),`Minified MUI error #${e}; visit ${n} for the full message.`}const THEME_ID="$$material";function _extends$z(){return _extends$z=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)({}).hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},_extends$z.apply(null,arguments)}function sheetForTag(e){if(e.sheet)return e.sheet;for(var t=0;t<document.styleSheets.length;t++)if(document.styleSheets[t].ownerNode===e)return document.styleSheets[t]}function createStyleElement(e){var t=document.createElement("style");return t.setAttribute("data-emotion",e.key),e.nonce!==void 0&&t.setAttribute("nonce",e.nonce),t.appendChild(document.createTextNode("")),t.setAttribute("data-s",""),t}var StyleSheet=function(){function e(n){var i=this;this._insertTag=function(o){var l;i.tags.length===0?i.insertionPoint?l=i.insertionPoint.nextSibling:i.prepend?l=i.container.firstChild:l=i.before:l=i.tags[i.tags.length-1].nextSibling,i.container.insertBefore(o,l),i.tags.push(o)},this.isSpeedy=n.speedy===void 0?!0:n.speedy,this.tags=[],this.ctr=0,this.nonce=n.nonce,this.key=n.key,this.container=n.container,this.prepend=n.prepend,this.insertionPoint=n.insertionPoint,this.before=null}var t=e.prototype;return t.hydrate=function(i){i.forEach(this._insertTag)},t.insert=function(i){this.ctr%(this.isSpeedy?65e3:1)===0&&this._insertTag(createStyleElement(this));var o=this.tags[this.tags.length-1];if(this.isSpeedy){var l=sheetForTag(o);try{l.insertRule(i,l.cssRules.length)}catch{}}else o.appendChild(document.createTextNode(i));this.ctr++},t.flush=function(){this.tags.forEach(function(i){var o;return(o=i.parentNode)==null?void 0:o.removeChild(i)}),this.tags=[],this.ctr=0},e}(),MS="-ms-",MOZ="-moz-",WEBKIT="-webkit-",COMMENT="comm",RULESET="rule",DECLARATION="decl",IMPORT="@import",KEYFRAMES="@keyframes",LAYER="@layer",abs=Math.abs,from=String.fromCharCode,assign$1=Object.assign;function hash$2(e,t){return charat(e,0)^45?(((t<<2^charat(e,0))<<2^charat(e,1))<<2^charat(e,2))<<2^charat(e,3):0}function trim(e){return e.trim()}function match(e,t){return(e=t.exec(e))?e[0]:e}function replace(e,t,n){return e.replace(t,n)}function indexof(e,t){return e.indexOf(t)}function charat(e,t){return e.charCodeAt(t)|0}function substr(e,t,n){return e.slice(t,n)}function strlen(e){return e.length}function sizeof(e){return e.length}function append$1(e,t){return t.push(e),e}function combine(e,t){return e.map(t).join("")}var line=1,column=1,length=0,position=0,character=0,characters="";function node(e,t,n,i,o,l,u){return{value:e,root:t,parent:n,type:i,props:o,children:l,line,column,length:u,return:""}}function copy$2(e,t){return assign$1(node("",null,null,"",null,null,0),e,{length:-e.length},t)}function char(){return character}function prev(){return character=position>0?charat(characters,--position):0,column--,character===10&&(column=1,line--),character}function next(){return character=position<length?charat(characters,position++):0,column++,character===10&&(column=1,line++),character}function peek(){return charat(characters,position)}function caret(){return position}function slice(e,t){return substr(characters,e,t)}function token(e){switch(e){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function alloc(e){return line=column=1,length=strlen(characters=e),position=0,[]}function dealloc(e){return characters="",e}function delimit(e){return trim(slice(position-1,delimiter(e===91?e+2:e===40?e+1:e)))}function whitespace(e){for(;(character=peek())&&character<33;)next();return token(e)>2||token(character)>3?"":" "}function escaping(e,t){for(;--t&&next()&&!(character<48||character>102||character>57&&character<65||character>70&&character<97););return slice(e,caret()+(t<6&&peek()==32&&next()==32))}function delimiter(e){for(;next();)switch(character){case e:return position;case 34:case 39:e!==34&&e!==39&&delimiter(character);break;case 40:e===41&&delimiter(e);break;case 92:next();break}return position}function commenter(e,t){for(;next()&&e+character!==57;)if(e+character===84&&peek()===47)break;return"/*"+slice(t,position-1)+"*"+from(e===47?e:next())}function identifier(e){for(;!token(peek());)next();return slice(e,position)}function compile(e){return dealloc(parse("",null,null,null,[""],e=alloc(e),0,[0],e))}function parse(e,t,n,i,o,l,u,f,p){for(var d=0,m=0,g=u,_=0,S=0,E=0,b=1,T=1,C=1,A=0,R="",j=o,O=l,I=i,M=R;T;)switch(E=A,A=next()){case 40:if(E!=108&&charat(M,g-1)==58){indexof(M+=replace(delimit(A),"&","&\f"),"&\f")!=-1&&(C=-1);break}case 34:case 39:case 91:M+=delimit(A);break;case 9:case 10:case 13:case 32:M+=whitespace(E);break;case 92:M+=escaping(caret()-1,7);continue;case 47:switch(peek()){case 42:case 47:append$1(comment(commenter(next(),caret()),t,n),p);break;default:M+="/"}break;case 123*b:f[d++]=strlen(M)*C;case 125*b:case 59:case 0:switch(A){case 0:case 125:T=0;case 59+m:C==-1&&(M=replace(M,/\f/g,"")),S>0&&strlen(M)-g&&append$1(S>32?declaration(M+";",i,n,g-1):declaration(replace(M," ","")+";",i,n,g-2),p);break;case 59:M+=";";default:if(append$1(I=ruleset(M,t,n,d,m,o,f,R,j=[],O=[],g),l),A===123)if(m===0)parse(M,t,I,I,j,l,g,f,O);else switch(_===99&&charat(M,3)===110?100:_){case 100:case 108:case 109:case 115:parse(e,I,I,i&&append$1(ruleset(e,I,I,0,0,o,f,R,o,j=[],g),O),o,O,g,f,i?j:O);break;default:parse(M,I,I,I,[""],O,0,f,O)}}d=m=S=0,b=C=1,R=M="",g=u;break;case 58:g=1+strlen(M),S=E;default:if(b<1){if(A==123)--b;else if(A==125&&b++==0&&prev()==125)continue}switch(M+=from(A),A*b){case 38:C=m>0?1:(M+="\f",-1);break;case 44:f[d++]=(strlen(M)-1)*C,C=1;break;case 64:peek()===45&&(M+=delimit(next())),_=peek(),m=g=strlen(R=M+=identifier(caret())),A++;break;case 45:E===45&&strlen(M)==2&&(b=0)}}return l}function ruleset(e,t,n,i,o,l,u,f,p,d,m){for(var g=o-1,_=o===0?l:[""],S=sizeof(_),E=0,b=0,T=0;E<i;++E)for(var C=0,A=substr(e,g+1,g=abs(b=u[E])),R=e;C<S;++C)(R=trim(b>0?_[C]+" "+A:replace(A,/&\f/g,_[C])))&&(p[T++]=R);return node(e,t,n,o===0?RULESET:f,p,d,m)}function comment(e,t,n){return node(e,t,n,COMMENT,from(char()),substr(e,2,-2),0)}function declaration(e,t,n,i){return node(e,t,n,DECLARATION,substr(e,0,i),substr(e,i+1,-1),i)}function serialize(e,t){for(var n="",i=sizeof(e),o=0;o<i;o++)n+=t(e[o],o,e,t)||"";return n}function stringify(e,t,n,i){switch(e.type){case LAYER:if(e.children.length)break;case IMPORT:case DECLARATION:return e.return=e.return||e.value;case COMMENT:return"";case KEYFRAMES:return e.return=e.value+"{"+serialize(e.children,i)+"}";case RULESET:e.value=e.props.join(",")}return strlen(n=serialize(e.children,i))?e.return=e.value+"{"+n+"}":""}function middleware(e){var t=sizeof(e);return function(n,i,o,l){for(var u="",f=0;f<t;f++)u+=e[f](n,i,o,l)||"";return u}}function rulesheet(e){return function(t){t.root||(t=t.return)&&e(t)}}function memoize$3(e){var t=Object.create(null);return function(n){return t[n]===void 0&&(t[n]=e(n)),t[n]}}var identifierWithPointTracking=function(t,n,i){for(var o=0,l=0;o=l,l=peek(),o===38&&l===12&&(n[i]=1),!token(l);)next();return slice(t,position)},toRules=function(t,n){var i=-1,o=44;do switch(token(o)){case 0:o===38&&peek()===12&&(n[i]=1),t[i]+=identifierWithPointTracking(position-1,n,i);break;case 2:t[i]+=delimit(o);break;case 4:if(o===44){t[++i]=peek()===58?"&\f":"",n[i]=t[i].length;break}default:t[i]+=from(o)}while(o=next());return t},getRules=function(t,n){return dealloc(toRules(alloc(t),n))},fixedElements=new WeakMap,compat=function(t){if(!(t.type!=="rule"||!t.parent||t.length<1)){for(var n=t.value,i=t.parent,o=t.column===i.column&&t.line===i.line;i.type!=="rule";)if(i=i.parent,!i)return;if(!(t.props.length===1&&n.charCodeAt(0)!==58&&!fixedElements.get(i))&&!o){fixedElements.set(t,!0);for(var l=[],u=getRules(n,l),f=i.props,p=0,d=0;p<u.length;p++)for(var m=0;m<f.length;m++,d++)t.props[d]=l[p]?u[p].replace(/&\f/g,f[m]):f[m]+" "+u[p]}}},removeLabel=function(t){if(t.type==="decl"){var n=t.value;n.charCodeAt(0)===108&&n.charCodeAt(2)===98&&(t.return="",t.value="")}};function prefix$1(e,t){switch(hash$2(e,t)){case 5103:return WEBKIT+"print-"+e+e;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return WEBKIT+e+e;case 5349:case 4246:case 4810:case 6968:case 2756:return WEBKIT+e+MOZ+e+MS+e+e;case 6828:case 4268:return WEBKIT+e+MS+e+e;case 6165:return WEBKIT+e+MS+"flex-"+e+e;case 5187:return WEBKIT+e+replace(e,/(\w+).+(:[^]+)/,WEBKIT+"box-$1$2"+MS+"flex-$1$2")+e;case 5443:return WEBKIT+e+MS+"flex-item-"+replace(e,/flex-|-self/,"")+e;case 4675:return WEBKIT+e+MS+"flex-line-pack"+replace(e,/align-content|flex-|-self/,"")+e;case 5548:return WEBKIT+e+MS+replace(e,"shrink","negative")+e;case 5292:return WEBKIT+e+MS+replace(e,"basis","preferred-size")+e;case 6060:return WEBKIT+"box-"+replace(e,"-grow","")+WEBKIT+e+MS+replace(e,"grow","positive")+e;case 4554:return WEBKIT+replace(e,/([^-])(transform)/g,"$1"+WEBKIT+"$2")+e;case 6187:return replace(replace(replace(e,/(zoom-|grab)/,WEBKIT+"$1"),/(image-set)/,WEBKIT+"$1"),e,"")+e;case 5495:case 3959:return replace(e,/(image-set\([^]*)/,WEBKIT+"$1$`$1");case 4968:return replace(replace(e,/(.+:)(flex-)?(.*)/,WEBKIT+"box-pack:$3"+MS+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+WEBKIT+e+e;case 4095:case 3583:case 4068:case 2532:return replace(e,/(.+)-inline(.+)/,WEBKIT+"$1$2")+e;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(strlen(e)-1-t>6)switch(charat(e,t+1)){case 109:if(charat(e,t+4)!==45)break;case 102:return replace(e,/(.+:)(.+)-([^]+)/,"$1"+WEBKIT+"$2-$3$1"+MOZ+(charat(e,t+3)==108?"$3":"$2-$3"))+e;case 115:return~indexof(e,"stretch")?prefix$1(replace(e,"stretch","fill-available"),t)+e:e}break;case 4949:if(charat(e,t+1)!==115)break;case 6444:switch(charat(e,strlen(e)-3-(~indexof(e,"!important")&&10))){case 107:return replace(e,":",":"+WEBKIT)+e;case 101:return replace(e,/(.+:)([^;!]+)(;|!.+)?/,"$1"+WEBKIT+(charat(e,14)===45?"inline-":"")+"box$3$1"+WEBKIT+"$2$3$1"+MS+"$2box$3")+e}break;case 5936:switch(charat(e,t+11)){case 114:return WEBKIT+e+MS+replace(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return WEBKIT+e+MS+replace(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return WEBKIT+e+MS+replace(e,/[svh]\w+-[tblr]{2}/,"lr")+e}return WEBKIT+e+MS+e+e}return e}var prefixer=function(t,n,i,o){if(t.length>-1&&!t.return)switch(t.type){case DECLARATION:t.return=prefix$1(t.value,t.length);break;case KEYFRAMES:return serialize([copy$2(t,{value:replace(t.value,"@","@"+WEBKIT)})],o);case RULESET:if(t.length)return combine(t.props,function(l){switch(match(l,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return serialize([copy$2(t,{props:[replace(l,/:(read-\w+)/,":"+MOZ+"$1")]})],o);case"::placeholder":return serialize([copy$2(t,{props:[replace(l,/:(plac\w+)/,":"+WEBKIT+"input-$1")]}),copy$2(t,{props:[replace(l,/:(plac\w+)/,":"+MOZ+"$1")]}),copy$2(t,{props:[replace(l,/:(plac\w+)/,MS+"input-$1")]})],o)}return""})}},defaultStylisPlugins=[prefixer],createCache=function(t){var n=t.key;if(n==="css"){var i=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(i,function(b){var T=b.getAttribute("data-emotion");T.indexOf(" ")!==-1&&(document.head.appendChild(b),b.setAttribute("data-s",""))})}var o=t.stylisPlugins||defaultStylisPlugins,l={},u,f=[];u=t.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+n+' "]'),function(b){for(var T=b.getAttribute("data-emotion").split(" "),C=1;C<T.length;C++)l[T[C]]=!0;f.push(b)});var p,d=[compat,removeLabel];{var m,g=[stringify,rulesheet(function(b){m.insert(b)})],_=middleware(d.concat(o,g)),S=function(T){return serialize(compile(T),_)};p=function(T,C,A,R){m=A,S(T?T+"{"+C.styles+"}":C.styles),R&&(E.inserted[C.name]=!0)}}var E={key:n,sheet:new StyleSheet({key:n,container:u,nonce:t.nonce,speedy:t.speedy,prepend:t.prepend,insertionPoint:t.insertionPoint}),nonce:t.nonce,inserted:l,registered:{},insert:p};return E.sheet.hydrate(f),E},reactIs$3={exports:{}},reactIs_production_min$2={};/** @license React v16.13.1
|
|
39
39
|
* react-is.production.min.js
|
|
40
40
|
*
|
|
41
41
|
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
@@ -4120,52 +4120,45 @@ const CEInputBox = ({
|
|
|
4120
4120
|
id: C,
|
|
4121
4121
|
name: R,
|
|
4122
4122
|
onChangeMeta: A,
|
|
4123
|
-
rows: j
|
|
4123
|
+
rows: j,
|
|
4124
|
+
decimalScale: O = 2
|
|
4124
4125
|
}) => {
|
|
4125
|
-
const [
|
|
4126
|
-
|
|
4127
|
-
},
|
|
4128
|
-
|
|
4129
|
-
},
|
|
4130
|
-
const
|
|
4131
|
-
|
|
4126
|
+
const [I, M] = useState(!1), N = e == null ? "" : String(e), D = (V) => {
|
|
4127
|
+
M(!0), S == null || S(V);
|
|
4128
|
+
}, F = (V) => {
|
|
4129
|
+
M(!1), E == null || E(V);
|
|
4130
|
+
}, q = (V) => {
|
|
4131
|
+
const z = V.target.value;
|
|
4132
|
+
let L = null;
|
|
4133
|
+
if (i === "number" && (L = new RegExp(`^-?\\d*\\.?\\d{0,${O}}%?$`)), !(i === "number" && L && !L.test(z)) && !(i === "alphanumeric" && !/^[a-zA-Z0-9]*$/.test(z))) {
|
|
4132
4134
|
if (i === "number") {
|
|
4133
|
-
if (
|
|
4134
|
-
t(
|
|
4135
|
-
return;
|
|
4136
|
-
}
|
|
4137
|
-
if (V.endsWith("%")) {
|
|
4138
|
-
t(V), A == null || A(V, { id: C, name: R });
|
|
4135
|
+
if (z === "" || z === "-" || z === "." || z === "-." || z.endsWith(".")) {
|
|
4136
|
+
t(z), A == null || A(z, { id: C, name: R });
|
|
4139
4137
|
return;
|
|
4140
4138
|
}
|
|
4141
|
-
|
|
4142
|
-
t(V), A == null || A(V, { id: C, name: R });
|
|
4143
|
-
return;
|
|
4144
|
-
}
|
|
4145
|
-
const z = Number(V), L = Number.isNaN(z) ? V : z;
|
|
4146
|
-
t(L), A == null || A(L, { id: C, name: R });
|
|
4139
|
+
t(z), A == null || A(z, { id: C, name: R });
|
|
4147
4140
|
return;
|
|
4148
4141
|
}
|
|
4149
|
-
t(
|
|
4142
|
+
t(z), A == null || A(z, { id: C, name: R });
|
|
4150
4143
|
}
|
|
4151
|
-
},
|
|
4144
|
+
}, W = useRef(null);
|
|
4152
4145
|
useEffect(() => {
|
|
4153
|
-
i === "textarea" &&
|
|
4154
|
-
}, [
|
|
4155
|
-
const
|
|
4156
|
-
fontSize:
|
|
4157
|
-
padding:
|
|
4146
|
+
i === "textarea" && W.current && (W.current.style.height = "auto", W.current.style.height = `${W.current.scrollHeight}px`);
|
|
4147
|
+
}, [N, i]);
|
|
4148
|
+
const G = getSizeStyle$1(_ || "medium"), ee = f && l && !N, X = {
|
|
4149
|
+
fontSize: G.fontSize,
|
|
4150
|
+
padding: G.padding,
|
|
4158
4151
|
...g
|
|
4159
4152
|
};
|
|
4160
4153
|
return /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
4161
4154
|
"div",
|
|
4162
4155
|
{
|
|
4163
|
-
className: `validated-input-wrapper ${
|
|
4156
|
+
className: `validated-input-wrapper ${I ? "focused" : ""} ${ee ? "error" : ""}`,
|
|
4164
4157
|
children: [
|
|
4165
4158
|
p && /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
4166
4159
|
"label",
|
|
4167
4160
|
{
|
|
4168
|
-
className: `validated-input-label ${T ||
|
|
4161
|
+
className: `validated-input-label ${T || N || I ? "shrink" : ""}`,
|
|
4169
4162
|
children: [
|
|
4170
4163
|
p,
|
|
4171
4164
|
l && /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "required-asterisk", children: "*" }),
|
|
@@ -4176,44 +4169,44 @@ const CEInputBox = ({
|
|
|
4176
4169
|
i === "textarea" ? /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
4177
4170
|
"textarea",
|
|
4178
4171
|
{
|
|
4179
|
-
ref:
|
|
4172
|
+
ref: W,
|
|
4180
4173
|
rows: j,
|
|
4181
|
-
value:
|
|
4182
|
-
onChange: (
|
|
4183
|
-
t(
|
|
4174
|
+
value: N,
|
|
4175
|
+
onChange: (V) => {
|
|
4176
|
+
t(V.target.value), A == null || A(V.target.value, { id: C, name: R });
|
|
4184
4177
|
},
|
|
4185
|
-
onFocus:
|
|
4186
|
-
onBlur:
|
|
4178
|
+
onFocus: D,
|
|
4179
|
+
onBlur: F,
|
|
4187
4180
|
placeholder: n || " ",
|
|
4188
4181
|
id: C,
|
|
4189
4182
|
name: R,
|
|
4190
|
-
className: `validated-input-field ${
|
|
4183
|
+
className: `validated-input-field ${ee ? "input-error" : ""}`,
|
|
4191
4184
|
disabled: m,
|
|
4192
|
-
style:
|
|
4185
|
+
style: X
|
|
4193
4186
|
}
|
|
4194
4187
|
) : /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
4195
4188
|
"input",
|
|
4196
4189
|
{
|
|
4197
4190
|
type: i === "number" ? "text" : i,
|
|
4198
4191
|
inputMode: i === "number" ? "decimal" : void 0,
|
|
4199
|
-
value:
|
|
4200
|
-
onChange:
|
|
4201
|
-
onFocus:
|
|
4202
|
-
onBlur:
|
|
4192
|
+
value: N,
|
|
4193
|
+
onChange: q,
|
|
4194
|
+
onFocus: D,
|
|
4195
|
+
onBlur: F,
|
|
4203
4196
|
placeholder: n || " ",
|
|
4204
4197
|
id: C,
|
|
4205
4198
|
name: R,
|
|
4206
|
-
className: `validated-input-field ${
|
|
4199
|
+
className: `validated-input-field ${ee ? "input-error" : ""}`,
|
|
4207
4200
|
disabled: m,
|
|
4208
|
-
style:
|
|
4201
|
+
style: X,
|
|
4209
4202
|
autoFocus: b,
|
|
4210
4203
|
maxLength: o,
|
|
4211
|
-
onKeyDown: (
|
|
4212
|
-
i === "number" && ["e", "E"].includes(
|
|
4204
|
+
onKeyDown: (V) => {
|
|
4205
|
+
i === "number" && ["e", "E"].includes(V.key) && V.preventDefault();
|
|
4213
4206
|
}
|
|
4214
4207
|
}
|
|
4215
4208
|
),
|
|
4216
|
-
f &&
|
|
4209
|
+
f && ee && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "validated-input-error", children: u })
|
|
4217
4210
|
]
|
|
4218
4211
|
}
|
|
4219
4212
|
);
|
|
@@ -28,6 +28,7 @@ interface ValidatedInputProps {
|
|
|
28
28
|
onBlur?: (e: FocusEvent<HTMLInputElement | HTMLTextAreaElement>) => void;
|
|
29
29
|
autoFocus?: boolean;
|
|
30
30
|
alwaysShowLabel?: boolean;
|
|
31
|
+
decimalScale?: number;
|
|
31
32
|
}
|
|
32
33
|
declare const CEInputBox: React.FC<ValidatedInputProps>;
|
|
33
34
|
export default CEInputBox;
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "cecomponent",
|
|
3
3
|
"description": "A React component library for building modern UIs for Cleanearth",
|
|
4
|
-
"version": "1.0.
|
|
4
|
+
"version": "1.0.187",
|
|
5
5
|
"main": "dist/ce-component-lib.js",
|
|
6
6
|
"module": "dist/ce-component-lib.mjs",
|
|
7
7
|
"types": "dist/idex.d.ts",
|