MCPcopy
hub / github.com/olton/metroui / zs

Function zs

lib/metro.js:55–55  ·  view source on GitHub ↗
(...e)

Source from the content-addressed store, hash-verified

53 }
54 `]);e=window.URL.createObjectURL(s)}catch{}let r,l={},t=0,o=2147483647,a="";function i(){do t===o?t=0:t++;while(l.hasOwnProperty(t));return t}if(!(typeof Worker>"u"))try{r=new Worker(e),window.setInterval=function(s,c){let p=i();return l[p]={callback:s,parameters:Array.prototype.slice.call(arguments,2)},r.postMessage({name:"setInterval",fakeId:p,time:c}),p},window.clearInterval=function(s){l.hasOwnProperty(s)&&(delete l[s],r.postMessage({name:"clearInterval",fakeId:s}))},window.setTimeout=function(s,c){let p=i();return l[p]={callback:s,parameters:Array.prototype.slice.call(arguments,2),isTimeout:!0},r.postMessage({name:"setTimeout",fakeId:p,time:c}),p},window.clearTimeout=function(s){l.hasOwnProperty(s)&&(delete l[s],r.postMessage({name:"clearTimeout",fakeId:s}))},window.setImmediate=function(s){return setTimeout(s,0)},window.clearImmediate=function(s){clearTimeout(s)},r.onmessage=function(s){let c=s.data,p=c.fakeId,d,m,h;if(l.hasOwnProperty(p)&&(d=l[p],h=d.callback,m=d.parameters,d.hasOwnProperty("isTimeout")&&d.isTimeout&&delete l[p]),typeof h=="string")try{h=new Function(h)}catch(u){console.error(a+"Error parsing callback code string: ",u)}typeof h=="function"&&h.apply(window,m)},r.onerror=function(s){console.error(s)}}catch{console.log("Can't create worker for Intervals, use standard functions.")}})();g.fn.extend({_getDefaultElement(e){let r;return O(e)?r=this[0]:e instanceof HTMLElement?r=e:e instanceof g&&e.length>0?r=e[0]:typeof e=="string"?r=g(e)[0]:r=void 0,r},index:function(e){let r,l=-1;return this.length===0||(r=this._getDefaultElement(e),!r)||r&&r.parentNode&&g.each(r.parentNode.children,function(t){this===r&&(l=t)}),l},indexOf:function(e){let r,l=-1;return this.length===0||(r=this._getDefaultElement(e),!r)||this.each(function(t){this===r&&(l=t)}),l},get:function(e){return e===void 0?this:e<0?this[e+this.length]:e>this.length-1?void 0:this[e]},eq:function(e){return O(e)?this:this.length>0?g.extend(g(this.get(e)),{_prevObj:this}):this},is:function(e){let r=!1;return this.length===0?!1:e instanceof g?this.same(e):(e===":selected"?this.each(function(){this.selected&&(r=!0)}):e===":checked"?this.each(function(){this.checked&&(r=!0)}):e===":visible"?(r=!1,this.each(function(){he(this)&&(r=!0)})):e===":hidden"?this.each(function(){let l=getComputedStyle(this);(this.getAttribute("type")==="hidden"||this.hidden||l.display==="none"||l.visibility==="hidden"||parseInt(l.opacity)===0)&&(r=!0)}):typeof e=="string"&&[":selected"].indexOf(e)===-1?this.each(function(){ht.call(this,e)&&(r=!0)}):ue(e)?this.each(function(){let l=this;g.each(e,function(){l===this&&(r=!0)})}):typeof e=="object"&&e.nodeType===1&&this.each(function(){this===e&&(r=!0)}),r)},same:function(e){let r=!0;return e instanceof g||(e=g(e)),this.length!==e.length?!1:(this.each(function(){e.items().indexOf(this)===-1&&(r=!1)}),r)},last:function(){return this.eq(this.length-1)},first:function(){return this.eq(0)},odd:function(){let e=this.filter(function(r,l){return(l+1)%2!==0});return g.extend(e,{_prevObj:this})},even:function(){let e=this.filter(function(r,l){return(l+1)%2===0});return g.extend(e,{_prevObj:this})},filter:function(e){if(typeof e=="string"){let r=e;e=function(l){return ht.call(l,r)}}return g.extend(g.merge(g(),[].filter.call(this,e)),{_prevObj:this})},find:function(e){let r=[],l;return e instanceof g?e:(this.length===0?l=this:(this.each(function(){let t=this;typeof t.querySelectorAll>"u"||(r=r.concat([].slice.call(t.querySelectorAll(e))))}),l=g.merge(g(),r)),g.extend(l,{_prevObj:this}))},contains:function(e){return this.find(e).length>0},children:function(e){let r,l=[];return e instanceof g?e:(this.each(function(){let t=this;for(r=0;r<t.children.length;r++)t.children[r].nodeType===1&&l.push(t.children[r])}),l=e?l.filter(function(t){return ht.call(t,e)}):l,g.extend(g.merge(g(),l),{_prevObj:this}))},parent:function(e){let r=[];if(this.length!==0)return e instanceof g?e:(this.each(function(){this.parentNode&&r.indexOf(this.parentNode)===-1&&r.push(this.parentNode)}),r=e?r.filter(function(l){return ht.call(l,e)}):r,r.length?g.extend(g.merge(g(),r),{_prevObj:this}):void 0)},parents:function(e){let r=[];if(this.length!==0)return e instanceof g?e:(this.each(function(){let l=this.parentNode;for(;l;)l.nodeType===1&&r.indexOf(l)===-1&&(O(e)||ht.call(l,e))&&r.push(l),l=l.parentNode}),g.extend(g.merge(g(),r),{_prevObj:this}))},siblings:function(e){let r=[];if(this.length!==0)return e instanceof g?e:(this.each(function(){let l=this;l.parentNode&&g.each(l.parentNode.children,function(){l!==this&&r.push(this)})}),e&&(r=r.filter(function(l){return ht.call(l,e)})),g.extend(g.merge(g(),r),{_prevObj:this}))},_siblingAll:function(e,r){let l=[];if(this.length!==0)return r instanceof g?r:(this.each(function(){let t=this;for(;t&&(t=t[e],!!t);)l.push(t)}),r&&(l=l.filter(function(t){return ht.call(t,r)})),g.extend(g.merge(g(),l),{_prevObj:this}))},_sibling:function(e,r){let l=[];if(this.length!==0)return r instanceof g?r:(this.each(function(){let t=this[e];t&&t.nodeType===1&&l.push(t)}),r&&(l=l.filter(function(t){return ht.call(t,r)})),g.extend(g.merge(g(),l),{_prevObj:this}))},prev:function(e){return this._sibling("previousElementSibling",e)},next:function(e){return this._sibling("nextElementSibling",e)},prevAll:function(e){return this._siblingAll("previousElementSibling",e)},nextAll:function(e){return this._siblingAll("nextElementSibling",e)},closest:function(e){let r=[];if(this.length===0)return;if(!e)return this.parent();let l=this[0];for(;l;){if(ht.call(l,e)){r.push(l);break}l=l.parentElement}return g.extend(g.merge(g(),r.reverse()),{_prevObj:this})},has:function(e){let r=[];if(this.length!==0)return this.each(function(){g(this).children(e).length>0&&r.push(this)}),g.extend(g.merge(g(),r),{_prevObj:this})},back:function(e){let r;if(e===!0)for(r=this._prevObj;r&&r._prevObj;)r=r._prevObj;else r=this._prevObj?this._prevObj:this;return r}});function ra(e,r=document.body){let l=document.createElement("script");if(l.type="text/javascript",O(e))return g(l);let t=g(e)[0];return t.src?l.src=t.src:l.textContent=t.innerText,t.type&&(l.type=t.type),t.async&&(l.async=t.async),r.appendChild(l),t.parentNode&&t.parentNode.removeChild(t),l}g.extend({script:function(e,r){if(!O(e))if(e instanceof g&&(e=e[0]),e.tagName&&e.tagName==="SCRIPT")ra(e,r);else{let l=g(e).find("script");g.each(l,function(){ra(this,r)})}},loadScript:function(e,r=document.body,l){let t=document.createElement("script");t.type="text/javascript",t.src=e,t.onload=l,r.appendChild(t)}});g.fn.extend({script:function(e){return this.each(function(){g.script(this,e)})}});g.fn.extend({_prop:function(e,r){return arguments.length===1?this.length===0?void 0:this[0][e]:(O(r)&&(r=""),this.each(function(){let l=this;l[e]=r,e==="innerHTML"&&g.script(l,l)}))},prop:function(e,r){return arguments.length===1?this._prop(e):this._prop(e,typeof r>"u"?"":r)},val:function(e){return O(e)?this.length===0?void 0:this[0].value:this.each(function(){let r=g(this);typeof this.value<"u"?this.value=e:r.html(e)})},html:function(e){let r=this,l=[];return arguments.length===0?this._prop("innerHTML"):(e instanceof g?e.each(function(){l.push(g(this).outerHTML())}):l.push(e),r._prop("innerHTML",l.join(`
55`)),this)},outerHTML:function(){return this._prop("outerHTML")},text:function(e){return arguments.length===0?this._prop("textContent"):this._prop("textContent",typeof e>"u"?"":e)},innerText:function(e){return arguments.length===0?this._prop("innerText"):this._prop("innerText",typeof e>"u"?"":e)},empty:function(){return this.each(function(){typeof this.innerHTML<"u"&&(this.innerHTML=""),typeof this.value<"u"&&(this.value="")})},clear:function(){return this.empty()}});g.each=function(e,r){let l=0;if(typeof e!="object"&&(e=[]),ue(e))[].forEach.call(e,function(t,o){r.apply(t,[o,t])});else for(let t in e)Rt(e,t)&&r.apply(e[t],[t,e[t],l++]);return e};g.fn.extend({each:function(e){return g.each(this,e)}});var ze=function(e){this.expando="DATASET:UID:"+e.toUpperCase(),ze.uid++};ze.uid=-1;ze.prototype={cache:function(e){let r=e[this.expando];return r||(r={},sa(e)&&(e.nodeType?e[this.expando]=r:Object.defineProperty(e,this.expando,{value:r,configurable:!0}))),r},set:function(e,r,l){let t,o=this.cache(e);if(typeof r=="string")o[dt(r)]=l;else for(t in r)Rt(r,t)&&(o[dt(t)]=r[t]);return o},get:function(e,r){let l=r===void 0?this.cache(e):e[this.expando]&&e[this.expando][dt(r)];if(r)return l!==void 0?l:e.getAttribute&&e.getAttribute("data-"+ts(r))||void 0;l={...e[this.expando]};for(let t of e.attributes)if(t.name.startsWith("data-")){let o=t.name.slice(5);l[dt(o)]=t.value}return Wt(l)?void 0:l},access:function(e,r,l){return r===void 0||r&&typeof r=="string"&&l===void 0?this.get(e,r):(this.set(e,r,l),l!==void 0?l:r)},remove:function(e,r){let l=e[this.expando];if(l!==void 0){if(r!==void 0){let t=Array.isArray(r)?r:[r];for(let o of t)delete l[dt(o)],e.removeAttribute&&e.removeAttribute("data-"+o)}return(r===void 0||Wt(l))&&(e.nodeType?e[this.expando]=void 0:delete e[this.expando]),!0}},hasData:function(e){let r=e[this.expando];return r!==void 0&&!Wt(r)}};var Ft=new ze("dom");g.extend({hasData:function(e){return Ft.hasData(e)},data:function(e,r,l){return Ft.access(e,r,l)},removeData:function(e,r){return Ft.remove(e,r)},dataSet:function(e){if(O(e))return Ft;if(["INTERNAL","DOM"].indexOf(e.toUpperCase())>-1)throw Error("You can not use reserved name for your dataset");return new ze(e)}});g.fn.extend({data:function(e,r){let l,t,o;if(this.length!==0){if(t=this[0],arguments.length===0){if(t&&(o=Ft.get(t),t.nodeType===1)){for(let a of t.attributes)if(a.name.startsWith("data-")){let i=a.name.slice(5);o[dt(i)]=a.value}}return o}return arguments.length===1&&(typeof e=="string"||Array.isArray(e))?(l=Ft.get(t,e),rs(l)):this.each(function(){Ft.set(this,e,r)})}},removeData:function(e){return typeof e>"u"?this:this.each(function(){let r=Array.isArray(e)?e:e.split(" ").map(l=>l.trim()).filter(l=>l!=="");for(let l of r)Ft.remove(this,l)})},origin:function(e,r,l){if(this.length===0)return this;if(O(e)&&O(r))return g.data(this[0]);if(O(r)){let t=g.data(this[0],"origin-"+e);return O(t)?l:t}return this.data("origin-"+e,r),this}});g.extend({device:/android|webos|iphone|ipad|ipod|blackberry|iemobile|opera mini/i.test(navigator.userAgent.toLowerCase()),localhost:oa(),isLocalhost:oa,touchable:es(),isPrivateAddress:os,hashCode:function(e){let r=0,l,t;if(e.length===0)return r;for(l=0;l<e.length;l++)t=e.charCodeAt(l),r=(r<<5)-r+t,r|=0;return r},uniqueId:function(e="salt"){let r;return typeof e=="function"?r=e.name:typeof e=="string"&&e?r=e:typeof e=="string"&&e.length===0?r="salt":r=e.toString(),"dom-"+g.hashCode(r)},toArray:function(e){let r,l=[];for(r=0;r<e.length;r++)l.push(e[r]);return l},import:function(e){let r=[];return this.each(e,function(){r.push(this)}),this.merge(g(),r)},merge:function(e,r){let l=+r.length,t=0,o=e.length;for(;t<l;t++)e[o++]=r[t];return e.length=o,e},type:function(e){return Object.prototype.toString.call(e).replace(/^\[object (.+)]$/,"$1").toLowerCase()},isSelector:function(e){if(typeof e!="string"||e.length===0||e==="#"||e===".")return!1;try{return document.querySelector(e),!0}catch{return!1}},remove:function(e){return g(e).remove()},isPlainObject:Xt,isEmptyObject:Wt,isArrayLike:ue,acceptData:sa,not:O,parseUnit:ce,getUnit:la,unit:ce,isVisible:he,isHidden:$l,matches:function(e,r){return ht.call(e,r)},random:function(e,r){return arguments.length===1&&ue(e)?e[Math.floor(Math.random()*e.length)]:Math.floor(Math.random()*(r-e+1)+e)},hasProp:Rt,dark:globalThis.matchMedia&&globalThis.matchMedia("(prefers-color-scheme: dark)").matches,serializeToArray:function(e){let r=g(e)[0];if(!r||r.nodeName!=="FORM"){console.warn("Element is not a HTMLFromElement");return}let l,t,o=[];for(l=r.elements.length-1;l>=0;l=l-1)if(r.elements[l].name!=="")switch(r.elements[l].nodeName){case"INPUT":switch(r.elements[l].type){case"checkbox":case"radio":r.elements[l].checked&&o.push(r.elements[l].name+"="+encodeURIComponent(r.elements[l].value));break;case"file":break;default:o.push(r.elements[l].name+"="+encodeURIComponent(r.elements[l].value))}break;case"TEXTAREA":o.push(r.elements[l].name+"="+encodeURIComponent(r.elements[l].value));break;case"SELECT":switch(r.elements[l].type){case"select-one":o.push(r.elements[l].name+"="+encodeURIComponent(r.elements[l].value));break;case"select-multiple":for(t=r.elements[l].options.length-1;t>=0;t=t-1)r.elements[l].options[t].selected&&o.push(r.elements[l].name+"="+encodeURIComponent(r.elements[l].options[t].value));break}break;case"BUTTON":switch(r.elements[l].type){case"reset":case"submit":case"button":o.push(r.elements[l].name+"="+encodeURIComponent(r.elements[l].value));break}break}return o},serialize:function(e){return g.serializeToArray(e).join("&")},viewport:function(){let e=window,r=document,l=r.documentElement,t=r.getElementsByTagName("body")[0],o=e.innerWidth||l.clientWidth||t.clientWidth,a=e.innerHeight||l.clientHeight||t.clientHeight;return{width:o,height:a}}});g.fn.extend({items:function(){return g.toArray(this)}});var as=Event.prototype.stopPropagation,is=Event.prototype.preventDefault;Event.prototype.stopPropagation=function(){this.isPropagationStopped=!0,as.apply(this,arguments)};Event.prototype.preventDefault=function(){this.isPreventedDefault=!0,is.apply(this,arguments)};Event.prototype.stop=function(e){return e?this.stopImmediatePropagation():this.stopPropagation()};g.extend({events:[],eventHooks:{},eventUID:-1,setEventHandler:function(e){let r,l=-1,t,o;if(this.events.length>0){for(r=0;r<this.events.length;r++)if(this.events[r].handler===null){l=r;break}}return t={element:e.el,event:e.event,handler:e.handler,selector:e.selector,ns:e.ns,id:e.id,options:e.options},l===-1?(this.events.push(t),o=this.events.length-1):(this.events[l]=t,o=l),o},getEventHandler:function(e){if(this.events[e]!==void 0&&this.events[e]!==null)return this.events[e]=null,this.events[e].handler},off:function(){return g.each(this.events,function(){this.element.removeEventListener(this.event,this.handler,!0)}),this.events=[],this},getEvents:function(){return this.events},getEventHooks:function(){return this.eventHooks},addEventHook:function(e,r,l="before"){return g.each(Gt(e),(t,o)=>{let a=dt(`${l}-${o}`);this.eventHooks[a]=r}),this},removeEventHook:function(e,r="before"){return g.each(Gt(e),(l,t)=>{delete this.eventHooks[dt(`${r}-${t}`)]}),this},removeEventHooks:function(e){let r=this;return O(e)?this.eventHooks={}:g.each(Gt(e),function(){delete r.eventHooks[dt("before-"+this)],delete r.eventHooks[dt("after-"+this)]}),this}});g.fn.extend({on:function(e,r,l,t){if(this.length!==0)return typeof r=="function"&&(t=l||{},l=r,r=void 0),typeof t!="object"&&(t={}),this.each(function(o,a){g.each(Gt(e),(i,s)=>{let c,p=s.split("."),d=xo(p[0]),m=t.ns?t.ns:p[1],h,u;g.eventUID++,c=f=>{let b=f.target,x=g.eventHooks[dt("before-"+d)],v=g.eventHooks[dt("after-"+d)];if(typeof x=="function"&&x.call(b,f),!r)l.call(a,f);else for(;b&&b!==a;){if(ht.call(b,r)&&(l.call(b,f),f.isPropagationStopped)){f.stopImmediatePropagation();break}b=b.parentNode}typeof v=="function"&&v.call(b,f),t.once&&(h=+g(a).origin("event-"+f.type+(r?":"+r:"")+(m?":"+m:"")),isNaN(h)||g.events.splice(h,1))},Object.defineProperty(c,"name",{value:l.name&&l.name!==""?l.name:"func_event_"+d+"_"+g.eventUID}),u=d+(r?":"+r:"")+(m?":"+m:""),a.addEventListener(d,c,Wt(t)?!1:t),h=g.setEventHandler({el:a,event:d,handler:c,selector:r,ns:m,id:g.eventUID,options:Wt(t)?!1:t}),g(a).origin("event-"+u,h)})})},one:function(e,r,l,t={}){return typeof r=="function"&&(t=l||{},l=r,r=void 0),t.once=!0,this.on.apply(this,[e,r,l,t])},off:function(e,r,l){return Xt(r)&&(l=r,r=null),Xt(l)||(l={}),O(e)||e.toLowerCase()==="all"?this.each(function(){let t=this;g.each(g.events,function(){let o=this;o.element===t&&(t.removeEventListener(o.event,o.handler,o.options),o.handler=null,g(t).origin("event-"+name+(o.selector?":"+o.selector:"")+(o.ns?":"+o.ns:""),null))})}):this.each(function(){let t=this;g.each(Gt(e),function(){let o=this.split("."),a=xo(o[0]),i=l.ns?l.ns:o[1],s,c;s="event-"+a+(r?":"+r:"")+(i?":"+i:""),c=g(t).origin(s),c!==void 0&&g.events[c].handler&&(t.removeEventListener(a,g.events[c].handler,g.events[c].options),g.events[c].handler=null),g(t).origin(s,null)})})},trigger:function(e,r){return this.fire(e,r)},fire:function(e,r){let l,t;if(this.length!==0)return l=xo(e),["focus","blur"].indexOf(l)>-1?(this[0][l](),this):(t=new CustomEvent(l,{bubbles:!0,cancelable:!0,detail:r}),this.each(function(){this.dispatchEvent(t)}))}});"blur focus resize scroll click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup contextmenu touchstart touchend touchmove touchcancel".split(" ").forEach(function(e){g.fn[e]=function(r,l,t){return arguments.length>0?this.on(e,r,l,t):this.fire(e)}});g.fn.extend({hover:function(e,r){return this.mouseenter(e).mouseleave(r||e)}});g.ready=function(e,r){document.addEventListener("DOMContentLoaded",e,r||!1)};g.load=function(e){return g(window).on("load",e)};g.unload=function(e){return g(window).on("unload",e)};g.fn.extend({unload:function(e){return this.length===0||this[0].self!==window?void 0:g.unload(e)}});g.beforeunload=function(e){return typeof e=="string"?g(window).on("beforeunload",function(r){return r.returnValue=e,e}):g(window).on("beforeunload",e)};g.fn.extend({beforeunload:function(e){return this.length===0||this[0].self!==window?void 0:g.beforeunload(e)}});g.fn.extend({ready:function(e){if(this.length&&this[0]===document&&typeof e=="function")return g.ready(e)}});g.ajax=function(e){return new Promise(function(r,l){let t=new XMLHttpRequest,o=(e.method||"GET").toUpperCase(),a=[],i=O(e.async)?!0:e.async,s=e.url,c,p=function(h,u){typeof h=="function"&&h.apply(null,u)},d=function(h){return["GET","JSON"].indexOf(h)!==-1},m=function(h){let u=[];return g.each(h,function(f,b){let x=Ml(b)?b:JSON.stringify(b);u.push(f+"="+x)}),u.join("&")};if(e.data instanceof HTMLFormElement){let h=e.data.getAttribute("action").trim(),u=e.data.getAttribute("method").trim();O(s)&&h&&(s=h),u&&(o=u.toUpperCase())}if(e.timeout&&(t.timeout=e.timeout),e.withCredentials&&(t.withCredentials=e.withCredentials),e.data instanceof HTMLFormElement)c=g.serialize(e.data);else if(e.data instanceof HTMLElement&&e.data.getAttribute("type")&&e.data.getAttribute("type").toLowerCase()==="file"){let h=e.data.getAttribute("name");c=new FormData;for(let u=0;u<e.data.files.length;u++)c.append(h,e.data.files[u])}else Xt(e.data)?c=m(e.data):e.data instanceof FormData||typeof e.data=="string"?c=e.data:(c=new FormData,c.append("_data",JSON.stringify(e.data)));d(o)&&(s+=typeof c=="string"?"?"+c:Wt(c)?"":"?"+JSON.stringify(c)),t.open(o,s,i,e.user,e.password),e.headers&&g.each(e.headers,function(h,u){t.setRequestHeader(h,u),a.push(h)}),d(o)||a.indexOf("Content-type")===-1&&e.contentType!==!1&&t.setRequestHeader("Content-type","application/x-www-form-urlencoded"),t.send(c),t.addEventListener("load",function(h){if(t.readyState===4&&t.status<300){let u=e.returnValue&&e.returnValue==="xhr"?t:t.response;if(e.parseJson)try{u=JSON.parse(u)}catch{u={}}p(r,[u]),p(e.onSuccess,[h,t])}else p(l,[t]),p(e.onFail,[h,t]);p(e.onLoad,[h,t])}),g.each(["readystatechange","error","timeout","progress","loadstart","loadend","abort"],function(){let h=dt("on-"+(this==="readystatechange"?"state":this));t.addEventListener(h,function(u){p(e[h],[u,t])})})})};["GET","POST","PUT","PATCH","DELETE","JSON"].forEach(function(e){g[e.toLowerCase()]=function(r,l,t){let o={method:e==="JSON"?"GET":e,url:r,data:l,parseJson:e==="JSON"};return g.ajax(g.extend({},o,t))}});g.fn.extend({load:function(e,r,l){let t=this;return this.length&&this[0].self===window?g.load(e):g.get(e,r,l).then(function(o){t.each(function(){this.innerHTML=o})})}});g.fn.extend({style:function(e,r){let l;function t(o,a,i){return["scrollLeft","scrollTop"].includes(a)?g(o)[a]():getComputedStyle(o,i)[a]}if(!(typeof e=="string"&&this.length===0)){if(this.length===0)return this;if(l=this[0],!e||e==="all")return getComputedStyle(l,r);{let o={},a=e.split(", ").map(function(i){return(""+dt(i)).trim()});return a.length===1?t(l,a[0],r):(g.each(a,function(){let i=this;o[this]=t(l,i,r)}),o)}}},removeStyleProperty:function(e){if(O(e)||this.length===0)return this;let r=e.split(", ").map(function(l){return(""+l).trim()});return this.each(function(){let l=this;g.each(r,function(){l.style.removeProperty(this)})})},removeStyle:function(e){if(!e)return this;let r=Gt(e,", ");return this.each(function(){let l=this;g.each(r,function(){l.style[this]=""})})},css:function(e,r){return e=e||"all",typeof e=="string"&&O(r)?this.style(e):this.each(function(l,t){typeof e=="object"?g.each(e,function(o,a){ea(t,o,a)}):typeof e=="string"&&ea(t,e,r)})},cssVar:function(e,r){if(!O(e))return O(r)?getComputedStyle(this[0]).getPropertyValue("--"+e):this.each(function(){this.style.setProperty("--"+e,r)})}});g.fn.extend({addClass:function(){},removeClass:function(){},toggleClass:function(){},containsClass:function(e){return this.hasClass(e)},hasClass:function(e){if(O(e))return!1;let r=!1,l=e.split(" ").filter(t=>(""+t).trim()!=="");return this.each(function(){let t=this;g.each(l,function(){!r&&t.classList&&t.classList.contains(this)&&(r=!0)})}),r},clearClasses:function(){return this.each(function(){this.className=""})},cls:function(e=!1){return this.length===0?void 0:e?this[0].className.split(" "):this[0].className},removeClassBy:function(e){return this.each(function(){let r=g(this),l=r.cls(!0);g.each(l,function(){let t=this;t.indexOf(e)>-1&&r.removeClass(t)})})},classNames:function(){let e=Array.prototype.slice.call(arguments,0),r=[];return g.each(e,function(l,t){typeof t=="string"?r.push(t):Xt(t)?g.each(t,function(o,a){a&&r.push(o)}):Ql()}),this.each(function(){this.className+=" "+r.join(" ")})}});["add","remove","toggle"].forEach(function(e){g.fn[e+"Class"]=function(r){let l=r?Array.isArray(r)?r:r.split(" ").filter(function(t){return!!t}):[];return l.length?this.each(function(){let t=this;typeof t.classList<"u"?g.each(l,function(a,i){t.classList[e](i)}):t.className+=l.join(" ")}):this}});g.parseHTML=function(e){let r,l,t=[],o,a,i=/^<([a-z][^\/\0>:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i;if(typeof e!="string"||e.trim()==="")return[];if(e=e.trim(),l=i.exec(e),l)t.push(document.createElement(l[1]));else{if(g.isSelector(e)){let s=document.querySelectorAll(e);if(s.length)for(let c of s)t.push(c);return t.length===0&&t.push(document.createTextNode(e)),t}o=document.implementation.createHTMLDocument(""),r=o.createElement("base"),r.href=document.location.href,o.head.appendChild(r),a=o.body,a.innerHTML=e;for(let s=0;s<a.childNodes.length;s++)t.push(a.childNodes[s].cloneNode(!0))}return t};g.fn.extend({_size:function(e,r){if(this.length!==0){if(O(r)){let l=this[0];if(e==="height")return l===window?window.innerHeight:l===document?l.body.clientHeight:parseInt(getComputedStyle(l).height);if(e==="width")return l===window?window.innerWidth:l===document?l.body.clientWidth:parseInt(getComputedStyle(l).width)}return this.each(function(){let l=this;l===window||l===document||(l.style[e]=isNaN(r)?r:+r==0?0:r+"px")})}},height:function(e){return this._size("height",e)},width:function(e){return this._size("width",e)},_sizeOut:function(e,r){let l,t,o,a;if(this.length===0)return;if(typeof r=="number")return this.each(function(){let c=this;if(c===window||c===document)return;let p,d=getComputedStyle(c),m=e==="width"?parseInt(d.borderLeftWidth)+parseInt(d.borderRightWidth):parseInt(d.borderTopWidth)+parseInt(d.borderBottomWidth),h=e==="width"?parseInt(d.paddingLeft)+parseInt(d.paddingRight):parseInt(d.paddingTop)+parseInt(d.paddingBottom);p=g(this)[e](r)[e]()-m-h,c.style[e]=p+"px"});let s=r===!0;return l=this[0],t=l[e==="width"?"offsetWidth":"offsetHeight"],o=getComputedStyle(l),a=t+parseInt(o[e==="width"?"marginLeft":"marginTop"])+parseInt(o[e==="width"?"marginRight":"marginBottom"]),s?a:t},outerWidth:function(e){return this._sizeOut("width",e)},outerHeight:function(e){return this._sizeOut("height",e)},padding:function(e){if(this.length===0)return;let r=getComputedStyle(this[0],e);return{top:parseInt(r.paddingTop),right:parseInt(r.paddingRight),bottom:parseInt(r.paddingBottom),left:parseInt(r.paddingLeft)}},margin:function(e){if(this.length===0)return;let r=getComputedStyle(this[0],e);return{top:parseInt(r.marginTop),right:parseInt(r.marginRight),bottom:parseInt(r.marginBottom),left:parseInt(r.marginLeft)}},border:function(e){if(this.length===0)return;let r=getComputedStyle(this[0],e);return{top:parseInt(r.borderTopWidth),right:parseInt(r.borderRightWidth),bottom:parseInt(r.borderBottomWidth),left:parseInt(r.borderLeftWidth)}}});g.fn.extend({offset:function(e){if(e===void 0){if(this.length===0)return;let r=this[0].getBoundingClientRect();return{top:r.top+(window.scrollY||window.pageYOffset||document.documentElement.scrollTop||0),left:r.left+(window.scrollX||window.pageXOffset||document.documentElement.scrollLeft||0)}}return this.each(function(){let{top:r,left:l}=e,t=g(this),o=getComputedStyle(this).position,a=this.getBoundingClientRect(),i={top:a.top+(window.scrollY||window.pageYOffset||0),left:a.left+(window.scrollX||window.pageXOffset||0)};o==="static"&&t.css("position","relative"),["absolute","fixed"].indexOf(o)===-1&&(r=r-i.top,l=l-i.left),r&&t.css("top",r),l&&t.css("left",l)})},position:function(e=!1){let r=0,l=0,t,o;if(this.length!==0)return t=this[0],o=getComputedStyle(t),e&&(r=parseInt(o.marginLeft),l=parseInt(o.marginTop)),{left:t.offsetLeft-r,top:t.offsetTop-l}},left:function(e,r){if(this.length!==0)return O(e)?this.position(r).left:typeof e=="boolean"?(r=e,this.position(r).left):this.each(function(){g(this).css({left:e})})},top:function(e,r=!1){if(this.length!==0)return O(e)?this.position(r).top:typeof e=="boolean"?(r=e,this.position(r).top):this.each(function(){g(this).css({top:e})})},rect:function(){return this.length===0?void 0:this[0].getBoundingClientRect()},pos:function(){if(this.length===0)return;let e=g(this[0]);return{top:parseInt(e.style("top")),left:parseInt(e.style("left"))}}});g.fn.extend({attr:function(e,r){let l={};if(!(this.length===0&&arguments.length===0))return this.length&&arguments.length===0?(g.each(this[0].attributes,function(){l[this.name]=this.value}),l):arguments.length===1&&typeof e=="string"?this.length&&this[0].nodeType===1&&this[0].hasAttribute(e)?this[0].getAttribute(e):void 0:this.each(function(){let t=this;Xt(e)?g.each(e,function(o,a){t.setAttribute(o,a)}):t.setAttribute(e,r)})},removeAttr:function(e){let r;return e?(r=typeof e=="string"?e.split(",").map(function(l){return l.trim()}):e,this.each(function(){let l=this;g.each(r,function(){l.hasAttribute(this)&&l.removeAttribute(this)})})):this.each(function(l,t){let o=g(t).attr();g.each(o,function(a){t.removeAttribute(a)})})},toggleAttr:function(e,r){return this.each(function(){let l=this;O(r)?l.removeAttribute(e):l.setAttribute(e,r)})},id:function(e){return typeof e>"u"?this.length===1?g(this[0]).attr("id"):this.map(r=>g(r).attr("id")):this.each(function(){g(this).attr("id",e)})},title:function(e){return typeof e>"u"?this.length?g(this[0]).attr("title"):void 0:this.each(function(){g(this).attr("title",e)})},href:function(e){return typeof e>"u"?this.length&&this[0].tagName==="A"?this[0].href:void 0:this.each(function(){this.tagName==="A"&&(this.href=e)})},name:function(e){return typeof e>"u"?this.length&&this[0].name?this[0].name:void 0:this.each(function(){this.name&&(this.name=e)})},src:function(e){return typeof e>"u"?this.length&&this[0].src?this[0].src:void 0:this.each(function(){this.src&&(this.src=e)})}});g.extend({meta:function(e){return O(e)?g("meta"):g("meta[name='$name']".replace("$name",e))},metaBy:function(e){return O(e)?g("meta"):g("meta[$name]".replace("$name",e))},doctype:function(){return g("doctype")},html:function(){return g("html")},head:function(){return g("html").find("head")},body:function(){return g("body")},document:function(){return g(document)},window:function(){return g(window)},charset:function(e){if(e){let r=g("meta[charset]");r.length>0&&r.attr("charset",e)}return document.characterSet},lang:function(e){if(e){let r=g("html");r.length>0&&r.attr("lang",e)}return document.documentElement.lang},title:function(e){if(typeof e>"u")return document.title;document.title=e}});g.extend({bind:(e,r)=>e.bind(r)});(function(e){e.forEach(function(r){["append","prepend"].forEach(function(l){Rt(r,l)||Object.defineProperty(r,l,{configurable:!0,enumerable:!0,writable:!0,value:function(){let t=Array.prototype.slice.call(arguments),o=document.createDocumentFragment();t.forEach(function(a){let i=a instanceof Node;o.appendChild(i?a:document.createTextNode(String(a)))}),l==="prepend"?this.insertBefore(o,this.firstChild):this.appendChild(o)}})})})})([Element.prototype,Document.prototype,DocumentFragment.prototype]);var It=function(e){let r;return typeof e=="string"?r=g.isSelector(e)?g(e):g.parseHTML(e):e instanceof HTMLElement?r=[e]:ue(e)&&(r=e),r};g.fn.extend({appendText:function(e){return this.each(function(r,l){l.innerHTML+=e})},prependText:function(e){return this.each(function(r,l){l.innerHTML=e+l.innerHTML})},append:function(e){let r=It(e);return this.each(function(l,t){g.each(r,function(){if(t===this)return;let o=l===0?this:this.cloneNode(!0);o.tagName&&o.tagName==="SCRIPT"?g.script(o,t):t.append(o)})})},appendTo:function(e){let r=It(e);return this.each(function(l,t){g.each(r,function(o,a){t!==this&&a.append(o===0?t:t.cloneNode(!0))})})},prepend:function(e){let r=It(e);return this.each(function(l,t){g.each(r,function(){if(t===this)return;let o=l===0?this:this.cloneNode(!0);g.script(o),o.tagName&&o.tagName!=="SCRIPT"&&t.prepend(o)})})},prependTo:function(e){let r=It(e);return this.each(function(){let l=this;g.each(r,function(t,o){l!==this&&g(o).prepend(t===0?l:l.cloneNode(!0))})})},insertBefore:function(e){let r=It(e);return this.each(function(){let l=this;g.each(r,function(t){if(l===this)return;let o=this.parentNode;o&&o.insertBefore(t===0?l:l.cloneNode(!0),this)})})},insertAfter:function(e){let r=It(e);return this.each(function(){let l=this;g.each(r,function(t,o){if(l===this)return;let a=this.parentNode;a&&a.insertBefore(t===0?l:l.cloneNode(!0),o.nextSibling)})})},after:function(e){return this.each(function(){let r=this;typeof e=="string"?r.insertAdjacentHTML("afterend",e):g(e).insertAfter(r)})},before:function(e){return this.each(function(){let r=this;typeof e=="string"?r.insertAdjacentHTML("beforebegin",e):g(e).insertBefore(r)})},clone:function(e=!1,r=!1){let l=[];return this.each(function(){let t=this.cloneNode(e),o=g(t),a;r&&g.hasData(this)&&(a=g(this).data(),g.each(a,function(i,s){o.data(i,s)})),l.push(t)}),g.merge(g(),l)},import:function(e){let r=[];return O(e)&&(e=!1),this.each(function(){r.push(document.importNode(this,e))}),g.merge(g(),r)},adopt:function(){let e=[];return this.each(function(){e.push(document.adoptNode(this))}),g.merge(g(),e)},remove:function(e){let r=0,l,t,o=[];if(this.length!==0){for(t=e?this.filter(function(a){return ht.call(a,e)}):this.items();(l=t[r])!=null;r++)l.parentNode&&(o.push(l.parentNode.removeChild(l)),g.removeData(l));return g.merge(g(),o)}},wrap:function(e){if(this.length===0)return;let r=g(It(e));if(!r.length)return;let l=[];return this.each(function(){let t,o;for(o=r.clone(!0,!0),o.insertBefore(this),t=o;t.children().length;)t=t.children().eq(0);t.append(this),l.push(o)}),g(l)},wrapAll:function(e){let r,l,t;if(this.length!==0&&(r=g(It(e)),!!r.length)){for(l=r.clone(!0,!0),l.insertBefore(this[0]),t=l;t.children().length;)t=t.children().eq(0);return this.each(function(){t.append(this)}),l}},wrapInner:function(e){if(this.length===0)return;let r=g(It(e));if(!r.length)return;let l=[];return this.each(function(){let t=g(this),o=t.html(),a=r.clone(!0,!0);t.html(a.html(o)),l.push(a)}),g(l)}});g.extend({animation:{duration:1e3,ease:"linear",elements:{}}});typeof window.setupAnimation=="object"&&g.each(window.setupAnimation,function(e,r){typeof g.animation[e]<"u"&&!O(r)&&(g.animation[e]=r)});var ns=["translateX","translateY","translateZ","rotate","rotateX","rotateY","rotateZ","scale","scaleX","scaleY","scaleZ","skew","skewX","skewY"],ls=["opacity","zIndex"],ss=["opacity","volume"],cs=["scrollLeft","scrollTop"],ps=["opacity","volume"];function ca(e){return e instanceof HTMLElement||e instanceof SVGElement}function ds(e,r){let l=/^(\*=|\+=|-=)/.exec(e);if(!l)return e;let t=la(e)||0,o=parseFloat(r),a=parseFloat(e.replace(l[0],""));switch(l[0][0]){case"+":return o+a+t;case"-":return o-a+t;case"*":return o*a+t;case"/":return o/a+t}}function ms(e,r,l){return typeof e[r]<"u"?cs.indexOf(r)>-1?r==="scrollLeft"?e===window?scrollX:e.scrollLeft:e===window?scrollY:e.scrollTop:e[r]||0:e.style[r]||getComputedStyle(e,l)[r]}function hs(e,r,l,t,o){O(o)&&(o=!1),r=dt(r),o&&(l=parseInt(l)),ca(e)?typeof e[r]<"u"?e[r]=l:e.style[r]=r==="transform"||r.toLowerCase().indexOf("color")>-1?l:l+t:e[r]=l}function us(e,r,l){g.each(r,function(t,o){hs(e,t,o[0]+o[2]*l,o[3],o[4])})}function pa(e){if(!ca(e))return{};let r=e.style.transform||"",l=/(\w+)\(([^)]*)\)/g,t={},o;for(;o=l.exec(r);)t[o[1]]=o[2];return t}function vo(e){return/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(e||"#000000").slice(1).map(function(l){return parseInt(l,16)})}function fs(e,r){return getComputedStyle(e)[r].replace(/[^\d.,]/g,"").split(",").map(function(l){return parseInt(l)})}function gs(e,r,l){let t=[],o=pa(e);g.each(r,function(a,i){let s=i[0],c=i[1],p=i[2],d=i[3];a=""+a,(a.indexOf("rotate")>-1||a.indexOf("skew")>-1)&&d===""&&(d="deg"),a.indexOf("scale")>-1&&(d=""),a.indexOf("translate")>-1&&d===""&&(d="px"),d==="turn"?t.push(a+"("+c*l+d+")"):t.push(a+"("+(s+p*l)+d+")")}),g.each(o,function(a,i){r[a]===void 0&&t.push(a+"("+i+")")}),e.style.transform=t.join(" ")}function bs(e,r,l){g.each(r,function(t,o){let a,i=[0,0,0],s;for(a=0;a<3;a++)i[a]=Math.floor(o[0][a]+o[2][a]*l);s="rgb("+i.join(",")+")",e.style[t]=s})}function aa(e){let r=/^#?([a-f\d])([a-f\d])([a-f\d])$/i;return e[0]==="#"&&e.length===4?"#"+e.replace(r,function(l,t,o,a){return t+t+o+o+a+a}):e[0]==="#"?e:"#"+e}function ia(e,r,l){us(e,r.props,l),gs(e,r.transform,l),bs(e,r.color,l)}function xs(e,r,l){let t={props:{},transform:{},color:{}},o,a,i,s,c,p,d=pa(e);return O(l)&&(l="normal"),g.each(r,function(m,h){let u=ns.indexOf(""+m)>-1,f=ls.indexOf(""+m)>-1,b=(""+m).toLowerCase().indexOf("color")>-1;if(Array.isArray(h)&&h.length===1&&(h=h[0]),Array.isArray(h)?(a=b?vo(aa(h[0])):ce(h[0]),i=b?vo(aa(h[1])):ce(h[1])):(u?a=d[m]||m==="scale"?1:0:b?a=fs(e,m):a=ms(e,m,void 0),a=b?a:ce(a),i=b?vo(h):ce(ds(h,Array.isArray(a)?a[0]:a))),ps.indexOf(""+m)>-1&&a[0]===i[0]&&(a[0]=i[0]>0?0:1),l==="reverse"&&(p=a,a=i,i=p),c=e instanceof HTMLElement&&i[1]===""&&!f&&!u?"px":i[1],b)for(s=[0,0,0],o=0;o<3;o++)s[o]=i[o]-a[o];else s=i[0]-a[0];u?t.transform[m]=[a[0],i[0],s,c]:b?t.color[m]=[a,i,s,c]:t.props[m]=[a[0],i[0],s,c,ss.indexOf(""+m)===-1]}),t}function na(e,r,l){return Math.min(Math.max(e,r),l)}var At={linear:function(){return function(e){return e}}};At.default=At.linear;var ko={Sine:function(){return function(e){return 1-Math.cos(e*Math.PI/2)}},Circ:function(){return function(e){return 1-Math.sqrt(1-e*e)}},Back:function(){return function(e){return e*e*(3*e-2)}},Bounce:function(){return function(e){let r,l=4;for(;e<((r=Math.pow(2,--l))-1)/11;);return 1/Math.pow(4,3-l)-7.5625*Math.pow((r*3-2)/22-e,2)}},Elastic:function(e,r){O(e)&&(e=1),O(r)&&(r=.5);let l=na(e,1,10),t=na(r,.1,2);return function(o){return o===0||o===1?o:-l*Math.pow(2,10*(o-1))*Math.sin((o-1-t/(Math.PI*2)*Math.asin(1/l))*(Math.PI*2)/t)}}};["Quad","Cubic","Quart","Quint","Expo"].forEach(function(e,r){ko[e]=function(){return function(l){return Math.pow(l,r+2)}}});Object.keys(ko).forEach(function(e){let r=ko[e];At["easeIn"+e]=r,At["easeOut"+e]=function(l,t){return function(o){return 1-r(l,t)(1-o)}},At["easeInOut"+e]=function(l,t){return function(o){return o<.5?r(l,t)(o*2)/2:1-r(l,t)(o*-2+2)/2}}});var vs={id:null,el:null,draw:{},dur:g.animation.duration,ease:g.animation.ease,loop:0,pause:0,dir:"normal",defer:0,onStart:function(){},onStop:function(){},onStopAll:function(){},onPause:function(){},onPauseAll:function(){},onResume:function(){},onResumeAll:function(){},onFrame:function(){},onDone:function(){}};function wo(e){return new Promise(function(r){let l=this,t=g.assign({},vs,{dur:g.animation.duration,ease:g.animation.ease},e),o=t.id,a=t.el,i=t.draw,s=t.dur,c=t.ease,p=t.loop,d=t.onStart,m=t.onFrame,h=t.onDone,u=t.pause,f=t.dir,b=t.defer,x={},v="linear",z=[],C=At.linear,y,k=f==="alternate"?"normal":f,w=!1,S=o||+(performance.now()*Math.pow(10,14));if(O(a))throw new Error("Unknown element!");if(typeof a=="string"&&(a=document.querySelector(a)),typeof i!="function"&&typeof i!="object")throw new Error("Unknown draw object. Must be a function or object!");s===0&&(s=1),f==="alternate"&&typeof p=="number"&&(p*=2),typeof c=="string"?(y=/\(([^)]+)\)/.exec(c),v=c.split("(")[0],z=y?y[1].split(",").map(function(R){return parseFloat(R)}):[],C=At[v]||At.linear):typeof c=="function"?C=c:C=At.linear,g.animation.elements[S]={element:a,id:null,stop:0,pause:0,loop:0,t:-1,started:0,paused:0};let _=function(){typeof i=="object"&&(x=xs(a,i,k)),typeof d=="function"&&d.apply(a),g.animation.elements[S].loop+=1,g.animation.elements[S].started=performance.now(),g.animation.elements[S].duration=s,g.animation.elements[S].id=requestAnimationFrame(I)},j=function(){cancelAnimationFrame(g.animation.elements[S].id),delete g.animation.elements[o],typeof h=="function"&&h.apply(a),r(l)},I=function(R){let J,L,{stop:et,pause:nt,started:K}=g.animation.elements[S];if(g.animation.elements[S].paused&&(K=R-g.animation.elements[S].t*s,g.animation.elements[S].started=K),L=((R-K)/s).toFixed(4),L>1&&(L=1),L<0&&(L=0),J=C.apply(null,z)(L),g.animation.elements[S].t=L,g.animation.elements[S].p=J,nt){g.animation.elements[S].id=requestAnimationFrame(I);return}if(et>0){et===2&&(typeof i=="function"?i.bind(a)(1,1):ia(a,x,1)),j();return}typeof i=="function"?i.bind(a)(L,J):ia(a,x,J),typeof m=="function"&&m.apply(a,[L,J]),L<=1&&(g.animation.elements[S].id=requestAnimationFrame(I)),L>=1&&(p?(f==="alternate"&&(k=k==="normal"?"reverse":"normal"),typeof p=="boolean"?setTimeout(function(){_()},u):p>g.animation.elements[S].loop?setTimeout(function(){_()},u):j()):f==="alternate"&&!w?(k=k==="normal"?"reverse":"normal",w=!0,_()):j())};b>0?setTimeout(function(){_()},b):_()})}function pe(e,r){let l=g.animation.elements[e];typeof l>"u"||(O(r)&&(r=!0),l.stop=r===!0?2:1,typeof l.onStop=="function"&&l.onStop.apply(l.element))}function ks(e,r){g.each(g.animation.elements,function(l,t){r?typeof r=="string"?ht.call(t.element,r)&&pe(l,e):r.length?g.each(r,function(){t.element===this&&pe(l,e)}):r instanceof Element&&t.element===r&&pe(l,e):pe(l,e)})}function de(e){let r=g.animation.elements[e];typeof r>"u"||(r.pause=1,r.paused=performance.now(),typeof r.onPause=="function"&&r.onPause.apply(r.element))}function ws(e){g.each(g.animation.elements,function(r,l){e?typeof e=="string"?ht.call(l.element,e)&&de(r):e.length?g.each(e,function(){l.element===this&&de(r)}):e instanceof Element&&l.element===e&&de(r):de(r)})}function me(e){let r=g.animation.elements[e];typeof r>"u"||(r.pause=0,r.paused=0,typeof r.onResume=="function"&&r.onResume.apply(r.element))}function ys(e){g.each(g.animation.elements,function(r,l){e?typeof e=="string"?ht.call(l.element,e)&&me(r):e.length?g.each(e,function(){l.element===this&&me(r)}):e instanceof Element&&l.element===e&&me(r):me(r)})}var _s={loop:!1,onChainItem:null,onChainItemComplete:null,onChainComplete:null};function da(e,r){let l=g.extend({},_s,r);if(typeof l.loop!="boolean"&&l.loop--,!Array.isArray(e))return console.warn("Chain array is not defined!"),!1;let t=function(o,a){return o.then(function(){return typeof l.onChainItem=="function"&&l.onChainItem(a),wo(a).then(function(){typeof l.onChainItemComplete=="function"&&l.onChainItemComplete(a)})})};e.reduce(t,Promise.resolve()).then(function(){typeof l.onChainComplete=="function"&&l.onChainComplete(),l.loop&&da(e,l)})}g.easing={};g.extend(g.easing,At);g.extend({animate:function(e){let r,l,t,o,a;return arguments.length>1?(r=g(arguments[0])[0],l=arguments[1],t=arguments[2]||g.animation.duration,o=arguments[3]||g.animation.ease,a=arguments[4],typeof t=="function"&&(a=t,o=g.animation.ease,t=g.animation.duration),typeof o=="function"&&(a=o,o=g.animation.ease),wo({el:r,draw:l,dur:t,ease:o,onDone:a})):wo(e)},chain:da,stop:pe,stopAll:ks,resume:me,resumeAll:ys,pause:de,pauseAll:ws});g.fn.extend({animate:function(e){let r=this,l,t,o,a,i=e,s;return s=!Array.isArray(e)&&(arguments.length>1||arguments.length===1&&typeof arguments[0].draw>"u"),s?(l=arguments[0],t=arguments[1]||g.animation.duration,o=arguments[2]||g.animation.ease,a=arguments[3],typeof t=="function"&&(a=t,t=g.animation.duration,o=g.animation.ease),typeof o=="function"&&(a=o,o=g.animation.ease),this.each(function(){return g.animate({el:this,draw:l,dur:t,ease:o,onDone:a})})):Array.isArray(e)?(g.each(e,function(){let c=this;r.each(function(){c.el=this,g.animate(c)})}),this):this.each(function(){i.el=this,g.animate(i)})},chain:function(e,r){return this.each(function(){let l=this;g.each(e,function(){this.el=l}),g.chain(e,r)})},stop:function(e){return this.each(function(){let r=this;g.each(g.animation.elements,function(l,t){t.element===r&&pe(l,e)})})},pause:function(){return this.each(function(){let e=this;g.each(g.animation.elements,function(r,l){l.element===e&&de(r)})})},resume:function(){return this.each(function(){let e=this;g.each(g.animation.elements,function(r,l){l.element===e&&me(r)})})}});g.extend({hidden:function(e,r,l){return e=g(e)[0],typeof r>"u"?(e.hidden=!e.hidden,this):(typeof r=="string"&&(r=r.toLowerCase()==="true"),typeof r=="function"&&(l=r,r=!e.hidden),e.hidden=r,typeof l=="function"&&(g.bind(l,e),l.call(e,arguments)),this)},hide:function(e,r){let l=g(e);e=l[0];let t=e.style.display,o=getComputedStyle(e,null).display;return l.origin("display",{inline:t,css:o}),e.style.display="none",typeof r=="function"&&(g.bind(r,e),r.call(e,arguments)),this},show:function(e,r){let t=g(e).origin("display");if(e=g(e)[0],e.style.display="",t){let o=t.inline||"",a=t.css||"";o&&o!=="none"?e.style.display=o:a==="none"&&(e.style.display="block")}else e.style.display="block";return parseInt(e.style.opacity)===0&&(e.style.opacity="1"),typeof r=="function"&&(g.bind(r,e),r.call(e,arguments)),this},visible:function(e,r,l){return r===void 0&&(r=!0),e.style.visibility=r?"visible":"hidden",typeof l=="function"&&(g.bind(l,e),l.call(e,arguments)),this},toggle:function(e,r){let l=getComputedStyle(e,null).display!=="none"?"hide":"show";return g[l](e,r)}});g.fn.extend({hide:function(){let e;return g.each(arguments,function(){typeof this=="function"&&(e=this)}),this.each(function(){g.hide(this,e)})},show:function(){let e;return g.each(arguments,function(){typeof this=="function"&&(e=this)}),this.each(function(){g.show(this,e)})},visible:function(e,r){return this.each(function(){g.visible(this,e,r)})},toggle:function(e){return this.each(function(){g.toggle(this,e)})},hidden:function(e,r){return this.each(function(){g.hidden(this,e,r)})}});g.extend({fx:{off:!1}});g.fn.extend({fadeIn:function(e,r,l){return this.each(function(){let t=this,o=g(t),a=!(!he(t)||he(t)&&+o.style("opacity")==0);if(O(e)&&O(r)&&O(l)?(l=null,e=g.animation.duration):typeof e=="function"&&(l=e,e=g.animation.duration),typeof r=="function"&&(l=r,r=g.animation.ease),g.fx.off&&(e=0),a)return typeof l=="function"&&g.bind(l,this)(),this;let i=o.origin("display",void 0,"block");return t.style.opacity="0",t.style.display=i,g.animate({el:t,draw:{opacity:1},dur:e,ease:r,onDone:function(){typeof l=="function"&&g.bind(l,this)()}})})},fadeOut:function(e,r,l){return this.each(function(){let t=this,o=g(t);return O(e)&&O(r)&&O(l)?(l=null,e=g.animation.duration):typeof e=="function"&&(l=e,e=g.animation.duration),typeof r=="function"&&(l=r,r=g.animation.ease),o.origin("display",o.style("display")),he(t)?g.animate({el:t,draw:{opacity:0},dur:e,ease:r,onDone:function(){this.style.display="none",typeof l=="function"&&g.bind(l,this)()}}):(typeof l=="function"&&g.bind(l,this)(),this)})},slideUp:function(e,r,l){return this.each(function(){let t=this,o=g(t),a;if(o.height()!==0)return O(e)&&O(r)&&O(l)?(l=null,e=g.animation.duration):typeof e=="function"&&(l=e,e=g.animation.duration),typeof r=="function"&&(l=r,r=g.animation.ease),a=o.height(),o.origin("height",a),o.origin("display",g(t).style("display")),o.css({overflow:"hidden"}),g.animate({el:t,draw:{height:0},dur:e,ease:r,onDone:function(){o.hide().removeStyleProperty("overflow, height"),typeof l=="function"&&g.bind(l,this)()}})})},slideDown:function(e,r,l){return this.each(function(){let t=this,o=g(t),a,i;return O(e)&&O(r)&&O(l)?(l=null,e=g.animation.duration):typeof e=="function"&&(l=e,e=g.animation.duration),typeof r=="function"&&(l=r,r=g.animation.ease),o.show().visible(!1),a=+o.origin("height",void 0,o.height()),parseInt(a)===0&&(a=t.scrollHeight),i=o.origin("display",o.style("display"),"block"),o.height(0).visible(!0),o.css({overflow:"hidden",display:i==="none"?"block":i}),g.animate({el:t,draw:{height:a},dur:e,ease:r,onDone:function(){g(t).removeStyleProperty("overflow, height, visibility"),typeof l=="function"&&g.bind(l,this)()}})})},moveTo:function(e,r,l,t,o){let a={top:r,left:e};return typeof l=="function"&&(o=l,l=g.animation.duration,t=g.animation.ease),typeof t=="function"&&(o=t,t=g.animation.ease),this.each(function(){g.animate({el:this,draw:a,dur:l,ease:t,onDone:o})})},centerTo:function(e,r,l,t,o){return typeof l=="function"&&(o=l,l=g.animation.duration,t=g.animation.ease),typeof t=="function"&&(o=t,t=g.animation.ease),this.each(function(){let a={left:e-this.clientWidth/2,top:r-this.clientHeight/2};g.animate({el:this,draw:a,dur:l,ease:t,onDone:o})})},colorTo:function(e,r,l,t){let o={color:e};return typeof r=="function"&&(t=r,r=g.animation.duration,l=g.animation.ease),typeof l=="function"&&(t=l,l=g.animation.ease),this.each(function(){g.animate({el:this,draw:o,dur:r,ease:l,onDone:t})})},backgroundTo:function(e,r,l,t){let o={backgroundColor:e};return typeof r=="function"&&(t=r,r=g.animation.duration,l=g.animation.ease),typeof l=="function"&&(t=l,l=g.animation.ease),this.each(function(){g.animate({el:this,draw:o,dur:r,ease:l,onDone:t})})},zoomIn:function(e,r,l){let t={scale:[0,1]};return typeof e=="function"&&(l=e,e=g.animation.duration,r=g.animation.ease),typeof r=="function"&&(l=r,r=g.animation.ease),this.each(function(){g.animate({el:this,draw:t,dur:e,ease:r,onDone:l})})},zoomOut:function(e=1e3,r="linear",l=()=>{}){return typeof e=="function"&&(l=e,e=g.animation.duration,r=g.animation.ease),typeof r=="function"&&(l=r,r=g.animation.ease),this.each(function(){g.animate({el:this,draw:{scale:0},dur:e,ease:r,onDone:l})})}});g.extend({scrollTop:function(e){if(O(e))return window.scrollY;window.scrollTo(window.scrollX,e)},scrollLeft:function(e){if(O(e))return window.scrollX;window.scrollTo(e,window.scrollY)},scrollTo:function(e,r){window.scrollTo(e,r)},scrollToElement:function(e){g(e).scrollTo()}});g.fn.extend({scrollTop:function(e){return O(e)?this.length===0?void 0:this[0]===window?scrollY:this[0].scrollTop:this.each(function(){if(this===window){window.scrollTo(window.scrollX,e);return}this.scrollTop=e})},scrollLeft:function(e){return O(e)?this.length===0?void 0:this[0]===window?scrollX:this[0].scrollLeft:this.each(function(){if(this===window){window.scrollTo(e,window.scrollY);return}this.scrollLeft=e})},scrollTo:function(e=!1){if(this.length===0)return this;let r=this[0].getBoundingClientRect(),l=r.left+(e?0:window.scrollX),t=r.top+(e?0:window.scrollY);return window.scrollTo(l,t),this}});g.init=function(e,r){let l,t=this;if(typeof e=="string"&&(e=e.trim()),this.uid=g.uniqueId(),!e)return this;if(typeof e=="function")return g.ready(e);if(e instanceof Element)return this.push(e),this;if(e instanceof g)return g.each(e,function(){t.push(this)}),this;if(e==="window"||e===window)return this.push(window),this;if(e==="document"||e===document)return this.push(document),this;if(e==="body"||e===document.body)return this.push(document.body),this;if(e==="html"||e===document.documentElement)return this.push(document.documentElement),this;if(e==="doctype"||e===document.doctype)return this.push(document.doctype),this;if(e&&e.nodeType)return this.push(e),this;if(ue(e))return g.each(e,function(){g(this).each(function(){t.push(this)})}),this;if(typeof e!="string"&&e.self&&e.self!==window)return this;if(e==="#"||e===".")return this;if(e[0]==="@")g("[data-role]").each(function(){Gt(g(this).attr("data-role"),",").indexOf(e.slice(1))>-1&&t.push(this)});else{l=g.parseHTML(e);for(let o=0;o<l.length;o++)l[o].nodeType===1&&this.push(l[o])}return r!==void 0&&(r instanceof g?this.each(function(){g(r).append(t)}):r instanceof HTMLElement?g(r).append(t):Xt(r)&&g.each(this,function(){for(let o in r)Rt(r,o)&&this.setAttribute(o,r[o])})),this};g.init.prototype=g.fn;globalThis.Dom=g;typeof $>"u"&&(globalThis.$=g);var _o={};Zo(_o,{EVENTS:()=>ma,info:()=>Ws,useClickOutside:()=>Cs,useCompose:()=>zs,useCookie:()=>Ss,useCurry:()=>As,useDebounce:()=>Ts,useEvent:()=>Es,useId:()=>Is,useInterval:()=>Bs,useMediaQuery:()=>Ps,useMemo:()=>Os,usePipe:()=>Ls,useQueue:()=>Ns,useState:()=>Vs,useThrottle:()=>Hs,useToggle:()=>Ys});function Cs(e,r){if(!e)return{attach:()=>{},detach:()=>{}};let l=a=>{e.contains(a.target)||r()};return{attach:()=>document.addEventListener("click",l),detach:()=>document.removeEventListener("click",l)}}function zs(...e){if(!e.every(r=>typeof r=="function"))throw new Error("useCompose: All arguments should be functions");switch(e.length){case 0:return r=>r;case 1:return e[0];case 2:{let[r,l]=e;return(...t)=>r(l(...t))}default:return function(...l){let t=e[e.length-1](...l);for(let o=e.length-2;o>=0;o--)t=e[o](t);return t}}}function Ss(e){function r(){let o=document.cookie.match(new RegExp(`(?:^|; )${e.replace(/([\.$?*|{}\(\)\[\]\\\/\+^])/g,"\\$1")}=([^;]*)`));return o?decodeURIComponent(o[1]):null}function l(o,a={}){a={path:"/",...a},document.cookie=`${e}=${encodeURIComponent(o)}; ${Object.keys(a).map(i=>`${i}=${a[i]}`).join("; ")}`}function t(){l("",{"max-age":-1})}return{get:r,set:l,delete:t}}function As(e){if(typeof e!="function")throw new Error("useCurry: \u043F\u0435\u0440\u0432\u044B\u0439 \u0430\u0440\u0433\u0443\u043C\u0435\u043D\u0442 \u0434\u043E\u043B\u0436\u0435\u043D \u0431\u044B\u0442\u044C \u0444\u0443\u043D\u043A\u0446\u0438\u0435\u0439");return function r(...l){return l.length>=e.length?e.apply(this,l):function(...t){return r.apply(this,l.concat(t))}}}function Ts(e,r,l={}){if(typeof e!="function")throw new Error("useDebounce: \u043F\u0435\u0440\u0432\u044B\u0439 \u0430\u0440\u0433\u0443\u043C\u0435\u043D\u0442 \u0434\u043E\u043B\u0436\u0435\u043D \u0431\u044B\u0442\u044C \u0444\u0443\u043D\u043A\u0446\u0438\u0435\u0439");if(r<0)throw new Error("useDebounce: \u0432\u0440\u0435\u043C\u044F \u043E\u0436\u0438\u0434\u0430\u043D\u0438\u044F \u0434\u043E\u043B\u0436\u043D\u043E \u0431\u044B\u0442\u044C \u043F\u043E\u043B\u043E\u0436\u0438\u0442\u0435\u043B\u044C\u043D\u044B\u043C \u0447\u0438\u0441\u043B\u043E\u043C");let t=null,o;function a(...i){let s=this,c=l.immediate&&!t;return t!==null&&clearTimeout(t),t=setTimeout(()=>{t=null,l.immediate||(o=e.apply(s,i))},r),c&&(o=e.apply(s,i)),o}return a.cancel=function(){t!==null&&(clearTimeout(t),t=null)},a}var ma=(e=>(e.LOAD="load",e.VIEWPORT="viewport",e.ATTRIBUTE="attribute",e.CHILDREN="children",e.DATA="data",e))(ma||{}),Es=({event:e,root:r,target:l,effect:t})=>{let o=typeof l=="string"?document.querySelector(l):l;if(typeof t!="function")throw Error("Side effect must be a function!");if(!o)throw Error("Please specify a target element!");switch(e){case"load":{new MutationObserver((i,s)=>{let c=document.querySelector(l);c!==null&&(t(c),s.disconnect())}).observe(document.body,{childList:!0,subtree:!0});break}case"viewport":{let i={root:r instanceof HTMLElement?r:typeof r=="string"?document.querySelector(r):null,rootMargin:"0px",threshold:.5};new IntersectionObserver((c,p)=>{for(let d of c)d.isIntersecting&&t(o)},i).observe(o);break}case"attribute":{new MutationObserver(i=>{for(let s of i)s.target===o&&s.type==="attributes"&&t(o,s.attributeName,o.getAttribute(s.attributeName))}).observe(o,{attributes:!0});break}case"children":{new MutationObserver(i=>{for(let s of i)s.target===o&&s.type==="childList"&&t(o,s.addedNodes,s.removedNodes)}).observe(o,{childList:!0,subtree:!0});break}case"data":{new MutationObserver(i=>{for(let s of i)s.target===o&&s.type==="characterData"&&t(o,o.textContent)}).observe(o,{characterData:!0});break}default:o instanceof HTMLElement&&o.addEventListener(e,a=>{t(o,a)})}},yo=new Map,js=0;function Ds(e){return e.replace(/[^a-zA-Z0-9_-]/g,"_")}function Is(e,r={}){let l=e??Symbol("id-key"),{divider:t="-",prefix:o="id",forceNew:a=!1}=r;if(!a&&yo.has(l))return yo.get(l);let i=typeof document<"u",s=1e3,c=0,p=()=>{let m;return e instanceof HTMLElement?m=e.tagName.toLowerCase():typeof e=="object"&&e!==null?m="object":e!==void 0?m=Ds(String(e)):m="generic",`${o}${t}${m}${t}${js++}`},d=p();if(i)for(;document.getElementById(d);){if(c++>s)throw new Error("useId: \u043D\u0435 \u0443\u0434\u0430\u043B\u043E\u0441\u044C \u0441\u0433\u0435\u043D\u0435\u0440\u0438\u0440\u043E\u0432\u0430\u0442\u044C \u0443\u043D\u0438\u043A\u0430\u043B\u044C\u043D\u044B\u0439 ID \u043F\u043E\u0441\u043B\u0435 \u043C\u043D\u043E\u0433\u043E\u0447\u0438\u0441\u043B\u0435\u043D\u043D\u044B\u0445 \u043F\u043E\u043F\u044B\u0442\u043E\u043A");d=p()}return yo.set(l,d),d}function Bs(e,r){let l=null;function t(){l||(l=window.setInterval(()=>e(),r))}function o(){l&&(window.clearInterval(l),l=null)}return{start:t,stop:o}}function Ps(e){let r=window.matchMedia(e);function l(){return r.matches}let t=l();function o(){t=l()}return r.addEventListener("change",o),t}var Os=(e,r={})=>{let l=new Map,{maxSize:t}=r,o=(...a)=>{let i=JSON.stringify(a);if(l.has(i))return l.get(i);let s=e(...a);if(t&&l.size>=t){let c=l.keys().next().value;typeof c=="string"&&l.delete(c)}return l.set(i,s),s};return o.clearCache=()=>(l.clear(),!0),o};function Ls(...e){if(!e.every(r=>typeof r=="function"))throw new Error("usePipe: \u0432\u0441\u0435 \u0430\u0440\u0433\u0443\u043C\u0435\u043D\u0442\u044B \u0434\u043E\u043B\u0436\u043D\u044B \u0431\u044B\u0442\u044C \u0444\u0443\u043D\u043A\u0446\u0438\u044F\u043C\u0438");switch(e.length){case 0:return r=>r;case 1:return e[0];case 2:{let[r,l]=e;return(...t)=>l(r(...t))}default:return function(...l){let t=e[0](...l);for(let o=1;o<e.length;o++)t=e[o](t);return t}}}function Ns(){let e=[];return{enqueue:r=>(e.push(r),e.length),dequeue:()=>e.shift(),peek:()=>e[0]||null,size:()=>e.length,isEmpty:()=>e.length===0,clear:()=>{e.length=0}}}var Zt=[],Fs=-1,Rs=class{constructor(e){this.index=e}valueOf(){return Zt[this.index].value}toString(){let e=Zt[this.index].value;return String(e)}[Symbol.toPrimitive](e){let r=Zt[this.index].value;return e==="number"&&typeof r=="number"?r:e==="string"?String(r):r}},Vs=(e,r)=>{let l=Fs++;return Zt[l]||(Zt[l]={value:e}),[new Rs(l),a=>{let i=Zt[l].value,s=typeof a=="function"?a(i):a;Zt[l].value=s,typeof r=="function"&&r(s,i)}]};function Hs(e,r,l={}){if(typeof e!="function")throw new Error("useThrottle: \u043F\u0435\u0440\u0432\u044B\u0439 \u0430\u0440\u0433\u0443\u043C\u0435\u043D\u0442 \u0434\u043E\u043B\u0436\u0435\u043D \u0431\u044B\u0442\u044C \u0444\u0443\u043D\u043A\u0446\u0438\u0435\u0439");if(r<0)throw new Error("useThrottle: \u0432\u0440\u0435\u043C\u044F \u043E\u0436\u0438\u0434\u0430\u043D\u0438\u044F \u0434\u043E\u043B\u0436\u043D\u043E \u0431\u044B\u0442\u044C \u043F\u043E\u043B\u043E\u0436\u0438\u0442\u0435\u043B\u044C\u043D\u044B\u043C \u0447\u0438\u0441\u043B\u043E\u043C");let t=null,o=null,a=null,i,s=null,{leading:c=!0,trailing:p=!0}=l;function d(){i=e.apply(a,o),o=a=null,s=Date.now()}function m(...h){let u=Date.now();!s&&!c&&(s=u);let f=r-(u-s);return o=h,a=this,f<=0||f>r?(t&&(clearTimeout(t),t=null),d()):!t&&p&&(t=setTimeout(()=>{t=null,p&&o&&d()},f)),i}return m.cancel=function(){t&&(clearTimeout(t),t=null),o=a=null,s=null},m}function Ys(e=!1){let r=e;return{get:()=>r,toggle:()=>(r=!r,r),set:l=>(r=l,r)}}var Us="0.13.0",qs="07.03.2025, 23:32:05",Ws=()=>{console.info(`%c Hooks %c v${Us} %c ${qs} `,"color: #ffffff; font-weight: bold; background: #5c2c05","color: white; background: darkgreen","color: white; background: #0080fe;")};globalThis.Hooks=_o;var Gs=Object.defineProperty,Xs=(e,r)=>{for(var l in r)Gs(e,l,{get:r[l],enumerable:!0})},zo={};Xs(zo,{Primitives:()=>ua,add:()=>Ba,brighten:()=>Ia,cmyk2rgb:()=>To,cmyk2websafe:()=>za,colorDefaultProps:()=>We,colorToString:()=>va,colorType:()=>Ot,colorTypes:()=>ct,create:()=>Js,createColor:()=>ga,createColorScheme:()=>Pa,darken:()=>Aa,desaturate:()=>ja,equal:()=>xa,expand:()=>Ks,expandHexColor:()=>je,grayscale:()=>Sa,hex2hsv:()=>Ms,hex2rgb:()=>Xe,hex2websafe:()=>ya,hsl2hsv:()=>ka,hsl2websafe:()=>Ca,hsv2hex:()=>Qs,hsv2hsl:()=>Je,hsv2rgb:()=>Vt,hsv2websafe:()=>_a,hueShift:()=>Ta,isCMYK:()=>be,isColor:()=>Bt,isDark:()=>So,isHEX:()=>Ie,isHSL:()=>ge,isHSLA:()=>Mt,isHSV:()=>ee,isLight:()=>ba,isPrimitive:()=>Oa,isRGB:()=>De,isRGBA:()=>Ut,lighten:()=>Jt,mix:()=>mt,multiply:()=>Eo,parse:()=>Ge,parseColor:()=>zt,random:()=>$s,randomColor:()=>jo,rgb2cmyk:()=>Ao,rgb2hex:()=>Ze,rgb2hsv:()=>_t,rgb2websafe:()=>oe,rgba2websafe:()=>wa,saturate:()=>Kt,shade:()=>Ea,spin:()=>Da,test:()=>fa,toCMYK:()=>Se,toColor:()=>Ct,toHEX:()=>Pt,toHSL:()=>fe,toHSLA:()=>Yt,toHSV:()=>$t,toRGB:()=>tt,toRGBA:()=>Ht,websafe:()=>Co});var rt=class{constructor(e=0,r=0,l=0){this.h=e,this.s=r,this.v=l}toString(){return"hsv("+[Math.round(this.h),Math.round(this.s*100)+"%",Math.round(this.v*100)+"%"].join(",")+")"}},Ae=class{constructor(e=0,r=0,l=0){this.h=e,this.s=(""+r).includes("%")?parseInt(r)/100:r,this.l=(""+l).includes("%")?parseInt(l)/100:l}toString(){return"hsl("+[Math.round(this.h),Math.round(this.s*100)+"%",Math.round(this.l*100)+"%"].join(",")+")"}},Te=class{constructor(e=0,r=0,l=0,t=0){this.h=e,this.s=(""+r).includes("%")?parseInt(r)/100:r,this.l=(""+l).includes("%")?parseInt(l)/100:l,this.a=t}toString(){return"hsla("+[Math.round(this.h),Math.round(this.s*100)+"%",Math.round(this.l*100)+"%",parseFloat(this.a).toFixed(2)].join(",")+")"}},bt=class{constructor(e=0,r=0,l=0){this.r=e,this.g=r,this.b=l}toString(){return`rgb(${this.r},${this.g},${this.b})`}},te=class{constructor(e=0,r=0,l=0,t=0){this.r=e,this.g=r,this.b=l,this.a=t}toString(){return`rgba(${this.r},${this.g},${this.b},${this.a})`}},Ee=class{constructor(e=0,r=0,l=0,t=0){this.c=e,this.m=r,this.y=l,this.k=t}toString(){return`cmyk(${this.c},${this.m},${this.y},${this.k})`}},Qt={aliceBlue:"#f0f8ff",antiqueWhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedAlmond:"#ffebcd",blue:"#0000ff",blueViolet:"#8a2be2",brown:"#a52a2a",burlyWood:"#deb887",cadetBlue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflowerBlue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyan:"#00ffff",darkBlue:"#00008b",darkCyan:"#008b8b",darkGoldenRod:"#b8860b",darkGray:"#a9a9a9",darkGreen:"#006400",darkKhaki:"#bdb76b",darkMagenta:"#8b008b",darkOliveGreen:"#556b2f",darkOrange:"#ff8c00",darkOrchid:"#9932cc",darkRed:"#8b0000",darkSalmon:"#e9967a",darkSeaGreen:"#8fbc8f",darkSlateBlue:"#483d8b",darkSlateGray:"#2f4f4f",darkTurquoise:"#00ced1",darkViolet:"#9400d3",deepPink:"#ff1493",deepSkyBlue:"#00bfff",dimGray:"#696969",dodgerBlue:"#1e90ff",fireBrick:"#b22222",floralWhite:"#fffaf0",forestGreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#DCDCDC",ghostWhite:"#F8F8FF",gold:"#ffd700",goldenRod:"#daa520",gray:"#808080",green:"#008000",greenYellow:"#adff2f",honeyDew:"#f0fff0",hotPink:"#ff69b4",indianRed:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",lavender:"#e6e6fa",lavenderBlush:"#fff0f5",lawnGreen:"#7cfc00",lemonChiffon:"#fffacd",lightBlue:"#add8e6",lightCoral:"#f08080",lightCyan:"#e0ffff",lightGoldenRodYellow:"#fafad2",lightGray:"#d3d3d3",lightGreen:"#90ee90",lightPink:"#ffb6c1",lightSalmon:"#ffa07a",lightSeaGreen:"#20b2aa",lightSkyBlue:"#87cefa",lightSlateGray:"#778899",lightSteelBlue:"#b0c4de",lightYellow:"#ffffe0",lime:"#00ff00",limeGreen:"#32dc32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",mediumAquaMarine:"#66cdaa",mediumBlue:"#0000cd",mediumOrchid:"#ba55d3",mediumPurple:"#9370db",mediumSeaGreen:"#3cb371",mediumSlateBlue:"#7b68ee",mediumSpringGreen:"#00fa9a",mediumTurquoise:"#48d1cc",mediumVioletRed:"#c71585",midnightBlue:"#191970",mintCream:"#f5fffa",mistyRose:"#ffe4e1",moccasin:"#ffe4b5",navajoWhite:"#ffdead",navy:"#000080",oldLace:"#fdd5e6",olive:"#808000",oliveDrab:"#6b8e23",orange:"#ffa500",orangeRed:"#ff4500",orchid:"#da70d6",paleGoldenRod:"#eee8aa",paleGreen:"#98fb98",paleTurquoise:"#afeeee",paleVioletRed:"#db7093",papayaWhip:"#ffefd5",peachPuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderBlue:"#b0e0e6",purple:"#800080",rebeccaPurple:"#663399",red:"#ff0000",rosyBrown:"#bc8f8f",royalBlue:"#4169e1",saddleBrown:"#8b4513",salmon:"#fa8072",sandyBrown:"#f4a460",seaGreen:"#2e8b57",seaShell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",slyBlue:"#87ceeb",slateBlue:"#6a5acd",slateGray:"#708090",snow:"#fffafa",springGreen:"#00ff7f",steelBlue:"#4682b4",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",tomato:"#ff6347",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whiteSmoke:"#f5f5f5",yellow:"#ffff00",yellowGreen:"#9acd32"},qe={lime:"#a4c400",green:"#60a917",emerald:"#008a00",blue:"#00AFF0",teal:"#00aba9",cyan:"#1ba1e2",cobalt:"#0050ef",indigo:"#6a00ff",violet:"#aa00ff",pink:"#dc4fad",magenta:"#d80073",crimson:"#a20025",red:"#CE352C",orange:"#fa6800",amber:"#f0a30a",yellow:"#fff000",brown:"#825a2c",olive:"#6d8764",steel:"#647687",mauve:"#76608a",taupe:"#87794e"},ha={color:function(e,r=Qt,l=void 0){return r[e]!==void 0?r[e]:l},palette:function(e=Qt){return Object.keys(e)},colors:function(e=Qt){return Object.values(e)}},ua={HSV:rt,HSL:Ae,HSLA:Te,RGB:bt,RGBA:te,CMYK:Ee},ct={HEX:"hex",RGB:"rgb",RGBA:"rgba",HSV:"hsv",HSL:"hsl",HSLA:"hsla",CMYK:"cmyk",UNKNOWN:"unknown"},We={angle:30,algorithm:1,step:.1,distance:5,tint1:.8,tint2:.4,shade1:.6,shade2:.3,alpha:1,baseLight:"#ffffff",baseDark:"self"};function Zs(e,r){let l;switch(r){case"hex":l=e.map(function(t){return Pt(t)});break;case"rgb":l=e.map(function(t){return tt(t)});break;case"rgba":l=e.map(function(t){return Ht(t,opt.alpha)});break;case"hsl":l=e.map(function(t){return fe(t)});break;case"hsla":l=e.map(function(t){return Yt(t,opt.alpha)});break;case"cmyk":l=e.map(function(t){return Se(t)});break;default:l=e}return l}function Tt(e,r,l){return Math.max(r,Math.min(e,l))}function xt(e,r,l){return e<r?r:e>l?l:e}function gt(e,r){for(e+=r;e>=360;)e-=360;for(;e<0;)e+=360;return e}var fa=e=>{let r=c=>/^#([A-Fa-f0-9]{3}){1,2}$/.test(c),l=c=>/^rgb\(\s*\d+\s*,\s*\d+\s*,\s*\d+\s*\)$/.test(c),t=c=>/^rgba\(\s*\d+\s*,\s*\d+\s*,\s*\d+\s*,\s*(0(\.\d+)?|1(\.0+)?)\s*\)$/.test(c),o=c=>/^hsv\(\s*\d+\s*,\s*\d+\s*,\s*\d+\s*\)$/.test(c),a=c=>/^hsl\(\s*\d+\s*,\s*\d+\s*,\s*\d+\s*\)$/.test(c),i=c=>/^hsla\(\s*\d+\s*,\s*\d+\s*,\s*\d+\s*,\s*(0(\.\d+)?|1(\.0+)?)\s*\)$/.test(c),s=c=>/^cmyk\(\s*\d+\s*,\s*\d+\s*,\s*\d+\s*,\s*\d+\s*\)$/.test(c);return r(e)||l(e)||o(e)||i(e)||i(e)||t(e)||a(e)||s(e)},ga=(e="hex",r="#000000")=>{let l;return typeof r=="string"&&(l=zt(r)),Bt(l)||(l="#000000"),Ct(l,e.toLowerCase())},Js=ga,je=function(e){if(Bt(e)&&typeof e!="string")return e;if(typeof e!="string")throw new Error("Value is not a string!");if(e[0]==="#"&&e.length===4){let r=/^#?([a-f\d])([a-f\d])([a-f\d])$/i;return"#"+e.replace(r,(l,t,o,a)=>t+t+o+o+a+a)}return e[0]==="#"?e:"#"+e},Ks=je,So=e=>{if(e=zt(e),!Bt(e))return;let r=tt(e);return(r.r*299+r.g*587+r.b*114)/1e3<128},ba=e=>!So(e),ee=e=>zt(e)instanceof rt,ge=e=>zt(e)instanceof Ae,Mt=e=>zt(e)instanceof Te,De=e=>zt(e)instanceof bt,Ut=e=>zt(e)instanceof te,be=e=>zt(e)instanceof Ee,Ie=e=>/(^#[0-9A-F]{6}$)|(^#[0-9A-F]{3}$)/i.test(e),Bt=e=>e?typeof e=="string"?fa(e):Ie(e)||De(e)||Ut(e)||ee(e)||ge(e)||Mt(e)||be(e):!1,Ot=e=>Ie(e)?ct.HEX:De(e)?ct.RGB:Ut(e)?ct.RGBA:ee(e)?ct.HSV:ge(e)?ct.HSL:Mt(e)?ct.HSLA:be(e)?ct.CMYK:ct.UNKNOWN,xa=(e,r)=>!Bt(e)||!Bt(r)?!1:Pt(e)===Pt(r),va=e=>e.toString(),Xe=e=>{let r=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(je(e)),l=[parseInt(r[1],16),parseInt(r[2],16),parseInt(r[3],16)];return r?new bt(...l):null},Ze=e=>"#"+((1<<24)+(e.r<<16)+(e.g<<8)+e.b).toString(16).slice(1),_t=e=>{let r=new rt,l,t,o,a=e.r/255,i=e.g/255,s=e.b/255,c=Math.max(a,i,s),p=Math.min(a,i,s),d=c-p;return o=c,c===0?t=0:t=1-p/c,c===p?l=0:c===a&&i>=s?l=60*((i-s)/d):c===a&&i<s?l=60*((i-s)/d)+360:c===i?l=60*((s-a)/d)+120:c===s?l=60*((a-i)/d)+240:l=0,r.h=l,r.s=t,r.v=o,r},Vt=e=>{let r,l,t,o=e.h,a=e.s*100,i=e.v*100,s=Math.floor(o/60),c=(100-a)*i/100,p=(i-c)*(o%60/60),d=c+p,m=i-p;switch(s){case 0:r=i,l=d,t=c;break;case 1:r=m,l=i,t=c;break;case 2:r=c,l=i,t=d;break;case 3:r=c,l=m,t=i;break;case 4:r=d,l=c,t=i;break;case 5:r=i,l=c,t=m;break}return new bt(Math.round(r*255/100),Math.round(l*255/100),Math.round(t*255/100))},Qs=e=>Ze(Vt(e)),Ms=e=>_t(Xe(e)),Ao=e=>{let r=new Ee,l=e.r/255,t=e.g/255,o=e.b/255;return r.k=Math.min(1-l,1-t,1-o),r.c=1-r.k===0?0:(1-l-r.k)/(1-r.k),r.m=1-r.k===0?0:(1-t-r.k)/(1-r.k),r.y=1-r.k===0?0:(1-o-r.k)/(1-r.k),r.c=Math.round(r.c*100),r.m=Math.round(r.m*100),r.y=Math.round(r.y*100),r.k=Math.round(r.k*100),r},To=e=>{let r=Math.floor(255*(1-e.c/100)*(1-e.k/100)),l=Math.ceil(255*(1-e.m/100)*(1-e.k/100)),t=Math.ceil(255*(1-e.y/100)*(1-e.k/100));return new bt(r,l,t)},Je=e=>{let r,l,t,o;return r=parseInt(e.h),t=(2-e.s)*e.v,l=e.s*e.v,t===0?l=0:(o=t<=1?t:2-t,o===0?l=0:l/=o),t/=2,Number.isNaN(l)&&(l=0),Number.isNaN(t)&&(t=0),new Ae(r,l,t)},ka=e=>{let r,l,t,o;return r=e.h,o=e.l*2,l=e.s*(o<=1?o:2-o),t=(o+l)/2,o+l===0?l=0:l=2*l/(o+l),new rt(r,l,t)},oe=e=>new bt(Math.round(e.r/51)*51,Math.round(e.g/51)*51,Math.round(e.b/51)*51),wa=e=>{let r=oe(e);return new te(r.r,r.g,r.b,e.a)},ya=e=>Ze(oe(Xe(e))),_a=e=>_t(oe(tt(e))),Ca=e=>Je(_t(oe(tt(e)))),za=e=>Ao(oe(To(e))),Co=e=>Ie(e)?ya(e):De(e)?oe(e):Ut(e)?wa(e):ee(e)?_a(e):ge(e)?Ca(e):be(e)?za(e):e,Ct=(e,r="rgb",l=1)=>{let t;switch(r.toLowerCase()){case"hex":t=Pt(e);break;case"rgb":t=tt(e);break;case"rgba":t=Ht(e,l);break;case"hsl":t=fe(e);break;case"hsla":t=Yt(e,l);break;case"hsv":t=$t(e);break;case"cmyk":t=Se(e);break;default:t=e}return t},Pt=e=>typeof e=="string"&&e[0]==="#"?je(e):Ze(tt(Ge(e))),tt=e=>{if(De(e))return e;if(Ut(e))return new bt(e.r,e.g,e.b);if(ee(e))return Vt(e);if(ge(e)||Mt(e))return Vt(ka(e));if(Ie(e))return Xe(e);if(be(e))return To(e);throw new Error("Unknown color format!")},Ht=(e,r)=>{if(Ut(e))return typeof r<"u"&&(e.a=r),e;let l=tt(e);return new te(l.r,l.g,l.b,typeof e.a<"u"?e.a:r)},$t=e=>ee(e)?e:_t(tt(e)),fe=e=>ge(e)?e:Je(_t(tt(e))),Yt=(e,r=1)=>{if(Mt(e))return r&&(e.a=r),e;let l=Je(_t(tt(e)));return l.a=typeof e.a<"u"?e.a:r,new Te(l.h,l.s,l.l,l.a)},Se=e=>be(e)?e:Ao(tt(e)),Sa=e=>{let r=tt(e),l=Ot(e).toLowerCase(),t=Math.round(r.r*.2125+r.g*.7154+r.b*.0721),o=new bt(t,t,t);return Ct(o,l)},Aa=(e,r=10)=>Jt(e,-1*Math.abs(r)),Jt=(e,r=10)=>{let l=Ot(e).toLowerCase(),t=Yt(e);return t.l+=r/100,t.l=Tt(t.l,0,1),Ct(t,l)},Ta=(e,r,l=1)=>{let t=$t(e),o=Ot(e).toLowerCase(),a=t.h;for(a+=r;a>=360;)a-=360;for(;a<0;)a+=360;return t.h=a,Ct(t,o,l)},mt=(e,r,l)=>{l=l===0?0:l||50;let t=new bt(0,0,0),o=tt(e),a=tt(r),i=l/100;return t.r=Math.round((a.r-o.r)*i+o.r),t.g=Math.round((a.g-o.g)*i+o.g),t.b=Math.round((a.b-o.b)*i+o.b),Pt(t)},Eo=(e,r)=>{let l=tt(e),t=tt(r),o=new bt;return l.b=Math.floor(l.b*t.b/255),l.g=Math.floor(l.g*t.g/255),l.r=Math.floor(l.r*t.r/255),Pt(o)},Ea=(e,r)=>{if(!Bt(e))throw new Error(e+" is not a valid color value!");r/=100;let l=Ot(e).toLowerCase(),t=tt(e),o=r<0?0:255,a=r<0?r*-1:r,i,s,c,p;return i=Math.round((o-t.r)*a)+t.r,s=Math.round((o-t.g)*a)+t.g,c=Math.round((o-t.b)*a)+t.b,(l===ct.RGBA||l===ct.HSLA)&&(p=e.a),Ct(new bt(i,s,c),l,p)},Kt=(e,r)=>{let l=Ot(e).toLowerCase(),t=Yt(e);return t.s+=r/100,t.s=Tt(t.s,0,1),Ct(t,l)},ja=(e,r)=>Kt(e,-1*Math.abs(r)),Da=(e,r)=>{let l,t,o,a;if(!Bt(e))throw new Error(e+" is not a valid color value!");return l=fe(e),a=l.h+r,a>360?a=a%360:a<0&&(a=360+a%360),l.h=a,t=Ot(e).toLowerCase(),(t===ct.RGBA||t===ct.HSLA)&&(o=e.a),t==="hsl"?l:Ct(l,t,o)},Ia=(e,r)=>{let l=1,t=Ot(e).toLowerCase(),o=$t(e);return(t===ct.RGBA||t===ct.HSLA)&&(l=e.a),o.v+=r/100,o.v=Tt(o.v,0,1),Ct(o,t,l)},Ba=(e,r,l)=>{let t=Ge(e),o=Ge(r),a=Ht(t,void 0),i=Ht(o,void 0),s=new te,c=(""+l).toLowerCase()||"hex";return s.r=Math.round((a.r+i.r)/2),s.g=Math.round((a.g+i.g)/2),s.b=Math.round((a.b+i.b)/2),s.a=Math.round((a.a+i.a)/2),Ct(s,l,s.a)},Pa=(e,r,l=ct.HEX,t)=>{let o=Object.assign({},We,t),a,i=[],s,c,p,d,m;if(s=$t(e),ee(s)===!1)return console.warn("The value is a not supported color format!"),!1;switch(p=s.h,d=s.s,m=s.v,r){case"monochromatic":case"mono":{if(o.algorithm===1)c=Vt(s),c.r=xt(Math.round(c.r+(255-c.r)*o.tint1),0,255),c.g=xt(Math.round(c.g+(255-c.g)*o.tint1),0,255),c.b=xt(Math.round(c.b+(255-c.b)*o.tint1),0,255),i.push(_t(c)),c=Vt(s),c.r=xt(Math.round(c.r+(255-c.r)*o.tint2),0,255),c.g=xt(Math.round(c.g+(255-c.g)*o.tint2),0,255),c.b=xt(Math.round(c.b+(255-c.b)*o.tint2),0,255),i.push(_t(c)),i.push(s),c=Vt(s),c.r=xt(Math.round(c.r*o.shade1),0,255),c.g=xt(Math.round(c.g*o.shade1),0,255),c.b=xt(Math.round(c.b*o.shade1),0,255),i.push(_t(c)),c=Vt(s),c.r=xt(Math.round(c.r*o.shade2),0,255),c.g=xt(Math.round(c.g*o.shade2),0,255),c.b=xt(Math.round(c.b*o.shade2),0,255),i.push(_t(c));else if(o.algorithm===2)for(i.push(s),a=1;a<=o.distance;a++)m=Tt(m-o.step,0,1),d=Tt(d-o.step,0,1),i.push({h:p,s:d,v:m});else if(o.algorithm===3)for(i.push(s),a=1;a<=o.distance;a++)m=Tt(m-o.step,0,1),i.push({h:p,s:d,v:m});else m=Tt(s.v+o.step*2,0,1),i.push({h:p,s:d,v:m}),m=Tt(s.v+o.step,0,1),i.push({h:p,s:d,v:m}),i.push(s),d=s.s,m=s.v,m=Tt(s.v-o.step,0,1),i.push({h:p,s:d,v:m}),m=Tt(s.v-o.step*2,0,1),i.push({h:p,s:d,v:m});break}case"complementary":case"complement":case"comp":{i.push(s),p=gt(s.h,180),i.push(new rt(p,d,m));break}case"double-complementary":case"double-complement":case"double":{i.push(s),p=gt(p,180),i.push(new rt(p,d,m)),p=gt(p,o.angle),i.push(new rt(p,d,m)),p=gt(p,180),i.push(new rt(p,d,m));break}case"analogous":case"analog":{p=gt(p,o.angle),i.push(new rt(p,d,m)),i.push(s),p=gt(s.h,0-o.angle),i.push(new rt(p,d,m));break}case"triadic":case"triad":{for(i.push(s),a=1;a<3;a++)p=gt(p,120),i.push(new rt(p,d,m));break}case"tetradic":case"tetra":{i.push(s),p=gt(s.h,180),i.push(new rt(p,d,m)),p=gt(s.h,-1*o.angle),i.push(new rt(p,d,m)),p=gt(p,180),i.push(new rt(p,d,m));break}case"square":{for(i.push(s),a=1;a<4;a++)p=gt(p,90),i.push(new rt(p,d,m));break}case"split-complementary":case"split-complement":case"split":{p=gt(p,180-o.angle),i.push(new rt(p,d,m)),i.push(s),p=gt(s.h,180+o.angle),i.push(new rt(p,d,m));break}case"material":{var h=o.baseLight,u=o.baseDark==="self"||!o.baseDark?Eo(e,e):o.baseDark;i.push({50:mt(h,e,10),100:mt(h,e,30),200:mt(h,e,50),300:mt(h,e,70),400:mt(h,e,85),500:mt(h,e,100),600:mt(u,e,92),700:mt(u,e,83),800:mt(u,e,74),900:mt(u,e,65),A100:Jt(Kt(mt(u,e,15),80),65),A200:Jt(Kt(mt(u,e,15),80),55),A400:Jt(Kt(mt(h,e,100),55),10),A700:Jt(Kt(mt(u,e,83),65),10)});break}default:console.error("Unknown schema name")}return r==="material"?i[0]:Zs(i,l)},Oa=e=>e instanceof rt||e instanceof Ae||e instanceof Te||e instanceof bt||e instanceof te||e instanceof Ee,zt=function(e){if(Oa(e))return e;let r=(""+e).toLowerCase();typeof Qt[r]<"u"&&(r=Qt[r]),typeof qe[r]<"u"&&(r=qe[r]);let l=r.replace(/[^\d.,%]/g,"").split(",").map(t=>isNaN(t)?t:+t);return r[0]==="#"?je(r):r.includes("rgba")?new te(l[0],l[1],l[2],l[3]):r.includes("rgb")?new bt(l[0],l[1],l[2]):r.includes("cmyk")?new Ee(l[0],l[1],l[2],l[3]):r.includes("hsv")?new rt(l[0],l[1],l[2]):r.includes("hsla")?new Te(l[0],l[1],l[2],l[3]):r.includes("hsl")?new Ae(l[0],l[1],l[2]):r},Ge=zt,jo=(e="hex",r=1)=>{let l=(s,c)=>Math.floor(s+Math.random()*(c+1-s)),t,o,a,i;return o=l(0,255),a=l(0,255),i=l(0,255),t="#"+((1<<24)+(o<<16)+(a<<8)+i).toString(16).slice(1),e==="hex"?t:Ct(t,e,r)},$s=jo,Do=class{_setValue(e){e||(e="#000000"),typeof e=="string"&&(e=zt(e)),e&&Bt(e)?this._value=e:this._value=void 0}_setOptions(e){this._options=Object.assign({},We,e)}constructor(e="#000000",r=null){this._setValue(e),this._setOptions(r)}get options(){return this._options}set options(e){this._setOptions(e)}get value(){return this._value?this._value:void 0}set value(e){this._setValue(e)}toRGB(){if(this._value)return this._value=tt(this._value),this}get rgb(){return this._value?tt(this._value):void 0}toRGBA(e){if(this._value)return Ut(this._value)?e&&(this._value=Ht(this._value,e)):this._value=Ht(this._value,e||We.alpha),this}get rgba(){return this._value?Ut(this._value)?this._value:Ht(this._value,this._options.alpha):void 0}toHEX(){if(this._value)return this._value=Pt(this._value),this}get hex(){return this._value?Pt(this._value):void 0}toHSV(){if(this._value)return this._value=$t(this._value),this}get hsv(){return this._value?$t(this._value):void 0}toHSL(){if(this._value)return this._value=fe(this._value),this}get hsl(){return this._value?fe(this._value):void 0}toHSLA(e){if(this._value)return Mt(this._value)?e&&(this._value=Yt(this._value,e)):this._value=Yt(this._value,e),this}get hsla(){return this._value?Mt(this._value)?this._value:Yt(this._value,this._options.alpha):void 0}toCMYK(){if(this._value)return this._value=Se(this._value),this}get cmyk(){return this._value?Se(this._value):void 0}toWebsafe(){if(this._value)return this._value=Co(this._value),this}get websafe(){return this._value?Co(this._value):void 0}toString(){return this._value?va(this._value):void 0}darken(e=10){if(this._value)return this._value=Aa(this._value,e),this}lighten(e=10){if(this._value)return this._value=Jt(this._value,e),this}isDark(){return this._value?So(this._value):void 0}isLight(){return this._value?ba(this._value):void 0}hueShift(e){if(this._value)return this._value=Ta(this._value,e),this}grayscale(){if(!(!this._value||this.type===ct.UNKNOWN))return this._value=Sa(this._value,(""+this.type).toLowerCase()),this}get type(){return Ot(this._value)}getScheme(e,r,l){return this._value?Pa(this._value,e,r,l):void 0}equal(e){return xa(this._value,e)}random(e,r){this._value=jo(e,r)}channel(e,r){let l=`${this.type}`.toUpperCase();if(["red","green","blue"].includes(e)){this.toRGB();let t={red:"r",green:"g",blue:"b"};this._value[t[e]]=r,this[`to${l}`]()}if(e==="alpha"&&this._value.a&&(this._value.a=r),["hue","saturation","value"].includes(e)){this.toHSV();let t={hue:"h",saturation:"s",value:"v"};this._value[t[e]]=r,this[`to${l}`]()}if(["lightness"].includes(e)&&(this.toHSL(),this._value.l=r,this[`to${l}`]()),["cyan","magenta","yellow","black"].includes(e)){this.toCMYK();let t={cyan:"c",magenta:"m",yellow:"y",black:"k"};this._value[t[e]]=r,this[`to${l}`]()}return this}add(e){this._setValue(Ba(this._value,e))}mix(e,r){this._setValue(mt(this._value,e,r))}multiply(e){this._setValue(Eo(this._value,e))}shade(e){this._setValue(Ea(this._value,e))}saturate(e){this._setValue(Kt(this._value,e))}desaturate(e){this._setValue(ja(this._value,e))}spin(e){this._setValue(Da(this._value,e))}brighten(e){this._setValue(Ia(this._value,e))}},La={...ua},tc="1.0.4",ec="11.08.2024, 23:47:03",Na=()=>{console.info(`%c Farbe %c v${tc} %c ${ec} `,"color: #ffffff; font-weight: bold; background: #ff00ff","color: white; background: darkgreen","color: white; background: #0080fe;")};globalThis.Farbe=Do;globalThis.farbe=e=>new Do(e);globalThis.Farbe.Routines=zo;globalThis.Farbe.Palette=ha;globalThis.Farbe.StandardColors=Qt;globalThis.Farbe.MetroColors=qe;globalThis.Farbe.Primitives=La;globalThis.Farbe.info=Na;var oc=Object.defineProperty,rc=(e,r)=>{for(var l in r)oc(e,l,{get:r[l],enumerable:!0})};function Fa(e){return e.replace(/([A-Z])/g,function(r){return"-"+r.toLowerCase()})}function ac(e=[]){return Array.isArray(e)?e.join(" "):e.toString()}var ic=["opacity","zIndex","order","zoom"];function Ra(e={}){return typeof e=="string"?e:Object.keys(e).map(r=>{let l=Fa(r),t=e[r];return!ic.includes(l)&&!isNaN(t)&&(t+="px"),`${l}: ${t}`}).join(";")}var nc=["accesskey","autocapitalize","autofocus","contenteditable","dir","draggable","enterkeyhint","hidden","inert","inputmode","is","itemid","itemprop","itemref","itemscope","itemtype","lang","nonce","popover","spellcheck","style","tabindex","title","translate","writingsuggestions"],lc=e=>{let r,l,t=[],o,a,i=/^<([a-z][^\/\0>:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i;if(typeof e=="string"){if(e=e.trim(),o=document.implementation.createHTMLDocument(""),r=o.createElement("base"),r.href=document.location.href,o.head.appendChild(r),a=o.body,l=i.exec(e),l)return document.createElement(l[1]);a.innerHTML=e;for(let s=0;s<a.childNodes.length;s++)t.push(a.childNodes[s]);return t[0]}},sc=["onauxclick","onbeforeinput","onbeforematch","onbeforetoggle","onblur","oncancel","oncanplay","oncanplaythrough","onchange","onclick","onclose","oncontextlost","oncontextmenu","oncontextrestored","oncopy","oncuechange","oncut","ondblclick","ondrag","ondragend","ondragenter","ondragleave","ondragover","ondragstart","ondrop","ondurationchange","onemptied","onended","onerror","onfocus","onformdata","oninput","oninvalid","onkeydown","onkeypress","onkeyup","onload","onloadeddata","onloadedmetadata","onloadstart","onmousedown","onmouseenter","onmouseleave","onmousemove","onmouseout","onmouseover","onmouseup","onpaste","onpause","onplay","onplaying","onprogress","onratechange","onreset","onresize","onscroll","onscrollend","onsecuritypolicyviolation","onseeked","onseeking","onselect","onslotchange","onstalled","onsubmit","onsuspend","ontimeupdate","ontoggle","onvolumechange","onwaiting","onwheel"],Ke=class{constructor(e={}){this.options=e,this.tag="div"}selfAttributes(){return[]}get attributes(){return this.getAttributes().join(" ")}getAttributes(){let e=[],r=["hidden","disabled","required","readonly","selected","open","multiply","default"],l=["className","style","data","tag","events"];for(let t in this.options)if(!l.includes(t)){if(r.includes(t)&&this.options[t]===!0){e.push(t);continue}(this.selfAttributes().includes(t)&&!e.includes(t)||nc.includes(t))&&e.push(`${t}="${this.options[t]}"`)}return this.classes&&e.push(`class="${this.classes}"`),this.styles&&e.push(`style="${this.styles}"`),this.dataSet&&e.push(this.dataSet),this.aria&&e.push(this.aria),e}draw(){return this.template()}get dataSet(){let{data:e={}}=this.options,r=[];for(let l in e)r.push(`data-${Fa(l)}="${e[l]}"`);return r.join(" ")}get aria(){let{aria:e={}}=this.options,r=[];for(let l in e)r.push(`aria-${l.toLowerCase()}="${e[l]}"`);return r.join(" ")}get events(){let{events:e={},control:r=!0}=this.options,l=[];for(let t in e)r&&!sc.includes(t)&&console.info(`Event ${t} for element ${this.tag} not specified in HTML specification`),l.push(`${t.toLowerCase()}="${e[t]}"`);return l.join(" ")}get classes(){return ac(this.options.class)}get styles(){return Ra(this.options.style)}template(){return""}toString(){return this.draw()}toElement(){return lc(this.draw())}},Bo=e=>{if(Array.isArray(e))return e.map(Bo).join(`
56`);if(typeof e=="string"||typeof e=="number"||typeof e=="boolean")return e;if(e.draw)return e.draw();throw new Error("Unknown element! "+e)},T=class extends Ke{constructor(...e){let r={},l=[];for(let t of e)typeof t=="object"&&!(t instanceof Ke)?r=t:l.push(t);super(r),this.children=l}template(e){let r=this.options.tag?this.options.tag:this.tag;return`
57 <${r} ${this.attributes} ${this.events}>${e}</${r}>
58 `}draw(){return this.template(this.children.map(Bo).join(""))}},pt=class extends Ke{constructor(e={}){super(e),this.options=e}template(){return`

Callers

nothing calls this directly

Calls 2

rFunction · 0.70
lFunction · 0.70

Tested by

no test coverage detected