PageSourceSearch

https://kodywallet.lovable.app/assets/GasHistory-YtTSsYWj.js

js kodywallet.lovable.app collected 2026-10-03 03:37:34 UTC 2,894 bytes, 2 lines download raw bytes

1import{j as e}from"./vendor-query-C4QtGD8R.js";import{r as d}from"./vendor-web3-mi09CyaI.js";import{C as m,b as c,c as x,a as p}from"./card-D2_mOq8f.js";import{F as h}from"./fuel-D8aMkdIX.js";import{T as g}from"./trending-up-Brp94x_o.js";import{T as u}from"./trending-down-5Ezr-k0z.js";import"./index-ygc0PZs_.js";import"./vendor-charts-DZJdoORE.js";import"./vendor-ui-BBZYHNnl.js";import"./vendor-supabase-DauP3j-J.js";import"./vendor-react-C2ZpyAAy.js";function f(){const t=[];let s=25;for(let r=23;r>=0;r--){s+=(Math.random()-.48)*8,s=Math.max(8,Math.min(120,s));const o=new Date;o.setHours(o.getHours()-r),t.push({hour:`${o.getHours().toString().padStart(2,"0")}:00`,gwei:Math.round(s*10)/10})}return t}function L(){const t=d.useMemo(f,[]),s=Math.max(...t.map(a=>a.gwei)),r=Math.min(...t.map(a=>a.gwei)),o=t[t.length-1].gwei,i=Math.round(t.reduce((a,l)=>a+l.gwei,0)/t.length*10)/10,n=o>i;return e.jsxs(m,{className:"glass border-border/40",children:[e.jsx(c,{className:"pb-3",children:e.jsxs(x,{className:"text-sm flex items-center gap-2",children:[e.jsx(h,{className:"w-4 h-4 text-primary"})," Gas Price History (24h)"]})}),e.jsxs(p,{className:"space-y-3",children:[e.jsx("div",{className:"grid grid-cols-4 gap-2",children:[{label:"Now",value:`${o} gwei`,color:"text-primary"},{label:"Avg",value:`${i} gwei`,color:"text-muted-foreground"},{label:"Low",value:`${r} gwei`,color:"text-emerald-500"},{label:"High",value:`${s} gwei`,color:"text-red-500"}].map(a=>e.jsxs("div",{className:"text-center",children:[e.jsx("p",{className:"text-[10px] text-muted-foreground",children:a.label}),e.jsx("p",{className:`text-xs font-bold ${a.color}`,children:a.value})]},a.label))}),e.jsxs("div",{className:"flex items-center gap-1 text-[10px] text-muted-foreground justify-center",children:[n?e.jsx(g,{className:"w-3 h-3 text-red-500"}):e.jsx(u,{className:"w-3 h-3 text-emerald-500"}),"Gas is ",n?"above":"below"," average"]}),e.jsxs("svg",{viewBox:"0 0 480 100",className:"w-full h-20",children:[e.jsx("defs",{children:e.jsxs("linearGradient",{id:"gasGrad",x1:"0",y1:"0",x2:"0",y2:"1",children:[e.jsx("stop",{offset:"0%",stopColor:"hsl(var(--primary))",stopOpacity:"0.3"}),e.jsx("stop",{offset:"100%",stopColor:"hsl(var(--primary))",stopOpacity:"0"})]})}),e.jsx("path",{d:`M0,${100-(t[0].gwei-r)/(s-r)*80} ${t.map((a,l)=>`L${l/(t.length-1)*480},${100-(a.gwei-r)/(s-r)*80}`).join(" ")} L480,100 L0,100 Z`,fill:"url(#gasGrad)"}),e.jsx("path",{d:t.map((a,l)=>`${l===0?"M":"L"}${l/(t.length-1)*480},${100-(a.gwei-r)/(s-r)*80}`).join(" "),fill:"none",stroke:"hsl(var(--primary))",strokeWidth:"2"})]}),e.jsxs("div",{className:"flex justify-between text-[9px] text-muted-foreground/50",children:[e.jsx("span",{children:t[0].hour}),e.jsx("span",{children:t[Math.floor(t.length/2)].hour}),e.jsx("span",{children:t[t.length-1].hour})]})]})]})}export{L as default};
2//# sourceMappingURL=GasHistory-YtTSsYWj.js.map

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.