@ngrok/mantle 0.90.0 → 0.90.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/agent.json +1 -1
- package/dist/{alert-BzPDUaU7.d.ts → alert-CTAmHdLa.d.ts} +1 -1
- package/dist/alert-center.d.ts +1 -1
- package/dist/alert-center.js +1 -1
- package/dist/{alert-ZaUBtgno.js → alert-xJELJxL4.js} +1 -1
- package/dist/alert.d.ts +1 -1
- package/dist/alert.js +1 -1
- package/dist/app-layout.d.ts +1 -1
- package/dist/app-layout.js +1 -1
- package/dist/area-chart.js +1 -1
- package/dist/bar-chart.js +1 -1
- package/dist/{button-CHoYpOzx.d.ts → button-BRjAW1ec.d.ts} +1 -1
- package/dist/{button-DL7V4bzW.d.ts → button-BZT5f79d.d.ts} +2 -2
- package/dist/{button-BMfUxs_j.js → button-Bkl_QYpp.js} +1 -1
- package/dist/{button-D8rr-1AB.js → button-DTpsT864.js} +1 -1
- package/dist/button.d.ts +2 -2
- package/dist/button.js +1 -1
- package/dist/calendar.js +1 -1
- package/dist/chart-BfJ835dr.js +2 -0
- package/dist/{checkbox-C3N2afhB.js → checkbox-BpW9TmW6.js} +1 -1
- package/dist/checkbox.js +1 -1
- package/dist/{choice-DQmecLfy.js → choice-U6_8mOOO.js} +1 -1
- package/dist/choice.js +1 -1
- package/dist/code-block-CNR8NuNT.js +12 -0
- package/dist/code-block.d.ts +2 -2
- package/dist/code-block.js +1 -1
- package/dist/code-block_highlight-utils.js +1 -1
- package/dist/color.js +1 -1
- package/dist/combobox.d.ts +1 -1
- package/dist/combobox.js +1 -1
- package/dist/command.d.ts +5 -4
- package/dist/command.js +1 -1
- package/dist/data-table.d.ts +1 -1
- package/dist/data-table.js +1 -1
- package/dist/{dialog-CaGJD02w.js → dialog-C9QGvVNG.js} +1 -1
- package/dist/{dialog-DQdeqvq-.d.ts → dialog-CgwSNHs1.d.ts} +1 -1
- package/dist/dialog.d.ts +1 -1
- package/dist/dialog.js +1 -1
- package/dist/direction-CvDpql3O.js +1 -0
- package/dist/{dropdown-menu-CutWQ0bl.js → dropdown-menu-j4RbBbGa.js} +1 -1
- package/dist/dropdown-menu.js +1 -1
- package/dist/{field-B1wqeZr4.js → field-Bihblt8U.js} +1 -1
- package/dist/field-CPvjazWN.js +1 -0
- package/dist/field.d.ts +1 -1
- package/dist/field.js +1 -1
- package/dist/{icons-CH3tD_wq.js → icons-CDLz5lpI.js} +1 -1
- package/dist/{icons-CAtjMNti.js → icons-CW9lV9E1.js} +1 -1
- package/dist/icons.js +1 -1
- package/dist/{input-D_DjD9lT.js → input-eEKzP3cE.js} +1 -1
- package/dist/input.js +1 -1
- package/dist/{label-5T8i7I4X.js → label-nHqqYS7e.js} +1 -1
- package/dist/label.js +1 -1
- package/dist/line-chart.js +1 -1
- package/dist/llms.txt +1 -1
- package/dist/multi-select.js +1 -1
- package/dist/otp-input.d.ts +5 -0
- package/dist/otp-input.js +1 -1
- package/dist/pagination.d.ts +1 -1
- package/dist/pagination.js +1 -1
- package/dist/progress.js +1 -1
- package/dist/radio-group.js +1 -1
- package/dist/sandbar.js +1 -1
- package/dist/scatter-plot.js +1 -1
- package/dist/{select-DcL0-duV.js → select-Os5GVejP.js} +1 -1
- package/dist/select.js +1 -1
- package/dist/selectable-list.js +1 -1
- package/dist/{separator-DvPe27fH.js → separator-BPE-A8tw.js} +1 -1
- package/dist/separator.js +1 -1
- package/dist/{sheet-H8zvhSuA.js → sheet-CAFS09pT.js} +1 -1
- package/dist/sheet.d.ts +1 -1
- package/dist/sheet.js +1 -1
- package/dist/sidebar.d.ts +1 -1
- package/dist/sidebar.js +1 -1
- package/dist/slider.js +1 -1
- package/dist/split-button.d.ts +1 -1
- package/dist/split-button.js +1 -1
- package/dist/strata.d.ts +11 -7
- package/dist/strata.js +1 -1
- package/dist/switch.js +1 -1
- package/dist/tabs.d.ts +11 -1
- package/dist/tabs.js +1 -1
- package/dist/text-area.js +1 -1
- package/dist/theme-Dzem-qRB.js +1 -0
- package/dist/theme-switcher.d.ts +1 -1
- package/dist/theme-switcher.js +1 -1
- package/dist/theme.js +1 -1
- package/dist/toast.js +1 -1
- package/dist/truncated-text.d.ts +9 -1
- package/dist/truncated-text.js +1 -1
- package/dist/utils.js +1 -1
- package/package.json +2 -2
- package/dist/chart-BRkJfptA.js +0 -2
- package/dist/code-block-4Esx_gV-.js +0 -12
- package/dist/direction-Wa9W2F61.js +0 -1
- package/dist/field-Bpptk_9t.js +0 -1
- package/dist/theme-6Q65C1Rx.js +0 -1
package/dist/chart-BRkJfptA.js
DELETED
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{n as e,t}from"./compose-refs-sFdxsL7k.js";import{t as n}from"./cx-CK7o_rVv.js";import{t as r}from"./data-slot-EM6s2WEU.js";import{t as i}from"./button-BMfUxs_j.js";import{t as a}from"./use-is-hydrated-DDCqXmju.js";import{t as o}from"./use-copy-to-clipboard-ByLT8veV.js";import{t as s}from"./alternate-announcement-BkH4bOKp.js";import{t as c}from"./live-region-DQ1QLv3L.js";import{c as l}from"react/compiler-runtime";import{createContext as u,useContext as d,useEffect as f,useId as p,useLayoutEffect as m,useRef as h,useState as g,useSyncExternalStore as _}from"react";import v from"tiny-invariant";import{Fragment as y,jsx as b,jsxs as x}from"react/jsx-runtime";import{CheckIcon as S}from"@phosphor-icons/react/Check";import{CopyIcon as C}from"@phosphor-icons/react/Copy";import{scaleTime as w}from"d3-scale";import{area as T,curveLinear as E,curveMonotoneX as D,curveStep as O,line as k}from"d3-shape";const A=(e,t)=>Reflect.get(e,t),j=(e,t)=>e instanceof Date?e.getTime():typeof e==`number`?e:t&&typeof e==`string`?new Date(e).getTime():NaN,M=(e,t,n,r)=>`${e} ${t} "${n}" does not match any key in the provided data. Available keys: ${Object.keys(r[0]??{}).join(`, `)}.`,N=(e,t,n)=>`${e} could not read any "${t}" values as ${n===`time`?`dates`:`numbers`} for the "${n}" x scale — check the xScale and the data types.`,P=(e,t)=>e.some(e=>A(e,t)!==void 0),ee=({rootName:e,partName:t,rows:n,xKey:r,xScale:i,dataKeys:a,zKey:o})=>{if(n.length===0)return;if(!P(n,r))throw Error(M(e,`xKey`,r,n));let s=n;if(i===`linear`||i===`time`){let t=!1;if(s=n.filter(e=>{let n=A(e,r);return n!=null&&(t=!0),Number.isFinite(j(n,i===`time`))}),t&&s.length===0)throw Error(N(e,r,i))}if(s.length!==0){for(let e of a)if(!P(s,e))throw Error(M(t,`dataKey`,e,n));if(o!=null&&!P(s,o))throw Error(M(e,`zKey`,o,n))}},F=/* @__PURE__ */ new Map;let I=!1;const te=e=>typeof e==`object`&&!!e&&`yield`in e&&typeof Reflect.get(e,`yield`)==`function`,ne=()=>{let e=Reflect.get(globalThis,`scheduler`);return te(e)?e.yield():new Promise(e=>{if(typeof MessageChannel<`u`){let t=new MessageChannel;t.port1.addEventListener(`message`,()=>{t.port1.close(),e()},{once:!0}),t.port1.start(),t.port2.postMessage(null)}else setTimeout(e,0)})},re=(e,t)=>{let n=e.ownerDocument.defaultView;return t==null||n==null||t.bottom>0&&t.top<n.innerHeight&&t.right>0&&t.left<n.innerWidth},L=()=>{let e=performance.now(),t=[...F.entries()].toSorted(([,e],[,t])=>Number(t.onScreen)-Number(e.onScreen)||e.top-t.top);for(let[n,r]of t)if(F.get(n)===r&&(F.delete(n),r.run(r.rect),F.size>0&&performance.now()-e>=4))break;F.size>0&&!I&&(I=!0,ie())},ie=async()=>{await ne(),I=!1,L()},ae=(e,t)=>{F.set(e,{run:t.run,rect:t.rect,onScreen:re(e,t.rect),top:t.rect?.top??0})},oe=e=>{let t=F.get(e);t!=null&&(t.onScreen=!0)},se=e=>{F.delete(e)},R=()=>{F.size!==0&&L()};let z=null;const ce=()=>z??=new Intl.NumberFormat;let B=null;const V=()=>B??=new Intl.NumberFormat(void 0,{maximumSignificantDigits:4}),le=/* @__PURE__ */ new Map,H=(e,t)=>{let n=Object.is(e,-0)?0:e,r=t?.maximumFractionDigits;if(r!=null){let e=le.get(r);return e??(e=new Intl.NumberFormat(void 0,{maximumFractionDigits:r}),le.set(r,e)),e.format(n)}return n!==0&&Math.abs(n)<1?V().format(n):ce().format(n)},U=e=>!Number.isFinite(e)||e<=0?0:Math.min(20,Math.max(0,-Math.floor(Math.log10(e))));let W=null;const G=()=>W??=new Intl.DateTimeFormat(void 0,{month:`short`,day:`numeric`,hour:`numeric`,minute:`2-digit`});let K=null;const ue=()=>K??=new Intl.DateTimeFormat(void 0,{year:`numeric`,month:`short`,day:`numeric`}),de=e=>e.getHours()!==0||e.getMinutes()!==0||e.getSeconds()!==0||e.getMilliseconds()!==0,q=(e,t)=>typeof e==`string`?e:typeof e==`number`?H(e):Number.isNaN(e.getTime())?`—`:t?.datasetHasTimeOfDay??de(e)?G().format(e):ue().format(e),fe=e=>typeof e==`string`||typeof e==`number`||e instanceof Date?e:String(e),pe=(e,t,n)=>{let r=!1;if(n===`band`||n===`point`){let n=null,i=null;for(let a of e){let e=fe(A(a,t));e instanceof Date&&de(e)&&(r=!0),n??=e,i=e}return{count:e.length,first:n,last:i,hasTimeOfDay:r}}let i=n===`time`,a=0,o=1/0,s=-1/0;for(let n of e){let e=A(n,t),c=j(e,i);if(Number.isFinite(c)){if(!r){let t=e instanceof Date?e:i?new Date(c):null;t!=null&&de(t)&&(r=!0)}a+=1,o=Math.min(o,c),s=Math.max(s,c)}}return a===0?{count:a,first:null,last:null,hasTimeOfDay:r}:{count:a,first:i?new Date(o):o,last:i?new Date(s):s,hasTimeOfDay:r}},me={line:`Line chart`,bar:`Bar chart`,area:`Area chart`,scatter:`Scatter plot`},he=(e,t)=>e===`bar`?t?`category`:`categories`:t?`data point`:`data points`,ge=e=>e.length>0?` Series: ${e.join(`, `)}.`:``,_e=({kind:e,summary:t,hydrated:n})=>{let r;if(t.count===0)r=`${me[e]} with no data.`;else{let i=t.count===1,a=he(e,i),o=n?H(t.count):String(t.count),s=``;if(n&&t.first!=null&&t.last!=null){let e={datasetHasTimeOfDay:t.hasTimeOfDay};s=i?` at ${q(t.first,e)}`:` from ${q(t.first,e)} to ${q(t.last,e)}`}r=`${me[e]} with ${o} ${a}${s}.`}return{sentence:r,instructions:` Use the left and right arrow keys to move between data points, Page Up and Page Down to jump by a tenth of the data, Home and End to jump to the first and last, Enter or Space to activate the current point, and Escape to dismiss the readout.`}},ve=e=>{let{step:t,slot:n}=e,r=Math.min(64,Math.max(24,t*.6));return Math.min(n,r)},ye=.5,be=(e,t)=>e<0?e:t,xe=e=>{let{lower:t,upper:n,toPixel:r,reveal:i,gap:a}=e,o=r(t<0?n:t),s=o+(r(be(t,n))-o)*i;if(Math.abs(o-r(0))<ye)return{baseline:o,value:s};let c=Math.min(a,Math.abs(o-s)/2);return{baseline:o-Math.sign(o-s)*c,value:s}},Se=e=>{let{lower:t,upper:n,pileOuter:r,toPixel:i}=e;if(Number.isNaN(r))return!1;let a=i(be(t,n));return Math.abs(a-i(r))<ye},Ce=[`chart-1`,`chart-2`,`chart-3`,`chart-4`,`chart-5`,`chart-6`,`chart-7`,`chart-8`,`chart-other`],we=e=>Ce.includes(e),Te=e=>`--color-${e}`,Ee=`var(--color-chart-decorative)`,De=[`chart-1`,`chart-2`,`chart-3`,`chart-4`,`chart-5`,`chart-6`,`chart-7`,`chart-8`],Oe=/* @__PURE__ */ new WeakMap,ke=e=>{let t=Oe.get(e);return(t==null||t.parentNode!==e)&&(t=e.ownerDocument.createElement(`span`),t.style.display=`none`,t.setAttribute(`aria-hidden`,`true`),e.appendChild(t),Oe.set(e,t)),t},Ae=(e,t)=>{let n=ke(e);return n.style.color=t,e.ownerDocument.defaultView?.getComputedStyle(n).color??``},je=/* @__PURE__ */ new WeakMap,Me=e=>{let t=je.get(e);if(t!==void 0)return t;let n=e.createElement(`canvas`);n.width=1,n.height=1;let r=n.getContext(`2d`);return je.set(e,r),r},Ne=[`#010203`,`#030201`],J=/* @__PURE__ */ new WeakMap,Y=(e,t)=>{let n=J.get(e);n??(n=/* @__PURE__ */ new Map,J.set(e,n));let r=n.get(t);if(r!=null)return r;let i=!1;for(let n of Ne)if(e.fillStyle=n,e.fillStyle=t,e.fillStyle!==n){i=!0;break}return n.set(t,i),i},X=/^var\(\s*(--[\w-]+)\s*\)$/i,Pe=/var\(|currentcolor|light-dark\(/i,Fe=(e,t)=>{let{computed:n,parseContext:r}=t,i=/* @__PURE__ */ new Map;return{resolve:t=>{let a=i.get(t);if(a!=null)return a;let o=t.trim(),s=X.exec(o),c;c=s?.[1]==null?o.toLowerCase()===`currentcolor`?n.color:o:n.getPropertyValue(s[1]).trim();let l;return l=c===``||Pe.test(c)?Ae(e,o):r==null||Y(r,c)?c:Ae(e,o),i.set(t,l),l},fontFamily:n.fontFamily||`sans-serif`}},Z=(e,t)=>we(t)?e.resolve(`var(${Te(t)})`):e.resolve(t),Ie=e=>({grid:e.resolve(`var(--border-color-card-muted)`),baseline:e.resolve(`var(--border-color-card)`),tickText:e.resolve(`var(--text-color-muted)`),reference:e.resolve(`var(--color-neutral-500)`),surface:e.resolve(`var(--background-color-card)`)}),Le=e=>`${e.className}|${e.getAttribute(`data-applied-theme`)??``}|${e.getAttribute(`data-theme`)??``}`,Re=/* @__PURE__ */ new WeakMap,ze=(e,t)=>{let n=Re.get(e);if(n==null){let t=/* @__PURE__ */ new Set,r={observer:new MutationObserver(()=>{let n=Le(e);if(n!==r.signature){r.signature=n;for(let e of t)e()}}),listeners:t,signature:Le(e)};r.observer.observe(e,{attributes:!0,attributeFilter:[`class`,`data-applied-theme`,`data-theme`]}),Re.set(e,r),n=r}return n.listeners.add(t),()=>{n.listeners.delete(t),n.listeners.size===0&&(n.observer.disconnect(),Re.delete(e))}},Be=1.5,Ve=1.1,He=1.6,Ue=e=>`oklch(from ${e} calc(l - 0.18) c h)`,We=(e,t,n)=>{let r=Be;n===`up`?(e.moveTo(-1.5,t+r),e.lineTo(t+r,-1.5),e.moveTo(-1.5,r),e.lineTo(r,-1.5),e.moveTo(t-r,t+r),e.lineTo(t+r,t-r)):(e.moveTo(-1.5,-1.5),e.lineTo(t+r,t+r),e.moveTo(t-r,-1.5),e.lineTo(t+r,r),e.moveTo(-1.5,t-r),e.lineTo(r,t+r))},Ge=(e,t)=>{let{size:n,width:r}=t;e.fillRect(0,n/2-r/2,n,r)},Ke=(e,t)=>{let{size:n,width:r}=t;e.fillRect(n/2-r/2,0,r,n)},qe={hatch:(e,{size:t,ink:n})=>{e.strokeStyle=n,e.lineWidth=Be,e.beginPath(),We(e,t,`up`),e.stroke()},"hatch-reverse":(e,{size:t,ink:n})=>{e.strokeStyle=n,e.lineWidth=Be,e.beginPath(),We(e,t,`down`),e.stroke()},crosshatch:(e,{size:t,ink:n})=>{e.strokeStyle=n,e.lineWidth=1,e.beginPath(),We(e,t,`up`),We(e,t,`down`),e.stroke()},perpendicular:(e,{size:t,ink:n,orientation:r})=>{e.fillStyle=n,r===`horizontal`?Ke(e,{size:t,width:2}):Ge(e,{size:t,width:2})},parallel:(e,{size:t,ink:n,orientation:r})=>{e.fillStyle=n,r===`horizontal`?Ge(e,{size:t,width:2}):Ke(e,{size:t,width:2})},grid:(e,{size:t,ink:n})=>{e.fillStyle=n,Ge(e,{size:t,width:Ve}),Ke(e,{size:t,width:Ve})},dots:(e,{size:t,ink:n})=>{e.fillStyle=n,e.beginPath(),e.arc(t/4,t/4,He,0,Math.PI*2),e.moveTo(3*t/4+He,3*t/4),e.arc(3*t/4,3*t/4,He,0,Math.PI*2),e.fill()}},Je=(e,t)=>{let{texture:n,color:r,ink:i,devicePixelRatio:a,orientation:o}=t,s=e.canvas.ownerDocument.createElement(`canvas`);s.width=Math.max(1,Math.round(8*a)),s.height=s.width;let c=s.getContext(`2d`);if(c==null)return null;let l=s.width/8;c.scale(l,l),c.fillStyle=r,c.fillRect(0,0,8,8),qe[n](c,{size:8,ink:i,orientation:o});let u=e.createPattern(s,`repeat`);return u?.setTransform({a:1/l,b:0,c:0,d:1/l,e:0,f:0}),u},Ye=/* @__PURE__ */ new WeakMap,Xe=e=>{if(typeof e.matchMedia!=`function`)return!1;let t=Ye.get(e.matchMedia);return t??(t=e.matchMedia(`(prefers-reduced-motion: reduce)`),Ye.set(e.matchMedia,t)),t.matches},Ze=/* @__PURE__ */ new WeakMap,Qe=(e,t)=>{let n=e.matchMedia(`(resolution: ${e.devicePixelRatio}dppx)`),r=()=>{if(n.removeEventListener(`change`,r),t.listeners.size!==0){Qe(e,t);for(let e of t.listeners)e()}};n.addEventListener(`change`,r),t.disarm=()=>n.removeEventListener(`change`,r)},$e=(e,t)=>{if(typeof e.matchMedia!=`function`)return()=>{};let n=Ze.get(e);if(n==null){let t={listeners:/* @__PURE__ */ new Set,disarm:()=>{}};Qe(e,t),Ze.set(e,t),n=t}return n.listeners.add(t),()=>{n.listeners.delete(t),n.listeners.size===0&&(n.disarm(),Ze.delete(e))}},et=/* @__PURE__ */ new WeakMap,tt=(e,t)=>{let n=et.get(e);if(n==null){let t={listeners:/* @__PURE__ */ new Set,onBefore:()=>{for(let e of t.listeners)e.before()},onAfter:()=>{for(let e of t.listeners)e.after()}};e.addEventListener(`beforeprint`,t.onBefore),e.addEventListener(`afterprint`,t.onAfter),et.set(e,t),n=t}return n.listeners.add(t),()=>{n.listeners.delete(t),n.listeners.size===0&&(e.removeEventListener(`beforeprint`,n.onBefore),e.removeEventListener(`afterprint`,n.onAfter),et.delete(e))}},nt=/* @__PURE__ */ new WeakMap,rt=(e,t)=>{if(typeof ResizeObserver>`u`)return()=>{};let n=e.ownerDocument,r=nt.get(n);if(r==null){let e=/* @__PURE__ */ new Map;r={handlers:e,observer:new ResizeObserver(t=>{for(let n of t)e.get(n.target)?.(n)})},nt.set(n,r)}let i=r;return i.handlers.set(e,t),i.observer.observe(e),()=>{i.handlers.get(e)===t&&(i.handlers.delete(e),i.observer.unobserve(e),i.handlers.size===0&&(i.observer.disconnect(),nt.get(n)===i&&nt.delete(n)))}},it=e=>{let{pointCount:t,columnCount:n,wasDecimated:r}=e;return n<=0?!1:r?t>=n*3:t>=n*4},at=e=>{let{xs:t,values:n,startIndex:r,endIndex:i,positionK:a,positionB:o,columnCount:s}=e,c=new Uint8Array(s),l=new Float64Array(s),u=new Float64Array(s),d=new Float64Array(s),f=new Float64Array(s);for(let e=r;e<=i;e++){let r=n[e]??NaN;if(Number.isNaN(r))continue;let i=t[e]??NaN,p=Math.floor(i*a+o);p===s&&(p=s-1),!(p<0||p>=s)&&(c[p]===0?(c[p]=1,l[p]=r,u[p]=r,d[p]=r,f[p]=r):(r<(l[p]??1/0)&&(l[p]=r),r>(u[p]??-1/0)&&(u[p]=r),f[p]=r))}return{columnCount:s,hasData:c,minValue:l,maxValue:u,inValue:d,outValue:f}},ot=(e,t,n)=>{if(t<=0)return null;let r=0,i=t-1,a=e[0]??0,o=e[i]??0;if(n<=a)return 0;if(n>=o)return i;for(;i-r>1;){let t=r+i>>1;(e[t]??0)<=n?r=t:i=t}let s=n-(e[r]??0);return(e[i]??0)-n<s?i:r},st=Math.PI/2-.05,ct=e=>({cosYaw:Math.cos(e.yaw),sinYaw:Math.sin(e.yaw),cosPitch:Math.cos(e.pitch),sinPitch:Math.sin(e.pitch)}),lt=(e,t,n,r)=>{let i=e*r.cosYaw+n*r.sinYaw,a=-e*r.sinYaw+n*r.cosYaw,o=t*r.cosPitch-a*r.sinPitch,s=t*r.sinPitch+a*r.cosPitch,c=4/(4+s);return{x:i*c,y:o*c,depth:s,scale:c}},ut=e=>Math.min(st,Math.max(-st,e)),dt=(e,t)=>{let n=t[1]-t[0];return n===0?0:(e-t[0])/n*2-1},ft=[[-1,-1,-1],[1,-1,-1],[1,1,-1],[-1,1,-1],[-1,-1,1],[1,-1,1],[1,1,1],[-1,1,1]],pt=[[0,1],[1,2],[2,3],[3,0],[4,5],[5,6],[6,7],[7,4],[0,4],[1,5],[2,6],[3,7]],mt=Math.sqrt(50),ht=Math.sqrt(10),gt=Math.sqrt(2),_t=(e,t,n,r)=>{let i=(t-e)/Math.max(0,n),a=r?.integer?Math.max(1,i):i,o=Math.floor(Math.log10(a)),s=a/10**o,c=s>=mt?10:s>=ht?5:s>=gt?2:1,l,u,d;return o<0?(d=10**-o/c,l=Math.round(e*d),u=Math.round(t*d),l/d<e&&(l+=1),u/d>t&&--u,d=-d):(d=10**o*c,l=Math.round(e/d),u=Math.round(t/d),l*d<e&&(l+=1),u*d>t&&--u),u<l&&.5<=n&&n<2?_t(e,t,n*2,r):[l,u,d]},vt=(e,t,n,r)=>{if(!(n>0))return[];if(e===t)return r?.integer&&!Number.isInteger(e)?[]:[e];let i=t<e,[a,o,s]=i?_t(t,e,n,r):_t(e,t,n,r);if(!(o>=a))return[];let c=o-a+1,l=[];for(let e=0;e<c;e+=1){let t=i?o-e:a+e;l.push(s<0?t/-s:t*s)}return l},yt=(e,t,n)=>_t(e,t,n)[2],bt=(e,t)=>{let n=e[1]-e[0];if(n===0)return{k:0,b:(t[0]+t[1])/2};let r=(t[1]-t[0])/n;return{k:r,b:t[0]-e[0]*r}},xt=e=>{let{count:t,rangeStart:n,rangeEnd:r,paddingInner:i,paddingOuter:a}=e,o=r-n;if(t<=0||o<=0)return{count:Math.max(0,t),rangeStart:n,step:0,bandwidth:0,offset:0};let s=o/Math.max(1,t-i+a*2);return{count:t,rangeStart:n,step:s,bandwidth:s*(1-i),offset:s*a}},St=(e,t)=>e.rangeStart+e.offset+t*e.step,Ct=(e,t)=>St(e,t)+e.bandwidth/2,wt=(e,t)=>({start:St(e,t)-(e.step-e.bandwidth)/2,size:e.step}),Tt=(e,t)=>{if(e.count===0||e.step===0)return null;let n=Math.floor((t-e.rangeStart-e.offset+e.step/2-e.bandwidth/2)/e.step);return Math.min(e.count-1,Math.max(0,n))},Et=(e,t,n)=>vt(e[0],e[1],t,n);let Q=null,Dt=null;const Ot=e=>{if(Dt!=null&&Q!=null&&Q[0]===e[0]&&Q[1]===e[1])return Dt;let t=w().domain([new Date(e[0]),new Date(e[1])]);return Q=[e[0],e[1]],Dt=t,t},kt=(e,t)=>Ot(e).ticks(t).map(e=>e.getTime()),At=e=>{let t=Ot(e).tickFormat();return e=>t(new Date(e))},jt=(e,t)=>{if(e[0]>e[1])return jt([e[1],e[0]],t);if(e[0]===e[1]){let n=e[0],r=n===0?1:Math.abs(n)*.5;return jt([n-r,n+r],t)}let n=e[0],r=e[1],i=NaN;for(let e=0;e<10;e++){let e=yt(n,r,t);if(e===i||e===0||!Number.isFinite(e))break;if(e>0)n=Math.floor(n/e)*e,r=Math.ceil(r/e)*e;else{let t=-e;n=Math.floor(n*t)/t,r=Math.ceil(r*t)/t}i=e}return[n,r]},Mt=(e,t)=>{let n=jt(e,t);return e[0]===0?[0,n[1]]:n},Nt=e=>e===`monotone`?D:e===`step`?O:E,$=e=>Math.round(e)+.5,Pt=(e,t)=>{let{plot:n,color:r,xLines:i,yLines:a}=t;e.save(),e.strokeStyle=r,e.lineWidth=1;for(let t of i)e.globalAlpha=t.alpha,e.beginPath(),e.moveTo($(t.position),n.top),e.lineTo($(t.position),n.top+n.height),e.stroke();for(let t of a)e.globalAlpha=t.alpha,e.beginPath(),e.moveTo(n.left,$(t.position)),e.lineTo(n.left+n.width,$(t.position)),e.stroke();e.restore()},Ft=(e,t)=>{let{plot:n,color:r,y:i}=t;e.strokeStyle=r,e.lineWidth=1,e.beginPath(),e.moveTo(n.left,$(i)),e.lineTo(n.left+n.width,$(i)),e.stroke()},It=(e,t)=>{let{plot:n,color:r,x:i}=t;e.strokeStyle=r,e.lineWidth=1,e.beginPath(),e.moveTo($(i),n.top),e.lineTo($(i),n.top+n.height),e.stroke()},Lt=(e,t)=>{let{fill:n,rects:r}=t;e.fillStyle=n,e.beginPath();for(let t of r){let n=Math.max(.5,t.width),r=Math.min(t.valueY,t.baselineY),i=Math.abs(t.baselineY-t.valueY);if(i===0)continue;let a=t.rounded&&n>=8?Math.min(4,n/2,i):0;a===0?e.rect(t.x,r,n,i):t.valueY<=t.baselineY?e.roundRect(t.x,r,n,i,[a,a,0,0]):e.roundRect(t.x,r,n,i,[0,0,a,a])}e.fill()},Rt=(e,t)=>{let{fill:n,rects:r}=t;e.fillStyle=n,e.beginPath();for(let t of r){let n=Math.max(.5,t.height),r=Math.min(t.valueX,t.baselineX),i=Math.abs(t.valueX-t.baselineX);if(i===0)continue;let a=t.rounded&&n>=8?Math.min(4,n/2,i):0;a===0?e.rect(r,t.y,i,n):t.valueX>=t.baselineX?e.roundRect(r,t.y,i,n,[0,a,a,0]):e.roundRect(r,t.y,i,n,[a,0,0,a])}e.fill()},zt=(e,t)=>{let{color:n,curve:r,indexes:i,xAt:a,yAt:o,definedAt:s}=t,c=k().x(a).y(o).defined(s).curve(Nt(r)).context(e);e.strokeStyle=n,e.lineWidth=2,e.lineJoin=`round`,e.lineCap=`round`,e.beginPath(),c(i),e.stroke()},Bt=(e,t)=>{let{color:n,curve:r,indexes:i,xAt:a,y0At:o,y1At:s,definedAt:c}=t,l=T().x(a).y0(o).y1(s).defined(c).curve(Nt(r)).context(e);e.beginPath(),l(i),e.save(),e.globalAlpha=.1,e.fillStyle=n,e.fill(),e.restore();let u=k().x(a).y(s).defined(c).curve(Nt(r)).context(e);e.strokeStyle=n,e.lineWidth=2,e.lineJoin=`round`,e.lineCap=`round`,e.beginPath(),u(i),e.stroke()},Vt=(e,t)=>{let{color:n,columns:r,columnToX:i,valueK:a,valueB:o}=t;e.strokeStyle=n,e.lineWidth=2,e.lineJoin=`round`,e.lineCap=`round`,e.beginPath();let s=!1;for(let t=0;t<r.columnCount;t++){if(r.hasData[t]===0){s=!1;continue}let n=i(t),c=(r.inValue[t]??0)*a+o,l=(r.minValue[t]??0)*a+o,u=(r.maxValue[t]??0)*a+o,d=(r.outValue[t]??0)*a+o;s?e.lineTo(n,c):(e.moveTo(n,c),s=!0),(l!==c||u!==c)&&(e.lineTo(n,l),e.lineTo(n,u)),d!==u&&e.lineTo(n,d)}e.stroke()},Ht=(e,t)=>{let{color:n,lowerColumns:r,upperColumns:i,columnToX:a,valueK:o,valueB:s}=t;e.beginPath();let c=-1,l=t=>{if(c<0)return;let n=!1;for(let r=c;r<=t;r++){let t=a(r),c=(i.maxValue[r]??0)*o+s;n?e.lineTo(t,c):(e.moveTo(t,c),n=!0)}for(let n=t;n>=c;n--){let t=a(n),i=(r.minValue[n]??0)*o+s;e.lineTo(t,i)}e.closePath(),c=-1};for(let e=0;e<i.columnCount;e++)i.hasData[e]===0?l(e-1):c<0&&(c=e);l(i.columnCount-1),e.save(),e.globalAlpha=.1,e.fillStyle=n,e.fill(),e.restore(),Vt(e,{color:n,columns:i,columnToX:a,valueK:o,valueB:s})},Ut=(e,t,n,r,i)=>{let a=!1;for(let[o,s]of i)a?e.lineTo(t+o*r,n+s*r):(e.moveTo(t+o*r,n+s*r),a=!0);e.closePath()},Wt=[[-1/3,-1],[1/3,-1],[1/3,-1/3],[1,-1/3],[1,1/3],[1/3,1/3],[1/3,1],[-1/3,1],[-1/3,1/3],[-1,1/3],[-1,-1/3],[-1/3,-1/3]],Gt=Wt.map(([e,t])=>[(e-t)/Math.SQRT2,(e+t)/Math.SQRT2]),Kt=Array.from({length:10},(e,t)=>{let n=-Math.PI/2+t*Math.PI/5,r=t%2==0?1:.382;return[Math.cos(n)*r,Math.sin(n)*r]}),qt={circle:(e,t,n,r)=>{e.arc(t,n,r,0,Math.PI*2)},square:(e,t,n,r)=>{let i=r*.886;e.moveTo(t-i,n-i),e.lineTo(t+i,n-i),e.lineTo(t+i,n+i),e.lineTo(t-i,n+i),e.closePath()},triangle:(e,t,n,r)=>{let i=r*1.55;e.moveTo(t,n-i),e.lineTo(t+i*.866,n+i*.5),e.lineTo(t-i*.866,n+i*.5),e.closePath()},diamond:(e,t,n,r)=>{let i=r*1.253;e.moveTo(t,n-i),e.lineTo(t+i,n),e.lineTo(t,n+i),e.lineTo(t-i,n),e.closePath()},"triangle-down":(e,t,n,r)=>{let i=r*1.55;e.moveTo(t,n+i),e.lineTo(t+i*.866,n-i*.5),e.lineTo(t-i*.866,n-i*.5),e.closePath()},plus:(e,t,n,r)=>{Ut(e,t,n,r*1.189,Wt)},cross:(e,t,n,r)=>{Ut(e,t,n,r*1.189,Gt)},star:(e,t,n,r)=>{Ut(e,t,n,r*1.673,Kt)}},Jt=(e,t,n,r,i)=>{qt[i](e,t,n,r)},Yt=(e,t)=>{let{color:n,surface:r,shape:i,indexes:a,xAt:o,yAt:s,definedAt:c}=t;e.fillStyle=n,e.strokeStyle=r,e.lineWidth=2;for(let t of a)c(t)&&(e.beginPath(),Jt(e,o(t),s(t),4,i),e.fill(),e.stroke())},Xt=5e3,Zt=2e4,Qt=(e,t)=>{let{color:n,surface:r,shape:i,totalPointCount:a,indexes:o,xAt:s,yAt:c,radiusAt:l}=t;if(e.fillStyle=n,a>Zt){e.beginPath();for(let t of o)l(t)<=0||e.rect(s(t)-1,c(t)-1,2,2);e.fill();return}let u=a<=Xt;e.strokeStyle=r,e.lineWidth=2;for(let t of o){let n=l(t);n<=0||(e.beginPath(),Jt(e,s(t),c(t),n,i),e.fill(),u&&e.stroke())}},$t=(e,t)=>{let{count:n,order:r,screenX:i,screenY:a,radius:o,colorAt:s,shapeAt:c,alphaAt:l,surface:u}=t;if(e.save(),n>Zt){let t=``,n=-1;for(let c of r){let r=s(c);r!==t&&(e.fillStyle=r,t=r);let u=l(c);u!==n&&(e.globalAlpha=u,n=u);let d=Math.max(1,(o[c]??0)/2);e.fillRect((i[c]??0)-d/2,(a[c]??0)-d/2,d,d)}e.restore();return}let d=n<=Xt;e.strokeStyle=u,e.lineWidth=2;let f=``,p=-1;for(let t of r){let n=s(t);n!==f&&(e.fillStyle=n,f=n);let r=l(t);r!==p&&(e.globalAlpha=r,p=r),e.beginPath(),Jt(e,i[t]??0,a[t]??0,o[t]??0,c(t)),e.fill(),d&&e.stroke()}e.restore()},en=(e,t)=>{let{gridColor:n,axisColor:r,corners:i,edges:a,cubeAlpha:o,axes:s}=t;if(e.save(),o>.01){e.globalAlpha=o,e.strokeStyle=n,e.lineWidth=1,e.beginPath();for(let[t,n]of a){let r=i[t],a=i[n];r!=null&&a!=null&&(e.moveTo(r.x,r.y),e.lineTo(a.x,a.y))}e.stroke()}e.strokeStyle=r;for(let{alpha:t,from:n,to:r}of s)t<=.01||(e.globalAlpha=t,e.beginPath(),e.moveTo(n.x,n.y),e.lineTo(r.x,r.y),e.stroke());e.restore()},tn=(e,t)=>{let{textColor:n,fontFamily:r,plot:i,center:a,axes:o}=t;e.save(),e.fillStyle=n,e.font=`11px ${r}`,e.textAlign=`center`,e.textBaseline=`middle`;for(let{label:t,alpha:n,from:r,to:s}of o){if(n<=.01)continue;let o=Math.hypot(r.x-a.x,r.y-a.y),c=Math.hypot(s.x-a.x,s.y-a.y),l=c>=o?s:r,u=c>=o?r:s,d=Math.max(1,Math.hypot(l.x-u.x,l.y-u.y)),f=(l.x-u.x)/d*16,p=(l.y-u.y)/d*16,m=Math.min(i.left+i.width-8,Math.max(i.left+8,l.x+f)),h=Math.min(i.top+i.height-6,Math.max(i.top+6,l.y+p));e.globalAlpha=n,e.fillText(t,m,h)}e.restore()},nn=(e,t)=>{let{plot:n,color:r,textColor:i,y:a,label:o,fontFamily:s}=t;e.strokeStyle=r,e.lineWidth=1,e.setLineDash([4,4]),e.beginPath(),e.moveTo(n.left,$(a)),e.lineTo(n.left+n.width,$(a)),e.stroke(),e.setLineDash([]),o!=null&&o.length>0&&(e.font=`11px ${s}`,e.fillStyle=i,e.textAlign=`right`,e.textBaseline=`bottom`,e.fillText(o,n.left+n.width-4,a-3))},rn=(e,t)=>{let{plot:n,color:r,textColor:i,x:a,label:o,fontFamily:s}=t;if(e.strokeStyle=r,e.lineWidth=1,e.setLineDash([4,4]),e.beginPath(),e.moveTo($(a),n.top),e.lineTo($(a),n.top+n.height),e.stroke(),e.setLineDash([]),o!=null&&o.length>0){e.font=`11px ${s}`,e.fillStyle=i;let t=e.measureText(o).width,r=a+4+t<=n.left+n.width;e.textAlign=r?`left`:`right`,e.textBaseline=`top`,e.fillText(o,r?a+4:a-4,n.top+3)}},an=(e,t)=>{let{plot:n,color:r,fontFamily:i,xLabels:a,yLabels:o}=t;e.save(),e.font=`11px ${i}`,e.fillStyle=r,e.textAlign=`right`,e.textBaseline=`middle`;for(let t of o)e.globalAlpha=t.alpha,e.fillText(t.text,n.left-8,t.position);e.textAlign=`center`,e.textBaseline=`top`;for(let t of a)e.globalAlpha=t.alpha,e.fillText(t.text,t.position,n.top+n.height+8);e.restore()},on=e=>{let t=e.length,n=e[0]?.length??0,r=[],i=[];for(let e=0;e<t;e++)r.push(new Float64Array(n)),i.push(new Float64Array(n));let a=0,o=0,s=new Float64Array(n),c=new Float64Array(n),l=new Int32Array(n).fill(-1),u=new Int32Array(n).fill(-1);for(let d=0;d<t;d++){let t=e[d],f=r[d],p=i[d];if(t!=null&&f!=null&&p!=null)for(let e=0;e<n;e++){let n=t[e]??NaN;if(Number.isNaN(n))f[e]=NaN,p[e]=NaN;else if(n>=0){let t=s[e]??0,r=t+n;s[e]=r,f[e]=t,p[e]=r,r>o&&(o=r),n>0&&(l[e]=d)}else{let t=c[e]??0,r=t+n;c[e]=r,f[e]=r,p[e]=t,r<a&&(a=r),u[e]=d}}}return{lower:r,upper:i,min:a,max:o,positiveEnd:l,negativeEnd:u}},sn=e=>1-(1-e)**3;var cn=class{#e=/* @__PURE__ */ new Float64Array;#t=/* @__PURE__ */ new Float64Array;#n=/* @__PURE__ */ new Float64Array;#r=0;#i=0;#a=!1;get active(){return this.#a}values(){return this.#n}retarget(e,t){let{duration:n,now:r}=t,i=e.length,a=this.#n.length!==i;if(a&&(this.#e=new Float64Array(i),this.#t=new Float64Array(i),this.#n=new Float64Array(i)),a||n<=0){for(let t=0;t<i;t++){let n=e[t]??NaN;this.#e[t]=n,this.#t[t]=n,this.#n[t]=n}this.#a=!1;return}let o=!1;for(let t=0;t<i;t++){let n=e[t]??NaN,r=this.#n[t]??NaN;if(r!==n&&!(Number.isNaN(r)&&Number.isNaN(n))){o=!0;break}}if(o){for(let t=0;t<i;t++)this.#e[t]=this.#n[t]??NaN,this.#t[t]=e[t]??NaN;this.#r=r,this.#i=n,this.#a=!0}else{for(let t=0;t<i;t++)this.#t[t]=e[t]??NaN;this.#a=!1}}snap(){this.#n.set(this.#t),this.#a=!1}tick(e){if(!this.#a)return!1;let t=Math.min(1,(e-this.#r)/this.#i),n=sn(t);for(let e=0;e<this.#n.length;e++){let t=this.#e[e]??NaN,r=this.#t[e]??NaN;Number.isNaN(t)||Number.isNaN(r)?this.#n[e]=r:this.#n[e]=t+(r-t)*n}return t>=1&&(this.#a=!1),this.#a}},ln=class{#e=/* @__PURE__ */ new Float64Array;#t=/* @__PURE__ */ new Float64Array;#n=0;#r=!1;#i;#a;#o=0;constructor(e={}){this.#i=e.speed??.14,this.#a=e.epsilon??.001}get active(){return this.#r}values(){return this.#t}jump(e){this.#t.length!==e.length&&(this.#e=new Float64Array(e.length),this.#t=new Float64Array(e.length));for(let t=0;t<e.length;t++){let n=e[t]??NaN;this.#e[t]=n,this.#t[t]=n}this.#r=!1}aim(e,t){if(this.#t.length!==e.length){this.jump(e);return}let n=!1;for(let t=0;t<e.length;t++){let r=e[t]??NaN,i=this.#e[t]??NaN;if(i!==r&&!(Number.isNaN(i)&&Number.isNaN(r))){n=!0;break}}if(!n)return;let r=0;for(let t=0;t<e.length;t++){let n=e[t]??NaN;this.#e[t]=n;let i=Math.abs(n-(this.#t[t]??NaN));Number.isFinite(i)&&i>r&&(r=i)}this.#o=r,this.#r||(this.#r=!0,this.#n=t)}tick(e){if(!this.#r)return!1;let t=Math.min(50,Math.max(0,e-this.#n));this.#n=e;let n=1-(1-this.#i)**(t/16.67),r=Math.max(this.#o*this.#a,2**-52),i=!0;for(let e=0;e<this.#t.length;e++){let t=this.#e[e]??NaN,a=this.#t[e]??NaN;if(Number.isNaN(t)||Number.isNaN(a)){this.#t[e]=t;continue}let o=a+(t-a)*n;n>0&&o===a||Math.abs(t-o)<=r?this.#t[e]=t:(this.#t[e]=o,i=!1)}return this.#r=!i,this.#r}};const un=e=>`${e.colorInput}|${e.texture}`,dn={bar:`BarChart.Bar`,line:`LineChart.Line`,area:`AreaChart.Area`,scatter:`ScatterPlot.Point`},fn=1e3;var pn=class{#e;#t;#n;#r={xKey:``,xScale:`linear`,yDomain:[`auto`,`auto`],orientation:`vertical`,zKey:null,dimensions:3,stacked:!1,animate:!0};#i={onDatumActivate:null,onActiveIndexChange:null};#a=null;#o=!1;#s=null;#c=null;#l=null;#u=null;#d=null;#f=null;#p;#m=!1;#h;#g=!1;#_=0;#v=0;#y=1;#b=[];#x=0;#S=/* @__PURE__ */ new Float64Array;#C=[];#w=null;#T=null;#E=!1;#D=!1;#O=/* @__PURE__ */ new Map;#k=0;#A=0;#j=!0;#M=!0;#N=null;#P=new ln({speed:.16});#F=new ln({speed:.2});#I=/* @__PURE__ */ new Map;#L=/* @__PURE__ */ new Map;#R=!1;#z=/* @__PURE__ */ new Map;#B=/* @__PURE__ */ new Map;#V=0;#H=!1;#U=/* @__PURE__ */ new Map;#W={alpha:0,target:0};#G=0;#K=null;#q=null;#J=null;#Y={left:0,top:0,width:0,height:0};#X=null;#Z=/* @__PURE__ */ new Float64Array;#Q=[0,1];#$={yaw:.65,pitch:-.35};#ee=new ln({speed:.12});#te=new ln({speed:.16});#ne=null;#re=!1;#ie=null;#ae=/* @__PURE__ */ new Int32Array;#oe=/* @__PURE__ */ new Map;#se=``;#ce=null;#le=null;#ue=null;#de=void 0;#fe=null;#pe=!1;#me=null;#he=null;#ge={width:0,height:0};#_e=!1;#ve=!1;#ye=0;#be=!1;constructor(e){this.#e=e.kind,this.#t=e.elements,this.#n=e.store,this.#p=e.inView??!0,this.#h=this.#p,e.size!=null&&(this.#_=e.size.width,this.#v=e.size.height),this.#y=this.#Ve(),this.#n.onSeriesChange=()=>{this.#D=!0,this.#Le()},this.#n.onPresentationChange=()=>{this.#Le()},this.#s=rt(e.elements.plot,e=>{let t=this.#Ve();(e.contentRect.width!==this.#_||e.contentRect.height!==this.#v||t!==this.#y)&&(this.#_=e.contentRect.width,this.#v=e.contentRect.height,this.#y=t,this.#U.clear(),this.#ce=null,this.#Le())}),this.#p&&this.#Ce();let t=e.elements.root.ownerDocument.documentElement;this.#c=ze(t,()=>{this.#J=null,this.#Le()}),this.#f=e.elements.root.ownerDocument.defaultView,this.#f!=null&&(this.#d=tt(this.#f,{before:this.#xe,after:this.#Se}),this.#u=$e(this.#f,()=>{this.#y=this.#Ve(),this.#U.clear(),this.#Le()})),this.#te.jump([1,1])}destroy(){this.#be=!0,this.#s?.(),this.#l?.disconnect(),this.#c?.(),this.#u?.(),this.#d?.(),this.#n.onSeriesChange=null,this.#n.onPresentationChange=null,this.#K!=null&&(clearTimeout(this.#K),this.#K=null),this.#ye!==0&&cancelAnimationFrame(this.#ye)}setInView(e){e===this.#p||this.#be||(this.#p=e,e&&(this.#Ce(),(this.#ve||this.#D)&&this.#ze()))}markSeen(){if(this.#h||this.#be)return;this.#h=!0;let e=performance.now(),t=this.#ke();for(let n of this.#L.values())n.retarget([1],{duration:t,now:e});this.#Le()}releaseBackingStores(){if(this.#be)return;let e=this.#t.canvas;(e.width!==0||e.height!==0)&&(e.width=0,e.height=0);let t=this.#q;t!=null&&(t.width!==0||t.height!==0)&&(t.width=0,t.height=0),this.#ve=!0}commitNow(){this.#be||(this.#ye!==0&&(cancelAnimationFrame(this.#ye),this.#ye=0),this.#_e=!1,this.#Be())}attachTooltip(e){this.#t.tooltip===e||this.#be||(this.#l?.disconnect(),this.#l=null,this.#ge={width:0,height:0},this.#t.tooltip=e,e!=null&&this.#p&&this.#Ce(),this.#Re())}paintForPrint(){if(!(this.#be||this.#m)){if(this.#m=!0,this.#_===0||this.#v===0){let e=this.#t.plot.getBoundingClientRect();this.#_=e.width,this.#v=e.height}if(!this.#h){this.#h=!0;let e=performance.now();for(let t of this.#L.values())t.retarget([1],{duration:0,now:e})}this.#ve=!0,this.#Be()}}#xe=()=>{this.paintForPrint()};#Se=()=>{this.#m=!1,this.#p||this.releaseBackingStores()};#Ce(){let e=this.#t.tooltip;e!=null&&this.#l==null&&typeof ResizeObserver<`u`&&(this.#l=new ResizeObserver(()=>{this.#ge={width:e.offsetWidth,height:e.offsetHeight},this.#Re()}),this.#l.observe(e))}#we(){return this.#o||(this.#o=!0,this.#a=this.#t.canvas.getContext(`2d`)),this.#a}setOptions(e){let t=this.#r;if(this.#r=e,t.xScale!==e.xScale&&this.#z.clear(),t.animate&&!e.animate&&this.#Te(),t.dimensions!==e.dimensions){let t=[+(e.dimensions>=2),+(e.dimensions>=3)],n=mn(e.dimensions);if(this.#Oe()===0||!this.#R)this.#te.jump(t),this.#$=n,this.#ee.jump([n.yaw,n.pitch]);else{let e=n.yaw+Math.round((this.#$.yaw-n.yaw)/(Math.PI*2))*Math.PI*2;this.#te.aim(t,performance.now()),this.#ee.jump([this.#$.yaw,this.#$.pitch]),this.#ee.aim([e,n.pitch],performance.now())}}(t.xKey!==e.xKey||t.xScale!==e.xScale||t.zKey!==e.zKey||t.stacked!==e.stacked)&&(this.#D=!0),(t.yDomain[0]!==e.yDomain[0]||t.yDomain[1]!==e.yDomain[1])&&(this.#ce=null,this.#R&&(this.#Oe()===0?this.#P.jump(this.#je()):this.#P.aim(this.#je(),performance.now()))),this.#Le()}setCallbacks(e){this.#i=e}setRows(e){e!==this.#b&&(this.#b=e,this.#D=!0,this.#Le())}flushIngest(){!this.#D||this.#be||(this.#D=!1,this.#Ee())}setControlledActiveIndex(e){let t=this.#fe;this.#fe=null;let n=this.#de!==void 0;if(this.#de=e,e!==void 0){let n=t!=null&&t.index===e&&t.viaKeyboard;this.#gt(e==null?null:this.#ft(e),{viaKeyboard:n,notify:!1})}else n&&this.#gt(null,{viaKeyboard:!1,notify:!1});this.#Re()}handlePointerMove(e,t){if(this.#ne!=null){let n=e-this.#ne.lastX,r=t-this.#ne.lastY;(this.#ne.moved||Math.abs(n)+Math.abs(r)>3)&&(this.#ne.moved=!0,this.#$={yaw:this.#$.yaw+n*.008,pitch:ut(this.#$.pitch+r*.008)},this.#ee.jump([this.#$.yaw,this.#$.pitch]),this.#ne.lastX=e,this.#ne.lastY=t,this.#gt(null,{viaKeyboard:!1,notify:!1}),this.#Le());return}if(this.#me=e,this.#he=t,this.#e===`scatter`){let n=this.#Ct(e,t);this.#le=n?.seriesKey??null,this.#ce=n==null?null:{x:n.screenX,y:n.screenY},this.#gt(n?.index??null,{viaKeyboard:!1,notify:!0});return}let n=this.#mt(e,t);this.#gt(n,{viaKeyboard:!1,notify:!0})}handlePointerDown(e,t){this.#re=!0,this.#Ne()?this.#ne={lastX:e,lastY:t,moved:!1}:this.handlePointerMove(e,t)}handlePointerUp(e,t){let n=this.#ne;this.#ne=null;let r=this.#re;if(this.#re=!1,n!=null){if(n.moved)return;this.handlePointerMove(e,t)}r&&this.handleActivate(e,t)}handlePointerLeave(){this.#me=null,this.#he=null,this.#ne=null,this.#re=!1,this.#le=null,this.#ce=null,this.#gt(null,{viaKeyboard:!1,notify:!0})}handleActivate(e,t){let n=this.#ut();if(n==null)return;let r=this.#dt(n),i=this.#b[r];if(i==null)return;let a=this.#e===`scatter`?this.#le:e==null||t==null?null:this.#ht(n,e,t);this.#i.onDatumActivate?.({index:r,xValue:this.#pt(n),datum:i,dataKey:a})}handleKeyDown(e){if(this.#x===0)return!1;let t=this.#x-1,n=this.#ut(),r=this.#H?Math.max(1,Math.floor(this.#x/Math.max(1,this.#Y.width*this.#y))):1,i=Math.max(1,Math.floor(this.#x/10)),a=(()=>{switch(e){case`ArrowLeft`:return Math.max(0,(n??this.#x)-r);case`ArrowRight`:return Math.min(t,(n??-1)+r);case`PageUp`:return Math.min(t,(n??0)+i);case`PageDown`:return Math.max(0,(n??t)-i);case`Home`:return 0;case`End`:return t;case`Escape`:return null;default:return}})();return a===void 0?e===`Enter`||e===` `?(this.handleActivate(null,null),!0):!1:(this.#me=null,this.#he=null,this.#le=null,this.#ce=null,this.#gt(a,{viaKeyboard:!0,notify:!0}),!0)}invalidateColors(){this.#J!=null&&(this.#J=null,this.#oe.clear(),this.#Le())}#Te(){this.#P.jump(this.#je()),this.#F.jump(this.#Me()),this.#te.jump([+(this.#r.dimensions>=2),+(this.#r.dimensions>=3)]);let e=mn(this.#r.dimensions);this.#$=e,this.#ee.jump([e.yaw,e.pitch]);for(let e of this.#I.values())e.snap();for(let e of this.#L.values())e.snap();this.#W.alpha=this.#W.target,this.#Le()}#Ee(){let e=this.#b,{xKey:t,xScale:n}=this.#r,r=this.#n.seriesSpecs();this.#U.clear();let i=this.#S;if(n===`band`||n===`point`){let n=e.length,r=new Float64Array(n),i=Array.from({length:n},()=>``),a=!1;for(let o=0;o<n;o++){let n=e[o],s=n==null?void 0:A(n,t);s!==void 0&&(a=!0),i[o]=typeof s==`string`||typeof s==`number`||s instanceof Date?s:String(s),r[o]=o}v(n===0||a,M(this.#Fe(),`xKey`,t,e)),this.#w=null,this.#T=null,this.#x=n,this.#S=r,this.#C=i,this.#M=!0}else{let r=[],i=!1,a=!1,o=!1;for(let s=0;s<e.length;s++){let c=e[s],l=c==null?void 0:A(c,t);l!==void 0&&(i=!0),l!=null&&(a=!0);let u=j(l,n===`time`);Number.isFinite(u)&&(r.push({source:s,x:u}),o=!0)}v(e.length===0||i,M(this.#Fe(),`xKey`,t,e)),v(!a||o,N(this.#Fe(),t,n));let s=!0;for(let e=1;e<r.length;e++)if((r[e]?.x??0)<(r[e-1]?.x??0)){s=!1;break}let c=s?r:r.toSorted((e,t)=>e.x-t.x),l=c.length,u=new Float64Array(l),d=l===e.length,f=!0,p=new Int32Array(l);for(let e=0;e<l;e++){let t=c[e];t!=null&&(u[e]=t.x,Number.isInteger(t.x)||(f=!1),p[e]=t.source,t.source!==e&&(d=!1))}if(d)this.#w=null,this.#T=null;else{this.#w=p;let t=new Int32Array(e.length).fill(-1);for(let e=0;e<l;e++){let n=p[e];n!=null&&(t[n]=e)}this.#T=t}this.#x=l,this.#S=u,this.#C=[],this.#M=f}let a=!1;for(let e of this.#C)if(e instanceof Date&&de(e)){a=!0;break}this.#E=a;let o=this.#S[0],s=this.#S[this.#x-1],c=i[0],l=i[i.length-1];!this.#Ne()&&(n===`linear`||n===`time`)&&o!=null&&s!=null&&c!=null&&l!=null&&o>c&&s>=l?(this.#W.target=1,this.#G=performance.now()):(o!==c||s!==l)&&(this.#W.target=0);let u=this.#x,d=i.length===u&&u<=2500;if(d){for(let e=0;e<u;e++)if(i[e]!==this.#S[e]){d=!1;break}}let f=this.#O;this.#O=/* @__PURE__ */ new Map;let p=1/0,m=-1/0,h=!0;for(let t of r){let n=new Float64Array(u),r=!1;for(let i=0;i<u;i++){let a=e[this.#w==null?i:this.#w[i]??i],o=a==null?void 0:A(a,t.dataKey);if(o===void 0){n[i]=NaN;continue}r=!0;let s=typeof o==`number`&&Number.isFinite(o)?o:NaN;n[i]=s,Number.isNaN(s)||(s<p&&(p=s),s>m&&(m=s),Number.isInteger(s)||(h=!1))}v(u===0||r,M(dn[t.mark],`dataKey`,t.dataKey,e)),this.#O.set(t.dataKey,n)}this.#k=p===1/0?0:p,this.#A=m===-1/0?0:m,this.#j=h;let g=this.#r.zKey;if(this.#e===`scatter`&&g!=null){let t=new Float64Array(u),n=1/0,r=-1/0,i=!1;for(let a=0;a<u;a++){let o=e[this.#w==null?a:this.#w[a]??a],s=o==null?void 0:A(o,g);s!==void 0&&(i=!0);let c=typeof s==`number`&&Number.isFinite(s)?s:NaN;t[a]=c,Number.isNaN(c)||(c<n&&(n=c),c>r&&(r=c))}v(u===0||i,M(`ScatterPlot.Root`,`zKey`,g,e)),this.#Z=t,this.#Q=n===1/0?[0,1]:jt([n,r],5)}else this.#Z=/* @__PURE__ */ new Float64Array;this.#ie=null,this.#ce=null,this.#N=this.#r.stacked?on(r.map(e=>this.#O.get(e.dataKey)??/* @__PURE__ */ new Float64Array)):null,this.#H=it({pointCount:u,columnCount:Math.max(1,Math.round(this.#Y.width*this.#y)),wasDecimated:this.#H});let _=this.#J;if(_!=null){for(let e of this.#n.seriesMeta())if(_.inputs.get(e.dataKey)!==un(e)){this.#J=null;break}}this.#De(r,f,d);let y=this.#ut();y!=null&&this.#gt(Math.min(y,Math.max(0,u-1)),{viaKeyboard:this.#pe,notify:!1}),this.#bt({force:!0})}#De(e,t,n){let r=performance.now(),i=this.#Oe(),a=!this.#R;this.#R=this.#R||this.#x>0,a||i===0?(this.#P.jump(this.#je()),this.#F.jump(this.#Me())):(this.#P.aim(this.#je(),r),this.#F.aim(this.#Me(),r));let o=this.#x>0&&this.#x<=2500&&n,s=/* @__PURE__ */ new Set,c=/* @__PURE__ */ new Set,l=(e,t,n)=>{s.add(e);let a=this.#I.get(e);a??(a=new cn,this.#I.set(e,a));let c=o&&n&&a.values().length===t.length;a.retarget(t,{duration:c?i:0,now:r})};e.forEach((e,n)=>{c.add(e.dataKey);let i=t.has(e.dataKey);if(this.#N==null?l(e.dataKey,this.#O.get(e.dataKey)??/* @__PURE__ */ new Float64Array,i):(l(`${e.dataKey}:lower`,this.#N.lower[n]??/* @__PURE__ */ new Float64Array,i),l(`${e.dataKey}:upper`,this.#N.upper[n]??/* @__PURE__ */ new Float64Array,i)),!this.#L.has(e.dataKey)&&this.#x>0){let t=new cn,n=this.#ke();t.retarget([0],{duration:0,now:r}),(this.#h||n===0)&&t.retarget([1],{duration:this.#h?n:0,now:r}),this.#L.set(e.dataKey,t)}});for(let e of this.#I.keys())s.has(e)||this.#I.delete(e);for(let e of this.#L.keys())c.has(e)||this.#L.delete(e)}#Oe(){return!this.#p&&!this.#m?0:this.#ke()}#ke(){return!this.#r.animate||this.#Ae()?0:280}#Ae(){return this.#f!=null&&Xe(this.#f)}#je(){let[e,t]=this.#r.yDomain,n,r;if(this.#N==null?this.#e===`line`||this.#e===`scatter`?(n=this.#k,r=this.#A):(n=Math.min(0,this.#k),r=Math.max(0,this.#A)):(n=Math.min(0,this.#N.min),r=Math.max(0,this.#N.max)),typeof e==`number`&&(n=e),typeof t==`number`&&(r=t),this.#x===0)return[0,1];let i=this.#e===`bar`||this.#e===`area`?Mt([n,r],5):jt([n,r],5);return[typeof e==`number`?e:i[0],typeof t==`number`?t:i[1]]}#Me(){if(this.#x===0)return[0,1];let e=this.#S[0]??0,t=this.#S[this.#x-1]??0;return e===t?[e-.5,t+.5]:this.#e===`scatter`?jt([e,t],5):[e,t]}#Ne(){return this.#e===`scatter`&&this.#r.zKey!=null}#Pe(){return this.#e===`bar`&&this.#r.orientation===`horizontal`}#Fe(){return`${dn[this.#e].split(`.`)[0]??`Chart`}.Root`}#Ie(e,t){let n=this.#q;n??(n=this.#t.canvas.ownerDocument.createElement(`canvas`),this.#q=n),(n.width!==e||n.height!==t)&&(n.width=e,n.height=t);let r=n.getContext(`2d`);return r==null?null:{canvas:n,ctx:r}}#Le(){this.#ve=!0,this.#g=!0,this.#ze()}#Re(){this.#ze()}#ze(){this.#_e||this.#be||(this.#_e=!0,this.#ye=requestAnimationFrame(()=>{this.#_e=!1,this.#ye=0,this.#Be()}))}#Be(){if(!this.#be){if(this.flushIngest(),this.#ve&&!this.#p&&!this.#m)this.#g&&(this.#g=!1,this.#Ge());else if(this.#ve){this.#ve=!1,this.#g=!1;let e=performance.now(),t=!1;t=this.#P.tick(e)||t,t=this.#F.tick(e)||t;for(let n of this.#I.values())t=n.tick(e)||t;for(let n of this.#L.values())t=n.tick(e)||t;if(t=this.#te.tick(e)||t,this.#ee.tick(e)){t=!0;let e=this.#ee.values();this.#$={yaw:e[0]??this.#$.yaw,pitch:e[1]??this.#$.pitch}}this.#_>0&&this.#v>0&&this.#He(),this.#Ge(),t=this.#Qe(e)||t,t&&this.#Le()}this.#Tt()}}#Ve(){return typeof devicePixelRatio==`number`&&devicePixelRatio>0?Math.min(devicePixelRatio,3):1}#He(){let e=this.#t.root,t=`${Le(e.ownerDocument.documentElement)}|${this.#y}|${this.#r.orientation}`;if(this.#J?.signature===t)return;let n=this.#Ue();if(n==null)return;let r=this.#we(),i=/* @__PURE__ */ new Map,a=/* @__PURE__ */ new Map,o=/* @__PURE__ */ new Map;for(let e of this.#n.seriesMeta()){let t=Z(n,e.colorInput);if(i.set(e.dataKey,t),a.set(e.dataKey,un(e)),r!=null&&e.mark===`bar`&&e.texture!==`solid`){let i=Je(r,{texture:e.texture,color:t,ink:n.resolve(Ue(t)),devicePixelRatio:this.#y,orientation:this.#r.orientation});i!=null&&o.set(e.dataKey,i)}}this.#J={signature:t,resolver:n,series:i,inputs:a,barTextures:o,chrome:Ie(n),fontFamily:n.fontFamily}}#Ue(){let e=this.#t.root,t=e.ownerDocument.defaultView;return t==null?null:Fe(this.#t.plot,{computed:t.getComputedStyle(e),parseContext:Me(e.ownerDocument)})}#We(e){let t=this.#J?.signature??``;t!==this.#se&&(this.#oe.clear(),this.#se=t);let n=this.#oe.get(e);if(n!=null)return n;let r=this.#J?.resolver??this.#Ue(),i=r==null?e:Z(r,e);return this.#oe.set(e,i),i}#Ge(){let e=this.#n.getSnapshot(),t=this.#Ne(),n=this.#Pe(),r=!t&&e.xAxis!=null,i=!t&&e.yAxis!=null,a=n?r:i,o=(n?i:r)?24:8,s=Math.max(0,this.#v-8-o);this.#Y={left:8,top:8,width:Math.max(0,this.#_-16),height:s};let c=8;if(a){c=40;let e=this.#J==null?null:this.#we();if(e!=null&&this.#J!=null){e.font=`11px ${this.#J.fontFamily}`;let t=0,r=n?this.#Ze().map(e=>e.text):this.#Xe().map(e=>e.text);for(let n of r){let r=e.measureText(n).width;r>t&&(t=r)}c=Math.ceil(t)+14}}this.#Y={left:c,top:8,width:Math.max(0,this.#_-c-8),height:s};let l=n?this.#Y.top:this.#Y.left,u=n?this.#Y.top+this.#Y.height:this.#Y.left+this.#Y.width;this.#X=this.#r.xScale===`band`?xt({count:this.#x,rangeStart:l,rangeEnd:u,paddingInner:.2,paddingOuter:.1}):this.#r.xScale===`point`?xt({count:this.#x,rangeStart:l,rangeEnd:u,paddingInner:1,paddingOuter:.5}):null,this.#H=it({pointCount:this.#x,columnCount:Math.max(1,Math.round(this.#Y.width*this.#y)),wasDecimated:this.#H})}#Ke(){let e=this.#P.values();return bt([e[0]??0,e[1]??1],[this.#Y.top+this.#Y.height,this.#Y.top])}#qe(){let e=this.#P.values(),t=this.#Pe()?[this.#Y.left,this.#Y.left+this.#Y.width]:[this.#Y.top+this.#Y.height,this.#Y.top];return bt([e[0]??0,e[1]??1],t)}#Je(){let e=this.#F.values();return bt([e[0]??0,e[1]??1],[this.#Y.left,this.#Y.left+this.#Y.width])}#Ye(e){let t=this.#X;if(t!=null)return Ct(t,e);let{k:n,b:r}=this.#Je();return(this.#S[e]??0)*n+r}#Xe(){let e=this.#n.getSnapshot(),t=this.#P.values(),n=Et([t[0]??0,t[1]??1],e.yAxis?.tickCount??5,{integer:this.#j}),r=e.yAxis?.tickFormat,i=n.length>1?U(Math.abs((n[1]??0)-(n[0]??0))):void 0;return n.map(e=>({value:e,text:r==null?H(e,i==null?void 0:{maximumFractionDigits:i}):r(e)}))}#Ze(){let e=this.#n.getSnapshot(),t=e.xAxis?.tickFormat;if(this.#X!=null){let e=this.#Pe(),n=e?this.#Y.height:this.#Y.width,r=Math.max(1,Math.floor(n/(e?15:60))),i=Math.max(1,Math.ceil(this.#x/r)),a=[];for(let e=0;e<this.#x;e+=i){let n=this.#C[e]??``;a.push({index:e,value:e,text:t==null?q(n,{datasetHasTimeOfDay:this.#E}):t(n)})}return a}let n=this.#F.values(),r=[n[0]??0,n[1]??1],i=e.xAxis?.tickCount??Math.max(2,Math.floor(this.#Y.width/90));if(this.#r.xScale===`time`){let e=At(r);return kt(r,i).map(n=>({index:null,value:n,text:t==null?e(n):t(new Date(n))}))}let a=Et(r,i,{integer:this.#M}),o=a.length>1?U(Math.abs((a[1]??0)-(a[0]??0))):void 0;return a.map(e=>({index:null,value:e,text:t==null?H(e,o==null?void 0:{maximumFractionDigits:o}):t(e)}))}#Qe(e){let t=this.#we(),n=this.#J;if(t==null||n==null||this.#_<=0||this.#v<=0)return!1;let r=Math.min(50,Math.max(0,e-this.#V));this.#V=e;let i=this.#t.canvas,a=Math.round(this.#_*this.#y),o=Math.round(this.#v*this.#y);(i.width!==a||i.height!==o)&&(i.width=a,i.height=o),t.setTransform(this.#y,0,0,this.#y,0,0),t.clearRect(0,0,this.#_,this.#v);let s=this.#n.getSnapshot(),c=this.#Y;if(c.width<=0||c.height<=0)return!1;let l=this.#Ke(),u=this.#Je(),d=this.#n.seriesSpecs(),f=this.#Ne(),p=this.#Oe()===0,m=s.xAxis!=null||s.yAxis!=null||s.grid!=null,h=f||!m?[]:this.#$e(t,n.fontFamily),g=f||!m?[]:this.#et(t,n.fontFamily),_=hn(this.#z,h,r,p);_=hn(this.#B,g,r,p)||_;let v=this.#W;if(v.target===1){if(e-this.#G>fn)v.target=0;else if(this.#K==null){let t=fn-(e-this.#G)+17;this.#K=setTimeout(()=>{this.#K=null,this.#Le()},t)}}if(p)v.alpha=v.target;else{let e=1-(1-(v.target>v.alpha?.16:.08))**(r/16.67);v.alpha+=(v.target-v.alpha)*e,Math.abs(v.target-v.alpha)<.02&&(v.alpha=v.target)}v.alpha!==v.target&&(_=!0);let y=this.#Pe(),b=y?this.#qe():l,x=e=>this.#X==null?e*u.k+u.b:Ct(this.#X,e),S=e=>e*b.k+b.b,C=[...this.#z.entries()].map(([e,t])=>({position:x(e),alpha:t.alpha})),w=[...this.#B.entries()].map(([e,t])=>({position:S(e),alpha:t.alpha}));if(s.grid!=null&&!f){let e=s.grid.lines??(y?`vertical`:`horizontal`),r=y?C:w,i=y?w:C;Pt(t,{plot:c,color:n.chrome.grid,xLines:e===`horizontal`?[]:i,yLines:e===`vertical`?[]:r})}let T=Math.min(40,c.width*.25),E=t,D=null;v.alpha>.01&&T>1&&(D=this.#Ie(a,o),D!=null&&(D.ctx.setTransform(this.#y,0,0,this.#y,0,0),D.ctx.clearRect(0,0,this.#_,this.#v),E=D.ctx)),E.save(),E.beginPath(),E.rect(c.left,c.top,c.width,c.height+1),E.clip();let O=null;if(this.#e===`bar`?y?this.#ot(E,d):this.#at(E,d,l):this.#e===`scatter`?O=this.#xt(E,d,l):this.#st(E,d,l),E.restore(),D!=null){E.save(),E.globalCompositeOperation=`destination-out`;let e=E.createLinearGradient(c.left,0,c.left+T,0);e.addColorStop(0,`rgba(0, 0, 0, ${v.alpha})`),e.addColorStop(1,`rgba(0, 0, 0, 0)`),E.fillStyle=e,E.fillRect(c.left,c.top,T,c.height+1),E.restore(),t.drawImage(D.canvas,0,0,this.#_,this.#v)}O!=null&&tn(t,{textColor:n.chrome.tickText,fontFamily:n.fontFamily,plot:c,center:O.center,axes:O.axes}),this.#e===`bar`&&this.#x>0&&(y?It(t,{plot:c,color:n.chrome.baseline,x:S(0)}):Ft(t,{plot:c,color:n.chrome.baseline,y:S(0)}));for(let e of f?[]:s.referenceLines){let r=S(e.y);if(y?r<c.left||r>c.left+c.width:r<c.top||r>c.top+c.height)continue;let i=e.color==null?n.chrome.reference:this.#We(e.color);y?rn(t,{plot:c,color:i,textColor:n.chrome.tickText,x:r,label:e.label,fontFamily:n.fontFamily}):nn(t,{plot:c,color:i,textColor:n.chrome.tickText,y:r,label:e.label,fontFamily:n.fontFamily})}let k=s.xAxis==null||f?[]:[...this.#z.entries()].map(([e,t])=>({position:x(e),text:t.text,alpha:t.alpha})),A=s.yAxis==null||f?[]:[...this.#B.entries()].map(([e,t])=>({position:S(e),text:t.text,alpha:t.alpha})),j=y?A:k,M=y?k:A;return(j.length>0||M.length>0)&&an(t,{plot:c,color:n.chrome.tickText,fontFamily:n.fontFamily,xLabels:j,yLabels:M}),_}#$e(e,t){e.font=`11px ${t}`;let n=this.#Pe(),r=this.#Je(),i=[],a=-1/0;for(let t of this.#Ze()){let o=t.index!=null&&this.#X!=null,s=o&&this.#X!=null?Ct(this.#X,t.index??0):t.value*r.k+r.b,c=n?15/2:e.measureText(t.text).width/2,l=n?2:8;s-c<a+l||(a=s+c,i.push({key:o?t.index??0:t.value,text:t.text}))}return i}#et(e,t){let n=this.#Xe();if(!this.#Pe())return n.map(e=>({key:e.value,text:e.text}));e.font=`11px ${t}`;let r=this.#qe(),i=[],a=-1/0;for(let t of n){let n=t.value*r.k+r.b,o=e.measureText(t.text).width/2;n-o<a+8||(a=n+o,i.push({key:t.value,text:t.text}))}return i}#tt(e,t,n){let r=t===`value`?e.dataKey:`${e.dataKey}:${t}`;if(!this.#H&&this.#x<=2500){let e=this.#I.get(r);if(e!=null&&e.values().length===this.#x)return e.values()}return t===`value`?this.#O.get(e.dataKey)??/* @__PURE__ */ new Float64Array:(t===`lower`?this.#N?.lower:this.#N?.upper)?.[n]??/* @__PURE__ */ new Float64Array}#nt(e){return this.#L.get(e)?.values()[0]??1}#rt(e,t){if(e==null)return 0;let n=e[t]??0;return Number.isNaN(n)?0:n}#it(e,t,n){let r=this.#N;if(r==null)return!0;let i=r.lower[e]?.[t]??NaN,a=r.upper[e]?.[t]??NaN;if(Number.isNaN(i)||Number.isNaN(a))return!1;let o=i<0,s=(o?r.negativeEnd:r.positiveEnd)[t]??-1;if(s<0)return!1;let c=(o?r.lower:r.upper)[s]?.[t]??NaN;return Se({lower:i,upper:a,pileOuter:c,toPixel:n})}#at(e,t,n){let r=this.#X,i=this.#J;if(r==null||i==null||this.#x===0||t.length===0)return;let a=this.#N!=null,o=a?1:t.length,s=r.bandwidth>=8*o?2:+(r.bandwidth>=3*o),c=(r.bandwidth-s*(o-1))/o,l=ve({step:r.step,slot:c}),u=e=>e*n.k+n.b;t.forEach((t,n)=>{let d=this.#nt(t.dataKey),f=[],p=a?this.#tt(t,`lower`,n):null,m=a?this.#tt(t,`upper`,n):this.#tt(t,`value`,n);for(let e=0;e<this.#x;e++){let t=m[e]??NaN;if(Number.isNaN(t))continue;let i=this.#rt(p,e),h=a?St(r,e)+(r.bandwidth-l)/2:St(r,e)+(r.bandwidth-(c*o+s*(o-1)))/2+n*(c+s)+(c-l)/2,g=xe({lower:i,upper:t,toPixel:u,reveal:d,gap:a?s:0});f.push({x:h,width:l,baselineY:g.baseline,valueY:g.value,rounded:this.#it(n,e,u)})}Lt(e,{fill:i.barTextures.get(t.dataKey)??i.series.get(t.dataKey)??`currentColor`,rects:f})})}#ot(e,t){let n=this.#X,r=this.#J;if(n==null||r==null||this.#x===0||t.length===0)return;let i=this.#qe(),a=this.#N!=null,o=a?1:t.length,s=n.bandwidth>=8*o?2:+(n.bandwidth>=3*o),c=(n.bandwidth-s*(o-1))/o,l=ve({step:n.step,slot:c}),u=e=>e*i.k+i.b;t.forEach((t,i)=>{let d=this.#nt(t.dataKey),f=[],p=a?this.#tt(t,`lower`,i):null,m=a?this.#tt(t,`upper`,i):this.#tt(t,`value`,i);for(let e=0;e<this.#x;e++){let t=m[e]??NaN;if(Number.isNaN(t))continue;let r=this.#rt(p,e),h=a?St(n,e)+(n.bandwidth-l)/2:St(n,e)+(n.bandwidth-(c*o+s*(o-1)))/2+i*(c+s)+(c-l)/2,g=xe({lower:r,upper:t,toPixel:u,reveal:d,gap:a?s:0});f.push({y:h,height:l,baselineX:g.baseline,valueX:g.value,rounded:this.#it(i,e,u)})}Rt(e,{fill:r.barTextures.get(t.dataKey)??r.series.get(t.dataKey)??`currentColor`,rects:f})})}#st(e,t,n){let r=this.#J;if(r==null||this.#x===0)return;let i=this.#Je(),a=this.#X,o=e=>a==null?(this.#S[e]??0)*i.k+i.b:Ct(a,e);t.forEach((t,i)=>{let a=r.series.get(t.dataKey)??`currentColor`,s=this.#nt(t.dataKey);if(e.save(),s<1&&(e.beginPath(),e.rect(this.#Y.left,0,this.#Y.width*s,this.#v),e.clip()),this.#H){this.#ct(e,t,i,a,n),e.restore();return}let c=t.mark===`area`,l=this.#tt(t,this.#N==null?`value`:`upper`,i),u=this.#N==null?null:this.#tt(t,`lower`,i),d=e=>!Number.isNaN(l[e]??NaN),f=[];for(let e=0;e<this.#x;e++)(!t.connectNulls||d(e))&&f.push(e);let p=e=>(l[e]??0)*n.k+n.b;if(c){let r=u==null?()=>0*n.k+n.b:e=>(u[e]??0)*n.k+n.b;Bt(e,{color:a,curve:t.curve,indexes:f,xAt:o,y0At:r,y1At:p,definedAt:d})}else zt(e,{color:a,curve:t.curve,indexes:f,xAt:o,yAt:p,definedAt:d}),t.markers&&this.#Y.width/this.#x>=12&&Yt(e,{color:a,surface:r.chrome.surface,shape:this.#n.seriesShape(t.dataKey),indexes:f,xAt:o,yAt:p,definedAt:d});e.restore()})}#ct(e,t,n,r,i){let a=Math.max(1,Math.round(this.#Y.width*this.#y)),o=e=>this.#Y.left+(e+.5)/this.#y;if(t.mark===`area`){let s=this.#lt(`${t.dataKey}:upper`,this.#tt(t,this.#N==null?`value`:`upper`,n),a),c=this.#N==null?null:this.#lt(`${t.dataKey}:lower`,this.#tt(t,`lower`,n),a);c==null?Ht(e,{color:r,lowerColumns:yn(s,0),upperColumns:s,columnToX:o,valueK:i.k,valueB:i.b}):Ht(e,{color:r,lowerColumns:c,upperColumns:s,columnToX:o,valueK:i.k,valueB:i.b});return}let s=this.#lt(t.dataKey,this.#tt(t,`value`,n),a);Vt(e,{color:r,columns:s,columnToX:o,valueK:i.k,valueB:i.b})}#lt(e,t,n){let r=this.#F.values(),i=`${r[0]??0}:${r[1]??1}:${n}`,a=this.#U.get(e);if(a!=null&&a.key===i)return a.columns;let o=[r[0]??0,r[1]??1],s=bt(o,[0,n]),c=at({xs:this.#S,values:t,startIndex:0,endIndex:this.#x-1,positionK:s.k,positionB:s.b,columnCount:n});return this.#U.set(e,{key:i,columns:c}),c}#ut(){if(this.#x===0)return null;let e;return e=this.#de===void 0?this.#ue:this.#de==null?null:this.#ft(this.#de),e==null?null:Math.min(Math.max(0,e),this.#x-1)}#dt(e){return this.#w==null?e:this.#w[e]??e}#ft(e){if(this.#b.length===0)return null;let t=Math.min(Math.max(0,e),this.#b.length-1);if(this.#T==null)return t;let n=this.#T[t]??-1;return n===-1?null:n}#pt(e){if(e<0||e>=this.#x)return``;let{xScale:t}=this.#r;if(t===`band`||t===`point`)return this.#C[e]??``;let n=this.#S[e]??0;return t===`time`?new Date(n):n}#mt(e,t){if(this.#x===0)return null;let n=this.#X;if(n!=null)return Tt(n,this.#Pe()?t:e);let{k:r,b:i}=this.#Je();if(r===0)return 0;let a=e;if(this.#H){let t=Math.floor((e-this.#Y.left)*this.#y);a=this.#Y.left+(t+.5)/this.#y}return ot(this.#S,this.#x,(a-i)/r)}#ht(e,t,n){let r=this.#n.seriesSpecs(),i=this.#Pe(),a=this.#X;if(this.#e===`bar`&&this.#N==null&&a!=null&&r.length>1){let o=(i?n:t)-St(a,e),s=Math.floor(o/Math.max(1,a.bandwidth)*r.length);return r[Math.min(r.length-1,Math.max(0,s))]?.dataKey??null}let{k:o,b:s}=i?this.#qe():this.#Ke(),c=i?t:n,l=this.#N;if(this.#e===`bar`&&l!=null)for(let t=0;t<r.length;t++){let n=l.lower[t]?.[e]??NaN,i=l.upper[t]?.[e]??NaN;if(Number.isNaN(n)||Number.isNaN(i)||n===i)continue;let a=n*o+s,u=i*o+s;if(c>=Math.min(a,u)&&c<=Math.max(a,u))return r[t]?.dataKey??null}let u=null,d=1/0;return r.forEach((t,n)=>{let r=(this.#N==null?this.#O.get(t.dataKey):this.#N.upper[n])?.[e]??NaN;if(Number.isNaN(r))return;let i=Math.abs(r*o+s-c);i<d&&(d=i,u=t.dataKey)}),u}#gt(e,t){let n=e==null||this.#x===0?null:Math.min(Math.max(0,e),this.#x-1),r=this.#de!==void 0;if(t.notify&&n!==this.#ut()){let e=n==null?null:this.#dt(n);if(this.#i.onActiveIndexChange?.(e),r){this.#fe={index:e,viaKeyboard:t.viaKeyboard};return}}this.#pe=t.viaKeyboard,r||(this.#ue=n),this.#bt(),this.#Re()}#_t=null;#vt=!1;#yt=null;#bt(e={force:!1}){let t=this.#ut();if(!e.force&&t===this.#_t&&this.#pe===this.#vt&&this.#le===this.#yt)return;if(this.#_t=t,this.#vt=this.#pe,this.#yt=this.#le,t==null||this.#x===0){this.#n.publishHover(null);return}let n=this.#dt(t),r=this.#b[n]??{},i=this.#n.getSnapshot().series.map(e=>{let n=this.#O.get(e.dataKey)?.[t]??NaN;return{dataKey:e.dataKey,label:e.label,value:Number.isNaN(n)?null:n,color:e.color}});this.#r.stacked&&i.reverse(),this.#e===`scatter`&&(i=this.#le==null?i.filter(e=>e.value!=null):i.filter(e=>e.dataKey===this.#le));let a={index:n,xValue:this.#pt(t),datum:r,points:i,viaKeyboard:this.#pe};if(this.#Ne()){let e=this.#Z[t]??NaN;a.zValue=Number.isNaN(e)?null:e}this.#n.publishHover(a)}#xt(e,t,n){let r=this.#J;if(r==null||this.#x===0||t.length===0)return null;if(this.#Ne())return this.#St(e,t);let i=this.#Je(),a=t.map((e,t)=>{let n=this.#tt(e,`value`,t),r=[];for(let e=0;e<this.#x;e++)Number.isNaN(n[e]??NaN)||r.push(e);return r}),o=a.reduce((e,t)=>e+t.length,0);return t.forEach((t,s)=>{let c=this.#tt(t,`value`,s),l=a[s]??[];e.save(),e.globalAlpha=this.#nt(t.dataKey),Qt(e,{color:r.series.get(t.dataKey)??`currentColor`,surface:r.chrome.surface,shape:this.#n.seriesShape(t.dataKey),totalPointCount:o,indexes:l,xAt:e=>(this.#S[e]??0)*i.k+i.b,yAt:e=>(c[e]??0)*n.k+n.b,radiusAt:()=>4}),e.restore()}),null}#St(e,t){let n=this.#J;if(n==null)return null;let r=this.#Y,i=ct(this.#$),a=r.left+r.width/2,o=r.top+r.height/2,s=this.#te.values(),c=s[0]??1,l=s[1]??1,u=.85-.22*c-.11*l,d=Math.min(r.width,r.height)/2*u,f=this.#F.values(),p=[f[0]??0,f[1]??1],m=this.#P.values(),h=[m[0]??0,m[1]??1],g=this.#Q,_=t.map(e=>this.#nt(e.dataKey)),v=this.#te.values(),y=v[0]??1,b=v[1]??1,x=(e,t,n)=>{let r=lt(e,t,n,i);return{x:a+r.x*d,y:o-r.y*d}},S=ft.map(([e,t,n])=>x(e,t,n)),C=t[0],w=t.length===1&&C!=null?C.dataKey:`y`,T=[{label:this.#r.xKey,alpha:1,from:x(-1,-y,-b),to:x(1,-y,-b)},{label:w,alpha:y,from:x(-1,-1,-b),to:x(-1,1,-b)},{label:this.#r.zKey??`z`,alpha:b,from:x(-1,-y,-1),to:x(-1,-y,1)}];en(e,{gridColor:n.chrome.grid,axisColor:n.chrome.baseline,corners:S,edges:pt,cubeAlpha:b,axes:T});let E=this.#x*t.length,D=this.#ie;(D==null||D.screenX.length<E)&&(D={screenX:new Float64Array(E),screenY:new Float64Array(E),radius:new Float64Array(E),seriesIndex:new Int32Array(E),pointIndex:new Int32Array(E),depths:new Float64Array(E),count:0});let O=D.depths,k=0;t.forEach((e,t)=>{let n=this.#tt(e,`value`,t);for(let e=0;e<this.#x;e++){let r=n[e]??NaN,s=this.#Z[e]??NaN;if(Number.isNaN(r)||Number.isNaN(s))continue;let c=lt(dt(this.#S[e]??0,p),dt(r,h)*y,dt(s,g)*b,i);D.screenX[k]=a+c.x*d,D.screenY[k]=o-c.y*d,D.radius[k]=4*c.scale,D.seriesIndex[k]=t,D.pointIndex[k]=e,O[k]=c.depth,k+=1}}),D.count=k,this.#ie=D,this.#ae.length<k&&(this.#ae=new Int32Array(E));let A=this.#ae.subarray(0,k);for(let e=0;e<k;e++)A[e]=e;A.sort((e,t)=>(O[t]??0)-(O[e]??0));let j=t.map(e=>this.#n.seriesShape(e.dataKey));return $t(e,{count:k,order:A,screenX:D.screenX,screenY:D.screenY,radius:D.radius,colorAt:e=>{let r=t[D.seriesIndex[e]??0];return r==null?`currentColor`:n.series.get(r.dataKey)??`currentColor`},shapeAt:e=>j[D.seriesIndex[e]??0]??`circle`,alphaAt:e=>_[D.seriesIndex[e]??0]??1,surface:n.chrome.surface}),{center:{x:a,y:o},axes:T}}#Ct(e,t){let n=this.#n.seriesSpecs(),r=576,i=null;if(this.#Ne()){let a=this.#ie;if(a==null)return null;for(let o=0;o<a.count;o++){let s=(a.screenX[o]??0)-e,c=(a.screenY[o]??0)-t,l=s*s+c*c;if(l<r){let e=n[a.seriesIndex[o]??0];if(e==null)continue;r=l,i={seriesKey:e.dataKey,index:a.pointIndex[o]??0,screenX:a.screenX[o]??0,screenY:a.screenY[o]??0}}}return i}let a=this.#Je(),o=this.#Ke();for(let s of n){let n=this.#O.get(s.dataKey);if(n!=null)for(let c=0;c<this.#x;c++){let l=n[c]??NaN;if(Number.isNaN(l))continue;let u=(this.#S[c]??0)*a.k+a.b,d=l*o.k+o.b,f=u-e,p=d-t,m=f*f+p*p;m<r&&(r=m,i={seriesKey:s.dataKey,index:c,screenX:u,screenY:d})}}return i}#wt(e){let t=this.#n.seriesSpecs();if(this.#Ne()){let t=this.#ie;if(t==null)return null;for(let n=0;n<t.count;n++)if((t.pointIndex[n]??-1)===e)return{x:t.screenX[n]??0,y:t.screenY[n]??0};return null}let n=this.#Je(),r=this.#Ke();for(let i of t){let t=this.#O.get(i.dataKey)?.[e]??NaN;if(!Number.isNaN(t))return{x:(this.#S[e]??0)*n.k+n.b,y:t*r.k+r.b}}return null}#Tt(){let{hover:e,tooltip:t}=this.#t;if(e==null)return;let{crosshair:n,band:r,markers:i}=e,a=this.#ut(),o=a!=null&&this.#x>0,s=this.#e===`bar`,c=this.#e===`scatter`;if(n.style.opacity=o&&!s&&!c?`1`:`0`,r.style.opacity=o&&s?`1`:`0`,i.style.opacity=o&&!s?`1`:`0`,t!=null&&(t.style.opacity=o?`1`:`0`),!o)return;let l=this.#Y;if(c){let e=this.#ce??this.#wt(a);if(e==null){i.style.opacity=`0`,t!=null&&(t.style.opacity=`0`);return}for(;i.children.length>1;)i.lastElementChild?.remove();i.children.length===0&&i.appendChild(_n(i.ownerDocument));let n=i.children[0];if(n instanceof HTMLElement){let t=this.#n.getSnapshot().series,r=this.#le==null?t.find(e=>{let t=this.#O.get(e.dataKey)?.[a]??NaN;return!Number.isNaN(t)}):t.find(e=>e.dataKey===this.#le);n.style.opacity=`1`,vn(n,r?.shape??`circle`,r?.color??`currentColor`),n.style.transform=`translate3d(${e.x}px, ${e.y}px, 0)`}this.#Et(e.x,e.y);return}let u=this.#Ye(a),d=this.#Pe();if(s){let e=this.#X;if(e!=null){let t=wt(e,a),n=Math.max(1,t.size),i=t.start-(n-t.size)/2;d?(r.style.transform=`translate3d(${l.left}px, ${i}px, 0)`,r.style.width=`${l.width}px`,r.style.height=`${n}px`):(r.style.transform=`translate3d(${i}px, ${l.top}px, 0)`,r.style.width=`${n}px`,r.style.height=`${l.height}px`)}}else{n.style.transform=`translate3d(${u}px, ${l.top}px, 0)`,n.style.height=`${l.height}px`;let e=this.#n.getSnapshot().series;for(;i.children.length>e.length;)i.lastElementChild?.remove();for(;i.children.length<e.length;)i.appendChild(_n(i.ownerDocument));let t=this.#Ke();e.forEach((e,n)=>{let r=i.children[n];if(!(r instanceof HTMLElement))return;let o=this.#O.get(e.dataKey)?.[a]??NaN,s=this.#tt(e,this.#N==null?`value`:`upper`,n)[a]??NaN;Number.isNaN(o)||Number.isNaN(s)?r.style.opacity=`0`:(r.style.opacity=`1`,vn(r,e.shape,e.color),r.style.transform=`translate3d(${u}px, ${s*t.k+t.b}px, 0)`)})}s&&d&&this.#X!=null?this.#Et(this.#me??l.left+l.width/2,Ct(this.#X,a)):this.#Et(u,this.#he??l.top+8)}#Et(e,t){let n=this.#Y,r=this.#t.tooltip;if(r==null)return;let i=this.#ge,a=e+12;a+i.width>n.left+n.width&&e-12-i.width>=n.left&&(a=e-12-i.width);let o=Math.max(0,Math.min(t-i.height/2,n.top+n.height-i.height));r.style.transform=`translate3d(${a}px, ${o}px, 0)`}};const mn=e=>e===3?{yaw:.65,pitch:-.35}:{yaw:0,pitch:0},hn=(e,t,n,r)=>{for(let t of e.values())t.target=0;for(let n of t){let t=e.get(n.key);t==null?e.set(n.key,{alpha:+!!r,target:1,text:n.text}):(t.target=1,t.text=n.text)}let i=1-.84**(n/16.67),a=1-.88**(n/16.67),o=!1;for(let[t,n]of e){if(r)n.alpha=n.target;else{let e=n.target>n.alpha?i:a;n.alpha+=(n.target-n.alpha)*e}n.target===1&&n.alpha>.98&&(n.alpha=1),n.target===0&&n.alpha<.03?e.delete(t):n.alpha!==n.target&&(o=!0)}return o},gn={circle:`circle(50%)`,square:`inset(8%)`,triangle:`polygon(50% 0%, 100% 100%, 0% 100%)`,diamond:`polygon(50% 0%, 100% 50%, 50% 100%, 0% 50%)`,"triangle-down":`polygon(0% 0%, 100% 0%, 50% 100%)`,plus:`polygon(33.33% 0%, 66.67% 0%, 66.67% 33.33%, 100% 33.33%, 100% 66.67%, 66.67% 66.67%, 66.67% 100%, 33.33% 100%, 33.33% 66.67%, 0% 66.67%, 0% 33.33%, 33.33% 33.33%)`,cross:`polygon(73.57% 2.86%, 97.14% 26.43%, 73.57% 50%, 97.14% 73.57%, 73.57% 97.14%, 50% 73.57%, 26.43% 97.14%, 2.86% 73.57%, 26.43% 50%, 2.86% 26.43%, 26.43% 2.86%, 50% 26.43%)`,star:`polygon(50% 2.45%, 61.8% 38.77%, 100% 38.77%, 69.1% 61.23%, 80.9% 97.55%, 50% 75.1%, 19.1% 97.55%, 30.9% 61.23%, 0% 38.77%, 38.2% 38.77%)`},_n=e=>{let t=e.createElement(`div`);t.setAttribute(`data-slot`,`chart-active-point`),t.style.position=`absolute`,t.style.width=`12px`,t.style.height=`12px`,t.style.left=`-6px`,t.style.top=`-6px`;let n=e.createElement(`div`);n.style.position=`absolute`,n.style.inset=`0`,n.style.backgroundColor=`var(--background-color-card)`;let r=e.createElement(`div`);return r.style.position=`absolute`,r.style.inset=`2px`,t.appendChild(n),t.appendChild(r),t},vn=(e,t,n)=>{let r=gn[t];e.setAttribute(`data-shape`,t);let[i,a]=e.children;i instanceof HTMLElement&&(i.style.clipPath=r),a instanceof HTMLElement&&(a.style.clipPath=r,a.style.backgroundColor=n)},yn=(e,t)=>({columnCount:e.columnCount,hasData:e.hasData,minValue:new Float64Array(e.columnCount).fill(t),maxValue:new Float64Array(e.columnCount).fill(t),inValue:new Float64Array(e.columnCount).fill(t),outValue:new Float64Array(e.columnCount).fill(t)}),bn=e=>e.replaceAll(`|`,`\\|`).replaceAll(/\s*\n\s*/g,` `),xn=e=>e instanceof Date?Number.isNaN(e.getTime())?`—`:e.toISOString():typeof e==`number`?Number.isFinite(e)?String(e):`—`:typeof e==`string`?bn(e):`—`,Sn=e=>typeof e==`number`&&Number.isFinite(e)?String(e):`—`,Cn=e=>`| ${e.join(` | `)} |`,wn=({data:e,xKey:t,series:n,zKey:r})=>{let i=[bn(t),...n.map(e=>bn(e.label)),...r==null?[]:[bn(r)]],a=e.map(e=>[xn(A(e,t)),...n.map(t=>Sn(A(e,t.dataKey))),...r==null?[]:[Sn(A(e,r))]]);return[Cn(i),Cn(i.map(()=>`---`)),...a.map(e=>Cn(e))].join(`
|
|
2
|
-
`)},Tn=(e,t)=>e==null?`var(${Te(t)})`:we(e)?`var(${Te(e)})`:e,En={"chart-1":`circle`,"chart-2":`square`,"chart-3":`triangle`,"chart-4":`diamond`,"chart-5":`triangle-down`,"chart-6":`plus`,"chart-7":`cross`,"chart-8":`star`,"chart-other":`circle`},Dn=(e,t)=>e??En[t],On={1:`chart-1`,2:`chart-2`,3:`chart-3`,4:`chart-4`,5:`chart-5`,6:`chart-6`,7:`chart-7`,8:`chart-8`,other:`chart-other`},kn=e=>{let t=/* @__PURE__ */ new Set;for(let n of e)n.seriesSlot!=null&&n.seriesSlot!==`other`&&t.add(On[n.seriesSlot]);let n=/* @__PURE__ */ new Map,r=new Set(t);for(let t of e){if(t.seriesSlot!=null){n.set(t.dataKey,On[t.seriesSlot]);continue}let e=De.find(e=>!r.has(e))??`chart-other`;n.set(t.dataKey,e),r.add(e)}return n};var An=class{#e=/* @__PURE__ */ new Set;#t={series:[],hover:null,grid:null,xAxis:null,yAxis:null,referenceLines:[],tooltip:null,orientation:`vertical`};#n=/* @__PURE__ */ new Map;#r=/* @__PURE__ */ new Map;#i=0;#a=null;#o=!1;#s=`vertical`;#c=null;#l=null;#u=/* @__PURE__ */ new Map;#d=/* @__PURE__ */ new Map;#f=null;#p=null;#m=!1;get hoverEver(){return this.#m}onSeriesChange=null;onPresentationChange=null;subscribe=e=>(this.#e.add(e),()=>{this.#e.delete(e)});getSnapshot=()=>this.#t;seriesSpecs(){return[...this.#n.values()].toSorted((e,t)=>e.sequence-t.sequence).map(e=>e.spec)}seriesShape(e){return this.#t.series.find(t=>t.dataKey===e)?.shape??En[`chart-other`]}registerSeries(e){let t=this.#r.get(e.dataKey)??this.#i++;return this.#r.set(e.dataKey,t),this.#n.set(e.dataKey,{spec:e,sequence:t}),this.#h({seriesChanged:!0}),()=>{this.#n.get(e.dataKey)?.spec===e&&(this.#n.delete(e.dataKey),this.#h({seriesChanged:!0}))}}setDecorative(e){this.#o!==e&&(this.#o=e,this.#h({seriesChanged:!0}))}setOrientation(e){this.#s!==e&&(this.#s=e,this.#h())}registerGrid(e){let t={lines:e};return this.#a=t,this.#h(),()=>{this.#a===t&&(this.#a=null,this.#h())}}registerXAxis(e){return this.#c=e,this.#h(),()=>{this.#c===e&&(this.#c=null,this.#h())}}registerYAxis(e){return this.#l=e,this.#h(),()=>{this.#l===e&&(this.#l=null,this.#h())}}registerReferenceLine(e,t){let n=this.#d.get(e)??this.#i++;return this.#d.set(e,n),this.#u.set(e,{spec:t,sequence:n}),this.#h(),()=>{this.#u.get(e)?.spec===t&&(this.#u.delete(e),this.#h())}}registerTooltip(e){return this.#f=e,this.#h(),()=>{this.#f===e&&(this.#f=null,this.#h())}}publishHover(e){this.#p!==e&&(this.#p=e,e!=null&&(this.#m=!0),this.#t={...this.#t,hover:e},this.#g())}seriesMeta(){let e=this.seriesSpecs(),t=kn(e);return e.map(e=>{let n=t.get(e.dataKey)??`chart-other`,r=this.#o?Ee:Tn(e.color,n),i=this.#o?Ee:e.color??n;return{dataKey:e.dataKey,label:e.label,mark:e.mark,color:r,colorInput:i,shape:Dn(e.shape,n),texture:e.texture}})}#h(e={seriesChanged:!1}){this.#t={series:this.seriesMeta(),hover:this.#p,grid:this.#a,xAxis:this.#c,yAxis:this.#l,referenceLines:[...this.#u.values()].toSorted((e,t)=>e.sequence-t.sequence).map(e=>e.spec),tooltip:this.#f,orientation:this.#s},this.#g(),e.seriesChanged?this.onSeriesChange?.():this.onPresentationChange?.()}#g(){for(let e of this.#e)e()}};const jn=`100%`,Mn=`300%`,Nn=[`near`,`far`],Pn=/* @__PURE__ */ new WeakMap,Fn=/* @__PURE__ */ new WeakMap,In=/* @__PURE__ */ new WeakMap;let Ln=null;const Rn=()=>{if(Ln==null){let e=new IntersectionObserver(()=>{},{scrollMargin:`0px`});Ln=`scrollMargin`in e,e.disconnect()}return Ln},zn=/auto|scroll/,Bn=e=>{let t=e.ownerDocument,n=t.defaultView;if(n==null)return null;for(let r=e.parentElement;r!=null&&r!==t.documentElement&&r!==t.body;r=r.parentElement){let e=n.getComputedStyle(r);if(zn.test(e.overflowY)||zn.test(e.overflowX))return r}return null},Vn=(e,t,n)=>new IntersectionObserver(t=>{for(let n of t)In.get(n.target)?.({band:e,inView:n.isIntersecting,rect:n.boundingClientRect});R()},{root:n,rootMargin:t,scrollMargin:t,threshold:0}),Hn=e=>{let t=Pn.get(e);return t??(t={near:Vn(`near`,jn,null),far:Vn(`far`,Mn,null),visible:Vn(`visible`,`0px`,null),count:0},Pn.set(e,t)),t.count+=1,t},Un=(e,t)=>{--t.count,!(t.count>0)&&(t.near.disconnect(),t.far.disconnect(),t.visible.disconnect(),Pn.get(e)===t&&Pn.delete(e))},Wn=(e,t)=>{let n=Fn.get(e);if(n!=null)return n;let r={near:Vn(`near`,jn,e),far:Vn(`far`,Mn,e),open:{near:!1,far:!1},elements:/* @__PURE__ */ new Set};return In.set(e,({band:e,inView:t})=>{if(e!==`visible`&&r.open[e]!==t){r.open[e]=t;for(let n of r.elements)t?r[e].observe(n):(r[e].unobserve(n),In.get(n)?.({band:e,inView:!1,rect:null}))}}),t.near.observe(e),t.far.observe(e),t.count+=1,Fn.set(e,r),r},Gn=(e,t,n,r)=>{t.elements.size>0||(t.near.disconnect(),t.far.disconnect(),n.near.unobserve(e),n.far.unobserve(e),In.delete(e),Fn.get(e)===t&&Fn.delete(e),Un(r,n))},Kn=(e,t)=>{if(typeof IntersectionObserver>`u`)return t({band:`near`,inView:!0,rect:null}),t({band:`far`,inView:!0,rect:null}),t({band:`visible`,inView:!0,rect:null}),R(),()=>{se(e)};let n=e.ownerDocument,r=Hn(n);In.set(e,t),r.visible.observe(e);let i=Rn()?null:Bn(e);if(i==null)return r.near.observe(e),r.far.observe(e),()=>{In.get(e)===t&&(In.delete(e),se(e),r.near.unobserve(e),r.far.unobserve(e),r.visible.unobserve(e),Un(n,r))};let a=Wn(i,r);a.elements.add(e);for(let t of Nn)a.open[t]&&a[t].observe(e);return()=>{In.get(e)===t&&(In.delete(e),se(e),a.elements.delete(e),a.near.unobserve(e),a.far.unobserve(e),r.visible.unobserve(e),Un(n,r),Gn(i,a,r,n))}},qn=u(null),Jn=e=>{let t=d(qn);return v(t,`${e} must be composed inside ${e.split(`.`)[0]}.Root — it registers into the chart it belongs to and renders nothing on its own.`),t},Yn=e=>_(e.subscribe,e.getSnapshot,e.getSnapshot),Xn=e=>{let t=l(3),n,r;return t[0]===e?(n=t[1],r=t[2]):(n=()=>e.getSnapshot().series,r=()=>e.getSnapshot().series,t[0]=e,t[1]=n,t[2]=r),_(e.subscribe,n,r)},Zn=e=>{let t=l(3),n,r;return t[0]===e?(n=t[1],r=t[2]):(n=()=>e.getSnapshot().hover,r=()=>e.getSnapshot().hover,t[0]=e,t[1]=n,t[2]=r),_(e.subscribe,n,r)},Qn=e=>{let t=l(3),n,r;return t[0]===e?(n=t[1],r=t[2]):(n=()=>e.getSnapshot().orientation,r=()=>e.getSnapshot().orientation,t[0]=e,t[1]=n,t[2]=r),_(e.subscribe,n,r)},$n=(e,t)=>{let n=Object.keys(e);return n.length===Object.keys(t).length&&n.every(n=>Object.hasOwn(t,n)&&Object.is(Reflect.get(e,n),Reflect.get(t,n)))},er=e=>{let[t,n]=g(e);return $n(t,e)?t:(n(e),e)},tr={},nr=(e,t)=>{for(let n of e){let e=A(n,t);if(e!=null)return e instanceof Date?`time`:typeof e==`number`?`linear`:`point`}return`point`},rr=[`auto`,`auto`],ir=(e,t,n)=>{let r=(n,r)=>{let i=e.createElement(`div`);return i.setAttribute(`data-slot`,`${t}-${n}`),i.setAttribute(`aria-hidden`,`true`),i.className=r,i},i=e.createElement(`canvas`);return i.setAttribute(`data-slot`,`${t}-canvas`),i.setAttribute(`aria-hidden`,`true`),i.className=`absolute inset-0 size-full`,{canvas:i,hover:n.hover?{crosshair:r(`crosshair`,`bg-neutral-500 pointer-events-none absolute left-0 top-0 w-px opacity-0`),band:r(`hover-band`,`bg-neutral-500/10 pointer-events-none absolute left-0 top-0 rounded-sm opacity-0`),markers:r(`markers`,`pointer-events-none absolute inset-0 opacity-0`)}:null}},ar={bar:`Bar`,line:`Line`,area:`Area`,scatter:`Point`},or=t=>{let i=l(211),a,o,s,c,u,d,f,y,S,C,w,T,E,D,O,k,A,j,M,N,P,F,I,te,ne,re,L,ie,R;i[0]===t?(a=i[1],o=i[2],s=i[3],c=i[4],u=i[5],d=i[6],f=i[7],y=i[8],S=i[9],C=i[10],w=i[11],T=i[12],E=i[13],D=i[14],O=i[15],k=i[16],A=i[17],j=i[18],M=i[19],N=i[20],P=i[21],F=i[22],I=i[23],te=i[24],ne=i[25],re=i[26],L=i[27],ie=i[28],R=i[29]):({kind:w,componentName:y,slotName:j,data:S,xKey:L,xScale:ie,zKey:R,dimensions:N,yDomain:P,stacked:F,orientation:I,animate:o,pending:te,mode:ne,activeIndex:a,onActiveIndexChange:T,onDatumActivate:D,className:f,children:d,ref:A,"data-slot":C,"aria-label":c,"aria-labelledby":u,"aria-hidden":s,tabIndex:re,onFocus:O,onBlur:E,style:M,...k}=t,i[0]=t,i[1]=a,i[2]=o,i[3]=s,i[4]=c,i[5]=u,i[6]=d,i[7]=f,i[8]=y,i[9]=S,i[10]=C,i[11]=w,i[12]=T,i[13]=E,i[14]=D,i[15]=O,i[16]=k,i[17]=A,i[18]=j,i[19]=M,i[20]=N,i[21]=P,i[22]=F,i[23]=I,i[24]=te,i[25]=ne,i[26]=re,i[27]=L,i[28]=ie,i[29]=R);let z=N===void 0?3:N,ce=P===void 0?rr:P,B=F!==void 0&&F,V=I===void 0?`vertical`:I,le=te!==void 0&&te,H=ne===void 0?`interactive`:ne,U=H===`interactive`,W=H===`decorative`,G=o??H!==`static`,[K]=g(Er),[ue,de]=g(!1),q=h(null),fe=h(null),me=h(!1),he=h(null),_e;i[30]===Symbol.for(`react.memo_cache_sentinel`)?(_e={near:!1,withinFar:!0,seen:!1,focused:!1},i[30]=_e):_e=i[30];let ve=h(_e),ye=h(null),be;i[31]===K.hoverEver?be=i[32]:(be=()=>K.hoverEver,i[31]=K.hoverEver,i[32]=be);let xe=_(K.subscribe,be,Dr),Se;i[33]!==S||i[34]!==L||i[35]!==R?(Se={data:S,xKey:L,zKey:R},i[33]=S,i[34]=L,i[35]=R,i[36]=Se):Se=i[36];let Ce=h(Se),we;i[37]!==y||i[38]!==w||i[39]!==K?(we=()=>({kind:w,componentName:y,store:K,engineRef:q,dataRef:Ce}),i[37]=y,i[38]=w,i[39]=K,i[40]=we):we=i[40];let[Te]=g(we),Ee,De;i[41]!==S||i[42]!==L||i[43]!==R?(Ee=()=>{Ce.current={data:S,xKey:L,zKey:R}},De=[S,L,R],i[41]=S,i[42]=L,i[43]=R,i[44]=Ee,i[45]=De):(Ee=i[44],De=i[45]),m(Ee,De);let Oe=h(null),ke=e(Oe,A),Ae=h(null),je=h(null),Me=p(),Ne;i[46]!==S||i[47]!==w||i[48]!==L||i[49]!==ie?(Ne=w===`bar`?`band`:ie??nr(S,L),i[46]=S,i[47]=w,i[48]=L,i[49]=ie,i[50]=Ne):Ne=i[50];let J=Ne;v(w!==`scatter`||S.length===0||J!==`point`,`${y}.Root requires numeric or Date x values — the "${L}" values are not numbers or dates, so they have no position on a continuous scatter axis.`);let[Y,X]=ce,Pe;i[51]!==S||i[52]!==J||i[53]!==L?(Pe=pe(S,L,J),i[51]=S,i[52]=J,i[53]=L,i[54]=Pe):Pe=i[54];let Fe=Pe,Z=Fe.hasTimeOfDay,Ie;i[55]!==X||i[56]!==Y?(Ie=[Y,X],i[55]=X,i[56]=Y,i[57]=Ie):Ie=i[57];let Le=R??null,Re;i[58]!==G||i[59]!==z||i[60]!==V||i[61]!==J||i[62]!==B||i[63]!==Ie||i[64]!==Le||i[65]!==L?(Re={xKey:L,xScale:J,yDomain:Ie,zKey:Le,dimensions:z,stacked:B,orientation:V,animate:G},i[58]=G,i[59]=z,i[60]=V,i[61]=J,i[62]=B,i[63]=Ie,i[64]=Le,i[65]=L,i[66]=Re):Re=i[66];let ze;i[67]===Symbol.for(`react.memo_cache_sentinel`)?(ze={onDatumActivate:null,onActiveIndexChange:null},i[67]=ze):ze=i[67];let Be;i[68]===Re?Be=i[69]:(Be={options:Re,callbacks:ze,controlledActiveIndex:void 0},i[68]=Re,i[69]=Be);let Ve=h(Be),He;i[70]!==a||i[71]!==G||i[72]!==z||i[73]!==U||i[74]!==T||i[75]!==D||i[76]!==V||i[77]!==J||i[78]!==B||i[79]!==L||i[80]!==X||i[81]!==Y||i[82]!==R?(He=()=>{Ve.current={options:{xKey:L,xScale:J,yDomain:[Y,X],zKey:R??null,dimensions:z,stacked:B,orientation:V,animate:G},callbacks:U?{onDatumActivate:D??null,onActiveIndexChange:T??null}:{onDatumActivate:null,onActiveIndexChange:null},controlledActiveIndex:U?a:void 0}},i[70]=a,i[71]=G,i[72]=z,i[73]=U,i[74]=T,i[75]=D,i[76]=V,i[77]=J,i[78]=B,i[79]=L,i[80]=X,i[81]=Y,i[82]=R,i[83]=He):He=i[83],m(He);let Ue,We;i[84]!==U||i[85]!==w||i[86]!==j||i[87]!==K?(Ue=()=>(he.current=e=>{let t=Oe.current,n=Ae.current;if(q.current!=null||t==null||n==null)return;se(n);let r=ir(n.ownerDocument,j,{hover:U});n.prepend(r.canvas),r.hover!=null&&n.append(r.hover.crosshair,r.hover.band,r.hover.markers);let i=e!=null&&e.width>0&&e.height>0?{width:e.width,height:e.height}:void 0,a=new pn({kind:w,store:K,elements:{root:t,plot:n,canvas:r.canvas,hover:r.hover,tooltip:je.current},inView:!1,size:i}),o=Ve.current;a.setOptions(o.options),a.setRows(Ce.current.data),a.setCallbacks(o.callbacks),a.setControlledActiveIndex(o.controlledActiveIndex),q.current=a,fe.current=r,a.flushIngest(),a.setInView(ve.current.near||ve.current.focused),ve.current.seen&&a.markSeen(),a.commitNow()},me.current&&(me.current=!1,he.current(null)),()=>{me.current=q.current!=null,he.current=null;let e=q.current,t=fe.current;q.current=null,fe.current=null,e?.destroy(),t!=null&&(t.canvas.remove(),t.hover?.crosshair.remove(),t.hover?.band.remove(),t.hover?.markers.remove())}),We=[w,K,j,U],i[84]=U,i[85]=w,i[86]=j,i[87]=K,i[88]=Ue,i[89]=We):(Ue=i[88],We=i[89]),m(Ue,We);let Ge,Ke;i[90]===Symbol.for(`react.memo_cache_sentinel`)?(Ge=()=>{let e=Ae.current;if(e!=null)return Kn(e,t=>{let{band:n,inView:r,rect:i}=t,a=q.current,o=ve.current;n===`near`?(o.near=r,a==null?r?ae(e,{rect:i,run:e=>he.current?.(e)}):se(e):a.setInView(r||o.focused)):n===`visible`&&r?(o.seen=!0,a==null?oe(e):a.markSeen()):n===`far`&&(o.withinFar=r,!r&&!o.focused&&a?.releaseBackingStores())})},Ke=[],i[90]=Ge,i[91]=Ke):(Ge=i[90],Ke=i[91]),m(Ge,Ke);let qe,Je;i[92]===Symbol.for(`react.memo_cache_sentinel`)?(qe=()=>{let e=Oe.current?.ownerDocument.defaultView;if(e!=null)return tt(e,{before:()=>{he.current?.(null),q.current?.paintForPrint()},after:Or})},Je=[],i[92]=qe,i[93]=Je):(qe=i[92],Je=i[93]),m(qe,Je);let Ye,Xe;i[94]!==G||i[95]!==W||i[96]!==z||i[97]!==V||i[98]!==J||i[99]!==B||i[100]!==K||i[101]!==L||i[102]!==X||i[103]!==Y||i[104]!==R?(Ye=()=>{q.current?.setOptions({xKey:L,xScale:J,yDomain:[Y,X],zKey:R??null,dimensions:z,stacked:B,orientation:V,animate:G}),K.setOrientation(V),K.setDecorative(W)},Xe=[K,W,L,J,Y,X,R,z,B,V,G],i[94]=G,i[95]=W,i[96]=z,i[97]=V,i[98]=J,i[99]=B,i[100]=K,i[101]=L,i[102]=X,i[103]=Y,i[104]=R,i[105]=Ye,i[106]=Xe):(Ye=i[105],Xe=i[106]),m(Ye,Xe);let Ze,Qe;i[107]===S?(Ze=i[108],Qe=i[109]):(Ze=()=>{q.current?.setRows(S)},Qe=[S],i[107]=S,i[108]=Ze,i[109]=Qe),m(Ze,Qe);let $e;i[110]!==U||i[111]!==T||i[112]!==D?($e=()=>{q.current?.setCallbacks(U?{onDatumActivate:D??null,onActiveIndexChange:T??null}:{onDatumActivate:null,onActiveIndexChange:null})},i[110]=U,i[111]=T,i[112]=D,i[113]=$e):$e=i[113],m($e);let et,nt;i[114]!==a||i[115]!==U?(et=()=>{q.current?.setControlledActiveIndex(U?a:void 0)},nt=[U,a],i[114]=a,i[115]=U,i[116]=et,i[117]=nt):(et=i[116],nt=i[117]),m(et,nt);let rt=er(M??tr),it;i[118]===Symbol.for(`react.memo_cache_sentinel`)?(it=()=>{q.current?.invalidateColors()},i[118]=it):it=i[118];let at;i[119]!==f||i[120]!==rt?(at=[f,rt],i[119]=f,i[120]=rt,i[121]=at):at=i[121],m(it,at);let ot;i[122]===K?ot=i[123]:(ot=()=>{let e=ye.current;if(e==null)return;let t=null,n=()=>{let n=ge(K.getSnapshot().series.map(kr));n!==t&&(t=n,e.textContent=n)};return n(),K.subscribe(n)},i[122]=K,i[123]=ot);let st;i[124]!==W||i[125]!==K?(st=[K,W],i[124]=W,i[125]=K,i[126]=st):st=i[126],m(ot,st);let ct=h(null),lt;i[127]!==y||i[128]!==S||i[129]!==w||i[130]!==J||i[131]!==K||i[132]!==L||i[133]!==R?(lt=()=>{let e=q.current;if(e!=null){e.flushIngest();return}let t=K.seriesSpecs().map(Ar),n=`${L}|${J}|${R??``}|${t.join(`|`)}`,r=ct.current;(r==null||r.data!==S||r.signature!==n)&&(ee({rootName:`${y}.Root`,partName:`${y}.${ar[w]}`,rows:S,xKey:L,xScale:J,dataKeys:t,zKey:R??null}),ct.current={data:S,signature:n})},i[127]=y,i[128]=S,i[129]=w,i[130]=J,i[131]=K,i[132]=L,i[133]=R,i[134]=lt):lt=i[134],m(lt);let ut;i[135]!==C||i[136]!==j?(ut=r(C,j),i[135]=C,i[136]=j,i[137]=ut):ut=i[137];let dt;i[138]===f?dt=i[139]:(dt=n(`relative flex aspect-video w-full flex-col`,f),i[138]=f,i[139]=dt);let ft=W?!0:s,pt=W?void 0:re,mt=W?!0:void 0,ht;i[140]!==U||i[141]!==O?(ht=e=>{O?.(e),U&&de(!0),ve.current.focused=!0,he.current?.(null),q.current?.setInView(!0)},i[140]=U,i[141]=O,i[142]=ht):ht=i[142];let gt;i[143]===E?gt=i[144]:(gt=e=>{if(E?.(e),e.relatedTarget instanceof Node&&e.currentTarget.contains(e.relatedTarget))return;let t=ve.current;t.focused=!1;let n=q.current;n!=null&&(n.setInView(t.near),t.withinFar||n.releaseBackingStores())},i[143]=E,i[144]=gt);let _t=U?ue?`engaged`:`dormant`:void 0,vt=`${j}-plot`,yt=le&&`opacity-60 transition-opacity duration-300`,bt;i[145]===yt?bt=i[146]:(bt=n(`relative min-h-0 w-full flex-1`,yt),i[145]=yt,i[146]=bt);let xt=H===`static`?`img`:void 0,St=H===`static`?c:void 0,Ct=H===`static`?u:void 0,wt=H===`static`?Me:void 0,Tt;i[147]!==c||i[148]!==u||i[149]!==Me||i[150]!==U||i[151]!==w||i[152]!==R?(Tt=U&&/* @__PURE__ */ b(`div`,{role:`application`,"aria-label":c,"aria-labelledby":u,"aria-describedby":Me,tabIndex:0,className:n(`focus-visible:ring-focus-accent absolute inset-0 rounded-sm outline-none focus-visible:ring-2`,(w===`line`||w===`area`)&&`cursor-crosshair`,w===`scatter`&&R!=null&&`touch-none cursor-grab active:cursor-grabbing`),onPointerDown:e=>{e.isTrusted&&w===`scatter`&&R!=null&&e.currentTarget.setPointerCapture(e.pointerId),q.current??he.current?.(Ae.current?.getBoundingClientRect()??null),q.current?.handlePointerDown(e.nativeEvent.offsetX,e.nativeEvent.offsetY)},onPointerMove:e=>{q.current?.handlePointerMove(e.nativeEvent.offsetX,e.nativeEvent.offsetY)},onPointerUp:e=>{q.current?.handlePointerUp(e.nativeEvent.offsetX,e.nativeEvent.offsetY)},onPointerLeave:()=>{q.current?.handlePointerLeave()},onPointerCancel:()=>{q.current?.handlePointerLeave()},onBlur:()=>{q.current?.handlePointerLeave()},onKeyDown:e=>{q.current?.handleKeyDown(e.key)&&e.preventDefault()}}),i[147]=c,i[148]=u,i[149]=Me,i[150]=U,i[151]=w,i[152]=R,i[153]=Tt):Tt=i[153];let Et;i[154]!==W||i[155]!==Me||i[156]!==U||i[157]!==w||i[158]!==j||i[159]!==Fe?(Et=!W&&/* @__PURE__ */ b(Sr,{id:Me,kind:w,slotName:j,seriesRef:ye,summary:Fe,instructions:U}),i[154]=W,i[155]=Me,i[156]=U,i[157]=w,i[158]=j,i[159]=Fe,i[160]=Et):Et=i[160];let Q;i[161]!==U||i[162]!==j||i[163]!==K||i[164]!==xe||i[165]!==Z?(Q=xe&&U&&/* @__PURE__ */ b(mr,{slotName:j,store:K,tooltipRef:e=>{je.current=e,q.current?.attachTooltip(e)},xHasTimeOfDay:Z}),i[161]=U,i[162]=j,i[163]=K,i[164]=xe,i[165]=Z,i[166]=Q):Q=i[166];let Dt;i[167]!==vt||i[168]!==bt||i[169]!==xt||i[170]!==St||i[171]!==Ct||i[172]!==wt||i[173]!==Tt||i[174]!==Et||i[175]!==Q?(Dt=/* @__PURE__ */ x(`div`,{"data-slot":vt,className:bt,role:xt,"aria-label":St,"aria-labelledby":Ct,"aria-describedby":wt,ref:Ae,children:[Tt,Et,Q]}),i[167]=vt,i[168]=bt,i[169]=xt,i[170]=St,i[171]=Ct,i[172]=wt,i[173]=Tt,i[174]=Et,i[175]=Q,i[176]=Dt):Dt=i[176];let Ot;i[177]!==U||i[178]!==K||i[179]!==Z?(Ot=U&&/* @__PURE__ */ b(Cr,{store:K,xHasTimeOfDay:Z}),i[177]=U,i[178]=K,i[179]=Z,i[180]=Ot):Ot=i[180];let kt;i[181]!==c||i[182]!==u||i[183]!==S||i[184]!==ue||i[185]!==U||i[186]!==j||i[187]!==K||i[188]!==Z||i[189]!==L||i[190]!==R?(kt=U&&ue&&/* @__PURE__ */ b(Tr,{data:S,label:c,labelledBy:u,slotName:j,store:K,xHasTimeOfDay:Z,xKey:L,zKey:R}),i[181]=c,i[182]=u,i[183]=S,i[184]=ue,i[185]=U,i[186]=j,i[187]=K,i[188]=Z,i[189]=L,i[190]=R,i[191]=kt):kt=i[191];let At;i[192]!==d||i[193]!==Te||i[194]!==Dt||i[195]!==Ot||i[196]!==kt?(At=/* @__PURE__ */ x(qn.Provider,{value:Te,children:[Dt,d,Ot,kt]}),i[192]=d,i[193]=Te,i[194]=Dt,i[195]=Ot,i[196]=kt,i[197]=At):At=i[197];let jt;return i[198]!==ke||i[199]!==k||i[200]!==M||i[201]!==ut||i[202]!==dt||i[203]!==ft||i[204]!==pt||i[205]!==mt||i[206]!==ht||i[207]!==gt||i[208]!==_t||i[209]!==At?(jt=/* @__PURE__ */ b(`div`,{"data-slot":ut,className:dt,"aria-hidden":ft,tabIndex:pt,inert:mt,ref:ke,onFocus:ht,onBlur:gt,style:M,...k,"data-state":_t,children:At}),i[198]=ke,i[199]=k,i[200]=M,i[201]=ut,i[202]=dt,i[203]=ft,i[204]=pt,i[205]=mt,i[206]=ht,i[207]=gt,i[208]=_t,i[209]=At,i[210]=jt):jt=i[210],jt},sr=(e,t,n)=>{let r=l(13),i=Jn(e);v(i.kind===t,`${e} cannot be composed inside ${i.componentName}.Root — compose ${i.componentName} series parts instead.`);let{dataKey:a,label:o,seriesSlot:s,color:c,curve:u,markers:d,connectNulls:f,shape:p,texture:h}=n,g=u===void 0?`linear`:u,_=d!==void 0&&d,y=f!==void 0&&f,b=h===void 0?`solid`:h,x,S;return r[0]!==c||r[1]!==y||r[2]!==i.store||r[3]!==g||r[4]!==a||r[5]!==o||r[6]!==t||r[7]!==_||r[8]!==s||r[9]!==p||r[10]!==b?(x=()=>i.store.registerSeries({dataKey:a,label:o??a,seriesSlot:s,color:c,mark:t,curve:g,markers:_,connectNulls:y,shape:p,texture:b}),S=[i.store,a,o,s,c,t,g,_,y,p,b],r[0]=c,r[1]=y,r[2]=i.store,r[3]=g,r[4]=a,r[5]=o,r[6]=t,r[7]=_,r[8]=s,r[9]=p,r[10]=b,r[11]=x,r[12]=S):(x=r[11],S=r[12]),m(x,S),null},cr=(e,t)=>{let n=l(4),r=Jn(e),{lines:i}=t,a,o;return n[0]!==r.store||n[1]!==i?(a=()=>r.store.registerGrid(i),o=[r.store,i],n[0]=r.store,n[1]=i,n[2]=a,n[3]=o):(a=n[2],o=n[3]),m(a,o),null},lr=(e,t)=>{let n=l(5),r=Jn(e),{tickFormat:i,tickCount:a}=t,o,s;return n[0]!==r.store||n[1]!==a||n[2]!==i?(o=()=>r.store.registerXAxis({tickFormat:i,tickCount:a}),s=[r.store,i,a],n[0]=r.store,n[1]=a,n[2]=i,n[3]=o,n[4]=s):(o=n[3],s=n[4]),m(o,s),null},ur=(e,t)=>{let n=l(5),r=Jn(e),{tickFormat:i,tickCount:a}=t,o,s;return n[0]!==r.store||n[1]!==a||n[2]!==i?(o=()=>r.store.registerYAxis({tickFormat:i,tickCount:a}),s=[r.store,i,a],n[0]=r.store,n[1]=a,n[2]=i,n[3]=o,n[4]=s):(o=n[3],s=n[4]),m(o,s),null},dr=(e,t)=>{let n=l(7),r=Jn(e),i=p(),{y:a,label:o,color:s}=t,c,u;return n[0]!==s||n[1]!==r.store||n[2]!==i||n[3]!==o||n[4]!==a?(c=()=>r.store.registerReferenceLine(i,{y:a,label:o,color:s}),u=[r.store,i,a,o,s],n[0]=s,n[1]=r.store,n[2]=i,n[3]=o,n[4]=a,n[5]=c,n[6]=u):(c=n[5],u=n[6]),m(c,u),null},fr=(e,t)=>{let n=l(16),r=Jn(e),i,a,o,s,c,u;n[0]===t?(i=n[1],a=n[2],o=n[3],s=n[4],c=n[5],u=n[6]):({labelFormat:s,valueFormat:u,indicator:c,footer:o,children:i,...a}=t,n[0]=t,n[1]=i,n[2]=a,n[3]=o,n[4]=s,n[5]=c,n[6]=u);let d=c===void 0?`line`:c,f=er(a),p,h;return n[7]!==i||n[8]!==r.store||n[9]!==o||n[10]!==d||n[11]!==s||n[12]!==f||n[13]!==u?(p=()=>r.store.registerTooltip({labelFormat:s,valueFormat:u,indicator:d,footer:o,children:i,divProps:f}),h=[r.store,s,u,d,o,i,f],n[7]=i,n[8]=r.store,n[9]=o,n[10]=d,n[11]=s,n[12]=f,n[13]=u,n[14]=p,n[15]=h):(p=n[14],h=n[15]),m(p,h),null},pr=(e,t,n)=>e==null?`—`:n==null?H(e):n(e,t),mr=r=>{let i=l(27),{slotName:a,store:o,tooltipRef:s,xHasTimeOfDay:c}=r,u=Yn(o),d=u.tooltip,f=u.hover,p;i[0]===d?.divProps?p=i[1]:(p=d?.divProps??{},i[0]=d?.divProps,i[1]=p);let g,_,v,S;i[2]===p?(g=i[3],_=i[4],v=i[5],S=i[6]):({className:g,ref:_,style:S,...v}=p,i[2]=p,i[3]=g,i[4]=_,i[5]=v,i[6]=S);let C=h(null),w=e(s,C),T,E;i[7]===_?(T=i[8],E=i[9]):(T=()=>{if(_==null)return;let e=t(_),n=e(C.current);return()=>{typeof n==`function`?n():e(null)}},E=[_],i[7]=_,i[8]=T,i[9]=E),m(T,E);let D=d?.footer,O=`${a}-tooltip`,k;i[10]===g?k=i[11]:(k=n(`bg-popover border-popover text-strong pointer-events-none absolute left-0 top-0 z-10 min-w-32 rounded-md border px-2.5 py-1.5 text-xs shadow-md`,g),i[10]=g,i[11]=k);let A;i[12]===S?A=i[13]:(A={opacity:0,...S},i[12]=S,i[13]=A);let j=A,M;i[14]!==d||i[15]!==D||i[16]!==f||i[17]!==a||i[18]!==c?(M=f==null?null:d?.children==null?/* @__PURE__ */ x(y,{children:[/* @__PURE__ */ b(`div`,{className:`text-muted font-medium`,children:d?.labelFormat==null?q(f.xValue,{datasetHasTimeOfDay:c}):d.labelFormat(f.xValue)}),/* @__PURE__ */ b(`div`,{className:`mt-1 grid gap-1`,children:f.points.map(e=>/* @__PURE__ */ x(`div`,{className:`flex items-center gap-1.5`,children:[d?.indicator===`none`?null:/* @__PURE__ */ b(`span`,{"aria-hidden":!0,className:`h-2.5 w-0.5 shrink-0 rounded-full`,style:{backgroundColor:e.color}}),/* @__PURE__ */ b(`span`,{className:`text-muted`,children:e.label}),/* @__PURE__ */ b(`span`,{className:`text-strong ml-auto pl-3 font-medium tabular-nums`,children:pr(e.value,e.dataKey,d?.valueFormat)})]},e.dataKey))}),f.zValue===void 0?null:/* @__PURE__ */ x(`div`,{className:`mt-1 flex items-center gap-1.5`,children:[/* @__PURE__ */ b(`span`,{className:`text-muted`,children:`z`}),/* @__PURE__ */ b(`span`,{className:`text-strong ml-auto pl-3 font-medium tabular-nums`,children:f.zValue==null?`—`:H(f.zValue)})]}),D==null?null:/* @__PURE__ */ b(`div`,{className:`text-muted mt-1`,children:typeof D==`function`?D(f):D})]}):/* @__PURE__ */ b(`div`,{"data-slot":`${a}-tooltip-label`,className:`contents`,children:d.children(f)}),i[14]=d,i[15]=D,i[16]=f,i[17]=a,i[18]=c,i[19]=M):M=i[19];let N;return i[20]!==w||i[21]!==v||i[22]!==O||i[23]!==k||i[24]!==j||i[25]!==M?(N=/* @__PURE__ */ b(`div`,{"data-slot":O,ref:w,className:k,style:j,...v,children:M}),i[20]=w,i[21]=v,i[22]=O,i[23]=k,i[24]=j,i[25]=M,i[26]=N):N=i[26],N},hr=(e,t,n=3)=>`repeating-linear-gradient(${e}, ${t} 0, ${t} 1px, transparent 1px, transparent ${n}px)`,gr=`forced-color-adjust-none [print-color-adjust:exact] [-webkit-print-color-adjust:exact]`,_r={hatch:({ink:e})=>({backgroundImage:hr(`135deg`,e)}),"hatch-reverse":({ink:e})=>({backgroundImage:hr(`45deg`,e)}),crosshatch:({ink:e})=>({backgroundImage:`${hr(`135deg`,e,4)}, ${hr(`45deg`,e,4)}`}),perpendicular:({ink:e,orientation:t})=>({backgroundImage:hr(t===`horizontal`?`90deg`:`0deg`,e)}),parallel:({ink:e,orientation:t})=>({backgroundImage:hr(t===`horizontal`?`0deg`:`90deg`,e)}),grid:({ink:e})=>({backgroundImage:`${hr(`0deg`,e,4)}, ${hr(`90deg`,e,4)}`}),dots:({ink:e})=>({backgroundImage:`radial-gradient(circle at 1px 1px, ${e} 0.75px, transparent 0.8px)`,backgroundSize:`3px 3px`})},vr=(e,t,n)=>e===`solid`?{}:_r[e]({ink:Ue(t),orientation:n}),yr=e=>{let t=l(31),{series:r,orientation:i}=e;if(r.mark===`bar`){let e=r.texture,a;t[0]===Symbol.for(`react.memo_cache_sentinel`)?(a=n(`size-2 shrink-0 rounded-[2px]`,gr),t[0]=a):a=t[0];let o=r.color,s;t[1]!==i||t[2]!==r.color||t[3]!==r.texture?(s=vr(r.texture,r.color,i),t[1]=i,t[2]=r.color,t[3]=r.texture,t[4]=s):s=t[4];let c;t[5]!==r.color||t[6]!==s?(c={backgroundColor:o,...s},t[5]=r.color,t[6]=s,t[7]=c):c=t[7];let l;return t[8]!==r.texture||t[9]!==c?(l=/* @__PURE__ */ b(`span`,{"aria-hidden":!0,"data-texture":e,className:a,style:c}),t[8]=r.texture,t[9]=c,t[10]=l):l=t[10],l}if(r.mark===`line`){let e;t[11]===Symbol.for(`react.memo_cache_sentinel`)?(e=n(`absolute inset-x-0 top-1/2 h-0.5 -translate-y-1/2 rounded-full`,gr),t[11]=e):e=t[11];let i;t[12]===r.color?i=t[13]:(i=/* @__PURE__ */ b(`span`,{className:e,style:{backgroundColor:r.color}}),t[12]=r.color,t[13]=i);let a=r.shape,o;t[14]===Symbol.for(`react.memo_cache_sentinel`)?(o=n(`relative size-2`,gr),t[14]=o):o=t[14];let s=gn[r.shape],c;t[15]!==r.color||t[16]!==s?(c={backgroundColor:r.color,clipPath:s},t[15]=r.color,t[16]=s,t[17]=c):c=t[17];let l;t[18]!==r.shape||t[19]!==c?(l=/* @__PURE__ */ b(`span`,{"data-shape":a,className:o,style:c}),t[18]=r.shape,t[19]=c,t[20]=l):l=t[20];let u;return t[21]!==i||t[22]!==l?(u=/* @__PURE__ */ x(`span`,{"aria-hidden":!0,className:`relative flex h-2 w-3 shrink-0 items-center justify-center`,children:[i,l]}),t[21]=i,t[22]=l,t[23]=u):u=t[23],u}let a=r.shape,o;t[24]===Symbol.for(`react.memo_cache_sentinel`)?(o=n(`size-2 shrink-0`,gr),t[24]=o):o=t[24];let s=gn[r.shape],c;t[25]!==r.color||t[26]!==s?(c={backgroundColor:r.color,clipPath:s},t[25]=r.color,t[26]=s,t[27]=c):c=t[27];let u;return t[28]!==r.shape||t[29]!==c?(u=/* @__PURE__ */ b(`span`,{"aria-hidden":!0,"data-shape":a,className:o,style:c}),t[28]=r.shape,t[29]=c,t[30]=u):u=t[30],u},br=e=>{let t=l(18),r,i,a,o,s;t[0]===e?(r=t[1],i=t[2],a=t[3],o=t[4],s=t[5]):({partName:a,slotName:s,className:i,children:r,...o}=e,t[0]=e,t[1]=r,t[2]=i,t[3]=a,t[4]=o,t[5]=s);let c=Jn(a),u=Xn(c.store),d=Qn(c.store);if(u.length<2)return null;let f=`${s}-legend`,p;t[6]===i?p=t[7]:(p=n(`text-muted flex flex-wrap items-center gap-x-4 gap-y-1 pt-3 text-xs`,i),t[6]=i,t[7]=p);let m;t[8]!==r||t[9]!==d||t[10]!==u||t[11]!==s?(m=r==null?u.map(e=>/* @__PURE__ */ x(`div`,{className:`flex items-center gap-1.5`,children:[/* @__PURE__ */ b(yr,{series:e,orientation:d}),e.label]},e.dataKey)):/* @__PURE__ */ b(`div`,{"data-slot":`${s}-legend-label`,className:`contents`,children:r(u)}),t[8]=r,t[9]=d,t[10]=u,t[11]=s,t[12]=m):m=t[12];let h;return t[13]!==o||t[14]!==f||t[15]!==p||t[16]!==m?(h=/* @__PURE__ */ b(`div`,{"data-slot":f,className:p,...o,children:m}),t[13]=o,t[14]=f,t[15]=p,t[16]=m,t[17]=h):h=t[17],h},xr=e=>{let t=l(31),n,r,a,u,d,p,m,_;t[0]===e?(n=t[1],r=t[2],a=t[3],u=t[4],d=t[5],p=t[6],m=t[7],_=t[8]):({partName:u,slotName:m,label:_,onCopy:r,onCopyError:a,onClick:n,ref:p,...d}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=a,t[4]=u,t[5]=d,t[6]=p,t[7]=m,t[8]=_);let v=_===void 0?`Copy data as Markdown`:_,w=Jn(u),T=o(),[E,D]=g(``),O=E!==``,k=h(!1),A=h(void 0),j,M;t[9]===Symbol.for(`react.memo_cache_sentinel`)?(j=()=>()=>{A.current!=null&&clearTimeout(A.current)},M=[],t[9]=j,t[10]=M):(j=t[9],M=t[10]),f(j,M);let N=`${m}-copy-button`,P;t[11]===O?P=t[12]:(P=b(O?S:C,{}),t[11]=O,t[12]=P);let ee;t[13]!==w||t[14]!==T||t[15]!==n||t[16]!==r||t[17]!==a?(ee=async e=>{try{if(n?.(e),e.defaultPrevented){A.current!=null&&(clearTimeout(A.current),A.current=void 0),D(``);return}let{data:t,xKey:i,zKey:a}=w.dataRef.current,o=wn({data:t,xKey:i,zKey:a,series:w.store.getSnapshot().series});await T(o),r?.(o),D(s(`Copied`,k)),A.current!=null&&clearTimeout(A.current),A.current=setTimeout(()=>{D(``)},2e3)}catch(e){a?.(e)}},t[13]=w,t[14]=T,t[15]=n,t[16]=r,t[17]=a,t[18]=ee):ee=t[18];let F;t[19]!==v||t[20]!==d||t[21]!==p||t[22]!==N||t[23]!==P||t[24]!==ee?(F=/* @__PURE__ */ b(i,{type:`button`,appearance:`ghost`,intent:`neutral`,size:`sm`,"data-slot":N,label:v,icon:P,ref:p,onClick:ee,...d}),t[19]=v,t[20]=d,t[21]=p,t[22]=N,t[23]=P,t[24]=ee,t[25]=F):F=t[25];let I;t[26]===E?I=t[27]:(I=/* @__PURE__ */ b(c,{children:E}),t[26]=E,t[27]=I);let te;return t[28]!==F||t[29]!==I?(te=/* @__PURE__ */ x(y,{children:[F,I]}),t[28]=F,t[29]=I,t[30]=te):te=t[30],te},Sr=e=>{let t=l(17),{id:n,kind:r,slotName:i,seriesRef:o,summary:s,instructions:c}=e,u=a(),d;t[0]!==u||t[1]!==r||t[2]!==s?(d=_e({kind:r,summary:s,hydrated:u}),t[0]=u,t[1]=r,t[2]=s,t[3]=d):d=t[3];let f=d,p=`${i}-description`,m;t[4]===f.sentence?m=t[5]:(m=/* @__PURE__ */ b(`span`,{children:f.sentence}),t[4]=f.sentence,t[5]=m);let h;t[6]===o?h=t[7]:(h=/* @__PURE__ */ b(`span`,{ref:o}),t[6]=o,t[7]=h);let g;t[8]!==c||t[9]!==f.instructions?(g=c&&/* @__PURE__ */ b(`span`,{children:f.instructions}),t[8]=c,t[9]=f.instructions,t[10]=g):g=t[10];let _;return t[11]!==n||t[12]!==p||t[13]!==m||t[14]!==h||t[15]!==g?(_=/* @__PURE__ */ x(`span`,{id:n,"data-slot":p,className:`sr-only`,children:[m,h,g]}),t[11]=n,t[12]=p,t[13]=m,t[14]=h,t[15]=g,t[16]=_):_=t[16],_},Cr=e=>{let t=l(6),{store:n,xHasTimeOfDay:r}=e,i=Zn(n),[a,o]=g(``),s,c;t[0]!==i||t[1]!==r?(s=()=>{if(i==null||!i.viaKeyboard){o(``);return}let e=i.points.map(jr).join(`, `),t=i.zValue===void 0?``:`, z: ${i.zValue==null?`no data`:H(i.zValue)}`,n=setTimeout(()=>{o(`${q(i.xValue,{datasetHasTimeOfDay:r})}. ${e}${t}`)},120);return()=>clearTimeout(n)},c=[i,r],t[0]=i,t[1]=r,t[2]=s,t[3]=c):(s=t[2],c=t[3]),f(s,c);let u;return t[4]===a?u=t[5]:(u=/* @__PURE__ */ b(`span`,{role:`status`,"aria-live":`polite`,className:`sr-only`,children:a}),t[4]=a,t[5]=u),u},wr=(e,t)=>{let n=l(3),[r,i]=g(void 0),a,o;return n[0]===t?(a=n[1],o=n[2]):(a=()=>{if(t==null){i(void 0);return}let e=t.split(/\s+/).map(Mr).filter(Boolean).join(` `);i(e||void 0)},o=[t],n[0]=t,n[1]=a,n[2]=o),f(a,o),e??r},Tr=e=>{let t=l(39),{data:n,label:r,labelledBy:i,slotName:a,store:o,xHasTimeOfDay:s,xKey:c,zKey:u}=e,d=Xn(o),f=wr(r,i);if(n.length===0||d.length===0)return null;let p,m,h,g,_;if(t[0]!==n||t[1]!==f||t[2]!==d||t[3]!==a||t[4]!==s||t[5]!==c||t[6]!==u){let e=n.slice(0,150);g=`sr-only`,_=`${a}-data-table`;let r=`${f==null?`Chart data`:`${f} — chart data`}${n.length>150?`. Showing the first 150 of ${n.length} rows.`:`.`}`;t[12]===r?m=t[13]:(m=/* @__PURE__ */ b(`caption`,{children:r}),t[12]=r,t[13]=m);let i;t[14]===c?i=t[15]:(i=/* @__PURE__ */ b(`th`,{scope:`col`,children:c}),t[14]=c,t[15]=i);let o;t[16]===d?o=t[17]:(o=d.map(Nr),t[16]=d,t[17]=o);let l;t[18]===u?l=t[19]:(l=u==null?null:/* @__PURE__ */ b(`th`,{scope:`col`,children:u}),t[18]=u,t[19]=l),t[20]!==i||t[21]!==o||t[22]!==l?(h=/* @__PURE__ */ b(`thead`,{children:/* @__PURE__ */ x(`tr`,{children:[i,o,l]})}),t[20]=i,t[21]=o,t[22]=l,t[23]=h):h=t[23];let v;t[24]!==d||t[25]!==s||t[26]!==c||t[27]!==u?(v=(e,t)=>{let n=A(e,c),r=n instanceof Date&&!Number.isNaN(n.getTime()),i=typeof n==`string`||typeof n==`number`||n instanceof Date?q(n,{datasetHasTimeOfDay:s}):String(n);return/* @__PURE__ */ x(`tr`,{children:[/* @__PURE__ */ b(`th`,{scope:`row`,"data-value":typeof n==`number`&&Number.isFinite(n)?n:void 0,children:r?/* @__PURE__ */ b(`time`,{dateTime:n.toISOString(),children:i}):i}),d.map(t=>{let n=A(e,t.dataKey),r=typeof n==`number`&&Number.isFinite(n);return/* @__PURE__ */ b(`td`,{"data-value":r?n:void 0,children:r?H(n):`—`},t.dataKey)}),u==null?null:(()=>{let t=A(e,u),n=typeof t==`number`&&Number.isFinite(t);return/* @__PURE__ */ b(`td`,{"data-value":n?t:void 0,children:n?H(t):`—`})})()]},t)},t[24]=d,t[25]=s,t[26]=c,t[27]=u,t[28]=v):v=t[28],p=e.map(v),t[0]=n,t[1]=f,t[2]=d,t[3]=a,t[4]=s,t[5]=c,t[6]=u,t[7]=p,t[8]=m,t[9]=h,t[10]=g,t[11]=_}else p=t[7],m=t[8],h=t[9],g=t[10],_=t[11];let v;t[29]===p?v=t[30]:(v=/* @__PURE__ */ b(`tbody`,{children:p}),t[29]=p,t[30]=v);let y;t[31]!==m||t[32]!==h||t[33]!==v?(y=/* @__PURE__ */ x(`table`,{children:[m,h,v]}),t[31]=m,t[32]=h,t[33]=v,t[34]=y):y=t[34];let S;return t[35]!==g||t[36]!==_||t[37]!==y?(S=/* @__PURE__ */ b(`div`,{className:g,"data-slot":_,children:y}),t[35]=g,t[36]=_,t[37]=y,t[38]=S):S=t[38],S};function Er(){return new An}function Dr(){return!1}function Or(){}function kr(e){return e.label}function Ar(e){return e.dataKey}function jr(e){return`${e.label}: ${e.value==null?`no data`:H(e.value)}`}function Mr(e){return document.getElementById(e)?.textContent?.trim()??``}function Nr(e){return/* @__PURE__ */ b(`th`,{scope:`col`,children:e.label},e.dataKey)}export{dr as a,lr as c,cr as i,ur as l,br as n,sr as o,or as r,fr as s,xr as t};
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import{t as e}from"./cx-CK7o_rVv.js";import{t}from"./booleanish-BfvnW6vy.js";const n=/* @__PURE__ */ new Set([`bash`,`sh`,`shell`]);function r(e,t){return!(n.has(e)&&!t.trim().includes(`
|
|
2
|
-
`))}const i=Symbol(`MantleCodeBlockValue`);function a({preHtml:e,preValToken:t,preVals:n,highlightLines:r,lineNumberStart:a,showLineNumbers:o,code:s,language:c}){return{[i]:!0,language:c,code:s,"~preHtml":e,"~preValToken":t,"~preVals":n,"~highlightLines":r,"~lineNumberStart":a,"~showLineNumbers":o}}function o(e,t){let n=``;for(let r=0;r<e.length;r+=1)n+=e[r]??``,r<t.length&&(n+=String(t[r]));return n}function s(e,t={}){let{showLineNumbers:n,highlightLines:i,lineNumberStart:s}=t;return(t,...c)=>{let l=o(t,c);return a({language:e,code:l,preHtml:void 0,preVals:c.length>0?c:void 0,highlightLines:i,lineNumberStart:s,showLineNumbers:n??r(e,l)})}}function c(e){if(e.length<=1)return e;e.sort((e,t)=>e.startLine===t.startLine?t.endLine-e.endLine:e.startLine-t.startLine);let t=[],n=-1;for(let r of e)r.startLine!==n&&(t.push(r),n=r.startLine);return t}function l(e){let t=e.length;if(t===0)return[];let n=[],r=[],i=1,a=0;for(;a<t;){let o=e.charCodeAt(a);if(o===10)i+=1,a+=1;else if(o===13)i+=1,a+=1,a<t&&e.charCodeAt(a)===10&&(a+=1);else if(o===34)for(a+=1;a<t;){let t=e.charCodeAt(a);if(t===92)a+=2;else{if(t===34){a+=1;break}if(t===10||t===13)break;a+=1}}else if(o===123||o===91)n.push({opener:o,line:i}),a+=1;else if(o===125||o===93){let e=o===125?123:91,t=n[n.length-1];t?.opener===e?(n.pop(),t.line!==i&&r.push({id:String(t.line),startLine:t.line,endLine:i})):t!=null&&(n.length=0),a+=1}else a+=1}return c(r)}function u(...e){let t=/* @__PURE__ */ new Set;for(let n of e)if(typeof n==`number`){if(!d(n))continue;let e=Math.floor(n);t.add(e)}else{let e=n.indexOf(`-`),r=n.slice(0,e),i=n.slice(e+1),a=Number.parseInt(r,10),o=Number.parseInt(i,10);if(!d(a)||!d(o)||(a>o&&([a,o]=[o,a]),o-a+1>1e3))continue;for(let e=a;e<=o;e++)t.add(e)}return t}const d=e=>e!=null&&!Number.isNaN(e)&&e>0&&Number.isFinite(e);function f(e){let t=e.length;for(;t>0&&(e.charCodeAt(t-1)===10||e.charCodeAt(t-1)===13);)--t;return t===e.length?e:e.slice(0,t)}function p(e){let t=f(e).replaceAll(`\r
|
|
3
|
-
`,`
|
|
4
|
-
`).replaceAll(`\r`,`
|
|
5
|
-
`).split(`
|
|
6
|
-
`);for(let e=0;e<t.length;e++){let n=t[e]??``;n.startsWith(`<span class="line">`)&&n.endsWith(`</span>`)&&(t[e]=n.slice(19,n.length-7))}return t}function m(e){return encodeURIComponent(e)}function h({foldableRanges:t,highlightLines:n,html:r,lineNumberStart:i=1,showLineNumbers:a=!1}){let o=u(...n??[]),s=p(r),c=/* @__PURE__ */ new Map,l=/* @__PURE__ */ new Map,d=t!=null&&t.length>0;if(d&&t!=null)for(let e of t){let t=m(e.id);c.set(e.startLine,t);for(let n=e.startLine+1;n<e.endLine;n+=1){let e=l.get(n);e??(e=[],l.set(n,e)),e.push(t)}}let f=``;for(let t=0;t<s.length;t++){let n=s[t]??``,r=t+1,u=i+t,p=d?c.get(r):void 0,m=e(`mantle-code-line`,o.has(u)&&`mantle-code-line-highlighted`,p!=null&&`mantle-code-line-opener`),h=a?`<span class="mantle-code-line-number" data-slot="line-number" aria-hidden="true">${u}</span>`:``,g=``,_=``,v=``;if(d){p!=null&&(g=`<button type="button" class="mantle-code-fold-toggle" data-slot="fold-toggle" data-fold-line="${p}" aria-expanded="true" aria-label="Toggle code folding"><svg class="mantle-code-fold-caret" viewBox="0 0 16 16" aria-hidden="true" focusable="false"><path fill="currentColor" fill-rule="evenodd" d="M3.22 5.97a.75.75 0 0 1 1.06 0L8 9.69l3.72-3.72a.75.75 0 1 1 1.06 1.06l-4.25 4.25a.75.75 0 0 1-1.06 0L3.22 7.03a.75.75 0 0 1 0-1.06Z"/></svg></button>`,v=`<span class="mantle-code-fold-ellipsis" data-slot="fold-ellipsis" aria-hidden="true">⋯</span>`);let e=l.get(r);e!=null&&e.length>0&&(_=` data-fold-regions="${e.join(` `)}"`)}let y=`<span class="mantle-code-line-content" data-slot="line-content">${n===``?` `:n}${v}</span>`;f+=`<span class="${m}" data-line-number="${u}"${_}>${h}${g}${y}</span>`}return f}function g(e){switch(e){case`python`:case`py`:case`yaml`:case`yml`:return`indentation`;case`html`:case`xml`:return`tag`;case`bash`:case`sh`:case`shell`:case`plain`:case`plaintext`:case`text`:case`txt`:return`none`;default:return`bracket`}}function _({language:e,tokens:t}){switch(g(e)){case`bracket`:return S(t);case`indentation`:return w(t);case`tag`:return ee(t);case`none`:return[]}}function v(e){if(e.length===0)return!1;let t=e[e.length-1]?.scopeName??``;return t===`string`||t===`comment`||t.startsWith(`string.`)||t.startsWith(`comment.`)||t.startsWith(`constant.character.escape`)}function y(e){return e.explanation!=null&&e.explanation.length>0?e.explanation:[{content:e.content,scopes:[]}]}function b(e){let t=``;for(let n of e){let e=y(n),r=!1;for(let t of e)if(v(t.scopes)){r=!0;break}if(!r)t+=n.content;else for(let n of e)v(n.scopes)||(t+=n.content)}return t}function x(e){if(e==null||e.length===0)return-1;let t=0;for(let n of e){let e=n.content;for(let n=0;n<e.length;n+=1){let r=e.charCodeAt(n);if(r===32||r===9)t+=1;else return t}}return-1}function S(e){let t=[],n=[];for(let r=0;r<e.length;r+=1){let i=e[r];if(i==null)continue;let a=r+1;for(let e of i)if(C(e.content))for(let r of y(e)){if(v(r.scopes))continue;let e=r.content;for(let r=0;r<e.length;r+=1){let i=e.charCodeAt(r);if(i===123||i===91)t.push(a);else if(i===125||i===93){let e=t.pop();e!=null&&e!==a&&n.push({id:String(e),startLine:e,endLine:a})}}}}return c(n)}function C(e){for(let t=0;t<e.length;t+=1){let n=e.charCodeAt(t);if(n===123||n===125||n===91||n===93)return!0}return!1}function w(e){let t=Array.from({length:e.length});for(let n=0;n<e.length;n+=1)t[n]=x(e[n]);let n=[];for(let e=0;e<t.length;e+=1){let r=t[e]??-1;if(r<0)continue;let i=-1,a=e+1;for(;a<t.length;){let e=t[a]??-1;if(e<0)a+=1;else if(e>r)i=a,a+=1;else break}i>e&&n.push({id:String(e+1),startLine:e+1,endLine:i+2})}return c(n)}function ee(e){let t=[],n=[];for(let r=0;r<e.length;r+=1){let i=e[r];if(i==null)continue;let a=r+1,o=E(b(i));for(let e of o)if(e.kind===`open`)t.push({name:e.name,line:a});else{let r=t.length>0?t[t.length-1]:void 0;r!=null&&r.name.toLowerCase()===e.name.toLowerCase()&&(t.pop(),r.line!==a&&n.push({id:String(r.line),startLine:r.line,endLine:a}))}}return c(n)}const T=/* @__PURE__ */ new Set([`area`,`base`,`br`,`col`,`embed`,`hr`,`img`,`input`,`link`,`meta`,`param`,`source`,`track`,`wbr`]);function E(e){let t=[],n=0;for(;n<e.length;){let r=e.indexOf(`<`,n);if(r===-1)break;let i=O(e,r+1),a=e.charCodeAt(i)===47;if(a&&(i=O(e,i+1)),!k(e.charCodeAt(i))){n=r+1;continue}let o=i;for(i+=1;i<e.length&&A(e.charCodeAt(i));)i+=1;let s=e.slice(o,i),c=j(e,i);c===-1?n=r+1:a?(t.push({name:s,kind:`close`}),n=c+1):(te(e,c)||T.has(s.toLowerCase())||t.push({name:s,kind:`open`}),n=c+1)}return t}function D(e){return e===9||e===10||e===11||e===12||e===13||e===32}function O(e,t){let n=t;for(;n<e.length&&D(e.charCodeAt(n));)n+=1;return n}function k(e){return e>=65&&e<=90||e>=97&&e<=122}function A(e){return k(e)||e>=48&&e<=57||e===45||e===58||e===95}function j(e,t){let n;for(let r=t;r<e.length;r+=1){let t=e.charCodeAt(r);if(n!=null)t===n&&(n=void 0);else if(t===34||t===39)n=t;else if(t===62)return r}return-1}function te(e,t){let n=t-1;for(;n>=0&&D(e.charCodeAt(n));)--n;return n>=0&&e.charCodeAt(n)===47}const ne=[`tabs`,`spaces`];function M(e){return ne.includes(e)}function re(e,t){return t||(F(e)?`tabs`:(I(e),`spaces`))}const N=/* @__PURE__ */ new Set([`csharp`,`css`,`go`,`html`,`java`,`javascript`,`js`,`jsx`,`ts`,`tsx`,`typescript`,`xml`]),P=/* @__PURE__ */ new Set([`python`,`py`,`yaml`,`yml`,`ruby`,`rb`,`terraform`,`tf`]);function F(e){return N.has(e)}function I(e){return P.has(e)}function L(e,t){let n=t?.indentation??`spaces`,r=e.replace(/\r\n?/g,`
|
|
7
|
-
`),i=r.trim();if(i===``)return``;let a=B(r),o=i.split(`
|
|
8
|
-
`),s=Array.from({length:o.length});for(let e=0;e<o.length;e++){let t=o[e];if(t==null)continue;let r=z(t)?t:t.slice(a);s[e]=R(r,n)}return s.join(`
|
|
9
|
-
`)}function R(e,t){let n=0;for(;n<e.length;){let t=e[n];if(t!==` `&&t!==` `)break;n+=1}if(n===0||n===e.length)return e;let r=e.slice(0,n);return(t===`spaces`?r.replace(/\t/g,` `):r.replace(/ {2}/g,` `))+e.slice(n)}function z(e){let t=e[0];return t!=null&&t!==` `&&t!==` `}function B(e){let t=1/0,n=0,r=!0;for(let i=0;i<e.length;i++){let a=e[i];if(r){if(a===` `||a===` `){n+=1;continue}if(a===`
|
|
10
|
-
`||a===`\r`){n=0;continue}if(n<t&&(t=n,t===0))return 0;r=!1}else(a===`
|
|
11
|
-
`||a===`\r`)&&(r=!0,n=0)}return t===1/0?0:t}const V=/* @__PURE__ */ `bash.cs.csharp.css.go.html.java.javascript.js.json.jsx.plain.plaintext.py.python.rb.ruby.rust.sh.shell.terraform.text.tf.ts.tsx.txt.typescript.xml.yaml.yml`.split(`.`),H=new Set(V),U=`text`;function W(e){let t=e?.trim()??``;if(!t)return U;let n=t.indexOf(`-`),r=n===-1?t:t.slice(n+1);return G(r)?r:U}const G=e=>typeof e==`string`&&H.has(e);function K(e){if(typeof e==`boolean`)return e;if(typeof e==`string`){if(e===`true`)return!0;if(e===`false`)return!1}}function q(e){if(typeof e==`number`&&Number.isFinite(e)&&e>0)return Math.floor(e);if(typeof e==`string`&&/^\d+$/.test(e)){let t=Number.parseInt(e,10);return t>0?t:void 0}}function J(e){if(typeof e==`number`)return Number.isFinite(e)&&e>0?Math.floor(e):void 0;if(typeof e==`string`){let t=e.trim();if(/^\d+$/.test(t)){let e=Number.parseInt(t,10);return e>0?e:void 0}if(/^\d+-\d+$/.test(t)){let[e,n]=t.split(`-`);return Number.parseInt(e??``,10)>0&&Number.parseInt(n??``,10)>0?t:void 0}}}function Y(e){if(typeof e==`string`){let t=[],n=e.split(`,`);for(let e of n){let n=J(e);n!=null&&t.push(n)}return t.length>0?t:void 0}if(!Array.isArray(e))return;let t=[];for(let n of e){let e=J(n);e!=null&&t.push(e)}return t.length>0?t:void 0}const X={collapsible:!1,disableCopy:!1,indentation:void 0,mode:void 0,title:void 0};function ie(e){let t=e?.trim()??``;if(!t)return X;let n={},r=Q(t);for(let e of r){let t=e.indexOf(`=`),r=t===-1?e:e.slice(0,t),i=t===-1?void 0:e.slice(t+1);r&&(n[r]=Z(i)??!0)}return oe(n)}function Z(e){if(e==null)return;let t=e.trim(),n=t.length-1;return n>=1&&t.charCodeAt(0)===34&&t.charCodeAt(n)===34?t.slice(1,n):t}function Q(e){let t=e?.trim()??``,n=[],r=``,i=!1;for(let e=0;e<t.length;e++){let a=t[e]??``;!i&&ae(a)?r&&=(n.push(r),``):(a===`"`&&(i=!i),r+=a)}return r&&n.push(r),n}function ae(e){return e===` `||e===` `||e===`
|
|
12
|
-
`||e===`\r`}function $(e){return e===`cli`||e===`file`||e===`traffic-policy`}function oe(e){let{collapsible:n=X.collapsible,disableCopy:r=X.disableCopy,indentation:i=X.indentation,mode:a=X.mode,title:o=X.title}=e;return{collapsible:typeof n==`string`||typeof n==`boolean`?t(n):X.collapsible,disableCopy:typeof r==`string`||typeof r==`boolean`?t(r):X.disableCopy,indentation:M(i)?i:X.indentation,mode:$(a)?a:X.mode,title:typeof o==`string`?o.trim():X.title}}function se(e){let{collapsible:n,disableCopy:r,mantleCode:i,mantleCollapsible:a,mantleDisableCopy:o,mantleHighlightLines:s,mantleLanguage:c,mantleLineNumberStart:l,mantleMode:u,mantlePreHtml:d,mantleShowLineNumbers:f,mantleTitle:p,mode:m,title:h,...g}=e;return c==null&&i==null&&d==null&&f==null&&s==null&&l==null&&a==null&&o==null&&u==null&&p==null?{mantleCode:void 0,props:g}:{mantleCode:{code:typeof i==`string`?i:void 0,collapsible:(typeof a==`string`||typeof a==`boolean`?t(a):void 0)??(typeof n==`string`||typeof n==`boolean`?t(n):void 0),disableCopy:typeof o==`string`||typeof o==`boolean`?t(o):typeof r==`string`||typeof r==`boolean`?t(r):void 0,highlightLines:Y(s),language:typeof c==`string`&&G(c)?c:void 0,lineNumberStart:q(l),mode:$(u)?u:$(m)?m:void 0,preHtml:typeof d==`string`?d:void 0,rawLanguage:c,showLineNumbers:K(f),title:typeof p==`string`?p.trim():typeof h==`string`?h.trim():void 0},props:g}}export{s as S,h as _,Q as a,a as b,K as c,V as d,L as f,g,_ as h,se as i,G as l,M as m,Z as n,Y as o,re as p,ie as r,q as s,X as t,W as u,l as v,r as x,c as y};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
const e=[`alphanumeric`,`time`],t=t=>typeof t==`string`&&e.includes(t),n=e=>e,r=[`asc`,`desc`],i=e=>typeof e==`string`&&r.includes(e),a=e=>e,o=[...r],s=e=>typeof e==`string`&&o.includes(e),c=e=>e,l=[`newest-to-oldest`,`oldest-to-newest`],u=e=>typeof e==`string`&&l.includes(e),d={asc:`oldest-to-newest`,desc:`newest-to-oldest`};function f(e){if(i(e))return d[e];if(u(e))return e;throw Error(`Invalid time sorting direction given: "${e}"`)}export{o as a,t as c,e as d,d as f,f as i,u as l,a as n,s as o,l as p,n as r,i as s,c as t,r as u};
|
package/dist/field-Bpptk_9t.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{createContext as e,createElement as t,useContext as n}from"react";const r=e(void 0),i=({children:e,validation:n})=>t(r.Provider,{value:n},e),a=()=>n(r),o=e=>e!=null&&e!==!1&&e!==`false`,s=e=>(typeof e==`function`?e():e)||void 0,c=({"aria-invalid":e,defaultAriaInvalid:t=!0,validation:n})=>{let r=o(e)?`error`:s(n),i=e??(r===`error`||!t&&void 0);return{isInvalid:o(i),ariaInvalid:i,validation:r}};export{a,s as i,o as n,c as r,i as t};
|
package/dist/theme-6Q65C1Rx.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{t as e}from"./cx-CK7o_rVv.js";import{t}from"./use-matches-media-query-m860lols.js";import{n,t as r}from"./cookie-ca4g5CKp.js";import{n as i}from"./browser-only-Crr3sgA0.js";import{c as a}from"react/compiler-runtime";import{createContext as o,useContext as s,useEffect as c,useRef as l,useState as u}from"react";import d from"tiny-invariant";import{jsx as f}from"react/jsx-runtime";const p=[`light`,`dark`,`light-high-contrast`,`dark-high-contrast`],m=[`system`,...p],h=e=>e;function g(e){return typeof e==`string`&&m.includes(e)}const _=e=>e;function v(e){return typeof e==`string`&&p.includes(e)}const y=`(prefers-color-scheme: dark)`,b=`(prefers-contrast: more)`,x=`mantle-ui-theme`,S=`system`,C=o(null);function w(e){let t=a(14),{children:n,forceTheme:r,ssrCookie:o}=e,s;t[0]!==r||t[1]!==o?(s=()=>{let e=F({cookie:i()?document.cookie:o});return E(e,{forceTheme:r}),e},t[0]=r,t[1]=o,t[2]=s):s=t[2];let[d,p]=u(s),m=l(null),h,_;t[3]===r?(h=t[4],_=t[5]):(h=()=>{let e=function(e){let t=e??F({cookie:document.cookie});p(t),E(t,{forceTheme:r})};e();try{`BroadcastChannel`in window&&(m.current=new BroadcastChannel(x),m.current.addEventListener(`message`,t=>{let n=t?.data?.theme;g(n)&&e(n)}))}catch{}let t=function(t){t.key===`${x}__ping`&&e()};window.addEventListener(`storage`,t);let n=window.matchMedia(y),i=window.matchMedia(b),a=function(){e()},o=function(){document.visibilityState===`visible`&&e()};return n.addEventListener(`change`,a),i.addEventListener(`change`,a),window.addEventListener(`pageshow`,a),document.addEventListener(`visibilitychange`,o),()=>{window.removeEventListener(`storage`,t),n.removeEventListener(`change`,a),i.removeEventListener(`change`,a),window.removeEventListener(`pageshow`,a),document.removeEventListener(`visibilitychange`,o),B(m.current),m.current=null}},_=[r],t[3]=r,t[4]=h,t[5]=_),c(h,_);let v;t[6]===r?v=t[7]:(v=e=>{z(e),p(e),E(e,{forceTheme:r}),L(e,{broadcastChannel:m.current,pingKey:`${x}__ping`})},t[6]=r,t[7]=v);let S;t[8]!==v||t[9]!==d?(S=[d,v],t[8]=v,t[9]=d,t[10]=S):S=t[10];let w=S,T;return t[11]!==n||t[12]!==w?(T=/* @__PURE__ */ f(C.Provider,{value:w,children:n}),t[11]=n,t[12]=w,t[13]=T):T=t[13],T}function T(){let e=s(C);return d(e,`useTheme must be used within a ThemeProvider`),e}function E(e,{forceTheme:t}={}){if(!i())return;let n=window.document.documentElement,r=window.matchMedia(y).matches,a=window.matchMedia(b).matches,o=t??O(e,{prefersDarkMode:r,prefersHighContrast:a}),s=n.dataset.theme,c=n.dataset.appliedTheme,l=g(s)?s:void 0,u=v(c)?c:void 0;(l!==e||u!==o)&&(n.classList.remove(...p),n.classList.add(o),n.dataset.theme=e,n.dataset.appliedTheme=o)}function D(){if(!i())return{appliedTheme:void 0,theme:void 0};let e=window.document.documentElement,t=g(e.dataset.theme)?e.dataset.theme:void 0;return{appliedTheme:v(e.dataset.appliedTheme)?e.dataset.appliedTheme:void 0,theme:t}}function O(e,{prefersDarkMode:t,prefersHighContrast:n}){return e===`system`?A({prefersDarkMode:t,prefersHighContrast:n}):e}function k(){let e=a(4),n=s(C),r=n==null?`system`:n[0],i=t(y),o=t(b),c;return e[0]!==i||e[1]!==o||e[2]!==r?(c=O(r,{prefersDarkMode:i,prefersHighContrast:o}),e[0]=i,e[1]=o,e[2]=r,e[3]=c):c=e[3],c}function A({prefersDarkMode:e,prefersHighContrast:t}){return t?e?`dark-high-contrast`:`light-high-contrast`:e?`dark`:`light`}function j(e){let{storageKey:t,defaultTheme:n,themes:r,resolvedThemes:i,prefersDarkModeMediaQuery:a,prefersHighContrastMediaQuery:o,forceTheme:s}=e;function c(e){return typeof e==`string`&&r.includes(e)}function l(e){let t=document.cookie;if(!t)return null;try{let n=t.split(`;`).find(t=>t.trim().startsWith(`${e}=`))?.trim().slice(e.length+1);return n?decodeURIComponent(n):null}catch{return null}}function u(e,t){let n=/* @__PURE__ */ new Date;n.setFullYear(n.getFullYear()+1);let r=window.location.hostname,i=window.location.protocol,a=r===`ngrok.com`||r.endsWith(`.ngrok.com`)?`; domain=.ngrok.com`:``,o=i===`https:`?`; Secure`:``;return`${e}=${encodeURIComponent(t)}; expires=${n.toUTCString()}; path=/${a}; SameSite=Lax${o}`}function d(e,t){try{document.cookie=u(e,t)}catch{}}function f(e,t,n){return e===`system`?n?t?`dark-high-contrast`:`light-high-contrast`:t?`dark`:`light`:e}let p=null,m=null,h=null;try{p=l(t)}catch{}if(c(p))h=p;else{try{m=window.localStorage?.getItem(t)??null}catch{}c(m)&&(h=m)}let g=c(h)?h:n,_=matchMedia(a).matches,v=matchMedia(o).matches,y=s??f(g,_,v),b=document.documentElement;if(b.dataset.appliedTheme!==y||b.dataset.theme!==g){for(let e of i)b.classList.remove(e);b.classList.add(y),b.dataset.theme=g,b.dataset.appliedTheme=y}let x=c(p);try{if(c(m)&&!x){d(t,m);try{window.localStorage.removeItem(t)}catch{}}else x||d(t,g)}catch{}}function M(e){let t={storageKey:x,defaultTheme:S,themes:m,resolvedThemes:p,prefersDarkModeMediaQuery:y,prefersHighContrastMediaQuery:b,forceTheme:e};return`(${j.toString()})(${JSON.stringify(t)})`}const N=e=>{let t=a(7),{forceTheme:n,nonce:r}=e,i;t[0]===n?i=t[1]:(i=M(n),t[0]=n,t[1]=i);let o;t[2]===i?o=t[3]:(o={__html:i},t[2]=i,t[3]=o);let s;return t[4]!==r||t[5]!==o?(s=/* @__PURE__ */ f(`script`,{dangerouslySetInnerHTML:o,nonce:r,suppressHydrationWarning:!0}),t[4]=r,t[5]=o,t[6]=s):s=t[6],s};function P(t){let n=a(16),r;n[0]===t?r=n[1]:(r=t===void 0?{}:t,n[0]=t,n[1]=r);let o=r,s;n[2]===o?s=n[3]:(s=o??{},n[2]=o,n[3]=s);let{className:c,forceTheme:l,ssrCookie:u}=s,d=c===void 0?``:c,f,p;if(i()){let e;if(n[7]===Symbol.for(`react.memo_cache_sentinel`)){let t=window.matchMedia(y).matches,r=window.matchMedia(b).matches;f=F({cookie:document.cookie}),e=O(f,{prefersDarkMode:t,prefersHighContrast:r}),n[7]=e,n[8]=f}else e=n[7],f=n[8];p=e}else{let e;n[4]===u?(e=n[5],f=n[6]):(f=F({cookie:u}),e=O(f,{prefersDarkMode:!1,prefersHighContrast:!1}),n[4]=u,n[5]=e,n[6]=f),p=e}let m=l??p,h;n[9]!==m||n[10]!==d?(h=e(d,m),n[9]=m,n[10]=d,n[11]=h):h=n[11];let g;return n[12]!==m||n[13]!==f||n[14]!==h?(g={className:h,"data-applied-theme":m,"data-theme":f},n[12]=m,n[13]=f,n[14]=h,n[15]=g):g=n[15],g}function F({cookie:e}){if(!e)return S;let t=n(e,x);return g(t)?t:S}function I(e){return r(e,x)}function L(e,t){let{broadcastChannel:n,pingKey:r}=t;try{if(n){n.postMessage({theme:e,timestamp:Date.now()});return}}catch{}try{localStorage.setItem(r,JSON.stringify({theme:e,timestamp:Date.now()}))}catch{}}function R(e){let t=/* @__PURE__ */ new Date;t.setFullYear(t.getFullYear()+1);let{hostname:n,protocol:r}=window.location,i=n===`ngrok.com`||n.endsWith(`.ngrok.com`)?`; domain=.ngrok.com`:``,a=r===`https:`?`; Secure`:``;return`${x}=${encodeURIComponent(e)}; expires=${t.toUTCString()}; path=/${i}; SameSite=Lax${a}`}function z(e){if(i())try{document.cookie=R(e)}catch{}}function B(e){if(e!=null)try{e.close()}catch{}}export{M as a,P as c,h as d,v as f,m as h,F as i,T as l,p as m,w as n,D as o,g as p,I as r,k as s,N as t,_ as u};
|