From c3627e4954d8a8662c011a26afa772316269846e Mon Sep 17 00:00:00 2001 From: Valexr Date: Sun, 14 Apr 2024 15:21:08 +0000 Subject: [PATCH] =?UTF-8?q?Deploying=20to=20gh-pages=20from=20@=20Valexr/c?= =?UTF-8?q?ounty@f99730bb68b90c4e34ccf219f26b070affbc94e3=20=F0=9F=9A=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- build/app.css | 2 +- build/app.js | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/build/app.css b/build/app.css index 9254bf7..319c77e 100644 --- a/build/app.css +++ b/build/app.css @@ -1 +1 @@ -:root{--dark: #1c1b22;--light: #f2f2f2;--back: #e9e9ed;--hover: #d0d0d7;--active: #b1b1b9}@media (prefers-color-scheme: dark){:root{color-scheme:dark;--light: #1c1b22;--dark: #f2f2f2;--back: #2b2a33;--hover: #52525e;--active: #5b5b66}}body,html{height:100%}body{margin:0;display:grid;grid-template-rows:auto 1fr auto;grid-template-columns:1fr;font-family:system-ui;text-align:center;background-color:var(--light)}body:after{content:"";background:#00000045;position:absolute;z-index:-1;inset:0}header{display:flex;align-items:center;justify-content:space-between;padding:1rem}header>*{margin:0}button{text-align:inherit;color:inherit;background-color:var(--back);padding:.45rem 1rem;margin:0;border:0;border-radius:.25rem;font-size:inherit;user-select:none;-webkit-user-select:none;cursor:pointer}button:hover{background-color:var(--hover)}button:hover:active{background-color:var(--active)}a{color:inherit}*{box-sizing:border-box}header.svelte-hel6gh.svelte-hel6gh{justify-content:center}main.svelte-hel6gh.svelte-hel6gh{padding:1em;display:grid;place-content:center}form.svelte-hel6gh.svelte-hel6gh{align-items:center;justify-content:center}input.svelte-hel6gh.svelte-hel6gh{font-size:1.5em;font-weight:700;font-family:inherit;background:transparent;border:0;color:inherit}ul.svelte-hel6gh.svelte-hel6gh{list-style:none;padding:0;margin:0 0 .25em;font-size:min(30vw,25vh);font-weight:700;display:flex;justify-content:center;gap:.15em}ul.svelte-hel6gh li.svelte-hel6gh{position:relative}ul.svelte-hel6gh li.svelte-hel6gh:after{content:attr(id);font-size:15%;font-weight:400;position:absolute;inset:90% 0 0}blockquote.svelte-hel6gh p.svelte-hel6gh{font-style:italic} +:root{--dark: #1c1b22;--light: #f2f2f2;--back: #e9e9ed;--hover: #d0d0d7;--active: #b1b1b9}@media (prefers-color-scheme: dark){:root{color-scheme:dark;--light: #1c1b22;--dark: #f2f2f2;--back: #2b2a33;--hover: #52525e;--active: #5b5b66}}body,html{height:100%}body{margin:0;display:grid;grid-template-rows:auto 1fr auto;grid-template-columns:1fr;font-family:system-ui;text-align:center;background-color:var(--light)}body:after{content:"";background:#00000045;position:absolute;z-index:-1;inset:0}header{display:flex;align-items:center;justify-content:space-between;padding:1rem}header>*{margin:0}button{text-align:inherit;color:inherit;background-color:var(--back);padding:.45rem 1rem;margin:0;border:0;border-radius:.25rem;font-size:inherit;user-select:none;-webkit-user-select:none;cursor:pointer}button:hover{background-color:var(--hover)}button:hover:active{background-color:var(--active)}a{color:inherit}*{box-sizing:border-box}header.svelte-1p6an5p.svelte-1p6an5p{justify-content:center}main.svelte-1p6an5p.svelte-1p6an5p{padding:1em;display:grid;place-content:center}form.svelte-1p6an5p.svelte-1p6an5p{align-items:center;justify-content:center}input.svelte-1p6an5p.svelte-1p6an5p{font-size:1.5em;font-weight:700;font-family:inherit;background:transparent;border:0;color:inherit}ul.svelte-1p6an5p.svelte-1p6an5p{list-style:none;padding:0;margin:0 0 .25em;font-size:min(27.5vw,25vh);font-weight:700;display:flex;justify-content:center;gap:.25em}ul.svelte-1p6an5p li.svelte-1p6an5p{position:relative}ul.svelte-1p6an5p li.svelte-1p6an5p:after{content:attr(id);font-size:15%;font-weight:400;position:absolute;inset:90% 0 0}blockquote.svelte-1p6an5p p.svelte-1p6an5p{font-style:italic} diff --git a/build/app.js b/build/app.js index 417229d..8e2a909 100644 --- a/build/app.js +++ b/build/app.js @@ -1,4 +1,4 @@ -var xt="county";var gt={type:"git",url:"https://github.com/Valexr/county.git"};function f(){}function yt(t){return!!t&&(typeof t=="object"||typeof t=="function")&&typeof t.then=="function"}function rt(t){return t()}function z(){return Object.create(null)}function g(t){t.forEach(rt)}function N(t){return typeof t=="function"}function bt(t,e){return t!=t?e==e:t!==e||t&&typeof t=="object"||typeof t=="function"}function $t(t,e){return t!=t?e==e:t!==e}function Ft(t){return Object.keys(t).length===0}function ot(t,...e){if(t==null){for(let r of e)r(void 0);return f}let n=t.subscribe(...e);return n.unsubscribe?()=>n.unsubscribe():n}function W(t,e,n){t.$$.on_destroy.push(ot(e,n))}function wt(t,e,n){return t.set(n),e}var R=typeof window<"u"?window:typeof globalThis<"u"?globalThis:global;var G=class t{_listeners="WeakMap"in R?new WeakMap:void 0;_observer=void 0;options;constructor(e){this.options=e}observe(e,n){return this._listeners.set(e,n),this._getObserver().observe(e,this.options),()=>{this._listeners.delete(e),this._observer.unobserve(e)}}_getObserver(){return this._observer??(this._observer=new ResizeObserver(e=>{for(let n of e)t.entries.set(n.target,n),this._listeners.get(n.target)?.(n)}))}};G.entries="WeakMap"in R?new WeakMap:void 0;var vt=!1;function Qt(){vt=!0}function Et(){vt=!1}function d(t,e){t.appendChild(e)}function w(t,e,n){t.insertBefore(e,n||null)}function y(t){t.parentNode&&t.parentNode.removeChild(t)}function m(t){return document.createElement(t)}function U(t){return document.createTextNode(t)}function k(){return U(" ")}function kt(){return U("")}function Z(t,e,n,r){return t.addEventListener(e,n,r),()=>t.removeEventListener(e,n,r)}function St(t){return function(e){return e.preventDefault(),t.call(this,e)}}function h(t,e,n){n==null?t.removeAttribute(e):t.getAttribute(e)!==n&&t.setAttribute(e,n)}function Bt(t){return Array.from(t.childNodes)}function j(t,e){e=""+e,t.data!==e&&(t.data=e)}function it(t,e){t.value=e??""}function Ut(t){let e={};return t.childNodes.forEach(n=>{e[n.slot||"default"]=!0}),e}var S;function b(t){S=t}function Lt(){if(!S)throw new Error("Function called outside component initialization");return S}function Nt(t,e){let n=t.$$.callbacks[e.type];n&&n.slice().forEach(r=>r.call(this,e))}var D=[];var Tt=[],C=[],Ct=[],oe=Promise.resolve(),ct=!1;function Mt(){ct||(ct=!0,oe.then(I))}function A(t){C.push(t)}var st=new Set,T=0;function I(){if(T!==0)return;let t=S;do{try{for(;Tt.indexOf(r)===-1?e.push(r):n.push(r)),n.forEach(r=>r()),C=e}var H=new Set,L;function Rt(){L={r:0,c:[],p:L}}function jt(){L.r||g(L.c),L=L.p}function P(t,e){t&&t.i&&(H.delete(t),t.i(e))}function lt(t,e,n,r){if(t&&t.o){if(H.has(t))return;H.add(t),L.c.push(()=>{H.delete(t),r&&(n&&t.d(1),r())}),t.o(e)}else r&&r()}function ut(t,e){let n=e.token={};function r(o,i,u,l){if(e.token!==n)return;e.resolved=l;let c=e.ctx;u!==void 0&&(c=c.slice(),c[u]=l);let s=o&&(e.current=o)(c),a=!1;e.block&&(e.blocks?e.blocks.forEach((p,_)=>{_!==i&&p&&(Rt(),lt(p,1,1,()=>{e.blocks[_]===p&&(e.blocks[_]=null)}),jt())}):e.block.d(1),s.c(),P(s,1),s.m(e.mount(),e.anchor),a=!0),e.block=s,e.blocks&&(e.blocks[i]=s),a&&I()}if(yt(t)){let o=Lt();if(t.then(i=>{b(o),r(e.then,1,e.value,i),b(null)},i=>{if(b(o),r(e.catch,2,e.error,i),b(null),!e.hasCatch)throw i}),e.current!==e.pending)return r(e.pending,0),!0}else{if(e.current!==e.then)return r(e.then,1,e.value,t),!0;e.resolved=t}}function at(t,e,n){let r=e.slice(),{resolved:o}=t;t.current===t.then&&(r[t.value]=o),t.current===t.catch&&(r[t.error]=o),t.block.p(r,n)}var se=["allowfullscreen","allowpaymentrequest","async","autofocus","autoplay","checked","controls","default","defer","disabled","formnovalidate","hidden","inert","ismap","loop","multiple","muted","nomodule","novalidate","open","playsinline","readonly","required","reversed","selected"],ce=new Set([...se]);function ae(t,e,n){let{fragment:r,after_update:o}=t.$$;r&&r.m(e,n),A(()=>{let i=t.$$.on_mount.map(rt).filter(N);t.$$.on_destroy?t.$$.on_destroy.push(...i):g(i),t.$$.on_mount=[]}),o.forEach(A)}function fe(t,e){let n=t.$$;n.fragment!==null&&(Ot(n.after_update),g(n.on_destroy),n.fragment&&n.fragment.d(e),n.on_destroy=n.fragment=null,n.ctx=[])}function pe(t,e){t.$$.dirty[0]===-1&&(D.push(t),Mt(),t.$$.dirty.fill(0)),t.$$.dirty[e/31|0]|=1<{let x=$.length?$[0]:_;return s.ctx&&o(s.ctx[p],s.ctx[p]=x)&&(!s.skip_bound&&s.bound[p]&&s.bound[p](x),a&&pe(t,p)),_}):[],s.update(),a=!0,g(s.before_update),s.fragment=r?r(s.ctx):!1,e.target){if(e.hydrate){Qt();let p=Bt(e.target);s.fragment&&s.fragment.l(p),p.forEach(y)}else s.fragment&&s.fragment.c();e.intro&&P(t.$$.fragment),ae(t,e.target,e.anchor),Et(),I()}b(c)}var de;typeof HTMLElement=="function"&&(de=class extends HTMLElement{$$ctor;$$s;$$c;$$cn=!1;$$d={};$$r=!1;$$p_d={};$$l={};$$l_u=new Map;constructor(t,e,n){super(),this.$$ctor=t,this.$$s=e,n&&this.attachShadow({mode:"open"})}addEventListener(t,e,n){if(this.$$l[t]=this.$$l[t]||[],this.$$l[t].push(e),this.$$c){let r=this.$$c.$on(t,e);this.$$l_u.set(e,r)}super.addEventListener(t,e,n)}removeEventListener(t,e,n){if(super.removeEventListener(t,e,n),this.$$c){let r=this.$$l_u.get(e);r&&(r(),this.$$l_u.delete(e))}}async connectedCallback(){if(this.$$cn=!0,!this.$$c){let t=function(o){return()=>{let i;return{c:function(){i=m("slot"),o!=="default"&&h(i,"name",o)},m:function(c,s){w(c,i,s)},d:function(c){c&&y(i)}}}};if(await Promise.resolve(),!this.$$cn||this.$$c)return;let e={},n=Ut(this);for(let o of this.$$s)o in n&&(e[o]=[t(o)]);for(let o of this.attributes){let i=this.$$g_p(o.name);i in this.$$d||(this.$$d[i]=ft(i,o.value,this.$$p_d,"toProp"))}for(let o in this.$$p_d)!(o in this.$$d)&&this[o]!==void 0&&(this.$$d[o]=this[o],delete this[o]);this.$$c=new this.$$ctor({target:this.shadowRoot||this,props:{...this.$$d,$$slots:e,$$scope:{ctx:[]}}});let r=()=>{this.$$r=!0;for(let o in this.$$p_d)if(this.$$d[o]=this.$$c.$$.ctx[this.$$c.$$.props[o]],this.$$p_d[o].reflect){let i=ft(o,this.$$d[o],this.$$p_d,"toAttribute");i==null?this.removeAttribute(this.$$p_d[o].attribute||o):this.setAttribute(this.$$p_d[o].attribute||o,i)}this.$$r=!1};this.$$c.$$.after_update.push(r),r();for(let o in this.$$l)for(let i of this.$$l[o]){let u=this.$$c.$on(o,i);this.$$l_u.set(i,u)}this.$$l={}}}attributeChangedCallback(t,e,n){this.$$r||(t=this.$$g_p(t),this.$$d[t]=ft(t,n,this.$$p_d,"toProp"),this.$$c?.$set({[t]:this.$$d[t]}))}disconnectedCallback(){this.$$cn=!1,Promise.resolve().then(()=>{this.$$cn||(this.$$c.$destroy(),this.$$c=void 0)})}$$g_p(t){return Object.keys(this.$$p_d).find(e=>this.$$p_d[e].attribute===t||!this.$$p_d[e].attribute&&e.toLowerCase()===t)||t}});function ft(t,e,n,r){let o=n[t]?.type;if(e=o==="Boolean"&&typeof e!="boolean"?e!=null:e,!r||!n[t])return e;if(r==="toAttribute")switch(o){case"Object":case"Array":return e==null?null:JSON.stringify(e);case"Boolean":return e?"":null;case"Number":return e??null;default:return e}else switch(o){case"Object":case"Array":return e&&JSON.parse(e);case"Boolean":return e;case"Number":return e!=null?+e:e;default:return e}}var q=class{$$=void 0;$$set=void 0;$destroy(){fe(this,1),this.$destroy=f}$on(e,n){if(!N(n))return f;let r=this.$$.callbacks[e]||(this.$$.callbacks[e]=[]);return r.push(n),()=>{let o=r.indexOf(n);o!==-1&&r.splice(o,1)}}$set(e){this.$$set&&!Ft(e)&&(this.$$.skip_bound=!0,this.$$set(e),this.$$.skip_bound=!1)}};var It="4";typeof window<"u"&&(window.__svelte||(window.__svelte={v:new Set})).v.add(It);async function Pt(t=5,{width:e=window.innerWidth,height:n=window.innerHeight}){try{return await he(t,{width:e,height:n})}catch(r){console.error(`Could not fetch photos: ${r}`)}}async function he(t=9,e={width:window.innerWidth,height:window.innerHeight}){let n="https://valexr.github.io/county/assets/photos.json",r=Array.from({length:t},()=>Math.floor(Math.random()*24644));return(await(await fetch(n)).json()).reduce((c,[s,a,p],_)=>{if(r.includes(_)){let $={width:e.height*(a/10),height:e.height},x={width:e.width,height:e.height},E=`?w=${u(l($,x).width)}`;c.push({id:_,src:`https://images.unsplash.com/photo-${s}${E}`,alt:`Image by ${p} from Unsplash`,...l($,x)})}return c},[]);function u(c){return c*devicePixelRatio}function l(c,s){let a=Math.min(s.width/c.width,s.height,c.height);return{width:Math.round(c.width*a),height:Math.round(c.height*a)}}}var M=[];function X(t,e){return{subscribe:pt(t,e).subscribe}}function pt(t,e=f){let n,r=new Set;function o(l){if(bt(t,l)&&(t=l,n)){let c=!M.length;for(let s of r)s[1](),M.push(s,t);if(c){for(let s=0;s{r.delete(s),r.size===0&&n&&(n(),n=null)}}return{set:o,update:i,subscribe:u}}function qt(t,e,n){let r=!Array.isArray(t),o=r?[t]:t;if(!o.every(Boolean))throw new Error("derived() expects stores as input, got a falsy value");let i=e.length<2;return X(n,(u,l)=>{let c=!1,s=[],a=0,p=f,_=()=>{if(a)return;p();let x=e(r?s[0]:s,u,l);i?u(x):p=N(x)?x:f},$=o.map((x,E)=>ot(x,B=>{s[E]=B,a&=~(1<{a|=1<e,set:c=>l(c),update:c=>l(c(e)),remove:()=>i?.removeItem(t),clear:()=>i?.clear(),subscribe:r}}var V=Vt("startDate","",!0),Jt=qt(V,(t,e)=>{let n=new Date,r=new Date(t),o=n.getTime()-r.getTime(),i=n.getMonth()-r.getMonth(),u=n.getDate()-r.getDate(),l=new Date(n.getFullYear(),n.getMonth()+1,0).getDate(),c=new Date(o).getFullYear()-1970,s=(c*12+i)%12,a=(s*l+u)%l;e({years:c,months:s,days:a})},{years:0,months:0,days:0}),zt=X(new Date().toLocaleTimeString("ru"),t=>{let e=setInterval(()=>{let n=new Date().toLocaleTimeString("ru");t(n)},1e3);return()=>clearInterval(e)}),dr=X(new Date().toLocaleDateString("ru"));var{document:Wt}=R;function Gt(t){t[7]=t[9].quote,t[8]=t[9].author}function _e(t){return{c:f,m:f,p:f,d:f}}function me(t){let e,n,r,o,i,u,l,c,s=t[2].years+"",a,p,_,$=t[2].months+"",x,E,B,J=t[2].days+"",Y,ht,K,tt,et,O,Ht,nt,_t,v={ctx:t,current:null,token:null,hasCatch:!1,pending:ye,then:ge,catch:xe,value:9};return ut(Ht=we(),v),{c(){e=m("header"),n=m("form"),r=m("label"),o=m("input"),i=k(),u=m("main"),l=m("ul"),c=m("li"),a=U(s),p=k(),_=m("li"),x=U($),E=k(),B=m("li"),Y=U(J),ht=k(),K=m("h2"),tt=U(t[3]),et=k(),O=m("footer"),v.block.c(),h(o,"type","date"),h(o,"placeholder","Set start date"),h(o,"class","svelte-hel6gh"),h(n,"action","POST"),h(n,"class","svelte-hel6gh"),h(e,"class","svelte-hel6gh"),h(c,"id","years"),h(c,"class","svelte-hel6gh"),h(_,"id","months"),h(_,"class","svelte-hel6gh"),h(B,"id","days"),h(B,"class","svelte-hel6gh"),h(l,"class","svelte-hel6gh"),h(u,"class","svelte-hel6gh")},m(Q,F){w(Q,e,F),d(e,n),d(n,r),d(r,o),it(o,t[1]),w(Q,i,F),w(Q,u,F),d(u,l),d(l,c),d(c,a),d(l,p),d(l,_),d(_,x),d(l,E),d(l,B),d(B,Y),d(u,ht),d(u,K),d(K,tt),w(Q,et,F),w(Q,O,F),v.block.m(O,v.anchor=null),v.mount=()=>O,v.anchor=null,nt||(_t=[Z(o,"input",t[6]),Z(n,"submit",St(t[5]))],nt=!0)},p(Q,F){t=Q,F&2&&it(o,t[1]),F&4&&s!==(s=t[2].years+"")&&j(a,s),F&4&&$!==($=t[2].months+"")&&j(x,$),F&4&&J!==(J=t[2].days+"")&&j(Y,J),F&8&&j(tt,t[3]),at(v,t,F)},d(Q){Q&&(y(e),y(i),y(u),y(et),y(O)),v.block.d(),v.token=null,v=null,nt=!1,g(_t)}}}function xe(t){return{c:f,m:f,p:f,d:f}}function ge(t){Gt(t);let e,n,r,o;return{c(){e=m("blockquote"),n=m("p"),n.textContent=`${t[7]}`,r=k(),o=m("footer"),o.textContent=`~ ${t[8]}`,h(n,"class","svelte-hel6gh"),h(e,"class","svelte-hel6gh")},m(i,u){w(i,e,u),d(e,n),d(e,r),d(e,o)},p(i,u){Gt(i)},d(i){i&&y(e)}}}function ye(t){return{c:f,m:f,p:f,d:f}}function be(t){return{c:f,m:f,p:f,d:f}}function $e(t){let e,n,r,o;Wt.title=e=t[0];let i={ctx:t,current:null,token:null,hasCatch:!1,pending:be,then:me,catch:_e};return ut(o=Fe(),i),{c(){n=k(),r=kt(),i.block.c()},m(u,l){w(u,n,l),w(u,r,l),i.block.m(u,i.anchor=l),i.mount=()=>r.parentNode,i.anchor=r},p(u,[l]){t=u,l&1&&e!==(e=t[0])&&(Wt.title=e),at(i,t,l)},i:f,o:f,d(u){u&&(y(n),y(r)),i.block.d(u),i.token=null,i=null}}}async function Fe(){let t=await Pt(1,{});t&&(document.body.style.cssText=` +var xt="county";var bt={type:"git",url:"https://github.com/Valexr/county.git"};function f(){}function yt(t){return!!t&&(typeof t=="object"||typeof t=="function")&&typeof t.then=="function"}function rt(t){return t()}function J(){return Object.create(null)}function b(t){t.forEach(rt)}function N(t){return typeof t=="function"}function gt(t,e){return t!=t?e==e:t!==e||t&&typeof t=="object"||typeof t=="function"}function $t(t,e){return t!=t?e==e:t!==e}function Ft(t){return Object.keys(t).length===0}function ot(t,...e){if(t==null){for(let r of e)r(void 0);return f}let n=t.subscribe(...e);return n.unsubscribe?()=>n.unsubscribe():n}function G(t,e,n){t.$$.on_destroy.push(ot(e,n))}function wt(t,e,n){return t.set(n),e}var O=typeof window<"u"?window:typeof globalThis<"u"?globalThis:global;var W=class t{_listeners="WeakMap"in O?new WeakMap:void 0;_observer=void 0;options;constructor(e){this.options=e}observe(e,n){return this._listeners.set(e,n),this._getObserver().observe(e,this.options),()=>{this._listeners.delete(e),this._observer.unobserve(e)}}_getObserver(){return this._observer??(this._observer=new ResizeObserver(e=>{for(let n of e)t.entries.set(n.target,n),this._listeners.get(n.target)?.(n)}))}};W.entries="WeakMap"in O?new WeakMap:void 0;var vt=!1;function Qt(){vt=!0}function Et(){vt=!1}function d(t,e){t.appendChild(e)}function w(t,e,n){t.insertBefore(e,n||null)}function y(t){t.parentNode&&t.parentNode.removeChild(t)}function m(t){return document.createElement(t)}function U(t){return document.createTextNode(t)}function k(){return U(" ")}function kt(){return U("")}function H(t,e,n,r){return t.addEventListener(e,n,r),()=>t.removeEventListener(e,n,r)}function St(t){return function(e){return e.preventDefault(),t.call(this,e)}}function h(t,e,n){n==null?t.removeAttribute(e):t.getAttribute(e)!==n&&t.setAttribute(e,n)}function Bt(t){return Array.from(t.childNodes)}function R(t,e){e=""+e,t.data!==e&&(t.data=e)}function it(t,e){t.value=e??""}function Ut(t){let e={};return t.childNodes.forEach(n=>{e[n.slot||"default"]=!0}),e}var S;function g(t){S=t}function Dt(){if(!S)throw new Error("Function called outside component initialization");return S}function Nt(t,e){let n=t.$$.callbacks[e.type];n&&n.slice().forEach(r=>r.call(this,e))}var L=[];var Ct=[],T=[],Tt=[],oe=Promise.resolve(),ct=!1;function Mt(){ct||(ct=!0,oe.then(A))}function j(t){T.push(t)}var st=new Set,C=0;function A(){if(C!==0)return;let t=S;do{try{for(;Ct.indexOf(r)===-1?e.push(r):n.push(r)),n.forEach(r=>r()),T=e}var X=new Set,D;function Rt(){D={r:0,c:[],p:D}}function jt(){D.r||b(D.c),D=D.p}function I(t,e){t&&t.i&&(X.delete(t),t.i(e))}function lt(t,e,n,r){if(t&&t.o){if(X.has(t))return;X.add(t),D.c.push(()=>{X.delete(t),r&&(n&&t.d(1),r())}),t.o(e)}else r&&r()}function ut(t,e){let n=e.token={};function r(o,i,u,l){if(e.token!==n)return;e.resolved=l;let c=e.ctx;u!==void 0&&(c=c.slice(),c[u]=l);let s=o&&(e.current=o)(c),a=!1;e.block&&(e.blocks?e.blocks.forEach((p,_)=>{_!==i&&p&&(Rt(),lt(p,1,1,()=>{e.blocks[_]===p&&(e.blocks[_]=null)}),jt())}):e.block.d(1),s.c(),I(s,1),s.m(e.mount(),e.anchor),a=!0),e.block=s,e.blocks&&(e.blocks[i]=s),a&&A()}if(yt(t)){let o=Dt();if(t.then(i=>{g(o),r(e.then,1,e.value,i),g(null)},i=>{if(g(o),r(e.catch,2,e.error,i),g(null),!e.hasCatch)throw i}),e.current!==e.pending)return r(e.pending,0),!0}else{if(e.current!==e.then)return r(e.then,1,e.value,t),!0;e.resolved=t}}function at(t,e,n){let r=e.slice(),{resolved:o}=t;t.current===t.then&&(r[t.value]=o),t.current===t.catch&&(r[t.error]=o),t.block.p(r,n)}var se=["allowfullscreen","allowpaymentrequest","async","autofocus","autoplay","checked","controls","default","defer","disabled","formnovalidate","hidden","inert","ismap","loop","multiple","muted","nomodule","novalidate","open","playsinline","readonly","required","reversed","selected"],ce=new Set([...se]);function ae(t,e,n){let{fragment:r,after_update:o}=t.$$;r&&r.m(e,n),j(()=>{let i=t.$$.on_mount.map(rt).filter(N);t.$$.on_destroy?t.$$.on_destroy.push(...i):b(i),t.$$.on_mount=[]}),o.forEach(j)}function fe(t,e){let n=t.$$;n.fragment!==null&&(Ot(n.after_update),b(n.on_destroy),n.fragment&&n.fragment.d(e),n.on_destroy=n.fragment=null,n.ctx=[])}function pe(t,e){t.$$.dirty[0]===-1&&(L.push(t),Mt(),t.$$.dirty.fill(0)),t.$$.dirty[e/31|0]|=1<{let x=$.length?$[0]:_;return s.ctx&&o(s.ctx[p],s.ctx[p]=x)&&(!s.skip_bound&&s.bound[p]&&s.bound[p](x),a&&pe(t,p)),_}):[],s.update(),a=!0,b(s.before_update),s.fragment=r?r(s.ctx):!1,e.target){if(e.hydrate){Qt();let p=Bt(e.target);s.fragment&&s.fragment.l(p),p.forEach(y)}else s.fragment&&s.fragment.c();e.intro&&I(t.$$.fragment),ae(t,e.target,e.anchor),Et(),A()}g(c)}var de;typeof HTMLElement=="function"&&(de=class extends HTMLElement{$$ctor;$$s;$$c;$$cn=!1;$$d={};$$r=!1;$$p_d={};$$l={};$$l_u=new Map;constructor(t,e,n){super(),this.$$ctor=t,this.$$s=e,n&&this.attachShadow({mode:"open"})}addEventListener(t,e,n){if(this.$$l[t]=this.$$l[t]||[],this.$$l[t].push(e),this.$$c){let r=this.$$c.$on(t,e);this.$$l_u.set(e,r)}super.addEventListener(t,e,n)}removeEventListener(t,e,n){if(super.removeEventListener(t,e,n),this.$$c){let r=this.$$l_u.get(e);r&&(r(),this.$$l_u.delete(e))}}async connectedCallback(){if(this.$$cn=!0,!this.$$c){let t=function(o){return()=>{let i;return{c:function(){i=m("slot"),o!=="default"&&h(i,"name",o)},m:function(c,s){w(c,i,s)},d:function(c){c&&y(i)}}}};if(await Promise.resolve(),!this.$$cn||this.$$c)return;let e={},n=Ut(this);for(let o of this.$$s)o in n&&(e[o]=[t(o)]);for(let o of this.attributes){let i=this.$$g_p(o.name);i in this.$$d||(this.$$d[i]=ft(i,o.value,this.$$p_d,"toProp"))}for(let o in this.$$p_d)!(o in this.$$d)&&this[o]!==void 0&&(this.$$d[o]=this[o],delete this[o]);this.$$c=new this.$$ctor({target:this.shadowRoot||this,props:{...this.$$d,$$slots:e,$$scope:{ctx:[]}}});let r=()=>{this.$$r=!0;for(let o in this.$$p_d)if(this.$$d[o]=this.$$c.$$.ctx[this.$$c.$$.props[o]],this.$$p_d[o].reflect){let i=ft(o,this.$$d[o],this.$$p_d,"toAttribute");i==null?this.removeAttribute(this.$$p_d[o].attribute||o):this.setAttribute(this.$$p_d[o].attribute||o,i)}this.$$r=!1};this.$$c.$$.after_update.push(r),r();for(let o in this.$$l)for(let i of this.$$l[o]){let u=this.$$c.$on(o,i);this.$$l_u.set(i,u)}this.$$l={}}}attributeChangedCallback(t,e,n){this.$$r||(t=this.$$g_p(t),this.$$d[t]=ft(t,n,this.$$p_d,"toProp"),this.$$c?.$set({[t]:this.$$d[t]}))}disconnectedCallback(){this.$$cn=!1,Promise.resolve().then(()=>{this.$$cn||(this.$$c.$destroy(),this.$$c=void 0)})}$$g_p(t){return Object.keys(this.$$p_d).find(e=>this.$$p_d[e].attribute===t||!this.$$p_d[e].attribute&&e.toLowerCase()===t)||t}});function ft(t,e,n,r){let o=n[t]?.type;if(e=o==="Boolean"&&typeof e!="boolean"?e!=null:e,!r||!n[t])return e;if(r==="toAttribute")switch(o){case"Object":case"Array":return e==null?null:JSON.stringify(e);case"Boolean":return e?"":null;case"Number":return e??null;default:return e}else switch(o){case"Object":case"Array":return e&&JSON.parse(e);case"Boolean":return e;case"Number":return e!=null?+e:e;default:return e}}var P=class{$$=void 0;$$set=void 0;$destroy(){fe(this,1),this.$destroy=f}$on(e,n){if(!N(n))return f;let r=this.$$.callbacks[e]||(this.$$.callbacks[e]=[]);return r.push(n),()=>{let o=r.indexOf(n);o!==-1&&r.splice(o,1)}}$set(e){this.$$set&&!Ft(e)&&(this.$$.skip_bound=!0,this.$$set(e),this.$$.skip_bound=!1)}};var It="4";typeof window<"u"&&(window.__svelte||(window.__svelte={v:new Set})).v.add(It);async function Pt(t=5,{width:e=window.innerWidth,height:n=window.innerHeight}){try{return await he(t,{width:e,height:n})}catch(r){console.error(`Could not fetch photos: ${r}`)}}async function he(t=9,e={width:window.innerWidth,height:window.innerHeight}){let n="https://valexr.github.io/county/assets/photos.json",r=Array.from({length:t},()=>Math.floor(Math.random()*24644));return(await(await fetch(n)).json()).reduce((c,[s,a,p],_)=>{if(r.includes(_)){let $={width:e.height*(a/10),height:e.height},x={width:e.width,height:e.height},E=`?w=${u(l($,x).width)}`;c.push({id:_,src:`https://images.unsplash.com/photo-${s}${E}`,alt:`Image by ${p} from Unsplash`,...l($,x)})}return c},[]);function u(c){return c*devicePixelRatio}function l(c,s){let a=Math.min(s.width/c.width,s.height,c.height);return{width:Math.round(c.width*a),height:Math.round(c.height*a)}}}var M=[];function Y(t,e){return{subscribe:pt(t,e).subscribe}}function pt(t,e=f){let n,r=new Set;function o(l){if(gt(t,l)&&(t=l,n)){let c=!M.length;for(let s of r)s[1](),M.push(s,t);if(c){for(let s=0;s{r.delete(s),r.size===0&&n&&(n(),n=null)}}return{set:o,update:i,subscribe:u}}function qt(t,e,n){let r=!Array.isArray(t),o=r?[t]:t;if(!o.every(Boolean))throw new Error("derived() expects stores as input, got a falsy value");let i=e.length<2;return Y(n,(u,l)=>{let c=!1,s=[],a=0,p=f,_=()=>{if(a)return;p();let x=e(r?s[0]:s,u,l);i?u(x):p=N(x)?x:f},$=o.map((x,E)=>ot(x,B=>{s[E]=B,a&=~(1<{a|=1<e,set:c=>l(c),update:c=>l(c(e)),remove:()=>i?.removeItem(t),clear:()=>i?.clear(),subscribe:r}}var q=Vt("startDate","",!0),zt=qt(q,(t,e)=>{let n=new Date,r=new Date(t),o=n.getTime()-r.getTime(),i=n.getMonth()-r.getMonth(),u=n.getDate()-r.getDate(),l=new Date(n.getFullYear(),n.getMonth()+1,0).getDate(),c=new Date(o).getFullYear()-1970,s=(c*12+i)%12,a=(s*l+u)%l;e({years:c,months:s,days:a})},{years:0,months:0,days:0}),Jt=Y(new Date().toLocaleTimeString("ru"),t=>{let e=setInterval(()=>{let n=new Date().toLocaleTimeString("ru");t(n)},1e3);return()=>clearInterval(e)}),dr=Y(new Date().toLocaleDateString("ru"));var{document:Gt}=O;function Wt(t){t[7]=t[9].quote,t[8]=t[9].author}function _e(t){return{c:f,m:f,p:f,d:f}}function me(t){let e,n,r,o,i,u,l,c,s=t[2].years+"",a,p,_,$=t[2].months+"",x,E,B,V=t[2].days+"",Z,ht,Xt,K,z,tt,et,nt,_t,v={ctx:t,current:null,token:null,hasCatch:!1,pending:ye,then:be,catch:xe,value:9};return ut(Xt=we(),v),{c(){e=m("header"),n=m("form"),r=m("label"),o=m("input"),i=k(),u=m("main"),l=m("ul"),c=m("li"),a=U(s),p=k(),_=m("li"),x=U($),E=k(),B=m("li"),Z=U(V),ht=k(),v.block.c(),K=k(),z=m("footer"),tt=m("h2"),et=U(t[3]),h(o,"type","date"),h(o,"placeholder","Set start date"),h(o,"class","svelte-1p6an5p"),h(n,"action","POST"),h(n,"class","svelte-1p6an5p"),h(e,"class","svelte-1p6an5p"),h(c,"id","years"),h(c,"class","svelte-1p6an5p"),h(_,"id","months"),h(_,"class","svelte-1p6an5p"),h(B,"id","days"),h(B,"class","svelte-1p6an5p"),h(l,"class","svelte-1p6an5p"),h(u,"class","svelte-1p6an5p")},m(Q,F){w(Q,e,F),d(e,n),d(n,r),d(r,o),it(o,t[1]),w(Q,i,F),w(Q,u,F),d(u,l),d(l,c),d(c,a),d(l,p),d(l,_),d(_,x),d(l,E),d(l,B),d(B,Z),d(u,ht),v.block.m(u,v.anchor=null),v.mount=()=>u,v.anchor=null,w(Q,K,F),w(Q,z,F),d(z,tt),d(tt,et),nt||(_t=[H(o,"input",t[6]),H(n,"submit",St(t[5]))],nt=!0)},p(Q,F){t=Q,F&2&&it(o,t[1]),F&4&&s!==(s=t[2].years+"")&&R(a,s),F&4&&$!==($=t[2].months+"")&&R(x,$),F&4&&V!==(V=t[2].days+"")&&R(Z,V),at(v,t,F),F&8&&R(et,t[3])},d(Q){Q&&(y(e),y(i),y(u),y(K),y(z)),v.block.d(),v.token=null,v=null,nt=!1,b(_t)}}}function xe(t){return{c:f,m:f,p:f,d:f}}function be(t){Wt(t);let e,n,r,o;return{c(){e=m("blockquote"),n=m("p"),n.textContent=`${t[7]}`,r=k(),o=m("footer"),o.textContent=`~ ${t[8]}`,h(n,"class","svelte-1p6an5p"),h(e,"class","svelte-1p6an5p")},m(i,u){w(i,e,u),d(e,n),d(e,r),d(e,o)},p(i,u){Wt(i)},d(i){i&&y(e)}}}function ye(t){return{c:f,m:f,p:f,d:f}}function ge(t){return{c:f,m:f,p:f,d:f}}function $e(t){let e,n,r,o;Gt.title=e=t[0];let i={ctx:t,current:null,token:null,hasCatch:!1,pending:ge,then:me,catch:_e};return ut(o=Fe(),i),{c(){n=k(),r=kt(),i.block.c()},m(u,l){w(u,n,l),w(u,r,l),i.block.m(u,i.anchor=l),i.mount=()=>r.parentNode,i.anchor=r},p(u,[l]){t=u,l&1&&e!==(e=t[0])&&(Gt.title=e),at(i,t,l)},i:f,o:f,d(u){u&&(y(n),y(r)),i.block.d(u),i.token=null,i=null}}}async function Fe(){let t=await Pt(1,{});t&&(document.body.style.cssText=` background: url(${t[0].src}) center no-repeat; background-size: cover; - `)}async function we(){return(await fetch("https://dummyjson.com/quotes/random")).json()}function ve(t,e,n){let r,o,i;W(t,V,a=>n(1,r=a)),W(t,Jt,a=>n(2,o=a)),W(t,zt,a=>n(3,i=a));let{name:u}=e,{repository:l}=e;wt(V,r="2013-04-09",r);function c(a){Nt.call(this,t,a)}function s(){r=this.value,V.set(r)}return t.$$set=a=>{"name"in a&&n(0,u=a.name),"repository"in a&&n(4,l=a.repository)},[u,r,o,i,l,c,s]}var dt=class extends q{constructor(e){super(),At(this,e,ve,$e,$t,{name:0,repository:4})}},Zt=dt;var Qr=new Zt({target:document.body,props:{name:xt,repository:gt}});export{Qr as default}; + `)}async function we(){return(await fetch("https://dummyjson.com/quotes/random")).json()}function ve(t,e,n){let r,o,i;G(t,q,a=>n(1,r=a)),G(t,zt,a=>n(2,o=a)),G(t,Jt,a=>n(3,i=a));let{name:u}=e,{repository:l}=e;wt(q,r="2013-04-09",r);function c(a){Nt.call(this,t,a)}function s(){r=this.value,q.set(r)}return t.$$set=a=>{"name"in a&&n(0,u=a.name),"repository"in a&&n(4,l=a.repository)},[u,r,o,i,l,c,s]}var dt=class extends P{constructor(e){super(),At(this,e,ve,$e,$t,{name:0,repository:4})}},Ht=dt;var Qr=new Ht({target:document.body,props:{name:xt,repository:bt}});export{Qr as default};