Files
sunscope/assets/index-cxJ3Sbx3.js
T

2 lines
33 KiB
JavaScript
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const s of document.querySelectorAll('link[rel="modulepreload"]'))_(s);new MutationObserver(s=>{for(const i of s)if(i.type==="childList")for(const f of i.addedNodes)f.tagName==="LINK"&&f.rel==="modulepreload"&&_(f)}).observe(document,{childList:!0,subtree:!0});function n(s){const i={};return s.integrity&&(i.integrity=s.integrity),s.referrerPolicy&&(i.referrerPolicy=s.referrerPolicy),s.crossOrigin==="use-credentials"?i.credentials="include":s.crossOrigin==="anonymous"?i.credentials="omit":i.credentials="same-origin",i}function _(s){if(s.ep)return;s.ep=!0;const i=n(s);fetch(s.href,i)}})();var Z,N,Re,L,ke,Le,je,te,V,E,Oe,le,re,ce,J={},Y=[],Xe=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,ee=Array.isArray;function U(e,t){for(var n in t)e[n]=t[n];return e}function se(e){e&&e.parentNode&&e.parentNode.removeChild(e)}function Ze(e,t,n){var _,s,i,f={};for(i in t)i=="key"?_=t[i]:i=="ref"?s=t[i]:f[i]=t[i];if(arguments.length>2&&(f.children=arguments.length>3?Z.call(arguments,2):n),typeof e=="function"&&e.defaultProps!=null)for(i in e.defaultProps)f[i]===void 0&&(f[i]=e.defaultProps[i]);return q(e,f,_,s,null)}function q(e,t,n,_,s){var i={type:e,props:t,key:n,ref:_,__k:null,__:null,__b:0,__e:null,__c:null,constructor:void 0,__v:s??++Re,__i:-1,__u:0};return s==null&&N.vnode!=null&&N.vnode(i),i}function j(e){return e.children}function G(e,t){this.props=e,this.context=t}function O(e,t){if(t==null)return e.__?O(e.__,e.__i+1):null;for(var n;t<e.__k.length;t++)if((n=e.__k[t])!=null&&n.__e!=null)return n.__e;return typeof e.type=="function"?O(e):null}function et(e){if(e.__P&&e.__d){var t=e.__v,n=t.__e,_=[],s=[],i=U({},t);i.__v=t.__v+1,N.vnode&&N.vnode(i),_e(e.__P,i,t,e.__n,e.__P.namespaceURI,32&t.__u?[n]:null,_,n??O(t),!!(32&t.__u),s),i.__v=t.__v,i.__.__k[i.__i]=i,ze(_,i,s),t.__e=t.__=null,i.__e!=n&&Be(i)}}function Be(e){if((e=e.__)!=null&&e.__c!=null)return e.__e=e.__c.base=null,e.__k.some(function(t){if(t!=null&&t.__e!=null)return e.__e=e.__c.base=t.__e}),Be(e)}function we(e){(!e.__d&&(e.__d=!0)&&L.push(e)&&!Q.__r++||ke!=N.debounceRendering)&&((ke=N.debounceRendering)||Le)(Q)}function Q(){try{for(var e,t=1;L.length;)L.length>t&&L.sort(je),e=L.shift(),t=L.length,et(e)}finally{L.length=Q.__r=0}}function Ee(e,t,n,_,s,i,f,r,l,c,d){var o,p,m,b,w,h,y,k=_&&_.__k||Y,C=t.length;for(l=tt(n,t,k,l,C),o=0;o<C;o++)(m=n.__k[o])!=null&&(p=m.__i!=-1&&k[m.__i]||J,m.__i=o,h=_e(e,m,p,s,i,f,r,l,c,d),b=m.__e,m.ref&&p.ref!=m.ref&&(p.ref&&de(p.ref,null,m),d.push(m.ref,m.__c||b,m)),w==null&&b!=null&&(w=b),(y=!!(4&m.__u))||p.__k===m.__k?(l=We(m,l,e,y),y&&p.__e&&(p.__e=null)):typeof m.type=="function"&&h!==void 0?l=h:b&&(l=b.nextSibling),m.__u&=-7);return n.__e=w,l}function tt(e,t,n,_,s){var i,f,r,l,c,d=n.length,o=d,p=0;for(e.__k=new Array(s),i=0;i<s;i++)(f=t[i])!=null&&typeof f!="boolean"&&typeof f!="function"?(typeof f=="string"||typeof f=="number"||typeof f=="bigint"||f.constructor==String?f=e.__k[i]=q(null,f,null,null,null):ee(f)?f=e.__k[i]=q(j,{children:f},null,null,null):f.constructor===void 0&&f.__b>0?f=e.__k[i]=q(f.type,f.props,f.key,f.ref?f.ref:null,f.__v):e.__k[i]=f,l=i+p,f.__=e,f.__b=e.__b+1,r=null,(c=f.__i=nt(f,n,l,o))!=-1&&(o--,(r=n[c])&&(r.__u|=2)),r==null||r.__v==null?(c==-1&&(s>d?p--:s<d&&p++),typeof f.type!="function"&&(f.__u|=4)):c!=l&&(c==l-1?p--:c==l+1?p++:(c>l?p--:p++,f.__u|=4))):e.__k[i]=null;if(o)for(i=0;i<d;i++)(r=n[i])!=null&&!(2&r.__u)&&(r.__e==_&&(_=O(r)),qe(r,r));return _}function We(e,t,n,_){var s,i;if(typeof e.type=="function"){for(s=e.__k,i=0;s&&i<s.length;i++)s[i]&&(s[i].__=e,t=We(s[i],t,n,_));return t}e.__e!=t&&(_&&(t&&e.type&&!t.parentNode&&(t=O(e)),n.insertBefore(e.__e,t||null)),t=e.__e);do t=t&&t.nextSibling;while(t!=null&&t.nodeType==8);return t}function nt(e,t,n,_){var s,i,f,r=e.key,l=e.type,c=t[n],d=c!=null&&(2&c.__u)==0;if(c===null&&r==null||d&&r==c.key&&l==c.type)return n;if(_>(d?1:0)){for(s=n-1,i=n+1;s>=0||i<t.length;)if((c=t[f=s>=0?s--:i++])!=null&&!(2&c.__u)&&r==c.key&&l==c.type)return f}return-1}function Ne(e,t,n){t[0]=="-"?e.setProperty(t,n??""):e[t]=n==null?"":typeof n!="number"||Xe.test(t)?n:n+"px"}function z(e,t,n,_,s){var i,f;e:if(t=="style")if(typeof n=="string")e.style.cssText=n;else{if(typeof _=="string"&&(e.style.cssText=_=""),_)for(t in _)n&&t in n||Ne(e.style,t,"");if(n)for(t in n)_&&n[t]==_[t]||Ne(e.style,t,n[t])}else if(t[0]=="o"&&t[1]=="n")i=t!=(t=t.replace(Oe,"$1")),f=t.toLowerCase(),t=f in e||t=="onFocusOut"||t=="onFocusIn"?f.slice(2):t.slice(2),e.l||(e.l={}),e.l[t+i]=n,n?_?n[E]=_[E]:(n[E]=le,e.addEventListener(t,i?ce:re,i)):e.removeEventListener(t,i?ce:re,i);else{if(s=="http://www.w3.org/2000/svg")t=t.replace(/xlink(H|:h)/,"h").replace(/sName$/,"s");else if(t!="width"&&t!="height"&&t!="href"&&t!="list"&&t!="form"&&t!="tabIndex"&&t!="download"&&t!="rowSpan"&&t!="colSpan"&&t!="role"&&t!="popover"&&t in e)try{e[t]=n??"";break e}catch{}typeof n=="function"||(n==null||n===!1&&t[4]!="-"?e.removeAttribute(t):e.setAttribute(t,t=="popover"&&n==1?"":n))}}function Me(e){return function(t){if(this.l){var n=this.l[t.type+e];if(t[V]==null)t[V]=le++;else if(t[V]<n[E])return;return n(N.event?N.event(t):t)}}}function _e(e,t,n,_,s,i,f,r,l,c){var d,o,p,m,b,w,h,y,k,C,D,g,M,T,I,A=t.type;if(t.constructor!==void 0)return null;128&n.__u&&(l=!!(32&n.__u),i=[r=t.__e=n.__e]),(d=N.__b)&&d(t);e:if(typeof A=="function")try{if(y=t.props,k=A.prototype&&A.prototype.render,C=(d=A.contextType)&&_[d.__c],D=d?C?C.props.value:d.__:_,n.__c?h=(o=t.__c=n.__c).__=o.__E:(k?t.__c=o=new A(y,D):(t.__c=o=new G(y,D),o.constructor=A,o.render=rt),C&&C.sub(o),o.state||(o.state={}),o.__n=_,p=o.__d=!0,o.__h=[],o._sb=[]),k&&o.__s==null&&(o.__s=o.state),k&&A.getDerivedStateFromProps!=null&&(o.__s==o.state&&(o.__s=U({},o.__s)),U(o.__s,A.getDerivedStateFromProps(y,o.__s))),m=o.props,b=o.state,o.__v=t,p)k&&A.getDerivedStateFromProps==null&&o.componentWillMount!=null&&o.componentWillMount(),k&&o.componentDidMount!=null&&o.__h.push(o.componentDidMount);else{if(k&&A.getDerivedStateFromProps==null&&y!==m&&o.componentWillReceiveProps!=null&&o.componentWillReceiveProps(y,D),t.__v==n.__v||!o.__e&&o.shouldComponentUpdate!=null&&o.shouldComponentUpdate(y,o.__s,D)===!1){t.__v!=n.__v&&(o.props=y,o.state=o.__s,o.__d=!1),t.__e=n.__e,t.__k=n.__k,t.__k.some(function(v){v&&(v.__=t)}),Y.push.apply(o.__h,o._sb),o._sb=[],o.__h.length&&f.push(o);break e}o.componentWillUpdate!=null&&o.componentWillUpdate(y,o.__s,D),k&&o.componentDidUpdate!=null&&o.__h.push(function(){o.componentDidUpdate(m,b,w)})}if(o.context=D,o.props=y,o.__P=e,o.__e=!1,g=N.__r,M=0,k)o.state=o.__s,o.__d=!1,g&&g(t),d=o.render(o.props,o.state,o.context),Y.push.apply(o.__h,o._sb),o._sb=[];else do o.__d=!1,g&&g(t),d=o.render(o.props,o.state,o.context),o.state=o.__s;while(o.__d&&++M<25);o.state=o.__s,o.getChildContext!=null&&(_=U(U({},_),o.getChildContext())),k&&!p&&o.getSnapshotBeforeUpdate!=null&&(w=o.getSnapshotBeforeUpdate(m,b)),T=d!=null&&d.type===j&&d.key==null?Ve(d.props.children):d,r=Ee(e,ee(T)?T:[T],t,n,_,s,i,f,r,l,c),o.base=t.__e,t.__u&=-161,o.__h.length&&f.push(o),h&&(o.__E=o.__=null)}catch(v){if(t.__v=null,l||i!=null)if(v.then){for(t.__u|=l?160:128;r&&r.nodeType==8&&r.nextSibling;)r=r.nextSibling;i[i.indexOf(r)]=null,t.__e=r}else{for(I=i.length;I--;)se(i[I]);ie(t)}else t.__e=n.__e,t.__k=n.__k,v.then||ie(t);N.__e(v,t,n)}else i==null&&t.__v==n.__v?(t.__k=n.__k,t.__e=n.__e):r=t.__e=ot(n.__e,t,n,_,s,i,f,l,c);return(d=N.diffed)&&d(t),128&t.__u?void 0:r}function ie(e){e&&(e.__c&&(e.__c.__e=!0),e.__k&&e.__k.some(ie))}function ze(e,t,n){for(var _=0;_<n.length;_++)de(n[_],n[++_],n[++_]);N.__c&&N.__c(t,e),e.some(function(s){try{e=s.__h,s.__h=[],e.some(function(i){i.call(s)})}catch(i){N.__e(i,s.__v)}})}function Ve(e){return typeof e!="object"||e==null||e.__b>0?e:ee(e)?e.map(Ve):U({},e)}function ot(e,t,n,_,s,i,f,r,l){var c,d,o,p,m,b,w,h=n.props||J,y=t.props,k=t.type;if(k=="svg"?s="http://www.w3.org/2000/svg":k=="math"?s="http://www.w3.org/1998/Math/MathML":s||(s="http://www.w3.org/1999/xhtml"),i!=null){for(c=0;c<i.length;c++)if((m=i[c])&&"setAttribute"in m==!!k&&(k?m.localName==k:m.nodeType==3)){e=m,i[c]=null;break}}if(e==null){if(k==null)return document.createTextNode(y);e=document.createElementNS(s,k,y.is&&y),r&&(N.__m&&N.__m(t,i),r=!1),i=null}if(k==null)h===y||r&&e.data==y||(e.data=y);else{if(i=i&&Z.call(e.childNodes),!r&&i!=null)for(h={},c=0;c<e.attributes.length;c++)h[(m=e.attributes[c]).name]=m.value;for(c in h)m=h[c],c=="dangerouslySetInnerHTML"?o=m:c=="children"||c in y||c=="value"&&"defaultValue"in y||c=="checked"&&"defaultChecked"in y||z(e,c,null,m,s);for(c in y)m=y[c],c=="children"?p=m:c=="dangerouslySetInnerHTML"?d=m:c=="value"?b=m:c=="checked"?w=m:r&&typeof m!="function"||h[c]===m||z(e,c,m,h[c],s);if(d)r||o&&(d.__html==o.__html||d.__html==e.innerHTML)||(e.innerHTML=d.__html),t.__k=[];else if(o&&(e.innerHTML=""),Ee(t.type=="template"?e.content:e,ee(p)?p:[p],t,n,_,k=="foreignObject"?"http://www.w3.org/1999/xhtml":s,i,f,i?i[0]:n.__k&&O(n,0),r,l),i!=null)for(c=i.length;c--;)se(i[c]);r||(c="value",k=="progress"&&b==null?e.removeAttribute("value"):b!=null&&(b!==e[c]||k=="progress"&&!b||k=="option"&&b!=h[c])&&z(e,c,b,h[c],s),c="checked",w!=null&&w!=e[c]&&z(e,c,w,h[c],s))}return e}function de(e,t,n){try{if(typeof e=="function"){var _=typeof e.__u=="function";_&&e.__u(),_&&t==null||(e.__u=e(t))}else e.current=t}catch(s){N.__e(s,n)}}function qe(e,t,n){var _,s;if(N.unmount&&N.unmount(e),(_=e.ref)&&(_.current&&_.current!=e.__e||de(_,null,t)),(_=e.__c)!=null){if(_.componentWillUnmount)try{_.componentWillUnmount()}catch(i){N.__e(i,t)}_.base=_.__P=null}if(_=e.__k)for(s=0;s<_.length;s++)_[s]&&qe(_[s],t,n||typeof e.type!="function");n||se(e.__e),e.__c=e.__=e.__e=void 0}function rt(e,t,n){return this.constructor(e,n)}function ct(e,t,n){var _,s,i,f;t==document&&(t=document.documentElement),N.__&&N.__(e,t),s=(_=!1)?null:t.__k,i=[],f=[],_e(t,e=t.__k=Ze(j,null,[e]),s||J,J,t.namespaceURI,s?null:t.firstChild?Z.call(t.childNodes):null,i,s?s.__e:t.firstChild,_,f),ze(i,e,f)}Z=Y.slice,N={__e:function(e,t,n,_){for(var s,i,f;t=t.__;)if((s=t.__c)&&!s.__)try{if((i=s.constructor)&&i.getDerivedStateFromError!=null&&(s.setState(i.getDerivedStateFromError(e)),f=s.__d),s.componentDidCatch!=null&&(s.componentDidCatch(e,_||{}),f=s.__d),f)return s.__E=s}catch(r){e=r}throw e}},Re=0,G.prototype.setState=function(e,t){var n;n=this.__s!=null&&this.__s!=this.state?this.__s:this.__s=U({},this.state),typeof e=="function"&&(e=e(U({},n),this.props)),e&&U(n,e),e!=null&&this.__v&&(t&&this._sb.push(t),we(this))},G.prototype.forceUpdate=function(e){this.__v&&(this.__e=!0,e&&this.__h.push(e),we(this))},G.prototype.render=j,L=[],Le=typeof Promise=="function"?Promise.prototype.then.bind(Promise.resolve()):setTimeout,je=function(e,t){return e.__v.__b-t.__v.__b},Q.__r=0,te=Math.random().toString(8),V="__d"+te,E="__a"+te,Oe=/(PointerCapture)$|Capture$/i,le=0,re=Me(!1),ce=Me(!0);var it=0;function a(e,t,n,_,s,i){t||(t={});var f,r,l=t;if("ref"in l)for(r in l={},t)r=="ref"?f=t[r]:l[r]=t[r];var c={type:e,props:l,key:n,ref:f,__k:null,__:null,__b:0,__e:null,__c:null,constructor:void 0,__v:--it,__i:-1,__u:0,__source:s,__self:i};if(typeof e=="function"&&(f=e.defaultProps))for(r in f)l[r]===void 0&&(l[r]=f[r]);return N.vnode&&N.vnode(c),c}var W,P,ne,Ce,X=0,Ge=[],$=N,Te=$.__b,Se=$.__r,Pe=$.diffed,$e=$.__c,De=$.unmount,Ie=$.__;function ue(e,t){$.__h&&$.__h(P,e,X||t),X=0;var n=P.__H||(P.__H={__:[],__h:[]});return e>=n.__.length&&n.__.push({}),n.__[e]}function F(e){return X=1,at(Je,e)}function at(e,t,n){var _=ue(W++,2);if(_.t=e,!_.__c&&(_.__=[Je(void 0,t),function(r){var l=_.__N?_.__N[0]:_.__[0],c=_.t(l,r);l!==c&&(_.__N=[c,_.__[1]],_.__c.setState({}))}],_.__c=P,!P.__f)){var s=function(r,l,c){if(!_.__c.__H)return!0;var d=_.__c.__H.__.filter(function(p){return p.__c});if(d.every(function(p){return!p.__N}))return!i||i.call(this,r,l,c);var o=_.__c.props!==r;return d.some(function(p){if(p.__N){var m=p.__[0];p.__=p.__N,p.__N=void 0,m!==p.__[0]&&(o=!0)}}),i&&i.call(this,r,l,c)||o};P.__f=!0;var i=P.shouldComponentUpdate,f=P.componentWillUpdate;P.componentWillUpdate=function(r,l,c){if(this.__e){var d=i;i=void 0,s(r,l,c),i=d}f&&f.call(this,r,l,c)},P.shouldComponentUpdate=s}return _.__N||_.__}function Ae(e,t){var n=ue(W++,3);!$.__s&&Ke(n.__H,t)&&(n.__=e,n.u=t,P.__H.__h.push(n))}function lt(e){return X=5,st(function(){return{current:e}},[])}function st(e,t){var n=ue(W++,7);return Ke(n.__H,t)&&(n.__=e(),n.__H=t,n.__h=e),n.__}function _t(){for(var e;e=Ge.shift();){var t=e.__H;if(e.__P&&t)try{t.__h.some(K),t.__h.some(ae),t.__h=[]}catch(n){t.__h=[],$.__e(n,e.__v)}}}$.__b=function(e){P=null,Te&&Te(e)},$.__=function(e,t){e&&t.__k&&t.__k.__m&&(e.__m=t.__k.__m),Ie&&Ie(e,t)},$.__r=function(e){Se&&Se(e),W=0;var t=(P=e.__c).__H;t&&(ne===P?(t.__h=[],P.__h=[],t.__.some(function(n){n.__N&&(n.__=n.__N),n.u=n.__N=void 0})):(t.__h.some(K),t.__h.some(ae),t.__h=[],W=0)),ne=P},$.diffed=function(e){Pe&&Pe(e);var t=e.__c;t&&t.__H&&(t.__H.__h.length&&(Ge.push(t)!==1&&Ce===$.requestAnimationFrame||((Ce=$.requestAnimationFrame)||dt)(_t)),t.__H.__.some(function(n){n.u&&(n.__H=n.u),n.u=void 0})),ne=P=null},$.__c=function(e,t){t.some(function(n){try{n.__h.some(K),n.__h=n.__h.filter(function(_){return!_.__||ae(_)})}catch(_){t.some(function(s){s.__h&&(s.__h=[])}),t=[],$.__e(_,n.__v)}}),$e&&$e(e,t)},$.unmount=function(e){De&&De(e);var t,n=e.__c;n&&n.__H&&(n.__H.__.some(function(_){try{K(_)}catch(s){t=s}}),n.__H=void 0,t&&$.__e(t,n.__v))};var He=typeof requestAnimationFrame=="function";function dt(e){var t,n=function(){clearTimeout(_),He&&cancelAnimationFrame(t),setTimeout(e)},_=setTimeout(n,35);He&&(t=requestAnimationFrame(n))}function K(e){var t=P,n=e.__c;typeof n=="function"&&(e.__c=void 0,n()),P=t}function ae(e){var t=P;e.__c=e.__(),P=t}function Ke(e,t){return!e||e.length!==t.length||t.some(function(n,_){return n!==e[_]})}function Je(e,t){return typeof t=="function"?t(e):t}const Fe=5670374419e-17,Ue=.97,ut=.7,ht=.23;function ft(e,t){return 6.105*Math.exp(17.27*e/(237.7+e))*(t/100)}function mt(e,t,n){const _=Date.UTC(n.getUTCFullYear(),0,0),s=n-_,i=Math.floor(s/864e5),f=n.getUTCHours()+n.getUTCMinutes()/60+n.getUTCSeconds()/3600,r=2*Math.PI/365*(i-1+(f-12)/24),l=229.18*(75e-6+.001868*Math.cos(r)-.032077*Math.sin(r)-.014615*Math.cos(2*r)-.040849*Math.sin(2*r)),c=.006918-.399912*Math.cos(r)+.070257*Math.sin(r)-.006758*Math.cos(2*r)+907e-6*Math.sin(2*r)-.002697*Math.cos(3*r)+.00148*Math.sin(3*r),d=l+4*t,p=((f*60+d)/4-180)*Math.PI/180,m=e*Math.PI/180,b=Math.sin(m)*Math.sin(c)+Math.cos(m)*Math.cos(c)*Math.cos(p),w=Math.acos(Math.max(-1,Math.min(1,b)));return(Math.PI/2-w)*(180/Math.PI)}function pt(e,t,n,_,s){const i=e+273.15;let f=0;if(s>0){const o=s;f=.308*Math.cos(Math.PI/180*o*(.998-o*o/5e4))}let r=0;s>1&&(r=t/Math.sin(s*Math.PI/180),r=Math.min(r,1100));const l=ut*(f*r+.5*n+.5*ht*_),c=Ue*Fe*Math.pow(i,4);return Math.pow((l+c)/(Ue*Fe),.25)-273.15}function yt(e,t,n,_){const s=Math.max(.5,Math.min(17,n)),i=t-e,f=_/10,r=e,l=s,c=i,d=f,o=r*r,p=o*r,m=p*r,b=m*r,w=b*r,h=l*l,y=h*l,k=y*l,C=k*l,D=C*l,g=c*c,M=g*c,T=M*c,I=T*c,A=I*c,v=d*d,u=v*d,x=u*d,S=x*d,H=S*d;return r+.607562052+-.0227712343*r+.000806470249*o+-.000154271372*p+-324651735e-14*m+732602852e-16*b+135959073e-17*w+-2.2583652*l+.0880326035*r*l+.00216844454*o*l+-153347087e-13*p*l+-572983704e-15*m*l+-255090145e-17*b*l+-.751269505*h+-.00408350271*r*h+-521670675e-13*o*h+194544667e-14*p*h+114099531e-16*m*h+.158137256*y+-657263143e-13*r*y+222697524e-15*o*y+-416117031e-16*p*y+-.0127762753*k+966891875e-14*r*k+252785852e-17*o*k+.000456306672*C+-174202546e-15*r*C+-591491269e-14*D+.398374029*c+.000183945314*r*c+-.00017375451*o*c+-760781159e-15*p*c+377830287e-16*m*c+543079673e-18*b*c+-.0200518269*l*c+.000892859837*r*l*c+345433048e-14*o*l*c+-377925774e-15*p*l*c+-169699377e-17*m*l*c+.000169992415*h*c+-499204314e-13*r*h*c+247417178e-15*o*h*c+107596466e-16*p*h*c+849242932e-13*y*c+135191328e-14*r*y*c+-621531254e-17*o*y*c+-499410301e-14*k*c+-189489258e-16*r*k*c+815300114e-16*C*c+.00075504309*g+-565095215e-13*r*g+-452166564e-15*o*g+246688878e-16*p*g+242674348e-18*m*g+.00015454725*l*g+52411097e-13*r*l*g+-875874982e-16*o*l*g+-150743064e-17*p*l*g+-156236307e-13*h*g+-133895614e-15*r*h*g+249709824e-17*o*h*g+651711721e-15*y*g+194960053e-17*r*y*g+-100361113e-16*k*g+-121206673e-13*M+-21820366e-14*r*M+751269482e-17*o*M+979063848e-19*p*M+125006734e-14*l*M+-181584736e-17*r*l*M+-352197671e-18*o*l*M+-33651463e-15*h*M+135908359e-18*r*h*M+41703262e-17*y*M+-130369025e-17*T+413908461e-18*r*T+922652254e-20*o*T+-508220384e-17*l*T+-224730961e-19*r*l*T+117139133e-18*h*T+662154879e-18*I+40386326e-20*r*I+195087203e-20*l*I+-473602469e-20*A+5.12733497*d+-.312788561*r*d+-.0196701861*o*d+.00099969087*p*d+951738512e-14*m*d+-466426341e-15*b*d+.548050612*l*d+-.00330552823*r*l*d+-.0016411944*o*l*d+-516670694e-14*p*l*d+952692432e-15*m*l*d+-.0429223622*h*d+.00500845667*r*h*d+100601257e-14*o*h*d+-181748644e-14*p*h*d+-.00125813502*y*d+-.000179330391*r*y*d+234994441e-14*o*y*d+.000129735808*k*d+12906487e-13*r*k*d+-228558686e-14*C*d+-.0369476348*c*d+.00162325322*r*c*d+-31427968e-12*o*c*d+259835559e-14*p*c*d+-477136523e-16*m*c*d+.0086420339*l*c*d+-.000687405181*r*l*c*d+-913863872e-14*o*l*c*d+515916806e-15*p*l*c*d+-359217476e-13*h*c*d+328696511e-13*r*h*c*d+-710542454e-15*o*h*c*d+-1243823e-11*y*c*d+-7385844e-15*r*y*c*d+220609296e-15*k*c*d+-.00073246918*g*d+-187381964e-13*r*g*d+480925239e-14*o*g*d+-87549204e-15*p*g*d+27786293e-12*l*g*d+-506004592e-14*r*l*g*d+114325367e-15*o*l*g*d+253016723e-14*h*g*d+-172857035e-16*r*h*g*d+-395079398e-16*y*g*d+-359413173e-15*M*d+704388046e-15*r*M*d+-189309167e-16*o*M*d+-479768731e-15*l*M*d+796079978e-17*r*l*M*d+162897058e-17*h*M*d+394367674e-16*T*d+-118566247e-17*r*T*d+334678041e-18*l*T*d+-115606447e-18*I*d+-2.80626406*v+.548712484*r*v+-.0039942841*o*v+-.000954009191*p*v+193090978e-13*m*v+-.308806365*l*v+.0116952364*r*l*v+.000495271903*o*l*v+-190710882e-13*p*l*v+.00210787756*h*v+-.000698445738*r*h*v+230109073e-13*o*h*v+.00041785659*y*v+-127043871e-13*r*y*v+-304620472e-14*k*v+.0514507424*c*v+-.00432510997*r*c*v+899281156e-13*o*c*v+-714663943e-15*p*c*v+-.000266016305*l*c*v+.000263789586*r*l*c*v+-701199003e-14*o*l*c*v+-.000106823306*h*c*v+361341136e-14*r*h*c*v+229748967e-15*y*c*v+.000304788893*g*v+-642070836e-13*r*g*v+116257971e-14*o*g*v+768023384e-14*l*g*v+-547446896e-15*r*l*g*v+-35993791e-15*h*g*v+-436497725e-14*M*v+168737969e-15*r*M*v+267489271e-16*l*M*v+323926897e-17*T*v+-.0353874123*u+-.22120119*r*u+.0155126038*o*u+-.000263917279*p*u+.0453433455*l*u+-.00432943862*r*l*u+.000145389826*o*l*u+.00021750861*h*u+-666724702e-13*r*h*u+33321714e-12*y*u+-.00226921615*c*u+.000380261982*r*c*u+-545314314e-17*o*c*u+-.000796355448*l*c*u+253458034e-13*r*l*c*u+-631223658e-14*h*c*u+.000302122035*g*u+-477403547e-14*r*g*u+173825715e-14*l*g*u+-409087898e-15*M*u+.614155345*x+-.0616755931*r*x+.00133374846*o*x+.00355375387*l*x+-.000513027851*r*l*x+.000102449757*h*x+-.00148526421*c*x+-411469183e-13*r*c*x+-680434415e-14*l*c*x+-977675906e-14*g*x+.0882773108*S+-.00301859306*r*S+.00104452989*l*S+.000247090539*c*S+.00148348065*H}function oe(e){return e<-40?{label:"Extreme cold",bg:"#1a1438",fg:"#fff"}:e<-27?{label:"Very strong cold",bg:"#23408f",fg:"#fff"}:e<-13?{label:"Arctic",bg:"#3f73c4",fg:"#fff"}:e<0?{label:"Freezing",bg:"#7eb0e0",fg:"#1a1612"}:e<9?{label:"Cold",bg:"#bcd9ec",fg:"#1a1612"}:e<18?{label:"Chilled",bg:"#c8dcc0",fg:"#1a1612"}:e<26?{label:"Comfortable",bg:"#6ab05a",fg:"#fff"}:e<32?{label:"Moderate heat",bg:"#e8c547",fg:"#1a1612"}:e<38?{label:"Strong heat",bg:"#dc8a3a",fg:"#1a1612"}:e<46?{label:"Very strong heat",bg:"#c44a3a",fg:"#fff"}:{label:"Extreme heat",bg:"#7a1a1a",fg:"#fff"}}function gt({value:e,cat:t,loading:n}){const f=Array.from({length:36},(m,b)=>{const h=(b*10-90)*Math.PI/180,y=b%9===0,k=b%3===0,C=y?72:k?78:82;return{x1:100+86*Math.cos(h),y1:100+86*Math.sin(h),x2:100+C*Math.cos(h),y2:100+C*Math.sin(h),major:y,medium:k}}),r=[{min:-40,max:-27,color:"#23408f"},{min:-27,max:-13,color:"#3f73c4"},{min:-13,max:0,color:"#7eb0e0"},{min:0,max:9,color:"#bcd9ec"},{min:9,max:18,color:"#c8dcc0"},{min:18,max:26,color:"#6ab05a"},{min:26,max:32,color:"#e8c547"},{min:32,max:38,color:"#dc8a3a"},{min:38,max:46,color:"#c44a3a"},{min:46,max:50,color:"#7a1a1a"}];function l(m,b){const h=(135+m*270)*Math.PI/180;return[100+b*Math.cos(h),100+b*Math.sin(h)]}function c(m){const b=Math.min(1,Math.max(0,(m.min+10)/60)),w=Math.min(1,Math.max(0,(m.max+10)/60)),h=68,[y,k]=l(b,h),[C,D]=l(w,h),g=(w-b)*270>180?1:0;return`M ${y} ${k} A ${h} ${h} 0 ${g} 1 ${C} ${D}`}let d=100,o=154;if(e!=null){const w=(135+Math.min(1,Math.max(0,(e+10)/60))*270)*Math.PI/180;d=100+54*Math.cos(w),o=100+54*Math.sin(w)}const p=t?t.bg:"#c8922a";return a("svg",{viewBox:"0 0 200 200",className:"scope-ring","aria-label":"Current UTCI scope readout",children:[a("defs",{children:a("radialGradient",{id:"scope-bg-glow",cx:"50%",cy:"50%",r:"50%",children:[a("stop",{offset:"0%","stop-color":p,"stop-opacity":"0.12"}),a("stop",{offset:"100%","stop-color":p,"stop-opacity":"0"})]})}),a("circle",{cx:100,cy:100,r:"96",fill:"url(#scope-bg-glow)"}),r.map((m,b)=>a("path",{d:c(m),fill:"none",stroke:m.color,"stroke-width":"4",opacity:"0.4","stroke-linecap":"butt"},b)),a("circle",{cx:100,cy:100,r:86,fill:"none",stroke:"#c9b08a","stroke-width":"1.5"}),f.map((m,b)=>a("line",{x1:m.x1,y1:m.y1,x2:m.x2,y2:m.y2,stroke:m.major?"#c8922a":m.medium?"#c9b08a":"#e0d0b0","stroke-width":m.major?1.5:.75},b)),a("line",{x1:17,y1:100,x2:68,y2:100,stroke:"#d4b896","stroke-width":"0.75"}),a("line",{x1:132,y1:100,x2:183,y2:100,stroke:"#d4b896","stroke-width":"0.75"}),a("line",{x1:100,y1:17,x2:100,y2:68,stroke:"#d4b896","stroke-width":"0.75"}),a("line",{x1:100,y1:132,x2:100,y2:183,stroke:"#d4b896","stroke-width":"0.75"}),a("circle",{cx:100,cy:100,r:"58",fill:"none",stroke:"#e8d8c0","stroke-width":"0.75"}),a("circle",{cx:100,cy:100,r:"32",fill:"none",stroke:"#e8d8c0","stroke-width":"0.5"}),[[-1,-1],[1,-1],[-1,1],[1,1]].map(([m,b],w)=>a("g",{children:[a("line",{x1:100+m*72,y1:100+b*72,x2:100+m*60,y2:100+b*72,stroke:"#c9b08a","stroke-width":"1"}),a("line",{x1:100+m*72,y1:100+b*72,x2:100+m*72,y2:100+b*60,stroke:"#c9b08a","stroke-width":"1"})]},w)),e!=null&&a(j,{children:[a("line",{x1:100,y1:100,x2:d,y2:o,stroke:"#c8922a","stroke-width":"3","stroke-linecap":"round",opacity:"0.18"}),a("line",{x1:100,y1:100,x2:d,y2:o,stroke:"#c8922a","stroke-width":"1.5","stroke-linecap":"round",opacity:"0.95"})]}),a("circle",{cx:100,cy:100,r:"5.5",fill:"#f5edd6",stroke:"#c8922a","stroke-width":"1.5"}),a("circle",{cx:100,cy:100,r:"2.5",fill:"#c8922a"}),n?a("text",{x:100,y:105,"text-anchor":"middle",fill:"#b09870","font-size":"11","font-family":"monospace",children:"· · ·"}):e!=null?a(j,{children:[a("text",{x:100,y:92,"text-anchor":"middle",fill:"#1e1208","font-size":"26","font-family":"Fraunces, serif","font-weight":"700",children:[e.toFixed(1),"°"]}),a("text",{x:100,y:107,"text-anchor":"middle",fill:"#9a7d5a","font-size":"6.5","font-family":"JetBrains Mono, monospace","letter-spacing":"2",children:"UTCI NOW"}),a("text",{x:100,y:119,"text-anchor":"middle",fill:p,"font-size":"7","font-family":"JetBrains Mono, monospace","letter-spacing":"0.8",children:t.label.toUpperCase()})]}):a("text",{x:100,y:105,"text-anchor":"middle",fill:"#b09870","font-size":"8","font-family":"JetBrains Mono, monospace","letter-spacing":"1.2",children:"AWAITING"})]})}function bt(e,t,n){let _=0;if(e>0){const s=Math.min(7,1.4*Math.pow(e,.55)+e*.28),i=1+Math.min(.35,n*.025);_+=s*i}return t>0&&(_+=Math.min(6,2.2+t*1.6)),-Math.round(_*10)/10}function vt(){var v;const[e,t]=F({name:"Pangbourne, Berkshire",lat:51.4839,lon:-1.0725,country:"GB"}),[n,_]=F(null),[s,i]=F(!1),[f,r]=F(null),[l,c]=F(""),[d,o]=F([]),[p,m]=F(!1),[b,w]=F(0),[h,y]=F({hour:!0,air:!0,rh:!0,wind:!0,cloud:!1,sun:!1,direct:!1,diffuse:!1,tmrt:!1,delta:!1,utci:!1,utciP:!0,precip:!0}),k=u=>y(x=>({...x,[u]:!x[u]})),C=lt(null);Ae(()=>{if(l.length<2){o([]);return}C.current&&clearTimeout(C.current),C.current=setTimeout(async()=>{m(!0);try{const x=await(await fetch(`https://geocoding-api.open-meteo.com/v1/search?name=${encodeURIComponent(l)}&count=6&language=en&format=json`)).json();o(x.results||[])}catch{o([])}finally{m(!1)}},300)},[l]),Ae(()=>{async function u(){i(!0),r(null);try{const x=`https://api.open-meteo.com/v1/forecast?latitude=${e.lat}&longitude=${e.lon}&hourly=temperature_2m,relative_humidity_2m,wind_speed_10m,direct_radiation,diffuse_radiation,shortwave_radiation,cloud_cover,precipitation,snowfall&wind_speed_unit=ms&timezone=auto&forecast_days=3`,S=await fetch(x);if(!S.ok)throw new Error(`Open-Meteo HTTP ${S.status}`);_(await S.json())}catch(x){r(x.message)}finally{i(!1)}}u()},[e]);const D=n?n.hourly.time.map((u,x)=>{const S=n.hourly.temperature_2m[x],H=n.hourly.relative_humidity_2m[x],R=n.hourly.wind_speed_10m[x],B=n.hourly.direct_radiation[x]||0,he=n.hourly.diffuse_radiation[x]||0,fe=n.hourly.shortwave_radiation[x]||0,Ye=n.hourly.cloud_cover[x],me=n.hourly.precipitation[x]||0,pe=n.hourly.snowfall[x]||0,ye=new Date(u),ge=mt(e.lat,e.lon,ye),be=ft(S,H),ve=pt(S,B,he,fe,ge),xe=yt(S,ve,R,be),Qe=xe+bt(me,pe,R);return{iso:u,dt:ye,Ta:S,RH:H,va:R,dir:B,dif:he,glob:fe,cc:Ye,precip:me,snow:pe,elev:ge,Tmrt:ve,utci:xe,utciAdj:Qe,eh:be}}):[],g=[];D.forEach(u=>{const x=u.iso.slice(0,10);let S=g.find(H=>H.key===x);S||(S={key:x,date:new Date(u.iso),rows:[]},g.push(S)),S.rows.push(u)});const M=((v=g[b])==null?void 0:v.rows)||[],T=new Date,I=D.length>0?D.find(u=>T.toDateString()===u.dt.toDateString()&&T.getHours()===u.dt.getHours())??D.reduce((u,x)=>Math.abs(x.dt-T)<Math.abs(u.dt-T)?x:u):null,A=I?oe(I.utciAdj):{bg:"#4a4228",fg:"#ede4cc",label:"No data"};return a("div",{className:"utci-app",children:[a("nav",{className:"utci-topnav",children:[a("a",{href:"./index.html",children:"Home"}),a("a",{href:"./about.html",children:"About"})]}),a("div",{className:"lens-bloom-a"}),a("div",{className:"lens-bloom-b"}),a("div",{className:"utci-shell",children:[a("div",{className:"utci-header",children:[a("div",{children:[a("h1",{className:"utci-title",children:[a("span",{className:"title-sun",children:"SUN"}),a("span",{className:"title-scope",children:"Scope"})," ",a("sub",{className:"title-beta",children:"beta"})]}),a("div",{className:"utci-tagline",children:"See the sun the way your body does."}),a("div",{className:"utci-subtitle",children:[a("a",{href:"https://utci.org/",target:"_blank",rel:"noopener noreferrer",className:"utci-subtitle-link",children:"Universal Thermal Climate Index"})," · Bröde 2012 · Open-Meteo · SunScope soak-factor"]}),a("div",{className:"utci-current-loc",children:["↳ ",e.name,a("span",{className:"utci-loc-coords",children:[e.lat.toFixed(3),"°, ",e.lon.toFixed(3),"°"]})]})]}),a("div",{children:a(gt,{value:(I==null?void 0:I.utciAdj)??null,cat:A,loading:s})}),a("div",{className:"header-right",children:a("div",{className:"utci-search-wrap",children:[a("label",{className:"utci-search-label",children:"Change location"}),a("input",{className:"utci-search",type:"text",placeholder:"Search any town or city…",value:l,onChange:u=>c(u.target.value)}),d.length>0&&a("div",{className:"utci-results",children:d.map(u=>a("div",{className:"utci-result",onClick:()=>{t({name:`${u.name}${u.admin1?", "+u.admin1:""}`,lat:u.latitude,lon:u.longitude,country:u.country_code}),c(""),o([]),w(0)},children:[a("div",{children:[u.name,u.admin1?`, ${u.admin1}`:""]}),a("div",{className:"utci-result-meta",children:[u.country," · ",u.latitude.toFixed(2),"°, ",u.longitude.toFixed(2),"°"]})]},`${u.id}-${u.latitude}`))}),p&&a("div",{className:"utci-searching",children:"Searching…"})]})})]}),f&&a("div",{className:"utci-status",style:{borderColor:"#3a1010",color:"#c44a3a"},children:["⚠ ",f]}),s&&!f&&a("div",{className:"utci-status",children:"Acquiring forecast data…"}),n&&g.length>0&&a(j,{children:[a("div",{className:"utci-day-tabs",children:g.map((u,x)=>a("button",{className:`utci-day-tab ${x===b?"active":""}`,onClick:()=>w(x),children:[x===0?"Today":x===1?"Tomorrow":"Day after",a("span",{className:"utci-day-date",children:u.date.toLocaleDateString("en-GB",{weekday:"long",day:"numeric",month:"short"})})]},u.key))}),a("div",{className:"col-toggles",children:[a("span",{className:"col-toggles-label",children:"Columns:"}),[{key:"hour",label:"Hour"},{key:"air",label:"Air"},{key:"rh",label:"RH"},{key:"wind",label:"Wind"},{key:"cloud",label:"Cloud"},{key:"sun",label:"Sun"},{key:"direct",label:"Direct"},{key:"diffuse",label:"Diffuse"},{key:"tmrt",label:"Tmrt"},{key:"delta",label:"Δ"},{key:"utci",label:"UTCI"},{key:"precip",label:"Precip"},{key:"utciP",label:"UTCI+P"}].map(u=>a("button",{className:`col-toggle${h[u.key]?" on":""}`,onClick:()=>k(u.key),children:u.label},u.key))]}),a("div",{className:"utci-table-wrap",children:a("table",{className:"utci-table",children:[a("thead",{children:a("tr",{children:[h.hour&&a("th",{children:"Hour"}),h.air&&a("th",{children:["Air ",a("span",{className:"col-unit",children:"°C"})]}),h.rh&&a("th",{children:["RH ",a("span",{className:"col-unit",children:"%"})]}),h.wind&&a("th",{children:["Wind ",a("span",{className:"col-unit",children:"m/s"})]}),h.cloud&&a("th",{children:["Cloud ",a("span",{className:"col-unit",children:"%"})]}),h.sun&&a("th",{children:["Sun ",a("span",{className:"col-unit",children:"elev°"})]}),h.direct&&a("th",{children:["Direct ",a("span",{className:"col-unit",children:"W/m²"})]}),h.diffuse&&a("th",{children:["Diffuse ",a("span",{className:"col-unit",children:"W/m²"})]}),h.tmrt&&a("th",{children:["Tmrt ",a("span",{className:"col-unit",children:"°C"})]}),h.delta&&a("th",{children:["Δ ",a("span",{className:"col-unit",children:"UTCIAir"})]}),h.utci&&a("th",{children:["UTCI ",a("span",{className:"col-unit",children:"°C felt"})]}),h.precip&&a("th",{children:["Precip ",a("span",{className:"col-unit",children:"mm/h"})]}),h.utciP&&a("th",{children:["UTCI+P ",a("span",{className:"col-unit",children:"°C adj."})]})]})}),a("tbody",{children:M.map(u=>{const x=oe(u.utci),S=u.elev<0,H=T.toDateString()===u.dt.toDateString()&&T.getHours()===u.dt.getHours(),R=u.utci-u.Ta;return a("tr",{className:[S?"is-night":"",H?"is-now":""].join(" "),children:[h.hour&&a("td",{className:"utci-time",children:[H&&a("span",{className:"now-pip"}),u.dt.toLocaleTimeString("en-GB",{hour:"2-digit",minute:"2-digit"})]}),h.air&&a("td",{children:u.Ta.toFixed(1)}),h.rh&&a("td",{children:Math.round(u.RH)}),h.wind&&a("td",{children:u.va.toFixed(1)}),h.cloud&&a("td",{children:Math.round(u.cc)}),h.sun&&a("td",{children:u.elev>0?u.elev.toFixed(1):"—"}),h.direct&&a("td",{children:Math.round(u.dir)}),h.diffuse&&a("td",{children:Math.round(u.dif)}),h.tmrt&&a("td",{children:u.Tmrt.toFixed(1)}),h.delta&&a("td",{style:{color:R>3?"#c8601a":R<-3?"#3f73c4":"#9a7d5a",fontWeight:600},children:[R>0?"+":"",R.toFixed(1)]}),h.utci&&a("td",{children:a("span",{className:"utci-cell",style:{background:x.bg,color:x.fg},children:u.utci.toFixed(1)})}),h.precip&&a("td",{style:{color:u.snow>0?"#6090c8":u.precip>0?"#5090b0":"#c0a880"},children:u.snow>0?"❅ "+u.snow.toFixed(1)+"cm":u.precip>0?u.precip.toFixed(1):"—"}),h.utciP&&(()=>{const B=oe(u.utciAdj);return a("td",{style:{background:"rgba(180,215,250,0.10)"},children:a("span",{className:"utci-cell",style:{background:B.bg,color:B.fg},children:u.utciAdj.toFixed(1)})})})()]},u.iso)})})]})}),a("div",{className:"utci-legend",children:[a("span",{className:"utci-legend-label",children:"Thermal stress bands"}),a("div",{className:"utci-legend-row",children:[{l:"-27 to -13 Arctic",bg:"#3f73c4",fg:"#fff"},{l:"-13 to 0 Freezing",bg:"#7eb0e0",fg:"#111"},{l:"0 to 9 Cold",bg:"#bcd9ec",fg:"#111"},{l:"9 to 18 Chilled",bg:"#c8dcc0",fg:"#111"},{l:"18 to 26 Comfortable",bg:"#6ab05a",fg:"#fff"},{l:"26 to 32 Mod heat",bg:"#e8c547",fg:"#111"},{l:"32 to 38 Strong heat",bg:"#dc8a3a",fg:"#111"},{l:"38 to 46 V. strong",bg:"#c44a3a",fg:"#fff"},{l:"> 46 Extreme heat",bg:"#7a1a1a",fg:"#fff"}].map((u,x)=>a("span",{className:"utci-legend-item",style:{background:u.bg,color:u.fg},children:u.l},x))})]})]}),a("div",{className:"utci-about",children:[a("h2",{className:"utci-about-heading",children:"What is SunScope?"}),a("p",{className:"utci-about-text",children:["SunScope shows how the weather will actually ",a("em",{children:"feel"})," on your body — not just the air temperature. It uses the ",a("strong",{children:"Universal Thermal Climate Index (UTCI)"}),", a peer-reviewed biometeorological standard developed by Bröde et al. (2012) that combines air temperature, humidity, wind speed, and solar radiation into a single ",a("em",{children:"felt temperature"}),". On a calm, sunny winter day UTCI can read several degrees warmer than the thermometer; on a grey, blustery day it can read far colder. Forecast data is sourced in real time from ",a("strong",{children:"Open-Meteo"}),", a free and open-source weather API, and solar radiation is used to calculate Mean Radiant Temperature — the heat your skin absorbs from the sun — making SunScope one of the most complete outdoor comfort forecasts available for free."]}),a("p",{className:"utci-about-text",children:["The ",a("strong",{children:"UTCI+P"})," column adds the ",a("strong",{children:"SunScope soak-factor"}),": an original precipitation penalty that accounts for the extra chill of rain and snow on exposed skin and wet clothing. Light drizzle reduces the felt temperature by around 12 °C; heavy rain combined with wind can push it down by 78 °C. Snow carries an additional penalty on top. The result is a honest, real-world comfort score for any location worldwide — simply search for your town or city and compare the three-day hourly forecast."]})]}),a("div",{className:"utci-footer",children:[a("em",{children:"Reading the table."})," A large positive Δ means your body is absorbing far more heat than the air temperature alone suggests — typically due to direct solar radiation. On clear sunny days this gap can exceed 10°C even at modest air temperatures."]})]})]})}ct(a(vt,{}),document.getElementById("root"));