import"./react-C1sqhVEE.js";import{d as l,_ as s,e as i}from"./Settings-C7_TiiRH.js";import{t as e,g as n}from"./index-D8wxMOat.js";import{j as m}from"./ui-cEB64NN_.js";import{u as p,i as g,a as d,b as c,c as h,d as u,e as b,f,g as y}from"./echarts-gihz4qUC.js";import"./syntaxHighlighter-C6zraU67.js";import"./reactQuery-CcoxLypZ.js";import"./reactRouter-B7BPABFu.js";import"./dateFns-DhBcwMxz.js";p([g,d,c,h,u,b,f,y]);const $=a=>{const o=a[0];let t=`<strong>${o.name}</strong><br/>`;const r=n(o.value);return t+=`<small>Average TPDEX: ${o.value} (${r.label})</small>`,t},x=a=>new Date(a).toLocaleTimeString(void 0,{hour:"2-digit",minute:"2-digit"}),D=({data:a})=>{const o={...l,grid:{...l.grid,left:8,right:64,top:64,bottom:24},xAxis:{type:"category",data:a.map(t=>x(t.datetime))},yAxis:{axisLabel:{show:!1}},tooltip:{...l.tooltip,formatter:$},series:[{data:a.map(t=>t.value),type:"line",smooth:!0,symbol:"none",lineStyle:{width:4}}],visualMap:{bottom:4,right:4,pieces:[...Array(e.length-1).keys()].map(t=>t?{label:e[t].label,lt:e[t-1].threshold,gte:e[t].threshold,color:e[t].bgColor}:{label:e[t].label,gte:e[t].threshold,color:e[t].bgColor}),outOfRange:{color:"#999"}}};return m(s,{echarts:i,option:o,notMerge:!0,lazyUpdate:!0,opts:{height:240,width:"auto"}})};export{D as default};
