upptime/client/legacy/client.6f96cb6b.js

18 lines
41 KiB
JavaScript
Raw Normal View History

function e(){}function t(e,t){for(const n in t)e[n]=t[n];return e}function n(e){return e()}function s(){return Object.create(null)}function r(e){e.forEach(n)}function o(e){return"function"==typeof e}function i(e,t){return e!=e?t==t:e!==t||e&&"object"==typeof e||"function"==typeof e}let a;function c(e,t){return a||(a=document.createElement("a")),a.href=t,e===a.href}function l(e,n,s,r){return e[1]&&r?t(s.ctx.slice(),e[1](r(n))):s.ctx}function u(e){const t={};for(const n in e)"$"!==n[0]&&(t[n]=e[n]);return t}function d(e){return null==e?"":e}let f=!1;function h(e,t,n,s){for(;e<t;){const r=e+(t-e>>1);n(r)<=s?e=r+1:t=r}return e}function m(e,t){if(f){for(!function(e){if(e.hydrate_init)return;e.hydrate_init=!0;let t=e.childNodes;if("HEAD"===e.nodeName){const e=[];for(let n=0;n<t.length;n++){const s=t[n];void 0!==s.claim_order&&e.push(s)}t=e}const n=new Int32Array(t.length+1),s=new Int32Array(t.length);n[0]=-1;let r=0;for(let e=0;e<t.length;e++){const o=t[e].claim_order,i=(r>0&&t[n[r]].claim_order<=o?r+1:h(1,r,(e=>t[n[e]].claim_order),o))-1;s[e]=n[i]+1;const a=i+1;n[a]=e,r=Math.max(a,r)}const o=[],i=[];let a=t.length-1;for(let e=n[r]+1;0!=e;e=s[e-1]){for(o.push(t[e-1]);a>=e;a--)i.push(t[a]);a--}for(;a>=0;a--)i.push(t[a]);o.reverse(),i.sort(((e,t)=>e.claim_order-t.claim_order));for(let t=0,n=0;t<i.length;t++){for(;n<o.length&&i[t].claim_order>=o[n].claim_order;)n++;const s=n<o.length?o[n]:null;e.insertBefore(i[t],s)}}(e),(void 0===e.actual_end_child||null!==e.actual_end_child&&e.actual_end_child.parentNode!==e)&&(e.actual_end_child=e.firstChild);null!==e.actual_end_child&&void 0===e.actual_end_child.claim_order;)e.actual_end_child=e.actual_end_child.nextSibling;t!==e.actual_end_child?void 0===t.claim_order&&t.parentNode===e||e.insertBefore(t,e.actual_end_child):e.actual_end_child=t.nextSibling}else t.parentNode===e&&null===t.nextSibling||e.appendChild(t)}function p(e,t,n){e.insertBefore(t,n||null)}function g(e,t,n){f&&!n?m(e,t):t.parentNode===e&&t.nextSibling==n||e.insertBefore(t,n||null)}function b(e){e.parentNode&&e.parentNode.removeChild(e)}function _(e,t){for(let n=0;n<e.length;n+=1)e[n]&&e[n].d(t)}function v(e){return document.createElement(e)}function y(e){return document.createElementNS("http://www.w3.org/2000/svg",e)}function w(e){return document.createTextNode(e)}function $(){return w(" ")}function E(){return w("")}function S(e,t,n,s){return e.addEventListener(t,n,s),()=>e.removeEventListener(t,n,s)}function A(e){return function(t){return t.preventDefault(),e.call(this,t)}}function T(e,t,n){null==n?e.removeAttribute(t):e.getAttribute(t)!==n&&e.setAttribute(t,n)}const x=["width","height"];function I(e,t){const n=Object.getOwnPropertyDescriptors(e.__proto__);for(const s in t)null==t[s]?e.removeAttribute(s):"style"===s?e.style.cssText=t[s]:"__value"===s?e.value=e[s]=t[s]:n[s]&&n[s].set&&-1===x.indexOf(s)?e[s]=t[s]:T(e,s,t[s])}function N(e){let t;return{p(){for(var n=arguments.length,s=new Array(n),r=0;r<n;r++)s[r]=arguments[r];t=s,t.forEach((t=>e.push(t)))},r(){t.forEach((t=>e.splice(e.indexOf(t),1)))}}}function L(e){return Array.from(e.childNodes)}function P(e){void 0===e.claim_info&&(e.claim_info={last_index:0,total_claimed:0})}function R(e,t,n,s){let r=arguments.length>4&&void 0!==arguments[4]&&arguments[4];P(e);const o=(()=>{for(let s=e.claim_info.last_index;s<e.length;s++){const o=e[s];if(t(o)){const t=n(o);return void 0===t?e.splice(s,1):e[s]=t,r||(e.claim_info.last_index=s),o}}for(let s=e.claim_info.last_index-1;s>=0;s--){const o=e[s];if(t(o)){const t=n(o);return void 0===t?e.splice(s,1):e[s]=t,r?void 0===t&&e.claim_info.last_index--:e.claim_info.last_index=s,o}}return s()})();return o.claim_order=e.claim_info.total_claimed,e.claim_info.total_claimed+=1,o}function O(e,t,n,s){return R(e,(e=>e.nodeName===t),(e=>{const t=[];for(let s=0;s<e.attributes.length;s++){const r=e.attributes[s];n[r.name]||t.push(r.name)}t.forEach((t=>e.removeAttribute(t)))}),(()=>s(t)))}function k(e,t,n){return O(e,t,n,v)}function C(e,t,n){return O(e,t,n,y)}function H(e,t){return R(e,(e=>3===e.nodeType),(e=>{const n=""+t;if(e.data.startsWith(n)
/*! *****************************************************************************
Copyright (c) Microsoft Corporation.
Permission to use, copy, modify, and/or distribute this software for any
purpose with or without fee is hereby granted.
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
PERFORMANCE OF THIS SOFTWARE.
***************************************************************************** */
function mt(e,t,n,s){return new(n||(n=Promise))((function(r,o){function i(e){try{c(s.next(e))}catch(e){o(e)}}function a(e){try{c(s.throw(e))}catch(e){o(e)}}function c(e){var t;e.done?r(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(i,a)}c((s=s.apply(e,t||[])).next())}))}function pt(e){for(;e&&"A"!==e.nodeName.toUpperCase();)e=e.parentNode;return e}let gt,bt=1;const _t="undefined"!=typeof history?history:{pushState:()=>{},replaceState:()=>{},scrollRestoration:"auto"},vt={};let yt,wt;const $t=e=>"undefined"!=typeof URLSearchParams?[...new URLSearchParams(e).entries()]:e.slice(1).split("&").map((e=>{const[,t,n=""]=/([^=]*)(?:=([\S\s]*))?/.exec(decodeURIComponent(e.replace(/\+/g," ")));return[t,n]}));function Et(e){const t=Object.create(null);return e.length?$t(e).reduce(((e,t)=>{let[n,s]=t;return"string"==typeof e[n]&&(e[n]=[e[n]]),"object"==typeof e[n]?e[n].push(s):e[n]=s,e}),t):t}function St(e){if(e.origin!==location.origin)return null;if(!e.pathname.startsWith(yt))return null;let t=e.pathname.slice(yt.length);if(""===t&&(t="/"),!ut.some((e=>e.test(t))))for(let n=0;n<ft.length;n+=1){const s=ft[n],r=s.pattern.exec(t);if(r){const n=Et(e.search),o=s.parts[s.parts.length-1],i=o.params?o.params(r):{},a={host:location.host,path:t,query:n,params:i};return{href:e.href,route:s,match:r,page:a}}}}function At(e){if(1!==function(e){return null===e.which?e.button:e.which}(e))return;if(e.metaKey||e.ctrlKey||e.shiftKey||e.altKey)return;if(e.defaultPrevented)return;const t=pt(e.target);if(!t)return;if(!t.href)return;const n="object"==typeof t.href&&"SVGAnimatedString"===t.href.constructor.name,s=String(n?t.href.baseVal:t.href);if(s===location.href)return void(location.hash||e.preventDefault());if(t.hasAttribute("download")||"external"===t.getAttribute("rel"))return;if(n?t.target.baseVal:t.target)return;const r=new URL(s);if(r.pathname===location.pathname&&r.search===location.search)return;const o=St(r);if(o){It(o,null,t.hasAttribute("sapper:noscroll"),r.hash),e.preventDefault(),_t.pushState({id:gt},"",r.href)}}function Tt(){return{x:pageXOffset,y:pageYOffset}}function xt(e){if(vt[gt]=Tt(),e.state){const t=St(new URL(location.href));t?It(t,e.state.id):location.href=location.href}else!function(e){bt=e}(bt+1),function(e){gt=e}(bt),_t.replaceState({id:gt},"",location.href)}function It(e,t,n,s){return mt(this,void 0,void 0,(function*(){const r=!!t;if(r)gt=t;else{const e=Tt();vt[gt]=e,gt=t=++bt,vt[gt]=n?e:{x:0,y:0}}if(yield wt(e),document.activeElement&&document.activeElement instanceof HTMLElement&&document.activeElement.blur(),!n){let e,n=vt[t];s&&(e=document.getElementById(s.slice(1)),e&&(n={x:0,y:e.getBoundingClientRect().top+scrollY})),vt[gt]=n,n&&(r||e)?scrollTo(n.x,n.y):scrollTo(0,0)}}))}function Nt(e){let t=e.baseURI;if(!t){const n=e.getElementsByTagName("base");t=n.length?n[0].href:e.URL}return t}let Lt,Pt=null;function Rt(e){const t=pt(e.target);t&&t.hasAttribute("sapper:prefetch")&&function(e){const t=St(new URL(e,Nt(document)));if(t)Pt&&e===Pt.href||(Pt={href:e,promise:Ft(t)}),Pt.promise}(t.href)}function Ot(e){clearTimeout(Lt),Lt=setTimeout((()=>{Rt(e)}),20)}function kt(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{noscroll:!1,replaceState:!1};const n=St(new URL(e,Nt(document)));if(n){const s=It(n,null,t.noscroll);return _t[t.replaceState?"replaceState":"pushState"]({id:gt},"",e),s}return location.href=e,new Promise((()=>{}))}const Ct="undefined"!=typeof __SAPPER__&&__SAPPER__;let Ht,Mt,Dt,Ut=!1,Gt=[],jt="{}";const Bt={page:function(e){const t=Ne(e);let n=!0;return{notify:function(){n=!0,t.update((e=>e))},set:function(e){n=!1,t.set(e)},subscribe:function(e){let s;return t.subscribe((t=>{(void 0===s||n&&t!==s)&&e(s=t)}))}}}({}),preloading:Ne(null),session:Ne(Ct&&Ct.session)};let qt,zt,Kt;function Wt(e){var t,n;return t=e.target,Kt=t,n=Ct.baseUrl,yt=n,wt=Vt,"scrollRestoration"in _t&&(_t.scrollRestoration="manual"),addEventListener("beforeunload",(()=>{_t.scrollRestoration="auto"})),addEventListener("load",(()=>{_t.scrollRestoration="manual"})),addEventListener("click",At),addEventListener("p
import __inject_styles from './inject_styles.099149d9.js';