dynamic-html-helpers 1.0.8 → 1.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/Bundle/htmlhelpers.min.js +15 -15
- package/Bundle/htmlhelpers.script.min.js +15 -15
- package/package.json +1 -1
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
var gr=Object.defineProperty,l=(e,t)=>gr(e,"name",{value:t,configurable:!0}),{IS:p,maybe:pr,$Wrap:wo,xProxy:To,isNothing:$o}=ft();function ft(){Symbol.proxy=Symbol.for("toa.proxy"),Symbol.is=Symbol.for("toa.is"),Symbol.type=Symbol.for("toa.type"),Symbol.isSymbol=Symbol.for("toa.isASymbol"),f();let e=v(),[t,n]=[y(),A()];return n.custom(),{IS:r,maybe:e,$Wrap:t,isNothing:g,xProxy:n};function r(a,...s){if(e({trial:l(d=>"isTypes"in(s?.[0]??{}),"trial")})){let d=s[0];return"defaultValue"in d?w(a,d):"notTypes"in d?S(a,d):r(a,...[d.isTypes].flat())}let m=typeof a=="symbol"?Symbol.isSymbol:a;return s.length>1?h(m,...s):i(a,...s)}function o(a){return a?.[Symbol.proxy]??r(a)}function i(a,...s){let{noInput:m,noShouldbe:d,compareTo:T,inputCTOR:j,isNaN:I,isInfinity:k,shouldBeFirstElementIsNothing:P}=u(a,...s);switch(s=s.length&&s[0],!0){case P:return String(a)===String(T);case(a?.[Symbol.proxy]&&d):return a[Symbol.proxy];case I:return d?"NaN":e({trial:l(Z=>String(T),"trial")})===String(a);case k:return d?"Infinity":e({trial:l(Z=>String(T),"trial")})===String(a);case m:return d?String(a):String(T)===String(a);case j===Boolean:return s?j===s:"Boolean";default:return b(a,s,d,c(a,j))}}function c(a,s){return a===0?Number:a===""?String:a?s:{name:String(a)}}function u(a,...s){let m=s.length<1,d=!m&&s[0],T=!m&&g(s[0]),j=a==null,I=!j&&Object.getPrototypeOf(a)?.constructor,k=e({trial:l(Z=>String(a),"trial")})==="NaN",P=e({trial:l(Z=>String(a),"trial")})==="Infinity";return{noInput:j,noShouldbe:m,compareTo:d,inputCTOR:I,isNaN:k,isInfinity:P,shouldBeFirstElementIsNothing:T}}function b(a,s,m,d){switch(!0){case(!m&&s===a||a?.[Symbol.proxy]&&s===Proxy):return!0;case e({trial:l(T=>String(s),"trial")})==="NaN":return String(a)==="NaN";case(a?.[Symbol.toStringTag]&&r(s,String)):return String(s)===a[Symbol.toStringTag];default:return s?e({trial:l(T=>a instanceof s,"trial")})||s===d||s===Object.getPrototypeOf(d)||`${s?.name}`===d?.name:a?.[Symbol.toStringTag]&&`[object ${a?.[Symbol.toStringTag]}]`||d?.name||String(d)}}function h(a,...s){return s.some(m=>r(a,m))}function g(a,s=!1){let m=a==null;return m=s?m||r(a,1/0)||r(a,NaN):m,m}function v(){let a=l((s,m)=>s?.constructor===Function?s(m):void 0,"tryFn");return function({trial:s,whenError:m=l(()=>{},"whenError")}={}){try{return a(s)}catch(d){return a(m,d)}}}function y(){return function(a){return Object.freeze({get value(){return a},get[Symbol.type](){return o(a)},get type(){return o(a)},[Symbol.is](...s){return r(a,...s)},is(...s){return r(a,...s)}})}}function w(a,{defaultValue:s,isTypes:m=[void 0],notTypes:d}={}){return m=m?.constructor!==Array?[m]:m,d=d&&d?.constructor!==Array?[d]:[],d.length<1?r(a,...m)?a:s:S(a,{isTypes:m,notTypes:d})?a:s}function S(a,{isTypes:s=[void 0],notTypes:m=[void 0]}={}){return s=s?.constructor!==Array?[s]:s,m=m?.constructor!==Array?[m]:m,r(a,...s)&&!r(a,...m)}function f(){Object.getOwnPropertyDescriptors(Object.prototype)[Symbol.is]||(Object.defineProperties(Object.prototype,{[Symbol.type]:{get(){return o(this)},enumerable:!1,configurable:!1},[Symbol.is]:{value:l(function(...a){return r(this,...a)},"value"),enumerable:!1,configurable:!1}}),Object.defineProperties(Object,{[Symbol.type]:{value(a){return o(a)},enumerable:!1,configurable:!1},[Symbol.is]:{value:l(function(a,...s){return r(a,...s)},"value"),enumerable:!1,configurable:!1}}))}function x(a){let s=String(Object.getPrototypeOf(a)?.constructor);return s.slice(s.indexOf("ion")+3,s.indexOf("(")).trim()}function O(a){let s=a.set;return a.set=(m,d,T)=>d===Symbol.proxy?m[d]=T:s(m,d,T),a}function A(){let a=Proxy;return{native(){Proxy=a},custom(){Proxy=new a(a,{construct(s,m){for(let T of m)T.set&&(T=O(T));let d=new s(...m);return d[Symbol.proxy]=`Proxy (${x(m[0])})`,d}})}}}}l(ft,"TOAFactory");var yr=yt(),je=gt(),ae=pt();function gt(){return{html:Object.freeze("accept,action,align,alt,autocapitalize,autocomplete,autopictureinpicture,autoplay,background,bgcolor,border,capture,cellpadding,cellspacing,checked,cite,class,clear,contenteditable,color,cols,colspan,controls,controlslist,coords,crossorigin,datetime,decoding,default,dir,disabled,disablepictureinpicture,disableremoteplayback,download,draggable,enctype,enterkeyhint,face,for,headers,height,hidden,high,href,hreflang,id,inputmode,integrity,is,ismap,kind,label,lang,list,loading,loop,low,max,maxlength,media,method,min,minlength,multiple,muted,name,nonce,noshade,novalidate,nowrap,open,optimum,pattern,placeholder,playsinline,poster,preload,pubdate,radiogroup,readonly,rel,required,rev,reversed,role,rows,rowspan,spellcheck,scope,selected,shape,size,sizes,span,srclang,start,src,srcset,step,style,summary,tabindex,target,title,translate,type,usemap,valign,value,width,xmlns,slot".split(",")),svg:Object.freeze("accent-height,accumulate,additive,alignment-baseline,ascent,attributename,attributetype,azimuth,basefrequency,baseline-shift,begin,bias,by,class,clip,clippathunits,clip-path,clip-rule,color,color-interpolation,color-interpolation-filters,color-profile,color-rendering,cx,cy,d,dx,dy,diffuseconstant,direction,display,divisor,dur,edgemode,elevation,end,fill,fill-opacity,fill-rule,filter,filterunits,flood-color,flood-opacity,font-family,font-size,font-size-adjust,font-stretch,font-style,font-variant,font-weight,fx,fy,g1,g2,glyph-name,glyphref,gradientunits,gradienttransform,height,href,id,image-rendering,in,in2,k,k1,k2,k3,k4,kerning,keypoints,keysplines,keytimes,lang,lengthadjust,letter-spacing,kernelmatrix,kernelunitlength,lighting-color,local,marker-end,marker-mid,marker-start,markerheight,markerunits,markerwidth,maskcontentunits,maskunits,max,mask,media,method,mode,min,name,numoctaves,offset,operator,opacity,order,orient,orientation,origin,overflow,paint-order,path,pathlength,patterncontentunits,patterntransform,patternunits,points,preservealpha,preserveaspectratio,primitiveunits,r,rx,ry,radius,refx,refy,repeatcount,repeatdur,restart,result,rotate,scale,seed,shape-rendering,specularconstant,specularexponent,spreadmethod,startoffset,stddeviation,stitchtiles,stop-color,stop-opacity,stroke-dasharray,stroke-dashoffset,stroke-linecap,stroke-linejoin,stroke-miterlimit,stroke-opacity,stroke,stroke-width,style,surfacescale,systemlanguage,tabindex,targetx,targety,transform,text-anchor,text-decoration,text-rendering,textlength,type,u1,u2,unicode,values,viewbox,visibility,version,vert-adv-y,vert-origin-x,vert-origin-y,width,word-spacing,wrap,writing-mode,xchannelselector,ychannelselector,x,x1,x2,xmlns,y,y1,y2,z,zoomandpan".split(","))}}l(gt,"getAttrs");function pt(){return{a:!0,area:!0,audio:!1,br:!0,base:!0,body:!0,button:!0,canvas:!0,comment:!0,dl:!0,data:!0,datalist:!0,div:!0,em:!0,embed:!1,fieldset:!0,font:!0,footer:!0,form:!1,hr:!0,head:!0,header:!0,output:!0,iframe:!1,frameset:!1,img:!0,input:!0,li:!0,label:!0,legend:!0,link:!0,map:!0,mark:!0,menu:!0,media:!0,meta:!0,nav:!0,meter:!0,ol:!0,object:!1,optgroup:!0,option:!0,p:!0,param:!0,picture:!0,pre:!0,progress:!1,quote:!0,script:!1,select:!0,source:!0,span:!0,style:!0,caption:!0,td:!0,col:!0,table:!0,tr:!0,template:!1,textarea:!0,time:!0,title:!0,track:!0,details:!0,ul:!0,video:!0,del:!0,ins:!0,slot:!0,blockquote:!0,svg:!0,dialog:!0,summary:!0,main:!0,address:!0,colgroup:!0,tbody:!0,tfoot:!0,thead:!0,th:!0,dd:!0,dt:!0,figcaption:!0,figure:!0,i:!0,b:!0,code:!0,h1:!0,h2:!0,h3:!0,h4:!0,abbr:!0,bdo:!0,dfn:!0,kbd:!0,q:!0,rb:!0,rp:!0,rt:!0,ruby:!0,s:!0,strike:!0,samp:!0,small:!0,strong:!0,sup:!0,sub:!0,u:!0,var:!0,wbr:!0,nobr:!0,tt:!0,noscript:!0}}l(pt,"getPermissions");function yt(){return["::backdrop{background-color:grey;opacity:0.2;}",`#jqxPopup{overflow:hidden;background-color:transparent;outline:none;border:none;inset:0;animation:fade-out 0.5s ease-out;&[open]{display:flex;align-items:center;justify-content:center;animation:fade-in 0.5s ease;}#jqxPopupContent{background-color:white;border:solid 1px #eee;box-shadow:1px 2px 8px #999;border-radius:4px;padding:12px;vertical-align:middle;max-height:40vh;max-width:50vw;overflow:auto;margin:0 auto;div:not(#closeHandleIcon){clear:both;}@media (width <= 640px){max-width:80vw;max-height:60vh;}#closeHandleIcon{cursor:pointer;width:24px;height:24px;display:inline;position:absolute;top:4px;right:4px;justify-content:right;background-image:url("data:image/svg+xml;utf8,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22iso-8859-1%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20xmlns%3Axlink%3D%22http%3A%2F%2Fwww.w3.org%2F1999%2Fxlink%22%20version%3D%221.1%22%20id%3D%22Layer_1%22%20x%3D%220px%22%20y%3D%220px%22%20viewBox%3D%220%200%20128%20128%22%20style%3D%22enable-background%3Anew%200%200%20128%20128%3B%22%20xml%3Aspace%3D%22preserve%22%3E%3Crect%20x%3D%22-368%22%20y%3D%226%22%20style%3D%22display%3Anone%3Bfill%3A%23E0E0E0%3B%22%20width%3D%22866%22%20height%3D%221018%22%2F%3E%3Ccircle%20style%3D%22fill%3A%23FFFFFF%3B%22%20cx%3D%2264%22%20cy%3D%2264%22%20r%3D%2248%22%2F%3E%3Ccircle%20style%3D%22fill%3A%238CCFB9%3B%22%20cx%3D%2264%22%20cy%3D%2264%22%20r%3D%2239%22%2F%3E%3Ccircle%20style%3D%22fill%3Anone%3Bstroke%3A%23444B54%3Bstroke-width%3A6%3Bstroke-miterlimit%3A10%3B%22%20cx%3D%2264%22%20cy%3D%2264%22%20r%3D%2248%22%2F%3E%3Cpolyline%20style%3D%22fill%3Anone%3Bstroke%3A%23FFFFFF%3Bstroke-width%3A6%3Bstroke-linecap%3Around%3Bstroke-miterlimit%3A10%3B%22%20points%3D%2242%2C69%2055.55%2C81%20%20%2086%2C46%20%22%2F%3E%3C%2Fsvg%3E");@media (width <= 640px){background-image:none;position:relative;margin:-15px -15px 4px 0;float:right;vertical-align:middle;border:1px solid #AAA;padding:2px;border-radius:50%;width:12px;height:12px;font-size:12px;line-height:12px;font-weight:bold;text-align:center;&:after{content:'\\2714';color:green;}}}.warn{display:none;text-align:center;color:red;border-top:1px solid #999;margin-top:1em;padding-top:3px;animation:warn-fade-out 0.2s ease-out;}.warn.active{opacity:1;display:block;animation:warn-fade-in 0.2s ease-in;}}}`,"@keyframes fade-in{0%{opacity:0;transform:scale(0, 0);display:none;}100%{opacity:1;transform:scale(1, 1);display:flex;}}","@keyframes fade-out{0%{opacity:1;transform:scale(1, 1);display:flex;}100%{opacity:0;transform:scale(0, 0);display:none;}}","@keyframes warn-fade-in{0%{opacity:0;transform:scale(0, 0);display:none;}100%{opacity:1;transform:scale(1,1 );display:block;}}","@keyframes warn-fade-out{0%{opacity:1;transform:scale(1, 1);display:block;}100%{opacity:0;transform:scale(0, 0);display:none;}}"]}l(yt,"getPopupStyling");var dt={html:"innerHTML",text:"textContent",class:"className"},hr=ht();function ht(){let e={get(t,n){let r=String(n)?.toLowerCase();switch(!0){case r in t:return t[r];case Dt(r):return Ee(t,r,n);default:return Ee(t,r,n,!0)}},enumerable:!1,configurable:!1};return new Proxy({},e)}l(ht,"tinyDOM");function Ee(e,t,n,r=!1){return Object.defineProperty(e,t,{get(){return r?o=>$t(n):Ct(t)}}),e[t]}l(Ee,"createTagFunctionProperty");function bt(e,t,n){return t=t?.isJQx&&t.first()||t,pr({trial:l(r=>Ot(t)?e.append(t):qe(t)?e.insertAdjacentHTML("beforeend",t):e.append(t),"trial"),whenError:l(r=>console.info(`${n} (for root ${e}) not created, reason
|
|
2
|
-
`,r)
|
|
3
|
-
=> @charset, @namespace and @import are not supported here`),{done:!0}}
|
|
4
|
-
${
|
|
5
|
-
Rule: ${
|
|
6
|
-
${n}`),
|
|
7
|
-
${
|
|
8
|
-
Rule: ${
|
|
9
|
-
${n}`),
|
|
10
|
-
`)}
|
|
11
|
-
`).map(r=>r.replace(/\s|\/\/.*$/g,"").trim().replace(/(@s!)/g," ")).join(""),n)}
|
|
1
|
+
var{IS:d,maybe:_t,$Wrap:$o,xProxy:wo,isNothing:To}=Gt();function Gt(){Symbol.proxy=Symbol.for("toa.proxy"),Symbol.is=Symbol.for("toa.is"),Symbol.type=Symbol.for("toa.type"),Symbol.isSymbol=Symbol.for("toa.isASymbol"),m();let e=S(),[t,n]=[h(),A()];return n.custom(),{IS:r,maybe:e,$Wrap:t,isNothing:g,xProxy:n};function r(a,...l){if(e({trial:f=>"isTypes"in(l?.[0]??{})})){let f=l[0];return"defaultValue"in f?v(a,f):"notTypes"in f?b(a,f):r(a,...[f.isTypes].flat())}let c=typeof a=="symbol"?Symbol.isSymbol:a;return l.length>1?y(c,...l):i(a,...l)}function o(a){return a?.[Symbol.proxy]??r(a)}function i(a,...l){let{noInput:c,noShouldbe:f,compareTo:w,inputCTOR:N,isNaN:M,isInfinity:I,shouldBeFirstElementIsNothing:Z}=u(a,...l);switch(l=l.length&&l[0],!0){case Z:return String(a)===String(w);case(a?.[Symbol.proxy]&&f):return a[Symbol.proxy];case M:return f?"NaN":e({trial:P=>String(w)})===String(a);case I:return f?"Infinity":e({trial:P=>String(w)})===String(a);case c:return f?String(a):String(w)===String(a);case N===Boolean:return l?N===l:"Boolean";default:return p(a,l,f,s(a,N))}}function s(a,l){return a===0?Number:a===""?String:a?l:{name:String(a)}}function u(a,...l){let c=l.length<1,f=!c&&l[0],w=!c&&g(l[0]),N=a==null,M=!N&&Object.getPrototypeOf(a)?.constructor,I=e({trial:P=>String(a)})==="NaN",Z=e({trial:P=>String(a)})==="Infinity";return{noInput:N,noShouldbe:c,compareTo:f,inputCTOR:M,isNaN:I,isInfinity:Z,shouldBeFirstElementIsNothing:w}}function p(a,l,c,f){switch(!0){case(!c&&l===a||a?.[Symbol.proxy]&&l===Proxy):return!0;case e({trial:w=>String(l)})==="NaN":return String(a)==="NaN";case(a?.[Symbol.toStringTag]&&r(l,String)):return String(l)===a[Symbol.toStringTag];default:return l?e({trial:w=>a instanceof l})||l===f||l===Object.getPrototypeOf(f)||`${l?.name}`===f?.name:a?.[Symbol.toStringTag]&&`[object ${a?.[Symbol.toStringTag]}]`||f?.name||String(f)}}function y(a,...l){return l.some(c=>r(a,c))}function g(a,l=!1){let c=a==null;return c=l?c||r(a,1/0)||r(a,NaN):c,c}function S(){let a=(l,c)=>l?.constructor===Function?l(c):void 0;return function({trial:l,whenError:c=()=>{}}={}){try{return a(l)}catch(f){return a(c,f)}}}function h(){return function(a){return Object.freeze({get value(){return a},get[Symbol.type](){return o(a)},get type(){return o(a)},[Symbol.is](...l){return r(a,...l)},is(...l){return r(a,...l)}})}}function v(a,{defaultValue:l,isTypes:c=[void 0],notTypes:f}={}){return c=c?.constructor!==Array?[c]:c,f=f&&f?.constructor!==Array?[f]:[],f.length<1?r(a,...c)?a:l:b(a,{isTypes:c,notTypes:f})?a:l}function b(a,{isTypes:l=[void 0],notTypes:c=[void 0]}={}){return l=l?.constructor!==Array?[l]:l,c=c?.constructor!==Array?[c]:c,r(a,...l)&&!r(a,...c)}function m(){Object.getOwnPropertyDescriptors(Object.prototype)[Symbol.is]||(Object.defineProperties(Object.prototype,{[Symbol.type]:{get(){return o(this)},enumerable:!1,configurable:!1},[Symbol.is]:{value:function(...a){return r(this,...a)},enumerable:!1,configurable:!1}}),Object.defineProperties(Object,{[Symbol.type]:{value(a){return o(a)},enumerable:!1,configurable:!1},[Symbol.is]:{value:function(a,...l){return r(a,...l)},enumerable:!1,configurable:!1}}))}function x(a){let l=String(Object.getPrototypeOf(a)?.constructor);return l.slice(l.indexOf("ion")+3,l.indexOf("(")).trim()}function T(a){let l=a.set;return a.set=(c,f,w)=>f===Symbol.proxy?c[f]=w:l(c,f,w),a}function A(){let a=Proxy;return{native(){Proxy=a},custom(){Proxy=new a(a,{construct(l,c){for(let w of c)w.set&&(w=T(w));let f=new l(...c);return f[Symbol.proxy]=`Proxy (${x(c[0])})`,f}})}}}}var Kt=tn(),be=Xt(),ee=en();function Xt(){return{html:Object.freeze("accept,action,align,alt,autocapitalize,autocomplete,autopictureinpicture,autoplay,background,bgcolor,border,capture,cellpadding,cellspacing,checked,cite,class,clear,contenteditable,color,cols,colspan,controls,controlslist,coords,crossorigin,datetime,decoding,default,dir,disabled,disablepictureinpicture,disableremoteplayback,download,draggable,enctype,enterkeyhint,face,for,headers,height,hidden,high,href,hreflang,id,inputmode,integrity,is,ismap,kind,label,lang,list,loading,loop,low,max,maxlength,media,method,min,minlength,multiple,muted,name,nonce,noshade,novalidate,nowrap,open,optimum,pattern,placeholder,playsinline,poster,preload,pubdate,radiogroup,readonly,rel,required,rev,reversed,role,rows,rowspan,spellcheck,scope,selected,shape,size,sizes,span,srclang,start,src,srcset,step,style,summary,tabindex,target,title,translate,type,usemap,valign,value,width,xmlns,slot".split(",")),svg:Object.freeze("accent-height,accumulate,additive,alignment-baseline,ascent,attributename,attributetype,azimuth,basefrequency,baseline-shift,begin,bias,by,class,clip,clippathunits,clip-path,clip-rule,color,color-interpolation,color-interpolation-filters,color-profile,color-rendering,cx,cy,d,dx,dy,diffuseconstant,direction,display,divisor,dur,edgemode,elevation,end,fill,fill-opacity,fill-rule,filter,filterunits,flood-color,flood-opacity,font-family,font-size,font-size-adjust,font-stretch,font-style,font-variant,font-weight,fx,fy,g1,g2,glyph-name,glyphref,gradientunits,gradienttransform,height,href,id,image-rendering,in,in2,k,k1,k2,k3,k4,kerning,keypoints,keysplines,keytimes,lang,lengthadjust,letter-spacing,kernelmatrix,kernelunitlength,lighting-color,local,marker-end,marker-mid,marker-start,markerheight,markerunits,markerwidth,maskcontentunits,maskunits,max,mask,media,method,mode,min,name,numoctaves,offset,operator,opacity,order,orient,orientation,origin,overflow,paint-order,path,pathlength,patterncontentunits,patterntransform,patternunits,points,preservealpha,preserveaspectratio,primitiveunits,r,rx,ry,radius,refx,refy,repeatcount,repeatdur,restart,result,rotate,scale,seed,shape-rendering,specularconstant,specularexponent,spreadmethod,startoffset,stddeviation,stitchtiles,stop-color,stop-opacity,stroke-dasharray,stroke-dashoffset,stroke-linecap,stroke-linejoin,stroke-miterlimit,stroke-opacity,stroke,stroke-width,style,surfacescale,systemlanguage,tabindex,targetx,targety,transform,text-anchor,text-decoration,text-rendering,textlength,type,u1,u2,unicode,values,viewbox,visibility,version,vert-adv-y,vert-origin-x,vert-origin-y,width,word-spacing,wrap,writing-mode,xchannelselector,ychannelselector,x,x1,x2,xmlns,y,y1,y2,z,zoomandpan".split(","))}}function en(){return{a:!0,area:!0,audio:!1,br:!0,base:!0,body:!0,button:!0,canvas:!0,comment:!0,dl:!0,data:!0,datalist:!0,div:!0,em:!0,embed:!1,fieldset:!0,font:!0,footer:!0,form:!1,hr:!0,head:!0,header:!0,output:!0,iframe:!1,frameset:!1,img:!0,input:!0,li:!0,label:!0,legend:!0,link:!0,map:!0,mark:!0,menu:!0,media:!0,meta:!0,nav:!0,meter:!0,ol:!0,object:!1,optgroup:!0,option:!0,p:!0,param:!0,picture:!0,pre:!0,progress:!1,quote:!0,script:!1,select:!0,source:!0,span:!0,style:!0,caption:!0,td:!0,col:!0,table:!0,tr:!0,template:!1,textarea:!0,time:!0,title:!0,track:!0,details:!0,ul:!0,video:!0,del:!0,ins:!0,slot:!0,blockquote:!0,svg:!0,dialog:!0,summary:!0,main:!0,address:!0,colgroup:!0,tbody:!0,tfoot:!0,thead:!0,th:!0,dd:!0,dt:!0,figcaption:!0,figure:!0,i:!0,b:!0,code:!0,h1:!0,h2:!0,h3:!0,h4:!0,abbr:!0,bdo:!0,dfn:!0,kbd:!0,q:!0,rb:!0,rp:!0,rt:!0,ruby:!0,s:!0,strike:!0,samp:!0,small:!0,strong:!0,sup:!0,sub:!0,u:!0,var:!0,wbr:!0,nobr:!0,tt:!0,noscript:!0}}function tn(){return["::backdrop{background-color:grey;opacity:0.2;}",`#jqxPopup{overflow:hidden;background-color:transparent;outline:none;border:none;inset:0;animation:fade-out 0.5s ease-out;&[open]{display:flex;align-items:center;justify-content:center;animation:fade-in 0.5s ease;}#jqxPopupContent{background-color:white;border:solid 1px #eee;box-shadow:1px 2px 8px #999;border-radius:4px;padding:12px;vertical-align:middle;max-height:40vh;max-width:50vw;overflow:auto;margin:0 auto;div:not(#closeHandleIcon){clear:both;}@media (width <= 640px){max-width:80vw;max-height:60vh;}#closeHandleIcon{cursor:pointer;width:24px;height:24px;display:inline;position:absolute;top:4px;right:4px;justify-content:right;background-image:url("data:image/svg+xml;utf8,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22iso-8859-1%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20xmlns%3Axlink%3D%22http%3A%2F%2Fwww.w3.org%2F1999%2Fxlink%22%20version%3D%221.1%22%20id%3D%22Layer_1%22%20x%3D%220px%22%20y%3D%220px%22%20viewBox%3D%220%200%20128%20128%22%20style%3D%22enable-background%3Anew%200%200%20128%20128%3B%22%20xml%3Aspace%3D%22preserve%22%3E%3Crect%20x%3D%22-368%22%20y%3D%226%22%20style%3D%22display%3Anone%3Bfill%3A%23E0E0E0%3B%22%20width%3D%22866%22%20height%3D%221018%22%2F%3E%3Ccircle%20style%3D%22fill%3A%23FFFFFF%3B%22%20cx%3D%2264%22%20cy%3D%2264%22%20r%3D%2248%22%2F%3E%3Ccircle%20style%3D%22fill%3A%238CCFB9%3B%22%20cx%3D%2264%22%20cy%3D%2264%22%20r%3D%2239%22%2F%3E%3Ccircle%20style%3D%22fill%3Anone%3Bstroke%3A%23444B54%3Bstroke-width%3A6%3Bstroke-miterlimit%3A10%3B%22%20cx%3D%2264%22%20cy%3D%2264%22%20r%3D%2248%22%2F%3E%3Cpolyline%20style%3D%22fill%3Anone%3Bstroke%3A%23FFFFFF%3Bstroke-width%3A6%3Bstroke-linecap%3Around%3Bstroke-miterlimit%3A10%3B%22%20points%3D%2242%2C69%2055.55%2C81%20%20%2086%2C46%20%22%2F%3E%3C%2Fsvg%3E");@media (width <= 640px){background-image:none;position:relative;margin:-15px -15px 4px 0;float:right;vertical-align:middle;border:1px solid #AAA;padding:2px;border-radius:50%;width:12px;height:12px;font-size:12px;line-height:12px;font-weight:bold;text-align:center;&:after{content:'\\2714';color:green;}}}.warn{display:none;text-align:center;color:red;border-top:1px solid #999;margin-top:1em;padding-top:3px;animation:warn-fade-out 0.2s ease-out;}.warn.active{opacity:1;display:block;animation:warn-fade-in 0.2s ease-in;}}}`,"@keyframes fade-in{0%{opacity:0;transform:scale(0, 0);display:none;}100%{opacity:1;transform:scale(1, 1);display:flex;}}","@keyframes fade-out{0%{opacity:1;transform:scale(1, 1);display:flex;}100%{opacity:0;transform:scale(0, 0);display:none;}}","@keyframes warn-fade-in{0%{opacity:0;transform:scale(0, 0);display:none;}100%{opacity:1;transform:scale(1,1 );display:block;}}","@keyframes warn-fade-out{0%{opacity:1;transform:scale(1, 1);display:block;}100%{opacity:0;transform:scale(0, 0);display:none;}}"]}var Ue={html:"innerHTML",text:"textContent",class:"className"},nn=rn();function rn(){let e={get(t,n){let r=String(n)?.toLowerCase();switch(!0){case r in t:return t[r];case dn(r):return We(t,r,n);default:return We(t,r,n,!0)}},enumerable:!1,configurable:!1};return new Proxy({},e)}function We(e,t,n,r=!1){return Object.defineProperty(e,t,{get(){return r?o=>fn(n):gn(t)}}),e[t]}function on(e,t,n){return t=t?.isJQx&&t.first()||t,_t({trial:r=>mn(t)?e.append(t):rt(t)?e.insertAdjacentHTML("beforeend",t):e.append(t),whenError:r=>console.info(`${n} (for root ${e}) not created, reason
|
|
2
|
+
`,r)})}function an(e,t,...n){let r=ln(t,e);return n?.forEach(o=>on(r,o,e)),r}function ln(e,t){switch(e=je(t)?cn(e):e?.isJQx?e.first():e,!0){case d(e,String):return G(t,rt(e,t)?{html:e}:{text:e});case d(e,Node):return un(t,e);default:return G(t,e)}}function sn(e){return delete e.data,Object.keys(e).length<1||Object.keys(e).forEach(t=>{let n=t.toLowerCase();n in Ue&&(e[Ue[n]]=e[t],delete e[t])}),e}function un(e,t){let n=G(e);return n.append(t),n}function G(e,t={}){t=nt(t,{});let n=Object.entries(t.data??{}),r=Object.assign(je(e)?new Comment(t?.text):document.createElement(e),sn(t));return n.length&&n.forEach(([o,i])=>r.dataset[o]=String(i)),r}function nt(e,t){return t?d(e,{isTypes:Object,notTypes:[Array,null,NaN,Proxy],defaultValue:t}):d(e,{isTypes:Object,notTypes:[Array,null,NaN,Proxy]})}function cn(e){return nt(e)?e?.text??e?.textContent??"":String(e)}function fn(e){return G("b",{style:"color:red",text:`'${e}' is not a valid HTML-tag`})}function rt(e,t){return!je(t)&&d(e,String)&&/<.*>|&[#|0-9a-z]+[^;];/i.test(e)}function mn(e){return e?.constructor===Comment||e?.constructor===CharacterData}function je(e){return e?.constructor===Comment||/comment/i.test(e)}function dn(e){return!d(G(e),HTMLUnknownElement)}function gn(e){return(t,...n)=>an(e,t,...n)}var{IS:oe,maybe:Oo,$Wrap:Do,xProxy:jo,isNothing:No}=pn();function pn(){Symbol.proxy=Symbol.for("toa.proxy"),Symbol.is=Symbol.for("toa.is"),Symbol.type=Symbol.for("toa.type"),Symbol.isSymbol=Symbol.for("toa.isASymbol"),m();let e=S(),[t,n]=[h(),A()];return n.custom(),{IS:r,maybe:e,$Wrap:t,isNothing:g,xProxy:n};function r(a,...l){if(e({trial:f=>"isTypes"in(l?.[0]??{})})){let f=l[0];return"defaultValue"in f?v(a,f):"notTypes"in f?b(a,f):r(a,...[f.isTypes].flat())}let c=typeof a=="symbol"?Symbol.isSymbol:a;return l.length>1?y(c,...l):i(a,...l)}function o(a){return a?.[Symbol.proxy]??r(a)}function i(a,...l){let{noInput:c,noShouldbe:f,compareTo:w,inputCTOR:N,isNaN:M,isInfinity:I,shouldBeFirstElementIsNothing:Z}=u(a,...l);switch(l=l.length&&l[0],!0){case Z:return String(a)===String(w);case(a?.[Symbol.proxy]&&f):return a[Symbol.proxy];case M:return f?"NaN":e({trial:P=>String(w)})===String(a);case I:return f?"Infinity":e({trial:P=>String(w)})===String(a);case c:return f?String(a):String(w)===String(a);case N===Boolean:return l?N===l:"Boolean";default:return p(a,l,f,s(a,N))}}function s(a,l){return a===0?Number:a===""?String:a?l:{name:String(a)}}function u(a,...l){let c=l.length<1,f=!c&&l[0],w=!c&&g(l[0]),N=a==null,M=!N&&Object.getPrototypeOf(a)?.constructor,I=e({trial:P=>String(a)})==="NaN",Z=e({trial:P=>String(a)})==="Infinity";return{noInput:N,noShouldbe:c,compareTo:f,inputCTOR:M,isNaN:I,isInfinity:Z,shouldBeFirstElementIsNothing:w}}function p(a,l,c,f){switch(!0){case(!c&&l===a||a?.[Symbol.proxy]&&l===Proxy):return!0;case e({trial:w=>String(l)})==="NaN":return String(a)==="NaN";case(a?.[Symbol.toStringTag]&&r(l,String)):return String(l)===a[Symbol.toStringTag];default:return l?e({trial:w=>a instanceof l})||l===f||l===Object.getPrototypeOf(f)||`${l?.name}`===f?.name:a?.[Symbol.toStringTag]&&`[object ${a?.[Symbol.toStringTag]}]`||f?.name||String(f)}}function y(a,...l){return l.some(c=>r(a,c))}function g(a,l=!1){let c=a==null;return c=l?c||r(a,1/0)||r(a,NaN):c,c}function S(){let a=(l,c)=>l?.constructor===Function?l(c):void 0;return function({trial:l,whenError:c=()=>{}}={}){try{return a(l)}catch(f){return a(c,f)}}}function h(){return function(a){return Object.freeze({get value(){return a},get[Symbol.type](){return o(a)},get type(){return o(a)},[Symbol.is](...l){return r(a,...l)},is(...l){return r(a,...l)}})}}function v(a,{defaultValue:l,isTypes:c=[void 0],notTypes:f}={}){return c=c?.constructor!==Array?[c]:c,f=f&&f?.constructor!==Array?[f]:[],f.length<1?r(a,...c)?a:l:b(a,{isTypes:c,notTypes:f})?a:l}function b(a,{isTypes:l=[void 0],notTypes:c=[void 0]}={}){return l=l?.constructor!==Array?[l]:l,c=c?.constructor!==Array?[c]:c,r(a,...l)&&!r(a,...c)}function m(){Object.getOwnPropertyDescriptors(Object.prototype)[Symbol.is]||(Object.defineProperties(Object.prototype,{[Symbol.type]:{get(){return o(this)},enumerable:!1,configurable:!1},[Symbol.is]:{value:function(...a){return r(this,...a)},enumerable:!1,configurable:!1}}),Object.defineProperties(Object,{[Symbol.type]:{value(a){return o(a)},enumerable:!1,configurable:!1},[Symbol.is]:{value:function(a,...l){return r(a,...l)},enumerable:!1,configurable:!1}}))}function x(a){let l=String(Object.getPrototypeOf(a)?.constructor);return l.slice(l.indexOf("ion")+3,l.indexOf("(")).trim()}function T(a){let l=a.set;return a.set=(c,f,w)=>f===Symbol.proxy?c[f]=w:l(c,f,w),a}function A(){let a=Proxy;return{native(){Proxy=a},custom(){Proxy=new a(a,{construct(l,c){for(let w of c)w.set&&(w=T(w));let f=new l(...c);return f[Symbol.proxy]=`Proxy (${x(c[0])})`,f}})}}}}var ot=yn;function yn({styleSheet:e,createWithId:t}={}){let{tryParseAtOrNestedRules:n,ruleExists:r,checkParams:o,sheet:i,removeRules:s,consider:u,currentSheetID:p}=hn({styleSheet:e,createWithId:t});function y(b,m){if(b&&m.removeProperties){Object.keys(m.removeProperties).forEach(x=>b.style.removeProperty(qe(x)));return}Object.entries(m).forEach(([x,T])=>{x=qe(x.trim()),T=T.trim();let A;if(/!important/.test(T)&&(T=T.slice(0,T.indexOf("!important")).trim(),A="important"),!CSS.supports(x,T))return console.error(`StylingFactory ${p} error: '${x}' with value '${T}' not supported (yet)`);Be(()=>b.style.setProperty(x,T,A),`StylingFactory ${p} (setRule4Selector) failed`)})}function g(b,m,x=i){if(b=b?.trim?.(),!oe(b,String)||!b.length||/[;,]$/g.test(b))return console.error(`StylingFactory ${p} (setRules): [${b||"[no selector given]"}] is not a valid selector`);if(m.removeRule)return s(b);let T=r(b,!0),A=T||x.cssRules[x.insertRule(`${b} {}`,x.cssRules.length||0)];return u(()=>y(A,m),b,T)}function S(b){let m=b.trim().split(/{/,2),x=m.shift().trim();if(!oe(x,String)||!x?.trim()?.length)return console.error(`StylingFactory ${p} (doParse): no (valid) selector could be extracted from rule ${Se(b)}`);let T=Tn(m.shift());return Be(()=>g(x,T),`StylingFactory ${p} (setRules) failed`)}function h(b){let m=n(b);return m.done?m.existing:S(b)}function v(b,m){return b.trim().startsWith("@media")?h(bn(b,m)):g(b,m)}return function(b,m={}){return o(b,m)&&(Object.keys(m).length?v(b,m):h(b))}}function hn({styleSheet:e,createWithId:t}){let n="Note: The rule or some of its properties may not be supported by your browser (yet)",r=`for style#${t}`;e=t?o(t):e;function o(h){let v=document.querySelector(`#${h}`)?.sheet;if(v)return v;let b=Object.assign(document.createElement("style"),{id:h});return document.head.insertAdjacentElement("beforeend",b),b.sheet}function i(h){return console.error(`StylingFactory ${r} [rule: ${h}]
|
|
3
|
+
=> @charset, @namespace and @import are not supported here`),{done:!0}}function s(h,v){return[...e.rules].find(b=>v?Ve(b.selectorText||"",h):vn`${xn(h)}${[..."gim"]}`.test(b.cssText))}function u(h){return/^@charset|@import|namespace/i.test(h.trim())?i(h):h.match(/}/g)?.length>1?{existing:g(h,1),done:!0}:{done:!1}}function p(h){let v=[...e.cssRules].reduce((m,x,T)=>Ve(x.selectorText||"",h)&&m.concat(T)||m,[]),b=v.length;return v.forEach(m=>e.deleteRule(m)),b>0?console.info(`\u2714 Removed ${b} instance${b>1?"s":""} of selector ${h} from ${r.slice(4)}`):console.info(`\u2714 Remove rule: selector ${h} does not exist in ${r.slice(4)}`)}function y(h,v){return h&&oe(h,String)&&h.trim().length>0&&oe(v,Object)||(console.error(`StylingFactory ${r} called with invalid parameters`),!1)}function g(h){h=h.trim();let v=h.slice(0,h.indexOf("{")).trim(),b=!!s(v);try{return e.insertRule(`${h}`,e.cssRules.length),b}catch(m){return console.error(`StylingFactory ${r} (tryParse) ${m.name} Error:
|
|
4
|
+
${m.message}
|
|
5
|
+
Rule: ${Se(h)}
|
|
6
|
+
${n}`),b}}function S(h,v,b){try{return h(),b}catch(m){return console.error(`StylingFactory ${r} (tryAddOrModify) ${m.name} Error:
|
|
7
|
+
${m.message}
|
|
8
|
+
Rule: ${Se(v)}
|
|
9
|
+
${n}`),b}}return{sheet:e,removeRules:p,tryParseAtOrNestedRules:u,ruleExists:s,checkParams:y,tryParse:g,consider:S,currentSheetID:r}}function bn(e,t){return`${e.trim()} ${Object.entries(t).map(([n,r])=>`${n}: { ${Sn(r)}`)}`}function Se(e){let t=(e||"NO RULE").trim().slice(0,50).replace(/\n/g,"\\n").replace(/\s{2,}/g," ");return e.length>t.length?`${t.trim()}...truncated`:t}function Sn(e){return Object.entries(e).map(([t,n])=>`${t}: ${n.trim()}`).join(`;
|
|
10
|
+
`)}function xn(e){return e.replace(/([*\[\]()-+{}.$?\\])/g,t=>`\\${t}`)}function vn(e,...t){let n=t.length&&Array.isArray(t.slice(-1))?t.pop().join(""):"";return new RegExp((t.length&&e.raw.reduce((r,o,i)=>r.concat(t[i-1]||"").concat(o),"")||e.raw.join("")).split(`
|
|
11
|
+
`).map(r=>r.replace(/\s|\/\/.*$/g,"").trim().replace(/(@s!)/g," ")).join(""),n)}function qe(e){return e.replace(/[A-Z]/g,t=>`-${t.toLowerCase()}`).replace(/[^--]^-|-$/,"")}function Be(e,t){try{return e()}catch(n){console.error(`${t||"an error occured"}: ${n.message}`)}}function $n(e){return e.replace(/\/\*.+?\*\//gm,"").replace(/[}{\r\n]/g,"").replace(/(data:.+?);/g,(t,n)=>`${n}\\3b`).split(";").map(t=>t.trim()).join(`;
|
|
12
12
|
`).replaceAll("\\3b",";").split(`
|
|
13
|
-
`)}
|
|
14
|
-
`)),
|
|
15
|
-
`)),
|
|
16
|
-
`));default:return n}}return l(i,"log"),Object.defineProperties(n,{log:{value:i,enumerable:!1},error:{value:r,enumerable:!1},warn:{value:o,enumerable:!1}}),Object.freeze(n)}l(Yt,"systemLogFactory");function ce(){return(e=>`[${X(e.getHours())}:${X(e.getMinutes())}:${X(e.getSeconds())}.${X(e.getMilliseconds(),3)}]`)(new Date)}l(ce,"logTime");function _t(e,t){if(e)for(let[n,r]of Object.entries(t)){if(n=R(n),n.startsWith("data"))return _e(e,r);p(r,String)&&Be(n)&&e.setAttribute(n,r.split(/[, ]/)?.join(" "))}}l(_t,"assignAttrValues");function _e(e,t){if(e&&p(t,Object))for(let[n,r]of Object.entries(t))e.setAttribute(`data-${R(n)}`,r)}l(_e,"setData");function Ge(e){return e?p(e,Proxy)?[e.EL]:p(e,NodeList)?[...e]:W(e)?[e]:we(e)?e:e.isJQx?e.collection:void 0:[]}l(Ge,"input2Collection");function Ze(e,t){return e.andThen(t)}l(Ze,"after");function ze(e,t){return e.andThen(t,!0)}l(ze,"before");function W(e){return p(e,Text,HTMLElement,Comment)}l(W,"isNode");function ue(e,t){if(p(t,Object))for(let[n,r]of Object.entries(t)){let o;/!important/i.test(r)&&(r=r.slice(0,r.indexOf("!")).trim(),o="important"),e.style.setProperty(R(n),r,o)}}l(ue,"applyStyle");function U(e){let t=e.cloneNode(!0);return t.removeAttribute&&t.removeAttribute("id"),e.isConnected?e.remove():e=null,t}l(U,"cloneAndDestroy");function Gt(e){if(!e)return;let t=e.style,n=getComputedStyle(e),r=[t.visibility,n.visibility].includes("hidden"),o=[t.display,n.display].includes("none"),i=e.hidden,c=e.offsetTop<0||e.offsetLeft+e.offsetWidth<0||e.offsetLeft>document.body.offsetWidth,u=+n.opacity==0||+(t.opacity||1)==0;return!(i||c||u||o||r)}l(Gt,"isVisible");function Kt(e){return e?.isConnected?!![...document.querySelectorAll(":is(:read-write)")].find(t=>t===e):!1}l(Kt,"isWritable");function Xt(e){return e?.filter(t=>t).reduce((t,n)=>t.concat(Xe(n)?`<!--${n.data}-->`:xe(n)?n.textContent:n.outerHTML),"")}l(Xt,"ElemArray2HtmlString");function X(e,t=2){return`${e}`.padStart(t,"0")}l(X,"pad0");function en(e,t=0){return[e,t]=[Math.floor(e),Math.ceil(t)],Math.floor([...crypto.getRandomValues(new Uint32Array(1))].shift()/2**32*(e-t+1)+t)}l(en,"randomNr");function Ke(){return`_${on(vr).slice(0,8).join("")}`}l(Ke,"randomString");function tn(e){return e=p(e,String)&&/,/.test(e)?e.split(",").map(t=>t.trim().toLowerCase()).filter(t=>t.length>0):e,p(e,Array)?e:p(e,String)&&e?.trim().toLowerCase()||""}l(tn,"resolveEventTypeParameter");function nn(e){return e?.isConnected?!![...document.querySelectorAll(":is(:modal)")].find(t=>t===e):!1}l(nn,"isModal");function rn(e,t){switch(e=String(e).trim(),!0){case/^(0|false|f)$/i.test(e):return!1;case/^(1|true|t)$/i.test(e):return!0;default:return t}}l(rn,"convert2Bool");function on(e){let t=e.length;for(;t--;){let n=en(t);[e[t],e[n]]=[e[n],e[t]]}return e}l(on,"shuffle");function Se(e){return p(e,String)?e.toLowerCase().split("-").map((t,n)=>n&&`${an(t)}`||t).join(""):e}l(Se,"toCamelcase");function R(e){return e.replace(/[A-Z]/g,t=>`-${t.toLowerCase()}`).replace(/^-|-$/,"")}l(R,"toDashedNotation");function an([e,...t]){return`${e.toUpperCase()}${t.join("")}`}l(an,"ucFirst");function xe(e){return p(e,Comment,Text)}l(xe,"isCommentOrTextNode");function Xe(e){p(e,Comment)}l(Xe,"isComment");function ln(e){return p(e,Text)}l(ln,"isText");function ve(e){return p(e,String)&&/^<|>$/.test(`${e}`.trim())}l(ve,"isHtmlString");function we(e){return p(e,Array)&&!e?.find(t=>!W(t))}l(we,"isArrayOfHtmlElements");function et(e){return p(e,Array)&&!e?.find(t=>!ve(t))}l(et,"isArrayOfHtmlStrings");function D(e,t){let n=e.collection.filter(r=>!xe(r));for(let r=0;r<n.length;r+=1)t(n[r],r);return e}l(D,"loop");function tt(e,t,n){let r=t!==document.body&&p(e,String)&&e.toLowerCase()!=="body"?t:document,o;try{n.collection=[...r.querySelectorAll(e)]}catch{o=`JQx: Invalid CSS querySelector. [${p(e,String)?e:"Not a string!"}]`}let i=n.collection.length;return i<1?`CSS querySelector "${e}", output: nothing`:o??`CSS querySelector "${e}", output ${i} element${i>1?"s":""}`}l(tt,"setCollectionFromCssSelector");function sn(){return{isCommentOrTextNode:xe,isNode:W,isComment:Xe,isText:ln,isHtmlString:ve,isArrayOfHtmlElements:we,isArrayOfHtmlStrings:et,ElemArray2HtmlString:Xt,input2Collection:Ge,setCollectionFromCssSelector:tt,cssRuleEdit:jt({createWithId:"JQxStylesheet"})}}l(sn,"selectedFactoryHelpers");function cn(){let e=Object.freeze({notInDOM:"n/a",writable:"n/a",modal:"n/a",empty:!0,open:"n/a",visible:"n/a"});return t=>{let n=t.node;return p(n,Node)?Object.freeze({get writable(){return Kt(n)},get modal(){return nn(n)},get inDOM(){return n.isConnected},get open(){return n.open??!1},get visible(){return Gt(n)},get disabled(){return n.hasAttribute("readonly")||n.hasAttribute("disabled")},get empty(){return t.collection.length<1},get virtual(){return t.isVirtual}}):e}}l(cn,"ExamineElementFeatureFactory");function un(e,t,n,r){n&&p(t,String)&&(t={[t]:n==="-"?"":n});let o;t.className&&(o=t.className,delete t.className),o=[...e.classList].find(i=>i.startsWith("JQxClass-")||o&&i===o)||o||`JQxClass-${Ke().slice(1)}`,r.editCssRule(`.${o}`,t),e.classList.add(o)}l(un,"css");var Tr=cn();function mn(e){return{factoryExtensions:dn(e),instanceExtensions:fn(e)}}l(mn,"default");function dn(e){return{data(t){return{get all(){return new Proxy(t[0]?.dataset??{},wr)},set(n={}){if(!t.is.empty&&p(n,Object))for(let[r,o]of Object.entries(n))t.setData({[r]:o});return t},get(n,r){return t.data.all[n]??r},add(n={}){if(!t.is.empty&&p(n,Object))for(let[r,o]of Object.entries(n))t.setData({[r]:o});return t},remove(n){return t[0]?.removeAttribute(`data-${R(n)}`),t}}},dimensions(t){if(t.is.empty)return L.error("[JQx instance].dimensions called on empty instance"),{error:"[JQx instance].dimensions: NO ELEMENTS"};let{node:n}=t,r=n.getBoundingClientRect().toJSON();return r.scrollTopDistance=ge(n,0),r.scrollLeftDistance=ge(n,0,!1),r},node(t){return t[0]},HTML(t){return{get(n,r){if(t.is.empty)return"NO ELEMENTS IN COLLECTION";let o=n?t.outerHtml:t.html();return r?ne(o):o},set(n,r=!1,o=!1){n=n.isJQx?n.HTML.get(1):n;let i=p(n,String);return n=i&&o?ne(n):n,i&&(n||"").trim().length&&t.html(n,r),t},replace(n,r=!1){return t.HTML.set(n,!1,r)},append(n,r=!1){return n=p(n,HTMLElement)?e(n).HTML.get(1):n.isJQx?n.HTML.get(1):n,t.HTML.set(n,!0,r)},insert(n,r=!1){return n=p(n,HTMLElement)?e(n).HTML.get(1):n.isJQx?n.HTML.get(1):n,t.HTML.set(n+t.HTML.get(),!1,r)}}},is(t){return Tr(t)},length(t){return t.collection.length},outerHtml(t){return(t.first()||{outerHTML:void 0}).outerHTML},parent(t){let n=e(t[0]?.parentNode);return n.is.empty?t:n},render(t){switch(!0){case!t.is.empty:return t.toDOM();default:return e.logger.warn("[JQx.render]: empty collection"),t}},Style(t){return{get computed(){return t.is.empty?{}:getComputedStyle(t[0])},inline(n){return t.style(n)},inSheet(n){return t.css(n)},valueOf(n){return t.is.empty?void 0:getComputedStyle(t[0])[R(n)]},nwRule(n){return t.Style.byRule({rules:n})},byRule({classes2Apply:n=[],rules:r=[]}={}){let o=p(r,String)&&!n.length?r.split("{")[0].trim():"";if(r=r&&p(r,String)?[r]:r,n=n&&p(n,String)?[n]:n,(r?.length||n?.length)&&(r?.length&&e.editCssRules(...r),n))for(let i of n)t.addClass(i);return o?.startsWith(".")&&t.addClass(o.slice(1)),o?.startsWith("#")&&!t.attr("id")&&t.prop({id:o.slice(1)}),t}}}}}l(dn,"factoryExtensionsFactory");function fn(e){return{addClass(t,...n){return D(t,r=>r&&n.forEach(o=>r.classList.add(o)))},after:Ze,afterMe:Ze,andThen(t,n,r=!1){if(!n||!p(n,String,Node,Proxy))return L.log("[JQx instance].[before(Me) | after(Me) | andThen]: invalid/-sufficient input."),t;n=n?.isJQx?n:p(n,Node)?e.virtual(n):e.virtual(J(n));let[o,i,c]=r?[0,"before",n.collection.concat(t.collection)]:[t.collection.length-1,"after",t.collection.concat(n.collection)];return t[o][i](...n.collection),t.collection=c,t},append(t,...n){if(t.is.empty||n.length<1)return t;let r=t.length===1;for(let o of n){if(!o.isJQx&&E(o)){let i=o.trim(),c=/^<(.+)[^>]+>$/m.test(i)?J(o):e.text(o);D(t,u=>u.append(r?c:U(c)))}W(o)&&D(t,i=>i.append(r?o:U(o))),o.isJQx&&!o.is.empty&&D(t,i=>o.collection.forEach(c=>i.append(r?c:U(c))))}return t},appendTo(t,n){switch(!0){case(!n.isJQx&&!p(n,HTMLElement)):return $.warn("[JQx instance].appendTo: invalid input"),t;default:return(n.isJQx?n:e(n)).append(t),t}},attr(t,n,r){if(!t.node)return t;if(!r&&E(n))return n=R(n),n==="class"?[...t.node.classList].join(" "):t.node.getAttribute(n);if(E(n)&&r)switch(n=R(n),!0){case n.startsWith("data-"):n={data:{[n.replace("data-","")]:r}};break;default:n={[n]:r}}return p(n,Object)&&!t.is.empty&&_t(t.node,n),t},before:ze,beforeMe:ze,clear(t){return D(t,ke)},closest(t,n){let r=E(n)?t.node?.closest(n):void 0;return r?e(r):t},computedStyle(t,n){let{node:r}=t;return r&&getComputedStyle(r)[n]},css(t,n,r){return D(t,o=>un(o,n,r,e))},duplicate(t,n=!1,r=document.body){switch(!0){case t.is.empty:return L.error("Duplicating an empty JQx instance is not possible"),t;default:let o=t.collection[0].cloneNode(!0);return o.childNodes.forEach(i=>{i.removeAttribute&&i?.removeAttribute("id")}),n?e(o).toDOM(r):e.virtual(o)}},each(t,n){return D(t,n)},empty(t){return D(t,ke)},find(t,n){return t.collection.length>0?[...t.first()?.querySelectorAll(n)]:[]},find$(t,n){return t.collection.length>0?e(n,t):t},first(t,n=!1){return t.collection.length>0?n?t.single():t.collection[0]:void 0},first$(t,n){return t.single(n)},getData(t,n,r){return t.node?.dataset?.[n]||r},hasClass(t,...n){return t.is.empty||!t.node.classList.length?!1:n.find(r=>t.node.classList.contains(r))&&!0||!1},hide(t){return D(t,n=>ue(n,{display:"none !important"}))},html(t,n,r){switch(!0){case(t.is.empty&&!E(n)):return"";case!E(n):return t.node?.getHTML()??"";default:let o=J(`<div>${n.isJQx?n.HTML.get(!0):n}</div>`);return D(t,l(i=>(i.textContent=r?i.textContent:"",i.insertAdjacentHTML(e.at.end,o.getHTML())),"cb"))}},htmlFor(t,n,r="",o=!1){if(t.is.empty||!E(n)||!E(r))return t;let i=t.find$(n);if(i.length<1)return t;let c=J(`<span>${r}</span>`);return i.each(u=>{o||(u.textContent=""),u.insertAdjacentHTML(e.at.end,c?.getHTML())}),t},isEmpty(t){return!t.node},nth$(t,n){return t.single(n)},on(t,n,...r){switch(!0){case(t.is.empty||!p(n,String,Array)||!E(n)||r.length<1):return t;default:return e.handle({type:n,node:t.node,handler:r}),t}},once(t,n,...r){switch(!0){case(t.is.empty||!p(n,String,Array)||!E(n)||r.length<1):return t;default:return e.handle({type:n,once:!0,node:t.node,handler:r}),t}},prepend(t,...n){if(t.is.empty||!n)return;let r=t.length===1;for(let o of n){if(E(o)){o=o.trim();let i=/^<(.+)[^>]+>$/m.test(o)?J(o):e.text(o);i=r?i:U(i),D(t,c=>c.prepend(i.cloneNode(!0)))}W(o)&&D(t,i=>i.prepend(r?o:U(o))),o.isJQx&&!o.is.empty&&(o.collection.length>1&&o.collection.reverse(),D(t,i=>D(o,c=>i.prepend(r?c:U(c)))),o.collection.reverse())}return t},prependTo(t,n){return n.isJQx||(n=e.virtual(n)),n.prepend(t),t},prop(t,n,r){if(p(n,String)&&!r)return n.startsWith("data")?t[0]?.dataset[n.slice(n.indexOf("-")+1)]:t[0]?.[n];let o=p(n,Object)?n:{[n]:r};for(let[i,c]of Object.entries(o)){if(i=i.trim(),c&&!Be(i)||!c)return!1;if(i.toLowerCase()==="id")return t[0].id=c;D(t,u=>{if(i.startsWith("data"))return u.dataset[i.slice(i.indexOf("-")+1)]=c;u[i]=c})}return t},remove(t,n){let r=l(i=>i.remove(),"remover"),o=l(()=>t.collection=t.collection.filter(i=>document.documentElement.contains(i)),"removeFromCollection");if(n){let i=t.find$(n);return i.is.empty||(D(i,r),o()),t}return D(t,r),o(),t},rmAttr(t,...n){for(let r of n)t.node.removeAttribute(r);return t},removeClass(t,...n){return D(t,r=>{if(r)for(let o of n)r.classList.remove(o)})},renderTo(t,n,r){return n=p(n,HTMLElement)||n.isJQx?n:document.body,r=p(r,String)&&e.at[r]?r:e.at.end,t.first$().toDOM(n,r),t},replace(t,n,r){let o=t.node;return!n||!p(r,HTMLElement)&&!r?.isJQx?(e.logger.error("JQx replace: invalid replacement value"),t):((r.isJQx||p(r,NodeList))&&(r=r[0]),o&&n&&(n=p(n,String)?o.querySelectorAll(n):n.isJQx?n.collection:n,p(n,HTMLElement,NodeList,Array)&&p(r,HTMLElement)&&(p(n,HTMLElement)?[n]:[...n]).forEach(i=>i.replaceWith(r.cloneNode(!0)))),t)},replaceClass(t,n,...r){return D(t,o=>{o.classList.remove(n);for(let i of r)o.classList.add(i)})},replaceMe(t,n){return t.replaceWith(n)},replaceWith(t,n){return n=p(n,Element)?n:n.isJQx?n[0]:void 0,n&&(t[0].replaceWith(n),t=e.virtual(n)),t},setData(t,n){return D(t,r=>_e(r,n))},show(t){return D(t,n=>ue(n,{display:"revert-layer !important"}))},single(t,n){let r=t.collection.length>0;switch(n=n??0,!0){case(r&&p(n,String)):return t.find$(n);case(r&&p(n,Number)):return e(t.collection[n]);case r:return t.collection[0];default:return t}},style(t,n,r){return D(t,l(o=>{r&&p(n,String)&&(n={[n]:r||"none"}),ue(o,n)},"loopCollectionLambda"))},text(t,n,r=!1){switch(!0){case t.isEmpty():return t;case!p(n,String):return t.node.textContent;default:return D(t,o=>o.textContent=r?o.textContent+n:n)}},toDOM(t,n=document.body,r=H.BeforeEnd){return t.isVirtual=!1,fe(t.collection,n,r),t},toggleClass(t,n){return D(t,r=>r.classList.toggle(n))},toNodeList(t){return[...t.collection].map(n=>document.importNode(n,!0))},trigger(t,n,r,o){if(r=/Event\]$/.test(p(r))?r:Event,o=p(o,Object)?{...o,bubbles:o.bubbles??!0}:{bubbles:!0},!t.is.empty){let i=new r(n,o);t.each(c=>c.dispatchEvent(i))}return t},val(t,n){switch(!0){case(t.is.empty||!p(t.node,HTMLInputElement,HTMLSelectElement,HTMLTextAreaElement)):return t;case!p(n,String):return t.node.value;default:return t.node.value=p(n,String)?n:"",t}}}}l(fn,"instanceExtensionsFactory");var He,pe,{isComment:jo,isText:Eo,isHtmlString:Ao,isArrayOfHtmlElements:Lo,isArrayOfHtmlStrings:Fo,ElemArray2HtmlString:Mo,cssRuleEdit:Re,addFn:$r}=gn();function gn(){return{...sn(),addFn:pn}}l(gn,"selectedUtilitiesFactory");function pn(e,t){return e=e?.trim(),!E(e)||!p(t,Function)?L.error("JQx.fn: method invalid parameter(s)"):pe[e]=(n,...r)=>t(n,...r)}l(pn,"addFnMethod");function yn(e){return function(t,n,r){if(t=t?.trim(),!E(t)||!p(n,Function))return e.error("JQx.staticFn: invalid parameter(s)");let o=r?{get(){return n()}}:{value(...i){return n(...i)}};try{Object.defineProperty(e,t,o)}catch{return e.warn(`JQx.staticFn: extension [${t}] already exists`)}return L.log(`JQx: added static extension function [${t}]`)}}l(yn,"staticFNMethodFactory");function ee(e){return new Proxy(e,Object.freeze({get:l((t,n)=>hn(t,n,e),"get")}))}l(ee,"proxify");function Je(e,t){return(...n)=>p(e,Function)&&e(ee(t),...n)}l(Je,"wrap");function hn(e,t,n){switch(!0){case p(t,Symbol):return e;case p(+t,Number):return e.collection?.[t]||void 0;case t in He:return Je(He[t],n)();case t in pe:return Je(pe[t],n);default:return e[t]}}l(hn,"proxyKeyFactory");function bn(e){let t=Tn(e);for(let[n,r]of Object.entries(Object.getOwnPropertyDescriptors(t)))Object.defineProperty(e,n,r);return e}l(bn,"addJQxStaticMethods");function Sn(e){return{allow(t){let n=/-/.test(t),r=n&&t;t=n?Se(t):t.toLowerCase(),te.allowTag(t),Object.defineProperties(e,ye(t,!0,e,r))},prohibit(t){t=t.toLowerCase(),te.prohibitTag(t),Object.defineProperties(e,ye(t,!1,e))}}}l(Sn,"allowances");function Qe(...e){if(e.length===1){let t=String(e.shift().trim());e=t.startsWith("!")?[t.slice(1,-1)]:t.split(",").map(n=>n.trim())}for(let t of e.map(n=>n.startsWith("!")?n.slice(1,-1):n))Re(t,{removeRule:1})}l(Qe,"cssRemove");function xn(e){return function(t,n,r){n=n?.isJQx?n?.[0]:n,r=r&&Object.values(H).find(i=>r===i);let o=e(t,document.createElement("br"));if(n&&!p(n,HTMLBRElement))for(let i of o.collection)r?n.insertAdjacentElement(r,i):n.append(i);return o}}l(xn,"virtualFactory");function vn(...e){let t={};for(let n of e){let r=Object.getOwnPropertyDescriptors(n);for(let[o,i]of Object.entries(r))!(o in t)&&Object.defineProperty(t,o,{...i,enumerable:!1})}return t}l(vn,"combineObjectSources");function wn(e,t,n,r){return e=R(r||e.toLowerCase()),{get(){return(...o)=>(L.log(t?`JQx: created (virtual) instance from [JQx].${e}`:`JQx: ${e.toUpperCase()} is prohibited. Use [JQx].allowTag if necessary.`),t&&n.virtual(be(hr[e](...o)))||void 0)},enumerable:!1,configurable:!0}}l(wn,"tagGetterFactory");function ye(e,t,n,r){e=e.toLowerCase();let o=wn(e,t,n,r);return r?{[r]:o,[Se(r)]:o}:{[e]:o,[e.toUpperCase()]:o}}l(ye,"addGetters");function Tn(e){return vn(Object.entries(te.tagsRaw).reduce($n(e),{}),En(e))}l(Tn,"defaultStaticMethodsFactory");function $n(e){return function(t,[n,r]){return Object.defineProperties(t,ye(n,r,e)),t}}l($n,"staticTagsLambda");function On(e){return function(t,n,...r){p(n,Function)&&(r.push(n),n=void 0),e({type:t,selector:n,handlers:r})}}l(On,"delegateFactory");function Dn(e){return function(t){let{type:n,types:r,origin:o,selector:i,handler:c,handlers:u,node:b,name:h,capture:g,once:v,about:y}=t;c=u||c,n=r||n,i=o||i;let w=tn(n),S=h;c=p(c,Function)?[c]:c;let f={type:w,selector:i||o,capture:g,name:S,once:v,node:b,about:y};switch(!0){case(p(w,Array)&&w.length>0):for(let x of w)f.type=x,Ue(c,f,e);break;default:return Ue(c,f,e)}}}l(Dn,"delegateCaptureFactory");function Ue(e,t,n){for(let r of e)n.listen({...t,handler:r})}l(Ue,"assignListeners");function Cn(e){return function(t,n){return n=E(n)&&n,t=E(t)&&t,n&&t&&e.listenerStore[t][n]}}l(Cn,"getNamedListenerFactory");function Nn(e){return e.activePopup||Object.defineProperty(e,"activePopup",{value:Ut(e),enumerable:!1}),e.activePopup}l(Nn,"popupGetter");function jn(e){let t=l((u,b)=>Re(u,b),"editCssRule"),n=l(function(u){return jt({createWithId:u||`jqx${Ke()}`})},"createStyle"),r=l(function(...u){for(let b of u)Re(b)},"editCssRules"),o=Sn(e),i=Wt(e),c=Dn(i);return{editCssRule:t,createStyle:n,editCssRules:r,allowProhibit:o,handle:c,capturedHandling:c,log:l((...u)=>L.on.log(...u).off,"log"),warn:l((...u)=>L.on.warn(...u).off,"warn"),error:l((...u)=>L.on.error(...u).off,"error"),handlerWrapper:i}}l(jn,"getSelectedStaticMethods");function En(e){let{factoryExtensions:t,instanceExtensions:n}=mn(e);He=t,pe=n;let{editCssRule:r,createStyle:o,editCssRules:i,allowProhibit:c,handle:u,capturedHandling:b,log:h,warn:g,error:v,handlerWrapper:y}=jn(e),w=Cn(e),S=yn(e);return{log:h,warn:g,error:v,editCssRules:i,createStyle:o,editStylesheet:o,editCssRule:r,escHtml:ne,logger:L,text(f,x=!1){return x?e.comment(f):document.createTextNode(f)},node(f,x=document){return x.querySelector(f,x)},nodes(f,x=document){return[...x.querySelectorAll(f,x)]},clearAllTimers:qt,get staticFn(){return function(f,x,O){return S(f,x,O)}},get toBool(){return rn},get getNamedListener(){return w},get virtual(){return xn(e)},get allowTag(){return c.allow},get prohibitTag(){return c.prohibit},get removeCssRule(){return Qe},get removeCssRules(){return Qe},get delegate(){return On(b)},get delegateCaptured(){return b},get handle(){return b},get listen(){return y.listen},get at(){return H},get setStyle(){return r},get fn(){return $r},get lenient(){return te.allowUnknownHtmlTags},get IS(){return p},get Popup(){return Nn(e)},get listenerStore(){return y.ListenerStore}}}l(En,"staticMethodsFactory");var Or=bn(An());function An(){return function(e,t,n=H.BeforeEnd){if(e?.isJQx)return e;let r=p(t,HTMLBRElement);t=(!r&&t&&t.isJQx?t[0]:t)||document.body,n=n&&Object.values(H).find(h=>n===h)?n:void 0;let o=ve(e),i=!o&&et(e)||o,c={collection:Ge(e)??[],isVirtual:r,isJQx:!0},u=we(c.collection);if(c.collection.length&&u)return r||c.collection.forEach(h=>{t.contains(h)||fe([h],t,n)}),ee(c);if(i){if([e].flat().forEach(h=>c.collection.push(J(h))),c.collection.length>0){let h=c.collection.filter(w=>w?.dataset?.jqxcreationerror);c.collection=c.collection.filter(w=>!w?.dataset?.jqxcreationerror);let g=c.collection.map(w=>`${String(w.constructor).split(/function|\(/)[1].trim()}`),v=g.length>1,y=c.collection.length?g.join(", "):"sanitized: no elements remaining";L.log(`JQx: created ${c.isVirtual?"(virtual)":""} instance from ${v?"array of ":""}HTML string${v?"s":""} (${y})`),c.isVirtual||fe(c.collection,t,n)}return ee(c)}let b=tt(e,t,c);return e!==null&&L.log(`JQx: input => ${b}`),ee(c)}}l(An,"JQxMainFactory");var Q=Or;var[V,B,rt,ot]=["2-digit","numeric","long","short"],Te={fixed:{MM:{month:rt},M:{month:ot},m:{month:B},mm:{month:V},yyyy:{year:B},yy:{year:V},WD:{weekday:rt},wd:{weekday:ot},d:{day:B},dd:{day:V},h:{hour:B},hh:{hour:V},mi:{minute:B},mmi:{minute:V},s:{second:B},ss:{second:V},ms:{fractionalSecondDigits:3},tz:{timeZoneName:"shortOffset"},dl:{locale:"default"},h12:{hour12:!1},yn:{yearName:""},ry:{relatedYear:!0},msp:{fractionalSecond:!0}},dynamic:{tzn:e=>({timeZoneName:e.slice(4)}),hrc:e=>({hourCycle:`h${e.slice(4)}`}),ds:e=>({dateStyle:e.slice(3)}),ts:e=>({timeStyle:e.slice(3)}),tz:e=>({timeZone:e.slice(3)}),e:e=>({era:e.slice(2)}),l:e=>({locale:e.slice(2)})}},_={...Te,retrieveDynamic(e){let t=e?.slice(0,e?.indexOf(":"));return Te.dynamic[t]&&Te.dynamic[t](e)},get re(){return new RegExp(`\\b(${Object.keys(Te.fixed).join("|")})\\b`,"g")}},Ce=Dr;function Dr(e,t,n="l:default"){return/ds:|ts:/.test(n)?Cr(e,Ln(void 0),n):jr(e,Ln(t||void 0),n)}function Ln(e="dtf",t=0){let n=` ${e.replace(/(?<=\{)(.+?)(?=})/g,o=>`[${t++}]`).replace(/[{}]/g,"").trim()} `,r=e.match(/(?<=\{)(.+?)(?=})/g)||[];return{get texts(){return r},formatString(o){n=o},set formatStr(o){n=o},get formatStr(){return n},get units(){return n.match(_.re)||[]},finalize(o="",i="",c="",u=""){return n.replace(/~([\d+]?)/g,"$1").replace(/dtf/,o).replace(/era/,c).replace(/dp\b|~dp\b/,i).replace(/yn\b/,u).replace(/\[(\d+?)]/g,(b,h)=>r[h].trim()).trim()}}}function Vn(...e){return e?.reduce((t,n)=>({...t,..._.retrieveDynamic(n)||_.fixed[n]}),_.fixed.dl)}function Cr(e,t,n){let r=Vn(...Bn(n).split(",")),o=Intl.DateTimeFormat(r.locale,r).format(e);return t.finalize(o)}function Nr(e,t){return e==="numeric"&&t.startsWith("0")?t.slice(1):t}function jr(e,t,n){let r=Vn(...t.units.concat(Bn(n).split(",")).flat()),o={..._.fixed},i=Intl.DateTimeFormat(r.locale,r).formatToParts(e).reduce((c,u)=>u.type==="literal"&&/[ ,/-]/.test(u.value)?c:{...c,[u.type]:Nr(r[u.type],u.value)},{});return o.ms=r.fractionalSecondDigits?o.msp:o.ms,o.yyyy=i.relatedYear?o.ry:o.yyyy,t.formatStr=t.formatStr.replace(_.re,c=>/^(M|MM)$/.test(c)?Er(e,r.locale,r.timeZone,/^M$/.test(c)):i[Object.keys(o[c]).shift()]||c),t.finalize(void 0,i.dayPeriod,i.era,i.yearName)}function Er(e,t,n,r){return e.toLocaleString(t,{timeZone:n,month:r?ot:rt})}function Bn(e){return e.replace(/\s+/g,"")}var Ar=Lr;function Lr(){let e=(r,o)=>{let i=isNaN(new Date(r)),c=isNaN(new Date(o));if(c){let[u,b,h]=Array(3).fill("end date not valid");return{error:!0,message:u,full:b,clean:h}}if(i){let[u,b,h]=Array(3).fill("start date not valid");return{error:!0,message:u,full:b,clean:h}}if(i&&!c){let[u,b,h]=Array(3).fill("start- and/or end date are not valid");return{error:!0,message:u,full:b,clean:h}}return{error:!1}},t=n();return function({start:r,end:o,diffs:i={}}={}){let c=e(r,o),u=o>r?"+":"-";if(c.error)return c;let b=Math.abs(r-o),h=new Date(b),g=h.getUTCFullYear()-1970,v=h.getUTCMonth(),y=h.getUTCDate()-1,w=y%7,S=Math.floor(y/7),f=h.getUTCHours(),x=h.getUTCMinutes(),O=h.getUTCSeconds(),A=h.getUTCMilliseconds(),a=Math.floor(b/864e5);i={...i,fromUTC:r,toUTC:o,sign:"",years:g,months:v,days:y,hours:f,minutes:x,seconds:O,milliseconds:A,diffInDays:a},i.full=t({values:i,full:!0}),i.clean=t({values:i}),i.equalDates=i.clean==="Dates are equal";let s=f+x+O>0?"T":"";return i.clean!=="Dates are equal"&&(i.sign=u,i.jsPeriod=`${u}P${g>0?`${g}Y`:""}${v>0?`${v}M`:""}${S>0?`${S}W`:""}${w>0?`${w}D`:""}${s}${f>0?`${f}H`:""}${x>0?`${x}M`:""}${O>0?`${O}S`:""}`,i.ISOPeriod=`P${g>0?`${g}Y`:""}${v>0?`${v}M`:""}${y>0?`${y}D`:""}${s}${f>0?`${f}H`:""}${x>0?`${x}M`:""}${O>0?`${O}S`:""}`),i};function n(){let r=(...i)=>c=>i.reduce((u,b)=>b(u),c),o=(i,c)=>i===1?c.slice(0,-1):c;return r(({values:i,full:c})=>[Object.entries(i).filter(([u])=>/^(years|month|days|hours|minutes|seconds)/i.test(u)),c],([i,c])=>c?i:i.filter(([,u])=>c?+u:u>0),i=>i.reduce((c,[u,b])=>[...c,`${b} ${o(b,u)}`],[]),i=>i.length<1?"Dates are equal":`${i.slice(0,-1).join(", ")}${i.length>1?" and ":""}${i.slice(-1).shift()}`)}}var Fr=Mr;function Mr(){let e=Object.entries({year:"FullYear",month:"Month",date:"Date",day:"Date",hour:"Hours",minute:"Minutes",second:"Seconds",millisecond:"Milliseconds"}).reduce((r,[o,i])=>({...r,[o]:i,[`${o}s`]:i}),{}),t=!1,n=function(...r){let o=r.length===1;return t=r[0].trim().startsWith("subtract,"),t&&(r=o?r[0].trim().replace(/^subtract,/i,"").split(",").map(i=>i.trim()):r.filter(i=>!i.startsWith("subtract"))),o&&!t&&(r=r[0].split(",").map(i=>i.trim())),r.map(function(i){if(!i)return!1;let c=i.toLowerCase().split(/ {1,}/);return c.length<2?!1:c.map(u=>{u=`${u}`.trim().replace(/[^a-z0-9-+]/g,"");let b=parseInt(u,10);return Number.isNaN(b)?u:t?-b:+b})}).filter(i=>i)};return function(r,...o){if(o.length<1)return r;let i=n(...o);return i.length&&i.forEach(([c,u])=>{u=u,u=e[u],c&&u&&r[`set${u}`](r[`get${u}`]()+c)}),r}}var Yn=Ar(),_n=Qr(),z=Fr();function Fn(e,...t){return z(e,...t),e}function nt(e,{start:t,end:n,future:r,past:o,include:i={start:!1,end:!1}}={}){let c=e.clone.UTC;return t=t?.value||t?.constructor===Date?C(t?.value||t).UTC:C.now.UTC,n=n&&n?.value||n?.constructor===Date?C(n?.value||n).UTC:C.now.UTC,c.milliseconds=0,t.milliseconds=0,n.milliseconds=0,r?t>n:o?t<n:(i.start?+c>=+t:+c>+t)&&(i.end?+c<=+n:+c<+n)}function Mn(e,{zoneTime:t=!1,formatStr:n,moreOptions:r}={}){return r=t?e.localeInfo.formatOptions+(r?`,${r}`:""):N.formatOptions+(r?`,${r}`:""),t?(e.localeInfo||(e.localeInfo=N),Ce(e,n,r)):Ir(e,n,r)}function Ir(e,t,n){let r=e.clone.relocate(N);return n=(n||"").startsWith("+")?`${r.localeInfo.formatOptions},${n.slice(1)}`:n||r.localeInfo.formatOptions,Ce(r,t,n)}function kr(e,t){let n=Yn({start:e,end:t||e});return parseInt(`${n.sign}${n.diffInDays}`)}function In(e,t=!1){let{locale:n,timeZone:r}=t?e.localeInfo:N,o=sr(n,r),i=e.format("MM|WD",o).split("|");return{locale:n,timeZone:r,monthName:i[0],dayName:i[1],dayNames:lr(n),monthNames:ut(n)}}function kn(e,t=!1){let[n,r,o,i]=it(e,t),c={values4Timezone:t?N.timeZone:e.timeZone,hours:n,minutes:r,seconds:o,milliseconds:i};return Object.freeze(c)}function it(e,t=!1){let n=`l:en-CA,${t?`tz:${N.timeZone}`:`tz:${e.timeZone}`},hrc:23,ts:medium`;return e.format("",n).split(/:/).map(Number).concat(e.getMilliseconds())}function Pn(e,t){let n=t?`tz:${N.timeZone}`:`,tz:${e.timeZone}`,[r,o,i]=e.format("yyyy-mm-dd",n).split(/-/).map(Number);o-=1;let c=t?N.timeZone:e.timeZone;return Object.freeze({values4Timezone:c,year:r,month:o,date:i})}function Zn(e,t=!0){if(t)return[e.getFullYear(),e.getMonth(),e.getDate()];let n=e.format("yyyy-m-d",e.localeInfo.formatOptions).split(/-/).map(Number);return n[1]-=1,n}function Pr(e,{sunday:t=!1}={}){return at(e,{day:t?"sunday":"monday"})}function Zr(e,t){let n=e.toString().match(/GMT([+-])\d+/)?.[0]?.slice(3)??"+0000",r=t.toString().match(/GMT([+-])\d+/)?.[0]?.slice(3)??"+0000";return n=lt(n.slice(0,3)+":"+n.slice(-2),!0),r=lt(r.slice(0,3)+":"+r.slice(-2),!0),[-n[0]+r[0],-n[1]+r[1]].map(o=>n[0]<0?-o:o)}function Gn({start:e,end:t}={}){t||(t=e.clone),t?.clone||(t=C(t,{timeZone:e.timeZone})),e=C(Jn(e,e.timeZone),{timeZone:e.timeZone}),t=C(Jn(t,t.timeZone),{timeZone:t.timeZone});let n=Yn({start:e,end:t,diffs:{timeZoneStart:e.timeZone,timeZoneEnd:t.timeZone}}),r=Zr(t,e),o=r[0]>0?"ahead of":"behind",[i,c]=r.map(h=>Math.abs(h)),[u,b]=[`${i} ${ie(i,"hour")}`,`${c} ${ie(c,"minute")}`];return n.timeZonesOffsetDifference=n.sign.length<1||i+c===0?`Offsets of ${e.timeZone} and ${t.timeZone} are equal`:`${e.timeZone} is ${u}${c>0?` and ${b}`:""} ${o} ${t.timeZone}`,n}function zr(e){return e==="+"?"-":"+"}function zn(e,t){let n=String(t).toLowerCase()==="utc"||t.timeZone==="UTC";t=n?e.clone.relocate({timeZone:"UTC"}):C(e.value,{timeZone:t.timeZone||N.timeZone});let r=Gn({start:e.clone,end:t}),o=`${n?zr(r.sign):r.sign}${Hn(r.hours)}:${Hn(r.minutes)}`;return{fromTZ:e.timeZone,toTZ:t.timeZone,offset:o,offsetText:`${t.timeZone} `+Hr(o)+` ${e.timeZone}`}}function Hn(e,t=2){return`${e}`.padStart(t,"0")}function ie(e,t){return`${t}${e>1||e===0?"s":""}`}function Hr(e){if(/00:00/.test(e))return"no time diffence to";let t=e.slice(1).split(":").map(Number),[n,r]=t,o=e.at(0)==="+";return r>0?`${n} ${ie(n,"hour")} and ${r} ${ie(r,"minute")} ${o?"ahead of":"behind"}`:`${n} ${ie(n,"hour")} ${o?"ahead of":"behind"}`}function Rn(e,t,n){return e.clone.format(t,n||e.localeInfo.formatOptions)}function Rr(e,{withFormat:t,withFormatOptions:n,local:r=!1}={}){if(t)return r?Rn(e,t,$D.localeInformation.formatOptions):Rn(e,t,n);let o=e.clone.relocate({locale:"en"}),i=r?N.formatOptions:o.localeInfo.formatOptions,c=`wd M dd yyyy hh:mmi:ss ${o.format("tz",i+",tzn:longOffset").replace(":","")} (tz)`;return o.format(c,i+",tzn:long, hrc:23")}function Kn(e,t=!1){let n=Intl.DateTimeFormat("en",{timeZone:t?e.timeZone:N.timeZone,weekday:"short"});return _n(n.format(e))}function Jr(e){let t=N,n=e.localeInfo,r=e.clone.relocate({locale:t.locale,timeZone:t.timeZone}),o=e.offsetFrom(r),i=r.offsetFrom(e),c=t,u=n,b=e.format("hh:mmi:ss dp",`hrc:12,tz:${e.timeZone}`),h=r.format("hh:mmi:ss dp",`hrc:12,tz:${r.timeZone}`),g={note:"'user' are values for your locale/timeZone, 'remote' (if applicable) idem for the instance",locales:{user:{locale:c.locale,timeZone:c.timeZone}},dateTime:{user:{...e.dateTime,monthName:r.monthName,weekdayNr:r.day,weekdayName:r.dayName,dayPeriodTime:h,hasDST:r.hasDST,DSTActive:r.DSTActive,offsetFromRemote:o.offset,string:r.toString()}},offset:{fromUTC:e.UTC.offsetFrom(e).offsetText}};return n.timeZone!==t.timeZone&&(g.locales.remote={locale:u.locale,timeZone:u.timeZone},g.dateTime.remote={...e.zoneDateTime,monthName:e.zoneNames.monthName,weekdayNr:Kn(e,!0),weekdayName:e.zoneNames.dayName,dayPeriodTime:b,hasDST:e.hasDST,DSTActive:e.DSTActive,offsetFromUser:i.offset,string:e.toString()},g.offset.fromUserTime=i.offsetText),g}function $e(e,t=!0){if(t)return[e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds()];let n=e.format("yyyy-m-d-hh-mmi-ss",`${e.localeInfo.formatOptions},hrc23:true`).split(/-/).map(Number).concat(e.getMilliseconds());return n[1]-=1,n}function Xn(e){return new Date(e.year,e.month+1,0,0,0,0).getDate()}function er(e,t){t=F({locale:t}).locale;let n=e.clone.relocate({locale:t});return n.date={date:1},[n].concat([...Array(Xn(n)-1)].map((r,o)=>n.clone.add(`${o+1} days`)))}function at(e,{day:t,next:n=!1}={}){let r=_n(t?.toLowerCase()),o=C(new Date(...e.dateTimeValues),e.localeInfo);return r<0?(console.error(`[TickTock instance].next/previous invalid day value ${t}`),o):tr(o,r,n?1:-1)}function tr(e,t,n){return z(e,`${n} day`).getDay()<t?tr(e,t,n):e}function Oe(e,{dateOnly:t=!1,timeOnly:n=!1}={}){e.localeInfo||(e.localeInfo=oe());let{locale:r,timeZone:o}=e.localeInfo;return t?new Date(e).toLocaleDateString(r,{timeZone:o}):n?new Date(e).toLocaleTimeString(r,{timeZone:o}):new Date(e).toLocaleString(r,{timeZone:o})}function Jn(e,t){let n={timeZone:t,hourCycle:"h23"};return new Date(new Date(e).toLocaleString("en",n))}function re(e,{year:t,month:n,date:r}={}){return M(t)&&e.setFullYear(parseInt(t)),M(r)&&e.setDate(parseInt(r)),M(n)&&e.setMonth(parseInt(n)),e}function Y(e,{hours:t,minutes:n,seconds:r,milliseconds:o}={}){return M(t)&&e.setHours(parseInt(t)),M(n)&&e.setMinutes(parseInt(n)),M(r)&&e.setSeconds(parseInt(r)),M(o)&&e.setMilliseconds(parseInt(o)),e}function nr(e){return e?.constructor===Date||e?.value}function Qn(e,t){return nr(t)?C(t?.value||t,e.localeInfo):C.from(...e.dateTimeValues).relocate(e.localeInfo)}function Qr(){let e={short:["sun","mon","tue","wed","thu","fri","sat"],long:["sunday","monday","tuesday","wednesday","thursday","friday","saturday"]};return function(t){t=`${t}`.toLowerCase();let n=e.short.indexOf(t);return n<0?e.long.indexOf(t):n}}function lt(e,t=!1){if(t){let n=e.slice(1).split(/[-:]/).map(Number),r=e.slice(0,1)==="-";return n=n.map(o=>r?-o:o),n}return Number(e.split(/[+-]/).slice(-1)[0].replace(/:/,""))}function Ur(e){return e.time={hours:0,minutes:0,seconds:0,milliseconds:0},e}function Un(e,t){return Intl.DateTimeFormat("en-CA",{timeZone:t,timeZoneName:"long"}).format(e).split(/,/)[1].trim()}function rr(e,t){t=t||e?.timeZone||N.timeZone,e=e?.value?e:e?.constructor===Date?C(e,{timeZone:t}):C({timeZone:t});let n=e.year||e.getFullYear(),r=Un(new Date(n,0,1),t),o=Un(new Date(n,5,1),t);return r!==o}function or(e,t){return t=t||e?.timeZone||N.timeZone,e=e?.hasDST?e:e?.constructor===Date?C(e,{timeZone:t}):C({timeZone:t}),e.hasDST?!/standard/i.test(e.toString()):!1}function Wr(e,{locale:t,timeZone:n,l:r,tz:o}={}){return e.localeInfo=F({locale:r||t||e.l||e.locale,timeZone:o||n||e.tz||e.timeZone}),e}function qr(e,t){return nr(t)&&(e=C(t.value||t,t.localeInfo||e.localeInfo)),e}function ct(e,t){let n=ir(new Date(e,11,t||31));return n===1?ct(e,(t||31)-1):n}function Wn(e,t){let n=e.month;switch(!0){case n<3:return t?1:"First";case n<6:return t?2:"Second";case n<9:return t?3:"Third";case n<12:return t?4:"Fourth";default:return"unknown"}}function ir(e){let t=new Date(e),n=(t.getDay()+6)%7;t.setDate(t.getDate()-n+3);let r=t.valueOf();return t.setMonth(0,1),t.getDay()!==4&&t.setMonth(0,1+(4-t.getDay()+7)%7),1+Math.ceil((r-t)/6048e5)}var ar=Vr;function Vr({localeInfo:e,customMethods:t,dateValue:n}={}){let r,o={add(...i){return Fn(r,...i)},between({start:i,end:c,include:u}={}){return nt(r,{start:i,end:c,include:u})},cloneWith(i){return Qn(r,i)},daysUntil(i){return kr(r,i)},differenceTo(i){return Gn({start:r,end:i})},differenceUntil(i){return r.differenceTo(i).clean},firstWeekday({sunday:i=!1,midnight:c=!1}={}){return Pr(r,{sunday:i,midnight:c})},format(i,c){return Mn(r,{formatStr:i,moreOptions:c})},fullMonth(i){return er(r,i)},isFuture(i){return nt(r,{start:r,end:i,future:!0})},isPast(i){return nt(r,{start:r,end:i,past:!0})},next(i){return at(r,{day:i,next:!0})},offsetFrom(i){return zn(r,i)},previous(i){return at(r,{day:i,next:!1})},relocate({locale:i,timeZone:c,l:u,tz:b}={}){return Wr(r,{locale:i,timeZone:c,l:u,tz:b})},revalue(i){return r=qr(r,i),r},setDateValues({year:i,month:c,date:u}={}){return re(r,{year:i,month:c,date:u})},setTimeValues({hours:i,minutes:c,seconds:u,milliseconds:b}={}){return Y(r,{hours:i,minutes:c,seconds:u,milliseconds:b})},subtract(...i){return Fn(r,"subtract,"+i.join(","))},toArray(i=!1){return $e(r,i)},toString({template:i,formatOptions:c,local:u}={}){return Rr(r,{withFormat:i,withFormatOptions:c,local:u})},values(i=!1){return i?r.dateTime:r.zoneDateTime},zoneFormat(i,c){return Mn(r,{zoneTime:!0,formatStr:i,moreOptions:c})},set date({year:i,month:c,date:u}){re(r,{year:i,month:c,date:u})},set dateNr(i){re(r,{date:i})},set hours(i){Y(r,{hours:i})},set localeInfo({locale:i,timeZone:c,l:u,tz:b}){e=oe({locale:i,timeZone:c,l:u,tz:b})},set milliseconds(i){Y(r,{milliseconds:`${i}`})},set minutes(i){Y(r,{minutes:i})},set month(i){re(r,{month:i})},set seconds(i){Y(r,{seconds:i})},set time({hours:i,minutes:c,seconds:u,milliseconds:b}){Y(r,{hours:i,minutes:c,seconds:u,milliseconds:b})},set year(i){re(r,{year:i})},get age(){return r.differenceTo(new Date).years},get ageFull(){return r.differenceTo(new Date).clean},get clone(){return Qn(r)},get date(){return Pn(r,!0)},get dateNr(){return r.date.date},get dateTime(){return{...r.date,...r.time}},get dateTimeValues(){return $e(r,!0)},get dateValues(){return Zn(r,!0)},get day(){return r.getDay()},get dayName(){return r.names.dayName},get daysThisMonth(){return Xn(r)},get DSTActive(){return or(r)},get hasDST(){return rr(r)},get hours(){return r.time.hours},get info(){return Jr(r)},get isLeapYear(){return new Date(r.getFullYear(),2,0).getDate()===29},get ISO(){return r.toISOString()},get local(){return Oe(r)},get localDate(){return Oe(r,{dateOnly:!0})},get locale(){return(e||oe()).locale},get localeInfo(){return e},get localeString(){return Oe(r)},get localTime(){return Oe(r,{timeOnly:!0})},get milliseconds(){return r.getMilliseconds()},get minutes(){return r.time.minutes},get month(){return r.date.month},get monthName(){return r.names.monthName},get names(){return In(r)},get quarter(){return Wn(r)},get quarterNr(){return Wn(r,!0)},get removeTime(){return Ur(r)},get seconds(){return r.time.seconds},get time(){return kn(r,!0)},get timeValues(){return it(r,!0)},get timeZone(){return(e||oe()).timeZone},get unixEpochTimestamp(){return Math.floor(+r/1e3)},get userLocaleInfo(){return N},get UTC(){return r.clone.relocate({locale:r.locale,timeZone:"UTC"})},get UTCOffset(){return zn(r,"UTC")},get value(){return new Date(r)},get weeknr(){return ir(r)},get weeksInYear(){return ct(r.year,31)},get year(){return r.date.year},get zoneDate(){return Pn(r,!1)},get zoneDateNr(){return r.zoneDate.date},get zoneDateTime(){return{...r.zoneDate,...r.zoneTime}},get zoneDateTimeValues(){return $e(r,!1)},get zoneDateValues(){return Zn(r,!1)},get zoneDay(){return Kn(r,!0)},get zoneDayname(){return r.zoneNames.dayName},get zoneHours(){return r.zoneTime.hours},get zoneMinutes(){return r.zoneTime.minutes},get zoneMonth(){return r.zoneDate.month},get zoneMonthname(){return r.zoneNames.monthName},get zoneNames(){return In(r,!0)},get zoneSeconds(){return r.zoneTime.seconds},get zoneTime(){return kn(r)},get zoneTimeValues(){return it(r)},get zoneYear(){return r.zoneDate.year},get zoneValues(){return r.zoneDateTime},get zoneArray(){return $e(r,!1)}};return!e&&!n?o:(o.localeInfo=e||oe(),r=new Proxy(n,Br(o)),Object.entries(Object.getOwnPropertyDescriptors(cr(r,t))).forEach(([i,c])=>Object.defineProperty(o,i,c)),Object.freeze(r))}function Br(e){return{get(t,n){return n!=="toString"&&n in t?t[n].bind(t):Reflect.get(e,n)},set(t,n,r){return n in e&&Reflect.set(e,n,r)}}}var N=st(Intl.DateTimeFormat().resolvedOptions()),Yr=Object.getOwnPropertyNames(Date.prototype).filter(e=>e.startsWith("set")).reduce((e,t)=>[...e,{native:t,syn:"change"+t.slice(3)}],[]);function lr(e="en-GB"){return e=F({locale:e}).locale,{long:[...Array(7).keys()].map(t=>new Date(Date.UTC(1970,0,4+t)).toLocaleDateString(e,{timeZone:"Etc/UTC",weekday:"long"})),short:[...Array(7).keys()].map(t=>new Date(Date.UTC(1970,0,4+t)).toLocaleDateString(e,{timeZone:"Etc/UTC",weekday:"short"}))}}function ut(e="en"){return e=F({locale:e}).locale,{long:[...Array(12).keys()].map(t=>new Date(Date.UTC(1970,t,1)).toLocaleDateString(e,{timeZone:"Etc/UTC",month:"long"})),short:[...Array(12).keys()].map(t=>new Date(Date.UTC(1970,t,1)).toLocaleDateString(e,{timeZone:"Etc/UTC",month:"short"}))}}function _r({year:e,locale:t}={}){e=M(e)?parseInt(e):new Date().getFullYear();let n={year:e,calendar:{}},r=ut().long.map(o=>o.toLowerCase());for(let o=0;o<12;o+=1){let i=C.from(e,o,1);n.calendar[r[o]]=er(i,t)}return n}function Gr({year:e,monthNr:t,locale:n="en-CA"}={}){e=M(t)&&parseInt(e)||-1,t=M(t)&&parseInt(t)||new Date().getFullYear();let r=t>=1&&t<=12;return n=F({locale:n}).locale,t=r?t-1:void 0,r?C.from(e,t,1).relocate({locale:n}).fullMonth(n):"MonthNr should be a specific number (1 = january - 12 = december)"}function st(e){let t=sr(e.locale,e.timeZone);return Object.defineProperty(e,"formatOptions",{value:t,enumerable:!1})}function sr(e,t){return[`${e&&!(Array.isArray(e)&&e.length<1)?`l:${e}`:""}`,`${t?`tz:${t}`:""}`].filter(n=>n).join(",")}function F({locale:e,timeZone:t,l:n,tz:r}={}){return t=t||r,e=e||n,!e&&!t?N:Xr({trial:function(){let o=Intl.DateTimeFormat(e,{timeZone:t}).resolvedOptions();return e&&o.locale!==e&&console.error(`\u{1F6AB} Intl changed locale (using best fit) "${e}" to "${o.locale}"`),st(o)},whenError:function(o){switch(!0){case/incorrect locale/i.test(o.message):return console.error(`\u{1F6AB} Intl locale "${e}" best fit impossible, using "${N.locale}"`),F({locale:N.locale,timeZone:t});case/invalid time zone/i.test(o.message):return console.error(`\u{1F6AB} timeZone "${t}" not valid. Using "${N.timeZone}"`),F({locale:e,timeZone:N.timeZone});default:return N||st(Intl.DateTimeFormat().resolvedOptions())}}})}function oe({locale:e,timeZone:t,l:n,tz:r}={}){return F({locale:e,timeZone:t,l:n,tz:r},!0)}function qn(e){return!Number.isNaN(+e)&&e?.constructor===Date&&!e?.toISOString?.().startsWith("1970-01-01T00:00:00")?e:new Date}function Kr(e){let t=new Date;switch(!0){case e?.constructor===String:return qn(new Date(e));case(Array.isArray(e)&&e.map(Number).length===e.length):return e.length===1?new Date(e[0],0,1):new Date(...e);case e?.constructor===Date:return qn(e);default:return t}}function Xr({trial:e,whenError:t=()=>{}}={}){if(e?.constructor===Function)try{return e()}catch(n){return t?.constructor===Function?t(n):void 0}}function eo({timeZoneDate:e,timeZoneID:t,userTimeZoneID:n}={}){let r={timeZone:F({timeZone:t}).timeZone},o={timeZone:F({timeZone:n||""}).timeZone},i=C(e,r),c=C(e,o),u=c.differenceTo(i),b=i.offsetFrom(c).offset,[h,g]=lt(b,!0),v=c.clone.add(`${h} hours, ${g} minutes`),y=u.equalDates?"No difference":`Time offset ${b}: ${o.timeZone} is ${u.clean} ${h<0?"behind":"ahead of"} ${r.timeZone}`;return{remoteTimezone:r.timeZone,userTimezone:o.timeZone,timeDifference:y,result:{[r.timeZone.replace(/\//,"_")]:C(e).toString({template:"yyyy/mm/dd hh:mmi:ss",formatOptions:"hrc:23"}),[o.timeZone.replace(/\//,"_")]:v.toString({template:"yyyy/mm/dd hh:mmi:ss",formatOptions:"hrc:23"})}}}function M(e){return!Number.isNaN(parseInt(e))}function De(e,t,n){return e?.constructor===Number?z(t,`${e} ${n}`):t}function to(e){let t={addYears(n=1){return De(n,e,"years")},addMonths(n=1){return De(n,e,"months")},addWeeks(n=1){return n=n?.constructor===Number?n*7:1,De(n,e,"days")},addDays(n=1){return De(n,e,"days")},get nextYear(){return z(e,"1 year")},get nextWeek(){return z(e,"7 days")},get previousWeek(){return z(e,"-7 days")},get previousYear(){return z(e,"-1 year")},get nextMonth(){return z(e,"1 month")},get previousMonth(){return z(e,"-1 month")},get tomorrow(){return z(e,"1 day")},get yesterday(){return z(e,"-1 day")}};for(let n of Yr)t[n.syn]=function(...r){return e[n.native](...r),e};return t}function cr(e,t){let n=to(e);for(let[r,o]of Object.entries(t||{})){let i=o.enumerable,c=o.isGetter?{get(){return o.method(e)},enumerable:i}:{value(...u){return o.method(e,...u)},enumerable:i};Object.defineProperty(n,r,c)}return n}function no(e,t){return Object.defineProperties(e,{now:{get(){return e(new Date)}},localeInformation:{get(){return F()}},localWeekdaynames:{value(n){return lr(n)}},localMonthnames:{value(n){return ut(n)}},daysInMonth:{value(n,r=!1){return n=M(n)?parseInt(n):0,n>=1&&n<=12?new Date(r?2e3:2005,n,0).getDate():`${n} should be a Number (1 (january) - 12 (december))`}},yearCalendar:{value:_r},monthCalendar:{value:Gr},from:{value(...n){return e(n)}},fromUxTS:{value(n,r){n=M(n)?parseInt(n)*1e3:void 0;let o=n?new Date(n):new Date;return C(o,r||N)}},hasDST:{value({date:n,timeZone:r}={}){return rr(n,r)}},DSTActive:{value({date:n,timeZone:r}={}){return or(n,r)}},values:{value({date:n,timeZone:r}={}){n=n||n?.value||new Date;let o=Ce(n,"yyyy-m-d-h-mi-s",F({timeZone:r}).formatOptions.concat(",hrc:23")).split("-").map(Number).concat(n.getMilliseconds());return o[1]-=1,o}},format:{value({date:n,template:r,timeZone:o,locale:i,opts:c}={}){n=n||n?.value||new Date,r=r?.constructor===String?r:"yyyy/mm/dd hh:mmi:ss dp";let u=F({timeZone:o,locale:i}).formatOptions;return u+=c?`,${c}`:"",Ce(n,r,u)}},addCustom:{value({name:n,method:r,enumerable:o=!1,isGetter:i=!1}={}){n?.constructor===String&&r?.constructor===Function&&r.length>0&&(t[n]={method:r,enumerable:o,isGetter:i})}},validateLocaleInformation:{value:F},timeAcrossZones:{value:eo},weeksInYear:{value(n){return ct(n,31)}},keys:{get(){let n=Object.fromEntries(Object.entries(t).filter(([r,o])=>o.enumerable===!0));return[...Object.keys(ar()),...Object.keys(cr()),...Object.keys(n)].sort((r,o)=>r.localeCompare(o))}}}),e}var ur={},C=no(ro,ur);function ro(e,t){if(e?.localeInfo)return e.clone;let n=e?.locale||e?.timeZone||e?.tz||e?.l;return ar({localeInfo:F(n?e:t),dateValue:new Date(n?Date.now():Kr(e)),customMethods:ur})}var oo=Object.defineProperties(mr,{escape:{value:go,enumerable:!0}});function mr(e,...t){let{flags:n,cleanedArgs:r}=ao(...t);return so(new RegExp(po(io(e,...r)),n))}function io(e,...t){return G(t)?e.raw.reduce((n,r,o)=>n.concat(t[o-1]||"").concat(r),""):e.raw.join("")}function ao(...e){let t=mt(lo(e.at(-1)));return{flags:t,cleanedArgs:G(t)?e.slice(0,-1):e}}function lo(e){return Ne(e,Array)?e.join(""):""}function so(e){let t=new Proxy(Object.defineProperties({},{re:{get(){return e},enumerable:!1},toString:{value:()=>e.toString(),enumerable:!1},valueOf:{value:()=>e,enumerable:!1},flags:{value(n){return e=fo(n,e),t},enumerable:!1},clone:{get(){return mo(t)},enumerable:!1}}),uo(e));return t}function G(e){return e?.length>0}function Ne(e,t){return e?.constructor===t}function co(e,t,n){let r=Reflect.get(n,t);return{fromInstance:Reflect.get(e,t),fromRegExpMethod:Ne(r,Function)?r.bind(e.re):e.re[t]}}function uo(e){return{get(t,n){let{fromInstance:r,fromRegExpMethod:o}=co(t,n,e);switch(!0){case!!r:return r;default:return o}}}}function mo(e){let t=e.re.source,n=G(e.re.flags)?[...e.re.flags]:[];return mr`${t} ${n}`}function mt(e,t){return t=(t??"").replace(/^-r\|/,""),e=t.concat(Ne(e,String)&&G(e)?e:""),[...new Set([...e])].join("").replace(/[^dgimsuvy]/g,"")}function fo(e,t){switch(!0){case(!Ne(e,String)||!G(e)):return t;case e==="-r":return t=new RegExp(t.source);case e.startsWith("-r|"):return t=new RegExp(t.source,mt(e));default:return t=new RegExp(t.source,mt(t.flags,e))}}function go(e){switch(!0){case(e?.constructor!==String||!G(e)):return"";case!!RegExp.escape:return RegExp.escape(e);default:return(`\\x${e.at(0)}`+e.slice(1).replace(/\p{S}|\p{P}/gu,t=>`\\${t}`)).replace(/ |\\x /g,"\\x20")}}function po(e){return e.replace(/\/\*(?:[^*]|\*+[^*\/])*\*+\/|(?<!:|\\\|')\/\/.*/gm,"").replace(/\s/g,"").trim().replace(/<!([^>]\d+)>/g,(t,n)=>String.fromCharCode(+n)??t)}var{IS:yo}=ho(),K=yo;function ho(){Symbol.proxy=Symbol.for("toa.proxy"),Symbol.is=Symbol.for("toa.is"),Symbol.type=Symbol.for("toa.type"),Symbol.isSymbol=Symbol.for("toa.isASymbol"),f();let e=v(),[t,n]=[y(),A()];return n.custom(),{IS:r,maybe:e,$Wrap:t,isNothing:g,xProxy:n};function r(a,...s){if(e({trial:d=>"isTypes"in(s?.[0]??{})})){let d=s[0];return"defaultValue"in d?w(a,d):"notTypes"in d?S(a,d):r(a,...[d.isTypes].flat())}let m=typeof a=="symbol"?Symbol.isSymbol:a;return s.length>1?h(m,...s):i(a,...s)}function o(a){return a?.[Symbol.proxy]??r(a)}function i(a,...s){let{noInput:m,noShouldbe:d,compareTo:T,inputCTOR:j,isNaN:I,isInfinity:k,shouldBeFirstElementIsNothing:P}=u(a,...s);switch(s=s.length&&s[0],!0){case P:return String(a)===String(T);case(a?.[Symbol.proxy]&&d):return a[Symbol.proxy];case I:return d?"NaN":e({trial:Z=>String(T)})===String(a);case k:return d?"Infinity":e({trial:Z=>String(T)})===String(a);case m:return d?String(a):String(T)===String(a);case j===Boolean:return s?j===s:"Boolean";default:return b(a,s,d,c(a,j))}}function c(a,s){return a===0?Number:a===""?String:a?s:{name:String(a)}}function u(a,...s){let m=s.length<1,d=!m&&s[0],T=!m&&g(s[0]),j=a==null,I=!j&&Object.getPrototypeOf(a)?.constructor,k=Number.isNaN(a)||e({trial:Z=>String(a)==="NaN"}),P=e({trial:Z=>String(a)})==="Infinity";return{noInput:j,noShouldbe:m,compareTo:d,inputCTOR:I,isNaN:k,isInfinity:P,shouldBeFirstElementIsNothing:T}}function b(a,s,m,d){switch(!0){case(!m&&s===a||a?.[Symbol.proxy]&&s===Proxy):return!0;case e({trial:T=>String(s)})==="NaN":return String(a)==="NaN";case(a?.[Symbol.toStringTag]&&r(s,String)):return String(s)===a[Symbol.toStringTag];default:return s?e({trial:T=>a instanceof s})||s===d||s===Object.getPrototypeOf(d)||`${s?.name}`===d?.name:a?.[Symbol.toStringTag]&&`[object ${a?.[Symbol.toStringTag]}]`||d?.name||String(d)}}function h(a,...s){return s.some(m=>r(a,m))}function g(a,s=!1){let m=a==null;return m=s?m||r(a,1/0)||r(a,NaN):m,m}function v(){let a=(s,m)=>s?.constructor===Function?s(m):void 0;return function({trial:s,whenError:m=()=>{}}={}){try{return a(s)}catch(d){return a(m,d)}}}function y(){return function(a){return Object.freeze({get value(){return a},get[Symbol.type](){return o(a)},get type(){return o(a)},[Symbol.is](...s){return r(a,...s)},is(...s){return r(a,...s)}})}}function w(a,{defaultValue:s,isTypes:m=[void 0],notTypes:d}={}){return m=m?.constructor!==Array?[m]:m,d=d&&d?.constructor!==Array?[d]:[],d.length<1?r(a,...m)?a:s:S(a,{isTypes:m,notTypes:d})?a:s}function S(a,{isTypes:s=[void 0],notTypes:m=[void 0]}={}){return s=s?.constructor!==Array?[s]:s,m=m?.constructor!==Array?[m]:m,r(a,...s)&&!r(a,...m)}function f(){Object.getOwnPropertyDescriptors(Object.prototype)[Symbol.is]||(Object.defineProperties(Object.prototype,{[Symbol.type]:{get(){return o(this)},enumerable:!1,configurable:!1},[Symbol.is]:{value:function(...a){return r(this,...a)},enumerable:!1,configurable:!1}}),Object.defineProperties(Object,{[Symbol.type]:{value(a){return o(a)},enumerable:!1,configurable:!1},[Symbol.is]:{value:function(a,...s){return r(a,...s)},enumerable:!1,configurable:!1}}))}function x(a){let s=String(Object.getPrototypeOf(a)?.constructor);return s.slice(s.indexOf("ion")+3,s.indexOf("(")).trim()}function O(a){let s=a.set;return a.set=(m,d,T)=>d===Symbol.proxy?m[d]=T:s(m,d,T),a}function A(){let a=Proxy;return{native(){Proxy=a},custom(){Proxy=new a(a,{construct(s,m){for(let T of m)T.set&&(T=O(T));let d=new s(...m);return d[Symbol.proxy]=`Proxy (${x(m[0])})`,d}})}}}}var dr=fr(void 0),bo=fr("");Object.defineProperties(String.prototype,{[Symbol.for("interpolate")]:{value(...e){return dr(this,...e)}},[Symbol.for("interpolate$")]:{value(...e){return bo(this,...e)}}});function fr(e){return e=K(e,String,Number)?String(e):void 0,function(h,...g){return b(h,u(g))};function t(h,g){return g&&K(e,String,Number)?String(e):`{${h}}`}function n(h,g){let v=h in g;return v&&K(g[h],String,Number)?String(g[h]):t(h,v)}function r(h){return(...g)=>{let v=g.find(y=>y.key);return n(v?v.key:"_",h)}}function o(h,g){return h.replace(/\{(?<key>[a-z_\d]+)}/gim,r(g))}function i(h){let g=[];return Object.entries(h).forEach(([v,y])=>{y.forEach((w,S)=>(g[S]??={},g[S][v]=w))}),g}function c(h){return h.length===1&&Object.values(h[0]).every(Array.isArray)}function u(h){return c(h)?i(h[0]):h}function b(h,g){let v=g?.length?g.filter(y=>K(y,Object)).map((y,w)=>o(h,{...y,index:w+1})).join(""):h;return K(e,void 0)?v:v.replace(/\{[a-z_\d].+\}/gim,String(e))}}vo();So();function So(){/stackblitz/i.test(location.href)&&console.info("\u2714 Stackblitz rewrites links to _top. The 'stackblitzhelpers' module fixed it."),document.addEventListener("click",e=>{if(e.target.href){let t=e.target;if(t.dataset.top||t.classList.contains("internalLink")||t.target==="_top")return top.location.href=t.href}return!0})}function Wo(e=!0){let t=Q('<ul id="log2screen">').first();function n(i=!1){let c=i?Q.at.start:Q.at.end;return u=>{if(u?.isJQx)return Q.li(u.data.get("header")?{class:"head"}:"",u).renderTo(t,c);u=Q.IS(u,String,Number,Symbol)?String(u):xo(u,e);let b=u.startsWith("!!");u=b?u.slice(2):u,Q.li(b?{class:"head"}:"",u).renderTo(t,c)}}let[r,o]=[n(),n(!0)];return{log:(...i)=>i.forEach(r),logTop:(...i)=>i.forEach(o)}}function xo(e,t){try{return t?`<pre>${JSON.stringify(e,null,2)}</pre>`:JSON.stringify(e)}catch{return"Some [Object object] can not be converted to JSON"}}function vo(){Q.editCssRules("body{font:normal 14px/17px system-ui,sans-serif;margin:1rem;}","li::marker{vertical-align:top;}","code{color:green;background-color:#eee;padding:2px;font-family:monospace;}","code.codeblock{display:block;padding:6px;border:1px solid #999;margin:0.5rem 0;background-color:#eee;white-space:pre-wrap;}","h3{marginTop:1.5rem;}",".thickBorder{border:5px solid green;borderWidth:5px;padding:0.5rem;display:inline-block;}","a.ExternalLink{text-decoration:none;color:rgb(0,0,238);background-color:#EEE;padding:3px;font-weight:bold;}",".cmmt{color:#888;}",".hidden{display:none;}",".attention{color:red; font-size:1.2em; font-weight:bold;}","#log2screen li{listStyle:'\\2713';paddingLeft:6px;margin:0.5rem 0 0 -1.2rem;font-family:monospace}","#log2screen li.head{list-style-type:none;font-weight:bold;margin-top:0.8rem;margin-bottom:-0.2rem;font-family:revert;}",".err{fontStyle:italic; color:red; }","a{text-decoration:none; font-weight:bold;}","a:hover{text-decoration:underline;}","a[target]:before,a.internalLink:before,a.externalLink:before{color:rgba(0,0,238,0.7);font-size:1.1rem;padding-right:2px;vertical-align:baseline;}",`a[target="_blank"]:before,a.externalLink:before{content:'\\2197';}`,`a[data-top]:before,a.internalLink:before,a[target="_top"]:before{content:'\\21BA';}`)}export{Q as $,C as $D,Wo as logFactory,oo as regexhelper,dr as splat};
|
|
13
|
+
`)}function wn(e){return e.reduce((t,n)=>{let[r,o]=[n.slice(0,n.indexOf(":")).trim(),n.slice(n.indexOf(":")+1).trim().replace(/;$|;.+(?=\/*).+\/$/,"")];return r&&o?{...t,[r]:o}:t},{})}function Tn(e){return wn($n(e))}function Ve(e,t){return e?.replace("::",":")===t?.replace("::",":")}var xe=!1,On={on:()=>xe=!0,off:()=>xe=!1},K={tagsRaw:ee,allowUnknownHtmlTags:On,isAllowed(e){if(xe)return!0;let t=d(e,String)?e.toLowerCase():e?.nodeName.toLowerCase()||"none";return t==="#text"||!!ee[t]},allowTag:e=>ee[e.toLowerCase()]=!0,prohibitTag:e=>ee[e.toLowerCase()]=!1},Dn=!0,te={data:/data-[\-\w.\p{L}]/ui,validURL:/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i,whiteSpace:/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g,notAllowedValues:/^javascript|injected|noreferrer|alert|DataURL/gi};function jn(e){if(Dn&&Object.keys(e.removed).length){let t=Object.entries(e.removed).reduce((n,[r,o])=>[...n,`${ie(r)} => ${o}`],[]).join("\\000A");L.error(`JQx: HTML creation error(s): ${t}`)}}function Nn(e){let t=e.nodeName.toLowerCase(),n=["annotation-xml","color-profile","font-face","font-face-src","font-face-uri","font-face-format","font-face-name","missing-glyph"];return/-/.test(t)&&!n.find(r=>r===t)||K.isAllowed(t)}function Ne(e){let t={rawHTML:e?.parentElement?.getHTML()??"no html",removed:{}};return d(e,HTMLElement)&&[...e.childNodes].forEach(n=>{if(n?.children?.length&&Ne(n),n?.attributes){let r=d(n,SVGElement)?be.svg:be.html;[...(n??{attributes:[]}).attributes].forEach(o=>{let i=o.name.trim().toLowerCase(),s=o.value.trim().toLowerCase().replace(te.whiteSpace,""),u=i==="href"?!te.validURL.test(s):te.notAllowedValues.test(s),p=i.startsWith("data")?!te.data.test(i):!!r[i];if(u||p){let y=_e(o.value||"none",60);y+=y.length===60?"...":"",t.removed[`${o.name}`]=`attribute/property/value not allowed, removed. Value: ${y}`,n.removeAttribute(o.name)}})}if(!(Nn(n)||n.constructor===CharacterData||n.constructor===Comment)){let r=(n?.outerHTML||n?.textContent).trim(),o=_e(r,60)??"EMPTY";o+=o.length===60?"...":"",t.removed[`<${n.nodeName?.toLowerCase()}>`]=`not allowed, not rendered. Value: ${o}`,n.remove()}}),jn(t),e}function Cn(e){let t=document.createElement("div");return t.insertAdjacentHTML(z.end,e),t.childNodes.length?Ne(t):void 0}function An(e,t,n){switch(!0){case d(e,Comment):return t.insertAdjacentHTML(n,`<!--${e.data}-->`);case d(e,Text):return t.insertAdjacentText(n,e.data||e.textContent);default:return}}function ve(e=[],t=document.body,n=z.BeforeEnd){return n=n||z.BeforeEnd,t=t?.isJQx?t.node:t||document.body,e.reduce((r,o)=>{let i=U(o)&&Ln(o,t,n);return i?[...r,i]:r},[])}function Ln(e,t=document.body,n=z.BeforeEnd){return n=n||z.BeforeEnd,t=t?.isJQx?t?.[0]:t,d(e,Comment,Text)?An(e,t,n):d(e,HTMLElement)?t.insertAdjacentElement(n,e):void 0}function J(e){if(d(e,Text,Comment))return e;let t=e?.trim(),n=t?.split(/<text>|<\/text>/i)??[];if(n?.length&&(n=n.length>1?n.filter(o=>o.length).shift():void 0),t.startsWith("<!--")&&t.endsWith("-->"))return document.createComment(e.replace(/<!--|-->$/g,""));if(n||d(t,String)&&!/^<(.+)[^>]+>/m.test(t))return document.createTextNode(n??t);let r=Cn(e);return r.childNodes.length<1?J(`<span data-jqxcreationerror="1">${lt(e,60)}</span>`):r.children[0]}function kn(e){if(e.node("#jqxPopup"))return;e.logger.log("JQx: [JQx].Popup first call. Dialog element created."),e.dialog({id:"jqxPopup"},e.div({id:"jqxPopupContent"})).render,e.editCssRules(...Kt);let t=[],[n,r]=[e("#jqxPopupContent"),e.node("#jqxPopup")],o={};return e.handle({type:"click, keydown",handlers:h,name:"genericPopupCloseHandler",capture:!0,about:"A generic handler for JQx popups"}),Object.freeze({show:i,remove:s,removeModal:S});function i(m){if(r.open)switch(!0){case u(m):return;default:return s(),setTimeout(()=>i(m),200)}o={...m};let{content:x}=o;return e.IS(x,String,HTMLElement)||x?.isJQx?p():!0}function s(){return o.modal?b(o.warnMessage):y()}function u(m){for(let[x,T]of Object.entries(o))if(T!==m[x])return!1;return!0}function p(){n.clear();let{content:m,modal:x,closeAfter:T}=o;x=e.IS(x,Boolean)?x:!1;let A=x?"":e.div({id:"closeHandleIcon"});n.append(A,e.IS(m,String)?e.div(m):m),r.showModal(),!x&&e.IS(T,Number)&&v(s,T)}function y(){if(r.close(o.returnValue),g(),e.IS(o.callback,Function))return t.push(setTimeout(()=>o.callback(o.returnValue),200));o={}}function g(){t.forEach(m=>clearTimeout(m)),t=[]}function S({callback:m,value:x}={}){o.returnValue=x,o.modal=!1,o.callback=m||o.callback,s()}function h({evt:m}){if(!(Object.keys(o).length<1||!r.open||m.type==="keydown"&&m.key!=="Escape")&&(m.key==="Escape"&&o.modal&&m.preventDefault(),m.target.closest("#closeHandleIcon")||!m.target.closest("#jqxPopupContent")))return o.activeTimer&&clearTimeout(o.activeTimer),s()}function v(m,x){e.IS(m,Function)&&e.IS(x,Number)&&x>0&&(g(),t.push(setTimeout(m,x*1e3)))}function b(m){if(!e.IS(m,String,HTMLElement,Proxy))return;let x=n.find$(".warn");switch(!0){case x.is.empty:x=e.div({class:"warn"},m);default:n.append(x.addClass("active")),v(()=>n.find$(".warn").removeClass("active"),2)}}}function En(e){let t={},n="anonymous_";function r(g){if(g){let{handler:S,capture:h,type:v}=g;document.addEventListener(v,S,{capture:h})}}function o(g){if(g){let{type:S,handler:h,capture:v}=g;document.removeEventListener(S,h,{capture:v})}}function i(g,S,h,v){return function(b){if(!C(S))return g({evt:b});let m=b.target.closest(S);if(m){let x=e(m);g({self:x,me:x,evt:b}),h&&p(b.type,v)}return!0}}function s(g){return t[g]=t[g]||{},t[g]}function u(g,S){return Object.entries(s(g)).find(([h])=>h===S)}function p(g,S){let h=u(g,S);h&&(o(h[1]),delete t[g][S],delete $e[S],L.warn(`Removed listener [${S}] for event type [${g}].`))}function y(g){let{type:S,handler:h,name:v,capture:b,once:m,selector:x,node:T,about:A}=g;t[S]=t[S]||{};let a=Fn(v||h.name),l=h;if(T instanceof HTMLElement){let c=T.dataset.hid||a;T.dataset.hid=c,x=`[data-hid=${c}]`}switch(!0){case!t[S][a]:return L.log(`JQx: created listener for event type ${S}, with handler name ${a}`),t[S][a]={name:a,handler:i(h,x,m,a),capture:Hn(S,b),once:!!m,type:S,initialHandler:l,selector:!!x&&x||!1,about:!!A&&A||!1,unListen(){p(S,a)}},t[S][a];default:return console.warn(`The listener [${a}] for [${S}] exists, it is not re-assigned.`)}}return{remove(...g){return p(...g)},listen:function(g){let{type:S,handler:h}=g;if(!C(S)||!d(h,Function))return;let v=y(g);if(v)return r(v),{type:S,name:v.name,unListen(){p(S,v.name)}}},get ListenerStore(){return Object.freeze({...t})}}}var L=Rn(),Mn=["load","unload","scroll","focus","blur","DOMNodeRemovedFromDocument","DOMNodeInsertedIntoDocument","loadstart","progress","error","abort","load","loadend","pointerenter","pointerleave","readystatechange"],z=Object.freeze(new Proxy({start:"afterbegin",afterbegin:"afterbegin",end:"beforeend",beforeend:"beforeend",before:"beforebegin",beforebegin:"beforebegin",after:"afterend",afterend:"afterend"},{get(e,t){return e[String(t).toLowerCase()]??e[t]}})),In=[...Array(26)].map((e,t)=>String.fromCharCode(t+65)).concat([...Array(26)].map((e,t)=>String.fromCharCode(t+97))).concat([...Array(10)].map((e,t)=>`${t}`)),Zn=Object.freeze({get(e,t){return e[Ce(t)]||e[t]},enumerable:!1,configurable:!1}),$e={};function Pn(){let e=setTimeout(()=>{});for(;e>=0;)clearTimeout(e--)}function Fn(e){return C(e)&&!/^handler|handlers$/gi.test(e.trim())?e.trim():it()}function zn(e){let t=!!e.node&&!d(e,Text,Comment);switch(!0){case t:let n=e.node.dataset?Object.keys(e.node.dataset).map(o=>`[data-${o}]`):[],r=[e.attr("id")&&`#${e?.attr("id")}`||void 0,e.attr("class")&&e?.attr("class").split(" ").map(o=>`.${o}`).join(", ")||void 0,n.length>0&&n.join(", ")||void 0].filter(o=>!!o).join(", ")||[];return r.length?`(${r})`:"";default:return""}}function it(e){let t=`anonymous_${Math.random().toString(36).slice(2)}`;return $e[t]?it():($e[t]=t,t)}function Hn(e,t){return!!Mn.find(n=>n===e)||!!t}function at(e){return e.startsWith("data")||be.html.find(t=>e.toLowerCase()===t)}function Ye(e){return e&&(e.textContent="")}function we(e,t=0,n=!0){return e=e?.parentElement,t+=e?e[n?"scrollTop":"scrollLeft"]:0,e?we(e,t,n):t}function C(e,t=1){return t=d(t,Number)&&t||1,d(e,String)&&e.length>=t}function _e(e,t=120){return lt(e,t).replace(/</g,"<")}function lt(e,t=120){return`${e}`.trim().slice(0,t).replace(/>\s+</g,"><").replace(/</g,"<").replace(/\s{2,}/g," ").replace(/\n/g,"\\n")+(e.length>t?" …":"").trim()}function ie(e){switch(!0){case d(e,String):let t=document.createElement("div");return t.append(e),t.innerHTML;default:return e}}function pe(e){return d(e,String)&&Object.assign(document.createElement("textarea"),{innerHTML:e}).textContent||e}function Rn(){let[e,t]=[!1,!0],n=[],r={get on(){return e=!0,r},get off(){return e=!1,r},get disable(){return t=!0,r},get enable(){return t=!1,r},get backLog(){return n}};function o(){t=!0}function i(){t=!1}function s(...y){return n.unshift(...y.map(g=>`${ye()} \u2A3B ${pe(g)}`)),console.error(n.slice(0,y.length).join(`
|
|
14
|
+
`)),r}function u(...y){return n.unshift(...y.map(g=>`${ye()} \u26A0 ${pe(g)}`)),console.warn(n.slice(0,y.length).join(`
|
|
15
|
+
`)),r}function p(...y){let g=y.map(S=>`${ye()} \u2714 ${pe(S)}`);switch(!t&&n.unshift(...g),e){case!0:console.log(g.join(`
|
|
16
|
+
`));default:return r}}return Object.defineProperties(r,{log:{value:p,enumerable:!1},error:{value:s,enumerable:!1},warn:{value:u,enumerable:!1}}),Object.freeze(r)}function ye(){return(e=>`[${ne(e.getHours())}:${ne(e.getMinutes())}:${ne(e.getSeconds())}.${ne(e.getMilliseconds(),3)}]`)(new Date)}function Jn(e,t){if(e)for(let[n,r]of Object.entries(t)){if(n=H(n),n.startsWith("data"))return st(e,r);d(r,String)&&at(n)&&e.setAttribute(n,r.split(/[, ]/)?.join(" "))}}function st(e,t){if(e&&d(t,Object))for(let[n,r]of Object.entries(t))e.setAttribute(`data-${H(n)}`,r)}function ut(e){return e?d(e,Proxy)?[e.EL]:d(e,NodeList)?[...e]:U(e)?[e]:ke(e)?e:e.isJQx?e.collection:void 0:[]}function Ge(e,t){return e.andThen(t)}function Ke(e,t){return e.andThen(t,!0)}function U(e){return d(e,Text,HTMLElement,Comment)}function he(e,t){if(d(t,Object))for(let[n,r]of Object.entries(t)){let o;/!important/i.test(r)&&(r=r.slice(0,r.indexOf("!")).trim(),o="important"),e.style.setProperty(H(n),r,o)}}function Q(e){let t=e.cloneNode(!0);return t.removeAttribute&&t.removeAttribute("id"),e.isConnected?e.remove():e=null,t}function Qn(e){if(!e)return;let t=e.style,n=getComputedStyle(e),r=[t.visibility,n.visibility].includes("hidden"),o=[t.display,n.display].includes("none"),i=e.hidden,s=e.offsetTop<0||e.offsetLeft+e.offsetWidth<0||e.offsetLeft>document.body.offsetWidth,u=+n.opacity==0||+(t.opacity||1)==0;return!(i||s||u||o||r)}function Un(e){return e?.isConnected?!![...document.querySelectorAll(":is(:read-write)")].find(t=>t===e):!1}function Wn(e){return e?.filter(t=>t).reduce((t,n)=>t.concat(ft(n)?`<!--${n.data}-->`:Ae(n)?n.textContent:n.outerHTML),"")}function ne(e,t=2){return`${e}`.padStart(t,"0")}function qn(e,t=0){return[e,t]=[Math.floor(e),Math.ceil(t)],Math.floor([...crypto.getRandomValues(new Uint32Array(1))].shift()/2**32*(e-t+1)+t)}function ct(){return`_${_n(In).slice(0,8).join("")}`}function Bn(e){return e=d(e,String)&&/,/.test(e)?e.split(",").map(t=>t.trim().toLowerCase()).filter(t=>t.length>0):e,d(e,Array)?e:d(e,String)&&e?.trim().toLowerCase()||""}function Vn(e){return e?.isConnected?!![...document.querySelectorAll(":is(:modal)")].find(t=>t===e):!1}function Yn(e,t){switch(e=String(e).trim(),!0){case/^(0|false|f)$/i.test(e):return!1;case/^(1|true|t)$/i.test(e):return!0;default:return t}}function _n(e){let t=e.length;for(;t--;){let n=qn(t);[e[t],e[n]]=[e[n],e[t]]}return e}function Ce(e){return d(e,String)?e.toLowerCase().split("-").map((t,n)=>n&&`${Gn(t)}`||t).join(""):e}function H(e){return e.replace(/[A-Z]/g,t=>`-${t.toLowerCase()}`).replace(/^-|-$/,"")}function Gn([e,...t]){return`${e.toUpperCase()}${t.join("")}`}function Ae(e){return d(e,Comment,Text)}function ft(e){d(e,Comment)}function Kn(e){return d(e,Text)}function Le(e){return d(e,String)&&/^<|>$/.test(`${e}`.trim())}function ke(e){return d(e,Array)&&!e?.find(t=>!U(t))}function mt(e){return d(e,Array)&&!e?.find(t=>!Le(t))}function O(e,t){let n=e.collection.filter(r=>!Ae(r));for(let r=0;r<n.length;r+=1)t(n[r],r);return e}function Xn(e){return e.node?d(e.node,Comment)?`<!--${e.node.textContent}-->`:e.HTML.get(1).split(">")[0]+">...":""}function dt(e,t,n){let r=t!==document.body&&d(e,String)&&e.toLowerCase()!=="body"?t:document;try{n.collection=[...r.querySelectorAll(e)]}catch{L.warn(`JQx: Invalid CSS querySelector. [${d(e,String)?e:"Not a string!"}]`)}}function er(){return{isCommentOrTextNode:Ae,isNode:U,isComment:ft,isText:Kn,isHtmlString:Le,isArrayOfHtmlElements:ke,isArrayOfHtmlStrings:mt,ElemArray2HtmlString:Wn,input2Collection:ut,setCollectionFromCssSelector:dt,cssRuleEdit:ot({createWithId:"JQxStylesheet"})}}function tr(){let e=Object.freeze({notInDOM:"n/a",writable:"n/a",modal:"n/a",empty:!0,open:"n/a",visible:"n/a"});return t=>{let n=t.node;return d(n,Node)?Object.freeze({get writable(){return Un(n)},get modal(){return Vn(n)},get inDOM(){return n.isConnected},get open(){return n.open??!1},get visible(){return Qn(n)},get disabled(){return n.hasAttribute("readonly")||n.hasAttribute("disabled")},get empty(){return t.collection.length<1},get virtual(){return t.isVirtual}}):e}}function nr(e,t,n,r){n&&d(t,String)&&(t={[t]:n==="-"?"":n});let o;t.className&&(o=t.className,delete t.className),o=[...e.classList].find(i=>i.startsWith("JQxClass-")||o&&i===o)||o||`JQxClass-${ct().slice(1)}`,r.editCssRule(`.${o}`,t),e.classList.add(o)}var rr=tr();function or(e){return{factoryExtensions:ir(e),instanceExtensions:ar(e)}}function ir(e){return{data(t){return{get all(){return new Proxy(t[0]?.dataset??{},Zn)},set(n={}){if(!t.is.empty&&d(n,Object))for(let[r,o]of Object.entries(n))t.setData({[r]:o});return t},get(n,r){return t.data.all[n]??r},add(n={}){if(!t.is.empty&&d(n,Object))for(let[r,o]of Object.entries(n))t.setData({[r]:o});return t},remove(n){return t[0]?.removeAttribute(`data-${H(n)}`),t}}},dimensions(t){if(t.is.empty)return L.error("[JQx instance].dimensions called on empty instance"),{error:"[JQx instance].dimensions: NO ELEMENTS"};let{node:n}=t,r=n.getBoundingClientRect().toJSON();return r.scrollTopDistance=we(n,0),r.scrollLeftDistance=we(n,0,!1),r},node(t){return t[0]},HTML(t){return{get(n,r){if(t.is.empty)return"NO ELEMENTS IN COLLECTION";let o=n?t.outerHtml:t.html();return r?ie(o):o},set(n,r=!1,o=!1){n=n.isJQx?n.HTML.get(1):n;let i=d(n,String);return n=i&&o?ie(n):n,i&&(n||"").trim().length&&t.html(n,r),t},replace(n,r=!1){return t.HTML.set(n,!1,r)},append(n,r=!1){return n=d(n,HTMLElement)?e(n).HTML.get(1):n.isJQx?n.HTML.get(1):n,t.HTML.set(n,!0,r)},insert(n,r=!1){return n=d(n,HTMLElement)?e(n).HTML.get(1):n.isJQx?n.HTML.get(1):n,t.HTML.set(n+t.HTML.get(),!1,r)}}},is(t){return rr(t)},length(t){return t.collection.length},outerHtml(t){return(t.first()||{outerHTML:void 0}).outerHTML},parent(t){let n=e(t[0]?.parentNode);return n.is.empty?t:n},render(t){switch(!0){case!t.is.empty:return t.toDOM();default:return e.logger.warn("[JQx.render]: empty collection"),t}},Style(t){return{get computed(){return t.is.empty?{}:getComputedStyle(t[0])},inline(n){return t.style(n)},inSheet(n){return t.css(n)},valueOf(n){return t.is.empty?void 0:getComputedStyle(t[0])[H(n)]},nwRule(n){return t.Style.byRule({rules:n})},byRule({classes2Apply:n=[],rules:r=[]}={}){let o=d(r,String)&&!n.length?r.split("{")[0].trim():"";if(r=r&&d(r,String)?[r]:r,n=n&&d(n,String)?[n]:n,(r?.length||n?.length)&&(r?.length&&e.editCssRules(...r),n))for(let i of n)t.addClass(i);return o?.startsWith(".")&&t.addClass(o.slice(1)),o?.startsWith("#")&&!t.attr("id")&&t.prop({id:o.slice(1)}),t}}}}}function ar(e){return{addClass(t,...n){return O(t,r=>r&&n.forEach(o=>r.classList.add(o)))},after:Ge,afterMe:Ge,andThen(t,n,r=!1){if(!n||!d(n,String,Node,Proxy))return L.log("[JQx instance].[before(Me) | after(Me) | andThen]: invalid/-sufficient input."),t;n=n?.isJQx?n:d(n,Node)?e.virtual(n):e.virtual(J(n));let[o,i,s]=r?[0,"before",n.collection.concat(t.collection)]:[t.collection.length-1,"after",t.collection.concat(n.collection)];return t[o][i](...n.collection),t.collection=s,t},append(t,...n){if(t.is.empty||n.length<1)return t;let r=t.length===1;for(let o of n){if(!o.isJQx&&C(o)){let i=o.trim(),s=/^<(.+)[^>]+>$/m.test(i)?J(o):e.text(o);O(t,u=>u.append(r?s:Q(s)))}U(o)&&O(t,i=>i.append(r?o:Q(o))),o.isJQx&&!o.is.empty&&O(t,i=>o.collection.forEach(s=>i.append(r?s:Q(s))))}return t},appendTo(t,n){switch(!0){case(!n.isJQx&&!d(n,HTMLElement)):return $.warn("[JQx instance].appendTo: invalid input"),t;default:return(n.isJQx?n:e(n)).append(t),t}},attr(t,n,r){if(!t.node||d(t.node,Text,Comment))return t;if(!r&&C(n))return n=H(n),n==="class"?[...t.node.classList].join(" "):t.node.getAttribute(n);if(C(n)&&r)switch(n=H(n),!0){case n.startsWith("data-"):n={data:{[n.replace("data-","")]:r}};break;default:n={[n]:r}}return d(n,Object)&&!t.is.empty&&Jn(t.node,n),t},before:Ke,beforeMe:Ke,clear(t){return O(t,Ye)},closest(t,n){let r=C(n)?t.node?.closest(n):void 0;return r?e(r):t},computedStyle(t,n){let{node:r}=t;return r&&getComputedStyle(r)[n]},css(t,n,r){return O(t,o=>nr(o,n,r,e))},duplicate(t,n=!1,r=document.body){switch(!0){case t.is.empty:return L.error("Duplicating an empty JQx instance is not possible"),t;default:let o=t.collection[0].cloneNode(!0);return o.childNodes.forEach(i=>{i.removeAttribute&&i?.removeAttribute("id")}),n?e(o).toDOM(r):e.virtual(o)}},each(t,n){return O(t,n)},empty(t){return O(t,Ye)},find(t,n){return t.collection.length>0?[...t.first()?.querySelectorAll(n)]:[]},find$(t,n){return t.collection.length>0?e(n,t):t},first(t,n=!1){return t.collection.length>0?n?t.single():t.collection[0]:void 0},first$(t,n){return t.single(n)},getData(t,n,r){return t.node?.dataset?.[n]||r},hasClass(t,...n){return t.is.empty||!t.node.classList.length?!1:n.find(r=>t.node.classList.contains(r))&&!0||!1},hide(t){return O(t,n=>he(n,{display:"none !important"}))},html(t,n,r){switch(!0){case(t.is.empty&&!C(n)):return"";case!C(n):return t.node?.getHTML()??"";default:let o=J(`<div>${n.isJQx?n.HTML.get(!0):n}</div>`);return O(t,i=>(i.textContent=r?i.textContent:"",i.insertAdjacentHTML(e.at.end,o.getHTML())))}},htmlFor(t,n,r="",o=!1){if(t.is.empty||!C(n)||!C(r))return t;let i=t.find$(n);if(i.length<1)return t;let s=J(`<span>${r}</span>`);return i.each(u=>{o||(u.textContent=""),u.insertAdjacentHTML(e.at.end,s?.getHTML())}),t},isEmpty(t){return!t.node},nth$(t,n){return t.single(n)},on(t,n,...r){switch(!0){case(t.is.empty||!d(n,String,Array)||!C(n)||r.length<1):return t;default:return e.handle({type:n,node:t.node,handler:r}),t}},once(t,n,...r){switch(!0){case(t.is.empty||!d(n,String,Array)||!C(n)||r.length<1):return t;default:return e.handle({type:n,once:!0,node:t.node,handler:r}),t}},prepend(t,...n){if(t.is.empty||!n)return;let r=t.length===1;for(let o of n){if(C(o)){o=o.trim();let i=/^<(.+)[^>]+>$/m.test(o)?J(o):e.text(o);i=r?i:Q(i),O(t,s=>s.prepend(i.cloneNode(!0)))}U(o)&&O(t,i=>i.prepend(r?o:Q(o))),o.isJQx&&!o.is.empty&&(o.collection.length>1&&o.collection.reverse(),O(t,i=>O(o,s=>i.prepend(r?s:Q(s)))),o.collection.reverse())}return t},prependTo(t,n){return n.isJQx||(n=e.virtual(n)),n.prepend(t),t},prop(t,n,r){if(d(n,String)&&!r)return n.startsWith("data")?t[0]?.dataset[n.slice(n.indexOf("-")+1)]:t[0]?.[n];let o=d(n,Object)?n:{[n]:r};for(let[i,s]of Object.entries(o)){if(i=i.trim(),s&&!at(i)||!s)return!1;if(i.toLowerCase()==="id")return t[0].id=s;O(t,u=>{if(i.startsWith("data"))return u.dataset[i.slice(i.indexOf("-")+1)]=s;u[i]=s})}return t},remove(t,n){let r=i=>i.remove(),o=()=>t.collection=t.collection.filter(i=>document.documentElement.contains(i));if(n){let i=t.find$(n);return i.is.empty||(O(i,r),o()),t}return O(t,r),o(),t},rmAttr(t,...n){for(let r of n)t.node.removeAttribute(r);return t},removeClass(t,...n){return O(t,r=>{if(r)for(let o of n)r.classList.remove(o)})},renderTo(t,n,r){return n=d(n,HTMLElement)||n.isJQx?n:document.body,r=d(r,String)&&e.at[r]?r:e.at.end,t.first$().toDOM(n,r),t},replace(t,n,r){let o=t.node;return!n||!d(r,HTMLElement)&&!r?.isJQx?(e.logger.error("JQx replace: invalid replacement value"),t):((r.isJQx||d(r,NodeList))&&(r=r[0]),o&&n&&(n=d(n,String)?o.querySelectorAll(n):n.isJQx?n.collection:n,d(n,HTMLElement,NodeList,Array)&&d(r,HTMLElement)&&(d(n,HTMLElement)?[n]:[...n]).forEach(i=>i.replaceWith(r.cloneNode(!0)))),t)},replaceClass(t,n,...r){return O(t,o=>{o.classList.remove(n);for(let i of r)o.classList.add(i)})},replaceMe(t,n){return t.replaceWith(n)},replaceWith(t,n){return n=d(n,Element)?n:n.isJQx?n[0]:void 0,n&&(t[0].replaceWith(n),t=e.virtual(n)),t},setData(t,n){return O(t,r=>st(r,n))},show(t){return O(t,n=>he(n,{display:"revert-layer !important"}))},single(t,n){let r=t.collection.length>0;switch(n=n??0,!0){case(r&&d(n,String)):return t.find$(n);case(r&&d(n,Number)):return e(t.collection[n]);case r:return t.collection[0];default:return t}},style(t,n,r){return O(t,o=>{r&&d(n,String)&&(n={[n]:r||"none"}),he(o,n)})},text(t,n,r=!1){switch(!0){case t.isEmpty():return t;case!d(n,String):return t.node.textContent;default:return O(t,o=>o.textContent=r?o.textContent+n:n)}},toDOM(t,n=document.body,r=z.BeforeEnd){return t.isVirtual=!1,ve(t.collection,n,r),t},toggleClass(t,n){return O(t,r=>r.classList.toggle(n))},toNodeList(t){return[...t.collection].map(n=>document.importNode(n,!0))},trigger(t,n,r,o){if(r=/Event]$/.test(d(r))?r:Event,o=d(o,Object)?{...o,bubbles:o.bubbles??!0}:{bubbles:!0},!t.is.empty){let i=new r(n,o);t.each(s=>s.dispatchEvent(i))}return t},val(t,n){switch(!0){case(t.is.empty||!d(t.node,HTMLInputElement,HTMLSelectElement,HTMLTextAreaElement)):return t;case!d(n,String):return t.node.value;default:return t.node.value=d(n,String)?n:"",t}}}}var Te,ae,{isComment:Co,isText:Ao,isHtmlString:Lo,isArrayOfHtmlElements:ko,isArrayOfHtmlStrings:Eo,ElemArray2HtmlString:Mo,cssRuleEdit:Oe,addFn:lr}=sr();function sr(){return{...er(),addFn:ur}}function ur(e,t){return e=e?.trim(),!C(e)||!d(t,Function)?L.error("JQx.fn: method invalid parameter(s)"):ae[e]=(n,...r)=>t(n,...r)}function cr(e){return function(t,n,r){if(t=t?.trim(),!C(t)||!d(n,Function))return e.error("JQx.staticFn: invalid parameter(s)");let o=r?{get(){return n()}}:{value(...i){return n(...i)}};try{Object.defineProperty(e,t,o)}catch{return e.warn(`JQx.staticFn: extension [${t}] already exists`)}return L.log(`JQx: added static extension function [${t}]`)}}function re(e){return new Proxy(e,Object.freeze({get:(t,n)=>fr(t,n,e)}))}function Xe(e,t){return(...n)=>d(e,Function)&&e(re(t),...n)}function fr(e,t,n){switch(!0){case d(t,Symbol):return e;case d(+t,Number):return e.collection?.[t]||void 0;case t in Te:return Xe(Te[t],n)();case t in ae:return Xe(ae[t],n);default:return e[t]}}function mr(e){let t=hr(e);for(let[n,r]of Object.entries(Object.getOwnPropertyDescriptors(t)))Object.defineProperty(e,n,r);return e}function dr(e){return{allow(t){let n=/-/.test(t),r=n&&t;t=n?Ce(t):t.toLowerCase(),K.allowTag(t),Object.defineProperties(e,De(t,!0,e,r))},prohibit(t){t=t.toLowerCase(),K.prohibitTag(t),Object.defineProperties(e,De(t,!1,e))}}}function et(...e){if(e.length===1){let t=String(e.shift().trim());e=t.startsWith("!")?[t.slice(1,-1)]:t.split(",").map(n=>n.trim())}for(let t of e.map(n=>n.startsWith("!")?n.slice(1,-1):n))Oe(t,{removeRule:1})}function gr(e){return function(t,n,r){n=n?.isJQx?n?.[0]:n,r=r&&Object.values(z).find(i=>r===i);let o=e(t,document.createElement("br"));if(n&&!d(n,HTMLBRElement))for(let i of o.collection)r?n.insertAdjacentElement(r,i):n.append(i);return o}}function pr(...e){let t={};for(let n of e){let r=Object.getOwnPropertyDescriptors(n);for(let[o,i]of Object.entries(r))!(o in t)&&Object.defineProperty(t,o,{...i,enumerable:!1})}return t}function yr(e,t,n,r){return e=H(r||e.toLowerCase()),{get(){return(...o)=>{let i=t&&n.virtual(Ne(nn[e](...o)))||void 0,s=d(i?.node,Comment,Text,void 0)?"":zn(i);return L.log(t?`JQx: created (virtual) instance from [JQx].${e} ${s}`:`JQx: ${e.toUpperCase()} is prohibited. Use [JQx].allowTag if necessary.`),i}},enumerable:!1,configurable:!0}}function De(e,t,n,r){e=e.toLowerCase();let o=yr(e,t,n,r);return r?{[r]:o,[Ce(r)]:o}:{[e]:o,[e.toUpperCase()]:o}}function hr(e){return pr(Object.entries(K.tagsRaw).reduce(br(e),{}),Tr(e))}function br(e){return function(t,[n,r]){return Object.defineProperties(t,De(n,r,e)),t}}function Sr(e){return function(t,n,...r){d(n,Function)&&(r.push(n),n=void 0),e({type:t,selector:n,handlers:r})}}function xr(e){return function(t){let{type:n,types:r,origin:o,selector:i,handler:s,handlers:u,node:p,name:y,capture:g,once:S,about:h}=t;s=u||s,n=r||n,i=o||i;let v=Bn(n),b=y;s=d(s,Function)?[s]:s;let m={type:v,selector:i||o,capture:g,name:b,once:S,node:p,about:h};switch(!0){case(d(v,Array)&&v.length>0):for(let x of v)m.type=x,tt(s,m,e);break;default:return tt(s,m,e)}}}function tt(e,t,n){for(let r of e)n.listen({...t,handler:r})}function vr(e){return function(t,n){return n=C(n)&&n,t=C(t)&&t,n&&t&&e.listenerStore[t][n]}}function $r(e){return e.activePopup||Object.defineProperty(e,"activePopup",{value:kn(e),enumerable:!1}),e.activePopup}function wr(e){let t=(u,p)=>Oe(u,p),n=function(u){return ot({createWithId:u||`jqx${ct()}`})},r=function(...u){for(let p of u)Oe(p)},o=dr(e),i=En(e),s=xr(i);return{editCssRule:t,createStyle:n,editCssRules:r,allowProhibit:o,handle:s,capturedHandling:s,log:(...u)=>L.on.log(...u).off,warn:(...u)=>L.on.warn(...u).off,error:(...u)=>L.on.error(...u).off,handlerWrapper:i}}function Tr(e){let{factoryExtensions:t,instanceExtensions:n}=or(e);Te=t,ae=n;let{editCssRule:r,createStyle:o,editCssRules:i,allowProhibit:s,handle:u,capturedHandling:p,log:y,warn:g,error:S,handlerWrapper:h}=wr(e),v=vr(e),b=cr(e);return{log:y,warn:g,error:S,editCssRules:i,createStyle:o,editStylesheet:o,editCssRule:r,escHtml:ie,logger:L,text(m,x=!1){return x?e.comment(m):document.createTextNode(m)},node(m,x=document){return x.querySelector(m,x)},nodes(m,x=document){return[...x.querySelectorAll(m,x)]},clearAllTimers:Pn,get staticFn(){return function(m,x,T){return b(m,x,T)}},get toBool(){return Yn},get getNamedListener(){return v},get virtual(){return gr(e)},get allowTag(){return s.allow},get prohibitTag(){return s.prohibit},get removeCssRule(){return et},get removeCssRules(){return et},get delegate(){return Sr(p)},get delegateCaptured(){return p},get handle(){return p},get listen(){return h.listen},get at(){return z},get setStyle(){return r},get fn(){return lr},get lenient(){return K.allowUnknownHtmlTags},get IS(){return d},get Popup(){return $r(e)},get listenerStore(){return h.ListenerStore}}}var Or=mr(Dr());function Dr(){return function(e,t,n=z.BeforeEnd){if(e?.isJQx)return e;let r=d(t,HTMLBRElement);t=(!r&&t&&t.isJQx?t[0]:t)||document.body,n=n&&Object.values(z).find(p=>n===p)?n:void 0;let o=Le(e),i=!o&&mt(e)||o,s={collection:ut(e)??[],isVirtual:r,isJQx:!0},u=ke(s.collection);if(s.collection.length&&u)return r||s.collection.forEach(p=>{t.contains(p)||ve([p],t,n)}),re(s);if(i){if([e].flat().forEach(p=>s.collection.push(J(p))),s.collection.length>0){let p=s.collection.filter(S=>S?.dataset?.jqxcreationerror);s.collection=s.collection.filter(S=>!S?.dataset?.jqxcreationerror);let y=s.collection.map(S=>`${String(S.constructor).split(/function|\(/)[1].trim()}`).length>1;s=re(s);let g=s.collection.length>0?Xn(s):"sanitized: no elements remaining";L.log(`JQx: created ${s.isVirtual?"(virtual)":""} instance from ${y?"array of ":""}HTML string${y?"s":""} ${g}`),s.isVirtual||ve(s.collection,t,n)}return s}return dt(e,t,s),re(s)}}var R=Or;var[W,q,Ie,Ze]=["2-digit","numeric","long","short"],le={fixed:{MM:{month:Ie},M:{month:Ze},m:{month:q},mm:{month:W},yyyy:{year:q},yy:{year:W},WD:{weekday:Ie},wd:{weekday:Ze},d:{day:q},dd:{day:W},h:{hour:q},hh:{hour:W},mi:{minute:q},mmi:{minute:W},s:{second:q},ss:{second:W},ms:{fractionalSecondDigits:3},tz:{timeZoneName:"shortOffset"},dl:{locale:"default"},h12:{hour12:!1},yn:{yearName:""},ry:{relatedYear:!0},msp:{fractionalSecond:!0}},dynamic:{tzn:e=>({timeZoneName:e.slice(4)}),hrc:e=>({hourCycle:`h${e.slice(4)}`}),ds:e=>({dateStyle:e.slice(3)}),ts:e=>({timeStyle:e.slice(3)}),tz:e=>({timeZone:e.slice(3)}),e:e=>({era:e.slice(2)}),l:e=>({locale:e.slice(2)})}},V={...le,retrieveDynamic(e){let t=e?.slice(0,e?.indexOf(":"));return le.dynamic[t]&&le.dynamic[t](e)},get re(){return new RegExp(`\\b(${Object.keys(le.fixed).join("|")})\\b`,"g")}},me=jr;function jr(e,t,n="l:default"){return/ds:|ts:/.test(n)?Nr(e,gt(void 0),n):Ar(e,gt(t||void 0),n)}function gt(e="dtf"){let t=` ${e.replace(/[{}]/g,"").trim()} `,n=e.match(/(?<=\{)(.+?)(?=})/g)||[];return{set formatStr(r){t=r},get formatStr(){return t},get units(){return t.match(V.re)||[]},finalize(r="",o="",i="",s=""){return t.replace(/~([\d+]?)/g,"$1").replace(/dtf/,r).replace(/era/,i).replace(/dp\b|~dp\b/,o).replace(/yn\b/,s).replace(/\[(\d+?)]/g,(u,p)=>n[p].trim()).trim()}}}function Ct(...e){return e?.reduce((t,n)=>({...t,...V.retrieveDynamic(n)||V.fixed[n]}),V.fixed.dl)}function Nr(e,t,n){let r=Ct(...At(n).split(",")),o=Intl.DateTimeFormat(r.locale,r).format(e);return t.finalize(o)}function Cr(e,t){return e==="numeric"&&t.startsWith("0")?t.slice(1):t}function Ar(e,t,n){let r=Ct(...t.units.concat(At(n).split(",")).flat()),o={...V.fixed},i=Intl.DateTimeFormat(r.locale,r).formatToParts(e).reduce((s,u)=>u.type==="literal"&&/[ ,/-]/.test(u.value)?s:{...s,[u.type]:Cr(r[u.type],u.value)},{});return o.ms=r.fractionalSecondDigits?o.msp:o.ms,o.yyyy=i.relatedYear?o.ry:o.yyyy,t.formatStr=t.formatStr.replace(V.re,s=>/^(M|MM)$/.test(s)?Lr(e,r.locale,r.timeZone,/^M$/.test(s)):i[Object.keys(o[s]).shift()]||s),t.finalize(void 0,i.dayPeriod,i.era,i.yearName)}function Lr(e,t,n,r){return e.toLocaleString(t,{timeZone:n,month:r?Ze:Ie})}function At(e){return e.replace(/\s+/g,"")}var kr=Er;function Er(){let e=(r,o)=>{let i=isNaN(new Date(r)),s=isNaN(new Date(o));if(s){let[u,p,y]=Array(3).fill("end date not valid");return{error:!0,message:u,full:p,clean:y}}if(i){let[u,p,y]=Array(3).fill("start date not valid");return{error:!0,message:u,full:p,clean:y}}if(i&&!s){let[u,p,y]=Array(3).fill("start- and/or end date are not valid");return{error:!0,message:u,full:p,clean:y}}return{error:!1}},t=n();return function({start:r,end:o,diffs:i={}}={}){let s=e(r,o),u=o>r?"+":"-";if(s.error)return s;let p=Math.abs(r-o),y=new Date(p),g=y.getUTCFullYear()-1970,S=y.getUTCMonth(),h=y.getUTCDate()-1,v=h%7,b=Math.floor(h/7),m=y.getUTCHours(),x=y.getUTCMinutes(),T=y.getUTCSeconds(),A=y.getUTCMilliseconds(),a=Math.floor(p/864e5);i={...i,fromUTC:r,toUTC:o,sign:"",years:g,months:S,days:h,hours:m,minutes:x,seconds:T,milliseconds:A,diffInDays:a},i.full=t({values:i,full:!0}),i.clean=t({values:i}),i.equalDates=i.clean==="Dates are equal";let l=m+x+T>0?"T":"";return i.clean!=="Dates are equal"&&(i.sign=u,i.jsPeriod=`${u}P${g>0?`${g}Y`:""}${S>0?`${S}M`:""}${b>0?`${b}W`:""}${v>0?`${v}D`:""}${l}${m>0?`${m}H`:""}${x>0?`${x}M`:""}${T>0?`${T}S`:""}`,i.ISOPeriod=`P${g>0?`${g}Y`:""}${S>0?`${S}M`:""}${h>0?`${h}D`:""}${l}${m>0?`${m}H`:""}${x>0?`${x}M`:""}${T>0?`${T}S`:""}`),i};function n(){let r=(...i)=>s=>i.reduce((u,p)=>p(u),s),o=(i,s)=>i===1?s.slice(0,-1):s;return r(({values:i,full:s})=>[Object.entries(i).filter(([u])=>/^(years|month|days|hours|minutes|seconds)/i.test(u)),s],([i,s])=>s?i:i.filter(([,u])=>s?+u:u>0),i=>i.reduce((s,[u,p])=>[...s,`${p} ${o(p,u)}`],[]),i=>i.length<1?"Dates are equal":`${i.slice(0,-1).join(", ")}${i.length>1?" and ":""}${i.slice(-1).shift()}`)}}var Mr=Ir;function Ir(){let e=Object.entries({year:"FullYear",month:"Month",date:"Date",day:"Date",hour:"Hours",minute:"Minutes",second:"Seconds",millisecond:"Milliseconds"}).reduce((r,[o,i])=>({...r,[o]:i,[`${o}s`]:i}),{}),t=!1,n=function(...r){let o=r.length===1;return t=r[0].trim().startsWith("subtract,"),t&&(r=o?r[0].trim().replace(/^subtract,/i,"").split(",").map(i=>i.trim()):r.filter(i=>!i.startsWith("subtract"))),o&&!t&&(r=r[0].split(",").map(i=>i.trim())),r.map(function(i){if(!i)return!1;let s=i.toLowerCase().split(/ {1,}/);return s.length<2?!1:s.map(u=>{u=`${u}`.trim().replace(/[^a-z0-9-+]/g,"");let p=parseInt(u,10);return Number.isNaN(p)?u:t?-p:+p})}).filter(i=>i)};return function(r,...o){if(o.length<1)return r;let i=n(...o);return i.length&&i.forEach(([s,u])=>{u=u,u=e[u],s&&u&&r[`set${u}`](r[`get${u}`]()+s)}),r}}var Lt=kr(),kt=Qr(),F=Mr();function pt(e,...t){return F(e,...t),e}function Ee(e,{start:t,end:n,future:r,past:o,include:i={start:!1,end:!1}}={}){let s=e.clone.UTC;return t=t?.value||t?.constructor===Date?D(t?.value||t).UTC:D.now.UTC,n=n&&n?.value||n?.constructor===Date?D(n?.value||n).UTC:D.now.UTC,s.milliseconds=0,t.milliseconds=0,n.milliseconds=0,r?t>n:o?t<n:(i.start?+s>=+t:+s>+t)&&(i.end?+s<=+n:+s<+n)}function yt(e,{zoneTime:t=!1,formatStr:n,moreOptions:r}={}){return r=t?e.localeInfo.formatOptions+(r?`,${r}`:""):j.formatOptions+(r?`,${r}`:""),t?(e.localeInfo||(e.localeInfo=j),me(e,n,r)):Zr(e,n,r)}function Zr(e,t,n){let r=e.clone.relocate(j);return n=(n||"").startsWith("+")?`${r.localeInfo.formatOptions},${n.slice(1)}`:n||r.localeInfo.formatOptions,me(r,t,n)}function Pr(e,t){let n=Lt({start:e,end:t||e});return parseInt(`${n.sign}${n.diffInDays}`)}function ht(e,t=!1){let{locale:n,timeZone:r}=t?e.localeInfo:j,o=Ut(n,r),i=e.format("MM|WD",o).split("|");return{locale:n,timeZone:r,monthName:i[0],dayName:i[1],dayNames:Qt(n),monthNames:Je(n)}}function bt(e,t=!1){let[n,r,o,i]=Pe(e,t),s={values4Timezone:t?j.timeZone:e.timeZone,hours:n,minutes:r,seconds:o,milliseconds:i};return Object.freeze(s)}function Pe(e,t=!1){let n=`l:en-CA,${t?`tz:${j.timeZone}`:`tz:${e.timeZone}`},hrc:23,ts:medium`;return e.format("",n).split(/:/).map(Number).concat(e.getMilliseconds())}function St(e,t){let n=t?`tz:${j.timeZone}`:`,tz:${e.timeZone}`,[r,o,i]=e.format("yyyy-mm-dd",n).split(/-/).map(Number);o-=1;let s=t?j.timeZone:e.timeZone;return Object.freeze({values4Timezone:s,year:r,month:o,date:i})}function xt(e,t=!0){if(t)return[e.getFullYear(),e.getMonth(),e.getDate()];let n=e.format("yyyy-m-d",e.localeInfo.formatOptions).split(/-/).map(Number);return n[1]-=1,n}function Fr(e,{sunday:t=!1}={}){return Fe(e,{day:t?"sunday":"monday"})}function zr(e,t){let n=e.toString().match(/GMT([+-])\d+/)?.[0]?.slice(3)??"+0000",r=t.toString().match(/GMT([+-])\d+/)?.[0]?.slice(3)??"+0000";return n=ze(n.slice(0,3)+":"+n.slice(-2),!0),r=ze(r.slice(0,3)+":"+r.slice(-2),!0),[-n[0]+r[0],-n[1]+r[1]].map(o=>n[0]<0?-o:o)}function Et({start:e,end:t}={}){t||(t=e.clone),t?.clone||(t=D(t,{timeZone:e.timeZone})),e=D(Tt(e,e.timeZone),{timeZone:e.timeZone}),t=D(Tt(t,t.timeZone),{timeZone:t.timeZone});let n=Lt({start:e,end:t,diffs:{timeZoneStart:e.timeZone,timeZoneEnd:t.timeZone}}),r=zr(t,e),o=n.sign.startsWith("-")?"ahead of":"behind",[i,s]=r.map(y=>Math.abs(y)),[u,p]=[`${i} ${de(i,"hour")}`,`${s} ${de(s,"minute")}`];return n.timeZonesOffsetDifference=n.sign.length<1||i+s===0?`Offsets of ${e.timeZone} and ${t.timeZone} are equal`:`${e.timeZone} is ${u}${s>0?` and ${p}`:""} ${o} ${t.timeZone}`,n}function vt(e,t){t=String(t).toLowerCase()==="utc"||t.timeZone==="UTC"?e.clone.relocate({timeZone:"UTC"}):D(e.value,{timeZone:t.timeZone||j.timeZone});let n=Et({start:e.clone,end:t}),r=`${n.sign}${$t(n.hours)}:${$t(n.minutes)}`;return{fromTZ:e.timeZone,toTZ:t.timeZone,offset:r,offsetText:`${t.timeZone} ${Hr(r)} ${e.timeZone}`}}function $t(e,t=2){return`${e}`.padStart(t,"0")}function de(e,t){return`${t}${e>1||e===0?"s":""}`}function Hr(e){if(/00:00/.test(e))return"no time diffence to";let t=e.slice(1).split(":").map(Number),[n,r]=t,o=de(n,"hour"),i=de(r,"minute"),s=e.startsWith("+");return r>0?`${n} ${o} and ${r} ${i} ${s?"ahead of":"behind"}`:`${n} ${o} ${s?"ahead of":"behind"}`}function wt(e,t,n){return e.clone.format(t,n||e.localeInfo.formatOptions)}function Rr(e,{withFormat:t,withFormatOptions:n,local:r=!1}={}){if(t)return r?wt(e,t,$D.localeInformation.formatOptions):wt(e,t,n);let o=e.clone.relocate({locale:"en"}),i=r?j.formatOptions:o.localeInfo.formatOptions,s=`wd M dd yyyy hh:mmi:ss ${o.format("tz",i+",tzn:longOffset").replace(":","")} (tz)`;return o.format(s,i+",tzn:long, hrc:23")}function Mt(e,t=!1){let n=Intl.DateTimeFormat("en",{timeZone:t?e.timeZone:j.timeZone,weekday:"short"});return kt(n.format(e))}function Jr(e){let t=j,n=e.localeInfo,r=e.clone.relocate({locale:t.locale,timeZone:t.timeZone}),o=e.offsetFrom(r),i=r.offsetFrom(e),s=t,u=n,p=e.format("hh:mmi:ss dp",`hrc:12,tz:${e.timeZone}`),y=r.format("hh:mmi:ss dp",`hrc:12,tz:${r.timeZone}`),g={note:"'user' are values for your locale/timeZone, 'remote' (if applicable) idem for the instance",locales:{user:{locale:s.locale,timeZone:s.timeZone}},dateTime:{user:{...e.dateTime,monthName:r.monthName,weekdayNr:r.day,weekdayName:r.dayName,dayPeriodTime:y,hasDST:r.hasDST,DSTActive:r.DSTActive,offsetFromRemote:o.offset,string:r.toString()}},offset:{fromUTC:e.UTC.offsetFrom(e).offsetText}};return n.timeZone!==t.timeZone&&(g.locales.remote={locale:u.locale,timeZone:u.timeZone},g.dateTime.remote={...e.zoneDateTime,monthName:e.zoneNames.monthName,weekdayNr:Mt(e,!0),weekdayName:e.zoneNames.dayName,dayPeriodTime:p,hasDST:e.hasDST,DSTActive:e.DSTActive,offsetFromUser:i.offset,string:e.toString()},g.offset.fromUserTime=i.offsetText),g}function se(e,t=!0){if(t)return[e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds()];let n=e.format("yyyy-m-d-hh-mmi-ss",`${e.localeInfo.formatOptions},hrc23:true`).split(/-/).map(Number).concat(e.getMilliseconds());return n[1]-=1,n}function It(e){return new Date(e.year,e.month+1,0,0,0,0).getDate()}function Zt(e,t){t=k({locale:t}).locale;let n=e.clone.relocate({locale:t});return n.date={date:1},[n].concat([...Array(It(n)-1)].map((r,o)=>n.clone.add(`${o+1} days`)))}function Fe(e,{day:t,next:n=!1}={}){let r=kt(t?.toLowerCase()),o=D(new Date(...e.dateTimeValues),e.localeInfo);return r<0?(console.error(`[TickTock instance].next/previous invalid day value ${t}`),o):Pt(o,r,n?1:-1)}function Pt(e,t,n){return F(e,`${n} day`).getDay()<t?Pt(e,t,n):e}function ue(e,{dateOnly:t=!1,timeOnly:n=!1}={}){let{locale:r,timeZone:o}=e.localeInfo;return t?new Date(e).toLocaleDateString(r,{timeZone:o}):n?new Date(e).toLocaleTimeString(r,{timeZone:o}):new Date(e).toLocaleString(r,{timeZone:o})}function Tt(e,t){let n={timeZone:t,hourCycle:"h23"};return new Date(new Date(e).toLocaleString("en",n))}function X(e,{year:t,month:n,date:r}={}){return E(t)&&e.setFullYear(parseInt(t)),E(r)&&e.setDate(parseInt(r)),E(n)&&e.setMonth(parseInt(n)),e}function B(e,{hours:t,minutes:n,seconds:r,milliseconds:o}={}){return E(t)&&e.setHours(parseInt(t)),E(n)&&e.setMinutes(parseInt(n)),E(r)&&e.setSeconds(parseInt(r)),E(o)&&e.setMilliseconds(parseInt(o)),e}function Ft(e){return e?.constructor===Date||e?.value}function Ot(e,t){return Ft(t)?D(t?.value||t,e.localeInfo):D.from(...e.dateTimeValues).relocate(e.localeInfo)}function Qr(){let e={short:["sun","mon","tue","wed","thu","fri","sat"],long:["sunday","monday","tuesday","wednesday","thursday","friday","saturday"]};return function(t){t=`${t}`.toLowerCase();let n=e.short.indexOf(t);return n<0?e.long.indexOf(t):n}}function ze(e){let t=e.slice(1).split(/[-:]/).map(Number),n=e.startsWith("-");return t=t.map(r=>n?-r:r),t}function Ur(e){return e.time={hours:0,minutes:0,seconds:0,milliseconds:0},e}function Dt(e,t){return Intl.DateTimeFormat("en-CA",{timeZone:t,timeZoneName:"long"}).format(e).split(/,/)[1].trim()}function zt(e,t){t=t||e?.timeZone||j.timeZone,e=e?.value?e:e?.constructor===Date?D(e,{timeZone:t}):D({timeZone:t});let n=e.year||e.getFullYear(),r=Dt(new Date(n,0,1),t),o=Dt(new Date(n,5,1),t);return r!==o}function Ht(e,t){return t=t||e?.timeZone||j.timeZone,e=e?.hasDST?e:e?.constructor===Date?D(e,{timeZone:t}):D({timeZone:t}),e.hasDST?!/standard/i.test(e.toString()):!1}function Wr(e,{locale:t,timeZone:n,l:r,tz:o}={}){return e.localeInfo=k({locale:r||t||e.l||e.locale,timeZone:o||n||e.tz||e.timeZone}),e}function qr(e,t){return Ft(t)&&(e=D(t.value||t,t.localeInfo||e.localeInfo)),e}function Re(e,t){let n=Rt(new Date(e,11,t||31));return n===1?Re(e,(t||31)-1):n}function jt(e,t){let n=e.month;switch(!0){case n<3:return t?1:"First";case n<6:return t?2:"Second";case n<9:return t?3:"Third";case n<12:return t?4:"Fourth";default:return"unknown"}}function Rt(e){let t=new Date(e),n=(t.getDay()+6)%7;t.setDate(t.getDate()-n+3);let r=t.valueOf();return t.setMonth(0,1),t.getDay()!==4&&t.setMonth(0,1+(4-t.getDay()+7)%7),1+Math.ceil((r-t)/6048e5)}var Jt=Br;function Br({localeInfo:e,customMethods:t,dateValue:n}={}){let r,o={add(...i){return pt(r,...i)},between({start:i,end:s,include:u}={}){return Ee(r,{start:i,end:s,include:u})},cloneWith(i){return Ot(r,i)},daysUntil(i){return Pr(r,i)},differenceTo(i){return Et({start:r,end:i})},differenceUntil(i){return r.differenceTo(i).clean},firstWeekday({sunday:i=!1,midnight:s=!1}={}){return Fr(r,{sunday:i,midnight:s})},format(i,s){return yt(r,{formatStr:i,moreOptions:s})},fullMonth(i){return Zt(r,i)},isFuture(i){return Ee(r,{start:r,end:i,future:!0})},isPast(i){return Ee(r,{start:r,end:i,past:!0})},next(i){return Fe(r,{day:i,next:!0})},offsetFrom(i){return vt(r,i)},previous(i){return Fe(r,{day:i,next:!1})},relocate({locale:i,timeZone:s,l:u,tz:p}={}){return Wr(r,{locale:i,timeZone:s,l:u,tz:p})},revalue(i){return r=qr(r,i),r},setDateValues({year:i,month:s,date:u}={}){return X(r,{year:i,month:s,date:u})},setTimeValues({hours:i,minutes:s,seconds:u,milliseconds:p}={}){return B(r,{hours:i,minutes:s,seconds:u,milliseconds:p})},subtract(...i){return pt(r,"subtract,"+i.join(","))},toArray(i=!1){return se(r,i)},toString({template:i,formatOptions:s,local:u}={}){return Rr(r,{withFormat:i,withFormatOptions:s,local:u})},values(i=!1){return i?r.dateTime:r.zoneDateTime},zoneFormat(i,s){return yt(r,{zoneTime:!0,formatStr:i,moreOptions:s})},set date({year:i,month:s,date:u}){X(r,{year:i,month:s,date:u})},set dateNr(i){X(r,{date:i})},set hours(i){B(r,{hours:i})},set localeInfo({locale:i,timeZone:s,l:u,tz:p}){e=ce({locale:i,timeZone:s,l:u,tz:p})},set milliseconds(i){B(r,{milliseconds:`${i}`})},set minutes(i){B(r,{minutes:i})},set month(i){X(r,{month:i})},set seconds(i){B(r,{seconds:i})},set time({hours:i,minutes:s,seconds:u,milliseconds:p}){B(r,{hours:i,minutes:s,seconds:u,milliseconds:p})},set year(i){X(r,{year:i})},get age(){return r.differenceTo(new Date).years},get ageFull(){return r.differenceTo(new Date).clean},get clone(){return Ot(r)},get date(){return St(r,!0)},get dateNr(){return r.date.date},get dateTime(){return{...r.date,...r.time}},get dateTimeValues(){return se(r,!0)},get dateValues(){return xt(r,!0)},get day(){return r.getDay()},get dayName(){return r.names.dayName},get daysThisMonth(){return It(r)},get DSTActive(){return Ht(r)},get hasDST(){return zt(r)},get hours(){return r.time.hours},get info(){return Jr(r)},get isLeapYear(){return new Date(r.getFullYear(),2,0).getDate()===29},get ISO(){return r.toISOString()},get local(){return ue(r)},get localDate(){return ue(r,{dateOnly:!0})},get locale(){return(e||ce()).locale},get localeInfo(){return e},get localeString(){return ue(r)},get localTime(){return ue(r,{timeOnly:!0})},get milliseconds(){return r.getMilliseconds()},get minutes(){return r.time.minutes},get month(){return r.date.month},get monthName(){return r.names.monthName},get names(){return ht(r)},get quarter(){return jt(r)},get quarterNr(){return jt(r,!0)},get removeTime(){return Ur(r)},get seconds(){return r.time.seconds},get time(){return bt(r,!0)},get timeValues(){return Pe(r,!0)},get timeZone(){return(e||ce()).timeZone},get unixEpochTimestamp(){return Math.floor(+r/1e3)},get userLocaleInfo(){return j},get UTC(){return r.clone.relocate({locale:r.locale,timeZone:"UTC"})},get UTCOffset(){return vt(r,"UTC")},get value(){return new Date(r)},get weeknr(){return Rt(r)},get weeksInYear(){return Re(r.year,31)},get year(){return r.date.year},get zoneDate(){return St(r,!1)},get zoneDateNr(){return r.zoneDate.date},get zoneDateTime(){return{...r.zoneDate,...r.zoneTime}},get zoneDateTimeValues(){return se(r,!1)},get zoneDateValues(){return xt(r,!1)},get zoneDay(){return Mt(r,!0)},get zoneDayname(){return r.zoneNames.dayName},get zoneHours(){return r.zoneTime.hours},get zoneMinutes(){return r.zoneTime.minutes},get zoneMonth(){return r.zoneDate.month},get zoneMonthname(){return r.zoneNames.monthName},get zoneNames(){return ht(r,!0)},get zoneSeconds(){return r.zoneTime.seconds},get zoneTime(){return bt(r)},get zoneTimeValues(){return Pe(r)},get zoneYear(){return r.zoneDate.year},get zoneValues(){return r.zoneDateTime},get zoneArray(){return se(r,!1)}};return!e&&!n?o:(o.localeInfo=e||ce(),r=new Proxy(n,Vr(o)),Object.entries(Object.getOwnPropertyDescriptors(Wt(r,t))).forEach(([i,s])=>Object.defineProperty(o,i,s)),Object.freeze(r))}function Vr(e){return{get(t,n){return n!=="toString"&&n in t?t[n].bind(t):Reflect.get(e,n)},set(t,n,r){return n in e&&Reflect.set(e,n,r)}}}var j=He(Intl.DateTimeFormat().resolvedOptions()),Yr=Object.getOwnPropertyNames(Date.prototype).filter(e=>e.startsWith("set")).reduce((e,t)=>[...e,{native:t,syn:"change"+t.slice(3)}],[]),Me="\u{1F6AB}";function Qt(e="en-GB"){return e=k({locale:e}).locale,{long:[...Array(7).keys()].map(t=>new Date(Date.UTC(1970,0,4+t)).toLocaleDateString(e,{timeZone:"Etc/UTC",weekday:"long"})),short:[...Array(7).keys()].map(t=>new Date(Date.UTC(1970,0,4+t)).toLocaleDateString(e,{timeZone:"Etc/UTC",weekday:"short"}))}}function Je(e="en"){return e=k({locale:e}).locale,{long:[...Array(12).keys()].map(t=>new Date(Date.UTC(1970,t,1)).toLocaleDateString(e,{timeZone:"Etc/UTC",month:"long"})),short:[...Array(12).keys()].map(t=>new Date(Date.UTC(1970,t,1)).toLocaleDateString(e,{timeZone:"Etc/UTC",month:"short"}))}}function _r({year:e,locale:t}={}){e=E(e)?parseInt(e):new Date().getFullYear();let n={year:e,calendar:{}},r=Je().long.map(o=>o.toLowerCase());for(let o=0;o<12;o+=1){let i=D.from(e,o,1);n.calendar[r[o]]=Zt(i,t)}return n}function Gr({year:e,monthNr:t,locale:n="en-CA"}={}){e=E(t)&&parseInt(e)||-1,t=E(t)&&parseInt(t)||new Date().getFullYear();let r=t>=1&&t<=12;return n=k({locale:n}).locale,t=r?t-1:void 0,r?D.from(e,t,1).relocate({locale:n}).fullMonth(n):"MonthNr should be a specific number (1 = january - 12 = december)"}function He(e){let t=Ut(e.locale,e.timeZone);return Object.defineProperty(e,"formatOptions",{value:t,enumerable:!1})}function Ut(e,t){return[`${e&&!(Array.isArray(e)&&e.length<1)?`l:${e}`:""}`,`${t?`tz:${t}`:""}`].filter(n=>n).join(",")}function k({locale:e,timeZone:t,l:n,tz:r}={}){return t=t||r,e=e||n,!e&&!t?j:Xr({trial:function(){let o=Intl.DateTimeFormat(e,{timeZone:t}).resolvedOptions();return e&&o.locale!==e&&console.error(`${Me} Intl changed locale (using best fit) "${e}" to "${o.locale}"`),He(o)},onError:function(o){switch(!0){case/incorrect locale/i.test(o.message):return console.error(`${Me} Intl locale "${e}" best fit impossible, using "${j.locale}"`),k({locale:j.locale,timeZone:t});case/invalid time zone/i.test(o.message):return console.error(`${Me} timeZone "${t}" not valid. Using "${j.timeZone}"`),k({locale:e,timeZone:j.timeZone});default:return j||He(Intl.DateTimeFormat().resolvedOptions())}}})}function ce({locale:e,timeZone:t,l:n,tz:r}={}){return k({locale:e,timeZone:t,l:n,tz:r},!0)}function Nt(e){return!Number.isNaN(+e)&&e?.constructor===Date&&!e?.toISOString?.().startsWith("1970-01-01T00:00:00")?e:new Date}function Kr(e){let t=new Date;switch(!0){case e?.constructor===String:return Nt(new Date(e));case(Array.isArray(e)&&e.map(Number).length===e.length):return e.length===1?new Date(e[0],0,1):new Date(...e);case e?.constructor===Date:return Nt(e);default:return t}}function Xr({trial:e,onError:t=()=>{}}={}){if(e?.constructor===Function)try{return e()}catch(n){return t?.constructor===Function?t(n):void 0}}function eo({timeZoneDate:e,timeZoneID:t,userTimeZoneID:n}={}){let r={timeZone:k({timeZone:t}).timeZone},o={timeZone:k({timeZone:n||""}).timeZone},i=D(e,r),s=D(e,o),u=s.differenceTo(i),p=i.offsetFrom(s).offset,[y,g]=ze(p,!0),S=s.clone.add(`${y} hours, ${g} minutes`),h=u.equalDates?"No difference":`Time offset ${p}: ${o.timeZone} is ${u.clean} ${y<0?"behind":"ahead of"} ${r.timeZone}`;return{remoteTimezone:r.timeZone,userTimezone:o.timeZone,timeDifference:h,result:{[r.timeZone.replace(/\//,"_")]:D(e).toString({template:"yyyy/mm/dd hh:mmi:ss",formatOptions:"hrc:23"}),[o.timeZone.replace(/\//,"_")]:S.toString({template:"yyyy/mm/dd hh:mmi:ss",formatOptions:"hrc:23"})}}}function E(e){return!Number.isNaN(parseInt(e))}function fe(e,t,n){return e?.constructor===Number?F(t,`${e} ${n}`):t}function to(e){let t={addYears(n=1){return fe(n,e,"years")},addMonths(n=1){return fe(n,e,"months")},addWeeks(n=1){return n=n?.constructor===Number?n*7:1,fe(n,e,"days")},addDays(n=1){return fe(n,e,"days")},get nextYear(){return F(e,"1 year")},get nextWeek(){return F(e,"7 days")},get previousWeek(){return F(e,"-7 days")},get previousYear(){return F(e,"-1 year")},get nextMonth(){return F(e,"1 month")},get previousMonth(){return F(e,"-1 month")},get tomorrow(){return F(e,"1 day")},get yesterday(){return F(e,"-1 day")}};for(let n of Yr)t[n.syn]=function(...r){return e[n.native](...r),e};return t}function Wt(e,t){let n=to(e);for(let[r,o]of Object.entries(t||{})){let i=o.enumerable,s=o.isGetter?{get(){return o.method(e)},enumerable:i}:{value(...u){return o.method(e,...u)},enumerable:i};Object.defineProperty(n,r,s)}return n}function no(e,t){return Object.defineProperties(e,{now:{get(){return e(new Date)}},localeInformation:{get(){return k()}},localWeekdaynames:{value(n){return Qt(n)}},localMonthnames:{value(n){return Je(n)}},daysInMonth:{value(n,r=!1){return n=E(n)?parseInt(n):0,n>=1&&n<=12?new Date(r?2e3:2005,n,0).getDate():`${n} should be a Number between (1 (january) - 12 (december))`}},yearCalendar:{value:_r},monthCalendar:{value:Gr},from:{value(...n){return e(n)}},fromUxTS:{value(n,r){n=E(n)?parseInt(n)*1e3:void 0;let o=n?new Date(n):new Date;return D(o,r||j)}},hasDST:{value({date:n,timeZone:r}={}){return zt(n,r)}},DSTActive:{value({date:n,timeZone:r}={}){return Ht(n,r)}},values:{value({date:n,timeZone:r}={}){n=n||n?.value||new Date;let o=me(n,"yyyy-m-d-h-mi-s",k({timeZone:r}).formatOptions.concat(",hrc:23")).split("-").map(Number).concat(n.getMilliseconds());return o[1]-=1,o}},format:{value({date:n,template:r,timeZone:o,locale:i,opts:s}={}){n=n||n?.value||new Date,r=r?.constructor===String?r:"yyyy/mm/dd hh:mmi:ss dp";let u=k({timeZone:o,locale:i}).formatOptions;return u+=s?`,${s}`:"",me(n,r,u)}},addCustom:{value({name:n,method:r,enumerable:o=!1,isGetter:i=!1}={}){n?.constructor===String&&r?.constructor===Function&&r.length>0&&(t[n]={method:r,enumerable:o,isGetter:i})}},validateLocaleInformation:{value:k},timeAcrossZones:{value:eo},weeksInYear:{value(n){return Re(n,31)}},keys:{get(){let n=Object.fromEntries(Object.entries(t).filter(([r,o])=>o.enumerable===!0));return[...Object.keys(Jt()),...Object.keys(Wt()),...Object.keys(n)].sort((r,o)=>r.localeCompare(o))}}}),e}var qt={},D=no(ro,qt);function ro(e,t){if(e?.localeInfo)return e.clone;let n=e?.locale||e?.timeZone||e?.tz||e?.l;return Jt({localeInfo:k(n?e:t),dateValue:new Date(n?Date.now():Kr(e)),customMethods:qt})}var oo=Object.defineProperties(Bt,{escape:{value:go,enumerable:!0}});function Bt(e,...t){let{flags:n,cleanedArgs:r}=ao(...t);return so(new RegExp(po(io(e,...r)),n))}function io(e,...t){return Y(t)?e.raw.reduce((n,r,o)=>n.concat(t[o-1]||"").concat(r),""):e.raw.join("")}function ao(...e){let t=Qe(lo(e.at(-1)));return{flags:t,cleanedArgs:Y(t)?e.slice(0,-1):e}}function lo(e){return ge(e,Array)?e.join(""):""}function so(e){let t=new Proxy(Object.defineProperties({},{re:{get(){return e},enumerable:!1},toString:{value:()=>e.toString(),enumerable:!1},valueOf:{value:()=>e,enumerable:!1},flags:{value(n){return e=mo(n,e),t},enumerable:!1},clone:{get(){return fo(t)},enumerable:!1}}),co(e));return t}function Y(e){return e?.length>0}function ge(e,t){return e?.constructor===t}function uo(e,t,n){let r=Reflect.get(n,t);return{fromInstance:Reflect.get(e,t),fromRegExpMethod:ge(r,Function)?r.bind(e.re):e.re[t]}}function co(e){return{get(t,n){let{fromInstance:r,fromRegExpMethod:o}=uo(t,n,e);switch(!0){case!!r:return r;default:return o}}}}function fo(e){let t=e.re.source,n=Y(e.re.flags)?[...e.re.flags]:[];return Bt`${t} ${n}`}function Qe(e,t){return t=(t??"").replace(/^-r\|/,""),e=t.concat(ge(e,String)&&Y(e)?e:""),[...new Set([...e])].join("").replace(/[^dgimsuvy]/g,"")}function mo(e,t){switch(!0){case(!ge(e,String)||!Y(e)):return t;case e==="-r":return t=new RegExp(t.source);case e.startsWith("-r|"):return t=new RegExp(t.source,Qe(e));default:return t=new RegExp(t.source,Qe(t.flags,e))}}function go(e){switch(!0){case(e?.constructor!==String||!Y(e)):return"";case!!RegExp.escape:return RegExp.escape(e);default:return(`\\x${e.at(0)}`+e.slice(1).replace(/\p{S}|\p{P}/gu,t=>`\\${t}`)).replace(/ |\\x /g,"\\x20")}}function po(e){return e.replace(/\/\*(?:[^*]|\*+[^*\/])*\*+\/|(?<!:|\\\|')\/\/.*/gm,"").replace(/\s/g,"").trim().replace(/<!([^>]\d+)>/g,(t,n)=>String.fromCharCode(+n)??t)}var{IS:yo}=ho(),_=yo;function ho(){Symbol.proxy=Symbol.for("toa.proxy"),Symbol.is=Symbol.for("toa.is"),Symbol.type=Symbol.for("toa.type"),Symbol.isSymbol=Symbol.for("toa.isASymbol"),m();let e=S(),[t,n]=[h(),A()];return n.custom(),{IS:r,maybe:e,$Wrap:t,isNothing:g,xProxy:n};function r(a,...l){if(e({trial:f=>"isTypes"in(l?.[0]??{})})){let f=l[0];return"defaultValue"in f?v(a,f):"notTypes"in f?b(a,f):r(a,...[f.isTypes].flat())}let c=typeof a=="symbol"?Symbol.isSymbol:a;return l.length>1?y(c,...l):i(a,...l)}function o(a){return a?.[Symbol.proxy]??r(a)}function i(a,...l){let{noInput:c,noShouldbe:f,compareTo:w,inputCTOR:N,isNaN:M,isInfinity:I,shouldBeFirstElementIsNothing:Z}=u(a,...l);switch(l=l.length&&l[0],!0){case Z:return String(a)===String(w);case(a?.[Symbol.proxy]&&f):return a[Symbol.proxy];case M:return f?"NaN":e({trial:P=>String(w)})===String(a);case I:return f?"Infinity":e({trial:P=>String(w)})===String(a);case c:return f?String(a):String(w)===String(a);case N===Boolean:return l?N===l:"Boolean";default:return p(a,l,f,s(a,N))}}function s(a,l){return a===0?Number:a===""?String:a?l:{name:String(a)}}function u(a,...l){let c=l.length<1,f=!c&&l[0],w=!c&&g(l[0]),N=a==null,M=!N&&Object.getPrototypeOf(a)?.constructor,I=Number.isNaN(a)||e({trial:P=>String(a)==="NaN"}),Z=e({trial:P=>String(a)})==="Infinity";return{noInput:N,noShouldbe:c,compareTo:f,inputCTOR:M,isNaN:I,isInfinity:Z,shouldBeFirstElementIsNothing:w}}function p(a,l,c,f){switch(!0){case(!c&&l===a||a?.[Symbol.proxy]&&l===Proxy):return!0;case e({trial:w=>String(l)})==="NaN":return String(a)==="NaN";case(a?.[Symbol.toStringTag]&&r(l,String)):return String(l)===a[Symbol.toStringTag];default:return l?e({trial:w=>a instanceof l})||l===f||l===Object.getPrototypeOf(f)||`${l?.name}`===f?.name:a?.[Symbol.toStringTag]&&`[object ${a?.[Symbol.toStringTag]}]`||f?.name||String(f)}}function y(a,...l){return l.some(c=>r(a,c))}function g(a,l=!1){let c=a==null;return c=l?c||r(a,1/0)||r(a,NaN):c,c}function S(){let a=(l,c)=>l?.constructor===Function?l(c):void 0;return function({trial:l,whenError:c=()=>{}}={}){try{return a(l)}catch(f){return a(c,f)}}}function h(){return function(a){return Object.freeze({get value(){return a},get[Symbol.type](){return o(a)},get type(){return o(a)},[Symbol.is](...l){return r(a,...l)},is(...l){return r(a,...l)}})}}function v(a,{defaultValue:l,isTypes:c=[void 0],notTypes:f}={}){return c=c?.constructor!==Array?[c]:c,f=f&&f?.constructor!==Array?[f]:[],f.length<1?r(a,...c)?a:l:b(a,{isTypes:c,notTypes:f})?a:l}function b(a,{isTypes:l=[void 0],notTypes:c=[void 0]}={}){return l=l?.constructor!==Array?[l]:l,c=c?.constructor!==Array?[c]:c,r(a,...l)&&!r(a,...c)}function m(){Object.getOwnPropertyDescriptors(Object.prototype)[Symbol.is]||(Object.defineProperties(Object.prototype,{[Symbol.type]:{get(){return o(this)},enumerable:!1,configurable:!1},[Symbol.is]:{value:function(...a){return r(this,...a)},enumerable:!1,configurable:!1}}),Object.defineProperties(Object,{[Symbol.type]:{value(a){return o(a)},enumerable:!1,configurable:!1},[Symbol.is]:{value:function(a,...l){return r(a,...l)},enumerable:!1,configurable:!1}}))}function x(a){let l=String(Object.getPrototypeOf(a)?.constructor);return l.slice(l.indexOf("ion")+3,l.indexOf("(")).trim()}function T(a){let l=a.set;return a.set=(c,f,w)=>f===Symbol.proxy?c[f]=w:l(c,f,w),a}function A(){let a=Proxy;return{native(){Proxy=a},custom(){Proxy=new a(a,{construct(l,c){for(let w of c)w.set&&(w=T(w));let f=new l(...c);return f[Symbol.proxy]=`Proxy (${x(c[0])})`,f}})}}}}var Vt=Yt(void 0),bo=Yt("");Object.defineProperties(String.prototype,{[Symbol.for("interpolate")]:{value(...e){return Vt(this,...e)}},[Symbol.for("interpolate$")]:{value(...e){return bo(this,...e)}}});function Yt(e){return e=_(e,String,Number)?String(e):void 0,function(y,...g){return p(y,u(g))};function t(y,g){return g&&_(e,String,Number)?String(e):`{${y}}`}function n(y,g){let S=y in g;return S&&_(g[y],String,Number)?String(g[y]):t(y,S)}function r(y){return(...g)=>{let S=g.find(h=>h.key);return n(S?S.key:"_",y)}}function o(y,g){return y.replace(/\{(?<key>[a-z_\d]+)}/gim,r(g))}function i(y){let g=[];return Object.entries(y).forEach(([S,h])=>{h.forEach((v,b)=>(g[b]??={},g[b][S]=v))}),g}function s(y){return y.length===1&&Object.values(y[0]).every(Array.isArray)}function u(y){return s(y)?i(y[0]):y}function p(y,g){let S=g?.length?g.filter(h=>_(h,Object)).map((h,v)=>o(y,{...h,index:v+1})).join(""):y;return _(e,void 0)?S:S.replace(/\{[a-z_\d].+\}/gim,String(e))}}vo();So();function So(){/stackblitz/i.test(location.href)&&console.info("\u2714 Stackblitz rewrites links to _top. The 'stackblitzhelpers' module fixed it."),document.addEventListener("click",e=>{if(e.target.href){let t=e.target;if(t.dataset.top||t.classList.contains("internalLink")||t.target==="_top")return top.location.href=t.href}return!0})}function Wo(e=!0){let t=R('<ul id="log2screen">').first();function n(i=!1){let s=i?R.at.start:R.at.end;return u=>{if(u?.isJQx)return R.li(u.data.get("header")?{class:"head"}:"",u).renderTo(t,s);u=R.IS(u,String,Number,Symbol)?String(u):xo(u,e);let p=u.startsWith("!!");u=p?u.slice(2):u,R.li(p?{class:"head"}:"",u).renderTo(t,s)}}let[r,o]=[n(),n(!0)];return{log:(...i)=>i.forEach(r),logTop:(...i)=>i.forEach(o)}}function xo(e,t){try{return t?`<pre>${JSON.stringify(e,null,2)}</pre>`:JSON.stringify(e)}catch{return"Some [Object object] can not be converted to JSON"}}function vo(){R.editCssRules("body{font:normal 14px/17px system-ui,sans-serif;margin:1rem;}","li::marker{vertical-align:top;}","code{color:green;background-color:#eee;padding:2px;font-family:monospace;}","code.codeblock{display:block;padding:6px;border:1px solid #999;margin:0.5rem 0;background-color:#eee;white-space:pre-wrap;}","h3{marginTop:1.5rem;}",".thickBorder{border:5px solid green;borderWidth:5px;padding:0.5rem;display:inline-block;}","a.ExternalLink{text-decoration:none;color:rgb(0,0,238);background-color:#EEE;padding:3px;font-weight:bold;}",".cmmt{color:#888;}",".hidden{display:none;}",".attention{color:red; font-size:1.2em; font-weight:bold;}","#log2screen li{listStyle:'\\2713';paddingLeft:6px;margin:0.5rem 0 0 -1.2rem;font-family:monospace}","#log2screen li.head{list-style-type:none;font-weight:bold;margin-top:0.8rem;margin-bottom:-0.2rem;font-family:revert;}",".err{fontStyle:italic; color:red; }","a{text-decoration:none; font-weight:bold;}","a:hover{text-decoration:underline;}","a[target]:before,a.internalLink:before,a.externalLink:before{color:rgba(0,0,238,0.7);font-size:1.1rem;padding-right:2px;vertical-align:baseline;}",`a[target="_blank"]:before,a.externalLink:before{content:'\\2197';}`,`a[data-top]:before,a.internalLink:before,a[target="_top"]:before{content:'\\21BA';}`)}export{R as $,D as $D,Wo as logFactory,oo as regexhelper,Vt as splat};
|
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
var HTMLHelpers=(()=>{var je=Object.defineProperty;var yr=Object.getOwnPropertyDescriptor;var hr=Object.getOwnPropertyNames;var br=Object.prototype.hasOwnProperty;var Sr=(e,t)=>{for(var n in t)je(e,n,{get:t[n],enumerable:!0})},xr=(e,t,n,r)=>{if(t&&typeof t=="object"||typeof t=="function")for(let o of hr(t))!br.call(e,o)&&o!==n&&je(e,o,{get:()=>t[o],enumerable:!(r=yr(t,o))||r.enumerable});return e};var vr=e=>xr(je({},"__esModule",{value:!0}),e);var Eo={};Sr(Eo,{$:()=>J,$D:()=>C,logFactory:()=>Co,regexhelper:()=>fr,splat:()=>ft});var wr=Object.defineProperty,l=(e,t)=>wr(e,"name",{value:t,configurable:!0}),{IS:p,maybe:Tr,$Wrap:Lo,xProxy:Fo,isNothing:Mo}=pt();function pt(){Symbol.proxy=Symbol.for("toa.proxy"),Symbol.is=Symbol.for("toa.is"),Symbol.type=Symbol.for("toa.type"),Symbol.isSymbol=Symbol.for("toa.isASymbol"),f();let e=v(),[t,n]=[y(),A()];return n.custom(),{IS:r,maybe:e,$Wrap:t,isNothing:g,xProxy:n};function r(a,...s){if(e({trial:l(d=>"isTypes"in(s?.[0]??{}),"trial")})){let d=s[0];return"defaultValue"in d?w(a,d):"notTypes"in d?S(a,d):r(a,...[d.isTypes].flat())}let m=typeof a=="symbol"?Symbol.isSymbol:a;return s.length>1?h(m,...s):i(a,...s)}function o(a){return a?.[Symbol.proxy]??r(a)}function i(a,...s){let{noInput:m,noShouldbe:d,compareTo:T,inputCTOR:j,isNaN:I,isInfinity:k,shouldBeFirstElementIsNothing:P}=u(a,...s);switch(s=s.length&&s[0],!0){case P:return String(a)===String(T);case(a?.[Symbol.proxy]&&d):return a[Symbol.proxy];case I:return d?"NaN":e({trial:l(Z=>String(T),"trial")})===String(a);case k:return d?"Infinity":e({trial:l(Z=>String(T),"trial")})===String(a);case m:return d?String(a):String(T)===String(a);case j===Boolean:return s?j===s:"Boolean";default:return b(a,s,d,c(a,j))}}function c(a,s){return a===0?Number:a===""?String:a?s:{name:String(a)}}function u(a,...s){let m=s.length<1,d=!m&&s[0],T=!m&&g(s[0]),j=a==null,I=!j&&Object.getPrototypeOf(a)?.constructor,k=e({trial:l(Z=>String(a),"trial")})==="NaN",P=e({trial:l(Z=>String(a),"trial")})==="Infinity";return{noInput:j,noShouldbe:m,compareTo:d,inputCTOR:I,isNaN:k,isInfinity:P,shouldBeFirstElementIsNothing:T}}function b(a,s,m,d){switch(!0){case(!m&&s===a||a?.[Symbol.proxy]&&s===Proxy):return!0;case e({trial:l(T=>String(s),"trial")})==="NaN":return String(a)==="NaN";case(a?.[Symbol.toStringTag]&&r(s,String)):return String(s)===a[Symbol.toStringTag];default:return s?e({trial:l(T=>a instanceof s,"trial")})||s===d||s===Object.getPrototypeOf(d)||`${s?.name}`===d?.name:a?.[Symbol.toStringTag]&&`[object ${a?.[Symbol.toStringTag]}]`||d?.name||String(d)}}function h(a,...s){return s.some(m=>r(a,m))}function g(a,s=!1){let m=a==null;return m=s?m||r(a,1/0)||r(a,NaN):m,m}function v(){let a=l((s,m)=>s?.constructor===Function?s(m):void 0,"tryFn");return function({trial:s,whenError:m=l(()=>{},"whenError")}={}){try{return a(s)}catch(d){return a(m,d)}}}function y(){return function(a){return Object.freeze({get value(){return a},get[Symbol.type](){return o(a)},get type(){return o(a)},[Symbol.is](...s){return r(a,...s)},is(...s){return r(a,...s)}})}}function w(a,{defaultValue:s,isTypes:m=[void 0],notTypes:d}={}){return m=m?.constructor!==Array?[m]:m,d=d&&d?.constructor!==Array?[d]:[],d.length<1?r(a,...m)?a:s:S(a,{isTypes:m,notTypes:d})?a:s}function S(a,{isTypes:s=[void 0],notTypes:m=[void 0]}={}){return s=s?.constructor!==Array?[s]:s,m=m?.constructor!==Array?[m]:m,r(a,...s)&&!r(a,...m)}function f(){Object.getOwnPropertyDescriptors(Object.prototype)[Symbol.is]||(Object.defineProperties(Object.prototype,{[Symbol.type]:{get(){return o(this)},enumerable:!1,configurable:!1},[Symbol.is]:{value:l(function(...a){return r(this,...a)},"value"),enumerable:!1,configurable:!1}}),Object.defineProperties(Object,{[Symbol.type]:{value(a){return o(a)},enumerable:!1,configurable:!1},[Symbol.is]:{value:l(function(a,...s){return r(a,...s)},"value"),enumerable:!1,configurable:!1}}))}function x(a){let s=String(Object.getPrototypeOf(a)?.constructor);return s.slice(s.indexOf("ion")+3,s.indexOf("(")).trim()}function O(a){let s=a.set;return a.set=(m,d,T)=>d===Symbol.proxy?m[d]=T:s(m,d,T),a}function A(){let a=Proxy;return{native(){Proxy=a},custom(){Proxy=new a(a,{construct(s,m){for(let T of m)T.set&&(T=O(T));let d=new s(...m);return d[Symbol.proxy]=`Proxy (${x(m[0])})`,d}})}}}}l(pt,"TOAFactory");var $r=bt(),Ee=yt(),ae=ht();function yt(){return{html:Object.freeze("accept,action,align,alt,autocapitalize,autocomplete,autopictureinpicture,autoplay,background,bgcolor,border,capture,cellpadding,cellspacing,checked,cite,class,clear,contenteditable,color,cols,colspan,controls,controlslist,coords,crossorigin,datetime,decoding,default,dir,disabled,disablepictureinpicture,disableremoteplayback,download,draggable,enctype,enterkeyhint,face,for,headers,height,hidden,high,href,hreflang,id,inputmode,integrity,is,ismap,kind,label,lang,list,loading,loop,low,max,maxlength,media,method,min,minlength,multiple,muted,name,nonce,noshade,novalidate,nowrap,open,optimum,pattern,placeholder,playsinline,poster,preload,pubdate,radiogroup,readonly,rel,required,rev,reversed,role,rows,rowspan,spellcheck,scope,selected,shape,size,sizes,span,srclang,start,src,srcset,step,style,summary,tabindex,target,title,translate,type,usemap,valign,value,width,xmlns,slot".split(",")),svg:Object.freeze("accent-height,accumulate,additive,alignment-baseline,ascent,attributename,attributetype,azimuth,basefrequency,baseline-shift,begin,bias,by,class,clip,clippathunits,clip-path,clip-rule,color,color-interpolation,color-interpolation-filters,color-profile,color-rendering,cx,cy,d,dx,dy,diffuseconstant,direction,display,divisor,dur,edgemode,elevation,end,fill,fill-opacity,fill-rule,filter,filterunits,flood-color,flood-opacity,font-family,font-size,font-size-adjust,font-stretch,font-style,font-variant,font-weight,fx,fy,g1,g2,glyph-name,glyphref,gradientunits,gradienttransform,height,href,id,image-rendering,in,in2,k,k1,k2,k3,k4,kerning,keypoints,keysplines,keytimes,lang,lengthadjust,letter-spacing,kernelmatrix,kernelunitlength,lighting-color,local,marker-end,marker-mid,marker-start,markerheight,markerunits,markerwidth,maskcontentunits,maskunits,max,mask,media,method,mode,min,name,numoctaves,offset,operator,opacity,order,orient,orientation,origin,overflow,paint-order,path,pathlength,patterncontentunits,patterntransform,patternunits,points,preservealpha,preserveaspectratio,primitiveunits,r,rx,ry,radius,refx,refy,repeatcount,repeatdur,restart,result,rotate,scale,seed,shape-rendering,specularconstant,specularexponent,spreadmethod,startoffset,stddeviation,stitchtiles,stop-color,stop-opacity,stroke-dasharray,stroke-dashoffset,stroke-linecap,stroke-linejoin,stroke-miterlimit,stroke-opacity,stroke,stroke-width,style,surfacescale,systemlanguage,tabindex,targetx,targety,transform,text-anchor,text-decoration,text-rendering,textlength,type,u1,u2,unicode,values,viewbox,visibility,version,vert-adv-y,vert-origin-x,vert-origin-y,width,word-spacing,wrap,writing-mode,xchannelselector,ychannelselector,x,x1,x2,xmlns,y,y1,y2,z,zoomandpan".split(","))}}l(yt,"getAttrs");function ht(){return{a:!0,area:!0,audio:!1,br:!0,base:!0,body:!0,button:!0,canvas:!0,comment:!0,dl:!0,data:!0,datalist:!0,div:!0,em:!0,embed:!1,fieldset:!0,font:!0,footer:!0,form:!1,hr:!0,head:!0,header:!0,output:!0,iframe:!1,frameset:!1,img:!0,input:!0,li:!0,label:!0,legend:!0,link:!0,map:!0,mark:!0,menu:!0,media:!0,meta:!0,nav:!0,meter:!0,ol:!0,object:!1,optgroup:!0,option:!0,p:!0,param:!0,picture:!0,pre:!0,progress:!1,quote:!0,script:!1,select:!0,source:!0,span:!0,style:!0,caption:!0,td:!0,col:!0,table:!0,tr:!0,template:!1,textarea:!0,time:!0,title:!0,track:!0,details:!0,ul:!0,video:!0,del:!0,ins:!0,slot:!0,blockquote:!0,svg:!0,dialog:!0,summary:!0,main:!0,address:!0,colgroup:!0,tbody:!0,tfoot:!0,thead:!0,th:!0,dd:!0,dt:!0,figcaption:!0,figure:!0,i:!0,b:!0,code:!0,h1:!0,h2:!0,h3:!0,h4:!0,abbr:!0,bdo:!0,dfn:!0,kbd:!0,q:!0,rb:!0,rp:!0,rt:!0,ruby:!0,s:!0,strike:!0,samp:!0,small:!0,strong:!0,sup:!0,sub:!0,u:!0,var:!0,wbr:!0,nobr:!0,tt:!0,noscript:!0}}l(ht,"getPermissions");function bt(){return["::backdrop{background-color:grey;opacity:0.2;}",`#jqxPopup{overflow:hidden;background-color:transparent;outline:none;border:none;inset:0;animation:fade-out 0.5s ease-out;&[open]{display:flex;align-items:center;justify-content:center;animation:fade-in 0.5s ease;}#jqxPopupContent{background-color:white;border:solid 1px #eee;box-shadow:1px 2px 8px #999;border-radius:4px;padding:12px;vertical-align:middle;max-height:40vh;max-width:50vw;overflow:auto;margin:0 auto;div:not(#closeHandleIcon){clear:both;}@media (width <= 640px){max-width:80vw;max-height:60vh;}#closeHandleIcon{cursor:pointer;width:24px;height:24px;display:inline;position:absolute;top:4px;right:4px;justify-content:right;background-image:url("data:image/svg+xml;utf8,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22iso-8859-1%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20xmlns%3Axlink%3D%22http%3A%2F%2Fwww.w3.org%2F1999%2Fxlink%22%20version%3D%221.1%22%20id%3D%22Layer_1%22%20x%3D%220px%22%20y%3D%220px%22%20viewBox%3D%220%200%20128%20128%22%20style%3D%22enable-background%3Anew%200%200%20128%20128%3B%22%20xml%3Aspace%3D%22preserve%22%3E%3Crect%20x%3D%22-368%22%20y%3D%226%22%20style%3D%22display%3Anone%3Bfill%3A%23E0E0E0%3B%22%20width%3D%22866%22%20height%3D%221018%22%2F%3E%3Ccircle%20style%3D%22fill%3A%23FFFFFF%3B%22%20cx%3D%2264%22%20cy%3D%2264%22%20r%3D%2248%22%2F%3E%3Ccircle%20style%3D%22fill%3A%238CCFB9%3B%22%20cx%3D%2264%22%20cy%3D%2264%22%20r%3D%2239%22%2F%3E%3Ccircle%20style%3D%22fill%3Anone%3Bstroke%3A%23444B54%3Bstroke-width%3A6%3Bstroke-miterlimit%3A10%3B%22%20cx%3D%2264%22%20cy%3D%2264%22%20r%3D%2248%22%2F%3E%3Cpolyline%20style%3D%22fill%3Anone%3Bstroke%3A%23FFFFFF%3Bstroke-width%3A6%3Bstroke-linecap%3Around%3Bstroke-miterlimit%3A10%3B%22%20points%3D%2242%2C69%2055.55%2C81%20%20%2086%2C46%20%22%2F%3E%3C%2Fsvg%3E");@media (width <= 640px){background-image:none;position:relative;margin:-15px -15px 4px 0;float:right;vertical-align:middle;border:1px solid #AAA;padding:2px;border-radius:50%;width:12px;height:12px;font-size:12px;line-height:12px;font-weight:bold;text-align:center;&:after{content:'\\2714';color:green;}}}.warn{display:none;text-align:center;color:red;border-top:1px solid #999;margin-top:1em;padding-top:3px;animation:warn-fade-out 0.2s ease-out;}.warn.active{opacity:1;display:block;animation:warn-fade-in 0.2s ease-in;}}}`,"@keyframes fade-in{0%{opacity:0;transform:scale(0, 0);display:none;}100%{opacity:1;transform:scale(1, 1);display:flex;}}","@keyframes fade-out{0%{opacity:1;transform:scale(1, 1);display:flex;}100%{opacity:0;transform:scale(0, 0);display:none;}}","@keyframes warn-fade-in{0%{opacity:0;transform:scale(0, 0);display:none;}100%{opacity:1;transform:scale(1,1 );display:block;}}","@keyframes warn-fade-out{0%{opacity:1;transform:scale(1, 1);display:block;}100%{opacity:0;transform:scale(0, 0);display:none;}}"]}l(bt,"getPopupStyling");var gt={html:"innerHTML",text:"textContent",class:"className"},Or=St();function St(){let e={get(t,n){let r=String(n)?.toLowerCase();switch(!0){case r in t:return t[r];case Nt(r):return Ae(t,r,n);default:return Ae(t,r,n,!0)}},enumerable:!1,configurable:!1};return new Proxy({},e)}l(St,"tinyDOM");function Ae(e,t,n,r=!1){return Object.defineProperty(e,t,{get(){return r?o=>Dt(n):jt(t)}}),e[t]}l(Ae,"createTagFunctionProperty");function xt(e,t,n){return t=t?.isJQx&&t.first()||t,Tr({trial:l(r=>Ct(t)?e.append(t):Ve(t)?e.insertAdjacentHTML("beforeend",t):e.append(t),"trial"),whenError:l(r=>console.info(`${n} (for root ${e}) not created, reason
|
|
2
|
-
`,r)
|
|
3
|
-
=> @charset, @namespace and @import are not supported here`),{done:!0}}
|
|
4
|
-
${
|
|
5
|
-
Rule: ${
|
|
6
|
-
${n}`),
|
|
7
|
-
${
|
|
8
|
-
Rule: ${
|
|
9
|
-
${n}`),
|
|
10
|
-
`)}
|
|
11
|
-
`).map(r=>r.replace(/\s|\/\/.*$/g,"").trim().replace(/(@s!)/g," ")).join(""),n)}
|
|
1
|
+
var HTMLHelpers=(()=>{var pe=Object.defineProperty;var Kt=Object.getOwnPropertyDescriptor;var Xt=Object.getOwnPropertyNames;var en=Object.prototype.hasOwnProperty;var tn=(e,t)=>{for(var n in t)pe(e,n,{get:t[n],enumerable:!0})},nn=(e,t,n,r)=>{if(t&&typeof t=="object"||typeof t=="function")for(let o of Xt(t))!en.call(e,o)&&o!==n&&pe(e,o,{get:()=>t[o],enumerable:!(r=Kt(t,o))||r.enumerable});return e};var rn=e=>nn(pe({},"__esModule",{value:!0}),e);var Ao={};tn(Ao,{$:()=>H,$D:()=>D,logFactory:()=>jo,regexhelper:()=>Yt,splat:()=>We});var{IS:d,maybe:on,$Wrap:ko,xProxy:Eo,isNothing:Mo}=an();function an(){Symbol.proxy=Symbol.for("toa.proxy"),Symbol.is=Symbol.for("toa.is"),Symbol.type=Symbol.for("toa.type"),Symbol.isSymbol=Symbol.for("toa.isASymbol"),m();let e=S(),[t,n]=[h(),A()];return n.custom(),{IS:r,maybe:e,$Wrap:t,isNothing:g,xProxy:n};function r(a,...l){if(e({trial:f=>"isTypes"in(l?.[0]??{})})){let f=l[0];return"defaultValue"in f?v(a,f):"notTypes"in f?b(a,f):r(a,...[f.isTypes].flat())}let c=typeof a=="symbol"?Symbol.isSymbol:a;return l.length>1?y(c,...l):i(a,...l)}function o(a){return a?.[Symbol.proxy]??r(a)}function i(a,...l){let{noInput:c,noShouldbe:f,compareTo:w,inputCTOR:N,isNaN:M,isInfinity:I,shouldBeFirstElementIsNothing:Z}=u(a,...l);switch(l=l.length&&l[0],!0){case Z:return String(a)===String(w);case(a?.[Symbol.proxy]&&f):return a[Symbol.proxy];case M:return f?"NaN":e({trial:P=>String(w)})===String(a);case I:return f?"Infinity":e({trial:P=>String(w)})===String(a);case c:return f?String(a):String(w)===String(a);case N===Boolean:return l?N===l:"Boolean";default:return p(a,l,f,s(a,N))}}function s(a,l){return a===0?Number:a===""?String:a?l:{name:String(a)}}function u(a,...l){let c=l.length<1,f=!c&&l[0],w=!c&&g(l[0]),N=a==null,M=!N&&Object.getPrototypeOf(a)?.constructor,I=e({trial:P=>String(a)})==="NaN",Z=e({trial:P=>String(a)})==="Infinity";return{noInput:N,noShouldbe:c,compareTo:f,inputCTOR:M,isNaN:I,isInfinity:Z,shouldBeFirstElementIsNothing:w}}function p(a,l,c,f){switch(!0){case(!c&&l===a||a?.[Symbol.proxy]&&l===Proxy):return!0;case e({trial:w=>String(l)})==="NaN":return String(a)==="NaN";case(a?.[Symbol.toStringTag]&&r(l,String)):return String(l)===a[Symbol.toStringTag];default:return l?e({trial:w=>a instanceof l})||l===f||l===Object.getPrototypeOf(f)||`${l?.name}`===f?.name:a?.[Symbol.toStringTag]&&`[object ${a?.[Symbol.toStringTag]}]`||f?.name||String(f)}}function y(a,...l){return l.some(c=>r(a,c))}function g(a,l=!1){let c=a==null;return c=l?c||r(a,1/0)||r(a,NaN):c,c}function S(){let a=(l,c)=>l?.constructor===Function?l(c):void 0;return function({trial:l,whenError:c=()=>{}}={}){try{return a(l)}catch(f){return a(c,f)}}}function h(){return function(a){return Object.freeze({get value(){return a},get[Symbol.type](){return o(a)},get type(){return o(a)},[Symbol.is](...l){return r(a,...l)},is(...l){return r(a,...l)}})}}function v(a,{defaultValue:l,isTypes:c=[void 0],notTypes:f}={}){return c=c?.constructor!==Array?[c]:c,f=f&&f?.constructor!==Array?[f]:[],f.length<1?r(a,...c)?a:l:b(a,{isTypes:c,notTypes:f})?a:l}function b(a,{isTypes:l=[void 0],notTypes:c=[void 0]}={}){return l=l?.constructor!==Array?[l]:l,c=c?.constructor!==Array?[c]:c,r(a,...l)&&!r(a,...c)}function m(){Object.getOwnPropertyDescriptors(Object.prototype)[Symbol.is]||(Object.defineProperties(Object.prototype,{[Symbol.type]:{get(){return o(this)},enumerable:!1,configurable:!1},[Symbol.is]:{value:function(...a){return r(this,...a)},enumerable:!1,configurable:!1}}),Object.defineProperties(Object,{[Symbol.type]:{value(a){return o(a)},enumerable:!1,configurable:!1},[Symbol.is]:{value:function(a,...l){return r(a,...l)},enumerable:!1,configurable:!1}}))}function x(a){let l=String(Object.getPrototypeOf(a)?.constructor);return l.slice(l.indexOf("ion")+3,l.indexOf("(")).trim()}function T(a){let l=a.set;return a.set=(c,f,w)=>f===Symbol.proxy?c[f]=w:l(c,f,w),a}function A(){let a=Proxy;return{native(){Proxy=a},custom(){Proxy=new a(a,{construct(l,c){for(let w of c)w.set&&(w=T(w));let f=new l(...c);return f[Symbol.proxy]=`Proxy (${x(c[0])})`,f}})}}}}var ln=cn(),Se=sn(),ee=un();function sn(){return{html:Object.freeze("accept,action,align,alt,autocapitalize,autocomplete,autopictureinpicture,autoplay,background,bgcolor,border,capture,cellpadding,cellspacing,checked,cite,class,clear,contenteditable,color,cols,colspan,controls,controlslist,coords,crossorigin,datetime,decoding,default,dir,disabled,disablepictureinpicture,disableremoteplayback,download,draggable,enctype,enterkeyhint,face,for,headers,height,hidden,high,href,hreflang,id,inputmode,integrity,is,ismap,kind,label,lang,list,loading,loop,low,max,maxlength,media,method,min,minlength,multiple,muted,name,nonce,noshade,novalidate,nowrap,open,optimum,pattern,placeholder,playsinline,poster,preload,pubdate,radiogroup,readonly,rel,required,rev,reversed,role,rows,rowspan,spellcheck,scope,selected,shape,size,sizes,span,srclang,start,src,srcset,step,style,summary,tabindex,target,title,translate,type,usemap,valign,value,width,xmlns,slot".split(",")),svg:Object.freeze("accent-height,accumulate,additive,alignment-baseline,ascent,attributename,attributetype,azimuth,basefrequency,baseline-shift,begin,bias,by,class,clip,clippathunits,clip-path,clip-rule,color,color-interpolation,color-interpolation-filters,color-profile,color-rendering,cx,cy,d,dx,dy,diffuseconstant,direction,display,divisor,dur,edgemode,elevation,end,fill,fill-opacity,fill-rule,filter,filterunits,flood-color,flood-opacity,font-family,font-size,font-size-adjust,font-stretch,font-style,font-variant,font-weight,fx,fy,g1,g2,glyph-name,glyphref,gradientunits,gradienttransform,height,href,id,image-rendering,in,in2,k,k1,k2,k3,k4,kerning,keypoints,keysplines,keytimes,lang,lengthadjust,letter-spacing,kernelmatrix,kernelunitlength,lighting-color,local,marker-end,marker-mid,marker-start,markerheight,markerunits,markerwidth,maskcontentunits,maskunits,max,mask,media,method,mode,min,name,numoctaves,offset,operator,opacity,order,orient,orientation,origin,overflow,paint-order,path,pathlength,patterncontentunits,patterntransform,patternunits,points,preservealpha,preserveaspectratio,primitiveunits,r,rx,ry,radius,refx,refy,repeatcount,repeatdur,restart,result,rotate,scale,seed,shape-rendering,specularconstant,specularexponent,spreadmethod,startoffset,stddeviation,stitchtiles,stop-color,stop-opacity,stroke-dasharray,stroke-dashoffset,stroke-linecap,stroke-linejoin,stroke-miterlimit,stroke-opacity,stroke,stroke-width,style,surfacescale,systemlanguage,tabindex,targetx,targety,transform,text-anchor,text-decoration,text-rendering,textlength,type,u1,u2,unicode,values,viewbox,visibility,version,vert-adv-y,vert-origin-x,vert-origin-y,width,word-spacing,wrap,writing-mode,xchannelselector,ychannelselector,x,x1,x2,xmlns,y,y1,y2,z,zoomandpan".split(","))}}function un(){return{a:!0,area:!0,audio:!1,br:!0,base:!0,body:!0,button:!0,canvas:!0,comment:!0,dl:!0,data:!0,datalist:!0,div:!0,em:!0,embed:!1,fieldset:!0,font:!0,footer:!0,form:!1,hr:!0,head:!0,header:!0,output:!0,iframe:!1,frameset:!1,img:!0,input:!0,li:!0,label:!0,legend:!0,link:!0,map:!0,mark:!0,menu:!0,media:!0,meta:!0,nav:!0,meter:!0,ol:!0,object:!1,optgroup:!0,option:!0,p:!0,param:!0,picture:!0,pre:!0,progress:!1,quote:!0,script:!1,select:!0,source:!0,span:!0,style:!0,caption:!0,td:!0,col:!0,table:!0,tr:!0,template:!1,textarea:!0,time:!0,title:!0,track:!0,details:!0,ul:!0,video:!0,del:!0,ins:!0,slot:!0,blockquote:!0,svg:!0,dialog:!0,summary:!0,main:!0,address:!0,colgroup:!0,tbody:!0,tfoot:!0,thead:!0,th:!0,dd:!0,dt:!0,figcaption:!0,figure:!0,i:!0,b:!0,code:!0,h1:!0,h2:!0,h3:!0,h4:!0,abbr:!0,bdo:!0,dfn:!0,kbd:!0,q:!0,rb:!0,rp:!0,rt:!0,ruby:!0,s:!0,strike:!0,samp:!0,small:!0,strong:!0,sup:!0,sub:!0,u:!0,var:!0,wbr:!0,nobr:!0,tt:!0,noscript:!0}}function cn(){return["::backdrop{background-color:grey;opacity:0.2;}",`#jqxPopup{overflow:hidden;background-color:transparent;outline:none;border:none;inset:0;animation:fade-out 0.5s ease-out;&[open]{display:flex;align-items:center;justify-content:center;animation:fade-in 0.5s ease;}#jqxPopupContent{background-color:white;border:solid 1px #eee;box-shadow:1px 2px 8px #999;border-radius:4px;padding:12px;vertical-align:middle;max-height:40vh;max-width:50vw;overflow:auto;margin:0 auto;div:not(#closeHandleIcon){clear:both;}@media (width <= 640px){max-width:80vw;max-height:60vh;}#closeHandleIcon{cursor:pointer;width:24px;height:24px;display:inline;position:absolute;top:4px;right:4px;justify-content:right;background-image:url("data:image/svg+xml;utf8,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22iso-8859-1%22%3F%3E%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20xmlns%3Axlink%3D%22http%3A%2F%2Fwww.w3.org%2F1999%2Fxlink%22%20version%3D%221.1%22%20id%3D%22Layer_1%22%20x%3D%220px%22%20y%3D%220px%22%20viewBox%3D%220%200%20128%20128%22%20style%3D%22enable-background%3Anew%200%200%20128%20128%3B%22%20xml%3Aspace%3D%22preserve%22%3E%3Crect%20x%3D%22-368%22%20y%3D%226%22%20style%3D%22display%3Anone%3Bfill%3A%23E0E0E0%3B%22%20width%3D%22866%22%20height%3D%221018%22%2F%3E%3Ccircle%20style%3D%22fill%3A%23FFFFFF%3B%22%20cx%3D%2264%22%20cy%3D%2264%22%20r%3D%2248%22%2F%3E%3Ccircle%20style%3D%22fill%3A%238CCFB9%3B%22%20cx%3D%2264%22%20cy%3D%2264%22%20r%3D%2239%22%2F%3E%3Ccircle%20style%3D%22fill%3Anone%3Bstroke%3A%23444B54%3Bstroke-width%3A6%3Bstroke-miterlimit%3A10%3B%22%20cx%3D%2264%22%20cy%3D%2264%22%20r%3D%2248%22%2F%3E%3Cpolyline%20style%3D%22fill%3Anone%3Bstroke%3A%23FFFFFF%3Bstroke-width%3A6%3Bstroke-linecap%3Around%3Bstroke-miterlimit%3A10%3B%22%20points%3D%2242%2C69%2055.55%2C81%20%20%2086%2C46%20%22%2F%3E%3C%2Fsvg%3E");@media (width <= 640px){background-image:none;position:relative;margin:-15px -15px 4px 0;float:right;vertical-align:middle;border:1px solid #AAA;padding:2px;border-radius:50%;width:12px;height:12px;font-size:12px;line-height:12px;font-weight:bold;text-align:center;&:after{content:'\\2714';color:green;}}}.warn{display:none;text-align:center;color:red;border-top:1px solid #999;margin-top:1em;padding-top:3px;animation:warn-fade-out 0.2s ease-out;}.warn.active{opacity:1;display:block;animation:warn-fade-in 0.2s ease-in;}}}`,"@keyframes fade-in{0%{opacity:0;transform:scale(0, 0);display:none;}100%{opacity:1;transform:scale(1, 1);display:flex;}}","@keyframes fade-out{0%{opacity:1;transform:scale(1, 1);display:flex;}100%{opacity:0;transform:scale(0, 0);display:none;}}","@keyframes warn-fade-in{0%{opacity:0;transform:scale(0, 0);display:none;}100%{opacity:1;transform:scale(1,1 );display:block;}}","@keyframes warn-fade-out{0%{opacity:1;transform:scale(1, 1);display:block;}100%{opacity:0;transform:scale(0, 0);display:none;}}"]}var qe={html:"innerHTML",text:"textContent",class:"className"},fn=mn();function mn(){let e={get(t,n){let r=String(n)?.toLowerCase();switch(!0){case r in t:return t[r];case vn(r):return Be(t,r,n);default:return Be(t,r,n,!0)}},enumerable:!1,configurable:!1};return new Proxy({},e)}function Be(e,t,n,r=!1){return Object.defineProperty(e,t,{get(){return r?o=>Sn(n):$n(t)}}),e[t]}function dn(e,t,n){return t=t?.isJQx&&t.first()||t,on({trial:r=>xn(t)?e.append(t):it(t)?e.insertAdjacentHTML("beforeend",t):e.append(t),whenError:r=>console.info(`${n} (for root ${e}) not created, reason
|
|
2
|
+
`,r)})}function gn(e,t,...n){let r=pn(t,e);return n?.forEach(o=>dn(r,o,e)),r}function pn(e,t){switch(e=Ne(t)?bn(e):e?.isJQx?e.first():e,!0){case d(e,String):return G(t,it(e,t)?{html:e}:{text:e});case d(e,Node):return hn(t,e);default:return G(t,e)}}function yn(e){return delete e.data,Object.keys(e).length<1||Object.keys(e).forEach(t=>{let n=t.toLowerCase();n in qe&&(e[qe[n]]=e[t],delete e[t])}),e}function hn(e,t){let n=G(e);return n.append(t),n}function G(e,t={}){t=ot(t,{});let n=Object.entries(t.data??{}),r=Object.assign(Ne(e)?new Comment(t?.text):document.createElement(e),yn(t));return n.length&&n.forEach(([o,i])=>r.dataset[o]=String(i)),r}function ot(e,t){return t?d(e,{isTypes:Object,notTypes:[Array,null,NaN,Proxy],defaultValue:t}):d(e,{isTypes:Object,notTypes:[Array,null,NaN,Proxy]})}function bn(e){return ot(e)?e?.text??e?.textContent??"":String(e)}function Sn(e){return G("b",{style:"color:red",text:`'${e}' is not a valid HTML-tag`})}function it(e,t){return!Ne(t)&&d(e,String)&&/<.*>|&[#|0-9a-z]+[^;];/i.test(e)}function xn(e){return e?.constructor===Comment||e?.constructor===CharacterData}function Ne(e){return e?.constructor===Comment||/comment/i.test(e)}function vn(e){return!d(G(e),HTMLUnknownElement)}function $n(e){return(t,...n)=>gn(e,t,...n)}var{IS:oe,maybe:Io,$Wrap:Zo,xProxy:Po,isNothing:Fo}=wn();function wn(){Symbol.proxy=Symbol.for("toa.proxy"),Symbol.is=Symbol.for("toa.is"),Symbol.type=Symbol.for("toa.type"),Symbol.isSymbol=Symbol.for("toa.isASymbol"),m();let e=S(),[t,n]=[h(),A()];return n.custom(),{IS:r,maybe:e,$Wrap:t,isNothing:g,xProxy:n};function r(a,...l){if(e({trial:f=>"isTypes"in(l?.[0]??{})})){let f=l[0];return"defaultValue"in f?v(a,f):"notTypes"in f?b(a,f):r(a,...[f.isTypes].flat())}let c=typeof a=="symbol"?Symbol.isSymbol:a;return l.length>1?y(c,...l):i(a,...l)}function o(a){return a?.[Symbol.proxy]??r(a)}function i(a,...l){let{noInput:c,noShouldbe:f,compareTo:w,inputCTOR:N,isNaN:M,isInfinity:I,shouldBeFirstElementIsNothing:Z}=u(a,...l);switch(l=l.length&&l[0],!0){case Z:return String(a)===String(w);case(a?.[Symbol.proxy]&&f):return a[Symbol.proxy];case M:return f?"NaN":e({trial:P=>String(w)})===String(a);case I:return f?"Infinity":e({trial:P=>String(w)})===String(a);case c:return f?String(a):String(w)===String(a);case N===Boolean:return l?N===l:"Boolean";default:return p(a,l,f,s(a,N))}}function s(a,l){return a===0?Number:a===""?String:a?l:{name:String(a)}}function u(a,...l){let c=l.length<1,f=!c&&l[0],w=!c&&g(l[0]),N=a==null,M=!N&&Object.getPrototypeOf(a)?.constructor,I=e({trial:P=>String(a)})==="NaN",Z=e({trial:P=>String(a)})==="Infinity";return{noInput:N,noShouldbe:c,compareTo:f,inputCTOR:M,isNaN:I,isInfinity:Z,shouldBeFirstElementIsNothing:w}}function p(a,l,c,f){switch(!0){case(!c&&l===a||a?.[Symbol.proxy]&&l===Proxy):return!0;case e({trial:w=>String(l)})==="NaN":return String(a)==="NaN";case(a?.[Symbol.toStringTag]&&r(l,String)):return String(l)===a[Symbol.toStringTag];default:return l?e({trial:w=>a instanceof l})||l===f||l===Object.getPrototypeOf(f)||`${l?.name}`===f?.name:a?.[Symbol.toStringTag]&&`[object ${a?.[Symbol.toStringTag]}]`||f?.name||String(f)}}function y(a,...l){return l.some(c=>r(a,c))}function g(a,l=!1){let c=a==null;return c=l?c||r(a,1/0)||r(a,NaN):c,c}function S(){let a=(l,c)=>l?.constructor===Function?l(c):void 0;return function({trial:l,whenError:c=()=>{}}={}){try{return a(l)}catch(f){return a(c,f)}}}function h(){return function(a){return Object.freeze({get value(){return a},get[Symbol.type](){return o(a)},get type(){return o(a)},[Symbol.is](...l){return r(a,...l)},is(...l){return r(a,...l)}})}}function v(a,{defaultValue:l,isTypes:c=[void 0],notTypes:f}={}){return c=c?.constructor!==Array?[c]:c,f=f&&f?.constructor!==Array?[f]:[],f.length<1?r(a,...c)?a:l:b(a,{isTypes:c,notTypes:f})?a:l}function b(a,{isTypes:l=[void 0],notTypes:c=[void 0]}={}){return l=l?.constructor!==Array?[l]:l,c=c?.constructor!==Array?[c]:c,r(a,...l)&&!r(a,...c)}function m(){Object.getOwnPropertyDescriptors(Object.prototype)[Symbol.is]||(Object.defineProperties(Object.prototype,{[Symbol.type]:{get(){return o(this)},enumerable:!1,configurable:!1},[Symbol.is]:{value:function(...a){return r(this,...a)},enumerable:!1,configurable:!1}}),Object.defineProperties(Object,{[Symbol.type]:{value(a){return o(a)},enumerable:!1,configurable:!1},[Symbol.is]:{value:function(a,...l){return r(a,...l)},enumerable:!1,configurable:!1}}))}function x(a){let l=String(Object.getPrototypeOf(a)?.constructor);return l.slice(l.indexOf("ion")+3,l.indexOf("(")).trim()}function T(a){let l=a.set;return a.set=(c,f,w)=>f===Symbol.proxy?c[f]=w:l(c,f,w),a}function A(){let a=Proxy;return{native(){Proxy=a},custom(){Proxy=new a(a,{construct(l,c){for(let w of c)w.set&&(w=T(w));let f=new l(...c);return f[Symbol.proxy]=`Proxy (${x(c[0])})`,f}})}}}}var at=Tn;function Tn({styleSheet:e,createWithId:t}={}){let{tryParseAtOrNestedRules:n,ruleExists:r,checkParams:o,sheet:i,removeRules:s,consider:u,currentSheetID:p}=On({styleSheet:e,createWithId:t});function y(b,m){if(b&&m.removeProperties){Object.keys(m.removeProperties).forEach(x=>b.style.removeProperty(Ve(x)));return}Object.entries(m).forEach(([x,T])=>{x=Ve(x.trim()),T=T.trim();let A;if(/!important/.test(T)&&(T=T.slice(0,T.indexOf("!important")).trim(),A="important"),!CSS.supports(x,T))return console.error(`StylingFactory ${p} error: '${x}' with value '${T}' not supported (yet)`);Ye(()=>b.style.setProperty(x,T,A),`StylingFactory ${p} (setRule4Selector) failed`)})}function g(b,m,x=i){if(b=b?.trim?.(),!oe(b,String)||!b.length||/[;,]$/g.test(b))return console.error(`StylingFactory ${p} (setRules): [${b||"[no selector given]"}] is not a valid selector`);if(m.removeRule)return s(b);let T=r(b,!0),A=T||x.cssRules[x.insertRule(`${b} {}`,x.cssRules.length||0)];return u(()=>y(A,m),b,T)}function S(b){let m=b.trim().split(/{/,2),x=m.shift().trim();if(!oe(x,String)||!x?.trim()?.length)return console.error(`StylingFactory ${p} (doParse): no (valid) selector could be extracted from rule ${xe(b)}`);let T=kn(m.shift());return Ye(()=>g(x,T),`StylingFactory ${p} (setRules) failed`)}function h(b){let m=n(b);return m.done?m.existing:S(b)}function v(b,m){return b.trim().startsWith("@media")?h(Dn(b,m)):g(b,m)}return function(b,m={}){return o(b,m)&&(Object.keys(m).length?v(b,m):h(b))}}function On({styleSheet:e,createWithId:t}){let n="Note: The rule or some of its properties may not be supported by your browser (yet)",r=`for style#${t}`;e=t?o(t):e;function o(h){let v=document.querySelector(`#${h}`)?.sheet;if(v)return v;let b=Object.assign(document.createElement("style"),{id:h});return document.head.insertAdjacentElement("beforeend",b),b.sheet}function i(h){return console.error(`StylingFactory ${r} [rule: ${h}]
|
|
3
|
+
=> @charset, @namespace and @import are not supported here`),{done:!0}}function s(h,v){return[...e.rules].find(b=>v?_e(b.selectorText||"",h):Cn`${Nn(h)}${[..."gim"]}`.test(b.cssText))}function u(h){return/^@charset|@import|namespace/i.test(h.trim())?i(h):h.match(/}/g)?.length>1?{existing:g(h,1),done:!0}:{done:!1}}function p(h){let v=[...e.cssRules].reduce((m,x,T)=>_e(x.selectorText||"",h)&&m.concat(T)||m,[]),b=v.length;return v.forEach(m=>e.deleteRule(m)),b>0?console.info(`\u2714 Removed ${b} instance${b>1?"s":""} of selector ${h} from ${r.slice(4)}`):console.info(`\u2714 Remove rule: selector ${h} does not exist in ${r.slice(4)}`)}function y(h,v){return h&&oe(h,String)&&h.trim().length>0&&oe(v,Object)||(console.error(`StylingFactory ${r} called with invalid parameters`),!1)}function g(h){h=h.trim();let v=h.slice(0,h.indexOf("{")).trim(),b=!!s(v);try{return e.insertRule(`${h}`,e.cssRules.length),b}catch(m){return console.error(`StylingFactory ${r} (tryParse) ${m.name} Error:
|
|
4
|
+
${m.message}
|
|
5
|
+
Rule: ${xe(h)}
|
|
6
|
+
${n}`),b}}function S(h,v,b){try{return h(),b}catch(m){return console.error(`StylingFactory ${r} (tryAddOrModify) ${m.name} Error:
|
|
7
|
+
${m.message}
|
|
8
|
+
Rule: ${xe(v)}
|
|
9
|
+
${n}`),b}}return{sheet:e,removeRules:p,tryParseAtOrNestedRules:u,ruleExists:s,checkParams:y,tryParse:g,consider:S,currentSheetID:r}}function Dn(e,t){return`${e.trim()} ${Object.entries(t).map(([n,r])=>`${n}: { ${jn(r)}`)}`}function xe(e){let t=(e||"NO RULE").trim().slice(0,50).replace(/\n/g,"\\n").replace(/\s{2,}/g," ");return e.length>t.length?`${t.trim()}...truncated`:t}function jn(e){return Object.entries(e).map(([t,n])=>`${t}: ${n.trim()}`).join(`;
|
|
10
|
+
`)}function Nn(e){return e.replace(/([*\[\]()-+{}.$?\\])/g,t=>`\\${t}`)}function Cn(e,...t){let n=t.length&&Array.isArray(t.slice(-1))?t.pop().join(""):"";return new RegExp((t.length&&e.raw.reduce((r,o,i)=>r.concat(t[i-1]||"").concat(o),"")||e.raw.join("")).split(`
|
|
11
|
+
`).map(r=>r.replace(/\s|\/\/.*$/g,"").trim().replace(/(@s!)/g," ")).join(""),n)}function Ve(e){return e.replace(/[A-Z]/g,t=>`-${t.toLowerCase()}`).replace(/[^--]^-|-$/,"")}function Ye(e,t){try{return e()}catch(n){console.error(`${t||"an error occured"}: ${n.message}`)}}function An(e){return e.replace(/\/\*.+?\*\//gm,"").replace(/[}{\r\n]/g,"").replace(/(data:.+?);/g,(t,n)=>`${n}\\3b`).split(";").map(t=>t.trim()).join(`;
|
|
12
12
|
`).replaceAll("\\3b",";").split(`
|
|
13
|
-
`)}
|
|
14
|
-
`)),
|
|
15
|
-
`)),
|
|
16
|
-
`));default:return n}}return l(i,"log"),Object.defineProperties(n,{log:{value:i,enumerable:!1},error:{value:r,enumerable:!1},warn:{value:o,enumerable:!1}}),Object.freeze(n)}l(Gt,"systemLogFactory");function ce(){return(e=>`[${X(e.getHours())}:${X(e.getMinutes())}:${X(e.getSeconds())}.${X(e.getMilliseconds(),3)}]`)(new Date)}l(ce,"logTime");function Kt(e,t){if(e)for(let[n,r]of Object.entries(t)){if(n=R(n),n.startsWith("data"))return Ge(e,r);p(r,String)&&Ye(n)&&e.setAttribute(n,r.split(/[, ]/)?.join(" "))}}l(Kt,"assignAttrValues");function Ge(e,t){if(e&&p(t,Object))for(let[n,r]of Object.entries(t))e.setAttribute(`data-${R(n)}`,r)}l(Ge,"setData");function Ke(e){return e?p(e,Proxy)?[e.EL]:p(e,NodeList)?[...e]:W(e)?[e]:we(e)?e:e.isJQx?e.collection:void 0:[]}l(Ke,"input2Collection");function ze(e,t){return e.andThen(t)}l(ze,"after");function He(e,t){return e.andThen(t,!0)}l(He,"before");function W(e){return p(e,Text,HTMLElement,Comment)}l(W,"isNode");function ue(e,t){if(p(t,Object))for(let[n,r]of Object.entries(t)){let o;/!important/i.test(r)&&(r=r.slice(0,r.indexOf("!")).trim(),o="important"),e.style.setProperty(R(n),r,o)}}l(ue,"applyStyle");function U(e){let t=e.cloneNode(!0);return t.removeAttribute&&t.removeAttribute("id"),e.isConnected?e.remove():e=null,t}l(U,"cloneAndDestroy");function Xt(e){if(!e)return;let t=e.style,n=getComputedStyle(e),r=[t.visibility,n.visibility].includes("hidden"),o=[t.display,n.display].includes("none"),i=e.hidden,c=e.offsetTop<0||e.offsetLeft+e.offsetWidth<0||e.offsetLeft>document.body.offsetWidth,u=+n.opacity==0||+(t.opacity||1)==0;return!(i||c||u||o||r)}l(Xt,"isVisible");function en(e){return e?.isConnected?!![...document.querySelectorAll(":is(:read-write)")].find(t=>t===e):!1}l(en,"isWritable");function tn(e){return e?.filter(t=>t).reduce((t,n)=>t.concat(et(n)?`<!--${n.data}-->`:xe(n)?n.textContent:n.outerHTML),"")}l(tn,"ElemArray2HtmlString");function X(e,t=2){return`${e}`.padStart(t,"0")}l(X,"pad0");function nn(e,t=0){return[e,t]=[Math.floor(e),Math.ceil(t)],Math.floor([...crypto.getRandomValues(new Uint32Array(1))].shift()/2**32*(e-t+1)+t)}l(nn,"randomNr");function Xe(){return`_${ln(jr).slice(0,8).join("")}`}l(Xe,"randomString");function rn(e){return e=p(e,String)&&/,/.test(e)?e.split(",").map(t=>t.trim().toLowerCase()).filter(t=>t.length>0):e,p(e,Array)?e:p(e,String)&&e?.trim().toLowerCase()||""}l(rn,"resolveEventTypeParameter");function on(e){return e?.isConnected?!![...document.querySelectorAll(":is(:modal)")].find(t=>t===e):!1}l(on,"isModal");function an(e,t){switch(e=String(e).trim(),!0){case/^(0|false|f)$/i.test(e):return!1;case/^(1|true|t)$/i.test(e):return!0;default:return t}}l(an,"convert2Bool");function ln(e){let t=e.length;for(;t--;){let n=nn(t);[e[t],e[n]]=[e[n],e[t]]}return e}l(ln,"shuffle");function Se(e){return p(e,String)?e.toLowerCase().split("-").map((t,n)=>n&&`${sn(t)}`||t).join(""):e}l(Se,"toCamelcase");function R(e){return e.replace(/[A-Z]/g,t=>`-${t.toLowerCase()}`).replace(/^-|-$/,"")}l(R,"toDashedNotation");function sn([e,...t]){return`${e.toUpperCase()}${t.join("")}`}l(sn,"ucFirst");function xe(e){return p(e,Comment,Text)}l(xe,"isCommentOrTextNode");function et(e){p(e,Comment)}l(et,"isComment");function cn(e){return p(e,Text)}l(cn,"isText");function ve(e){return p(e,String)&&/^<|>$/.test(`${e}`.trim())}l(ve,"isHtmlString");function we(e){return p(e,Array)&&!e?.find(t=>!W(t))}l(we,"isArrayOfHtmlElements");function tt(e){return p(e,Array)&&!e?.find(t=>!ve(t))}l(tt,"isArrayOfHtmlStrings");function D(e,t){let n=e.collection.filter(r=>!xe(r));for(let r=0;r<n.length;r+=1)t(n[r],r);return e}l(D,"loop");function nt(e,t,n){let r=t!==document.body&&p(e,String)&&e.toLowerCase()!=="body"?t:document,o;try{n.collection=[...r.querySelectorAll(e)]}catch{o=`JQx: Invalid CSS querySelector. [${p(e,String)?e:"Not a string!"}]`}let i=n.collection.length;return i<1?`CSS querySelector "${e}", output: nothing`:o??`CSS querySelector "${e}", output ${i} element${i>1?"s":""}`}l(nt,"setCollectionFromCssSelector");function un(){return{isCommentOrTextNode:xe,isNode:W,isComment:et,isText:cn,isHtmlString:ve,isArrayOfHtmlElements:we,isArrayOfHtmlStrings:tt,ElemArray2HtmlString:tn,input2Collection:Ke,setCollectionFromCssSelector:nt,cssRuleEdit:At({createWithId:"JQxStylesheet"})}}l(un,"selectedFactoryHelpers");function mn(){let e=Object.freeze({notInDOM:"n/a",writable:"n/a",modal:"n/a",empty:!0,open:"n/a",visible:"n/a"});return t=>{let n=t.node;return p(n,Node)?Object.freeze({get writable(){return en(n)},get modal(){return on(n)},get inDOM(){return n.isConnected},get open(){return n.open??!1},get visible(){return Xt(n)},get disabled(){return n.hasAttribute("readonly")||n.hasAttribute("disabled")},get empty(){return t.collection.length<1},get virtual(){return t.isVirtual}}):e}}l(mn,"ExamineElementFeatureFactory");function dn(e,t,n,r){n&&p(t,String)&&(t={[t]:n==="-"?"":n});let o;t.className&&(o=t.className,delete t.className),o=[...e.classList].find(i=>i.startsWith("JQxClass-")||o&&i===o)||o||`JQxClass-${Xe().slice(1)}`,r.editCssRule(`.${o}`,t),e.classList.add(o)}l(dn,"css");var Ar=mn();function fn(e){return{factoryExtensions:gn(e),instanceExtensions:pn(e)}}l(fn,"default");function gn(e){return{data(t){return{get all(){return new Proxy(t[0]?.dataset??{},Er)},set(n={}){if(!t.is.empty&&p(n,Object))for(let[r,o]of Object.entries(n))t.setData({[r]:o});return t},get(n,r){return t.data.all[n]??r},add(n={}){if(!t.is.empty&&p(n,Object))for(let[r,o]of Object.entries(n))t.setData({[r]:o});return t},remove(n){return t[0]?.removeAttribute(`data-${R(n)}`),t}}},dimensions(t){if(t.is.empty)return L.error("[JQx instance].dimensions called on empty instance"),{error:"[JQx instance].dimensions: NO ELEMENTS"};let{node:n}=t,r=n.getBoundingClientRect().toJSON();return r.scrollTopDistance=ge(n,0),r.scrollLeftDistance=ge(n,0,!1),r},node(t){return t[0]},HTML(t){return{get(n,r){if(t.is.empty)return"NO ELEMENTS IN COLLECTION";let o=n?t.outerHtml:t.html();return r?ne(o):o},set(n,r=!1,o=!1){n=n.isJQx?n.HTML.get(1):n;let i=p(n,String);return n=i&&o?ne(n):n,i&&(n||"").trim().length&&t.html(n,r),t},replace(n,r=!1){return t.HTML.set(n,!1,r)},append(n,r=!1){return n=p(n,HTMLElement)?e(n).HTML.get(1):n.isJQx?n.HTML.get(1):n,t.HTML.set(n,!0,r)},insert(n,r=!1){return n=p(n,HTMLElement)?e(n).HTML.get(1):n.isJQx?n.HTML.get(1):n,t.HTML.set(n+t.HTML.get(),!1,r)}}},is(t){return Ar(t)},length(t){return t.collection.length},outerHtml(t){return(t.first()||{outerHTML:void 0}).outerHTML},parent(t){let n=e(t[0]?.parentNode);return n.is.empty?t:n},render(t){switch(!0){case!t.is.empty:return t.toDOM();default:return e.logger.warn("[JQx.render]: empty collection"),t}},Style(t){return{get computed(){return t.is.empty?{}:getComputedStyle(t[0])},inline(n){return t.style(n)},inSheet(n){return t.css(n)},valueOf(n){return t.is.empty?void 0:getComputedStyle(t[0])[R(n)]},nwRule(n){return t.Style.byRule({rules:n})},byRule({classes2Apply:n=[],rules:r=[]}={}){let o=p(r,String)&&!n.length?r.split("{")[0].trim():"";if(r=r&&p(r,String)?[r]:r,n=n&&p(n,String)?[n]:n,(r?.length||n?.length)&&(r?.length&&e.editCssRules(...r),n))for(let i of n)t.addClass(i);return o?.startsWith(".")&&t.addClass(o.slice(1)),o?.startsWith("#")&&!t.attr("id")&&t.prop({id:o.slice(1)}),t}}}}}l(gn,"factoryExtensionsFactory");function pn(e){return{addClass(t,...n){return D(t,r=>r&&n.forEach(o=>r.classList.add(o)))},after:ze,afterMe:ze,andThen(t,n,r=!1){if(!n||!p(n,String,Node,Proxy))return L.log("[JQx instance].[before(Me) | after(Me) | andThen]: invalid/-sufficient input."),t;n=n?.isJQx?n:p(n,Node)?e.virtual(n):e.virtual(Q(n));let[o,i,c]=r?[0,"before",n.collection.concat(t.collection)]:[t.collection.length-1,"after",t.collection.concat(n.collection)];return t[o][i](...n.collection),t.collection=c,t},append(t,...n){if(t.is.empty||n.length<1)return t;let r=t.length===1;for(let o of n){if(!o.isJQx&&E(o)){let i=o.trim(),c=/^<(.+)[^>]+>$/m.test(i)?Q(o):e.text(o);D(t,u=>u.append(r?c:U(c)))}W(o)&&D(t,i=>i.append(r?o:U(o))),o.isJQx&&!o.is.empty&&D(t,i=>o.collection.forEach(c=>i.append(r?c:U(c))))}return t},appendTo(t,n){switch(!0){case(!n.isJQx&&!p(n,HTMLElement)):return $.warn("[JQx instance].appendTo: invalid input"),t;default:return(n.isJQx?n:e(n)).append(t),t}},attr(t,n,r){if(!t.node)return t;if(!r&&E(n))return n=R(n),n==="class"?[...t.node.classList].join(" "):t.node.getAttribute(n);if(E(n)&&r)switch(n=R(n),!0){case n.startsWith("data-"):n={data:{[n.replace("data-","")]:r}};break;default:n={[n]:r}}return p(n,Object)&&!t.is.empty&&Kt(t.node,n),t},before:He,beforeMe:He,clear(t){return D(t,Pe)},closest(t,n){let r=E(n)?t.node?.closest(n):void 0;return r?e(r):t},computedStyle(t,n){let{node:r}=t;return r&&getComputedStyle(r)[n]},css(t,n,r){return D(t,o=>dn(o,n,r,e))},duplicate(t,n=!1,r=document.body){switch(!0){case t.is.empty:return L.error("Duplicating an empty JQx instance is not possible"),t;default:let o=t.collection[0].cloneNode(!0);return o.childNodes.forEach(i=>{i.removeAttribute&&i?.removeAttribute("id")}),n?e(o).toDOM(r):e.virtual(o)}},each(t,n){return D(t,n)},empty(t){return D(t,Pe)},find(t,n){return t.collection.length>0?[...t.first()?.querySelectorAll(n)]:[]},find$(t,n){return t.collection.length>0?e(n,t):t},first(t,n=!1){return t.collection.length>0?n?t.single():t.collection[0]:void 0},first$(t,n){return t.single(n)},getData(t,n,r){return t.node?.dataset?.[n]||r},hasClass(t,...n){return t.is.empty||!t.node.classList.length?!1:n.find(r=>t.node.classList.contains(r))&&!0||!1},hide(t){return D(t,n=>ue(n,{display:"none !important"}))},html(t,n,r){switch(!0){case(t.is.empty&&!E(n)):return"";case!E(n):return t.node?.getHTML()??"";default:let o=Q(`<div>${n.isJQx?n.HTML.get(!0):n}</div>`);return D(t,l(i=>(i.textContent=r?i.textContent:"",i.insertAdjacentHTML(e.at.end,o.getHTML())),"cb"))}},htmlFor(t,n,r="",o=!1){if(t.is.empty||!E(n)||!E(r))return t;let i=t.find$(n);if(i.length<1)return t;let c=Q(`<span>${r}</span>`);return i.each(u=>{o||(u.textContent=""),u.insertAdjacentHTML(e.at.end,c?.getHTML())}),t},isEmpty(t){return!t.node},nth$(t,n){return t.single(n)},on(t,n,...r){switch(!0){case(t.is.empty||!p(n,String,Array)||!E(n)||r.length<1):return t;default:return e.handle({type:n,node:t.node,handler:r}),t}},once(t,n,...r){switch(!0){case(t.is.empty||!p(n,String,Array)||!E(n)||r.length<1):return t;default:return e.handle({type:n,once:!0,node:t.node,handler:r}),t}},prepend(t,...n){if(t.is.empty||!n)return;let r=t.length===1;for(let o of n){if(E(o)){o=o.trim();let i=/^<(.+)[^>]+>$/m.test(o)?Q(o):e.text(o);i=r?i:U(i),D(t,c=>c.prepend(i.cloneNode(!0)))}W(o)&&D(t,i=>i.prepend(r?o:U(o))),o.isJQx&&!o.is.empty&&(o.collection.length>1&&o.collection.reverse(),D(t,i=>D(o,c=>i.prepend(r?c:U(c)))),o.collection.reverse())}return t},prependTo(t,n){return n.isJQx||(n=e.virtual(n)),n.prepend(t),t},prop(t,n,r){if(p(n,String)&&!r)return n.startsWith("data")?t[0]?.dataset[n.slice(n.indexOf("-")+1)]:t[0]?.[n];let o=p(n,Object)?n:{[n]:r};for(let[i,c]of Object.entries(o)){if(i=i.trim(),c&&!Ye(i)||!c)return!1;if(i.toLowerCase()==="id")return t[0].id=c;D(t,u=>{if(i.startsWith("data"))return u.dataset[i.slice(i.indexOf("-")+1)]=c;u[i]=c})}return t},remove(t,n){let r=l(i=>i.remove(),"remover"),o=l(()=>t.collection=t.collection.filter(i=>document.documentElement.contains(i)),"removeFromCollection");if(n){let i=t.find$(n);return i.is.empty||(D(i,r),o()),t}return D(t,r),o(),t},rmAttr(t,...n){for(let r of n)t.node.removeAttribute(r);return t},removeClass(t,...n){return D(t,r=>{if(r)for(let o of n)r.classList.remove(o)})},renderTo(t,n,r){return n=p(n,HTMLElement)||n.isJQx?n:document.body,r=p(r,String)&&e.at[r]?r:e.at.end,t.first$().toDOM(n,r),t},replace(t,n,r){let o=t.node;return!n||!p(r,HTMLElement)&&!r?.isJQx?(e.logger.error("JQx replace: invalid replacement value"),t):((r.isJQx||p(r,NodeList))&&(r=r[0]),o&&n&&(n=p(n,String)?o.querySelectorAll(n):n.isJQx?n.collection:n,p(n,HTMLElement,NodeList,Array)&&p(r,HTMLElement)&&(p(n,HTMLElement)?[n]:[...n]).forEach(i=>i.replaceWith(r.cloneNode(!0)))),t)},replaceClass(t,n,...r){return D(t,o=>{o.classList.remove(n);for(let i of r)o.classList.add(i)})},replaceMe(t,n){return t.replaceWith(n)},replaceWith(t,n){return n=p(n,Element)?n:n.isJQx?n[0]:void 0,n&&(t[0].replaceWith(n),t=e.virtual(n)),t},setData(t,n){return D(t,r=>Ge(r,n))},show(t){return D(t,n=>ue(n,{display:"revert-layer !important"}))},single(t,n){let r=t.collection.length>0;switch(n=n??0,!0){case(r&&p(n,String)):return t.find$(n);case(r&&p(n,Number)):return e(t.collection[n]);case r:return t.collection[0];default:return t}},style(t,n,r){return D(t,l(o=>{r&&p(n,String)&&(n={[n]:r||"none"}),ue(o,n)},"loopCollectionLambda"))},text(t,n,r=!1){switch(!0){case t.isEmpty():return t;case!p(n,String):return t.node.textContent;default:return D(t,o=>o.textContent=r?o.textContent+n:n)}},toDOM(t,n=document.body,r=H.BeforeEnd){return t.isVirtual=!1,fe(t.collection,n,r),t},toggleClass(t,n){return D(t,r=>r.classList.toggle(n))},toNodeList(t){return[...t.collection].map(n=>document.importNode(n,!0))},trigger(t,n,r,o){if(r=/Event\]$/.test(p(r))?r:Event,o=p(o,Object)?{...o,bubbles:o.bubbles??!0}:{bubbles:!0},!t.is.empty){let i=new r(n,o);t.each(c=>c.dispatchEvent(i))}return t},val(t,n){switch(!0){case(t.is.empty||!p(t.node,HTMLInputElement,HTMLSelectElement,HTMLTextAreaElement)):return t;case!p(n,String):return t.node.value;default:return t.node.value=p(n,String)?n:"",t}}}}l(pn,"instanceExtensionsFactory");var Re,pe,{isComment:zo,isText:Ho,isHtmlString:Ro,isArrayOfHtmlElements:Jo,isArrayOfHtmlStrings:Qo,ElemArray2HtmlString:Uo,cssRuleEdit:Je,addFn:Lr}=yn();function yn(){return{...un(),addFn:hn}}l(yn,"selectedUtilitiesFactory");function hn(e,t){return e=e?.trim(),!E(e)||!p(t,Function)?L.error("JQx.fn: method invalid parameter(s)"):pe[e]=(n,...r)=>t(n,...r)}l(hn,"addFnMethod");function bn(e){return function(t,n,r){if(t=t?.trim(),!E(t)||!p(n,Function))return e.error("JQx.staticFn: invalid parameter(s)");let o=r?{get(){return n()}}:{value(...i){return n(...i)}};try{Object.defineProperty(e,t,o)}catch{return e.warn(`JQx.staticFn: extension [${t}] already exists`)}return L.log(`JQx: added static extension function [${t}]`)}}l(bn,"staticFNMethodFactory");function ee(e){return new Proxy(e,Object.freeze({get:l((t,n)=>Sn(t,n,e),"get")}))}l(ee,"proxify");function Qe(e,t){return(...n)=>p(e,Function)&&e(ee(t),...n)}l(Qe,"wrap");function Sn(e,t,n){switch(!0){case p(t,Symbol):return e;case p(+t,Number):return e.collection?.[t]||void 0;case t in Re:return Qe(Re[t],n)();case t in pe:return Qe(pe[t],n);default:return e[t]}}l(Sn,"proxyKeyFactory");function xn(e){let t=On(e);for(let[n,r]of Object.entries(Object.getOwnPropertyDescriptors(t)))Object.defineProperty(e,n,r);return e}l(xn,"addJQxStaticMethods");function vn(e){return{allow(t){let n=/-/.test(t),r=n&&t;t=n?Se(t):t.toLowerCase(),te.allowTag(t),Object.defineProperties(e,ye(t,!0,e,r))},prohibit(t){t=t.toLowerCase(),te.prohibitTag(t),Object.defineProperties(e,ye(t,!1,e))}}}l(vn,"allowances");function Ue(...e){if(e.length===1){let t=String(e.shift().trim());e=t.startsWith("!")?[t.slice(1,-1)]:t.split(",").map(n=>n.trim())}for(let t of e.map(n=>n.startsWith("!")?n.slice(1,-1):n))Je(t,{removeRule:1})}l(Ue,"cssRemove");function wn(e){return function(t,n,r){n=n?.isJQx?n?.[0]:n,r=r&&Object.values(H).find(i=>r===i);let o=e(t,document.createElement("br"));if(n&&!p(n,HTMLBRElement))for(let i of o.collection)r?n.insertAdjacentElement(r,i):n.append(i);return o}}l(wn,"virtualFactory");function Tn(...e){let t={};for(let n of e){let r=Object.getOwnPropertyDescriptors(n);for(let[o,i]of Object.entries(r))!(o in t)&&Object.defineProperty(t,o,{...i,enumerable:!1})}return t}l(Tn,"combineObjectSources");function $n(e,t,n,r){return e=R(r||e.toLowerCase()),{get(){return(...o)=>(L.log(t?`JQx: created (virtual) instance from [JQx].${e}`:`JQx: ${e.toUpperCase()} is prohibited. Use [JQx].allowTag if necessary.`),t&&n.virtual(be(Or[e](...o)))||void 0)},enumerable:!1,configurable:!0}}l($n,"tagGetterFactory");function ye(e,t,n,r){e=e.toLowerCase();let o=$n(e,t,n,r);return r?{[r]:o,[Se(r)]:o}:{[e]:o,[e.toUpperCase()]:o}}l(ye,"addGetters");function On(e){return Tn(Object.entries(te.tagsRaw).reduce(Dn(e),{}),Ln(e))}l(On,"defaultStaticMethodsFactory");function Dn(e){return function(t,[n,r]){return Object.defineProperties(t,ye(n,r,e)),t}}l(Dn,"staticTagsLambda");function Cn(e){return function(t,n,...r){p(n,Function)&&(r.push(n),n=void 0),e({type:t,selector:n,handlers:r})}}l(Cn,"delegateFactory");function Nn(e){return function(t){let{type:n,types:r,origin:o,selector:i,handler:c,handlers:u,node:b,name:h,capture:g,once:v,about:y}=t;c=u||c,n=r||n,i=o||i;let w=rn(n),S=h;c=p(c,Function)?[c]:c;let f={type:w,selector:i||o,capture:g,name:S,once:v,node:b,about:y};switch(!0){case(p(w,Array)&&w.length>0):for(let x of w)f.type=x,We(c,f,e);break;default:return We(c,f,e)}}}l(Nn,"delegateCaptureFactory");function We(e,t,n){for(let r of e)n.listen({...t,handler:r})}l(We,"assignListeners");function jn(e){return function(t,n){return n=E(n)&&n,t=E(t)&&t,n&&t&&e.listenerStore[t][n]}}l(jn,"getNamedListenerFactory");function En(e){return e.activePopup||Object.defineProperty(e,"activePopup",{value:qt(e),enumerable:!1}),e.activePopup}l(En,"popupGetter");function An(e){let t=l((u,b)=>Je(u,b),"editCssRule"),n=l(function(u){return At({createWithId:u||`jqx${Xe()}`})},"createStyle"),r=l(function(...u){for(let b of u)Je(b)},"editCssRules"),o=vn(e),i=Vt(e),c=Nn(i);return{editCssRule:t,createStyle:n,editCssRules:r,allowProhibit:o,handle:c,capturedHandling:c,log:l((...u)=>L.on.log(...u).off,"log"),warn:l((...u)=>L.on.warn(...u).off,"warn"),error:l((...u)=>L.on.error(...u).off,"error"),handlerWrapper:i}}l(An,"getSelectedStaticMethods");function Ln(e){let{factoryExtensions:t,instanceExtensions:n}=fn(e);Re=t,pe=n;let{editCssRule:r,createStyle:o,editCssRules:i,allowProhibit:c,handle:u,capturedHandling:b,log:h,warn:g,error:v,handlerWrapper:y}=An(e),w=jn(e),S=bn(e);return{log:h,warn:g,error:v,editCssRules:i,createStyle:o,editStylesheet:o,editCssRule:r,escHtml:ne,logger:L,text(f,x=!1){return x?e.comment(f):document.createTextNode(f)},node(f,x=document){return x.querySelector(f,x)},nodes(f,x=document){return[...x.querySelectorAll(f,x)]},clearAllTimers:Bt,get staticFn(){return function(f,x,O){return S(f,x,O)}},get toBool(){return an},get getNamedListener(){return w},get virtual(){return wn(e)},get allowTag(){return c.allow},get prohibitTag(){return c.prohibit},get removeCssRule(){return Ue},get removeCssRules(){return Ue},get delegate(){return Cn(b)},get delegateCaptured(){return b},get handle(){return b},get listen(){return y.listen},get at(){return H},get setStyle(){return r},get fn(){return Lr},get lenient(){return te.allowUnknownHtmlTags},get IS(){return p},get Popup(){return En(e)},get listenerStore(){return y.ListenerStore}}}l(Ln,"staticMethodsFactory");var Fr=xn(Fn());function Fn(){return function(e,t,n=H.BeforeEnd){if(e?.isJQx)return e;let r=p(t,HTMLBRElement);t=(!r&&t&&t.isJQx?t[0]:t)||document.body,n=n&&Object.values(H).find(h=>n===h)?n:void 0;let o=ve(e),i=!o&&tt(e)||o,c={collection:Ke(e)??[],isVirtual:r,isJQx:!0},u=we(c.collection);if(c.collection.length&&u)return r||c.collection.forEach(h=>{t.contains(h)||fe([h],t,n)}),ee(c);if(i){if([e].flat().forEach(h=>c.collection.push(Q(h))),c.collection.length>0){let h=c.collection.filter(w=>w?.dataset?.jqxcreationerror);c.collection=c.collection.filter(w=>!w?.dataset?.jqxcreationerror);let g=c.collection.map(w=>`${String(w.constructor).split(/function|\(/)[1].trim()}`),v=g.length>1,y=c.collection.length?g.join(", "):"sanitized: no elements remaining";L.log(`JQx: created ${c.isVirtual?"(virtual)":""} instance from ${v?"array of ":""}HTML string${v?"s":""} (${y})`),c.isVirtual||fe(c.collection,t,n)}return ee(c)}let b=nt(e,t,c);return e!==null&&L.log(`JQx: input => ${b}`),ee(c)}}l(Fn,"JQxMainFactory");var J=Fr;var[V,B,ot,it]=["2-digit","numeric","long","short"],Te={fixed:{MM:{month:ot},M:{month:it},m:{month:B},mm:{month:V},yyyy:{year:B},yy:{year:V},WD:{weekday:ot},wd:{weekday:it},d:{day:B},dd:{day:V},h:{hour:B},hh:{hour:V},mi:{minute:B},mmi:{minute:V},s:{second:B},ss:{second:V},ms:{fractionalSecondDigits:3},tz:{timeZoneName:"shortOffset"},dl:{locale:"default"},h12:{hour12:!1},yn:{yearName:""},ry:{relatedYear:!0},msp:{fractionalSecond:!0}},dynamic:{tzn:e=>({timeZoneName:e.slice(4)}),hrc:e=>({hourCycle:`h${e.slice(4)}`}),ds:e=>({dateStyle:e.slice(3)}),ts:e=>({timeStyle:e.slice(3)}),tz:e=>({timeZone:e.slice(3)}),e:e=>({era:e.slice(2)}),l:e=>({locale:e.slice(2)})}},_={...Te,retrieveDynamic(e){let t=e?.slice(0,e?.indexOf(":"));return Te.dynamic[t]&&Te.dynamic[t](e)},get re(){return new RegExp(`\\b(${Object.keys(Te.fixed).join("|")})\\b`,"g")}},Ce=Mr;function Mr(e,t,n="l:default"){return/ds:|ts:/.test(n)?Ir(e,Mn(void 0),n):Pr(e,Mn(t||void 0),n)}function Mn(e="dtf",t=0){let n=` ${e.replace(/(?<=\{)(.+?)(?=})/g,o=>`[${t++}]`).replace(/[{}]/g,"").trim()} `,r=e.match(/(?<=\{)(.+?)(?=})/g)||[];return{get texts(){return r},formatString(o){n=o},set formatStr(o){n=o},get formatStr(){return n},get units(){return n.match(_.re)||[]},finalize(o="",i="",c="",u=""){return n.replace(/~([\d+]?)/g,"$1").replace(/dtf/,o).replace(/era/,c).replace(/dp\b|~dp\b/,i).replace(/yn\b/,u).replace(/\[(\d+?)]/g,(b,h)=>r[h].trim()).trim()}}}function Yn(...e){return e?.reduce((t,n)=>({...t,..._.retrieveDynamic(n)||_.fixed[n]}),_.fixed.dl)}function Ir(e,t,n){let r=Yn(..._n(n).split(",")),o=Intl.DateTimeFormat(r.locale,r).format(e);return t.finalize(o)}function kr(e,t){return e==="numeric"&&t.startsWith("0")?t.slice(1):t}function Pr(e,t,n){let r=Yn(...t.units.concat(_n(n).split(",")).flat()),o={..._.fixed},i=Intl.DateTimeFormat(r.locale,r).formatToParts(e).reduce((c,u)=>u.type==="literal"&&/[ ,/-]/.test(u.value)?c:{...c,[u.type]:kr(r[u.type],u.value)},{});return o.ms=r.fractionalSecondDigits?o.msp:o.ms,o.yyyy=i.relatedYear?o.ry:o.yyyy,t.formatStr=t.formatStr.replace(_.re,c=>/^(M|MM)$/.test(c)?Zr(e,r.locale,r.timeZone,/^M$/.test(c)):i[Object.keys(o[c]).shift()]||c),t.finalize(void 0,i.dayPeriod,i.era,i.yearName)}function Zr(e,t,n,r){return e.toLocaleString(t,{timeZone:n,month:r?it:ot})}function _n(e){return e.replace(/\s+/g,"")}var zr=Hr;function Hr(){let e=(r,o)=>{let i=isNaN(new Date(r)),c=isNaN(new Date(o));if(c){let[u,b,h]=Array(3).fill("end date not valid");return{error:!0,message:u,full:b,clean:h}}if(i){let[u,b,h]=Array(3).fill("start date not valid");return{error:!0,message:u,full:b,clean:h}}if(i&&!c){let[u,b,h]=Array(3).fill("start- and/or end date are not valid");return{error:!0,message:u,full:b,clean:h}}return{error:!1}},t=n();return function({start:r,end:o,diffs:i={}}={}){let c=e(r,o),u=o>r?"+":"-";if(c.error)return c;let b=Math.abs(r-o),h=new Date(b),g=h.getUTCFullYear()-1970,v=h.getUTCMonth(),y=h.getUTCDate()-1,w=y%7,S=Math.floor(y/7),f=h.getUTCHours(),x=h.getUTCMinutes(),O=h.getUTCSeconds(),A=h.getUTCMilliseconds(),a=Math.floor(b/864e5);i={...i,fromUTC:r,toUTC:o,sign:"",years:g,months:v,days:y,hours:f,minutes:x,seconds:O,milliseconds:A,diffInDays:a},i.full=t({values:i,full:!0}),i.clean=t({values:i}),i.equalDates=i.clean==="Dates are equal";let s=f+x+O>0?"T":"";return i.clean!=="Dates are equal"&&(i.sign=u,i.jsPeriod=`${u}P${g>0?`${g}Y`:""}${v>0?`${v}M`:""}${S>0?`${S}W`:""}${w>0?`${w}D`:""}${s}${f>0?`${f}H`:""}${x>0?`${x}M`:""}${O>0?`${O}S`:""}`,i.ISOPeriod=`P${g>0?`${g}Y`:""}${v>0?`${v}M`:""}${y>0?`${y}D`:""}${s}${f>0?`${f}H`:""}${x>0?`${x}M`:""}${O>0?`${O}S`:""}`),i};function n(){let r=(...i)=>c=>i.reduce((u,b)=>b(u),c),o=(i,c)=>i===1?c.slice(0,-1):c;return r(({values:i,full:c})=>[Object.entries(i).filter(([u])=>/^(years|month|days|hours|minutes|seconds)/i.test(u)),c],([i,c])=>c?i:i.filter(([,u])=>c?+u:u>0),i=>i.reduce((c,[u,b])=>[...c,`${b} ${o(b,u)}`],[]),i=>i.length<1?"Dates are equal":`${i.slice(0,-1).join(", ")}${i.length>1?" and ":""}${i.slice(-1).shift()}`)}}var Rr=Jr;function Jr(){let e=Object.entries({year:"FullYear",month:"Month",date:"Date",day:"Date",hour:"Hours",minute:"Minutes",second:"Seconds",millisecond:"Milliseconds"}).reduce((r,[o,i])=>({...r,[o]:i,[`${o}s`]:i}),{}),t=!1,n=function(...r){let o=r.length===1;return t=r[0].trim().startsWith("subtract,"),t&&(r=o?r[0].trim().replace(/^subtract,/i,"").split(",").map(i=>i.trim()):r.filter(i=>!i.startsWith("subtract"))),o&&!t&&(r=r[0].split(",").map(i=>i.trim())),r.map(function(i){if(!i)return!1;let c=i.toLowerCase().split(/ {1,}/);return c.length<2?!1:c.map(u=>{u=`${u}`.trim().replace(/[^a-z0-9-+]/g,"");let b=parseInt(u,10);return Number.isNaN(b)?u:t?-b:+b})}).filter(i=>i)};return function(r,...o){if(o.length<1)return r;let i=n(...o);return i.length&&i.forEach(([c,u])=>{u=u,u=e[u],c&&u&&r[`set${u}`](r[`get${u}`]()+c)}),r}}var Gn=zr(),Kn=Gr(),z=Rr();function In(e,...t){return z(e,...t),e}function rt(e,{start:t,end:n,future:r,past:o,include:i={start:!1,end:!1}}={}){let c=e.clone.UTC;return t=t?.value||t?.constructor===Date?C(t?.value||t).UTC:C.now.UTC,n=n&&n?.value||n?.constructor===Date?C(n?.value||n).UTC:C.now.UTC,c.milliseconds=0,t.milliseconds=0,n.milliseconds=0,r?t>n:o?t<n:(i.start?+c>=+t:+c>+t)&&(i.end?+c<=+n:+c<+n)}function kn(e,{zoneTime:t=!1,formatStr:n,moreOptions:r}={}){return r=t?e.localeInfo.formatOptions+(r?`,${r}`:""):N.formatOptions+(r?`,${r}`:""),t?(e.localeInfo||(e.localeInfo=N),Ce(e,n,r)):Qr(e,n,r)}function Qr(e,t,n){let r=e.clone.relocate(N);return n=(n||"").startsWith("+")?`${r.localeInfo.formatOptions},${n.slice(1)}`:n||r.localeInfo.formatOptions,Ce(r,t,n)}function Ur(e,t){let n=Gn({start:e,end:t||e});return parseInt(`${n.sign}${n.diffInDays}`)}function Pn(e,t=!1){let{locale:n,timeZone:r}=t?e.localeInfo:N,o=ur(n,r),i=e.format("MM|WD",o).split("|");return{locale:n,timeZone:r,monthName:i[0],dayName:i[1],dayNames:cr(n),monthNames:mt(n)}}function Zn(e,t=!1){let[n,r,o,i]=at(e,t),c={values4Timezone:t?N.timeZone:e.timeZone,hours:n,minutes:r,seconds:o,milliseconds:i};return Object.freeze(c)}function at(e,t=!1){let n=`l:en-CA,${t?`tz:${N.timeZone}`:`tz:${e.timeZone}`},hrc:23,ts:medium`;return e.format("",n).split(/:/).map(Number).concat(e.getMilliseconds())}function zn(e,t){let n=t?`tz:${N.timeZone}`:`,tz:${e.timeZone}`,[r,o,i]=e.format("yyyy-mm-dd",n).split(/-/).map(Number);o-=1;let c=t?N.timeZone:e.timeZone;return Object.freeze({values4Timezone:c,year:r,month:o,date:i})}function Hn(e,t=!0){if(t)return[e.getFullYear(),e.getMonth(),e.getDate()];let n=e.format("yyyy-m-d",e.localeInfo.formatOptions).split(/-/).map(Number);return n[1]-=1,n}function Wr(e,{sunday:t=!1}={}){return lt(e,{day:t?"sunday":"monday"})}function qr(e,t){let n=e.toString().match(/GMT([+-])\d+/)?.[0]?.slice(3)??"+0000",r=t.toString().match(/GMT([+-])\d+/)?.[0]?.slice(3)??"+0000";return n=st(n.slice(0,3)+":"+n.slice(-2),!0),r=st(r.slice(0,3)+":"+r.slice(-2),!0),[-n[0]+r[0],-n[1]+r[1]].map(o=>n[0]<0?-o:o)}function Xn({start:e,end:t}={}){t||(t=e.clone),t?.clone||(t=C(t,{timeZone:e.timeZone})),e=C(Un(e,e.timeZone),{timeZone:e.timeZone}),t=C(Un(t,t.timeZone),{timeZone:t.timeZone});let n=Gn({start:e,end:t,diffs:{timeZoneStart:e.timeZone,timeZoneEnd:t.timeZone}}),r=qr(t,e),o=r[0]>0?"ahead of":"behind",[i,c]=r.map(h=>Math.abs(h)),[u,b]=[`${i} ${ie(i,"hour")}`,`${c} ${ie(c,"minute")}`];return n.timeZonesOffsetDifference=n.sign.length<1||i+c===0?`Offsets of ${e.timeZone} and ${t.timeZone} are equal`:`${e.timeZone} is ${u}${c>0?` and ${b}`:""} ${o} ${t.timeZone}`,n}function Vr(e){return e==="+"?"-":"+"}function Rn(e,t){let n=String(t).toLowerCase()==="utc"||t.timeZone==="UTC";t=n?e.clone.relocate({timeZone:"UTC"}):C(e.value,{timeZone:t.timeZone||N.timeZone});let r=Xn({start:e.clone,end:t}),o=`${n?Vr(r.sign):r.sign}${Jn(r.hours)}:${Jn(r.minutes)}`;return{fromTZ:e.timeZone,toTZ:t.timeZone,offset:o,offsetText:`${t.timeZone} `+Br(o)+` ${e.timeZone}`}}function Jn(e,t=2){return`${e}`.padStart(t,"0")}function ie(e,t){return`${t}${e>1||e===0?"s":""}`}function Br(e){if(/00:00/.test(e))return"no time diffence to";let t=e.slice(1).split(":").map(Number),[n,r]=t,o=e.at(0)==="+";return r>0?`${n} ${ie(n,"hour")} and ${r} ${ie(r,"minute")} ${o?"ahead of":"behind"}`:`${n} ${ie(n,"hour")} ${o?"ahead of":"behind"}`}function Qn(e,t,n){return e.clone.format(t,n||e.localeInfo.formatOptions)}function Yr(e,{withFormat:t,withFormatOptions:n,local:r=!1}={}){if(t)return r?Qn(e,t,$D.localeInformation.formatOptions):Qn(e,t,n);let o=e.clone.relocate({locale:"en"}),i=r?N.formatOptions:o.localeInfo.formatOptions,c=`wd M dd yyyy hh:mmi:ss ${o.format("tz",i+",tzn:longOffset").replace(":","")} (tz)`;return o.format(c,i+",tzn:long, hrc:23")}function er(e,t=!1){let n=Intl.DateTimeFormat("en",{timeZone:t?e.timeZone:N.timeZone,weekday:"short"});return Kn(n.format(e))}function _r(e){let t=N,n=e.localeInfo,r=e.clone.relocate({locale:t.locale,timeZone:t.timeZone}),o=e.offsetFrom(r),i=r.offsetFrom(e),c=t,u=n,b=e.format("hh:mmi:ss dp",`hrc:12,tz:${e.timeZone}`),h=r.format("hh:mmi:ss dp",`hrc:12,tz:${r.timeZone}`),g={note:"'user' are values for your locale/timeZone, 'remote' (if applicable) idem for the instance",locales:{user:{locale:c.locale,timeZone:c.timeZone}},dateTime:{user:{...e.dateTime,monthName:r.monthName,weekdayNr:r.day,weekdayName:r.dayName,dayPeriodTime:h,hasDST:r.hasDST,DSTActive:r.DSTActive,offsetFromRemote:o.offset,string:r.toString()}},offset:{fromUTC:e.UTC.offsetFrom(e).offsetText}};return n.timeZone!==t.timeZone&&(g.locales.remote={locale:u.locale,timeZone:u.timeZone},g.dateTime.remote={...e.zoneDateTime,monthName:e.zoneNames.monthName,weekdayNr:er(e,!0),weekdayName:e.zoneNames.dayName,dayPeriodTime:b,hasDST:e.hasDST,DSTActive:e.DSTActive,offsetFromUser:i.offset,string:e.toString()},g.offset.fromUserTime=i.offsetText),g}function $e(e,t=!0){if(t)return[e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds()];let n=e.format("yyyy-m-d-hh-mmi-ss",`${e.localeInfo.formatOptions},hrc23:true`).split(/-/).map(Number).concat(e.getMilliseconds());return n[1]-=1,n}function tr(e){return new Date(e.year,e.month+1,0,0,0,0).getDate()}function nr(e,t){t=F({locale:t}).locale;let n=e.clone.relocate({locale:t});return n.date={date:1},[n].concat([...Array(tr(n)-1)].map((r,o)=>n.clone.add(`${o+1} days`)))}function lt(e,{day:t,next:n=!1}={}){let r=Kn(t?.toLowerCase()),o=C(new Date(...e.dateTimeValues),e.localeInfo);return r<0?(console.error(`[TickTock instance].next/previous invalid day value ${t}`),o):rr(o,r,n?1:-1)}function rr(e,t,n){return z(e,`${n} day`).getDay()<t?rr(e,t,n):e}function Oe(e,{dateOnly:t=!1,timeOnly:n=!1}={}){e.localeInfo||(e.localeInfo=oe());let{locale:r,timeZone:o}=e.localeInfo;return t?new Date(e).toLocaleDateString(r,{timeZone:o}):n?new Date(e).toLocaleTimeString(r,{timeZone:o}):new Date(e).toLocaleString(r,{timeZone:o})}function Un(e,t){let n={timeZone:t,hourCycle:"h23"};return new Date(new Date(e).toLocaleString("en",n))}function re(e,{year:t,month:n,date:r}={}){return M(t)&&e.setFullYear(parseInt(t)),M(r)&&e.setDate(parseInt(r)),M(n)&&e.setMonth(parseInt(n)),e}function Y(e,{hours:t,minutes:n,seconds:r,milliseconds:o}={}){return M(t)&&e.setHours(parseInt(t)),M(n)&&e.setMinutes(parseInt(n)),M(r)&&e.setSeconds(parseInt(r)),M(o)&&e.setMilliseconds(parseInt(o)),e}function or(e){return e?.constructor===Date||e?.value}function Wn(e,t){return or(t)?C(t?.value||t,e.localeInfo):C.from(...e.dateTimeValues).relocate(e.localeInfo)}function Gr(){let e={short:["sun","mon","tue","wed","thu","fri","sat"],long:["sunday","monday","tuesday","wednesday","thursday","friday","saturday"]};return function(t){t=`${t}`.toLowerCase();let n=e.short.indexOf(t);return n<0?e.long.indexOf(t):n}}function st(e,t=!1){if(t){let n=e.slice(1).split(/[-:]/).map(Number),r=e.slice(0,1)==="-";return n=n.map(o=>r?-o:o),n}return Number(e.split(/[+-]/).slice(-1)[0].replace(/:/,""))}function Kr(e){return e.time={hours:0,minutes:0,seconds:0,milliseconds:0},e}function qn(e,t){return Intl.DateTimeFormat("en-CA",{timeZone:t,timeZoneName:"long"}).format(e).split(/,/)[1].trim()}function ir(e,t){t=t||e?.timeZone||N.timeZone,e=e?.value?e:e?.constructor===Date?C(e,{timeZone:t}):C({timeZone:t});let n=e.year||e.getFullYear(),r=qn(new Date(n,0,1),t),o=qn(new Date(n,5,1),t);return r!==o}function ar(e,t){return t=t||e?.timeZone||N.timeZone,e=e?.hasDST?e:e?.constructor===Date?C(e,{timeZone:t}):C({timeZone:t}),e.hasDST?!/standard/i.test(e.toString()):!1}function Xr(e,{locale:t,timeZone:n,l:r,tz:o}={}){return e.localeInfo=F({locale:r||t||e.l||e.locale,timeZone:o||n||e.tz||e.timeZone}),e}function eo(e,t){return or(t)&&(e=C(t.value||t,t.localeInfo||e.localeInfo)),e}function ut(e,t){let n=lr(new Date(e,11,t||31));return n===1?ut(e,(t||31)-1):n}function Vn(e,t){let n=e.month;switch(!0){case n<3:return t?1:"First";case n<6:return t?2:"Second";case n<9:return t?3:"Third";case n<12:return t?4:"Fourth";default:return"unknown"}}function lr(e){let t=new Date(e),n=(t.getDay()+6)%7;t.setDate(t.getDate()-n+3);let r=t.valueOf();return t.setMonth(0,1),t.getDay()!==4&&t.setMonth(0,1+(4-t.getDay()+7)%7),1+Math.ceil((r-t)/6048e5)}var sr=to;function to({localeInfo:e,customMethods:t,dateValue:n}={}){let r,o={add(...i){return In(r,...i)},between({start:i,end:c,include:u}={}){return rt(r,{start:i,end:c,include:u})},cloneWith(i){return Wn(r,i)},daysUntil(i){return Ur(r,i)},differenceTo(i){return Xn({start:r,end:i})},differenceUntil(i){return r.differenceTo(i).clean},firstWeekday({sunday:i=!1,midnight:c=!1}={}){return Wr(r,{sunday:i,midnight:c})},format(i,c){return kn(r,{formatStr:i,moreOptions:c})},fullMonth(i){return nr(r,i)},isFuture(i){return rt(r,{start:r,end:i,future:!0})},isPast(i){return rt(r,{start:r,end:i,past:!0})},next(i){return lt(r,{day:i,next:!0})},offsetFrom(i){return Rn(r,i)},previous(i){return lt(r,{day:i,next:!1})},relocate({locale:i,timeZone:c,l:u,tz:b}={}){return Xr(r,{locale:i,timeZone:c,l:u,tz:b})},revalue(i){return r=eo(r,i),r},setDateValues({year:i,month:c,date:u}={}){return re(r,{year:i,month:c,date:u})},setTimeValues({hours:i,minutes:c,seconds:u,milliseconds:b}={}){return Y(r,{hours:i,minutes:c,seconds:u,milliseconds:b})},subtract(...i){return In(r,"subtract,"+i.join(","))},toArray(i=!1){return $e(r,i)},toString({template:i,formatOptions:c,local:u}={}){return Yr(r,{withFormat:i,withFormatOptions:c,local:u})},values(i=!1){return i?r.dateTime:r.zoneDateTime},zoneFormat(i,c){return kn(r,{zoneTime:!0,formatStr:i,moreOptions:c})},set date({year:i,month:c,date:u}){re(r,{year:i,month:c,date:u})},set dateNr(i){re(r,{date:i})},set hours(i){Y(r,{hours:i})},set localeInfo({locale:i,timeZone:c,l:u,tz:b}){e=oe({locale:i,timeZone:c,l:u,tz:b})},set milliseconds(i){Y(r,{milliseconds:`${i}`})},set minutes(i){Y(r,{minutes:i})},set month(i){re(r,{month:i})},set seconds(i){Y(r,{seconds:i})},set time({hours:i,minutes:c,seconds:u,milliseconds:b}){Y(r,{hours:i,minutes:c,seconds:u,milliseconds:b})},set year(i){re(r,{year:i})},get age(){return r.differenceTo(new Date).years},get ageFull(){return r.differenceTo(new Date).clean},get clone(){return Wn(r)},get date(){return zn(r,!0)},get dateNr(){return r.date.date},get dateTime(){return{...r.date,...r.time}},get dateTimeValues(){return $e(r,!0)},get dateValues(){return Hn(r,!0)},get day(){return r.getDay()},get dayName(){return r.names.dayName},get daysThisMonth(){return tr(r)},get DSTActive(){return ar(r)},get hasDST(){return ir(r)},get hours(){return r.time.hours},get info(){return _r(r)},get isLeapYear(){return new Date(r.getFullYear(),2,0).getDate()===29},get ISO(){return r.toISOString()},get local(){return Oe(r)},get localDate(){return Oe(r,{dateOnly:!0})},get locale(){return(e||oe()).locale},get localeInfo(){return e},get localeString(){return Oe(r)},get localTime(){return Oe(r,{timeOnly:!0})},get milliseconds(){return r.getMilliseconds()},get minutes(){return r.time.minutes},get month(){return r.date.month},get monthName(){return r.names.monthName},get names(){return Pn(r)},get quarter(){return Vn(r)},get quarterNr(){return Vn(r,!0)},get removeTime(){return Kr(r)},get seconds(){return r.time.seconds},get time(){return Zn(r,!0)},get timeValues(){return at(r,!0)},get timeZone(){return(e||oe()).timeZone},get unixEpochTimestamp(){return Math.floor(+r/1e3)},get userLocaleInfo(){return N},get UTC(){return r.clone.relocate({locale:r.locale,timeZone:"UTC"})},get UTCOffset(){return Rn(r,"UTC")},get value(){return new Date(r)},get weeknr(){return lr(r)},get weeksInYear(){return ut(r.year,31)},get year(){return r.date.year},get zoneDate(){return zn(r,!1)},get zoneDateNr(){return r.zoneDate.date},get zoneDateTime(){return{...r.zoneDate,...r.zoneTime}},get zoneDateTimeValues(){return $e(r,!1)},get zoneDateValues(){return Hn(r,!1)},get zoneDay(){return er(r,!0)},get zoneDayname(){return r.zoneNames.dayName},get zoneHours(){return r.zoneTime.hours},get zoneMinutes(){return r.zoneTime.minutes},get zoneMonth(){return r.zoneDate.month},get zoneMonthname(){return r.zoneNames.monthName},get zoneNames(){return Pn(r,!0)},get zoneSeconds(){return r.zoneTime.seconds},get zoneTime(){return Zn(r)},get zoneTimeValues(){return at(r)},get zoneYear(){return r.zoneDate.year},get zoneValues(){return r.zoneDateTime},get zoneArray(){return $e(r,!1)}};return!e&&!n?o:(o.localeInfo=e||oe(),r=new Proxy(n,no(o)),Object.entries(Object.getOwnPropertyDescriptors(mr(r,t))).forEach(([i,c])=>Object.defineProperty(o,i,c)),Object.freeze(r))}function no(e){return{get(t,n){return n!=="toString"&&n in t?t[n].bind(t):Reflect.get(e,n)},set(t,n,r){return n in e&&Reflect.set(e,n,r)}}}var N=ct(Intl.DateTimeFormat().resolvedOptions()),ro=Object.getOwnPropertyNames(Date.prototype).filter(e=>e.startsWith("set")).reduce((e,t)=>[...e,{native:t,syn:"change"+t.slice(3)}],[]);function cr(e="en-GB"){return e=F({locale:e}).locale,{long:[...Array(7).keys()].map(t=>new Date(Date.UTC(1970,0,4+t)).toLocaleDateString(e,{timeZone:"Etc/UTC",weekday:"long"})),short:[...Array(7).keys()].map(t=>new Date(Date.UTC(1970,0,4+t)).toLocaleDateString(e,{timeZone:"Etc/UTC",weekday:"short"}))}}function mt(e="en"){return e=F({locale:e}).locale,{long:[...Array(12).keys()].map(t=>new Date(Date.UTC(1970,t,1)).toLocaleDateString(e,{timeZone:"Etc/UTC",month:"long"})),short:[...Array(12).keys()].map(t=>new Date(Date.UTC(1970,t,1)).toLocaleDateString(e,{timeZone:"Etc/UTC",month:"short"}))}}function oo({year:e,locale:t}={}){e=M(e)?parseInt(e):new Date().getFullYear();let n={year:e,calendar:{}},r=mt().long.map(o=>o.toLowerCase());for(let o=0;o<12;o+=1){let i=C.from(e,o,1);n.calendar[r[o]]=nr(i,t)}return n}function io({year:e,monthNr:t,locale:n="en-CA"}={}){e=M(t)&&parseInt(e)||-1,t=M(t)&&parseInt(t)||new Date().getFullYear();let r=t>=1&&t<=12;return n=F({locale:n}).locale,t=r?t-1:void 0,r?C.from(e,t,1).relocate({locale:n}).fullMonth(n):"MonthNr should be a specific number (1 = january - 12 = december)"}function ct(e){let t=ur(e.locale,e.timeZone);return Object.defineProperty(e,"formatOptions",{value:t,enumerable:!1})}function ur(e,t){return[`${e&&!(Array.isArray(e)&&e.length<1)?`l:${e}`:""}`,`${t?`tz:${t}`:""}`].filter(n=>n).join(",")}function F({locale:e,timeZone:t,l:n,tz:r}={}){return t=t||r,e=e||n,!e&&!t?N:lo({trial:function(){let o=Intl.DateTimeFormat(e,{timeZone:t}).resolvedOptions();return e&&o.locale!==e&&console.error(`\u{1F6AB} Intl changed locale (using best fit) "${e}" to "${o.locale}"`),ct(o)},whenError:function(o){switch(!0){case/incorrect locale/i.test(o.message):return console.error(`\u{1F6AB} Intl locale "${e}" best fit impossible, using "${N.locale}"`),F({locale:N.locale,timeZone:t});case/invalid time zone/i.test(o.message):return console.error(`\u{1F6AB} timeZone "${t}" not valid. Using "${N.timeZone}"`),F({locale:e,timeZone:N.timeZone});default:return N||ct(Intl.DateTimeFormat().resolvedOptions())}}})}function oe({locale:e,timeZone:t,l:n,tz:r}={}){return F({locale:e,timeZone:t,l:n,tz:r},!0)}function Bn(e){return!Number.isNaN(+e)&&e?.constructor===Date&&!e?.toISOString?.().startsWith("1970-01-01T00:00:00")?e:new Date}function ao(e){let t=new Date;switch(!0){case e?.constructor===String:return Bn(new Date(e));case(Array.isArray(e)&&e.map(Number).length===e.length):return e.length===1?new Date(e[0],0,1):new Date(...e);case e?.constructor===Date:return Bn(e);default:return t}}function lo({trial:e,whenError:t=()=>{}}={}){if(e?.constructor===Function)try{return e()}catch(n){return t?.constructor===Function?t(n):void 0}}function so({timeZoneDate:e,timeZoneID:t,userTimeZoneID:n}={}){let r={timeZone:F({timeZone:t}).timeZone},o={timeZone:F({timeZone:n||""}).timeZone},i=C(e,r),c=C(e,o),u=c.differenceTo(i),b=i.offsetFrom(c).offset,[h,g]=st(b,!0),v=c.clone.add(`${h} hours, ${g} minutes`),y=u.equalDates?"No difference":`Time offset ${b}: ${o.timeZone} is ${u.clean} ${h<0?"behind":"ahead of"} ${r.timeZone}`;return{remoteTimezone:r.timeZone,userTimezone:o.timeZone,timeDifference:y,result:{[r.timeZone.replace(/\//,"_")]:C(e).toString({template:"yyyy/mm/dd hh:mmi:ss",formatOptions:"hrc:23"}),[o.timeZone.replace(/\//,"_")]:v.toString({template:"yyyy/mm/dd hh:mmi:ss",formatOptions:"hrc:23"})}}}function M(e){return!Number.isNaN(parseInt(e))}function De(e,t,n){return e?.constructor===Number?z(t,`${e} ${n}`):t}function co(e){let t={addYears(n=1){return De(n,e,"years")},addMonths(n=1){return De(n,e,"months")},addWeeks(n=1){return n=n?.constructor===Number?n*7:1,De(n,e,"days")},addDays(n=1){return De(n,e,"days")},get nextYear(){return z(e,"1 year")},get nextWeek(){return z(e,"7 days")},get previousWeek(){return z(e,"-7 days")},get previousYear(){return z(e,"-1 year")},get nextMonth(){return z(e,"1 month")},get previousMonth(){return z(e,"-1 month")},get tomorrow(){return z(e,"1 day")},get yesterday(){return z(e,"-1 day")}};for(let n of ro)t[n.syn]=function(...r){return e[n.native](...r),e};return t}function mr(e,t){let n=co(e);for(let[r,o]of Object.entries(t||{})){let i=o.enumerable,c=o.isGetter?{get(){return o.method(e)},enumerable:i}:{value(...u){return o.method(e,...u)},enumerable:i};Object.defineProperty(n,r,c)}return n}function uo(e,t){return Object.defineProperties(e,{now:{get(){return e(new Date)}},localeInformation:{get(){return F()}},localWeekdaynames:{value(n){return cr(n)}},localMonthnames:{value(n){return mt(n)}},daysInMonth:{value(n,r=!1){return n=M(n)?parseInt(n):0,n>=1&&n<=12?new Date(r?2e3:2005,n,0).getDate():`${n} should be a Number (1 (january) - 12 (december))`}},yearCalendar:{value:oo},monthCalendar:{value:io},from:{value(...n){return e(n)}},fromUxTS:{value(n,r){n=M(n)?parseInt(n)*1e3:void 0;let o=n?new Date(n):new Date;return C(o,r||N)}},hasDST:{value({date:n,timeZone:r}={}){return ir(n,r)}},DSTActive:{value({date:n,timeZone:r}={}){return ar(n,r)}},values:{value({date:n,timeZone:r}={}){n=n||n?.value||new Date;let o=Ce(n,"yyyy-m-d-h-mi-s",F({timeZone:r}).formatOptions.concat(",hrc:23")).split("-").map(Number).concat(n.getMilliseconds());return o[1]-=1,o}},format:{value({date:n,template:r,timeZone:o,locale:i,opts:c}={}){n=n||n?.value||new Date,r=r?.constructor===String?r:"yyyy/mm/dd hh:mmi:ss dp";let u=F({timeZone:o,locale:i}).formatOptions;return u+=c?`,${c}`:"",Ce(n,r,u)}},addCustom:{value({name:n,method:r,enumerable:o=!1,isGetter:i=!1}={}){n?.constructor===String&&r?.constructor===Function&&r.length>0&&(t[n]={method:r,enumerable:o,isGetter:i})}},validateLocaleInformation:{value:F},timeAcrossZones:{value:so},weeksInYear:{value(n){return ut(n,31)}},keys:{get(){let n=Object.fromEntries(Object.entries(t).filter(([r,o])=>o.enumerable===!0));return[...Object.keys(sr()),...Object.keys(mr()),...Object.keys(n)].sort((r,o)=>r.localeCompare(o))}}}),e}var dr={},C=uo(mo,dr);function mo(e,t){if(e?.localeInfo)return e.clone;let n=e?.locale||e?.timeZone||e?.tz||e?.l;return sr({localeInfo:F(n?e:t),dateValue:new Date(n?Date.now():ao(e)),customMethods:dr})}var fr=Object.defineProperties(gr,{escape:{value:vo,enumerable:!0}});function gr(e,...t){let{flags:n,cleanedArgs:r}=go(...t);return yo(new RegExp(wo(fo(e,...r)),n))}function fo(e,...t){return G(t)?e.raw.reduce((n,r,o)=>n.concat(t[o-1]||"").concat(r),""):e.raw.join("")}function go(...e){let t=dt(po(e.at(-1)));return{flags:t,cleanedArgs:G(t)?e.slice(0,-1):e}}function po(e){return Ne(e,Array)?e.join(""):""}function yo(e){let t=new Proxy(Object.defineProperties({},{re:{get(){return e},enumerable:!1},toString:{value:()=>e.toString(),enumerable:!1},valueOf:{value:()=>e,enumerable:!1},flags:{value(n){return e=xo(n,e),t},enumerable:!1},clone:{get(){return So(t)},enumerable:!1}}),bo(e));return t}function G(e){return e?.length>0}function Ne(e,t){return e?.constructor===t}function ho(e,t,n){let r=Reflect.get(n,t);return{fromInstance:Reflect.get(e,t),fromRegExpMethod:Ne(r,Function)?r.bind(e.re):e.re[t]}}function bo(e){return{get(t,n){let{fromInstance:r,fromRegExpMethod:o}=ho(t,n,e);switch(!0){case!!r:return r;default:return o}}}}function So(e){let t=e.re.source,n=G(e.re.flags)?[...e.re.flags]:[];return gr`${t} ${n}`}function dt(e,t){return t=(t??"").replace(/^-r\|/,""),e=t.concat(Ne(e,String)&&G(e)?e:""),[...new Set([...e])].join("").replace(/[^dgimsuvy]/g,"")}function xo(e,t){switch(!0){case(!Ne(e,String)||!G(e)):return t;case e==="-r":return t=new RegExp(t.source);case e.startsWith("-r|"):return t=new RegExp(t.source,dt(e));default:return t=new RegExp(t.source,dt(t.flags,e))}}function vo(e){switch(!0){case(e?.constructor!==String||!G(e)):return"";case!!RegExp.escape:return RegExp.escape(e);default:return(`\\x${e.at(0)}`+e.slice(1).replace(/\p{S}|\p{P}/gu,t=>`\\${t}`)).replace(/ |\\x /g,"\\x20")}}function wo(e){return e.replace(/\/\*(?:[^*]|\*+[^*\/])*\*+\/|(?<!:|\\\|')\/\/.*/gm,"").replace(/\s/g,"").trim().replace(/<!([^>]\d+)>/g,(t,n)=>String.fromCharCode(+n)??t)}var{IS:To}=$o(),K=To;function $o(){Symbol.proxy=Symbol.for("toa.proxy"),Symbol.is=Symbol.for("toa.is"),Symbol.type=Symbol.for("toa.type"),Symbol.isSymbol=Symbol.for("toa.isASymbol"),f();let e=v(),[t,n]=[y(),A()];return n.custom(),{IS:r,maybe:e,$Wrap:t,isNothing:g,xProxy:n};function r(a,...s){if(e({trial:d=>"isTypes"in(s?.[0]??{})})){let d=s[0];return"defaultValue"in d?w(a,d):"notTypes"in d?S(a,d):r(a,...[d.isTypes].flat())}let m=typeof a=="symbol"?Symbol.isSymbol:a;return s.length>1?h(m,...s):i(a,...s)}function o(a){return a?.[Symbol.proxy]??r(a)}function i(a,...s){let{noInput:m,noShouldbe:d,compareTo:T,inputCTOR:j,isNaN:I,isInfinity:k,shouldBeFirstElementIsNothing:P}=u(a,...s);switch(s=s.length&&s[0],!0){case P:return String(a)===String(T);case(a?.[Symbol.proxy]&&d):return a[Symbol.proxy];case I:return d?"NaN":e({trial:Z=>String(T)})===String(a);case k:return d?"Infinity":e({trial:Z=>String(T)})===String(a);case m:return d?String(a):String(T)===String(a);case j===Boolean:return s?j===s:"Boolean";default:return b(a,s,d,c(a,j))}}function c(a,s){return a===0?Number:a===""?String:a?s:{name:String(a)}}function u(a,...s){let m=s.length<1,d=!m&&s[0],T=!m&&g(s[0]),j=a==null,I=!j&&Object.getPrototypeOf(a)?.constructor,k=Number.isNaN(a)||e({trial:Z=>String(a)==="NaN"}),P=e({trial:Z=>String(a)})==="Infinity";return{noInput:j,noShouldbe:m,compareTo:d,inputCTOR:I,isNaN:k,isInfinity:P,shouldBeFirstElementIsNothing:T}}function b(a,s,m,d){switch(!0){case(!m&&s===a||a?.[Symbol.proxy]&&s===Proxy):return!0;case e({trial:T=>String(s)})==="NaN":return String(a)==="NaN";case(a?.[Symbol.toStringTag]&&r(s,String)):return String(s)===a[Symbol.toStringTag];default:return s?e({trial:T=>a instanceof s})||s===d||s===Object.getPrototypeOf(d)||`${s?.name}`===d?.name:a?.[Symbol.toStringTag]&&`[object ${a?.[Symbol.toStringTag]}]`||d?.name||String(d)}}function h(a,...s){return s.some(m=>r(a,m))}function g(a,s=!1){let m=a==null;return m=s?m||r(a,1/0)||r(a,NaN):m,m}function v(){let a=(s,m)=>s?.constructor===Function?s(m):void 0;return function({trial:s,whenError:m=()=>{}}={}){try{return a(s)}catch(d){return a(m,d)}}}function y(){return function(a){return Object.freeze({get value(){return a},get[Symbol.type](){return o(a)},get type(){return o(a)},[Symbol.is](...s){return r(a,...s)},is(...s){return r(a,...s)}})}}function w(a,{defaultValue:s,isTypes:m=[void 0],notTypes:d}={}){return m=m?.constructor!==Array?[m]:m,d=d&&d?.constructor!==Array?[d]:[],d.length<1?r(a,...m)?a:s:S(a,{isTypes:m,notTypes:d})?a:s}function S(a,{isTypes:s=[void 0],notTypes:m=[void 0]}={}){return s=s?.constructor!==Array?[s]:s,m=m?.constructor!==Array?[m]:m,r(a,...s)&&!r(a,...m)}function f(){Object.getOwnPropertyDescriptors(Object.prototype)[Symbol.is]||(Object.defineProperties(Object.prototype,{[Symbol.type]:{get(){return o(this)},enumerable:!1,configurable:!1},[Symbol.is]:{value:function(...a){return r(this,...a)},enumerable:!1,configurable:!1}}),Object.defineProperties(Object,{[Symbol.type]:{value(a){return o(a)},enumerable:!1,configurable:!1},[Symbol.is]:{value:function(a,...s){return r(a,...s)},enumerable:!1,configurable:!1}}))}function x(a){let s=String(Object.getPrototypeOf(a)?.constructor);return s.slice(s.indexOf("ion")+3,s.indexOf("(")).trim()}function O(a){let s=a.set;return a.set=(m,d,T)=>d===Symbol.proxy?m[d]=T:s(m,d,T),a}function A(){let a=Proxy;return{native(){Proxy=a},custom(){Proxy=new a(a,{construct(s,m){for(let T of m)T.set&&(T=O(T));let d=new s(...m);return d[Symbol.proxy]=`Proxy (${x(m[0])})`,d}})}}}}var ft=pr(void 0),Oo=pr("");Object.defineProperties(String.prototype,{[Symbol.for("interpolate")]:{value(...e){return ft(this,...e)}},[Symbol.for("interpolate$")]:{value(...e){return Oo(this,...e)}}});function pr(e){return e=K(e,String,Number)?String(e):void 0,function(h,...g){return b(h,u(g))};function t(h,g){return g&&K(e,String,Number)?String(e):`{${h}}`}function n(h,g){let v=h in g;return v&&K(g[h],String,Number)?String(g[h]):t(h,v)}function r(h){return(...g)=>{let v=g.find(y=>y.key);return n(v?v.key:"_",h)}}function o(h,g){return h.replace(/\{(?<key>[a-z_\d]+)}/gim,r(g))}function i(h){let g=[];return Object.entries(h).forEach(([v,y])=>{y.forEach((w,S)=>(g[S]??={},g[S][v]=w))}),g}function c(h){return h.length===1&&Object.values(h[0]).every(Array.isArray)}function u(h){return c(h)?i(h[0]):h}function b(h,g){let v=g?.length?g.filter(y=>K(y,Object)).map((y,w)=>o(h,{...y,index:w+1})).join(""):h;return K(e,void 0)?v:v.replace(/\{[a-z_\d].+\}/gim,String(e))}}jo();Do();function Do(){/stackblitz/i.test(location.href)&&console.info("\u2714 Stackblitz rewrites links to _top. The 'stackblitzhelpers' module fixed it."),document.addEventListener("click",e=>{if(e.target.href){let t=e.target;if(t.dataset.top||t.classList.contains("internalLink")||t.target==="_top")return top.location.href=t.href}return!0})}function Co(e=!0){let t=J('<ul id="log2screen">').first();function n(i=!1){let c=i?J.at.start:J.at.end;return u=>{if(u?.isJQx)return J.li(u.data.get("header")?{class:"head"}:"",u).renderTo(t,c);u=J.IS(u,String,Number,Symbol)?String(u):No(u,e);let b=u.startsWith("!!");u=b?u.slice(2):u,J.li(b?{class:"head"}:"",u).renderTo(t,c)}}let[r,o]=[n(),n(!0)];return{log:(...i)=>i.forEach(r),logTop:(...i)=>i.forEach(o)}}function No(e,t){try{return t?`<pre>${JSON.stringify(e,null,2)}</pre>`:JSON.stringify(e)}catch{return"Some [Object object] can not be converted to JSON"}}function jo(){J.editCssRules("body{font:normal 14px/17px system-ui,sans-serif;margin:1rem;}","li::marker{vertical-align:top;}","code{color:green;background-color:#eee;padding:2px;font-family:monospace;}","code.codeblock{display:block;padding:6px;border:1px solid #999;margin:0.5rem 0;background-color:#eee;white-space:pre-wrap;}","h3{marginTop:1.5rem;}",".thickBorder{border:5px solid green;borderWidth:5px;padding:0.5rem;display:inline-block;}","a.ExternalLink{text-decoration:none;color:rgb(0,0,238);background-color:#EEE;padding:3px;font-weight:bold;}",".cmmt{color:#888;}",".hidden{display:none;}",".attention{color:red; font-size:1.2em; font-weight:bold;}","#log2screen li{listStyle:'\\2713';paddingLeft:6px;margin:0.5rem 0 0 -1.2rem;font-family:monospace}","#log2screen li.head{list-style-type:none;font-weight:bold;margin-top:0.8rem;margin-bottom:-0.2rem;font-family:revert;}",".err{fontStyle:italic; color:red; }","a{text-decoration:none; font-weight:bold;}","a:hover{text-decoration:underline;}","a[target]:before,a.internalLink:before,a.externalLink:before{color:rgba(0,0,238,0.7);font-size:1.1rem;padding-right:2px;vertical-align:baseline;}",`a[target="_blank"]:before,a.externalLink:before{content:'\\2197';}`,`a[data-top]:before,a.internalLink:before,a[target="_top"]:before{content:'\\21BA';}`)}return vr(Eo);})();
|
|
13
|
+
`)}function Ln(e){return e.reduce((t,n)=>{let[r,o]=[n.slice(0,n.indexOf(":")).trim(),n.slice(n.indexOf(":")+1).trim().replace(/;$|;.+(?=\/*).+\/$/,"")];return r&&o?{...t,[r]:o}:t},{})}function kn(e){return Ln(An(e))}function _e(e,t){return e?.replace("::",":")===t?.replace("::",":")}var ve=!1,En={on:()=>ve=!0,off:()=>ve=!1},K={tagsRaw:ee,allowUnknownHtmlTags:En,isAllowed(e){if(ve)return!0;let t=d(e,String)?e.toLowerCase():e?.nodeName.toLowerCase()||"none";return t==="#text"||!!ee[t]},allowTag:e=>ee[e.toLowerCase()]=!0,prohibitTag:e=>ee[e.toLowerCase()]=!1},Mn=!0,te={data:/data-[\-\w.\p{L}]/ui,validURL:/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i,whiteSpace:/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g,notAllowedValues:/^javascript|injected|noreferrer|alert|DataURL/gi};function In(e){if(Mn&&Object.keys(e.removed).length){let t=Object.entries(e.removed).reduce((n,[r,o])=>[...n,`${ie(r)} => ${o}`],[]).join("\\000A");L.error(`JQx: HTML creation error(s): ${t}`)}}function Zn(e){let t=e.nodeName.toLowerCase(),n=["annotation-xml","color-profile","font-face","font-face-src","font-face-uri","font-face-format","font-face-name","missing-glyph"];return/-/.test(t)&&!n.find(r=>r===t)||K.isAllowed(t)}function Ce(e){let t={rawHTML:e?.parentElement?.getHTML()??"no html",removed:{}};return d(e,HTMLElement)&&[...e.childNodes].forEach(n=>{if(n?.children?.length&&Ce(n),n?.attributes){let r=d(n,SVGElement)?Se.svg:Se.html;[...(n??{attributes:[]}).attributes].forEach(o=>{let i=o.name.trim().toLowerCase(),s=o.value.trim().toLowerCase().replace(te.whiteSpace,""),u=i==="href"?!te.validURL.test(s):te.notAllowedValues.test(s),p=i.startsWith("data")?!te.data.test(i):!!r[i];if(u||p){let y=Ke(o.value||"none",60);y+=y.length===60?"...":"",t.removed[`${o.name}`]=`attribute/property/value not allowed, removed. Value: ${y}`,n.removeAttribute(o.name)}})}if(!(Zn(n)||n.constructor===CharacterData||n.constructor===Comment)){let r=(n?.outerHTML||n?.textContent).trim(),o=Ke(r,60)??"EMPTY";o+=o.length===60?"...":"",t.removed[`<${n.nodeName?.toLowerCase()}>`]=`not allowed, not rendered. Value: ${o}`,n.remove()}}),In(t),e}function Pn(e){let t=document.createElement("div");return t.insertAdjacentHTML(z.end,e),t.childNodes.length?Ce(t):void 0}function Fn(e,t,n){switch(!0){case d(e,Comment):return t.insertAdjacentHTML(n,`<!--${e.data}-->`);case d(e,Text):return t.insertAdjacentText(n,e.data||e.textContent);default:return}}function $e(e=[],t=document.body,n=z.BeforeEnd){return n=n||z.BeforeEnd,t=t?.isJQx?t.node:t||document.body,e.reduce((r,o)=>{let i=U(o)&&zn(o,t,n);return i?[...r,i]:r},[])}function zn(e,t=document.body,n=z.BeforeEnd){return n=n||z.BeforeEnd,t=t?.isJQx?t?.[0]:t,d(e,Comment,Text)?Fn(e,t,n):d(e,HTMLElement)?t.insertAdjacentElement(n,e):void 0}function J(e){if(d(e,Text,Comment))return e;let t=e?.trim(),n=t?.split(/<text>|<\/text>/i)??[];if(n?.length&&(n=n.length>1?n.filter(o=>o.length).shift():void 0),t.startsWith("<!--")&&t.endsWith("-->"))return document.createComment(e.replace(/<!--|-->$/g,""));if(n||d(t,String)&&!/^<(.+)[^>]+>/m.test(t))return document.createTextNode(n??t);let r=Pn(e);return r.childNodes.length<1?J(`<span data-jqxcreationerror="1">${ut(e,60)}</span>`):r.children[0]}function Hn(e){if(e.node("#jqxPopup"))return;e.logger.log("JQx: [JQx].Popup first call. Dialog element created."),e.dialog({id:"jqxPopup"},e.div({id:"jqxPopupContent"})).render,e.editCssRules(...ln);let t=[],[n,r]=[e("#jqxPopupContent"),e.node("#jqxPopup")],o={};return e.handle({type:"click, keydown",handlers:h,name:"genericPopupCloseHandler",capture:!0,about:"A generic handler for JQx popups"}),Object.freeze({show:i,remove:s,removeModal:S});function i(m){if(r.open)switch(!0){case u(m):return;default:return s(),setTimeout(()=>i(m),200)}o={...m};let{content:x}=o;return e.IS(x,String,HTMLElement)||x?.isJQx?p():!0}function s(){return o.modal?b(o.warnMessage):y()}function u(m){for(let[x,T]of Object.entries(o))if(T!==m[x])return!1;return!0}function p(){n.clear();let{content:m,modal:x,closeAfter:T}=o;x=e.IS(x,Boolean)?x:!1;let A=x?"":e.div({id:"closeHandleIcon"});n.append(A,e.IS(m,String)?e.div(m):m),r.showModal(),!x&&e.IS(T,Number)&&v(s,T)}function y(){if(r.close(o.returnValue),g(),e.IS(o.callback,Function))return t.push(setTimeout(()=>o.callback(o.returnValue),200));o={}}function g(){t.forEach(m=>clearTimeout(m)),t=[]}function S({callback:m,value:x}={}){o.returnValue=x,o.modal=!1,o.callback=m||o.callback,s()}function h({evt:m}){if(!(Object.keys(o).length<1||!r.open||m.type==="keydown"&&m.key!=="Escape")&&(m.key==="Escape"&&o.modal&&m.preventDefault(),m.target.closest("#closeHandleIcon")||!m.target.closest("#jqxPopupContent")))return o.activeTimer&&clearTimeout(o.activeTimer),s()}function v(m,x){e.IS(m,Function)&&e.IS(x,Number)&&x>0&&(g(),t.push(setTimeout(m,x*1e3)))}function b(m){if(!e.IS(m,String,HTMLElement,Proxy))return;let x=n.find$(".warn");switch(!0){case x.is.empty:x=e.div({class:"warn"},m);default:n.append(x.addClass("active")),v(()=>n.find$(".warn").removeClass("active"),2)}}}function Rn(e){let t={},n="anonymous_";function r(g){if(g){let{handler:S,capture:h,type:v}=g;document.addEventListener(v,S,{capture:h})}}function o(g){if(g){let{type:S,handler:h,capture:v}=g;document.removeEventListener(S,h,{capture:v})}}function i(g,S,h,v){return function(b){if(!C(S))return g({evt:b});let m=b.target.closest(S);if(m){let x=e(m);g({self:x,me:x,evt:b}),h&&p(b.type,v)}return!0}}function s(g){return t[g]=t[g]||{},t[g]}function u(g,S){return Object.entries(s(g)).find(([h])=>h===S)}function p(g,S){let h=u(g,S);h&&(o(h[1]),delete t[g][S],delete we[S],L.warn(`Removed listener [${S}] for event type [${g}].`))}function y(g){let{type:S,handler:h,name:v,capture:b,once:m,selector:x,node:T,about:A}=g;t[S]=t[S]||{};let a=qn(v||h.name),l=h;if(T instanceof HTMLElement){let c=T.dataset.hid||a;T.dataset.hid=c,x=`[data-hid=${c}]`}switch(!0){case!t[S][a]:return L.log(`JQx: created listener for event type ${S}, with handler name ${a}`),t[S][a]={name:a,handler:i(h,x,m,a),capture:Vn(S,b),once:!!m,type:S,initialHandler:l,selector:!!x&&x||!1,about:!!A&&A||!1,unListen(){p(S,a)}},t[S][a];default:return console.warn(`The listener [${a}] for [${S}] exists, it is not re-assigned.`)}}return{remove(...g){return p(...g)},listen:function(g){let{type:S,handler:h}=g;if(!C(S)||!d(h,Function))return;let v=y(g);if(v)return r(v),{type:S,name:v.name,unListen(){p(S,v.name)}}},get ListenerStore(){return Object.freeze({...t})}}}var L=Yn(),Jn=["load","unload","scroll","focus","blur","DOMNodeRemovedFromDocument","DOMNodeInsertedIntoDocument","loadstart","progress","error","abort","load","loadend","pointerenter","pointerleave","readystatechange"],z=Object.freeze(new Proxy({start:"afterbegin",afterbegin:"afterbegin",end:"beforeend",beforeend:"beforeend",before:"beforebegin",beforebegin:"beforebegin",after:"afterend",afterend:"afterend"},{get(e,t){return e[String(t).toLowerCase()]??e[t]}})),Qn=[...Array(26)].map((e,t)=>String.fromCharCode(t+65)).concat([...Array(26)].map((e,t)=>String.fromCharCode(t+97))).concat([...Array(10)].map((e,t)=>`${t}`)),Un=Object.freeze({get(e,t){return e[Ae(t)]||e[t]},enumerable:!1,configurable:!1}),we={};function Wn(){let e=setTimeout(()=>{});for(;e>=0;)clearTimeout(e--)}function qn(e){return C(e)&&!/^handler|handlers$/gi.test(e.trim())?e.trim():lt()}function Bn(e){let t=!!e.node&&!d(e,Text,Comment);switch(!0){case t:let n=e.node.dataset?Object.keys(e.node.dataset).map(o=>`[data-${o}]`):[],r=[e.attr("id")&&`#${e?.attr("id")}`||void 0,e.attr("class")&&e?.attr("class").split(" ").map(o=>`.${o}`).join(", ")||void 0,n.length>0&&n.join(", ")||void 0].filter(o=>!!o).join(", ")||[];return r.length?`(${r})`:"";default:return""}}function lt(e){let t=`anonymous_${Math.random().toString(36).slice(2)}`;return we[t]?lt():(we[t]=t,t)}function Vn(e,t){return!!Jn.find(n=>n===e)||!!t}function st(e){return e.startsWith("data")||Se.html.find(t=>e.toLowerCase()===t)}function Ge(e){return e&&(e.textContent="")}function Te(e,t=0,n=!0){return e=e?.parentElement,t+=e?e[n?"scrollTop":"scrollLeft"]:0,e?Te(e,t,n):t}function C(e,t=1){return t=d(t,Number)&&t||1,d(e,String)&&e.length>=t}function Ke(e,t=120){return ut(e,t).replace(/</g,"<")}function ut(e,t=120){return`${e}`.trim().slice(0,t).replace(/>\s+</g,"><").replace(/</g,"<").replace(/\s{2,}/g," ").replace(/\n/g,"\\n")+(e.length>t?" …":"").trim()}function ie(e){switch(!0){case d(e,String):let t=document.createElement("div");return t.append(e),t.innerHTML;default:return e}}function ye(e){return d(e,String)&&Object.assign(document.createElement("textarea"),{innerHTML:e}).textContent||e}function Yn(){let[e,t]=[!1,!0],n=[],r={get on(){return e=!0,r},get off(){return e=!1,r},get disable(){return t=!0,r},get enable(){return t=!1,r},get backLog(){return n}};function o(){t=!0}function i(){t=!1}function s(...y){return n.unshift(...y.map(g=>`${he()} \u2A3B ${ye(g)}`)),console.error(n.slice(0,y.length).join(`
|
|
14
|
+
`)),r}function u(...y){return n.unshift(...y.map(g=>`${he()} \u26A0 ${ye(g)}`)),console.warn(n.slice(0,y.length).join(`
|
|
15
|
+
`)),r}function p(...y){let g=y.map(S=>`${he()} \u2714 ${ye(S)}`);switch(!t&&n.unshift(...g),e){case!0:console.log(g.join(`
|
|
16
|
+
`));default:return r}}return Object.defineProperties(r,{log:{value:p,enumerable:!1},error:{value:s,enumerable:!1},warn:{value:u,enumerable:!1}}),Object.freeze(r)}function he(){return(e=>`[${ne(e.getHours())}:${ne(e.getMinutes())}:${ne(e.getSeconds())}.${ne(e.getMilliseconds(),3)}]`)(new Date)}function _n(e,t){if(e)for(let[n,r]of Object.entries(t)){if(n=R(n),n.startsWith("data"))return ct(e,r);d(r,String)&&st(n)&&e.setAttribute(n,r.split(/[, ]/)?.join(" "))}}function ct(e,t){if(e&&d(t,Object))for(let[n,r]of Object.entries(t))e.setAttribute(`data-${R(n)}`,r)}function ft(e){return e?d(e,Proxy)?[e.EL]:d(e,NodeList)?[...e]:U(e)?[e]:Ee(e)?e:e.isJQx?e.collection:void 0:[]}function Xe(e,t){return e.andThen(t)}function et(e,t){return e.andThen(t,!0)}function U(e){return d(e,Text,HTMLElement,Comment)}function be(e,t){if(d(t,Object))for(let[n,r]of Object.entries(t)){let o;/!important/i.test(r)&&(r=r.slice(0,r.indexOf("!")).trim(),o="important"),e.style.setProperty(R(n),r,o)}}function Q(e){let t=e.cloneNode(!0);return t.removeAttribute&&t.removeAttribute("id"),e.isConnected?e.remove():e=null,t}function Gn(e){if(!e)return;let t=e.style,n=getComputedStyle(e),r=[t.visibility,n.visibility].includes("hidden"),o=[t.display,n.display].includes("none"),i=e.hidden,s=e.offsetTop<0||e.offsetLeft+e.offsetWidth<0||e.offsetLeft>document.body.offsetWidth,u=+n.opacity==0||+(t.opacity||1)==0;return!(i||s||u||o||r)}function Kn(e){return e?.isConnected?!![...document.querySelectorAll(":is(:read-write)")].find(t=>t===e):!1}function Xn(e){return e?.filter(t=>t).reduce((t,n)=>t.concat(dt(n)?`<!--${n.data}-->`:Le(n)?n.textContent:n.outerHTML),"")}function ne(e,t=2){return`${e}`.padStart(t,"0")}function er(e,t=0){return[e,t]=[Math.floor(e),Math.ceil(t)],Math.floor([...crypto.getRandomValues(new Uint32Array(1))].shift()/2**32*(e-t+1)+t)}function mt(){return`_${or(Qn).slice(0,8).join("")}`}function tr(e){return e=d(e,String)&&/,/.test(e)?e.split(",").map(t=>t.trim().toLowerCase()).filter(t=>t.length>0):e,d(e,Array)?e:d(e,String)&&e?.trim().toLowerCase()||""}function nr(e){return e?.isConnected?!![...document.querySelectorAll(":is(:modal)")].find(t=>t===e):!1}function rr(e,t){switch(e=String(e).trim(),!0){case/^(0|false|f)$/i.test(e):return!1;case/^(1|true|t)$/i.test(e):return!0;default:return t}}function or(e){let t=e.length;for(;t--;){let n=er(t);[e[t],e[n]]=[e[n],e[t]]}return e}function Ae(e){return d(e,String)?e.toLowerCase().split("-").map((t,n)=>n&&`${ir(t)}`||t).join(""):e}function R(e){return e.replace(/[A-Z]/g,t=>`-${t.toLowerCase()}`).replace(/^-|-$/,"")}function ir([e,...t]){return`${e.toUpperCase()}${t.join("")}`}function Le(e){return d(e,Comment,Text)}function dt(e){d(e,Comment)}function ar(e){return d(e,Text)}function ke(e){return d(e,String)&&/^<|>$/.test(`${e}`.trim())}function Ee(e){return d(e,Array)&&!e?.find(t=>!U(t))}function gt(e){return d(e,Array)&&!e?.find(t=>!ke(t))}function O(e,t){let n=e.collection.filter(r=>!Le(r));for(let r=0;r<n.length;r+=1)t(n[r],r);return e}function lr(e){return e.node?d(e.node,Comment)?`<!--${e.node.textContent}-->`:e.HTML.get(1).split(">")[0]+">...":""}function pt(e,t,n){let r=t!==document.body&&d(e,String)&&e.toLowerCase()!=="body"?t:document;try{n.collection=[...r.querySelectorAll(e)]}catch{L.warn(`JQx: Invalid CSS querySelector. [${d(e,String)?e:"Not a string!"}]`)}}function sr(){return{isCommentOrTextNode:Le,isNode:U,isComment:dt,isText:ar,isHtmlString:ke,isArrayOfHtmlElements:Ee,isArrayOfHtmlStrings:gt,ElemArray2HtmlString:Xn,input2Collection:ft,setCollectionFromCssSelector:pt,cssRuleEdit:at({createWithId:"JQxStylesheet"})}}function ur(){let e=Object.freeze({notInDOM:"n/a",writable:"n/a",modal:"n/a",empty:!0,open:"n/a",visible:"n/a"});return t=>{let n=t.node;return d(n,Node)?Object.freeze({get writable(){return Kn(n)},get modal(){return nr(n)},get inDOM(){return n.isConnected},get open(){return n.open??!1},get visible(){return Gn(n)},get disabled(){return n.hasAttribute("readonly")||n.hasAttribute("disabled")},get empty(){return t.collection.length<1},get virtual(){return t.isVirtual}}):e}}function cr(e,t,n,r){n&&d(t,String)&&(t={[t]:n==="-"?"":n});let o;t.className&&(o=t.className,delete t.className),o=[...e.classList].find(i=>i.startsWith("JQxClass-")||o&&i===o)||o||`JQxClass-${mt().slice(1)}`,r.editCssRule(`.${o}`,t),e.classList.add(o)}var fr=ur();function mr(e){return{factoryExtensions:dr(e),instanceExtensions:gr(e)}}function dr(e){return{data(t){return{get all(){return new Proxy(t[0]?.dataset??{},Un)},set(n={}){if(!t.is.empty&&d(n,Object))for(let[r,o]of Object.entries(n))t.setData({[r]:o});return t},get(n,r){return t.data.all[n]??r},add(n={}){if(!t.is.empty&&d(n,Object))for(let[r,o]of Object.entries(n))t.setData({[r]:o});return t},remove(n){return t[0]?.removeAttribute(`data-${R(n)}`),t}}},dimensions(t){if(t.is.empty)return L.error("[JQx instance].dimensions called on empty instance"),{error:"[JQx instance].dimensions: NO ELEMENTS"};let{node:n}=t,r=n.getBoundingClientRect().toJSON();return r.scrollTopDistance=Te(n,0),r.scrollLeftDistance=Te(n,0,!1),r},node(t){return t[0]},HTML(t){return{get(n,r){if(t.is.empty)return"NO ELEMENTS IN COLLECTION";let o=n?t.outerHtml:t.html();return r?ie(o):o},set(n,r=!1,o=!1){n=n.isJQx?n.HTML.get(1):n;let i=d(n,String);return n=i&&o?ie(n):n,i&&(n||"").trim().length&&t.html(n,r),t},replace(n,r=!1){return t.HTML.set(n,!1,r)},append(n,r=!1){return n=d(n,HTMLElement)?e(n).HTML.get(1):n.isJQx?n.HTML.get(1):n,t.HTML.set(n,!0,r)},insert(n,r=!1){return n=d(n,HTMLElement)?e(n).HTML.get(1):n.isJQx?n.HTML.get(1):n,t.HTML.set(n+t.HTML.get(),!1,r)}}},is(t){return fr(t)},length(t){return t.collection.length},outerHtml(t){return(t.first()||{outerHTML:void 0}).outerHTML},parent(t){let n=e(t[0]?.parentNode);return n.is.empty?t:n},render(t){switch(!0){case!t.is.empty:return t.toDOM();default:return e.logger.warn("[JQx.render]: empty collection"),t}},Style(t){return{get computed(){return t.is.empty?{}:getComputedStyle(t[0])},inline(n){return t.style(n)},inSheet(n){return t.css(n)},valueOf(n){return t.is.empty?void 0:getComputedStyle(t[0])[R(n)]},nwRule(n){return t.Style.byRule({rules:n})},byRule({classes2Apply:n=[],rules:r=[]}={}){let o=d(r,String)&&!n.length?r.split("{")[0].trim():"";if(r=r&&d(r,String)?[r]:r,n=n&&d(n,String)?[n]:n,(r?.length||n?.length)&&(r?.length&&e.editCssRules(...r),n))for(let i of n)t.addClass(i);return o?.startsWith(".")&&t.addClass(o.slice(1)),o?.startsWith("#")&&!t.attr("id")&&t.prop({id:o.slice(1)}),t}}}}}function gr(e){return{addClass(t,...n){return O(t,r=>r&&n.forEach(o=>r.classList.add(o)))},after:Xe,afterMe:Xe,andThen(t,n,r=!1){if(!n||!d(n,String,Node,Proxy))return L.log("[JQx instance].[before(Me) | after(Me) | andThen]: invalid/-sufficient input."),t;n=n?.isJQx?n:d(n,Node)?e.virtual(n):e.virtual(J(n));let[o,i,s]=r?[0,"before",n.collection.concat(t.collection)]:[t.collection.length-1,"after",t.collection.concat(n.collection)];return t[o][i](...n.collection),t.collection=s,t},append(t,...n){if(t.is.empty||n.length<1)return t;let r=t.length===1;for(let o of n){if(!o.isJQx&&C(o)){let i=o.trim(),s=/^<(.+)[^>]+>$/m.test(i)?J(o):e.text(o);O(t,u=>u.append(r?s:Q(s)))}U(o)&&O(t,i=>i.append(r?o:Q(o))),o.isJQx&&!o.is.empty&&O(t,i=>o.collection.forEach(s=>i.append(r?s:Q(s))))}return t},appendTo(t,n){switch(!0){case(!n.isJQx&&!d(n,HTMLElement)):return $.warn("[JQx instance].appendTo: invalid input"),t;default:return(n.isJQx?n:e(n)).append(t),t}},attr(t,n,r){if(!t.node||d(t.node,Text,Comment))return t;if(!r&&C(n))return n=R(n),n==="class"?[...t.node.classList].join(" "):t.node.getAttribute(n);if(C(n)&&r)switch(n=R(n),!0){case n.startsWith("data-"):n={data:{[n.replace("data-","")]:r}};break;default:n={[n]:r}}return d(n,Object)&&!t.is.empty&&_n(t.node,n),t},before:et,beforeMe:et,clear(t){return O(t,Ge)},closest(t,n){let r=C(n)?t.node?.closest(n):void 0;return r?e(r):t},computedStyle(t,n){let{node:r}=t;return r&&getComputedStyle(r)[n]},css(t,n,r){return O(t,o=>cr(o,n,r,e))},duplicate(t,n=!1,r=document.body){switch(!0){case t.is.empty:return L.error("Duplicating an empty JQx instance is not possible"),t;default:let o=t.collection[0].cloneNode(!0);return o.childNodes.forEach(i=>{i.removeAttribute&&i?.removeAttribute("id")}),n?e(o).toDOM(r):e.virtual(o)}},each(t,n){return O(t,n)},empty(t){return O(t,Ge)},find(t,n){return t.collection.length>0?[...t.first()?.querySelectorAll(n)]:[]},find$(t,n){return t.collection.length>0?e(n,t):t},first(t,n=!1){return t.collection.length>0?n?t.single():t.collection[0]:void 0},first$(t,n){return t.single(n)},getData(t,n,r){return t.node?.dataset?.[n]||r},hasClass(t,...n){return t.is.empty||!t.node.classList.length?!1:n.find(r=>t.node.classList.contains(r))&&!0||!1},hide(t){return O(t,n=>be(n,{display:"none !important"}))},html(t,n,r){switch(!0){case(t.is.empty&&!C(n)):return"";case!C(n):return t.node?.getHTML()??"";default:let o=J(`<div>${n.isJQx?n.HTML.get(!0):n}</div>`);return O(t,i=>(i.textContent=r?i.textContent:"",i.insertAdjacentHTML(e.at.end,o.getHTML())))}},htmlFor(t,n,r="",o=!1){if(t.is.empty||!C(n)||!C(r))return t;let i=t.find$(n);if(i.length<1)return t;let s=J(`<span>${r}</span>`);return i.each(u=>{o||(u.textContent=""),u.insertAdjacentHTML(e.at.end,s?.getHTML())}),t},isEmpty(t){return!t.node},nth$(t,n){return t.single(n)},on(t,n,...r){switch(!0){case(t.is.empty||!d(n,String,Array)||!C(n)||r.length<1):return t;default:return e.handle({type:n,node:t.node,handler:r}),t}},once(t,n,...r){switch(!0){case(t.is.empty||!d(n,String,Array)||!C(n)||r.length<1):return t;default:return e.handle({type:n,once:!0,node:t.node,handler:r}),t}},prepend(t,...n){if(t.is.empty||!n)return;let r=t.length===1;for(let o of n){if(C(o)){o=o.trim();let i=/^<(.+)[^>]+>$/m.test(o)?J(o):e.text(o);i=r?i:Q(i),O(t,s=>s.prepend(i.cloneNode(!0)))}U(o)&&O(t,i=>i.prepend(r?o:Q(o))),o.isJQx&&!o.is.empty&&(o.collection.length>1&&o.collection.reverse(),O(t,i=>O(o,s=>i.prepend(r?s:Q(s)))),o.collection.reverse())}return t},prependTo(t,n){return n.isJQx||(n=e.virtual(n)),n.prepend(t),t},prop(t,n,r){if(d(n,String)&&!r)return n.startsWith("data")?t[0]?.dataset[n.slice(n.indexOf("-")+1)]:t[0]?.[n];let o=d(n,Object)?n:{[n]:r};for(let[i,s]of Object.entries(o)){if(i=i.trim(),s&&!st(i)||!s)return!1;if(i.toLowerCase()==="id")return t[0].id=s;O(t,u=>{if(i.startsWith("data"))return u.dataset[i.slice(i.indexOf("-")+1)]=s;u[i]=s})}return t},remove(t,n){let r=i=>i.remove(),o=()=>t.collection=t.collection.filter(i=>document.documentElement.contains(i));if(n){let i=t.find$(n);return i.is.empty||(O(i,r),o()),t}return O(t,r),o(),t},rmAttr(t,...n){for(let r of n)t.node.removeAttribute(r);return t},removeClass(t,...n){return O(t,r=>{if(r)for(let o of n)r.classList.remove(o)})},renderTo(t,n,r){return n=d(n,HTMLElement)||n.isJQx?n:document.body,r=d(r,String)&&e.at[r]?r:e.at.end,t.first$().toDOM(n,r),t},replace(t,n,r){let o=t.node;return!n||!d(r,HTMLElement)&&!r?.isJQx?(e.logger.error("JQx replace: invalid replacement value"),t):((r.isJQx||d(r,NodeList))&&(r=r[0]),o&&n&&(n=d(n,String)?o.querySelectorAll(n):n.isJQx?n.collection:n,d(n,HTMLElement,NodeList,Array)&&d(r,HTMLElement)&&(d(n,HTMLElement)?[n]:[...n]).forEach(i=>i.replaceWith(r.cloneNode(!0)))),t)},replaceClass(t,n,...r){return O(t,o=>{o.classList.remove(n);for(let i of r)o.classList.add(i)})},replaceMe(t,n){return t.replaceWith(n)},replaceWith(t,n){return n=d(n,Element)?n:n.isJQx?n[0]:void 0,n&&(t[0].replaceWith(n),t=e.virtual(n)),t},setData(t,n){return O(t,r=>ct(r,n))},show(t){return O(t,n=>be(n,{display:"revert-layer !important"}))},single(t,n){let r=t.collection.length>0;switch(n=n??0,!0){case(r&&d(n,String)):return t.find$(n);case(r&&d(n,Number)):return e(t.collection[n]);case r:return t.collection[0];default:return t}},style(t,n,r){return O(t,o=>{r&&d(n,String)&&(n={[n]:r||"none"}),be(o,n)})},text(t,n,r=!1){switch(!0){case t.isEmpty():return t;case!d(n,String):return t.node.textContent;default:return O(t,o=>o.textContent=r?o.textContent+n:n)}},toDOM(t,n=document.body,r=z.BeforeEnd){return t.isVirtual=!1,$e(t.collection,n,r),t},toggleClass(t,n){return O(t,r=>r.classList.toggle(n))},toNodeList(t){return[...t.collection].map(n=>document.importNode(n,!0))},trigger(t,n,r,o){if(r=/Event]$/.test(d(r))?r:Event,o=d(o,Object)?{...o,bubbles:o.bubbles??!0}:{bubbles:!0},!t.is.empty){let i=new r(n,o);t.each(s=>s.dispatchEvent(i))}return t},val(t,n){switch(!0){case(t.is.empty||!d(t.node,HTMLInputElement,HTMLSelectElement,HTMLTextAreaElement)):return t;case!d(n,String):return t.node.value;default:return t.node.value=d(n,String)?n:"",t}}}}var Oe,ae,{isComment:zo,isText:Ho,isHtmlString:Ro,isArrayOfHtmlElements:Jo,isArrayOfHtmlStrings:Qo,ElemArray2HtmlString:Uo,cssRuleEdit:De,addFn:pr}=yr();function yr(){return{...sr(),addFn:hr}}function hr(e,t){return e=e?.trim(),!C(e)||!d(t,Function)?L.error("JQx.fn: method invalid parameter(s)"):ae[e]=(n,...r)=>t(n,...r)}function br(e){return function(t,n,r){if(t=t?.trim(),!C(t)||!d(n,Function))return e.error("JQx.staticFn: invalid parameter(s)");let o=r?{get(){return n()}}:{value(...i){return n(...i)}};try{Object.defineProperty(e,t,o)}catch{return e.warn(`JQx.staticFn: extension [${t}] already exists`)}return L.log(`JQx: added static extension function [${t}]`)}}function re(e){return new Proxy(e,Object.freeze({get:(t,n)=>Sr(t,n,e)}))}function tt(e,t){return(...n)=>d(e,Function)&&e(re(t),...n)}function Sr(e,t,n){switch(!0){case d(t,Symbol):return e;case d(+t,Number):return e.collection?.[t]||void 0;case t in Oe:return tt(Oe[t],n)();case t in ae:return tt(ae[t],n);default:return e[t]}}function xr(e){let t=Or(e);for(let[n,r]of Object.entries(Object.getOwnPropertyDescriptors(t)))Object.defineProperty(e,n,r);return e}function vr(e){return{allow(t){let n=/-/.test(t),r=n&&t;t=n?Ae(t):t.toLowerCase(),K.allowTag(t),Object.defineProperties(e,je(t,!0,e,r))},prohibit(t){t=t.toLowerCase(),K.prohibitTag(t),Object.defineProperties(e,je(t,!1,e))}}}function nt(...e){if(e.length===1){let t=String(e.shift().trim());e=t.startsWith("!")?[t.slice(1,-1)]:t.split(",").map(n=>n.trim())}for(let t of e.map(n=>n.startsWith("!")?n.slice(1,-1):n))De(t,{removeRule:1})}function $r(e){return function(t,n,r){n=n?.isJQx?n?.[0]:n,r=r&&Object.values(z).find(i=>r===i);let o=e(t,document.createElement("br"));if(n&&!d(n,HTMLBRElement))for(let i of o.collection)r?n.insertAdjacentElement(r,i):n.append(i);return o}}function wr(...e){let t={};for(let n of e){let r=Object.getOwnPropertyDescriptors(n);for(let[o,i]of Object.entries(r))!(o in t)&&Object.defineProperty(t,o,{...i,enumerable:!1})}return t}function Tr(e,t,n,r){return e=R(r||e.toLowerCase()),{get(){return(...o)=>{let i=t&&n.virtual(Ce(fn[e](...o)))||void 0,s=d(i?.node,Comment,Text,void 0)?"":Bn(i);return L.log(t?`JQx: created (virtual) instance from [JQx].${e} ${s}`:`JQx: ${e.toUpperCase()} is prohibited. Use [JQx].allowTag if necessary.`),i}},enumerable:!1,configurable:!0}}function je(e,t,n,r){e=e.toLowerCase();let o=Tr(e,t,n,r);return r?{[r]:o,[Ae(r)]:o}:{[e]:o,[e.toUpperCase()]:o}}function Or(e){return wr(Object.entries(K.tagsRaw).reduce(Dr(e),{}),kr(e))}function Dr(e){return function(t,[n,r]){return Object.defineProperties(t,je(n,r,e)),t}}function jr(e){return function(t,n,...r){d(n,Function)&&(r.push(n),n=void 0),e({type:t,selector:n,handlers:r})}}function Nr(e){return function(t){let{type:n,types:r,origin:o,selector:i,handler:s,handlers:u,node:p,name:y,capture:g,once:S,about:h}=t;s=u||s,n=r||n,i=o||i;let v=tr(n),b=y;s=d(s,Function)?[s]:s;let m={type:v,selector:i||o,capture:g,name:b,once:S,node:p,about:h};switch(!0){case(d(v,Array)&&v.length>0):for(let x of v)m.type=x,rt(s,m,e);break;default:return rt(s,m,e)}}}function rt(e,t,n){for(let r of e)n.listen({...t,handler:r})}function Cr(e){return function(t,n){return n=C(n)&&n,t=C(t)&&t,n&&t&&e.listenerStore[t][n]}}function Ar(e){return e.activePopup||Object.defineProperty(e,"activePopup",{value:Hn(e),enumerable:!1}),e.activePopup}function Lr(e){let t=(u,p)=>De(u,p),n=function(u){return at({createWithId:u||`jqx${mt()}`})},r=function(...u){for(let p of u)De(p)},o=vr(e),i=Rn(e),s=Nr(i);return{editCssRule:t,createStyle:n,editCssRules:r,allowProhibit:o,handle:s,capturedHandling:s,log:(...u)=>L.on.log(...u).off,warn:(...u)=>L.on.warn(...u).off,error:(...u)=>L.on.error(...u).off,handlerWrapper:i}}function kr(e){let{factoryExtensions:t,instanceExtensions:n}=mr(e);Oe=t,ae=n;let{editCssRule:r,createStyle:o,editCssRules:i,allowProhibit:s,handle:u,capturedHandling:p,log:y,warn:g,error:S,handlerWrapper:h}=Lr(e),v=Cr(e),b=br(e);return{log:y,warn:g,error:S,editCssRules:i,createStyle:o,editStylesheet:o,editCssRule:r,escHtml:ie,logger:L,text(m,x=!1){return x?e.comment(m):document.createTextNode(m)},node(m,x=document){return x.querySelector(m,x)},nodes(m,x=document){return[...x.querySelectorAll(m,x)]},clearAllTimers:Wn,get staticFn(){return function(m,x,T){return b(m,x,T)}},get toBool(){return rr},get getNamedListener(){return v},get virtual(){return $r(e)},get allowTag(){return s.allow},get prohibitTag(){return s.prohibit},get removeCssRule(){return nt},get removeCssRules(){return nt},get delegate(){return jr(p)},get delegateCaptured(){return p},get handle(){return p},get listen(){return h.listen},get at(){return z},get setStyle(){return r},get fn(){return pr},get lenient(){return K.allowUnknownHtmlTags},get IS(){return d},get Popup(){return Ar(e)},get listenerStore(){return h.ListenerStore}}}var Er=xr(Mr());function Mr(){return function(e,t,n=z.BeforeEnd){if(e?.isJQx)return e;let r=d(t,HTMLBRElement);t=(!r&&t&&t.isJQx?t[0]:t)||document.body,n=n&&Object.values(z).find(p=>n===p)?n:void 0;let o=ke(e),i=!o&>(e)||o,s={collection:ft(e)??[],isVirtual:r,isJQx:!0},u=Ee(s.collection);if(s.collection.length&&u)return r||s.collection.forEach(p=>{t.contains(p)||$e([p],t,n)}),re(s);if(i){if([e].flat().forEach(p=>s.collection.push(J(p))),s.collection.length>0){let p=s.collection.filter(S=>S?.dataset?.jqxcreationerror);s.collection=s.collection.filter(S=>!S?.dataset?.jqxcreationerror);let y=s.collection.map(S=>`${String(S.constructor).split(/function|\(/)[1].trim()}`).length>1;s=re(s);let g=s.collection.length>0?lr(s):"sanitized: no elements remaining";L.log(`JQx: created ${s.isVirtual?"(virtual)":""} instance from ${y?"array of ":""}HTML string${y?"s":""} ${g}`),s.isVirtual||$e(s.collection,t,n)}return s}return pt(e,t,s),re(s)}}var H=Er;var[W,q,Ze,Pe]=["2-digit","numeric","long","short"],le={fixed:{MM:{month:Ze},M:{month:Pe},m:{month:q},mm:{month:W},yyyy:{year:q},yy:{year:W},WD:{weekday:Ze},wd:{weekday:Pe},d:{day:q},dd:{day:W},h:{hour:q},hh:{hour:W},mi:{minute:q},mmi:{minute:W},s:{second:q},ss:{second:W},ms:{fractionalSecondDigits:3},tz:{timeZoneName:"shortOffset"},dl:{locale:"default"},h12:{hour12:!1},yn:{yearName:""},ry:{relatedYear:!0},msp:{fractionalSecond:!0}},dynamic:{tzn:e=>({timeZoneName:e.slice(4)}),hrc:e=>({hourCycle:`h${e.slice(4)}`}),ds:e=>({dateStyle:e.slice(3)}),ts:e=>({timeStyle:e.slice(3)}),tz:e=>({timeZone:e.slice(3)}),e:e=>({era:e.slice(2)}),l:e=>({locale:e.slice(2)})}},V={...le,retrieveDynamic(e){let t=e?.slice(0,e?.indexOf(":"));return le.dynamic[t]&&le.dynamic[t](e)},get re(){return new RegExp(`\\b(${Object.keys(le.fixed).join("|")})\\b`,"g")}},me=Ir;function Ir(e,t,n="l:default"){return/ds:|ts:/.test(n)?Zr(e,yt(void 0),n):Fr(e,yt(t||void 0),n)}function yt(e="dtf"){let t=` ${e.replace(/[{}]/g,"").trim()} `,n=e.match(/(?<=\{)(.+?)(?=})/g)||[];return{set formatStr(r){t=r},get formatStr(){return t},get units(){return t.match(V.re)||[]},finalize(r="",o="",i="",s=""){return t.replace(/~([\d+]?)/g,"$1").replace(/dtf/,r).replace(/era/,i).replace(/dp\b|~dp\b/,o).replace(/yn\b/,s).replace(/\[(\d+?)]/g,(u,p)=>n[p].trim()).trim()}}}function Lt(...e){return e?.reduce((t,n)=>({...t,...V.retrieveDynamic(n)||V.fixed[n]}),V.fixed.dl)}function Zr(e,t,n){let r=Lt(...kt(n).split(",")),o=Intl.DateTimeFormat(r.locale,r).format(e);return t.finalize(o)}function Pr(e,t){return e==="numeric"&&t.startsWith("0")?t.slice(1):t}function Fr(e,t,n){let r=Lt(...t.units.concat(kt(n).split(",")).flat()),o={...V.fixed},i=Intl.DateTimeFormat(r.locale,r).formatToParts(e).reduce((s,u)=>u.type==="literal"&&/[ ,/-]/.test(u.value)?s:{...s,[u.type]:Pr(r[u.type],u.value)},{});return o.ms=r.fractionalSecondDigits?o.msp:o.ms,o.yyyy=i.relatedYear?o.ry:o.yyyy,t.formatStr=t.formatStr.replace(V.re,s=>/^(M|MM)$/.test(s)?zr(e,r.locale,r.timeZone,/^M$/.test(s)):i[Object.keys(o[s]).shift()]||s),t.finalize(void 0,i.dayPeriod,i.era,i.yearName)}function zr(e,t,n,r){return e.toLocaleString(t,{timeZone:n,month:r?Pe:Ze})}function kt(e){return e.replace(/\s+/g,"")}var Hr=Rr;function Rr(){let e=(r,o)=>{let i=isNaN(new Date(r)),s=isNaN(new Date(o));if(s){let[u,p,y]=Array(3).fill("end date not valid");return{error:!0,message:u,full:p,clean:y}}if(i){let[u,p,y]=Array(3).fill("start date not valid");return{error:!0,message:u,full:p,clean:y}}if(i&&!s){let[u,p,y]=Array(3).fill("start- and/or end date are not valid");return{error:!0,message:u,full:p,clean:y}}return{error:!1}},t=n();return function({start:r,end:o,diffs:i={}}={}){let s=e(r,o),u=o>r?"+":"-";if(s.error)return s;let p=Math.abs(r-o),y=new Date(p),g=y.getUTCFullYear()-1970,S=y.getUTCMonth(),h=y.getUTCDate()-1,v=h%7,b=Math.floor(h/7),m=y.getUTCHours(),x=y.getUTCMinutes(),T=y.getUTCSeconds(),A=y.getUTCMilliseconds(),a=Math.floor(p/864e5);i={...i,fromUTC:r,toUTC:o,sign:"",years:g,months:S,days:h,hours:m,minutes:x,seconds:T,milliseconds:A,diffInDays:a},i.full=t({values:i,full:!0}),i.clean=t({values:i}),i.equalDates=i.clean==="Dates are equal";let l=m+x+T>0?"T":"";return i.clean!=="Dates are equal"&&(i.sign=u,i.jsPeriod=`${u}P${g>0?`${g}Y`:""}${S>0?`${S}M`:""}${b>0?`${b}W`:""}${v>0?`${v}D`:""}${l}${m>0?`${m}H`:""}${x>0?`${x}M`:""}${T>0?`${T}S`:""}`,i.ISOPeriod=`P${g>0?`${g}Y`:""}${S>0?`${S}M`:""}${h>0?`${h}D`:""}${l}${m>0?`${m}H`:""}${x>0?`${x}M`:""}${T>0?`${T}S`:""}`),i};function n(){let r=(...i)=>s=>i.reduce((u,p)=>p(u),s),o=(i,s)=>i===1?s.slice(0,-1):s;return r(({values:i,full:s})=>[Object.entries(i).filter(([u])=>/^(years|month|days|hours|minutes|seconds)/i.test(u)),s],([i,s])=>s?i:i.filter(([,u])=>s?+u:u>0),i=>i.reduce((s,[u,p])=>[...s,`${p} ${o(p,u)}`],[]),i=>i.length<1?"Dates are equal":`${i.slice(0,-1).join(", ")}${i.length>1?" and ":""}${i.slice(-1).shift()}`)}}var Jr=Qr;function Qr(){let e=Object.entries({year:"FullYear",month:"Month",date:"Date",day:"Date",hour:"Hours",minute:"Minutes",second:"Seconds",millisecond:"Milliseconds"}).reduce((r,[o,i])=>({...r,[o]:i,[`${o}s`]:i}),{}),t=!1,n=function(...r){let o=r.length===1;return t=r[0].trim().startsWith("subtract,"),t&&(r=o?r[0].trim().replace(/^subtract,/i,"").split(",").map(i=>i.trim()):r.filter(i=>!i.startsWith("subtract"))),o&&!t&&(r=r[0].split(",").map(i=>i.trim())),r.map(function(i){if(!i)return!1;let s=i.toLowerCase().split(/ {1,}/);return s.length<2?!1:s.map(u=>{u=`${u}`.trim().replace(/[^a-z0-9-+]/g,"");let p=parseInt(u,10);return Number.isNaN(p)?u:t?-p:+p})}).filter(i=>i)};return function(r,...o){if(o.length<1)return r;let i=n(...o);return i.length&&i.forEach(([s,u])=>{u=u,u=e[u],s&&u&&r[`set${u}`](r[`get${u}`]()+s)}),r}}var Et=Hr(),Mt=Gr(),F=Jr();function ht(e,...t){return F(e,...t),e}function Me(e,{start:t,end:n,future:r,past:o,include:i={start:!1,end:!1}}={}){let s=e.clone.UTC;return t=t?.value||t?.constructor===Date?D(t?.value||t).UTC:D.now.UTC,n=n&&n?.value||n?.constructor===Date?D(n?.value||n).UTC:D.now.UTC,s.milliseconds=0,t.milliseconds=0,n.milliseconds=0,r?t>n:o?t<n:(i.start?+s>=+t:+s>+t)&&(i.end?+s<=+n:+s<+n)}function bt(e,{zoneTime:t=!1,formatStr:n,moreOptions:r}={}){return r=t?e.localeInfo.formatOptions+(r?`,${r}`:""):j.formatOptions+(r?`,${r}`:""),t?(e.localeInfo||(e.localeInfo=j),me(e,n,r)):Ur(e,n,r)}function Ur(e,t,n){let r=e.clone.relocate(j);return n=(n||"").startsWith("+")?`${r.localeInfo.formatOptions},${n.slice(1)}`:n||r.localeInfo.formatOptions,me(r,t,n)}function Wr(e,t){let n=Et({start:e,end:t||e});return parseInt(`${n.sign}${n.diffInDays}`)}function St(e,t=!1){let{locale:n,timeZone:r}=t?e.localeInfo:j,o=qt(n,r),i=e.format("MM|WD",o).split("|");return{locale:n,timeZone:r,monthName:i[0],dayName:i[1],dayNames:Wt(n),monthNames:Qe(n)}}function xt(e,t=!1){let[n,r,o,i]=Fe(e,t),s={values4Timezone:t?j.timeZone:e.timeZone,hours:n,minutes:r,seconds:o,milliseconds:i};return Object.freeze(s)}function Fe(e,t=!1){let n=`l:en-CA,${t?`tz:${j.timeZone}`:`tz:${e.timeZone}`},hrc:23,ts:medium`;return e.format("",n).split(/:/).map(Number).concat(e.getMilliseconds())}function vt(e,t){let n=t?`tz:${j.timeZone}`:`,tz:${e.timeZone}`,[r,o,i]=e.format("yyyy-mm-dd",n).split(/-/).map(Number);o-=1;let s=t?j.timeZone:e.timeZone;return Object.freeze({values4Timezone:s,year:r,month:o,date:i})}function $t(e,t=!0){if(t)return[e.getFullYear(),e.getMonth(),e.getDate()];let n=e.format("yyyy-m-d",e.localeInfo.formatOptions).split(/-/).map(Number);return n[1]-=1,n}function qr(e,{sunday:t=!1}={}){return ze(e,{day:t?"sunday":"monday"})}function Br(e,t){let n=e.toString().match(/GMT([+-])\d+/)?.[0]?.slice(3)??"+0000",r=t.toString().match(/GMT([+-])\d+/)?.[0]?.slice(3)??"+0000";return n=He(n.slice(0,3)+":"+n.slice(-2),!0),r=He(r.slice(0,3)+":"+r.slice(-2),!0),[-n[0]+r[0],-n[1]+r[1]].map(o=>n[0]<0?-o:o)}function It({start:e,end:t}={}){t||(t=e.clone),t?.clone||(t=D(t,{timeZone:e.timeZone})),e=D(Dt(e,e.timeZone),{timeZone:e.timeZone}),t=D(Dt(t,t.timeZone),{timeZone:t.timeZone});let n=Et({start:e,end:t,diffs:{timeZoneStart:e.timeZone,timeZoneEnd:t.timeZone}}),r=Br(t,e),o=n.sign.startsWith("-")?"ahead of":"behind",[i,s]=r.map(y=>Math.abs(y)),[u,p]=[`${i} ${de(i,"hour")}`,`${s} ${de(s,"minute")}`];return n.timeZonesOffsetDifference=n.sign.length<1||i+s===0?`Offsets of ${e.timeZone} and ${t.timeZone} are equal`:`${e.timeZone} is ${u}${s>0?` and ${p}`:""} ${o} ${t.timeZone}`,n}function wt(e,t){t=String(t).toLowerCase()==="utc"||t.timeZone==="UTC"?e.clone.relocate({timeZone:"UTC"}):D(e.value,{timeZone:t.timeZone||j.timeZone});let n=It({start:e.clone,end:t}),r=`${n.sign}${Tt(n.hours)}:${Tt(n.minutes)}`;return{fromTZ:e.timeZone,toTZ:t.timeZone,offset:r,offsetText:`${t.timeZone} ${Vr(r)} ${e.timeZone}`}}function Tt(e,t=2){return`${e}`.padStart(t,"0")}function de(e,t){return`${t}${e>1||e===0?"s":""}`}function Vr(e){if(/00:00/.test(e))return"no time diffence to";let t=e.slice(1).split(":").map(Number),[n,r]=t,o=de(n,"hour"),i=de(r,"minute"),s=e.startsWith("+");return r>0?`${n} ${o} and ${r} ${i} ${s?"ahead of":"behind"}`:`${n} ${o} ${s?"ahead of":"behind"}`}function Ot(e,t,n){return e.clone.format(t,n||e.localeInfo.formatOptions)}function Yr(e,{withFormat:t,withFormatOptions:n,local:r=!1}={}){if(t)return r?Ot(e,t,$D.localeInformation.formatOptions):Ot(e,t,n);let o=e.clone.relocate({locale:"en"}),i=r?j.formatOptions:o.localeInfo.formatOptions,s=`wd M dd yyyy hh:mmi:ss ${o.format("tz",i+",tzn:longOffset").replace(":","")} (tz)`;return o.format(s,i+",tzn:long, hrc:23")}function Zt(e,t=!1){let n=Intl.DateTimeFormat("en",{timeZone:t?e.timeZone:j.timeZone,weekday:"short"});return Mt(n.format(e))}function _r(e){let t=j,n=e.localeInfo,r=e.clone.relocate({locale:t.locale,timeZone:t.timeZone}),o=e.offsetFrom(r),i=r.offsetFrom(e),s=t,u=n,p=e.format("hh:mmi:ss dp",`hrc:12,tz:${e.timeZone}`),y=r.format("hh:mmi:ss dp",`hrc:12,tz:${r.timeZone}`),g={note:"'user' are values for your locale/timeZone, 'remote' (if applicable) idem for the instance",locales:{user:{locale:s.locale,timeZone:s.timeZone}},dateTime:{user:{...e.dateTime,monthName:r.monthName,weekdayNr:r.day,weekdayName:r.dayName,dayPeriodTime:y,hasDST:r.hasDST,DSTActive:r.DSTActive,offsetFromRemote:o.offset,string:r.toString()}},offset:{fromUTC:e.UTC.offsetFrom(e).offsetText}};return n.timeZone!==t.timeZone&&(g.locales.remote={locale:u.locale,timeZone:u.timeZone},g.dateTime.remote={...e.zoneDateTime,monthName:e.zoneNames.monthName,weekdayNr:Zt(e,!0),weekdayName:e.zoneNames.dayName,dayPeriodTime:p,hasDST:e.hasDST,DSTActive:e.DSTActive,offsetFromUser:i.offset,string:e.toString()},g.offset.fromUserTime=i.offsetText),g}function se(e,t=!0){if(t)return[e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds()];let n=e.format("yyyy-m-d-hh-mmi-ss",`${e.localeInfo.formatOptions},hrc23:true`).split(/-/).map(Number).concat(e.getMilliseconds());return n[1]-=1,n}function Pt(e){return new Date(e.year,e.month+1,0,0,0,0).getDate()}function Ft(e,t){t=k({locale:t}).locale;let n=e.clone.relocate({locale:t});return n.date={date:1},[n].concat([...Array(Pt(n)-1)].map((r,o)=>n.clone.add(`${o+1} days`)))}function ze(e,{day:t,next:n=!1}={}){let r=Mt(t?.toLowerCase()),o=D(new Date(...e.dateTimeValues),e.localeInfo);return r<0?(console.error(`[TickTock instance].next/previous invalid day value ${t}`),o):zt(o,r,n?1:-1)}function zt(e,t,n){return F(e,`${n} day`).getDay()<t?zt(e,t,n):e}function ue(e,{dateOnly:t=!1,timeOnly:n=!1}={}){let{locale:r,timeZone:o}=e.localeInfo;return t?new Date(e).toLocaleDateString(r,{timeZone:o}):n?new Date(e).toLocaleTimeString(r,{timeZone:o}):new Date(e).toLocaleString(r,{timeZone:o})}function Dt(e,t){let n={timeZone:t,hourCycle:"h23"};return new Date(new Date(e).toLocaleString("en",n))}function X(e,{year:t,month:n,date:r}={}){return E(t)&&e.setFullYear(parseInt(t)),E(r)&&e.setDate(parseInt(r)),E(n)&&e.setMonth(parseInt(n)),e}function B(e,{hours:t,minutes:n,seconds:r,milliseconds:o}={}){return E(t)&&e.setHours(parseInt(t)),E(n)&&e.setMinutes(parseInt(n)),E(r)&&e.setSeconds(parseInt(r)),E(o)&&e.setMilliseconds(parseInt(o)),e}function Ht(e){return e?.constructor===Date||e?.value}function jt(e,t){return Ht(t)?D(t?.value||t,e.localeInfo):D.from(...e.dateTimeValues).relocate(e.localeInfo)}function Gr(){let e={short:["sun","mon","tue","wed","thu","fri","sat"],long:["sunday","monday","tuesday","wednesday","thursday","friday","saturday"]};return function(t){t=`${t}`.toLowerCase();let n=e.short.indexOf(t);return n<0?e.long.indexOf(t):n}}function He(e){let t=e.slice(1).split(/[-:]/).map(Number),n=e.startsWith("-");return t=t.map(r=>n?-r:r),t}function Kr(e){return e.time={hours:0,minutes:0,seconds:0,milliseconds:0},e}function Nt(e,t){return Intl.DateTimeFormat("en-CA",{timeZone:t,timeZoneName:"long"}).format(e).split(/,/)[1].trim()}function Rt(e,t){t=t||e?.timeZone||j.timeZone,e=e?.value?e:e?.constructor===Date?D(e,{timeZone:t}):D({timeZone:t});let n=e.year||e.getFullYear(),r=Nt(new Date(n,0,1),t),o=Nt(new Date(n,5,1),t);return r!==o}function Jt(e,t){return t=t||e?.timeZone||j.timeZone,e=e?.hasDST?e:e?.constructor===Date?D(e,{timeZone:t}):D({timeZone:t}),e.hasDST?!/standard/i.test(e.toString()):!1}function Xr(e,{locale:t,timeZone:n,l:r,tz:o}={}){return e.localeInfo=k({locale:r||t||e.l||e.locale,timeZone:o||n||e.tz||e.timeZone}),e}function eo(e,t){return Ht(t)&&(e=D(t.value||t,t.localeInfo||e.localeInfo)),e}function Je(e,t){let n=Qt(new Date(e,11,t||31));return n===1?Je(e,(t||31)-1):n}function Ct(e,t){let n=e.month;switch(!0){case n<3:return t?1:"First";case n<6:return t?2:"Second";case n<9:return t?3:"Third";case n<12:return t?4:"Fourth";default:return"unknown"}}function Qt(e){let t=new Date(e),n=(t.getDay()+6)%7;t.setDate(t.getDate()-n+3);let r=t.valueOf();return t.setMonth(0,1),t.getDay()!==4&&t.setMonth(0,1+(4-t.getDay()+7)%7),1+Math.ceil((r-t)/6048e5)}var Ut=to;function to({localeInfo:e,customMethods:t,dateValue:n}={}){let r,o={add(...i){return ht(r,...i)},between({start:i,end:s,include:u}={}){return Me(r,{start:i,end:s,include:u})},cloneWith(i){return jt(r,i)},daysUntil(i){return Wr(r,i)},differenceTo(i){return It({start:r,end:i})},differenceUntil(i){return r.differenceTo(i).clean},firstWeekday({sunday:i=!1,midnight:s=!1}={}){return qr(r,{sunday:i,midnight:s})},format(i,s){return bt(r,{formatStr:i,moreOptions:s})},fullMonth(i){return Ft(r,i)},isFuture(i){return Me(r,{start:r,end:i,future:!0})},isPast(i){return Me(r,{start:r,end:i,past:!0})},next(i){return ze(r,{day:i,next:!0})},offsetFrom(i){return wt(r,i)},previous(i){return ze(r,{day:i,next:!1})},relocate({locale:i,timeZone:s,l:u,tz:p}={}){return Xr(r,{locale:i,timeZone:s,l:u,tz:p})},revalue(i){return r=eo(r,i),r},setDateValues({year:i,month:s,date:u}={}){return X(r,{year:i,month:s,date:u})},setTimeValues({hours:i,minutes:s,seconds:u,milliseconds:p}={}){return B(r,{hours:i,minutes:s,seconds:u,milliseconds:p})},subtract(...i){return ht(r,"subtract,"+i.join(","))},toArray(i=!1){return se(r,i)},toString({template:i,formatOptions:s,local:u}={}){return Yr(r,{withFormat:i,withFormatOptions:s,local:u})},values(i=!1){return i?r.dateTime:r.zoneDateTime},zoneFormat(i,s){return bt(r,{zoneTime:!0,formatStr:i,moreOptions:s})},set date({year:i,month:s,date:u}){X(r,{year:i,month:s,date:u})},set dateNr(i){X(r,{date:i})},set hours(i){B(r,{hours:i})},set localeInfo({locale:i,timeZone:s,l:u,tz:p}){e=ce({locale:i,timeZone:s,l:u,tz:p})},set milliseconds(i){B(r,{milliseconds:`${i}`})},set minutes(i){B(r,{minutes:i})},set month(i){X(r,{month:i})},set seconds(i){B(r,{seconds:i})},set time({hours:i,minutes:s,seconds:u,milliseconds:p}){B(r,{hours:i,minutes:s,seconds:u,milliseconds:p})},set year(i){X(r,{year:i})},get age(){return r.differenceTo(new Date).years},get ageFull(){return r.differenceTo(new Date).clean},get clone(){return jt(r)},get date(){return vt(r,!0)},get dateNr(){return r.date.date},get dateTime(){return{...r.date,...r.time}},get dateTimeValues(){return se(r,!0)},get dateValues(){return $t(r,!0)},get day(){return r.getDay()},get dayName(){return r.names.dayName},get daysThisMonth(){return Pt(r)},get DSTActive(){return Jt(r)},get hasDST(){return Rt(r)},get hours(){return r.time.hours},get info(){return _r(r)},get isLeapYear(){return new Date(r.getFullYear(),2,0).getDate()===29},get ISO(){return r.toISOString()},get local(){return ue(r)},get localDate(){return ue(r,{dateOnly:!0})},get locale(){return(e||ce()).locale},get localeInfo(){return e},get localeString(){return ue(r)},get localTime(){return ue(r,{timeOnly:!0})},get milliseconds(){return r.getMilliseconds()},get minutes(){return r.time.minutes},get month(){return r.date.month},get monthName(){return r.names.monthName},get names(){return St(r)},get quarter(){return Ct(r)},get quarterNr(){return Ct(r,!0)},get removeTime(){return Kr(r)},get seconds(){return r.time.seconds},get time(){return xt(r,!0)},get timeValues(){return Fe(r,!0)},get timeZone(){return(e||ce()).timeZone},get unixEpochTimestamp(){return Math.floor(+r/1e3)},get userLocaleInfo(){return j},get UTC(){return r.clone.relocate({locale:r.locale,timeZone:"UTC"})},get UTCOffset(){return wt(r,"UTC")},get value(){return new Date(r)},get weeknr(){return Qt(r)},get weeksInYear(){return Je(r.year,31)},get year(){return r.date.year},get zoneDate(){return vt(r,!1)},get zoneDateNr(){return r.zoneDate.date},get zoneDateTime(){return{...r.zoneDate,...r.zoneTime}},get zoneDateTimeValues(){return se(r,!1)},get zoneDateValues(){return $t(r,!1)},get zoneDay(){return Zt(r,!0)},get zoneDayname(){return r.zoneNames.dayName},get zoneHours(){return r.zoneTime.hours},get zoneMinutes(){return r.zoneTime.minutes},get zoneMonth(){return r.zoneDate.month},get zoneMonthname(){return r.zoneNames.monthName},get zoneNames(){return St(r,!0)},get zoneSeconds(){return r.zoneTime.seconds},get zoneTime(){return xt(r)},get zoneTimeValues(){return Fe(r)},get zoneYear(){return r.zoneDate.year},get zoneValues(){return r.zoneDateTime},get zoneArray(){return se(r,!1)}};return!e&&!n?o:(o.localeInfo=e||ce(),r=new Proxy(n,no(o)),Object.entries(Object.getOwnPropertyDescriptors(Bt(r,t))).forEach(([i,s])=>Object.defineProperty(o,i,s)),Object.freeze(r))}function no(e){return{get(t,n){return n!=="toString"&&n in t?t[n].bind(t):Reflect.get(e,n)},set(t,n,r){return n in e&&Reflect.set(e,n,r)}}}var j=Re(Intl.DateTimeFormat().resolvedOptions()),ro=Object.getOwnPropertyNames(Date.prototype).filter(e=>e.startsWith("set")).reduce((e,t)=>[...e,{native:t,syn:"change"+t.slice(3)}],[]),Ie="\u{1F6AB}";function Wt(e="en-GB"){return e=k({locale:e}).locale,{long:[...Array(7).keys()].map(t=>new Date(Date.UTC(1970,0,4+t)).toLocaleDateString(e,{timeZone:"Etc/UTC",weekday:"long"})),short:[...Array(7).keys()].map(t=>new Date(Date.UTC(1970,0,4+t)).toLocaleDateString(e,{timeZone:"Etc/UTC",weekday:"short"}))}}function Qe(e="en"){return e=k({locale:e}).locale,{long:[...Array(12).keys()].map(t=>new Date(Date.UTC(1970,t,1)).toLocaleDateString(e,{timeZone:"Etc/UTC",month:"long"})),short:[...Array(12).keys()].map(t=>new Date(Date.UTC(1970,t,1)).toLocaleDateString(e,{timeZone:"Etc/UTC",month:"short"}))}}function oo({year:e,locale:t}={}){e=E(e)?parseInt(e):new Date().getFullYear();let n={year:e,calendar:{}},r=Qe().long.map(o=>o.toLowerCase());for(let o=0;o<12;o+=1){let i=D.from(e,o,1);n.calendar[r[o]]=Ft(i,t)}return n}function io({year:e,monthNr:t,locale:n="en-CA"}={}){e=E(t)&&parseInt(e)||-1,t=E(t)&&parseInt(t)||new Date().getFullYear();let r=t>=1&&t<=12;return n=k({locale:n}).locale,t=r?t-1:void 0,r?D.from(e,t,1).relocate({locale:n}).fullMonth(n):"MonthNr should be a specific number (1 = january - 12 = december)"}function Re(e){let t=qt(e.locale,e.timeZone);return Object.defineProperty(e,"formatOptions",{value:t,enumerable:!1})}function qt(e,t){return[`${e&&!(Array.isArray(e)&&e.length<1)?`l:${e}`:""}`,`${t?`tz:${t}`:""}`].filter(n=>n).join(",")}function k({locale:e,timeZone:t,l:n,tz:r}={}){return t=t||r,e=e||n,!e&&!t?j:lo({trial:function(){let o=Intl.DateTimeFormat(e,{timeZone:t}).resolvedOptions();return e&&o.locale!==e&&console.error(`${Ie} Intl changed locale (using best fit) "${e}" to "${o.locale}"`),Re(o)},onError:function(o){switch(!0){case/incorrect locale/i.test(o.message):return console.error(`${Ie} Intl locale "${e}" best fit impossible, using "${j.locale}"`),k({locale:j.locale,timeZone:t});case/invalid time zone/i.test(o.message):return console.error(`${Ie} timeZone "${t}" not valid. Using "${j.timeZone}"`),k({locale:e,timeZone:j.timeZone});default:return j||Re(Intl.DateTimeFormat().resolvedOptions())}}})}function ce({locale:e,timeZone:t,l:n,tz:r}={}){return k({locale:e,timeZone:t,l:n,tz:r},!0)}function At(e){return!Number.isNaN(+e)&&e?.constructor===Date&&!e?.toISOString?.().startsWith("1970-01-01T00:00:00")?e:new Date}function ao(e){let t=new Date;switch(!0){case e?.constructor===String:return At(new Date(e));case(Array.isArray(e)&&e.map(Number).length===e.length):return e.length===1?new Date(e[0],0,1):new Date(...e);case e?.constructor===Date:return At(e);default:return t}}function lo({trial:e,onError:t=()=>{}}={}){if(e?.constructor===Function)try{return e()}catch(n){return t?.constructor===Function?t(n):void 0}}function so({timeZoneDate:e,timeZoneID:t,userTimeZoneID:n}={}){let r={timeZone:k({timeZone:t}).timeZone},o={timeZone:k({timeZone:n||""}).timeZone},i=D(e,r),s=D(e,o),u=s.differenceTo(i),p=i.offsetFrom(s).offset,[y,g]=He(p,!0),S=s.clone.add(`${y} hours, ${g} minutes`),h=u.equalDates?"No difference":`Time offset ${p}: ${o.timeZone} is ${u.clean} ${y<0?"behind":"ahead of"} ${r.timeZone}`;return{remoteTimezone:r.timeZone,userTimezone:o.timeZone,timeDifference:h,result:{[r.timeZone.replace(/\//,"_")]:D(e).toString({template:"yyyy/mm/dd hh:mmi:ss",formatOptions:"hrc:23"}),[o.timeZone.replace(/\//,"_")]:S.toString({template:"yyyy/mm/dd hh:mmi:ss",formatOptions:"hrc:23"})}}}function E(e){return!Number.isNaN(parseInt(e))}function fe(e,t,n){return e?.constructor===Number?F(t,`${e} ${n}`):t}function uo(e){let t={addYears(n=1){return fe(n,e,"years")},addMonths(n=1){return fe(n,e,"months")},addWeeks(n=1){return n=n?.constructor===Number?n*7:1,fe(n,e,"days")},addDays(n=1){return fe(n,e,"days")},get nextYear(){return F(e,"1 year")},get nextWeek(){return F(e,"7 days")},get previousWeek(){return F(e,"-7 days")},get previousYear(){return F(e,"-1 year")},get nextMonth(){return F(e,"1 month")},get previousMonth(){return F(e,"-1 month")},get tomorrow(){return F(e,"1 day")},get yesterday(){return F(e,"-1 day")}};for(let n of ro)t[n.syn]=function(...r){return e[n.native](...r),e};return t}function Bt(e,t){let n=uo(e);for(let[r,o]of Object.entries(t||{})){let i=o.enumerable,s=o.isGetter?{get(){return o.method(e)},enumerable:i}:{value(...u){return o.method(e,...u)},enumerable:i};Object.defineProperty(n,r,s)}return n}function co(e,t){return Object.defineProperties(e,{now:{get(){return e(new Date)}},localeInformation:{get(){return k()}},localWeekdaynames:{value(n){return Wt(n)}},localMonthnames:{value(n){return Qe(n)}},daysInMonth:{value(n,r=!1){return n=E(n)?parseInt(n):0,n>=1&&n<=12?new Date(r?2e3:2005,n,0).getDate():`${n} should be a Number between (1 (january) - 12 (december))`}},yearCalendar:{value:oo},monthCalendar:{value:io},from:{value(...n){return e(n)}},fromUxTS:{value(n,r){n=E(n)?parseInt(n)*1e3:void 0;let o=n?new Date(n):new Date;return D(o,r||j)}},hasDST:{value({date:n,timeZone:r}={}){return Rt(n,r)}},DSTActive:{value({date:n,timeZone:r}={}){return Jt(n,r)}},values:{value({date:n,timeZone:r}={}){n=n||n?.value||new Date;let o=me(n,"yyyy-m-d-h-mi-s",k({timeZone:r}).formatOptions.concat(",hrc:23")).split("-").map(Number).concat(n.getMilliseconds());return o[1]-=1,o}},format:{value({date:n,template:r,timeZone:o,locale:i,opts:s}={}){n=n||n?.value||new Date,r=r?.constructor===String?r:"yyyy/mm/dd hh:mmi:ss dp";let u=k({timeZone:o,locale:i}).formatOptions;return u+=s?`,${s}`:"",me(n,r,u)}},addCustom:{value({name:n,method:r,enumerable:o=!1,isGetter:i=!1}={}){n?.constructor===String&&r?.constructor===Function&&r.length>0&&(t[n]={method:r,enumerable:o,isGetter:i})}},validateLocaleInformation:{value:k},timeAcrossZones:{value:so},weeksInYear:{value(n){return Je(n,31)}},keys:{get(){let n=Object.fromEntries(Object.entries(t).filter(([r,o])=>o.enumerable===!0));return[...Object.keys(Ut()),...Object.keys(Bt()),...Object.keys(n)].sort((r,o)=>r.localeCompare(o))}}}),e}var Vt={},D=co(fo,Vt);function fo(e,t){if(e?.localeInfo)return e.clone;let n=e?.locale||e?.timeZone||e?.tz||e?.l;return Ut({localeInfo:k(n?e:t),dateValue:new Date(n?Date.now():ao(e)),customMethods:Vt})}var Yt=Object.defineProperties(_t,{escape:{value:vo,enumerable:!0}});function _t(e,...t){let{flags:n,cleanedArgs:r}=go(...t);return yo(new RegExp($o(mo(e,...r)),n))}function mo(e,...t){return Y(t)?e.raw.reduce((n,r,o)=>n.concat(t[o-1]||"").concat(r),""):e.raw.join("")}function go(...e){let t=Ue(po(e.at(-1)));return{flags:t,cleanedArgs:Y(t)?e.slice(0,-1):e}}function po(e){return ge(e,Array)?e.join(""):""}function yo(e){let t=new Proxy(Object.defineProperties({},{re:{get(){return e},enumerable:!1},toString:{value:()=>e.toString(),enumerable:!1},valueOf:{value:()=>e,enumerable:!1},flags:{value(n){return e=xo(n,e),t},enumerable:!1},clone:{get(){return So(t)},enumerable:!1}}),bo(e));return t}function Y(e){return e?.length>0}function ge(e,t){return e?.constructor===t}function ho(e,t,n){let r=Reflect.get(n,t);return{fromInstance:Reflect.get(e,t),fromRegExpMethod:ge(r,Function)?r.bind(e.re):e.re[t]}}function bo(e){return{get(t,n){let{fromInstance:r,fromRegExpMethod:o}=ho(t,n,e);switch(!0){case!!r:return r;default:return o}}}}function So(e){let t=e.re.source,n=Y(e.re.flags)?[...e.re.flags]:[];return _t`${t} ${n}`}function Ue(e,t){return t=(t??"").replace(/^-r\|/,""),e=t.concat(ge(e,String)&&Y(e)?e:""),[...new Set([...e])].join("").replace(/[^dgimsuvy]/g,"")}function xo(e,t){switch(!0){case(!ge(e,String)||!Y(e)):return t;case e==="-r":return t=new RegExp(t.source);case e.startsWith("-r|"):return t=new RegExp(t.source,Ue(e));default:return t=new RegExp(t.source,Ue(t.flags,e))}}function vo(e){switch(!0){case(e?.constructor!==String||!Y(e)):return"";case!!RegExp.escape:return RegExp.escape(e);default:return(`\\x${e.at(0)}`+e.slice(1).replace(/\p{S}|\p{P}/gu,t=>`\\${t}`)).replace(/ |\\x /g,"\\x20")}}function $o(e){return e.replace(/\/\*(?:[^*]|\*+[^*\/])*\*+\/|(?<!:|\\\|')\/\/.*/gm,"").replace(/\s/g,"").trim().replace(/<!([^>]\d+)>/g,(t,n)=>String.fromCharCode(+n)??t)}var{IS:wo}=To(),_=wo;function To(){Symbol.proxy=Symbol.for("toa.proxy"),Symbol.is=Symbol.for("toa.is"),Symbol.type=Symbol.for("toa.type"),Symbol.isSymbol=Symbol.for("toa.isASymbol"),m();let e=S(),[t,n]=[h(),A()];return n.custom(),{IS:r,maybe:e,$Wrap:t,isNothing:g,xProxy:n};function r(a,...l){if(e({trial:f=>"isTypes"in(l?.[0]??{})})){let f=l[0];return"defaultValue"in f?v(a,f):"notTypes"in f?b(a,f):r(a,...[f.isTypes].flat())}let c=typeof a=="symbol"?Symbol.isSymbol:a;return l.length>1?y(c,...l):i(a,...l)}function o(a){return a?.[Symbol.proxy]??r(a)}function i(a,...l){let{noInput:c,noShouldbe:f,compareTo:w,inputCTOR:N,isNaN:M,isInfinity:I,shouldBeFirstElementIsNothing:Z}=u(a,...l);switch(l=l.length&&l[0],!0){case Z:return String(a)===String(w);case(a?.[Symbol.proxy]&&f):return a[Symbol.proxy];case M:return f?"NaN":e({trial:P=>String(w)})===String(a);case I:return f?"Infinity":e({trial:P=>String(w)})===String(a);case c:return f?String(a):String(w)===String(a);case N===Boolean:return l?N===l:"Boolean";default:return p(a,l,f,s(a,N))}}function s(a,l){return a===0?Number:a===""?String:a?l:{name:String(a)}}function u(a,...l){let c=l.length<1,f=!c&&l[0],w=!c&&g(l[0]),N=a==null,M=!N&&Object.getPrototypeOf(a)?.constructor,I=Number.isNaN(a)||e({trial:P=>String(a)==="NaN"}),Z=e({trial:P=>String(a)})==="Infinity";return{noInput:N,noShouldbe:c,compareTo:f,inputCTOR:M,isNaN:I,isInfinity:Z,shouldBeFirstElementIsNothing:w}}function p(a,l,c,f){switch(!0){case(!c&&l===a||a?.[Symbol.proxy]&&l===Proxy):return!0;case e({trial:w=>String(l)})==="NaN":return String(a)==="NaN";case(a?.[Symbol.toStringTag]&&r(l,String)):return String(l)===a[Symbol.toStringTag];default:return l?e({trial:w=>a instanceof l})||l===f||l===Object.getPrototypeOf(f)||`${l?.name}`===f?.name:a?.[Symbol.toStringTag]&&`[object ${a?.[Symbol.toStringTag]}]`||f?.name||String(f)}}function y(a,...l){return l.some(c=>r(a,c))}function g(a,l=!1){let c=a==null;return c=l?c||r(a,1/0)||r(a,NaN):c,c}function S(){let a=(l,c)=>l?.constructor===Function?l(c):void 0;return function({trial:l,whenError:c=()=>{}}={}){try{return a(l)}catch(f){return a(c,f)}}}function h(){return function(a){return Object.freeze({get value(){return a},get[Symbol.type](){return o(a)},get type(){return o(a)},[Symbol.is](...l){return r(a,...l)},is(...l){return r(a,...l)}})}}function v(a,{defaultValue:l,isTypes:c=[void 0],notTypes:f}={}){return c=c?.constructor!==Array?[c]:c,f=f&&f?.constructor!==Array?[f]:[],f.length<1?r(a,...c)?a:l:b(a,{isTypes:c,notTypes:f})?a:l}function b(a,{isTypes:l=[void 0],notTypes:c=[void 0]}={}){return l=l?.constructor!==Array?[l]:l,c=c?.constructor!==Array?[c]:c,r(a,...l)&&!r(a,...c)}function m(){Object.getOwnPropertyDescriptors(Object.prototype)[Symbol.is]||(Object.defineProperties(Object.prototype,{[Symbol.type]:{get(){return o(this)},enumerable:!1,configurable:!1},[Symbol.is]:{value:function(...a){return r(this,...a)},enumerable:!1,configurable:!1}}),Object.defineProperties(Object,{[Symbol.type]:{value(a){return o(a)},enumerable:!1,configurable:!1},[Symbol.is]:{value:function(a,...l){return r(a,...l)},enumerable:!1,configurable:!1}}))}function x(a){let l=String(Object.getPrototypeOf(a)?.constructor);return l.slice(l.indexOf("ion")+3,l.indexOf("(")).trim()}function T(a){let l=a.set;return a.set=(c,f,w)=>f===Symbol.proxy?c[f]=w:l(c,f,w),a}function A(){let a=Proxy;return{native(){Proxy=a},custom(){Proxy=new a(a,{construct(l,c){for(let w of c)w.set&&(w=T(w));let f=new l(...c);return f[Symbol.proxy]=`Proxy (${x(c[0])})`,f}})}}}}var We=Gt(void 0),Oo=Gt("");Object.defineProperties(String.prototype,{[Symbol.for("interpolate")]:{value(...e){return We(this,...e)}},[Symbol.for("interpolate$")]:{value(...e){return Oo(this,...e)}}});function Gt(e){return e=_(e,String,Number)?String(e):void 0,function(y,...g){return p(y,u(g))};function t(y,g){return g&&_(e,String,Number)?String(e):`{${y}}`}function n(y,g){let S=y in g;return S&&_(g[y],String,Number)?String(g[y]):t(y,S)}function r(y){return(...g)=>{let S=g.find(h=>h.key);return n(S?S.key:"_",y)}}function o(y,g){return y.replace(/\{(?<key>[a-z_\d]+)}/gim,r(g))}function i(y){let g=[];return Object.entries(y).forEach(([S,h])=>{h.forEach((v,b)=>(g[b]??={},g[b][S]=v))}),g}function s(y){return y.length===1&&Object.values(y[0]).every(Array.isArray)}function u(y){return s(y)?i(y[0]):y}function p(y,g){let S=g?.length?g.filter(h=>_(h,Object)).map((h,v)=>o(y,{...h,index:v+1})).join(""):y;return _(e,void 0)?S:S.replace(/\{[a-z_\d].+\}/gim,String(e))}}Co();Do();function Do(){/stackblitz/i.test(location.href)&&console.info("\u2714 Stackblitz rewrites links to _top. The 'stackblitzhelpers' module fixed it."),document.addEventListener("click",e=>{if(e.target.href){let t=e.target;if(t.dataset.top||t.classList.contains("internalLink")||t.target==="_top")return top.location.href=t.href}return!0})}function jo(e=!0){let t=H('<ul id="log2screen">').first();function n(i=!1){let s=i?H.at.start:H.at.end;return u=>{if(u?.isJQx)return H.li(u.data.get("header")?{class:"head"}:"",u).renderTo(t,s);u=H.IS(u,String,Number,Symbol)?String(u):No(u,e);let p=u.startsWith("!!");u=p?u.slice(2):u,H.li(p?{class:"head"}:"",u).renderTo(t,s)}}let[r,o]=[n(),n(!0)];return{log:(...i)=>i.forEach(r),logTop:(...i)=>i.forEach(o)}}function No(e,t){try{return t?`<pre>${JSON.stringify(e,null,2)}</pre>`:JSON.stringify(e)}catch{return"Some [Object object] can not be converted to JSON"}}function Co(){H.editCssRules("body{font:normal 14px/17px system-ui,sans-serif;margin:1rem;}","li::marker{vertical-align:top;}","code{color:green;background-color:#eee;padding:2px;font-family:monospace;}","code.codeblock{display:block;padding:6px;border:1px solid #999;margin:0.5rem 0;background-color:#eee;white-space:pre-wrap;}","h3{marginTop:1.5rem;}",".thickBorder{border:5px solid green;borderWidth:5px;padding:0.5rem;display:inline-block;}","a.ExternalLink{text-decoration:none;color:rgb(0,0,238);background-color:#EEE;padding:3px;font-weight:bold;}",".cmmt{color:#888;}",".hidden{display:none;}",".attention{color:red; font-size:1.2em; font-weight:bold;}","#log2screen li{listStyle:'\\2713';paddingLeft:6px;margin:0.5rem 0 0 -1.2rem;font-family:monospace}","#log2screen li.head{list-style-type:none;font-weight:bold;margin-top:0.8rem;margin-bottom:-0.2rem;font-family:revert;}",".err{fontStyle:italic; color:red; }","a{text-decoration:none; font-weight:bold;}","a:hover{text-decoration:underline;}","a[target]:before,a.internalLink:before,a.externalLink:before{color:rgba(0,0,238,0.7);font-size:1.1rem;padding-right:2px;vertical-align:baseline;}",`a[target="_blank"]:before,a.externalLink:before{content:'\\2197';}`,`a[data-top]:before,a.internalLink:before,a[target="_top"]:before{content:'\\21BA';}`)}return rn(Ao);})();
|