|
|
|
var uPlot=function(){"use strict";function n(n,t,e,r){var i;e=e||0;for(var o=2147483647>=(r=r||t.length-1);r-e>1;)n>t[i=o?e+r>>1:v((e+r)/2)]?e=i:r=i;return n-t[e]>t[r]-n?r:e}var t=[0,0];function e(n,e,r,i){return t[0]=0>r?D(n,-r):n,t[1]=0>i?D(e,-i):e,t}function r(n,t,r,i){var o,l,a,u=10==r?w:x;return n==t&&(n/=r,t*=r),i?(o=v(u(n)),l=m(u(t)),n=(a=e(g(r,o),g(r,l),o,l))[0],t=a[1]):(o=v(u(n)),l=v(u(t)),n=z(n,(a=e(g(r,o),g(r,l),o,l))[0]),t=T(t,a[1])),[n,t]}var i={pad:0,soft:null,mode:0},o={min:i,max:i};function l(n,t,e,r){return H(e)?u(n,t,e):(i.pad=e,i.soft=r?0:null,i.mode=r?2:0,u(n,t,o))}function a(n,t){return null==n?t:n}function u(n,t,e){var r=e.min,i=e.max,o=a(r.pad,0),l=a(i.pad,0),u=a(r.hard,-b),s=a(i.hard,b),f=a(r.soft,b),h=a(i.soft,-b),m=a(r.mode,0),x=a(i.mode,0),_=t-n,y=_||c(t)||1e3,M=w(y),k=g(10,v(M)),S=D(z(n-y*(0==_?0==n?.1:1:o),k/100),6),E=n>=f&&(1==m||2==m&&f>S)?f:b,W=p(u,E>S&&n>=E?E:d(E,S)),Y=D(T(t+y*(0==_?0==t?.1:1:l),k/100),6),C=h>=t&&(1==x||2==x&&Y>h)?h:-b,A=d(s,Y>C&&C>=t?C:p(C,Y));return W==A&&0==W&&(A=100),[W,A]}var s=new Intl.NumberFormat(navigator.language).format,f=Math,c=f.abs,v=f.floor,h=f.round,m=f.ceil,d=f.min,p=f.max,g=f.pow,w=f.log10,x=f.log2,_=f.PI,b=1/0;function y(n,t){return h(n/t)*t}function M(n,t,e){return d(p(n,t),e)}function k(n){return"function"==typeof n?n:function(){return n}}function S(n,t){return t}function T(n,t){return m(n/t)*t}function z(n,t){return v(n/t)*t}function D(n,t){return h(n*(t=Math.pow(10,t)))/t}var E=new Map;function W(n){return((""+n).split(".")[1]||"").length}function Y(n,t,e,r){for(var i=[],o=r.map(W),l=t;e>l;l++)for(var a=c(l),u=D(g(n,l),a),s=0;r.length>s;s++){var f=r[s]*u,v=(0>f||0>l?a:0)+(o[s]>l?o[s]:0),h=D(f,v);i.push(h),E.set(h,v)}return i}var C={},A=Array.isArray;function F(n){return"string"==typeof n}function H(n){return"object"==typeof n&&null!==n}function P(n){var t;if(A(n))t=n.map(P);else if(H(n))for(var e in t={},n)t[e]=P(n[e]);else t=n;return t}function N(n){for(var t=arguments,e=1;t.length>e;e++){var r=t[e];for(var i in r)H(n[i])?N(n[i],P(r[i])):n[i]=P(r[i])}return n}var I="undefined"==typeof queueMicrotask?function(n){return Promise.resolve().then(n)}:queueMicrotask,V="width",L="height",O="top",j="bottom",B="left",G="right",R="#000",U="#0000",J="mousemove",q="mousedown",Z="mouseup",X="mouseenter",K="mouseleave",Q="dblclick",$="resize",nn="scroll",tn="u-off",en="u-label",rn=requestAnimationFrame,on=document,ln=window,an=devicePixelRatio;function un(n,t){null!=t&&n.classList.add(t)}function sn(n,t){n.classList.remove(t)}function fn(n,t,e){n.style[t]=e+"px"}function cn(n,t,e,r){var i=on.createElement(n);return null!=t&&un(i,t),null!=e&&e.insertBefore(i,r),i}function vn(n,t){return cn("div",n,t)}function hn(n,t,e,r,i){n.style.transform="translate("+t+"px,"+e+"px)",0>t||0>e||t>r||e>i?un(n,tn):sn(n,tn)}var mn={passive:!0};function dn(n,t,e){t.addEventListener(n,e,mn)}function pn(n,t,e){t.removeEventListener(n,e,mn)}var gn=["January","February","March","April","May","June","July","August","September","October","November","December"],wn=["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"];function xn(n){return n.slice(0,3)}var _n=wn.map(xn),bn=gn.map(xn),yn={MMMM:gn,MMM:bn,WWWW:wn,WWW:_n};function Mn(n){return(10>n?"0":"")+n}var kn={YYYY:function(n){return n.getFullYear()},YY:function(n){return(n.getFullYear()+"").slice(2)},MMMM:function(n,t){return t.MMMM[n.getMonth()]},MMM:function(n,t){return t.MMM[n.getMonth()]},MM:function(n){return Mn(n.getMonth()+1)},M:function(n){return n.getMonth()+1},DD:function(n){return Mn(n.getDate())},D:function(n){return n.getDate()},WWWW:function(n,t){return t.WWWW[n.getDay()]},WWW:function(n,t){return t.WWW[n.getDay()]},HH:function(n){return Mn(n.getHours())},H:function(n){return n.getHours()},h:function(n){var t=n.getHours();return 0==t?12:t>12?t-12:t},AA:function(n){return 12>n.getHours()?"AM":"PM"},aa:function(n){return 12>n.getHours()?"am":"pm"},a:function(n){return 12>n.getHours()?"a":"p"},mm:function(n){return Mn(n.getMinutes())},m:function(n){return n.getMinutes()},ss:function(n){return Mn(n.getSeconds
|