UNPKG

clock-analog-digital-react

Version:

A reusable React clock package with analog and digital clocks

30 lines (28 loc) 51.5 kB
"use strict";const k=require("react");function kt(e){const r=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const a=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(r,n,a.get?a:{enumerable:!0,get:()=>e[n]})}}return r.default=e,Object.freeze(r)}const ae=kt(k);var Ye={exports:{}},Pe={};/** * @license React * react-jsx-runtime.production.min.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */var jr;function Ct(){if(jr)return Pe;jr=1;var e=k,r=Symbol.for("react.element"),n=Symbol.for("react.fragment"),a=Object.prototype.hasOwnProperty,o=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,i={key:!0,ref:!0,__self:!0,__source:!0};function c(u,h,C){var d,p={},j=null,M=null;C!==void 0&&(j=""+C),h.key!==void 0&&(j=""+h.key),h.ref!==void 0&&(M=h.ref);for(d in h)a.call(h,d)&&!i.hasOwnProperty(d)&&(p[d]=h[d]);if(u&&u.defaultProps)for(d in h=u.defaultProps,h)p[d]===void 0&&(p[d]=h[d]);return{$$typeof:r,type:u,key:j,ref:M,props:p,_owner:o.current}}return Pe.Fragment=n,Pe.jsx=c,Pe.jsxs=c,Pe}var Ae={};/** * @license React * react-jsx-runtime.development.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */var Tr;function wt(){return Tr||(Tr=1,process.env.NODE_ENV!=="production"&&function(){var e=k,r=Symbol.for("react.element"),n=Symbol.for("react.portal"),a=Symbol.for("react.fragment"),o=Symbol.for("react.strict_mode"),i=Symbol.for("react.profiler"),c=Symbol.for("react.provider"),u=Symbol.for("react.context"),h=Symbol.for("react.forward_ref"),C=Symbol.for("react.suspense"),d=Symbol.for("react.suspense_list"),p=Symbol.for("react.memo"),j=Symbol.for("react.lazy"),M=Symbol.for("react.offscreen"),S=Symbol.iterator,f="@@iterator";function g(t){if(t===null||typeof t!="object")return null;var s=S&&t[S]||t[f];return typeof s=="function"?s:null}var x=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function b(t){{for(var s=arguments.length,l=new Array(s>1?s-1:0),y=1;y<s;y++)l[y-1]=arguments[y];T("error",t,l)}}function T(t,s,l){{var y=x.ReactDebugCurrentFrame,O=y.getStackAddendum();O!==""&&(s+="%s",l=l.concat([O]));var W=l.map(function(_){return String(_)});W.unshift("Warning: "+s),Function.prototype.apply.call(console[t],console,W)}}var v=!1,I=!1,R=!1,w=!1,D=!1,X;X=Symbol.for("react.module.reference");function $(t){return!!(typeof t=="string"||typeof t=="function"||t===a||t===i||D||t===o||t===C||t===d||w||t===M||v||I||R||typeof t=="object"&&t!==null&&(t.$$typeof===j||t.$$typeof===p||t.$$typeof===c||t.$$typeof===u||t.$$typeof===h||t.$$typeof===X||t.getModuleId!==void 0))}function oe(t,s,l){var y=t.displayName;if(y)return y;var O=s.displayName||s.name||"";return O!==""?l+"("+O+")":l}function Fe(t){return t.displayName||"Context"}function Z(t){if(t==null)return null;if(typeof t.tag=="number"&&b("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t;switch(t){case a:return"Fragment";case n:return"Portal";case i:return"Profiler";case o:return"StrictMode";case C:return"Suspense";case d:return"SuspenseList"}if(typeof t=="object")switch(t.$$typeof){case u:var s=t;return Fe(s)+".Consumer";case c:var l=t;return Fe(l._context)+".Provider";case h:return oe(t,t.render,"ForwardRef");case p:var y=t.displayName||null;return y!==null?y:Z(t.type)||"Memo";case j:{var O=t,W=O._payload,_=O._init;try{return Z(_(W))}catch{return null}}}return null}var Q=Object.assign,ie=0,J,ne,ze,Ee,fe,De,Le;function _e(){}_e.__reactDisabledLog=!0;function de(){{if(ie===0){J=console.log,ne=console.info,ze=console.warn,Ee=console.error,fe=console.group,De=console.groupCollapsed,Le=console.groupEnd;var t={configurable:!0,enumerable:!0,value:_e,writable:!0};Object.defineProperties(console,{info:t,log:t,warn:t,error:t,group:t,groupCollapsed:t,groupEnd:t})}ie++}}function he(){{if(ie--,ie===0){var t={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:Q({},t,{value:J}),info:Q({},t,{value:ne}),warn:Q({},t,{value:ze}),error:Q({},t,{value:Ee}),group:Q({},t,{value:fe}),groupCollapsed:Q({},t,{value:De}),groupEnd:Q({},t,{value:Le})})}ie<0&&b("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}}var pe=x.ReactCurrentDispatcher,me;function ge(t,s,l){{if(me===void 0)try{throw Error()}catch(O){var y=O.stack.trim().match(/\n( *(at )?)/);me=y&&y[1]||""}return` `+me+t}}var je=!1,be;{var rr=typeof WeakMap=="function"?WeakMap:Map;be=new rr}function Ne(t,s){if(!t||je)return"";{var l=be.get(t);if(l!==void 0)return l}var y;je=!0;var O=Error.prepareStackTrace;Error.prepareStackTrace=void 0;var W;W=pe.current,pe.current=null,de();try{if(s){var _=function(){throw Error()};if(Object.defineProperty(_.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(_,[])}catch(Y){y=Y}Reflect.construct(t,[],_)}else{try{_.call()}catch(Y){y=Y}t.call(_.prototype)}}else{try{throw Error()}catch(Y){y=Y}t()}}catch(Y){if(Y&&y&&typeof Y.stack=="string"){for(var E=Y.stack.split(` `),U=y.stack.split(` `),z=E.length-1,L=U.length-1;z>=1&&L>=0&&E[z]!==U[L];)L--;for(;z>=1&&L>=0;z--,L--)if(E[z]!==U[L]){if(z!==1||L!==1)do if(z--,L--,L<0||E[z]!==U[L]){var K=` `+E[z].replace(" at new "," at ");return t.displayName&&K.includes("<anonymous>")&&(K=K.replace("<anonymous>",t.displayName)),typeof t=="function"&&be.set(t,K),K}while(z>=1&&L>=0);break}}}finally{je=!1,pe.current=W,he(),Error.prepareStackTrace=O}var xe=t?t.displayName||t.name:"",ue=xe?ge(xe):"";return typeof t=="function"&&be.set(t,ue),ue}function tr(t,s,l){return Ne(t,!1)}function nr(t){var s=t.prototype;return!!(s&&s.isReactComponent)}function se(t,s,l){if(t==null)return"";if(typeof t=="function")return Ne(t,nr(t));if(typeof t=="string")return ge(t);switch(t){case C:return ge("Suspense");case d:return ge("SuspenseList")}if(typeof t=="object")switch(t.$$typeof){case h:return tr(t.render);case p:return se(t.type,s,l);case j:{var y=t,O=y._payload,W=y._init;try{return se(W(O),s,l)}catch{}}}return""}var ce=Object.prototype.hasOwnProperty,He={},Ve=x.ReactDebugCurrentFrame;function B(t){if(t){var s=t._owner,l=se(t.type,t._source,s?s.type:null);Ve.setExtraStackFrame(l)}else Ve.setExtraStackFrame(null)}function le(t,s,l,y,O){{var W=Function.call.bind(ce);for(var _ in t)if(W(t,_)){var E=void 0;try{if(typeof t[_]!="function"){var U=Error((y||"React class")+": "+l+" type `"+_+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof t[_]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw U.name="Invariant Violation",U}E=t[_](s,_,y,l,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(z){E=z}E&&!(E instanceof Error)&&(B(O),b("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).",y||"React class",l,_,typeof E),B(null)),E instanceof Error&&!(E.message in He)&&(He[E.message]=!0,B(O),b("Failed %s type: %s",l,E.message),B(null))}}}var ar=Array.isArray;function Te(t){return ar(t)}function or(t){{var s=typeof Symbol=="function"&&Symbol.toStringTag,l=s&&t[Symbol.toStringTag]||t.constructor.name||"Object";return l}}function ir(t){try{return Be(t),!1}catch{return!0}}function Be(t){return""+t}function Ue(t){if(ir(t))return b("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",or(t)),Be(t)}var vr=x.ReactCurrentOwner,nt={key:!0,ref:!0,__self:!0,__source:!0},xr,yr;function at(t){if(ce.call(t,"ref")){var s=Object.getOwnPropertyDescriptor(t,"ref").get;if(s&&s.isReactWarning)return!1}return t.ref!==void 0}function ot(t){if(ce.call(t,"key")){var s=Object.getOwnPropertyDescriptor(t,"key").get;if(s&&s.isReactWarning)return!1}return t.key!==void 0}function it(t,s){typeof t.ref=="string"&&vr.current}function st(t,s){{var l=function(){xr||(xr=!0,b("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",s))};l.isReactWarning=!0,Object.defineProperty(t,"key",{get:l,configurable:!0})}}function ct(t,s){{var l=function(){yr||(yr=!0,b("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",s))};l.isReactWarning=!0,Object.defineProperty(t,"ref",{get:l,configurable:!0})}}var lt=function(t,s,l,y,O,W,_){var E={$$typeof:r,type:t,key:s,ref:l,props:_,_owner:W};return E._store={},Object.defineProperty(E._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(E,"_self",{configurable:!1,enumerable:!1,writable:!1,value:y}),Object.defineProperty(E,"_source",{configurable:!1,enumerable:!1,writable:!1,value:O}),Object.freeze&&(Object.freeze(E.props),Object.freeze(E)),E};function ut(t,s,l,y,O){{var W,_={},E=null,U=null;l!==void 0&&(Ue(l),E=""+l),ot(s)&&(Ue(s.key),E=""+s.key),at(s)&&(U=s.ref,it(s,O));for(W in s)ce.call(s,W)&&!nt.hasOwnProperty(W)&&(_[W]=s[W]);if(t&&t.defaultProps){var z=t.defaultProps;for(W in z)_[W]===void 0&&(_[W]=z[W])}if(E||U){var L=typeof t=="function"?t.displayName||t.name||"Unknown":t;E&&st(_,L),U&&ct(_,L)}return lt(t,E,U,O,y,vr.current,_)}}var sr=x.ReactCurrentOwner,kr=x.ReactDebugCurrentFrame;function ve(t){if(t){var s=t._owner,l=se(t.type,t._source,s?s.type:null);kr.setExtraStackFrame(l)}else kr.setExtraStackFrame(null)}var cr;cr=!1;function lr(t){return typeof t=="object"&&t!==null&&t.$$typeof===r}function Cr(){{if(sr.current){var t=Z(sr.current.type);if(t)return` Check the render method of \``+t+"`."}return""}}function ft(t){return""}var wr={};function dt(t){{var s=Cr();if(!s){var l=typeof t=="string"?t:t.displayName||t.name;l&&(s=` Check the top-level render call using <`+l+">.")}return s}}function Sr(t,s){{if(!t._store||t._store.validated||t.key!=null)return;t._store.validated=!0;var l=dt(s);if(wr[l])return;wr[l]=!0;var y="";t&&t._owner&&t._owner!==sr.current&&(y=" It was passed a child from "+Z(t._owner.type)+"."),ve(t),b('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.',l,y),ve(null)}}function Rr(t,s){{if(typeof t!="object")return;if(Te(t))for(var l=0;l<t.length;l++){var y=t[l];lr(y)&&Sr(y,s)}else if(lr(t))t._store&&(t._store.validated=!0);else if(t){var O=g(t);if(typeof O=="function"&&O!==t.entries)for(var W=O.call(t),_;!(_=W.next()).done;)lr(_.value)&&Sr(_.value,s)}}}function ht(t){{var s=t.type;if(s==null||typeof s=="string")return;var l;if(typeof s=="function")l=s.propTypes;else if(typeof s=="object"&&(s.$$typeof===h||s.$$typeof===p))l=s.propTypes;else return;if(l){var y=Z(s);le(l,t.props,"prop",y,t)}else if(s.PropTypes!==void 0&&!cr){cr=!0;var O=Z(s);b("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",O||"Unknown")}typeof s.getDefaultProps=="function"&&!s.getDefaultProps.isReactClassApproved&&b("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function pt(t){{for(var s=Object.keys(t.props),l=0;l<s.length;l++){var y=s[l];if(y!=="children"&&y!=="key"){ve(t),b("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",y),ve(null);break}}t.ref!==null&&(ve(t),b("Invalid attribute `ref` supplied to `React.Fragment`."),ve(null))}}var Er={};function _r(t,s,l,y,O,W){{var _=$(t);if(!_){var E="";(t===void 0||typeof t=="object"&&t!==null&&Object.keys(t).length===0)&&(E+=" You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");var U=ft();U?E+=U:E+=Cr();var z;t===null?z="null":Te(t)?z="array":t!==void 0&&t.$$typeof===r?(z="<"+(Z(t.type)||"Unknown")+" />",E=" Did you accidentally export a JSX literal instead of a component?"):z=typeof t,b("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",z,E)}var L=ut(t,s,l,O,W);if(L==null)return L;if(_){var K=s.children;if(K!==void 0)if(y)if(Te(K)){for(var xe=0;xe<K.length;xe++)Rr(K[xe],t);Object.freeze&&Object.freeze(K)}else b("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");else Rr(K,t)}if(ce.call(s,"key")){var ue=Z(t),Y=Object.keys(s).filter(function(yt){return yt!=="key"}),ur=Y.length>0?"{key: someKey, "+Y.join(": ..., ")+": ...}":"{key: someKey}";if(!Er[ue+ur]){var xt=Y.length>0?"{"+Y.join(": ..., ")+": ...}":"{}";b(`A props object containing a "key" prop is being spread into JSX: let props = %s; <%s {...props} /> React keys must be passed directly to JSX without using spread: let props = %s; <%s key={someKey} {...props} />`,ur,ue,xt,ue),Er[ue+ur]=!0}}return t===a?pt(L):ht(L),L}}function mt(t,s,l){return _r(t,s,l,!0)}function gt(t,s,l){return _r(t,s,l,!1)}var bt=gt,vt=mt;Ae.Fragment=a,Ae.jsx=bt,Ae.jsxs=vt}()),Ae}var Pr;function St(){return Pr||(Pr=1,process.env.NODE_ENV==="production"?Ye.exports=Ct():Ye.exports=wt()),Ye.exports}var m=St();const Hr=()=>{const e=k.useRef(null),[r,n]=k.useState(()=>new Date),a=k.useCallback(()=>{e.current=window.setInterval(()=>{n(new Date)},1e3)},[]),o=k.useCallback(()=>{e.current!==null&&(clearInterval(e.current),e.current=null)},[]);k.useEffect(()=>(a(),o),[a,o]);const i=r.getSeconds(),c=r.getMinutes(),u=r.getHours();return{seconds:i,minutes:c,hours:u}},Rt=(e,r,n,a,o,i,c,u,h,C,d)=>{const p=[],M=[0,15,30,45],S=(f,g,x,b,T)=>{if(k.isValidElement(f)&&f.props){const{style:v}=f.props;return{width:String((v==null?void 0:v.width)||g),height:String((v==null?void 0:v.height)||x),backgroundColor:String((v==null?void 0:v.backgroundColor)||b),display:T?"block":"none"}}return{width:g,height:x,backgroundColor:b,display:T?"block":"none"}};for(let f=0;f<60;f++){const g=f*6,x=g*Math.PI/180,b=(e-(r?r*8:e*.07))*Math.cos(x),T=(e-(r?r*8:e*.07))*Math.sin(x);let v="minor",I,R,w,D;if(f%5!==0){v="minor";const $=S(d,`${.001*e}rem`,`${.002*e}rem`,u||"cyan",o);I=$.width,R=$.height,w=$.backgroundColor,D=$.display}else if(M.includes(f)){v="primary";const $=S(h,`${.0015*e}rem`,`${.0045*e}rem`,i||"#e9f2ef",n);I=$.width,R=$.height,w=$.backgroundColor,D=$.display}else{v="major";const $=S(C,`${.0015*e}rem`,`${.003*e}rem`,c||"#f7bee2",a);I=$.width,R=$.height,w=$.backgroundColor,D=$.display}const X={type:v,position:"absolute",top:`calc(50% + ${T}px)`,left:`calc(50% + ${b}px)`,transform:`translate(-50%, -50%) rotate(${g+90}deg)`,transformOrigin:"center",width:String(I),height:String(R),backgroundColor:String(w),display:D};p.push(X)}return p},Et=({radius:e,clockNumbersType:r,effectiveClockBorderThickness:n,effectivePrimaryNumbersFontSize:a,effectiveMajorNumbersFontSize:o,effectivePrimaryNumbersColor:i,effectiveMajorNumbersColor:c,hasPrimaryNumbers:u=!0,hasMajorNumbers:h=!0,PrimaryNumbersComponent:C,MajorNumbersComponent:d})=>k.useMemo(()=>{const p=["I","II","III","IV","V","VI","VII","VIII","IX","X","XI","XII"],j=S=>{const f=(S+1)*30-90,g=e-(n>1.4?n*3:0)-e*.25;return{x:g*Math.cos(f*Math.PI/180),y:g*Math.sin(f*Math.PI/180)}},M=(S,f)=>{if(k.isValidElement(S)&&S.props){const{style:g}=S.props;return{...f,...g,fontSize:`${(g==null?void 0:g.fontSize)||f.fontSize}`,color:`${(g==null?void 0:g.color)||f.color}`}}return f};return[...Array(12)].map((S,f)=>{const g=r==="ENGLISH"?f+1:r==="ROMAN"?p[f]:null,{x,y:b}=j(f),T=[12,3,6,9].includes(f+1),v=T?C:d,I=T?a:o,R=T?i||"#c7eaf0":c||"#6df2bf",w=T?u?"block":"none":h?"block":"none",D=M(v,{fontSize:`${Math.min(I,.18)*e}px`,color:R,width:"auto",height:"auto"});return{num:v||g,x,y:b,fontSize:D.fontSize,color:D.color,width:D.width,height:D.height,display:w,style:D}})},[e,r,n,a,o,i,c,u,h,C,d]);function dr(){return dr=Object.assign?Object.assign.bind():function(e){for(var r=1;r<arguments.length;r++){var n=arguments[r];for(var a in n)({}).hasOwnProperty.call(n,a)&&(e[a]=n[a])}return e},dr.apply(null,arguments)}function _t(e){if(e.sheet)return e.sheet;for(var r=0;r<document.styleSheets.length;r++)if(document.styleSheets[r].ownerNode===e)return document.styleSheets[r]}function jt(e){var r=document.createElement("style");return r.setAttribute("data-emotion",e.key),e.nonce!==void 0&&r.setAttribute("nonce",e.nonce),r.appendChild(document.createTextNode("")),r.setAttribute("data-s",""),r}var Tt=function(){function e(n){var a=this;this._insertTag=function(o){var i;a.tags.length===0?a.insertionPoint?i=a.insertionPoint.nextSibling:a.prepend?i=a.container.firstChild:i=a.before:i=a.tags[a.tags.length-1].nextSibling,a.container.insertBefore(o,i),a.tags.push(o)},this.isSpeedy=n.speedy===void 0?!0:n.speedy,this.tags=[],this.ctr=0,this.nonce=n.nonce,this.key=n.key,this.container=n.container,this.prepend=n.prepend,this.insertionPoint=n.insertionPoint,this.before=null}var r=e.prototype;return r.hydrate=function(a){a.forEach(this._insertTag)},r.insert=function(a){this.ctr%(this.isSpeedy?65e3:1)===0&&this._insertTag(jt(this));var o=this.tags[this.tags.length-1];if(this.isSpeedy){var i=_t(o);try{i.insertRule(a,i.cssRules.length)}catch{}}else o.appendChild(document.createTextNode(a));this.ctr++},r.flush=function(){this.tags.forEach(function(a){var o;return(o=a.parentNode)==null?void 0:o.removeChild(a)}),this.tags=[],this.ctr=0},e}(),V="-ms-",Je="-moz-",P="-webkit-",Vr="comm",mr="rule",gr="decl",Pt="@import",Br="@keyframes",At="@layer",Ot=Math.abs,Ze=String.fromCharCode,It=Object.assign;function $t(e,r){return H(e,0)^45?(((r<<2^H(e,0))<<2^H(e,1))<<2^H(e,2))<<2^H(e,3):0}function Ur(e){return e.trim()}function Mt(e,r){return(e=r.exec(e))?e[0]:e}function A(e,r,n){return e.replace(r,n)}function hr(e,r){return e.indexOf(r)}function H(e,r){return e.charCodeAt(r)|0}function Ie(e,r,n){return e.slice(r,n)}function ee(e){return e.length}function br(e){return e.length}function qe(e,r){return r.push(e),e}function Wt(e,r){return e.map(r).join("")}var Qe=1,Se=1,Yr=0,q=0,N=0,Re="";function er(e,r,n,a,o,i,c){return{value:e,root:r,parent:n,type:a,props:o,children:i,line:Qe,column:Se,length:c,return:""}}function Oe(e,r){return It(er("",null,null,"",null,null,0),e,{length:-e.length},r)}function Ft(){return N}function zt(){return N=q>0?H(Re,--q):0,Se--,N===10&&(Se=1,Qe--),N}function G(){return N=q<Yr?H(Re,q++):0,Se++,N===10&&(Se=1,Qe++),N}function te(){return H(Re,q)}function Ge(){return q}function We(e,r){return Ie(Re,e,r)}function $e(e){switch(e){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function qr(e){return Qe=Se=1,Yr=ee(Re=e),q=0,[]}function Gr(e){return Re="",e}function Xe(e){return Ur(We(q-1,pr(e===91?e+2:e===40?e+1:e)))}function Dt(e){for(;(N=te())&&N<33;)G();return $e(e)>2||$e(N)>3?"":" "}function Lt(e,r){for(;--r&&G()&&!(N<48||N>102||N>57&&N<65||N>70&&N<97););return We(e,Ge()+(r<6&&te()==32&&G()==32))}function pr(e){for(;G();)switch(N){case e:return q;case 34:case 39:e!==34&&e!==39&&pr(N);break;case 40:e===41&&pr(e);break;case 92:G();break}return q}function Nt(e,r){for(;G()&&e+N!==57;)if(e+N===84&&te()===47)break;return"/*"+We(r,q-1)+"*"+Ze(e===47?e:G())}function Ht(e){for(;!$e(te());)G();return We(e,q)}function Vt(e){return Gr(Ke("",null,null,null,[""],e=qr(e),0,[0],e))}function Ke(e,r,n,a,o,i,c,u,h){for(var C=0,d=0,p=c,j=0,M=0,S=0,f=1,g=1,x=1,b=0,T="",v=o,I=i,R=a,w=T;g;)switch(S=b,b=G()){case 40:if(S!=108&&H(w,p-1)==58){hr(w+=A(Xe(b),"&","&\f"),"&\f")!=-1&&(x=-1);break}case 34:case 39:case 91:w+=Xe(b);break;case 9:case 10:case 13:case 32:w+=Dt(S);break;case 92:w+=Lt(Ge()-1,7);continue;case 47:switch(te()){case 42:case 47:qe(Bt(Nt(G(),Ge()),r,n),h);break;default:w+="/"}break;case 123*f:u[C++]=ee(w)*x;case 125*f:case 59:case 0:switch(b){case 0:case 125:g=0;case 59+d:x==-1&&(w=A(w,/\f/g,"")),M>0&&ee(w)-p&&qe(M>32?Or(w+";",a,n,p-1):Or(A(w," ","")+";",a,n,p-2),h);break;case 59:w+=";";default:if(qe(R=Ar(w,r,n,C,d,o,u,T,v=[],I=[],p),i),b===123)if(d===0)Ke(w,r,R,R,v,i,p,u,I);else switch(j===99&&H(w,3)===110?100:j){case 100:case 108:case 109:case 115:Ke(e,R,R,a&&qe(Ar(e,R,R,0,0,o,u,T,o,v=[],p),I),o,I,p,u,a?v:I);break;default:Ke(w,R,R,R,[""],I,0,u,I)}}C=d=M=0,f=x=1,T=w="",p=c;break;case 58:p=1+ee(w),M=S;default:if(f<1){if(b==123)--f;else if(b==125&&f++==0&&zt()==125)continue}switch(w+=Ze(b),b*f){case 38:x=d>0?1:(w+="\f",-1);break;case 44:u[C++]=(ee(w)-1)*x,x=1;break;case 64:te()===45&&(w+=Xe(G())),j=te(),d=p=ee(T=w+=Ht(Ge())),b++;break;case 45:S===45&&ee(w)==2&&(f=0)}}return i}function Ar(e,r,n,a,o,i,c,u,h,C,d){for(var p=o-1,j=o===0?i:[""],M=br(j),S=0,f=0,g=0;S<a;++S)for(var x=0,b=Ie(e,p+1,p=Ot(f=c[S])),T=e;x<M;++x)(T=Ur(f>0?j[x]+" "+b:A(b,/&\f/g,j[x])))&&(h[g++]=T);return er(e,r,n,o===0?mr:u,h,C,d)}function Bt(e,r,n){return er(e,r,n,Vr,Ze(Ft()),Ie(e,2,-2),0)}function Or(e,r,n,a){return er(e,r,n,gr,Ie(e,0,a),Ie(e,a+1,-1),a)}function we(e,r){for(var n="",a=br(e),o=0;o<a;o++)n+=r(e[o],o,e,r)||"";return n}function Ut(e,r,n,a){switch(e.type){case At:if(e.children.length)break;case Pt:case gr:return e.return=e.return||e.value;case Vr:return"";case Br:return e.return=e.value+"{"+we(e.children,a)+"}";case mr:e.value=e.props.join(",")}return ee(n=we(e.children,a))?e.return=e.value+"{"+n+"}":""}function Yt(e){var r=br(e);return function(n,a,o,i){for(var c="",u=0;u<r;u++)c+=e[u](n,a,o,i)||"";return c}}function qt(e){return function(r){r.root||(r=r.return)&&e(r)}}function Xr(e){var r=Object.create(null);return function(n){return r[n]===void 0&&(r[n]=e(n)),r[n]}}var Gt=function(r,n,a){for(var o=0,i=0;o=i,i=te(),o===38&&i===12&&(n[a]=1),!$e(i);)G();return We(r,q)},Xt=function(r,n){var a=-1,o=44;do switch($e(o)){case 0:o===38&&te()===12&&(n[a]=1),r[a]+=Gt(q-1,n,a);break;case 2:r[a]+=Xe(o);break;case 4:if(o===44){r[++a]=te()===58?"&\f":"",n[a]=r[a].length;break}default:r[a]+=Ze(o)}while(o=G());return r},Kt=function(r,n){return Gr(Xt(qr(r),n))},Ir=new WeakMap,Jt=function(r){if(!(r.type!=="rule"||!r.parent||r.length<1)){for(var n=r.value,a=r.parent,o=r.column===a.column&&r.line===a.line;a.type!=="rule";)if(a=a.parent,!a)return;if(!(r.props.length===1&&n.charCodeAt(0)!==58&&!Ir.get(a))&&!o){Ir.set(r,!0);for(var i=[],c=Kt(n,i),u=a.props,h=0,C=0;h<c.length;h++)for(var d=0;d<u.length;d++,C++)r.props[C]=i[h]?c[h].replace(/&\f/g,u[d]):u[d]+" "+c[h]}}},Zt=function(r){if(r.type==="decl"){var n=r.value;n.charCodeAt(0)===108&&n.charCodeAt(2)===98&&(r.return="",r.value="")}};function Kr(e,r){switch($t(e,r)){case 5103:return P+"print-"+e+e;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return P+e+e;case 5349:case 4246:case 4810:case 6968:case 2756:return P+e+Je+e+V+e+e;case 6828:case 4268:return P+e+V+e+e;case 6165:return P+e+V+"flex-"+e+e;case 5187:return P+e+A(e,/(\w+).+(:[^]+)/,P+"box-$1$2"+V+"flex-$1$2")+e;case 5443:return P+e+V+"flex-item-"+A(e,/flex-|-self/,"")+e;case 4675:return P+e+V+"flex-line-pack"+A(e,/align-content|flex-|-self/,"")+e;case 5548:return P+e+V+A(e,"shrink","negative")+e;case 5292:return P+e+V+A(e,"basis","preferred-size")+e;case 6060:return P+"box-"+A(e,"-grow","")+P+e+V+A(e,"grow","positive")+e;case 4554:return P+A(e,/([^-])(transform)/g,"$1"+P+"$2")+e;case 6187:return A(A(A(e,/(zoom-|grab)/,P+"$1"),/(image-set)/,P+"$1"),e,"")+e;case 5495:case 3959:return A(e,/(image-set\([^]*)/,P+"$1$`$1");case 4968:return A(A(e,/(.+:)(flex-)?(.*)/,P+"box-pack:$3"+V+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+P+e+e;case 4095:case 3583:case 4068:case 2532:return A(e,/(.+)-inline(.+)/,P+"$1$2")+e;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(ee(e)-1-r>6)switch(H(e,r+1)){case 109:if(H(e,r+4)!==45)break;case 102:return A(e,/(.+:)(.+)-([^]+)/,"$1"+P+"$2-$3$1"+Je+(H(e,r+3)==108?"$3":"$2-$3"))+e;case 115:return~hr(e,"stretch")?Kr(A(e,"stretch","fill-available"),r)+e:e}break;case 4949:if(H(e,r+1)!==115)break;case 6444:switch(H(e,ee(e)-3-(~hr(e,"!important")&&10))){case 107:return A(e,":",":"+P)+e;case 101:return A(e,/(.+:)([^;!]+)(;|!.+)?/,"$1"+P+(H(e,14)===45?"inline-":"")+"box$3$1"+P+"$2$3$1"+V+"$2box$3")+e}break;case 5936:switch(H(e,r+11)){case 114:return P+e+V+A(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return P+e+V+A(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return P+e+V+A(e,/[svh]\w+-[tblr]{2}/,"lr")+e}return P+e+V+e+e}return e}var Qt=function(r,n,a,o){if(r.length>-1&&!r.return)switch(r.type){case gr:r.return=Kr(r.value,r.length);break;case Br:return we([Oe(r,{value:A(r.value,"@","@"+P)})],o);case mr:if(r.length)return Wt(r.props,function(i){switch(Mt(i,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return we([Oe(r,{props:[A(i,/:(read-\w+)/,":"+Je+"$1")]})],o);case"::placeholder":return we([Oe(r,{props:[A(i,/:(plac\w+)/,":"+P+"input-$1")]}),Oe(r,{props:[A(i,/:(plac\w+)/,":"+Je+"$1")]}),Oe(r,{props:[A(i,/:(plac\w+)/,V+"input-$1")]})],o)}return""})}},en=[Qt],rn=function(r){var n=r.key;if(n==="css"){var a=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(a,function(f){var g=f.getAttribute("data-emotion");g.indexOf(" ")!==-1&&(document.head.appendChild(f),f.setAttribute("data-s",""))})}var o=r.stylisPlugins||en,i={},c,u=[];c=r.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+n+' "]'),function(f){for(var g=f.getAttribute("data-emotion").split(" "),x=1;x<g.length;x++)i[g[x]]=!0;u.push(f)});var h,C=[Jt,Zt];{var d,p=[Ut,qt(function(f){d.insert(f)})],j=Yt(C.concat(o,p)),M=function(g){return we(Vt(g),j)};h=function(g,x,b,T){d=b,M(g?g+"{"+x.styles+"}":x.styles),T&&(S.inserted[x.name]=!0)}}var S={key:n,sheet:new Tt({key:n,container:c,nonce:r.nonce,speedy:r.speedy,prepend:r.prepend,insertionPoint:r.insertionPoint}),nonce:r.nonce,inserted:i,registered:{},insert:h};return S.sheet.hydrate(u),S},tn=!0;function nn(e,r,n){var a="";return n.split(" ").forEach(function(o){e[o]!==void 0?r.push(e[o]+";"):o&&(a+=o+" ")}),a}var Jr=function(r,n,a){var o=r.key+"-"+n.name;(a===!1||tn===!1)&&r.registered[o]===void 0&&(r.registered[o]=n.styles)},an=function(r,n,a){Jr(r,n,a);var o=r.key+"-"+n.name;if(r.inserted[n.name]===void 0){var i=n;do r.insert(n===i?"."+o:"",i,r.sheet,!0),i=i.next;while(i!==void 0)}};function on(e){for(var r=0,n,a=0,o=e.length;o>=4;++a,o-=4)n=e.charCodeAt(a)&255|(e.charCodeAt(++a)&255)<<8|(e.charCodeAt(++a)&255)<<16|(e.charCodeAt(++a)&255)<<24,n=(n&65535)*1540483477+((n>>>16)*59797<<16),n^=n>>>24,r=(n&65535)*1540483477+((n>>>16)*59797<<16)^(r&65535)*1540483477+((r>>>16)*59797<<16);switch(o){case 3:r^=(e.charCodeAt(a+2)&255)<<16;case 2:r^=(e.charCodeAt(a+1)&255)<<8;case 1:r^=e.charCodeAt(a)&255,r=(r&65535)*1540483477+((r>>>16)*59797<<16)}return r^=r>>>13,r=(r&65535)*1540483477+((r>>>16)*59797<<16),((r^r>>>15)>>>0).toString(36)}var sn={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,scale:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},cn=/[A-Z]|^ms/g,ln=/_EMO_([^_]+?)_([^]*?)_EMO_/g,Zr=function(r){return r.charCodeAt(1)===45},$r=function(r){return r!=null&&typeof r!="boolean"},fr=Xr(function(e){return Zr(e)?e:e.replace(cn,"-$&").toLowerCase()}),Mr=function(r,n){switch(r){case"animation":case"animationName":if(typeof n=="string")return n.replace(ln,function(a,o,i){return re={name:o,styles:i,next:re},o})}return sn[r]!==1&&!Zr(r)&&typeof n=="number"&&n!==0?n+"px":n};function Me(e,r,n){if(n==null)return"";var a=n;if(a.__emotion_styles!==void 0)return a;switch(typeof n){case"boolean":return"";case"object":{var o=n;if(o.anim===1)return re={name:o.name,styles:o.styles,next:re},o.name;var i=n;if(i.styles!==void 0){var c=i.next;if(c!==void 0)for(;c!==void 0;)re={name:c.name,styles:c.styles,next:re},c=c.next;var u=i.styles+";";return u}return un(e,r,n)}case"function":{if(e!==void 0){var h=re,C=n(e);return re=h,Me(e,r,C)}break}}var d=n;if(r==null)return d;var p=r[d];return p!==void 0?p:d}function un(e,r,n){var a="";if(Array.isArray(n))for(var o=0;o<n.length;o++)a+=Me(e,r,n[o])+";";else for(var i in n){var c=n[i];if(typeof c!="object"){var u=c;r!=null&&r[u]!==void 0?a+=i+"{"+r[u]+"}":$r(u)&&(a+=fr(i)+":"+Mr(i,u)+";")}else if(Array.isArray(c)&&typeof c[0]=="string"&&(r==null||r[c[0]]===void 0))for(var h=0;h<c.length;h++)$r(c[h])&&(a+=fr(i)+":"+Mr(i,c[h])+";");else{var C=Me(e,r,c);switch(i){case"animation":case"animationName":{a+=fr(i)+":"+C+";";break}default:a+=i+"{"+C+"}"}}}return a}var Wr=/label:\s*([^\s;{]+)\s*(;|$)/g,re;function fn(e,r,n){if(e.length===1&&typeof e[0]=="object"&&e[0]!==null&&e[0].styles!==void 0)return e[0];var a=!0,o="";re=void 0;var i=e[0];if(i==null||i.raw===void 0)a=!1,o+=Me(n,r,i);else{var c=i;o+=c[0]}for(var u=1;u<e.length;u++)if(o+=Me(n,r,e[u]),a){var h=i;o+=h[u]}Wr.lastIndex=0;for(var C="",d;(d=Wr.exec(o))!==null;)C+="-"+d[1];var p=on(o)+C;return{name:p,styles:o,next:re}}var dn=function(r){return r()},hn=ae.useInsertionEffect?ae.useInsertionEffect:!1,pn=hn||dn,Qr=ae.createContext(typeof HTMLElement<"u"?rn({key:"css"}):null);Qr.Provider;var mn=function(r){return k.forwardRef(function(n,a){var o=k.useContext(Qr);return r(n,o,a)})},gn=ae.createContext({}),bn=/^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|abbr|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|disableRemotePlayback|download|draggable|encType|enterKeyHint|fetchpriority|fetchPriority|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|translate|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|incremental|fallback|inert|itemProp|itemScope|itemType|itemID|itemRef|on|option|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/,vn=Xr(function(e){return bn.test(e)||e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)<91}),xn=vn,yn=function(r){return r!=="theme"},Fr=function(r){return typeof r=="string"&&r.charCodeAt(0)>96?xn:yn},zr=function(r,n,a){var o;if(n){var i=n.shouldForwardProp;o=r.__emotion_forwardProp&&i?function(c){return r.__emotion_forwardProp(c)&&i(c)}:i}return typeof o!="function"&&a&&(o=r.__emotion_forwardProp),o},kn=function(r){var n=r.cache,a=r.serialized,o=r.isStringTag;return Jr(n,a,o),pn(function(){return an(n,a,o)}),null},Cn=function e(r,n){var a=r.__emotion_real===r,o=a&&r.__emotion_base||r,i,c;n!==void 0&&(i=n.label,c=n.target);var u=zr(r,n,a),h=u||Fr(o),C=!h("as");return function(){var d=arguments,p=a&&r.__emotion_styles!==void 0?r.__emotion_styles.slice(0):[];if(i!==void 0&&p.push("label:"+i+";"),d[0]==null||d[0].raw===void 0)p.push.apply(p,d);else{var j=d[0];p.push(j[0]);for(var M=d.length,S=1;S<M;S++)p.push(d[S],j[S])}var f=mn(function(g,x,b){var T=C&&g.as||o,v="",I=[],R=g;if(g.theme==null){R={};for(var w in g)R[w]=g[w];R.theme=ae.useContext(gn)}typeof g.className=="string"?v=nn(x.registered,I,g.className):g.className!=null&&(v=g.className+" ");var D=fn(p.concat(I),x.registered,R);v+=x.key+"-"+D.name,c!==void 0&&(v+=" "+c);var X=C&&u===void 0?Fr(T):h,$={};for(var oe in g)C&&oe==="as"||X(oe)&&($[oe]=g[oe]);return $.className=v,b&&($.ref=b),ae.createElement(ae.Fragment,null,ae.createElement(kn,{cache:x,serialized:D,isStringTag:typeof T=="string"}),ae.createElement(T,$))});return f.displayName=i!==void 0?i:"Styled("+(typeof o=="string"?o:o.displayName||o.name||"Component")+")",f.defaultProps=r.defaultProps,f.__emotion_real=f,f.__emotion_base=o,f.__emotion_styles=p,f.__emotion_forwardProp=u,Object.defineProperty(f,"toString",{value:function(){return"."+c}}),f.withComponent=function(g,x){var b=e(g,dr({},n,x,{shouldForwardProp:zr(f,x,!0)}));return b.apply(void 0,p)},f}},wn=["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","big","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","marquee","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","tspan"],F=Cn.bind(null);wn.forEach(function(e){F[e]=F(e)});const Sn=F.div(({borderThikness:e,backgroundColor:r,borderColor:n})=>({boxSizing:"border-box",width:"100%",minWidth:"100%",maxWidth:"100%",position:"relative",aspectRatio:"1 / 1",borderRadius:"50%",border:`${e}rem solid ${n||"#000105"}`,margin:"0 auto",backgroundColor:r||"#01061a"})),Rn=F.div(({topY:e,leftX:r,fontSize:n,color:a,display:o})=>({position:"absolute",top:`calc(50% + ${e}px)`,left:`calc(50% + ${r}px)`,fontSize:n,color:a,fontWeight:"bold",transform:"translate(-50%, -50%)",zIndex:2,display:o})),En=F.div(({hourAngle:e,userBackgroundColor:r})=>({position:"absolute",top:"50%",left:"50%",width:"3%",height:"26%",backgroundColor:r||"#82a7cf",transform:`translate(-50%, -100%) rotate(${e}deg)`,transformOrigin:"bottom",borderRadius:"5rem",zIndex:6})),_n=F.div(({minuteAngle:e,userBackgroundColor:r})=>({position:"absolute",top:"50%",left:"50%",width:"2%",height:"37%",backgroundColor:r||"#046e5e",transform:`translate(-50%, -100%) rotate(${e}deg)`,transformOrigin:"bottom",borderRadius:"5rem",zIndex:7})),jn=F.div(({secondAngle:e,userBackgroundColor:r})=>({position:"absolute",top:"50%",left:"50%",width:"1%",height:"45%",backgroundColor:r||"#f0738c",transform:`translate(-50%, -100%) rotate(${e}deg)`,transformOrigin:"bottom",borderRadius:"4rem",opacity:.7,zIndex:8,transition:`transform ${e===0?"0.01s":"0.25s"} ease-in-out`})),Tn=F.div({position:"absolute",top:"50%",left:"50%",width:"max-content",aspectRatio:"1/1",transform:"translate(-50%, -50%)",zIndex:8}),Pn=F.div(({clockRadius:e,backgroundColor:r})=>({backgroundColor:r||"#0c0338",width:`${e*.0055}rem`,borderRadius:"50%",aspectRatio:"1/1"})),An=F.div(({offset:e})=>({position:"absolute",top:"50%",left:"50%",transform:`translate(-50%, -${e}%)`,zIndex:1}));F.div({boxSizing:"border-box",width:"100%",minWidth:"100%",maxWidth:"100%",aspectRatio:"3/1",display:"flex",justifyContent:"center",alignItems:"center",margin:"0 auto",backgroundColor:"blue",border:"solid 2px red"});F.div({boxSizing:"border-box",width:"max-content",minWidth:"max-content",maxWidth:"max-content",height:"max-content",minHeight:"max-content",maxHeight:"max-content",display:"flex",justifyContent:"center",alignItems:"center",backgroundColor:"white",border:"solid 2px black"});const On=F.div({boxSizing:"border-box",width:"100%",maxWidth:"100%",height:"100%",maxHeight:"100%",cursor:"pointer",display:"flex",justifyContent:"center",alignItems:"center",zIndex:5,position:"absolute",top:"70%",left:"50%",transform:"translate(-50%, -50%)"}),In=F.div(({width:e,top:r,left:n,backgroundColor:a,boxShadowColor:o})=>({boxSizing:"border-box",width:`${e*.5}px`,minWidth:`${e*.5}px`,maxWidth:`${e*.5}px`,aspectRatio:`${e*.374}px`,padding:"0.2rem",display:"flex",flexDirection:"column",gap:`${e*.0274}px`,backgroundColor:a||"black",position:"absolute",top:`${e*r}px`,left:`${e*n}px`,borderRadius:"1rem",boxShadow:`0px 0px 14px 1px ${o||"white"}`,zIndex:8}));F.div({boxSizing:"border-box",width:"100%",minWidth:"100%",maxWidth:"100%",height:"100%",minHeight:"100%",maxHeight:"100%",display:"flex",flexDirection:"row",justifyContent:"space-between"});F.div({boxSizing:"border-box",width:"30%",minWidth:"30%",maxWidth:"30%",aspectRatio:"1.4/1",backgroundColor:"blue",borderRadius:"1rem",zIndex:8});const $n=F.div({boxSizing:"border-box",width:"100%",minWidth:"100%",maxWidth:"100%",display:"flex",flexDirection:"row",justifyContent:"space-around",alignItems:"center",zIndex:8}),Dr=F.div({boxSizing:"border-box",width:"45%",minWidth:"45%",maxWidth:"45%",backgroundColor:"#04bf2c",color:"white",borderRadius:"1rem",display:"flex",justifyContent:"center",alignItems:"center",paddingBlock:"2%",cursor:"pointer",fontWeight:600}),Mn=({fillColor:e,iconSize:r})=>m.jsxs("svg",{width:r,height:r,viewBox:"0 0 24 24",fill:e,xmlns:"http://www.w3.org/2000/svg",children:[m.jsx("path",{d:"M15.0195 19.0596C15.0195 20.7096 13.6695 22.0596 12.0195 22.0596C11.1995 22.0596 10.4395 21.7196 9.89953 21.1796C9.35953 20.6396 9.01953 19.8796 9.01953 19.0596",stroke:"#3B3B3B",strokeWidth:"1.5",strokeMiterlimit:"10"}),m.jsx("path",{d:"M12.0196 2.91016C8.7096 2.91016 6.0196 5.60016 6.0196 8.91016V11.8002C6.0196 12.4102 5.7596 13.3402 5.4496 13.8602L4.2996 15.7702C3.5896 16.9502 4.0796 18.2602 5.3796 18.7002C9.6896 20.1402 14.3396 20.1402 18.6496 18.7002C19.8596 18.3002 20.3896 16.8702 19.7296 15.7702L18.5796 13.8602C18.2796 13.3402 18.0196 12.4102 18.0196 11.8002V8.91016C18.0196 5.61016 15.3196 2.91016 12.0196 2.91016Z",stroke:"#3B3B3B",strokeWidth:"1.5",strokeMiterlimit:"10",strokeLinecap:"round"}),m.jsx("path",{d:"M13.8699 3.20043C13.5599 3.11043 13.2399 3.04043 12.9099 3.00043C11.9499 2.88043 11.0299 2.95043 10.1699 3.20043C10.4599 2.46043 11.1799 1.94043 12.0199 1.94043C12.8599 1.94043 13.5799 2.46043 13.8699 3.20043Z",stroke:"#3B3B3B",strokeWidth:"1.5",strokeMiterlimit:"10",strokeLinecap:"round",strokeLinejoin:"round"})]}),et=({iconSize:e,ringFillColor:r,onClick:n})=>m.jsx(On,{onClick:n,children:m.jsx(Mn,{fillColor:r||"yellow",iconSize:e})}),rt=({top:e,left:r,width:n,backgroundColor:a,boxShadowColor:o,onAlarmSet:i,onCancel:c})=>{const[u,h]=k.useState("00:00"),C=p=>{h(p.target.value)},d=()=>{const p=new Date,[j,M]=u.split(":").map(Number),S=new Date(p.getFullYear(),p.getMonth(),p.getDate(),j,M);i(S)};return m.jsxs(In,{width:n,top:e,left:r,backgroundColor:a&&a,boxShadowColor:o&&o,children:[m.jsx("input",{id:"time-picker",type:"time",value:u,onChange:C,style:{fontSize:"1rem",fontWeight:600,padding:"0.25rem",borderRadius:"1.5rem"}}),m.jsxs($n,{children:[m.jsx(Dr,{onClick:d,children:"Set"}),m.jsx(Dr,{onClick:c,style:{backgroundColor:"#eb1328"},children:"Cancel"})]})]})},tt=e=>{const[r,n]=k.useState(!1);return k.useEffect(()=>{const a=setInterval(()=>{if(e){const o=new Date;o.getHours()===e.getHours()&&o.getMinutes()===e.getMinutes()&&o.getSeconds()===0&&(n(!0),clearInterval(a))}},1e3);return()=>{clearInterval(a)}},[e]),r},Wn=e=>{const{hasAlarm:r=!1,onAlarm:n=()=>{},clockBorderThickness:a=2,clockLogoSrcAndOffset:o={cmp:m.jsx(m.Fragment,{}),offset:0},clockNumbersType:i="ENGLISH",hasPrimaryTicks:c=!0,hasMajorTicks:u=!0,hasMinorTicks:h=!0,hasPrimaryNumbers:C=!0,hasMajorNumbers:d=!0,primaryNumbersFontSize:p,majorNumbersFontSize:j,UserPrimaryTicksComponent:M,UserMajorTicksComponent:S,UserMinorTicksComponent:f,ClockCenterComponent:g,PrimaryNumbersComponent:x,MajorNumbersComponent:b,colorConfiguration:T={}}=e,{clockBackgroundColor:v,clockBorderColor:I,hourHandColor:R,minuteHandColor:w,secondHandColor:D,primaryNumbersColor:X,majorNumbersColor:$,primaryTicksColor:oe,majorTicksColor:Fe,minorTicksColor:Z,centerCircleColor:Q,alarmRingColor:ie}=T,J=k.useRef(null),[ne,ze]=k.useState(0),[Ee,fe]=k.useState(!1),[De,Le]=k.useState(new Date("2011-10-10T14:48:00")),_e=tt(De);k.useEffect(()=>{_e&&n()},[_e]);const{seconds:de,minutes:he,hours:pe}=Hr(),me=k.useMemo(()=>a<=2&&a>=0?a:2,[a]),ge=k.useMemo(()=>!x&&p||.2,[x,p]),je=k.useMemo(()=>x?"":X,[x,X]),be=k.useMemo(()=>!b&&j||.15,[b,j]),rr=k.useMemo(()=>b?"":$,[b,$]),Ne=k.useMemo(()=>de*6,[de]),tr=k.useMemo(()=>he*6+de*.1,[he,de]),nr=k.useMemo(()=>pe%12*30+he*.5,[pe,he]),se=k.useCallback(()=>{if(J.current){const B=Math.min(J.current.offsetWidth,J.current.offsetHeight);ze(B/2)}},[]),ce=k.useCallback(B=>{Le(B),fe(!1)},[]);k.useEffect(()=>{const B=new ResizeObserver(()=>se());return J.current&&B.observe(J.current),()=>{J.current&&B.unobserve(J.current)}},[se]);const He=Rt(ne,a,c,u,h,oe,Fe,Z,M,S,f),Ve=Et({radius:ne,clockNumbersType:i,effectiveClockBorderThickness:me,effectivePrimaryNumbersFontSize:ge,effectiveMajorNumbersFontSize:be,effectivePrimaryNumbersColor:je,effectiveMajorNumbersColor:rr,hasPrimaryNumbers:C,hasMajorNumbers:d,PrimaryNumbersComponent:x,MajorNumbersComponent:b});return m.jsxs(Sn,{ref:J,borderThikness:me*(ne/16*.08),borderColor:I||"",backgroundColor:v||"",children:[He.map((B,le)=>m.jsx("div",{style:{...B},children:[0,15,30,45].includes(le)?M:le%5===0?S:f},le)),Ve.map(({num:B,x:le,y:ar,fontSize:Te,color:or,display:ir,style:Be},Ue)=>m.jsx(Rn,{topY:ar,leftX:le,fontSize:Te,color:or,display:ir,style:Be,children:B},Ue)),m.jsx(En,{hourAngle:nr,userBackgroundColor:R||""}),m.jsx(_n,{minuteAngle:tr,userBackgroundColor:w||""}),m.jsx(jn,{secondAngle:Ne,userBackgroundColor:D||""}),m.jsx(Tn,{children:g||m.jsx(Pn,{clockRadius:ne,backgroundColor:Q&&Q})}),o&&m.jsx(An,{offset:o.offset,children:o.cmp}),!Ee&&r&&m.jsx(et,{ringFillColor:ie||"yellow",iconSize:ne*.25,onClick:()=>fe(!0)}),Ee&&m.jsx(rt,{width:ne*2,top:.3,left:.195,onAlarmSet:ce,onCancel:()=>fe(!1),backgroundColor:v,boxShadowColor:X})]})},Fn=F.div(({padding:e,backgroundColor:r})=>({boxSizing:"border-box",width:"100%",aspectRatio:"3.5 / 1",display:"flex",justifyContent:"space-around",alignItems:"center",padding:`${e}rem`,direction:"ltr",backgroundColor:r||"white",position:"relative"})),ye=F.div(({style:e})=>({boxSizing:"border-box",aspectRatio:"1/2",position:"relative",...e})),Lr=F.div(({backgroundColor:e})=>({boxSizing:"border-box",width:"100%",height:"12.5%",backgroundColor:e||"black",clipPath:"polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%)",position:"absolute",top:"31.25%",left:0}));F.div({boxSizing:"border-box",height:"45%",border:"2px solid blue"});F.div(({style:e})=>({boxSizing:"border-box",position:"relative",...e}));const zn=F.div({boxSizing:"border-box",width:"100%",height:"100%",display:"flex",flexDirection:"column",justifyContent:"center",alignItems:"center"}),Dn=F.div({boxSizing:"border-box",width:"100%",height:"100%",display:"flex",flexDirection:"row",justifyContent:"center",alignItems:"center",gap:"200px"}),Nr=F.div({boxSizing:"border-box",width:"27%",display:"flex",justifyContent:"center",alignItems:"center"}),Ln=F.div({boxSizing:"border-box",width:"70%",height:"100%",display:"flex",justifyContent:"center",alignItems:"center"}),ke=({segmentsOn:e,activeSegmentColor:r,inactiveSegmentColor:n})=>{if(e.length!==7)throw new Error("segmentsOn must have exactly 7 boolean values.");const a=k.useMemo(()=>r||"black",[r]),o=k.useMemo(()=>n||"gray",[n]),i=k.useCallback(c=>c?a:o,[a,o]);return m.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 140 250",style:{width:"100%"},children:[m.jsx("polygon",{points:"25,0 115,0 125,10 105,30 35,30 15,10",stroke:"black",strokeWidth:"0",fill:i(e[0])}),m.jsx("polygon",{points:"0,25 0,115 10,125 30,105 30,35 10,15",stroke:"black",strokeWidth:"0",fill:i(e[1])}),m.jsx("polygon",{points:"0,135 0,225 10,235 30,215 30,145 10,125",stroke:"black",strokeWidth:"0",fill:i(e[2])}),m.jsx("polygon",{points:"140,225 140,135 130,125 110,145 110,215 130,235",stroke:"black",strokeWidth:"0",fill:i(e[3])}),m.jsx("polygon",{points:"140,115 140,25 130,15 110,35 110,105 130,125",stroke:"black",strokeWidth:"0",fill:i(e[4])}),m.jsx("polygon",{points:"115,250 25,250 15,240 35,220 105,220 125,240",stroke:"black",strokeWidth:"0",fill:i(e[5])}),m.jsx("polygon",{points:"35,110 105,110 120,125 105,140 35,140 20,125",stroke:"black",strokeWidth:"0",fill:i(e[6])})]})},Ce=e=>({0:[!0,!0,!0,!0,!0,!0,!1],1:[!1,!1,!1,!0,!0,!1,!1],2:[!0,!1,!0,!1,!0,!0,!0],3:[!0,!1,!1,!0,!0,!0,!0],4:[!1,!0,!1,!0,!0,!1,!0],5:[!0,!0,!1,!0,!1,!0,!0],6:[!0,!0,!0,!0,!1,!0,!0],7:[!0,!1,!1,!0,!0,!1,!1],8:[!0,!0,!0,!0,!0,!0,!0],9:[!0,!0,!1,!0,!0,!0,!0]})[e]||[!1,!1,!1,!1,!1,!1,!1],Nn=(e,r,n)=>{const a=d=>d<10?[0,d]:[Math.floor(d/10),d%10],[o,i]=a(e),[c,u]=a(r),[h,C]=a(n);return{hours:[Ce(o),Ce(i)],minutes:[Ce(c),Ce(u)],seconds:[Ce(h),Ce(C)]}},Hn=e=>{const{hasAlarm:r=!1,onAlarm:n=()=>{},padding:a=0,twentyFourHours:o=!1,colorConfiguration:i={}}=e,{backgroundColor:c,activeSegmentColor:u,inactiveSegmentColor:h,dotsColor:C,alarmRingColor:d}=i,{seconds:p,minutes:j,hours:M}=Hr(),[S,f]=k.useState(!1),[g,x]=k.useState(new Date("2011-10-10T14:48:00")),b=tt(g);k.useEffect(()=>{b&&n()},[b]);const T=k.useMemo(()=>o?M:M%12,[o,M]),v=k.useMemo(()=>Nn(T,j,p),[T,j,p]),I=k.useRef(null),[R,w]=k.useState(0),D=k.useCallback(()=>{I.current&&w(I.current.offsetWidth)},[]),X=k.useCallback($=>{f(!1),x($)},[]);return k.useLayoutEffect(()=>{const $=new ResizeObserver(()=>{D()});return I.current&&$.observe(I.current),()=>{I.current&&$.unobserve(I.current)}},[D]),m.jsxs(Fn,{padding:a,ref:I,backgroundColor:c||"white",children:[m.jsx(ye,{style:{width:`${.16*R}px`,height:`${.285714286*R}px`},children:m.jsx(ke,{activeSegmentColor:u||"black",inactiveSegmentColor:h||"white",segmentsOn:v==null?void 0:v.hours[0]})}),m.jsx(ye,{