zframes 0.5.2 → 0.5.3
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/NOTICE +6 -2
- package/dist/index.js +6 -1
- package/package.json +4 -4
- package/runtime/assets/{bitcoin-dominance-CtnczH5N.js → bitcoin-dominance-CxfMBVwW.js} +1 -1
- package/runtime/assets/{breakeven-zbCEQ5ag.js → breakeven-BrpmE2y2.js} +1 -1
- package/runtime/assets/{breathing-6Wmy_hqF.js → breathing-Bjv7D86F.js} +1 -1
- package/runtime/assets/{btc-blocks-D1xOLm2L.js → btc-blocks-Cy-YFeqC.js} +1 -1
- package/runtime/assets/{btc-difficulty-BTbKIqrl.js → btc-difficulty-CQ_30M6B.js} +1 -1
- package/runtime/assets/{btc-fees-5Geh2TSa.js → btc-fees-DsYgskwn.js} +1 -1
- package/runtime/assets/{btc-hashrate-DZfnxUsi.js → btc-hashrate-C0dYT_WJ.js} +1 -1
- package/runtime/assets/{btc-mempool-8oOMDiaW.js → btc-mempool-DipekM7O.js} +1 -1
- package/runtime/assets/{calculator-D91iI7KM.js → calculator-zC8onHXp.js} +1 -1
- package/runtime/assets/{checklist-DNrOJw0w.js → checklist-baxMKxEm.js} +1 -1
- package/runtime/assets/{clock-BzAIAbhU.js → clock-x9v1tYQm.js} +1 -1
- package/runtime/assets/{coin-movers-99W2EABZ.js → coin-movers-fIxzBuhy.js} +1 -1
- package/runtime/assets/{countdown-ZAJmbykg.js → countdown-BlyeM771.js} +1 -1
- package/runtime/assets/{daily-analysis-CS5MqofA.js → daily-analysis-DxjxE53t.js} +1 -1
- package/runtime/assets/{day-meter-DzBvLcpd.js → day-meter-9YEIbKbk.js} +1 -1
- package/runtime/assets/{dex-volume-chart-BfnczfAT.js → dex-volume-chart-CIN2oKpJ.js} +1 -1
- package/runtime/assets/{dex-volume-treemap-CLyIrkgU.js → dex-volume-treemap-CqHdMsnd.js} +1 -1
- package/runtime/assets/{dice-CAvRf0md.js → dice-DnddcY-J.js} +1 -1
- package/runtime/assets/{dino-game-gsyCpJ-0.js → dino-game-D6AH1SSj.js} +1 -1
- package/runtime/assets/{divider-DCTu-qNh.js → divider-Bu8aGlm1.js} +1 -1
- package/runtime/assets/{drawdy-CZWCFtog.js → drawdy-BhOQeakE.js} +1 -1
- package/runtime/assets/{editor-Ckt9OQ98.js → editor-Ca-voh3h.js} +1 -1
- package/runtime/assets/{fear-greed-DOcPswrx.js → fear-greed-i87oWLnT.js} +1 -1
- package/runtime/assets/{filings-feed-Cs--DpYl.js → filings-feed-Cxg9eG9S.js} +1 -1
- package/runtime/assets/{financial-stress-BqnxLk2O.js → financial-stress-Bv_reW65.js} +1 -1
- package/runtime/assets/{flappy-bird-DaasqVGg.js → flappy-bird-BENHBDEL.js} +1 -1
- package/runtime/assets/{fundamentals-GseULnsD.js → fundamentals-AlhngJ8G.js} +1 -1
- package/runtime/assets/{funding-heatmap-2RvVLTPN.js → funding-heatmap-B4RGXX4K.js} +1 -1
- package/runtime/assets/{funding-rate-chart-DCRKHp6g.js → funding-rate-chart-Cg6gi0YC.js} +1 -1
- package/runtime/assets/{fx-board-CVW6VmbY.js → fx-board-BqGsP0Xx.js} +1 -1
- package/runtime/assets/{heading-BaRMJq2t.js → heading-Dr7Q6vy_.js} +1 -1
- package/runtime/assets/{holiday-calendar-2OBfwbh-.js → holiday-calendar-C1fruUVL.js} +1 -1
- package/runtime/assets/{image-CuTXEV7Q.js → image-BulRsYTV.js} +1 -1
- package/runtime/assets/{index-CH54P4Cn.js → index-BgSQpj_B.js} +43 -43
- package/runtime/assets/{inflation-pulse-B8E9uzQB.js → inflation-pulse-Q-3bZn55.js} +1 -1
- package/runtime/assets/{journal-log-7APM_99k.js → journal-log-FuAPC6JH.js} +1 -1
- package/runtime/assets/{journal-open-CcdGuysA.js → journal-open-BREaG6Cs.js} +1 -1
- package/runtime/assets/{journal-results-CUTn4-kq.js → journal-results-Y_pKQcgg.js} +1 -1
- package/runtime/assets/{journal-score-C31dg2yL.js → journal-score-ZATtCKrj.js} +1 -1
- package/runtime/assets/{journal-ui-C5ueSjZx.js → journal-ui-C_1ADbUX.js} +1 -1
- package/runtime/assets/{labor-market-DgvDQtFo.js → labor-market-DVybIeSN.js} +1 -1
- package/runtime/assets/{lightning-stats-CiUlm-e_.js → lightning-stats-ByvWkKyP.js} +1 -1
- package/runtime/assets/{link-grid-DlsY59eq.js → link-grid-CJC48i5r.js} +1 -1
- package/runtime/assets/{market-cap-treemap-6vqLUgVk.js → market-cap-treemap-CpnOP_gY.js} +1 -1
- package/runtime/assets/{market-hours-BArlXOQB.js → market-hours-B9zPCvQk.js} +1 -1
- package/runtime/assets/{marquee-2Di2SqI2.js → marquee-D8GTgVmy.js} +1 -1
- package/runtime/assets/{mining-pools-Bg02wm2V.js → mining-pools-DiyEBr6a.js} +1 -1
- package/runtime/assets/{mover-row-C8040L85.js → mover-row-CO2STKkw.js} +1 -1
- package/runtime/assets/{national-debt-BS57WjA3.js → national-debt-CcTydivP.js} +1 -1
- package/runtime/assets/{news-feed-oBCTiuoo.js → news-feed-D4xS-sLD.js} +1 -1
- package/runtime/assets/{note-BLWlz52v.js → note-BXsj5NlE.js} +1 -1
- package/runtime/assets/{open-interest-DxMqZcmu.js → open-interest-DaFRJd2O.js} +1 -1
- package/runtime/assets/{options-iv-CgIIFdpN.js → options-iv-MpSqgS3E.js} +1 -1
- package/runtime/assets/{options-oi-strike-blRp4kmB.js → options-oi-strike-BHF28ASR.js} +1 -1
- package/runtime/assets/{options-put-call-CyOwXBVQ.js → options-put-call-_ZFaepBW.js} +1 -1
- package/runtime/assets/{pomodoro-BKJlh-bz.js → pomodoro-CxHVmgqp.js} +1 -1
- package/runtime/assets/{portfolio-allocation-Cat1vq2_.js → portfolio-allocation-Cf251dcH.js} +1 -1
- package/runtime/assets/{portfolio-common-DeyRfuNV.js → portfolio-common-DnESc3oR.js} +1 -1
- package/runtime/assets/{portfolio-holdings-DDDhMMFL.js → portfolio-holdings-2vYKEk7f.js} +1 -1
- package/runtime/assets/{portfolio-value-D9qrGeZp.js → portfolio-value-B-7uIpG4.js} +1 -1
- package/runtime/assets/{price-chart-CQJNOBtu.js → price-chart-Cx_2scgb.js} +1 -1
- package/runtime/assets/{price-compare-DqBiHd7S.js → price-compare-DQcEOpnr.js} +1 -1
- package/runtime/assets/{price-liveline-BlVGC2-R.js → price-liveline-TTo-aOFd.js} +1 -1
- package/runtime/assets/{price-ticker-QdVoVaQh.js → price-ticker-Cp7yYsNm.js} +1 -1
- package/runtime/assets/{protocol-fees-treemap-39F-aE33.js → protocol-fees-treemap-D-koQrKr.js} +1 -1
- package/runtime/assets/{protocol-tvl-chart-DZOgbMZu.js → protocol-tvl-chart-CDZkrQuF.js} +1 -1
- package/runtime/assets/{protocol-tvl-treemap-DusQ6xL2.js → protocol-tvl-treemap-I8fjLZU7.js} +1 -1
- package/runtime/assets/{quote-Di049ggj.js → quote-CKEEp9tF.js} +1 -1
- package/runtime/assets/{rates-board-Dm3tb6-P.js → rates-board-BElUHlYN.js} +1 -1
- package/runtime/assets/{returns-projector-BiMx_kSw.js → returns-projector-DjIbvas1.js} +1 -1
- package/runtime/assets/{risk-reward-1Q_Kt75s.js → risk-reward-pVHqmm_g.js} +1 -1
- package/runtime/assets/{rules-card-BkAX9PEq.js → rules-card-uMZQ6oP0.js} +1 -1
- package/runtime/assets/scene-uwfOGek1.js +1 -0
- package/runtime/assets/{session-progress-D_1dzPzM.js → session-progress-Djhvb1G5.js} +1 -1
- package/runtime/assets/{short-volume-U-uFonb2.js → short-volume-CiBfmCKw.js} +1 -1
- package/runtime/assets/{snake-Dp4E3Dcv.js → snake-CYXVjy8d.js} +1 -1
- package/runtime/assets/{spotify-embed-Cw95WZjV.js → spotify-embed-CGYKFOmX.js} +1 -1
- package/runtime/assets/{stopwatch-B2_iDkKK.js → stopwatch-Cl10sfaX.js} +1 -1
- package/runtime/assets/{top-movers--vCUiTII.js → top-movers-vvOomk6S.js} +1 -1
- package/runtime/assets/{treasury-auctions-BpzYivLg.js → treasury-auctions-JMoATy9T.js} +1 -1
- package/runtime/assets/{tvl-treemap-BYgD9bNy.js → tvl-treemap-B28_19EZ.js} +1 -1
- package/runtime/assets/{video-D-nBm697.js → video-DjiOnvMm.js} +1 -1
- package/runtime/assets/{yield-curve-8IsrMS_9.js → yield-curve-Dj5vJwI4.js} +1 -1
- package/runtime/index.html +1 -1
- package/runtime/assets/unicorn-scene-DcohHRPZ.js +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as f,j as t}from"./react-qoZPGuNy.js";import{a as p,c as j}from"./format-CfAcS4D8.js";import{f as w,Y as y,M}from"./index-
|
|
1
|
+
import{r as f,j as t}from"./react-qoZPGuNy.js";import{a as p,c as j}from"./format-CfAcS4D8.js";import{f as w,Y as y,M}from"./index-BgSQpj_B.js";import{F as v}from"./ui-Bq3RQsdJ.js";import{M as P}from"./mini-line-chart-CHM5UBjJ.js";import"./d3-xK4fOkBU.js";import"./utils-DaT-yT0k.js";y.schema;const S="CUUR0000SA0";function g(a,o){return!o||o<=0?null:(a/o-1)*100}function F({config:a}){const x=new Date().getUTCFullYear(),C=x-2,{series:e,isLoading:N}=M(S,C,x),n=f.useMemo(()=>((e==null?void 0:e.points)??[]).slice(-a.months),[a.months,e==null?void 0:e.points]),s=n.at(-1),r=n.at(-2),c=s?n.find(i=>{const h=new Date(i.time),u=new Date(s.time);return h.getUTCFullYear()===u.getUTCFullYear()-1&&h.getUTCMonth()===u.getUTCMonth()}):void 0,b=f.useMemo(()=>n.map(i=>({date:new Date(i.time).toISOString(),value:i.value})),[n]);if(N)return t.jsx(v,{loading:!0,children:"loading CPI…"});if(!e||!s)return t.jsx(v,{children:"no CPI data yet"});const l=g(s.value,r==null?void 0:r.value),d=g(s.value,c==null?void 0:c.value),m=j(d??l??0);return t.jsxs("div",{className:"flex h-full flex-col justify-center gap-3",children:[t.jsxs("div",{className:"flex items-start justify-between gap-3",children:[t.jsxs("div",{children:[t.jsx("div",{className:"caption text-soft uppercase",children:"BLS CPI-U"}),t.jsx("div",{className:"body-sm text-normal",children:s.date})]}),t.jsx("div",{className:"caption text-soft text-right",children:"monthly"})]}),t.jsxs("div",{className:"flex items-end justify-between gap-3",children:[t.jsxs("div",{children:[t.jsx("div",{className:"metric-xl leading-none",style:{color:m,textShadow:`0 0 24px ${m}44`},children:d!==null?p(d):"--"}),t.jsx("div",{className:"caption text-soft mt-1",children:"year over year"})]}),t.jsxs("div",{className:"text-right",children:[t.jsx("div",{className:"caption text-soft",children:"index"}),t.jsx("div",{className:"body-md text-strong font-bold tabular-nums",children:s.value.toFixed(3)}),t.jsx("div",{className:"caption text-soft mt-2",children:"month over month"}),t.jsx("div",{className:"body-md font-bold tabular-nums",style:{color:j(l??0)},children:l!==null?p(l):"--"})]})]}),t.jsx(P,{data:b,width:210,height:46,color:m}),t.jsxs("div",{className:"caption text-soft",children:[e.label," · ",n.length," monthly observations"]})]})}const _=w({...y,component:F});export{_ as inflationPulseFrame};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as a,j as s}from"./react-qoZPGuNy.js";import{f as G,s as U,v as P,k as H,h as c,A as _}from"./index-
|
|
1
|
+
import{r as a,j as s}from"./react-qoZPGuNy.js";import{f as G,s as U,v as P,k as H,h as c,A as _}from"./index-BgSQpj_B.js";import{i as $}from"./content-shared-BZ1XzrJx.js";import{d as M,a as J,c as K,U as q,D as X}from"./format-CfAcS4D8.js";import{C as Y,d as F,a as V,l as Z}from"./journal-store-KCRoPnI_.js";import{s as ee}from"./ui-Bq3RQsdJ.js";const se=["xyz:*"],I=v=>Object.entries(v).filter(([,t])=>t.markPx>0).map(([t])=>t).sort((t,m)=>c(t).localeCompare(c(m)));U.schema;const T=[{label:"funding reset",cls:"mean-reversion"},{label:"oversold bounce",cls:"mean-reversion"},{label:"range reclaim",cls:"mean-reversion"},{label:"breakout",cls:"breakout"},{label:"momentum / trend",cls:"breakout"},{label:"positioning flush",cls:"positioning"},{label:"catalyst / earnings",cls:"macro"}];function te(v){var R;const[t,m]=a.useState("xyz:TSLA"),[j,Q]=a.useState("long"),[N,C]=a.useState(!1),[p,k]=a.useState(""),[x,S]=a.useState(null),[b,w]=a.useState(""),[h,W]=a.useState(65),[L,O]=a.useState(!1),i=P(se,6e4),u=P(void 0,6e4),z=a.useMemo(()=>({...u,...i}),[u,i]),d=a.useMemo(()=>[...I(i),...I(u)],[i,u]),B=H([t]),f=e=>{var l;return B[e]??((l=z[e])==null?void 0:l.markPx)},g=f(t),y=(R=z[t])==null?void 0:R.changePct,o=x!=null?T[x]:null,n=o?Y[o.cls]:null,A=n?n.hits/n.n>=.55:!0,D=a.useMemo(()=>{const e=p.trim().toLowerCase();return(e?d.filter(r=>c(r).toLowerCase().includes(e)):d).slice(0,80)},[p,d]);function E(){if(!o)return;const e=b.trim()?`${o.label} — ${b.trim()}`:o.label;Z({sym:t,dir:j,confidence:h,claim:e,cls:o.cls,entry:g}),S(null),w(""),O(!0),window.setTimeout(()=>O(!1),1100)}return s.jsxs("div",{className:"flex h-full flex-col gap-2.5",children:[s.jsxs("div",{className:"relative",children:[s.jsxs("button",{type:"button",onClick:()=>C(e=>!e),className:`flex w-full items-center gap-2 px-2.5 py-2 ${$}`,children:[s.jsx(_,{symbol:t,size:20}),s.jsx("span",{className:"body-md text-strong font-semibold",children:c(t)}),s.jsxs("span",{className:"ml-auto flex items-baseline gap-2 tabular-nums",children:[s.jsx("span",{className:"body-sm text-strong",children:g!=null?M(g):"…"}),y!=null&&s.jsx("span",{className:"caption",style:{color:K(y)},children:J(y)})]}),s.jsx("span",{className:"caption text-disabled ml-1",children:N?"▲":"▼"})]}),N&&s.jsxs("div",{className:"absolute left-0 right-0 top-full z-50 mt-1 flex flex-col gap-1 rounded-md p-1.5 shadow-xl",style:{background:"hsl(248 32% 9%)",border:"1px solid var(--color-accent-line)"},children:[s.jsx("input",{autoFocus:!0,value:p,onChange:e=>k(e.target.value),placeholder:"search ticker…",className:"body-sm w-full rounded bg-white/[0.05] px-2 py-1.5 text-strong outline-none placeholder:text-disabled"}),s.jsxs("div",{className:`flex max-h-44 flex-col ${ee}`,children:[D.map(e=>s.jsxs("button",{type:"button",onClick:()=>{m(e),C(!1),k("")},className:"flex items-center gap-2 rounded px-2 py-1.5 transition-colors hover:bg-white/[0.06]",children:[s.jsx(_,{symbol:e,size:16}),s.jsx("span",{className:"body-sm text-normal",children:c(e)}),s.jsx("span",{className:"caption text-soft ml-auto tabular-nums",children:f(e)!=null?M(f(e)):"—"})]},e)),D.length===0&&s.jsx("span",{className:"caption text-disabled px-2 py-2",children:d.length===0?"loading universe…":"no Hyperliquid market for that"})]})]})]}),s.jsx("div",{className:"flex items-center gap-2",children:["long","short"].map(e=>{const l=j===e;return s.jsx("button",{type:"button",onClick:()=>Q(e),className:"body-sm flex-1 rounded-md py-1.5 font-bold uppercase tracking-wide transition-colors",style:{color:l?F(e):"var(--color-soft)",background:l?"var(--color-surface)":"rgba(255,255,255,0.03)",border:`1px solid ${l?F(e)+"55":"transparent"}`},children:e},e)})}),s.jsx("div",{className:"flex flex-wrap gap-1.5",children:T.map((e,l)=>{const r=x===l;return s.jsx("button",{type:"button",onClick:()=>S(r?null:l),className:"caption rounded-full px-2.5 py-1 transition-colors",style:{color:r?"var(--color-strong)":"var(--color-soft)",background:r?"hsl(var(--zf-accent-hue, 242) 80% 60% / 0.3)":"rgba(255,255,255,0.04)",border:`1px solid ${r?"var(--color-accent-line)":"transparent"}`},children:e.label},e.label)})}),s.jsx("input",{value:b,onChange:e=>w(e.target.value),onKeyDown:e=>e.key==="Enter"&&E(),placeholder:"add a note (optional)",className:`body-sm w-full rounded-md px-2.5 py-1.5 text-strong outline-none placeholder:text-disabled ${$}`}),n&&s.jsxs("span",{className:"caption",style:{color:A?q:X},children:["your last ",n.n," ",V[o.cls]," calls: ",n.hits,"/",n.n,A?" · your edge":" · a leak — size down"]}),s.jsxs("div",{className:"mt-auto flex items-center gap-2.5",children:[s.jsx("span",{className:"caption text-disabled",children:"how sure"}),s.jsx("input",{type:"range",min:50,max:95,step:1,value:h,onChange:e=>W(Number(e.target.value)),className:"h-1 flex-1 cursor-pointer",style:{accentColor:"hsl(var(--zf-accent-hue, 242) 85% 68%)"}}),s.jsxs("span",{className:"body-sm text-strong w-9 tabular-nums",children:[h,"%"]}),s.jsx("button",{type:"button",onClick:E,disabled:!o,className:"caption rounded px-3 py-1.5 font-bold uppercase tracking-wide transition-opacity disabled:opacity-40",style:{color:"var(--color-strong)",background:L?q+"55":"hsl(var(--zf-accent-hue, 242) 80% 60% / 0.35)"},children:L?"logged ✓":"log"})]})]})}const ie=G({...U,component:te});export{ie as journalLogFrame};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as a,j as t}from"./react-qoZPGuNy.js";import{u,r as l}from"./journal-store-KCRoPnI_.js";import{J as f,O as d}from"./journal-ui-
|
|
1
|
+
import{r as a,j as t}from"./react-qoZPGuNy.js";import{u,r as l}from"./journal-store-KCRoPnI_.js";import{J as f,O as d}from"./journal-ui-C_1ADbUX.js";import{f as w,w as i,k as x}from"./index-BgSQpj_B.js";import{s as j}from"./ui-Bq3RQsdJ.js";import"./format-CfAcS4D8.js";import"./content-shared-BZ1XzrJx.js";i.schema;function v({config:m}){const{open:s}=u(),[n,c]=a.useState(()=>Date.now()),r=x(s.map(o=>o.symbol));if(a.useEffect(()=>{const o=window.setInterval(()=>c(Date.now()),1e3);return()=>window.clearInterval(o)},[]),a.useEffect(()=>{for(const o of s){const e=r[o.symbol];n>=o.resolveAt&&e!=null&&l(o.id,e)}},[n,s,r]),s.length===0)return t.jsx(f,{children:"no open calls — log a read in Journal · Log"});const p=s.slice(0,m.max);return t.jsx("div",{className:`flex flex-col gap-2 ${j}`,children:p.map(o=>{const e=r[o.symbol];return t.jsx(d,{call:o,now:n,mid:e,onClose:e!=null?()=>l(o.id,e):void 0},o.id)})})}const b=w({...i,component:v});export{b as journalOpenFrame};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{j as r}from"./react-qoZPGuNy.js";import{u as t}from"./journal-store-KCRoPnI_.js";import{J as n,R as m}from"./journal-ui-
|
|
1
|
+
import{j as r}from"./react-qoZPGuNy.js";import{u as t}from"./journal-store-KCRoPnI_.js";import{J as n,R as m}from"./journal-ui-C_1ADbUX.js";import{f as i,x as o}from"./index-BgSQpj_B.js";import{s as u}from"./ui-Bq3RQsdJ.js";import"./format-CfAcS4D8.js";import"./content-shared-BZ1XzrJx.js";o.schema;function c({config:a}){const{resolved:s}=t();if(s.length===0)return r.jsx(n,{children:"nothing graded yet — your calls resolve here"});const l=s.slice(0,a.max);return r.jsx("div",{className:`flex flex-col gap-2 ${u}`,children:l.map(e=>r.jsx(m,{call:e},e.id))})}const g=i({...o,component:c});export{g as journalResultsFrame};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{j as o}from"./react-qoZPGuNy.js";import{U as h,D as x}from"./format-CfAcS4D8.js";import{u as g,a as c,C as n}from"./journal-store-KCRoPnI_.js";import{S as d}from"./journal-ui-
|
|
1
|
+
import{j as o}from"./react-qoZPGuNy.js";import{U as h,D as x}from"./format-CfAcS4D8.js";import{u as g,a as c,C as n}from"./journal-store-KCRoPnI_.js";import{S as d}from"./journal-ui-C_1ADbUX.js";import{f as b,y as p}from"./index-BgSQpj_B.js";import"./content-shared-BZ1XzrJx.js";p.schema;function j(){const r=Object.keys(n).map(e=>({cls:e,rate:n[e].hits/n[e].n}));return r.sort((e,s)=>s.rate-e.rate),{edge:r[0],leak:r[r.length-1]}}function v(r){const{resolved:e}=g(),{edge:s,leak:t}=j(),a=e.length,u=a?Math.round(e.reduce((i,f)=>i+f.confidence,0)/a):0,m=a?Math.round(e.filter(i=>i.verdict==="hit").length/a*100):0,l=u-m;return o.jsxs("div",{className:"flex h-full flex-col gap-2",children:[o.jsxs("div",{className:"grid grid-cols-3 gap-2",children:[o.jsx(d,{label:"your edge",value:`${Math.round(s.rate*100)}%`,sub:c[s.cls],color:h}),o.jsx(d,{label:"your leak",value:`${Math.round(t.rate*100)}%`,sub:`${c[t.cls]} — size down`,color:x}),o.jsx(d,{label:"calibration",value:a?`${u}→${m}`:"—",sub:a?l>4?`overconfident +${l}`:l<-4?`underconfident ${l}`:"well-calibrated":"no calls yet",color:Math.abs(l)>4?"#f4a259":h})]}),o.jsx("div",{className:"rounded-md px-3 py-2",style:{background:"hsl(var(--zf-accent-hue, 242) 80% 60% / 0.1)",border:"1px solid var(--color-accent-line)"},children:o.jsxs("p",{className:"body-sm text-normal leading-snug",children:[o.jsx("span",{className:"font-semibold text-highlight",children:"zAI ·"})," Sharpest on ",c[s.cls],". You leak on ",c[t.cls]," —"," ",n[t.cls].hits,"/",n[t.cls].n,", and your kill rule tripped on most of them. Size those down."]})})]})}const L=b({...p,component:v});export{L as journalScoreFrame};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{j as s}from"./react-qoZPGuNy.js";import{A as b,h}from"./index-
|
|
1
|
+
import{j as s}from"./react-qoZPGuNy.js";import{A as b,h}from"./index-BgSQpj_B.js";import{i as j}from"./content-shared-BZ1XzrJx.js";import{U as c,D as d,a as p,d as l}from"./format-CfAcS4D8.js";import{d as x,c as g,t as y,a as N,b as v,e as w}from"./journal-store-KCRoPnI_.js";function m({dir:e}){return s.jsx("span",{className:"caption rounded px-1.5 py-0.5 font-bold uppercase tracking-wide",style:{color:x(e),background:"var(--color-surface)"},children:e})}function u({symbol:e}){return s.jsxs("span",{className:"flex items-center gap-1.5",children:[s.jsx(b,{symbol:e,size:16}),s.jsx("span",{className:"body-sm text-strong font-semibold",children:h(e)})]})}function S({label:e,value:a,sub:t,color:n}){return s.jsxs("div",{className:`flex flex-col gap-0.5 px-2.5 py-2 ${j}`,children:[s.jsx("span",{className:"caption text-soft uppercase tracking-wide",children:e}),s.jsx("span",{className:"metric-sm font-bold leading-none tabular-nums",style:{color:n??"var(--color-strong)"},children:a}),t&&s.jsx("span",{className:"caption text-disabled",children:t})]})}function A({call:e,now:a,mid:t,onClose:n}){const o=x(e.dir),r=t!=null?g(e,t):null,i=t!=null?y(e,t):0,f=r==null?"var(--color-soft)":r>=0?c:d;return s.jsxs("div",{className:"flex flex-col gap-2 rounded-md border border-white/[0.06] bg-white/[0.02] px-3 py-2.5",children:[s.jsxs("div",{className:"flex items-center gap-2",children:[s.jsx(m,{dir:e.dir}),s.jsx(u,{symbol:e.symbol}),s.jsx("span",{className:"caption text-disabled",children:"·"}),s.jsxs("span",{className:"caption text-soft tabular-nums",children:[e.confidence,"%"]}),s.jsx("span",{className:"body-sm ml-auto font-bold tabular-nums",style:{color:f},children:r==null?"…":p(r)})]}),s.jsx("p",{className:"body-sm text-normal leading-snug",children:e.claim}),s.jsxs("div",{className:"flex flex-col gap-1",children:[s.jsxs("div",{className:"relative h-1.5 rounded-full bg-white/[0.06]",children:[s.jsx("div",{className:"absolute inset-y-0 left-0 rounded-full opacity-40",style:{width:`${i*100}%`,background:o}}),s.jsx("span",{className:"absolute top-1/2 h-2.5 w-2.5 -translate-x-1/2 -translate-y-1/2 rounded-full ring-2 ring-black/30",style:{left:`${i*100}%`,background:o}})]}),s.jsxs("div",{className:"caption text-disabled flex items-center justify-between tabular-nums",children:[s.jsxs("span",{children:["entry ",l(e.entry)]}),s.jsxs("span",{className:"text-soft",children:["now ",t!=null?l(t):"…"]}),s.jsxs("span",{children:["target ",l(e.target)]})]})]}),s.jsxs("div",{className:"flex items-center justify-between gap-2",children:[s.jsx("span",{className:"caption text-disabled uppercase tracking-wide",children:N[e.cls]}),s.jsxs("span",{className:"caption text-soft flex items-center gap-2 tabular-nums",children:[v(e.resolveAt-a),n&&s.jsx("button",{type:"button",onClick:n,disabled:t==null,className:"caption rounded px-1.5 py-0.5 uppercase tracking-wide transition-opacity hover:text-strong disabled:opacity-40",style:{background:"var(--color-surface)"},children:"close"})]})]})]})}function P({call:e}){const a=e.verdict==="hit"?c:d,t=e.signalsFired===void 0?null:w(e);return s.jsxs("div",{className:"flex flex-col gap-1.5 rounded-md border border-white/[0.04] px-3 py-2",children:[s.jsxs("div",{className:"flex items-center gap-2",children:[s.jsx(m,{dir:e.dir}),s.jsx(u,{symbol:e.symbol}),s.jsxs("span",{className:"caption text-soft tabular-nums",children:[e.confidence,"%"]}),s.jsx("span",{className:"body-sm ml-auto font-bold tabular-nums",style:{color:a},children:p(e.returnPct)})]}),s.jsx("p",{className:"body-sm text-soft leading-snug",children:e.claim}),t?s.jsxs("span",{className:"caption font-medium",style:{color:t.color},children:[t.glyph," ",t.label]}):s.jsxs("span",{className:"caption text-disabled uppercase tracking-wide",children:[e.verdict," · graded by return"]})]})}function D({children:e}){return s.jsx("div",{className:"body-sm text-soft flex h-full min-h-0 items-center justify-center text-center",children:e})}export{D as J,A as O,P as R,S};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as x,j as t}from"./react-qoZPGuNy.js";import{b,e as h,c as N,g as L}from"./format-CfAcS4D8.js";import{f as M,L as f,M as p}from"./index-
|
|
1
|
+
import{r as x,j as t}from"./react-qoZPGuNy.js";import{b,e as h,c as N,g as L}from"./format-CfAcS4D8.js";import{f as M,L as f,M as p}from"./index-BgSQpj_B.js";import{F as u}from"./ui-Bq3RQsdJ.js";import{M as S}from"./mini-line-chart-CHM5UBjJ.js";import"./d3-xK4fOkBU.js";import"./utils-DaT-yT0k.js";f.schema;const y="LNS14000000",E="CES0000000001";function w({config:l}){const i=new Date().getUTCFullYear(),c=i-2,{series:s,isLoading:j}=p(y,c,i),{series:e,isLoading:v}=p(E,c,i),a=x.useMemo(()=>((s==null?void 0:s.points)??[]).slice(-l.months),[l.months,s==null?void 0:s.points]),g=x.useMemo(()=>a.map(d=>({date:new Date(d.time).toISOString(),value:d.value})),[a]);if(j&&v)return t.jsx(u,{loading:!0,children:"loading labor data…"});const r=a.at(-1);if(!s||!r)return t.jsx(u,{children:"no labor data yet"});const o=e==null?void 0:e.points.at(-1),m=e==null?void 0:e.points.at(-2),n=o&&m?o.value-m.value:null;return t.jsxs("div",{className:"flex h-full min-h-0 flex-col justify-center gap-3",children:[t.jsxs("div",{className:"flex items-start justify-between gap-3",children:[t.jsxs("div",{children:[t.jsx("div",{className:"caption text-soft uppercase",children:"unemployment rate"}),t.jsx("div",{className:"body-sm text-normal",children:r.date})]}),t.jsx("div",{className:"caption text-soft text-right",children:"monthly"})]}),t.jsxs("div",{className:"flex items-end justify-between gap-3",children:[t.jsxs("div",{children:[t.jsx("div",{className:"metric-xl text-strong leading-none",children:b(r.value,1)}),t.jsxs("div",{className:"caption text-soft mt-1",children:[s.source," · U-3"]})]}),n!==null&&o&&t.jsxs("div",{className:"text-right",children:[t.jsx("div",{className:"caption text-soft",children:"nonfarm payrolls"}),t.jsxs("div",{className:"body-md font-bold tabular-nums",style:{color:N(n)},children:[n>=0?"+":"",h(n*1e3)]}),t.jsxs("div",{className:"caption text-soft mt-1 tabular-nums",children:[h(o.value*1e3)," jobs"]})]})]}),t.jsx(S,{data:g,width:210,height:44,color:L}),t.jsxs("div",{className:"caption text-soft",children:[s.label," · ",a.length," monthly observations"]})]})}const Y=M({...f,component:w});export{Y as laborMarketFrame};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{j as e}from"./react-qoZPGuNy.js";import{j as r,a as c,c as d}from"./format-CfAcS4D8.js";import{f as m,a_ as i,a$ as u}from"./index-
|
|
1
|
+
import{j as e}from"./react-qoZPGuNy.js";import{j as r,a as c,c as d}from"./format-CfAcS4D8.js";import{f as m,a_ as i,a$ as u}from"./index-BgSQpj_B.js";import{F as o}from"./ui-Bq3RQsdJ.js";i.schema;function s(n,t){return t==null||t===0?null:(n-t)/t*100}function l({label:n,value:t,delta:a}){return e.jsxs("div",{className:"flex flex-col items-center justify-center rounded-md bg-white/[0.04] px-2 py-2 text-center",children:[e.jsx("span",{className:"metric-sm text-strong leading-none",children:t}),e.jsx("span",{className:"caption text-soft mt-1",children:n}),a!==null&&e.jsx("span",{className:"caption mt-0.5 font-bold tabular-nums",style:{color:d(a)},children:c(a)})]})}function g({config:n}){const{stats:t,isLoading:a}=u();return a?e.jsx(o,{loading:!0,children:"loading lightning…"}):t?e.jsxs("div",{className:"flex h-full min-h-0 flex-col justify-center gap-2",children:[e.jsxs("div",{className:"grid grid-cols-3 gap-1.5",children:[e.jsx(l,{label:"nodes",value:t.nodeCount.toLocaleString("en-US"),delta:s(t.nodeCount,t.prevNodeCount)}),e.jsx(l,{label:"channels",value:t.channelCount.toLocaleString("en-US"),delta:s(t.channelCount,t.prevChannelCount)}),e.jsx(l,{label:"capacity",value:r(t.totalCapacity),delta:s(t.totalCapacity,t.prevTotalCapacity)})]}),n.showSplit&&e.jsxs("div",{className:"caption text-soft text-center",children:[t.clearnetNodes.toLocaleString("en-US")," clearnet ·"," ",t.torNodes.toLocaleString("en-US")," tor"]})]}):e.jsx(o,{children:"no lightning data yet"})}const j=m({...i,component:g});export{j as lightningStatsFrame};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{j as t,r as m}from"./react-qoZPGuNy.js";import{i as d}from"./content-shared-BZ1XzrJx.js";import{f as u,aF as i}from"./index-
|
|
1
|
+
import{j as t,r as m}from"./react-qoZPGuNy.js";import{i as d}from"./content-shared-BZ1XzrJx.js";import{f as u,aF as i}from"./index-BgSQpj_B.js";import{s as f}from"./ui-Bq3RQsdJ.js";i.schema;const p=e=>/^https?:\/\//i.test(e);function h(e){for(const r of[e,`https://${e}`])try{const n=new URL(r).hostname;if(n)return n}catch{}return null}function x(e){const r=h(e);return r?`https://www.google.com/s2/favicons?sz=64&domain=${encodeURIComponent(r)}`:null}function g({link:e}){const[r,n]=m.useState(!1),s=e.icon.trim(),a=s&&p(s)?s:null,o=s&&!a?s:null,l=a??(o?null:x(e.url)),c=l!=null&&!r;return t.jsxs("a",{href:e.url,target:"_blank",rel:"noopener noreferrer",title:e.url,className:`group flex items-center gap-2 px-2.5 py-2 ${d}`,children:[t.jsx("span",{className:"flex h-7 w-7 shrink-0 items-center justify-center overflow-hidden rounded-md bg-white/[0.06] text-base leading-none","aria-hidden":!0,children:o?t.jsx("span",{children:o}):c?t.jsx("img",{src:l,alt:"",className:"h-full w-full object-contain",loading:"lazy",referrerPolicy:"no-referrer",onError:()=>n(!0)}):t.jsx("span",{className:"text-soft font-dmsans font-bold uppercase",children:e.label.charAt(0)})}),t.jsx("span",{className:"body-sm text-normal min-w-0 flex-1 truncate font-medium group-hover:text-strong",children:e.label})]})}function j({config:e}){return t.jsx("div",{className:f,children:t.jsx("div",{className:"grid gap-2",style:{gridTemplateColumns:`repeat(${e.columns}, minmax(0, 1fr))`},children:e.links.map((r,n)=>t.jsx(g,{link:r},`${r.url}-${n}`))})})}const N=u({...i,component:j});export{N as linkGridFrame};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as p,j as m}from"./react-qoZPGuNy.js";import{f as i,a as c}from"./format-CfAcS4D8.js";import{f,aw as n,ax as d}from"./index-
|
|
1
|
+
import{r as p,j as m}from"./react-qoZPGuNy.js";import{f as i,a as c}from"./format-CfAcS4D8.js";import{f,aw as n,ax as d}from"./index-BgSQpj_B.js";import{T as h,a as l}from"./treemap-leaf-DNIoJEK-.js";import{F as s}from"./ui-Bq3RQsdJ.js";import"./utils-DaT-yT0k.js";import"./d3-xK4fOkBU.js";n.schema;function u({width:r,height:o,data:a}){const t=i(a.marketCapUsd);return m.jsx(l,{width:r,height:o,label:a.id,secondary:t,title:`${a.id} · ${t} mcap · ${c(a.changePct24h)}`})}function C({config:r}){const{entries:o,isLoading:a}=d(),t=p.useMemo(()=>o.slice(0,r.topN).map(e=>({id:e.symbol,value:e.marketCapUsd,marketCapUsd:e.marketCapUsd,changePct24h:e.changePct24h??0})),[o,r.topN]);return a?m.jsx(s,{loading:!0,children:"loading market caps…"}):t.length===0?m.jsx(s,{children:"no market data"}):m.jsx(h,{data:t,LeafComponent:u,getColorValue:e=>e.changePct24h})}const U=f({...n,component:C});export{U as marketCapTreemapFrame};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{j as e,r as d}from"./react-qoZPGuNy.js";import{D as x,E as m,e as g,s as f,f as b}from"./market-data-CvmpLFSo.js";import{U as l}from"./format-CfAcS4D8.js";import{f as w,Z as h}from"./index-
|
|
1
|
+
import{j as e,r as d}from"./react-qoZPGuNy.js";import{D as x,E as m,e as g,s as f,f as b}from"./market-data-CvmpLFSo.js";import{U as l}from"./format-CfAcS4D8.js";import{f as w,Z as h}from"./index-BgSQpj_B.js";import{F as j}from"./ui-Bq3RQsdJ.js";h.schema;const u={open:{color:l,chipBg:"rgba(63, 208, 143, 0.13)",label:"Open",verb:"closes",rail:l,railOpacity:1,wash:"linear-gradient(90deg, rgba(63, 208, 143, 0.08), transparent 40%)"},closed:{color:"#8b92a1",chipBg:"rgba(255, 255, 255, 0.045)",label:"Closed",verb:"opens",rail:"rgba(255, 255, 255, 0.22)",railOpacity:.55,wash:"none"},holiday:{color:"#f2b066",chipBg:"rgba(242, 176, 102, 0.13)",label:"Holiday",verb:"opens",rail:"#f2b066",railOpacity:1,wash:"linear-gradient(90deg, rgba(242, 176, 102, 0.07), transparent 40%)"}};function k(){return e.jsxs("svg",{"aria-hidden":"true",className:"shrink-0",fill:"none",height:"15",viewBox:"0 0 20 20",width:"15",children:[e.jsx("circle",{cx:"10",cy:"10",r:"7.25",stroke:"currentColor",strokeOpacity:"0.75",strokeWidth:"1.5"}),e.jsx("path",{d:"M2.75 10h14.5M10 2.75c2 2 3 4.42 3 7.25s-1 5.25-3 7.25M10 2.75c-2 2-3 4.42-3 7.25s1 5.25 3 7.25",stroke:"currentColor",strokeLinecap:"round",strokeOpacity:"0.55",strokeWidth:"1.2"}),e.jsx("path",{d:"m5.25 12.75 2.6-2.3 2.1 1.55 3.95-4.8",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"1.6"})]})}function v(s,r){try{return new Intl.DateTimeFormat("en-US",{timeZone:r,hour:"2-digit",minute:"2-digit",hour12:!1,timeZoneName:"short"}).format(s)}catch{return r}}function y(s){return/^[A-Z]{2}$/i.test(s)?[...s.toUpperCase()].map(r=>String.fromCodePoint(127462+r.charCodeAt(0)-65)).join(""):s}function N(){return e.jsxs("svg",{"aria-hidden":"true",className:"opacity-50 transition group-hover:translate-x-0.5 group-hover:-translate-y-0.5 group-hover:opacity-95",fill:"none",height:"12",viewBox:"0 0 16 16",width:"12",children:[e.jsx("path",{d:"M6 4.5H4.5a2 2 0 0 0-2 2v5a2 2 0 0 0 2 2h5a2 2 0 0 0 2-2V10",stroke:"currentColor",strokeLinecap:"round",strokeWidth:"1.5"}),e.jsx("path",{d:"M9 2.5h4.5V7M8.25 7.75l5-5",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"1.5"})]})}function C({state:s}){return e.jsx("span",{"aria-hidden":"true",className:"grid h-[30px] w-[30px] shrink-0 place-items-center overflow-hidden rounded-[9px] border border-white/10 shadow-[inset_0_1px_0_rgba(255,255,255,0.12),0_4px_10px_-7px_rgba(0,0,0,0.8)]",style:{background:"linear-gradient(150deg, rgba(255,255,255,0.1), rgba(255,255,255,0.02) 48%, rgba(0,0,0,0.22))"},children:e.jsx("span",{className:"text-[1.15rem] leading-none drop-shadow-[0_1px_3px_rgba(0,0,0,0.5)]",children:y(s.country)})})}function _({state:s}){const r=u[s.status],n=s.status==="closed";return e.jsxs("span",{className:"inline-flex items-center gap-1.5 rounded-full border px-2 py-[3px] font-dmsans text-[0.5rem] font-bold uppercase leading-none tracking-[0.09em]",style:{borderColor:n?"rgba(255,255,255,0.1)":`${r.color}33`,background:r.chipBg,color:n?"rgba(255,255,255,0.62)":r.color},children:[e.jsx("span",{className:"h-1.5 w-1.5 rounded-full",style:{background:n?"rgba(255,255,255,0.45)":r.color,boxShadow:s.status==="open"?`0 0 6px ${r.color}`:void 0}}),r.label]})}function S({now:s,state:r}){const n=u[r.status],o=b(r.nextChangeMin),c=v(s,r.tz);return e.jsxs("a",{"aria-label":`${r.name} website`,className:"group text-normal relative grid min-h-[42px] grid-cols-[auto_minmax(0,1fr)_auto] items-center gap-3 overflow-hidden rounded-xl border border-white/[0.06] bg-white/[0.022] py-1.5 pr-2.5 pl-3 transition duration-200 hover:-translate-y-px hover:border-white/[0.14] hover:bg-white/[0.05] hover:text-strong focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-white/50",href:r.website,rel:"noreferrer",style:{backgroundImage:n.wash},target:"_blank",title:`${r.name} · ${r.city} · ${r.open}-${r.close}`,children:[e.jsx("span",{"aria-hidden":"true",className:"absolute inset-y-[5px] left-0 w-[3px] rounded-r-full",style:{background:n.rail,opacity:n.railOpacity}}),e.jsx(C,{state:r}),e.jsxs("span",{className:"relative min-w-0 pl-0.5",children:[e.jsxs("span",{className:"flex min-w-0 items-center gap-1.5",children:[e.jsx("span",{className:"body-sm text-strong truncate font-bold",children:r.name}),e.jsx(N,{})]}),e.jsxs("span",{className:"caption text-soft flex min-w-0 items-center gap-1.5 tabular-nums",children:[e.jsx("span",{className:"truncate",children:r.city}),e.jsx("span",{className:"h-[3px] w-[3px] shrink-0 rounded-full bg-white/25"}),e.jsx("span",{className:"shrink-0",children:c})]})]}),e.jsxs("span",{className:"relative flex min-w-[84px] flex-col items-end gap-1",children:[e.jsx(_,{state:r}),e.jsxs("span",{className:"caption whitespace-nowrap text-right tabular-nums",style:{color:r.status==="closed"?"rgba(255,255,255,0.55)":n.color},children:[n.verb," ",o]})]})]})}function E({config:s}){const[r,n]=d.useState(()=>new Date);d.useEffect(()=>{const a=window.setInterval(()=>n(new Date),3e4);return()=>window.clearInterval(a)},[]);const o=s.exchanges.length?s.exchanges:x,c=o.join(","),i=d.useMemo(()=>{const a=o.map(t=>m[t.toUpperCase()]).filter(t=>!!t).map(t=>g(t,r));return f(a,s.sort)},[c,r,s.sort]);if(i.length===0)return e.jsx(j,{children:"no known exchanges — check the codes"});const p=i.filter(a=>a.status==="open").length;return e.jsxs("div",{className:"flex h-full min-h-0 flex-col overflow-hidden",children:[e.jsxs("div",{className:"caption text-soft mb-2 flex items-center justify-between gap-3 uppercase tracking-wide",children:[e.jsx("span",{className:"truncate",children:"exchange sessions"}),e.jsxs("span",{className:"inline-flex shrink-0 items-center gap-1.5 rounded-full border border-white/[0.08] bg-white/[0.045] px-2 py-0.5 tabular-nums",children:[p>0&&e.jsx("span",{className:"h-1.5 w-1.5 rounded-full",style:{background:l,boxShadow:`0 0 6px ${l}`}}),e.jsx("span",{className:"text-strong font-bold",children:p}),e.jsxs("span",{className:"text-soft",children:["/ ",i.length," open"]})]})]}),e.jsx("div",{className:"flex min-h-0 flex-1 flex-col gap-1 overflow-auto pr-0.5",children:i.map(a=>e.jsx(S,{now:r,state:a},a.code))})]})}const I=w({...h,component:E,titleIcon:k});export{I as marketHoursFrame};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{j as e}from"./react-qoZPGuNy.js";import{f as i,aJ as r}from"./index-
|
|
1
|
+
import{j as e}from"./react-qoZPGuNy.js";import{f as i,aJ as r}from"./index-BgSQpj_B.js";r.schema;const s={slow:24,normal:14,fast:8},m=`
|
|
2
2
|
.zf-marquee {
|
|
3
3
|
display: flex;
|
|
4
4
|
align-items: center;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as f,j as a}from"./react-qoZPGuNy.js";import{b as h}from"./format-CfAcS4D8.js";import{f as P,aY as u,aZ as g}from"./index-
|
|
1
|
+
import{r as f,j as a}from"./react-qoZPGuNy.js";import{b as h}from"./format-CfAcS4D8.js";import{f as P,aY as u,aZ as g}from"./index-BgSQpj_B.js";import{T as x,a as b}from"./treemap-leaf-DNIoJEK-.js";import{F as p}from"./ui-Bq3RQsdJ.js";import"./utils-DaT-yT0k.js";import"./d3-xK4fOkBU.js";u.schema;function j({width:o,height:t,data:r}){const s=h(r.sharePct,1);return a.jsx(b,{width:o,height:t,label:r.id,secondary:s,title:`${r.id} · ${s} of blocks`})}function C({config:o}){const{pools:t,isLoading:r}=g(o.window),s=f.useMemo(()=>{const n=(t==null?void 0:t.pools)??[],l=n.slice(0,o.topN).map(e=>({id:e.name,value:e.blockCount,sharePct:e.sharePct})),i=n.slice(o.topN);if(i.length>0){const e=i.reduce((c,m)=>c+m.blockCount,0),d=i.reduce((c,m)=>c+m.sharePct,0);e>0&&l.push({id:"Other",value:e,sharePct:d})}return l},[t,o.topN]);return r?a.jsx(p,{loading:!0,children:"loading pools…"}):s.length===0?a.jsx(p,{children:"no mining data yet"}):a.jsx(x,{data:s,LeafComponent:j,getColorValue:n=>n.sharePct})}const y=P({...u,component:C});export{y as miningPoolsFrame};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{j as t}from"./react-qoZPGuNy.js";import{A as m}from"./index-
|
|
1
|
+
import{j as t}from"./react-qoZPGuNy.js";import{A as m}from"./index-BgSQpj_B.js";import{d as r,a as n,c as l}from"./format-CfAcS4D8.js";function c({symbol:i,label:a,price:s,changePct:o,logoSize:e=16,gap:d="gap-2"}){return t.jsxs("div",{className:`grid grid-cols-[auto_minmax(0,1fr)_auto_auto] items-center ${d}`,title:s!==void 0?`${a} · ${r(s)}`:a,children:[t.jsx(m,{symbol:i,size:e}),t.jsx("span",{className:"body-sm truncate font-bold text-strong",children:a}),t.jsx("span",{className:"caption text-soft text-right tabular-nums",children:s!==void 0?r(s):"—"}),t.jsx("span",{className:`caption text-right font-bold tabular-nums${o===void 0?" text-disabled":""}`,style:o!==void 0?{color:l(o)}:void 0,children:o!==void 0?n(o):"…"})]})}export{c as M};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as m,j as t}from"./react-qoZPGuNy.js";import{f as a}from"./format-CfAcS4D8.js";import{f as x,O as o,P as h}from"./index-
|
|
1
|
+
import{r as m,j as t}from"./react-qoZPGuNy.js";import{f as a}from"./format-CfAcS4D8.js";import{f as x,O as o,P as h}from"./index-BgSQpj_B.js";import{F as l}from"./ui-Bq3RQsdJ.js";import{M as p}from"./mini-line-chart-CHM5UBjJ.js";import"./d3-xK4fOkBU.js";import"./utils-DaT-yT0k.js";o.schema;function u({config:n}){const{debt:e,isLoading:d}=h(n.trendDays),c=m.useMemo(()=>((e==null?void 0:e.trend)??[]).map(r=>({date:new Date(r.time).toISOString(),value:r.total})),[e==null?void 0:e.trend]);if(d)return t.jsx(l,{loading:!0,children:"loading national debt…"});if(!e)return t.jsx(l,{children:"no debt data yet"});const s=e.trend[0],i=s?e.total-s.total:null;return t.jsxs("div",{className:"flex h-full min-h-0 flex-col justify-center gap-3",children:[t.jsxs("div",{className:"flex items-start justify-between gap-3",children:[t.jsxs("div",{children:[t.jsx("div",{className:"caption text-soft uppercase",children:"total public debt"}),t.jsxs("div",{className:"body-sm text-normal",children:["as of ",e.date]})]}),t.jsx("div",{className:"caption text-soft text-right",children:"daily"})]}),t.jsxs("div",{className:"flex items-end justify-between gap-3",children:[t.jsx("div",{className:"metric-xl text-strong leading-none",children:a(e.total)}),i!==null&&s&&t.jsxs("div",{className:"text-right",children:[t.jsxs("div",{className:"body-md text-normal font-bold tabular-nums",children:[i>=0?"+":"",a(i)]}),t.jsxs("div",{className:"caption text-soft",children:["since ",s.date]})]})]}),t.jsx(p,{data:c,width:210,height:42,color:"hsl(var(--zf-accent-hue, 242) 85% 72%)"}),n.showSplit&&t.jsxs("div",{className:"grid grid-cols-2 gap-1.5 border-t border-white/[0.08] pt-2",children:[t.jsxs("div",{className:"rounded bg-white/[0.04] px-2 py-1.5",children:[t.jsx("div",{className:"caption text-soft truncate",children:"Held by public"}),t.jsx("div",{className:"body-sm text-strong font-bold tabular-nums",children:a(e.heldByPublic)})]}),t.jsxs("div",{className:"rounded bg-white/[0.04] px-2 py-1.5",children:[t.jsx("div",{className:"caption text-soft truncate",children:"Intragovernmental"}),t.jsx("div",{className:"body-sm text-strong font-bold tabular-nums",children:a(e.intragovernmental)})]})]})]})}const w=x({...o,component:u});export{w as nationalDebtFrame};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{j as s,r as h}from"./react-qoZPGuNy.js";import{F as f}from"./feed-row-mVg1d5Zj.js";import{t as p}from"./format-CfAcS4D8.js";import{f as x,_ as i,$ as b}from"./index-
|
|
1
|
+
import{j as s,r as h}from"./react-qoZPGuNy.js";import{F as f}from"./feed-row-mVg1d5Zj.js";import{t as p}from"./format-CfAcS4D8.js";import{f as x,_ as i,$ as b}from"./index-BgSQpj_B.js";import{F as t,s as j}from"./ui-Bq3RQsdJ.js";i.schema;const g={coindesk:"CoinDesk",cointelegraph:"Cointelegraph",decrypt:"Decrypt",cnbc:"CNBC Markets",nasdaq:"Nasdaq",stocks:"Google News"};function y({src:e}){const[r,a]=h.useState(!1);return r?null:s.jsx("img",{src:e,alt:"",loading:"lazy",decoding:"async",referrerPolicy:"no-referrer",onError:()=>a(!0),className:"size-12 shrink-0 rounded-md bg-white/[0.04] object-cover ring-1 ring-white/10"})}function w({item:e}){return s.jsx(f,{href:e.url,leading:e.imageUrl?s.jsx(y,{src:e.imageUrl}):void 0,title:e.title,subtitle:e.summary||void 0,meta:e.publishedAt!==void 0?p(e.publishedAt):void 0})}function N({config:e}){var n;const r=e.source==="stocks",a=r&&e.symbols.length===0,c=a?"":e.source,{items:o,isLoading:d}=b(c,r?e.symbols:void 0,e.count);if(a)return s.jsx(t,{children:"add stock symbols to show company headlines"});if(d)return s.jsx(t,{loading:!0,children:"loading headlines…"});const m=((n=o[0])==null?void 0:n.source)??g[e.source]??"news";return s.jsxs("div",{className:"flex h-full min-h-0 flex-col gap-2",children:[s.jsxs("div",{className:"flex items-baseline justify-between gap-3",children:[s.jsx("span",{className:"caption text-soft truncate",children:m}),s.jsx("span",{className:"caption text-soft shrink-0",children:"headlines"})]}),s.jsx("div",{className:j,children:o.length>0?o.map((l,u)=>s.jsx(w,{item:l},`${l.url}-${u}`)):s.jsxs(t,{children:["no headlines ",r?"for these symbols":"available"," — the runtime proxy may be offline"]})})]})}const A=x({...i,component:N});export{A as newsFeedFrame};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as a,j as c}from"./react-qoZPGuNy.js";import{f,a0 as m,m as d}from"./index-
|
|
1
|
+
import{r as a,j as c}from"./react-qoZPGuNy.js";import{f,a0 as m,m as d}from"./index-BgSQpj_B.js";import{s as p}from"./ui-Bq3RQsdJ.js";m.schema;function h({config:e}){const t=d(),[n,o]=a.useState(!1),[r,l]=a.useState(e.text),i=a.useRef(null);a.useEffect(()=>{l(e.text)},[e.text]),a.useEffect(()=>{var s;n&&((s=i.current)==null||s.focus())},[n]);const u=a.useCallback(()=>{r!==e.text&&(t==null||t({text:r})),o(!1)},[t,r,e.text]),x=e.align==="center"?"flex items-center justify-center text-center":"";return n?c.jsx("textarea",{ref:i,className:`body-sm text-normal h-full w-full resize-none bg-transparent outline-none placeholder:text-disabled ${x}`,value:r,onChange:s=>l(s.target.value),onBlur:u,onKeyDown:s=>{s.key==="Escape"&&(l(e.text),o(!1))},placeholder:"Write a note…"}):c.jsx("div",{className:`body-sm text-normal whitespace-pre-wrap ${p} ${x} ${t?"cursor-text":""}`,onClick:()=>t&&o(!0),title:t?"Click to edit":void 0,children:e.text||c.jsx("span",{className:"text-soft italic",children:t?"Click to add a note…":"New note"})})}const b=f({...m,component:h});export{b as noteFrame};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as n,j as e}from"./react-qoZPGuNy.js";import{f as p,ay as l,az as f,A as u,h as x}from"./index-
|
|
1
|
+
import{r as n,j as e}from"./react-qoZPGuNy.js";import{f as p,ay as l,az as f,A as u,h as x}from"./index-BgSQpj_B.js";import{f as r}from"./format-CfAcS4D8.js";import{F as i,s as h}from"./ui-Bq3RQsdJ.js";l.schema;const b=25;function g({config:m}){const{entries:a,isLoading:c}=f(m.symbols),t=n.useMemo(()=>a.slice(0,b),[a]),o=n.useMemo(()=>t.reduce((s,d)=>Math.max(s,d.openInterestUsd),0),[t]);return c?e.jsx(i,{loading:!0,children:"loading open interest…"}):t.length===0?e.jsx(i,{children:"no open-interest data"}):e.jsx("div",{className:`flex flex-col gap-1.5 ${h}`,children:t.map(s=>e.jsxs("div",{className:"grid grid-cols-[auto_minmax(0,1fr)_auto] items-center gap-2",title:`${s.symbol} · ${r(s.openInterestUsd)} open interest`,children:[e.jsx(u,{symbol:s.symbol,size:16}),e.jsxs("div",{className:"relative h-4 w-full overflow-hidden rounded-sm bg-white/[0.06]",children:[e.jsx("div",{className:"absolute inset-y-0 left-0 rounded-sm",style:{width:`${o>0?s.openInterestUsd/o*100:0}%`,background:"hsl(var(--zf-accent-hue, 242) 85% 72% / 0.5)"}}),e.jsx("span",{className:"absolute inset-y-0 left-1.5 flex items-center",children:e.jsx("span",{className:"body-sm truncate font-bold text-strong",children:x(s.symbol)})})]}),e.jsx("span",{className:"caption text-soft text-right tabular-nums",children:r(s.openInterestUsd)})]},s.symbol))})}const w=p({...l,component:g});export{w as openInterestFrame};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as l,j as e}from"./react-qoZPGuNy.js";import{c as x}from"./format-CfAcS4D8.js";import{f as p,b2 as m,b3 as v}from"./index-
|
|
1
|
+
import{r as l,j as e}from"./react-qoZPGuNy.js";import{c as x}from"./format-CfAcS4D8.js";import{f as p,b2 as m,b3 as v}from"./index-BgSQpj_B.js";import{F as c}from"./ui-Bq3RQsdJ.js";import{M as f}from"./mini-line-chart-CHM5UBjJ.js";import"./d3-xK4fOkBU.js";import"./utils-DaT-yT0k.js";m.schema;const j={"7D":{ms:7*864e5,res:3600},"1M":{ms:30*864e5,res:43200},"3M":{ms:90*864e5,res:86400}};function g({config:a}){const{ms:i,res:o}=j[a.lookback],d=l.useMemo(()=>{const t=o*1e3;return Math.floor((Date.now()-i)/t)*t},[i,o]),{points:s,isLoading:h}=v(a.currency,d,o),u=l.useMemo(()=>s.map(t=>({date:new Date(t.time).toISOString(),value:t.value})),[s]);if(h)return e.jsx(c,{loading:!0,children:"loading volatility…"});if(s.length===0)return e.jsx(c,{children:"no volatility data yet"});const n=s[s.length-1].value,r=n-s[0].value;return e.jsxs("div",{className:"flex h-full min-h-0 flex-col justify-center gap-3",children:[e.jsxs("div",{className:"flex items-end justify-between gap-3",children:[e.jsxs("div",{children:[e.jsxs("div",{className:"caption text-soft uppercase",children:[a.currency," DVOL · implied vol"]}),e.jsx("div",{className:"metric-lg text-strong leading-none",children:n.toFixed(1)})]}),e.jsxs("div",{className:"text-right",children:[e.jsxs("div",{className:"body-md font-bold tabular-nums",style:{color:x(r)},children:[r>=0?"+":"",r.toFixed(1)]}),e.jsxs("div",{className:"caption text-soft",children:["past ",a.lookback]})]})]}),e.jsx(f,{data:u,width:320,height:54,color:"hsl(var(--zf-accent-hue, 242) 85% 72%)"})]})}const O=p({...m,component:g});export{O as optionsIvFrame};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as L,j as t}from"./react-qoZPGuNy.js";import{U as S,D as E,e as v,d as F}from"./format-CfAcS4D8.js";import{f as P,b4 as N,b1 as R}from"./index-
|
|
1
|
+
import{r as L,j as t}from"./react-qoZPGuNy.js";import{U as S,D as E,e as v,d as F}from"./format-CfAcS4D8.js";import{f as P,b4 as N,b1 as R}from"./index-BgSQpj_B.js";import{F as g}from"./ui-Bq3RQsdJ.js";N.schema;const w=S,M=E;function B({config:h}){const{summary:p,isLoading:W}=R(h.currency),j=L.useMemo(()=>{if(!p)return null;const s=p.underlyingPrice,x=p.nearestExpiry.strikes;if(x.length===0)return null;const n=[...x].sort((r,y)=>Math.abs(r.strike-s)-Math.abs(y.strike-s)).slice(0,h.strikes).sort((r,y)=>r.strike-y.strike),d=Math.max(1,...n.map(r=>Math.max(r.callOi,r.putOi)));return{near:n,maxOi:d,spot:s,expiry:p.nearestExpiry.expiry}},[p,h.strikes]);if(W)return t.jsx(g,{loading:!0,children:"loading strikes…"});if(!j)return t.jsx(g,{children:"no options data yet"});const{near:e,maxOi:C,spot:a,expiry:H}=j,f=600,O=200,i=6,o=O-i-4,m=e.length,u=f/m,k=Math.max(2,u*.34),l=s=>s*u+u/2,b=s=>s/C*o;let c=null;if(a<=e[0].strike)c=l(0);else if(a>=e[m-1].strike)c=l(m-1);else for(let s=0;s<m-1;s++)if(a>=e[s].strike&&a<=e[s+1].strike){const x=e[s+1].strike-e[s].strike||1,n=(a-e[s].strike)/x;c=l(s)+n*(l(s+1)-l(s));break}return t.jsxs("div",{className:"flex h-full min-h-0 flex-col",children:[t.jsxs("div",{className:"caption text-soft mb-1 flex justify-between",children:[t.jsxs("span",{children:["OI by strike · ",H]}),t.jsxs("span",{children:[t.jsx("span",{style:{color:w},children:"calls"})," ·"," ",t.jsx("span",{style:{color:M},children:"puts"})]})]}),t.jsxs("svg",{viewBox:`0 0 ${f} ${O}`,preserveAspectRatio:"none",className:"min-h-0 w-full flex-1",children:[t.jsx("line",{x1:0,y1:i+o,x2:f,y2:i+o,style:{stroke:"var(--color-disabled)"},strokeWidth:1}),e.map((s,x)=>{const n=l(x),d=b(s.callOi),r=b(s.putOi);return t.jsxs("g",{children:[t.jsx("rect",{x:n-k-1,y:i+o-d,width:k,height:d,fill:w}),t.jsx("rect",{x:n+1,y:i+o-r,width:k,height:r,fill:M})]},s.strike)}),c!==null&&t.jsx("line",{x1:c,y1:i,x2:c,y2:i+o,style:{stroke:"var(--color-soft)"},strokeWidth:1,strokeDasharray:"4 3"})]}),t.jsxs("div",{className:"caption text-soft mt-1 flex justify-between tabular-nums",children:[t.jsx("span",{children:v(e[0].strike)}),t.jsxs("span",{className:"text-normal",children:["spot ",F(a)]}),t.jsx("span",{children:v(e[m-1].strike)})]})]})}const $=P({...N,component:B});export{$ as optionsOiStrikeFrame};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{j as s}from"./react-qoZPGuNy.js";import{U as h,D as f,b as e}from"./format-CfAcS4D8.js";import{f as j,b0 as u,b1 as v}from"./index-
|
|
1
|
+
import{j as s}from"./react-qoZPGuNy.js";import{U as h,D as f,b as e}from"./format-CfAcS4D8.js";import{f as j,b0 as u,b1 as v}from"./index-BgSQpj_B.js";import{F as d}from"./ui-Bq3RQsdJ.js";u.schema;const i=h,o=f;function y(t){return t>1?o:i}function b({config:t}){const{summary:l,isLoading:m}=v(t.currency);if(m)return s.jsx(d,{loading:!0,children:"loading options…"});if(!l)return s.jsx(d,{children:"no options data yet"});const n=t.basis==="oi"?l.putCallRatioOi:l.putCallRatioVolume,x=t.basis==="oi"?l.putCallRatioVolume:l.putCallRatioOi,r=l.callOi+l.putOi,a=r>0?l.callOi/r*100:50,c=100-a,p=y(n);return s.jsxs("div",{className:"flex h-full min-h-0 flex-col justify-center gap-3",children:[s.jsxs("div",{className:"flex items-end justify-between gap-3",children:[s.jsxs("div",{children:[s.jsxs("div",{className:"caption text-soft uppercase",children:[t.currency," put/call · ",t.basis==="oi"?"OI":"vol"]}),s.jsx("div",{className:"metric-xl leading-none",style:{color:p},children:n.toFixed(2)})]}),s.jsxs("div",{className:"text-right",children:[s.jsx("div",{className:"body-md text-normal font-bold tabular-nums",children:x.toFixed(2)}),s.jsxs("div",{className:"caption text-soft",children:["by ",t.basis==="oi"?"volume":"OI"]})]})]}),s.jsxs("div",{children:[s.jsxs("div",{className:"flex h-3 w-full gap-1 overflow-hidden rounded-full",children:[s.jsx("div",{className:"h-full rounded-l-full",style:{width:`${a}%`,background:i}}),s.jsx("div",{className:"h-full rounded-r-full",style:{width:`${c}%`,background:o}})]}),s.jsxs("div",{className:"caption text-soft mt-1 flex justify-between tabular-nums",children:[s.jsxs("span",{children:[s.jsx("span",{style:{color:i},children:"calls"})," ",e(a,0)]}),s.jsxs("span",{children:[e(c,0)," ",s.jsx("span",{style:{color:o},children:"puts"})]})]})]}),s.jsxs("div",{className:"caption text-soft",children:["avg implied vol ",e(l.avgIv,1)]})]})}const g=j({...u,component:b});export{g as optionsPutCallFrame};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r,j as s}from"./react-qoZPGuNy.js";import{i as k}from"./content-shared-BZ1XzrJx.js";import{f as w,bc as y}from"./index-
|
|
1
|
+
import{r,j as s}from"./react-qoZPGuNy.js";import{i as k}from"./content-shared-BZ1XzrJx.js";import{f as w,bc as y}from"./index-BgSQpj_B.js";y.schema;function M(e){const t=Math.floor(e/60),n=e%60;return`${t}:${String(n).padStart(2,"0")}`}function R({config:e}){const t=Math.max(1,Math.round(e.workMin*60)),n=Math.max(1,Math.round(e.breakMin*60)),[a,c]=r.useState("work"),[b,o]=r.useState(t),[l,i]=r.useState(!1),[u,m]=r.useState(1);r.useEffect(()=>{c("work"),o(t),i(!1),m(1)},[t,n]);const p=r.useRef(a);p.current=a;const x=r.useRef(u);x.current=u,r.useEffect(()=>{if(!l)return;const f=setInterval(()=>{o(h=>h>1?h-1:p.current==="work"?(c("break"),n):(c("work"),m(S=>x.current>=e.cycles?1:S+1),t))},1e3);return()=>clearInterval(f)},[l,t,n,e.cycles]);const j=()=>{i(!1),c("work"),o(t),m(1)},d=e.label.trim(),v=a==="work"?"var(--color-highlight)":void 0;return s.jsxs("div",{className:"flex h-full w-full flex-col items-center justify-center gap-1",children:[d&&s.jsx("div",{className:"caption text-soft uppercase tracking-[0.12em]",children:d}),s.jsxs("div",{className:"caption text-soft uppercase tracking-[0.18em]",children:[a," · ",u,"/",e.cycles]}),s.jsx("div",{className:"metric-xl text-strong",style:{color:v},children:M(b)}),s.jsxs("div",{className:"mt-1 flex gap-1",children:[s.jsx("button",{type:"button",onClick:()=>i(f=>!f),className:`caption text-normal px-3 py-1 ${k}`,children:l?"Pause":"Start"}),s.jsx("button",{type:"button",onClick:j,className:`caption text-soft px-3 py-1 ${k}`,children:"Reset"})]})]})}const $=w({...y,component:R});export{$ as pomodoroFrame};
|
package/runtime/assets/{portfolio-allocation-Cat1vq2_.js → portfolio-allocation-Cf251dcH.js}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as m,j as t}from"./react-qoZPGuNy.js";import{f as R,g as j,h as A}from"./index-
|
|
1
|
+
import{r as m,j as t}from"./react-qoZPGuNy.js";import{f as R,g as j,h as A}from"./index-BgSQpj_B.js";import{f as v,b as S}from"./format-CfAcS4D8.js";import{P as F,u as M,a as P}from"./portfolio-common-DnESc3oR.js";import{F as G}from"./ui-Bq3RQsdJ.js";import{C as y}from"./chart-utils-BYIZMM9J.js";import{s as p,p as E,a as h,o as _}from"./d3-xK4fOkBU.js";const B=["#FF1F5F","#81FE90"],L=({data:a,width:r=270,height:o=270,innerRadius:s=90,outerRadius:n=100,colors:e=B,children:l})=>{const d=m.useRef(null);return m.useEffect(()=>{if(!d.current||!a.length)return;p(d.current).selectAll("*").remove();const g=p(d.current),b=r/2,N=o/2,u=g.append("defs");u.append("filter").attr("id","glow").append("feGaussianBlur").attr("stdDeviation","3").attr("result","coloredBlur"),u.select("#glow").append("feMerge").selectAll("feMergeNode").data(["coloredBlur","SourceGraphic"]).enter().append("feMergeNode").attr("in",i=>i),u.append("filter").attr("id","glow-layer").append("feGaussianBlur").attr("stdDeviation","6").attr("result","glowBlur"),u.select("#glow-layer").append("feColorMatrix").attr("type","matrix").attr("values","1 0 0 0 0 0 1 0 0 0 0 0 1 0 0 0 0 0 0.5 0").attr("result","glowColor");const k=E().value(i=>i.value).padAngle(.02),w=h().innerRadius(s).outerRadius(n).cornerRadius(100),C=h().innerRadius(s).outerRadius(n).cornerRadius(100),x=_().domain(a.map((i,c)=>c.toString())).range(e),f=g.append("g").attr("transform",`translate(${b}, ${N})`).selectAll("g").data(k(a)).enter().append("g");f.append("path").attr("class","glow-layer").attr("d",C).attr("fill",(i,c)=>x(c.toString())).attr("filter","url(#glow-layer)").style("opacity",0).style("pointer-events","none"),f.append("path").attr("class","main-slice").attr("d",w).attr("fill",(i,c)=>x(c.toString())).attr("stroke","none"),f.on("mouseenter",function(){p(this).select(".glow-layer").transition().duration(300).style("opacity",1)}).on("mouseleave",function(){p(this).select(".glow-layer").transition().duration(300).style("opacity",0)})},[a,r,o,s,n,e]),t.jsxs("div",{className:"relative flex flex-col items-center justify-center rounded-full",style:{background:"linear-gradient(0deg, rgba(255, 255, 255, 0.05) 0%, rgba(255, 255, 255, 0) 100%)"},children:[t.jsx("svg",{ref:d,width:r,height:o,className:"relative z-10"}),t.jsx("div",{className:"absolute inset-0 flex items-center justify-center",children:l}),t.jsx("div",{className:"pointer-events-none absolute inset-0 rounded-full",style:{background:"linear-gradient(0deg, rgba(255, 255, 255, 0.1) 0%, rgba(255, 255, 255, 0) 100%)",maskImage:"radial-gradient(farthest-side, transparent calc(100% - 1px),#fff 0)",WebkitMaskComposite:"destination-out",maskComposite:"exclude"}}),t.jsx("div",{className:"pointer-events-none absolute inset-[10%] rounded-full",style:{background:"linear-gradient(180deg, rgba(255, 255, 255, 0.1) 0%, rgba(255, 255, 255, 0) 100%)",maskImage:"radial-gradient(farthest-side, transparent calc(100% - 1px),#fff 0)",WebkitMaskComposite:"destination-out",maskComposite:"exclude"}})]})},O=m.memo(L);j.schema;function $({portfolio:a,config:r}){const{priced:o}=M(a.holdings),s=m.useMemo(()=>o.map((e,l)=>({name:A(e.symbol),value:e.value??0,color:y[l%y.length]})).filter(e=>e.value>0).sort((e,l)=>l.value-e.value),[o]),n=s.reduce((e,l)=>e+l.value,0);return s.length===0?t.jsx(G,{children:"no live prices yet"}):t.jsxs("div",{className:"flex h-full w-full flex-col items-center justify-center gap-4",children:[t.jsx(O,{data:s,width:200,height:200,innerRadius:58,outerRadius:92,colors:s.map(e=>e.color),children:t.jsxs("div",{className:"flex flex-col items-center gap-0.5",children:[t.jsx(P,{portfolio:a,config:r,className:"caption text-soft"}),t.jsx("span",{className:"metric-lg text-strong",children:v(n)})]})}),t.jsx("div",{className:"flex w-full max-w-xs flex-wrap justify-center gap-x-5 gap-y-1.5",children:s.map(e=>t.jsxs("div",{className:"flex items-center gap-1.5",children:[t.jsx("span",{className:"h-2 w-2 flex-shrink-0 rounded-full",style:{background:e.color}}),t.jsx("span",{className:"body-sm text-soft",children:e.name}),t.jsx("span",{className:"body-sm text-normal font-bold tabular-nums",children:S(e.value/n*100,1)}),t.jsx("span",{className:"caption text-soft tabular-nums",children:v(e.value)})]},e.name))})]})}function I({config:a}){return t.jsx(F,{config:a,loadingLabel:"loading allocation…",children:r=>t.jsx($,{portfolio:r,config:a})})}const q=R({...j,component:I});export{q as portfolioAllocationFrame};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{j as s,r as d}from"./react-qoZPGuNy.js";import{j as b,k as j,l as g,A as y,m as w}from"./index-
|
|
1
|
+
import{j as s,r as d}from"./react-qoZPGuNy.js";import{j as b,k as j,l as g,A as y,m as w}from"./index-BgSQpj_B.js";import{F as h}from"./ui-Bq3RQsdJ.js";function P(n){if(n.source==="wallet"){const o=(n.address??"").trim();return o?{kind:"wallet",address:o}:null}return{kind:"binance"}}const C={WETH:"ETH",WBTC:"BTC"};function x(n){return C[n.toUpperCase()]??n}function D(n){const o=n??[],r=o.map(e=>x(e.symbol)),l=j(r);return d.useMemo(()=>{const e=o.map(a=>{const u=l[x(a.symbol)],c=u!==void 0?a.amount*u:a.valueUsd;return{...a,value:c}}),i=e.reduce((a,u)=>a+(u.value??0),0);return{priced:e,total:i}},[n,l])}function _({portfolio:n,config:o,className:r=""}){var i;const l=n.label??(o.source==="wallet"?"wallet":"portfolio"),e=(i=o.address)==null?void 0:i.trim();return o.source==="wallet"&&e?s.jsx("a",{href:`https://etherscan.io/address/${encodeURIComponent(e)}`,target:"_blank",rel:"noopener noreferrer",title:"View on Etherscan",className:`hover:text-white hover:underline ${r}`,onClick:a=>a.stopPropagation(),onPointerDown:a=>a.stopPropagation(),children:l}):s.jsx("span",{className:r,children:l})}function v(n,o){const r=(n==null?void 0:n.kind)==="binance",[l,e]=d.useState({loading:r,connected:!1,keyMasked:null});return d.useEffect(()=>{if(!r||!n){e({loading:!1,connected:!1,keyMasked:null});return}let i=!1;return e(a=>({...a,loading:!0})),fetch(`${g}?source=${n.kind}`,{headers:{accept:"application/json"}}).then(a=>a.ok?a.json():{connected:!1,keyMasked:null}).then(a=>{i||e({loading:!1,connected:!!a.connected,keyMasked:a.keyMasked??null})}).catch(()=>{i||e({loading:!1,connected:!1,keyMasked:null})}),()=>{i=!0}},[r,n==null?void 0:n.kind,o]),l}function N(n){const[o,r]=d.useState(0),l=d.useCallback(()=>r(p=>p+1),[]),e=P(n),i=v(e,o),a=(e==null?void 0:e.kind)==="binance",u=!!e&&(!a||i.connected),{portfolio:c,isLoading:f}=b(u?e:null);let t;return e?a&&i.loading?t={state:"checking"}:a&&!i.connected?t={state:"needs-connect",source:e}:f&&!c?t={state:"loading"}:c?c.holdings.length===0?t={state:"empty",portfolio:c}:t={state:"live",portfolio:c}:t={state:"error"}:t={state:"needs-address"},{view:t,refresh:l}}const m="w-full rounded-md border border-white/10 bg-white/[0.04] px-2 py-1.5 text-xs text-white/90 outline-none focus:border-white/25 placeholder:text-white/30",k="rounded-md bg-[hsl(var(--zf-accent-hue,242)_90%_60%)] px-3 py-1.5 text-xs font-semibold text-white disabled:opacity-50";function S({onConnected:n}){const[o,r]=d.useState(""),[l,e]=d.useState(""),[i,a]=d.useState(!1),[u,c]=d.useState(null),f=async()=>{a(!0),c(null);try{const t=await fetch(g,{method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify({source:"binance",key:o.trim(),secret:l.trim()})}),p=await t.json().catch(()=>({}));if(!t.ok||!p.ok)throw new Error(p.error??`HTTP ${t.status}`);r(""),e(""),n()}catch(t){c(t instanceof Error?t.message:String(t))}finally{a(!1)}};return s.jsxs("div",{className:"flex h-full w-full flex-col justify-center gap-2 px-1",children:[s.jsxs("div",{className:"flex items-center gap-1.5",children:[s.jsx(y,{symbol:"BNB",size:18}),s.jsx("span",{className:"text-strong text-sm font-bold",children:"Connect Binance"})]}),s.jsxs("p",{className:"caption text-soft",children:["Use a ",s.jsx("strong",{children:"read-only"})," key + secret — create them in Binance"," ",s.jsx("a",{href:"https://www.binance.com/en/my/settings/api-management",target:"_blank",rel:"noopener noreferrer",className:"text-[hsl(var(--zf-accent-hue,242)_90%_72%)] underline underline-offset-2 hover:text-white",onClick:t=>t.stopPropagation(),onPointerDown:t=>t.stopPropagation(),children:"API Management"})," ","(enable Reading only). Both stay on your machine, never shared."]}),s.jsx("input",{className:m,placeholder:"API key",value:o,autoComplete:"off",onChange:t=>r(t.target.value),onPointerDown:t=>t.stopPropagation()}),s.jsx("input",{className:m,placeholder:"API secret",type:"password",value:l,autoComplete:"off",onChange:t=>e(t.target.value),onPointerDown:t=>t.stopPropagation()}),u?s.jsx("p",{className:"caption text-[#ff6b81]",children:u}):null,s.jsx("button",{type:"button",className:k,disabled:i||!o.trim()||!l.trim(),onClick:t=>{t.stopPropagation(),f()},onPointerDown:t=>t.stopPropagation(),children:i?"Verifying…":"Connect"})]})}function E({current:n}){const o=w(),[r,l]=d.useState(n??"");return s.jsxs("div",{className:"flex h-full w-full flex-col justify-center gap-2 px-1",children:[s.jsxs("div",{className:"flex items-center gap-1.5",children:[s.jsx(y,{symbol:"ETH",size:18}),s.jsx("span",{className:"text-strong text-sm font-bold",children:"Track a wallet"})]}),s.jsx("p",{className:"caption text-soft",children:"Enter a public Ethereum address or ENS name. No keys — it’s public on-chain data. Sharing this dashboard reveals the holdings."}),s.jsx("input",{className:m,placeholder:"0x… or name.eth",value:r,autoComplete:"off",onChange:e=>l(e.target.value),onPointerDown:e=>e.stopPropagation()}),o?s.jsx("button",{type:"button",className:k,disabled:!r.trim(),onClick:e=>{e.stopPropagation(),o({address:r.trim()})},onPointerDown:e=>e.stopPropagation(),children:"Track"}):s.jsx("p",{className:"caption text-soft",children:"Set the address in the frame’s config to start tracking."})]})}function I({config:n,loadingLabel:o="loading portfolio…",children:r}){const{view:l,refresh:e}=N(n);switch(l.state){case"needs-address":case"needs-connect":return s.jsx(T,{view:l,config:n,onConnected:e});case"checking":case"loading":return s.jsx(h,{loading:!0,children:o});case"error":return s.jsx(h,{children:"couldn’t load — check the address or try again"});case"empty":return s.jsx(h,{children:"no holdings to show"});case"live":return s.jsx(s.Fragment,{children:r(l.portfolio)})}}function T({view:n,config:o,onConnected:r}){return n.state==="needs-connect"&&n.source.kind==="binance"?s.jsx(S,{onConnected:r}):s.jsx(E,{current:o.address})}export{I as P,_ as a,D as u};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{j as s,r as m}from"./react-qoZPGuNy.js";import{f as d,i as n,A as x,h as f}from"./index-
|
|
1
|
+
import{j as s,r as m}from"./react-qoZPGuNy.js";import{f as d,i as n,A as x,h as f}from"./index-BgSQpj_B.js";import{f as i,b as h,a as p,c as u}from"./format-CfAcS4D8.js";import{P as b,u as g,a as j}from"./portfolio-common-DnESc3oR.js";import{s as N}from"./ui-Bq3RQsdJ.js";n.schema;function y(t){return t>=1e3?t.toLocaleString("en-US",{maximumFractionDigits:2}):t>=1?t.toFixed(4).replace(/\.?0+$/,""):t.toPrecision(4)}function v({portfolio:t,config:a}){const{priced:l,total:r}=g(t.holdings),c=m.useMemo(()=>[...l].sort((e,o)=>(o.value??0)-(e.value??0)),[l]);return s.jsxs("div",{className:"flex h-full min-h-0 flex-col gap-2",children:[s.jsxs("div",{className:"flex items-baseline justify-between border-b border-white/[0.06] pb-1.5",children:[s.jsx(j,{portfolio:t,config:a,className:"caption text-soft"}),s.jsx("span",{className:"metric-sm text-strong",children:i(r)})]}),s.jsx("div",{className:N,children:s.jsx("table",{className:"w-full text-xs",children:s.jsx("tbody",{children:c.map(e=>{const o=r>0?(e.value??0)/r*100:0;return s.jsxs("tr",{className:"border-b border-white/[0.04]",children:[s.jsx("td",{className:"py-1.5",children:s.jsxs("div",{className:"flex items-center gap-1.5",children:[s.jsx(x,{symbol:e.symbol,size:16}),s.jsx("span",{className:"text-normal font-semibold",children:f(e.symbol)})]})}),s.jsx("td",{className:"text-soft py-1.5 text-right tabular-nums",children:y(e.amount)}),s.jsx("td",{className:"text-normal py-1.5 text-right font-semibold tabular-nums",children:e.value!==void 0?i(e.value):"—"}),s.jsx("td",{className:"text-soft py-1.5 text-right tabular-nums",children:h(o,1)}),s.jsx("td",{className:"py-1.5 text-right tabular-nums",children:e.changePct24h!==void 0?s.jsx("span",{style:{color:u(e.changePct24h)},children:p(e.changePct24h)}):s.jsx("span",{className:"text-soft",children:"·"})})]},e.symbol)})})})})]})}function P({config:t}){return s.jsx(b,{config:t,loadingLabel:"loading holdings…",children:a=>s.jsx(v,{portfolio:a,config:t})})}const L=d({...n,component:P});export{L as portfolioHoldingsFrame};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{j as e,r as o}from"./react-qoZPGuNy.js";import{L as V}from"./liveline-bcaEuskN.js";import{f as N,a as L,c as D}from"./format-CfAcS4D8.js";import{u as I,o as F}from"./live-tick-9Q3ubPF9.js";import{P as H,u as W,a as _}from"./portfolio-common-
|
|
1
|
+
import{j as e,r as o}from"./react-qoZPGuNy.js";import{L as V}from"./liveline-bcaEuskN.js";import{f as N,a as L,c as D}from"./format-CfAcS4D8.js";import{u as I,o as F}from"./live-tick-9Q3ubPF9.js";import{P as H,u as W,a as _}from"./portfolio-common-DnESc3oR.js";import{f as k,p as y}from"./index-BgSQpj_B.js";import"./ui-Bq3RQsdJ.js";const w=720,d=3,q={top:12,right:66,bottom:28,left:8};y.schema;function A(){return typeof document>"u"?"hsl(242 90% 66%)":`hsl(${getComputedStyle(document.documentElement).getPropertyValue("--zf-accent-hue").trim()||"242"} 90% 66%)`}function G({portfolio:a,config:c,windowSec:h}){var v;const{total:t}=W(a.holdings),p=o.useMemo(()=>A(),[]),{ref:P,visibleRef:x}=I(),u=o.useRef(!1),[s,M]=o.useState([]),b=o.useRef(t);o.useEffect(()=>{b.current=t},[t]);const i=o.useCallback(()=>{if(!x.current){u.current=!0;return}const n=b.current;if(!Number.isFinite(n)||n<=0)return;const l=Date.now()/1e3,S=u.current;u.current=!1,M(C=>{const r=S?[]:C,f=r[r.length-1];if(f&&Math.abs(l-f.time)<.5&&f.value===n)return r;const m=r.length===0?[{time:l-d,value:n},{time:l,value:n}]:[...r,{time:l,value:n}];return m.length>w?m.slice(-w):m})},[x]);o.useEffect(()=>{i()},[i,t]),o.useEffect(()=>F(i),[i]);const g=(v=s[0])==null?void 0:v.value,j=g&&t?(t/g-1)*100:0,E=o.useMemo(()=>s.length===0?[]:[{id:"equity",label:"Portfolio",color:p,data:s,value:t}],[s,t,p]),R=o.useMemo(()=>{if(s.length===0)return d;const n=s[s.length-1].time-s[0].time;return Math.min(h,Math.max(d,Math.ceil(n)))},[s,h]);return e.jsxs("div",{ref:P,className:"flex h-full min-h-0 flex-col",children:[e.jsxs("div",{className:"flex flex-none items-baseline justify-between border-b border-white/[0.06] pb-2",children:[e.jsxs("div",{className:"flex flex-col",children:[e.jsx(_,{portfolio:a,config:c,className:"caption text-soft"}),e.jsx("span",{className:"metric-md text-strong",children:N(t)})]}),e.jsxs("span",{className:"body-sm font-semibold tabular-nums",style:{color:D(j)},children:[L(j)," ",e.jsx("span",{className:"caption text-soft",children:"session"})]})]}),e.jsx("div",{className:"min-h-0 flex-1 [&>div[style*='align-items']]:!hidden",children:e.jsx(V,{data:[],value:t,series:E,theme:"dark",window:R,grid:!0,loading:s.length<=1,scrub:!1,badge:!1,formatValue:N,padding:q,style:{width:"100%",height:"100%"}})})]})}function O({config:a}){return e.jsx(H,{config:a,loadingLabel:"loading portfolio…",children:c=>e.jsx(G,{portfolio:c,config:a,windowSec:a.windowSec})})}const K=k({...y,component:O});export{K as portfolioValueFrame};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{j as i,r as o}from"./react-qoZPGuNy.js";import{L as T}from"./liveline-bcaEuskN.js";import{f as j,a1 as v,A as E,k as y,h as P,a2 as k}from"./index-
|
|
1
|
+
import{j as i,r as o}from"./react-qoZPGuNy.js";import{L as T}from"./liveline-bcaEuskN.js";import{f as j,a1 as v,A as E,k as y,h as P,a2 as k}from"./index-BgSQpj_B.js";import{d as x}from"./format-CfAcS4D8.js";import{u as A}from"./live-tick-9Q3ubPF9.js";import{F as N}from"./ui-Bq3RQsdJ.js";const f={"1m":6e4,"5m":5*6e4,"15m":15*6e4,"1h":60*6e4,"4h":240*6e4,"1d":1440*6e4},w=60,F={top:12,right:56,bottom:28,left:12};v.schema;function I({config:t}){const s=f[t.interval],c=o.useMemo(()=>Date.now()-s*w,[s]),{candles:n,isLoading:p}=k(t.symbol,t.interval,c,Math.min(s,6e4)),a=y([t.symbol])[t.symbol],{ref:M,visibleRef:b}=A(),h=o.useRef(!1),[u,g]=o.useState([]);o.useEffect(()=>{if(a===void 0)return;if(!b.current){h.current=!0;return}const e=h.current;h.current=!1,g(m=>{const d=[...e?[]:m,{time:Date.now()/1e3,value:a}];return d.length>900?d.slice(-600):d})},[a,b]),o.useEffect(()=>g([]),[t.symbol]);const S=o.useMemo(()=>n.slice(0,-1).map(e=>({time:e.time/1e3,open:e.open,high:e.high,low:e.low,close:e.close})),[n]),r=n[n.length-1],C=o.useMemo(()=>{if(!r)return;const e=a??r.close;return{time:r.time/1e3,open:r.open,high:Math.max(r.high,e),low:Math.min(r.low,e),close:e}},[r,a]),D=a??(r==null?void 0:r.close)??0,L=o.useMemo(()=>s>=f["1d"]?e=>new Date(e*1e3).toLocaleDateString("en-US",{month:"short",day:"numeric"}):s>=f["1h"]?e=>{const m=new Date(e*1e3);return`${m.toLocaleDateString("en-US",{month:"short",day:"numeric"})} ${String(m.getHours()).padStart(2,"0")}h`}:e=>new Date(e*1e3).toLocaleTimeString("en-US",{hour12:!1,hour:"2-digit",minute:"2-digit"}),[s]),R=o.useMemo(()=>{const e=n.map(l=>({time:l.time/1e3,value:l.close}));if(u.length===0)return e;const m=u[0].time;return[...e.filter(l=>l.time<m),...u]},[n,u]);return p&&n.length===0?i.jsx(N,{loading:!0,children:"loading chart…"}):i.jsx("div",{ref:M,className:"h-full min-h-0",children:i.jsx(T,{mode:t.mode,data:R,value:D,candles:S,candleWidth:s/1e3,liveCandle:C,window:s/1e3*w,color:t.color,theme:"dark",loading:p,formatValue:x,formatTime:L,padding:F,showValue:!0,fill:!0,pulse:!0})})}function V({config:t}){const s=t.mode==="candle",c=y(s?[t.symbol]:[])[t.symbol];return i.jsxs(i.Fragment,{children:[P(t.symbol),s&&c!==void 0&&i.jsx("span",{style:{marginInlineStart:"0.5em",color:"rgba(255, 255, 255, 0.82)",fontVariantNumeric:"tabular-nums"},children:x(c)})]})}const W=j({...v,component:I,titleIcon:({config:t})=>i.jsx(E,{symbol:t.symbol,size:14}),titleContent:V});export{W as priceChartFrame};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{j as t,r as p}from"./react-qoZPGuNy.js";import{f as v,a3 as f,h as d,a4 as L,a5 as O}from"./index-
|
|
1
|
+
import{j as t,r as p}from"./react-qoZPGuNy.js";import{f as v,a3 as f,h as d,a4 as L,a5 as O}from"./index-BgSQpj_B.js";import{a as g,d as F}from"./format-CfAcS4D8.js";import{F as u}from"./ui-Bq3RQsdJ.js";import{a as s,C as h}from"./chart-utils-BYIZMM9J.js";import{M as T}from"./index-DK7jWlTL.js";import"./d3-xK4fOkBU.js";import"./utils-DaT-yT0k.js";const D={"24h":{ms:1440*60*1e3,interval:"15m",timeframe:s["24h"]},"7D":{ms:10080*60*1e3,interval:"1h",timeframe:s["7D"]},"1M":{ms:720*60*60*1e3,interval:"4h",timeframe:s["1M"]}};f.schema;function E({config:e}){const{ms:m,interval:C,timeframe:M}=D[e.lookback],x=p.useMemo(()=>Date.now()-m,[m]),{candles:o,isLoading:S}=L(e.symbols,C,x),i=p.useMemo(()=>e.symbols.map((r,j)=>{var c;const n=o[r]??[],l=(c=n[0])==null?void 0:c.close;return{id:r,name:d(r),iconImageUrl:O(r),color:h[j%h.length],data:n.map(a=>({date:new Date(a.time).toISOString(),value:e.normalize&&l?(a.close/l-1)*100:a.close}))}}),[e.symbols,e.normalize,o]);return S?t.jsx(u,{loading:!0,children:"loading prices…"}):i.every(r=>r.data.length===0)?t.jsx(u,{children:"no price data yet"}):t.jsx(T,{series:i,timeframe:M,height:250,formatValue:e.normalize?g:F})}function I({config:e}){return t.jsx(t.Fragment,{children:e.symbols.map(d).join(" vs ")})}const w=v({...f,component:E,titleContent:I});export{w as priceCompareFrame};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as o,j as u}from"./react-qoZPGuNy.js";import{L as T}from"./liveline-bcaEuskN.js";import{f as V,a6 as L,k as W,v as $,h as N,A as B}from"./index-
|
|
1
|
+
import{r as o,j as u}from"./react-qoZPGuNy.js";import{L as T}from"./liveline-bcaEuskN.js";import{f as V,a6 as L,k as W,v as $,h as N,A as B}from"./index-BgSQpj_B.js";import{d as k,a as E,c as G}from"./format-CfAcS4D8.js";import{u as K,o as U}from"./live-tick-9Q3ubPF9.js";import{C as j}from"./chart-utils-BYIZMM9J.js";import"./d3-xK4fOkBU.js";const _=720,D=3,X={top:12,right:58,bottom:28,left:8};L.schema;function O(i){return i!==void 0&&Number.isFinite(i)}function q(i,s,S,m){let x=!1;const b={...i};for(const p of s){const d=S[p];if(!O(d))continue;const l=b[p]??[],g=l[l.length-1];if(g&&Math.abs(m-g.time)<.5&&g.value===d)continue;const h=l.length===0?[{time:m-D,value:d},{time:m,value:d}]:[...l,{time:m,value:d}];b[p]=h.length>_?h.slice(-_):h,x=!0}return x?b:i}function z(i,s){return s===0?0:(i/s-1)*100}function J({config:i}){const s=i.symbols,S=s.join("|"),m=W(s),x=$(s),{ref:b,visibleRef:p}=K(),d=o.useRef(!1),[l,g]=o.useState({}),[h,C]=o.useState(()=>new Set),v=o.useMemo(()=>{var n;const e={};for(const t of s){const a=m[t]??((n=x[t])==null?void 0:n.markPx);O(a)&&(e[t]=a)}return e},[m,x,s]),P=o.useRef(v);o.useEffect(()=>{P.current=v},[v]),o.useEffect(()=>{const e=new Set(s);g(n=>{let t=!1;const a={};for(const[r,f]of Object.entries(n)){if(!e.has(r)){t=!0;continue}a[r]=f}return t?a:n}),C(n=>{const t=new Set([...n].filter(a=>e.has(a)));return t.size===n.size?n:t})},[S,s]);const F=o.useCallback(e=>{C(n=>{const t=new Set(n);return t.has(e)?(t.delete(e),t):s.length-t.size<=1?n:(t.add(e),t)})},[s]),y=o.useCallback(()=>{if(!p.current){d.current=!0;return}const e=P.current;if(Object.keys(e).length===0)return;const n=Date.now()/1e3,t=d.current;d.current=!1,g(a=>q(t?{}:a,s,e,n))},[S,s,p]);o.useEffect(()=>{y()},[y,v]),o.useEffect(()=>U(y),[y]);const R=o.useMemo(()=>s.flatMap((e,n)=>{var f,c;if(h.has(e))return[];const t=l[e]??[],a=(f=t[0])==null?void 0:f.value;if(!a||t.length===0)return[];const r=i.normalize?t.map(w=>({time:w.time,value:z(w.value,a)})):t;return[{id:e,label:N(e),color:j[n%j.length],data:r,value:((c=r[r.length-1])==null?void 0:c.value)??0}]}),[l,h,s,i.normalize]),H=o.useMemo(()=>{var a,r;let e=1/0,n=-1/0;for(const f of s){const c=l[f]??[];c.length!==0&&(e=Math.min(e,((a=c[0])==null?void 0:a.time)??1/0),n=Math.max(n,((r=c[c.length-1])==null?void 0:r.time)??-1/0))}const t=Number.isFinite(e)&&Number.isFinite(n)?n-e:0;return Math.min(i.windowSec,Math.max(D,Math.ceil(t)))},[l,s,i.windowSec]),A=R.some(e=>e.data.length>1);return u.jsxs("div",{ref:b,className:"flex h-full min-h-0 flex-col",children:[u.jsx("div",{className:"grid flex-none grid-cols-1 gap-x-3 gap-y-1.5 border-b border-white/[0.06] pb-2 sm:grid-cols-2",children:s.map((e,n)=>{var w,I;const t=v[e],a=(I=(w=l[e])==null?void 0:w[0])==null?void 0:I.value,r=t!==void 0&&a?z(t,a):void 0,f=j[n%j.length],c=h.has(e);return u.jsxs("button",{type:"button","aria-pressed":!c,title:`${c?"Show":"Hide"} ${N(e)}`,className:`caption grid min-w-0 grid-cols-[auto_auto_minmax(0,1fr)_auto] items-center gap-1.5 rounded-md px-1.5 py-0.5 text-left transition ${c?"opacity-40 hover:opacity-70":"bg-white/[0.035] opacity-100 hover:bg-white/[0.06]"}`,onClick:M=>{M.stopPropagation(),F(e)},onPointerDown:M=>M.stopPropagation(),children:[u.jsx("span",{className:"h-1.5 w-1.5 rounded-full",style:{backgroundColor:f}}),u.jsx(B,{symbol:e,size:14}),u.jsx("span",{className:"truncate font-bold text-strong",children:N(e)}),u.jsxs("span",{className:"text-normal tabular-nums",children:[t!==void 0?k(t):"…",r!==void 0?u.jsx("span",{className:"ml-1 tabular-nums",style:{color:G(r)},children:E(r)}):null]})]},e)})}),u.jsx("div",{className:"min-h-0 flex-1 [&>div[style*='align-items']]:!hidden",children:u.jsx(T,{data:[],value:0,series:R,theme:"dark",window:H,grid:!0,loading:!A,scrub:!1,badge:!1,formatValue:i.normalize?E:k,padding:X,seriesToggleCompact:s.length>4,style:{width:"100%",height:"100%"}})})]})}const ae=V({...L,component:J});export{ae as priceLivelineFrame};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{j as i}from"./react-qoZPGuNy.js";import{f as d,a7 as c,a8 as l,a9 as x,h as g}from"./index-
|
|
1
|
+
import{j as i}from"./react-qoZPGuNy.js";import{f as d,a7 as c,a8 as l,a9 as x,h as g}from"./index-BgSQpj_B.js";import{M as f}from"./mover-row-CO2STKkw.js";import{F as u,s as h}from"./ui-Bq3RQsdJ.js";import"./format-CfAcS4D8.js";c.schema;function k({config:e}){const{mids:t,isLoading:m}=l(e.symbols),{stats:r,isLoading:n}=x(e.symbols),p=e.symbols.some(a=>{var s;return t[a]!==void 0||((s=r[a])==null?void 0:s.markPx)!==void 0});return(m||n)&&!p?i.jsx(u,{loading:!0,children:"loading prices…"}):i.jsx("div",{className:`flex flex-col gap-1.5 ${h}`,children:e.symbols.map(a=>{var s,o;return i.jsx(f,{symbol:a,label:g(a),price:t[a]??((s=r[a])==null?void 0:s.markPx),changePct:(o=r[a])==null?void 0:o.changePct,logoSize:18,gap:"gap-3"},a)})})}const L=d({...c,component:k});export{L as priceTickerFrame};
|
package/runtime/assets/{protocol-fees-treemap-39F-aE33.js → protocol-fees-treemap-D-koQrKr.js}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as c,j as s}from"./react-qoZPGuNy.js";import{f as i}from"./format-CfAcS4D8.js";import{f as p,au as n,av as f}from"./index-
|
|
1
|
+
import{r as c,j as s}from"./react-qoZPGuNy.js";import{f as i}from"./format-CfAcS4D8.js";import{f as p,au as n,av as f}from"./index-BgSQpj_B.js";import{T as l,a as u}from"./treemap-leaf-DNIoJEK-.js";import{F as m}from"./ui-Bq3RQsdJ.js";import"./utils-DaT-yT0k.js";import"./d3-xK4fOkBU.js";n.schema;function h({width:t,height:a,data:o}){const r=i(o.fees24h);return s.jsx(u,{width:t,height:a,label:o.id,secondary:r,title:`${o.id} · ${r} 24h fees`})}function d({config:t}){const{entries:a,isLoading:o}=f(),r=c.useMemo(()=>a.slice(0,t.topN).map(e=>({id:e.name,value:e.fees24h,fees24h:e.fees24h,changePct:e.changePct??0})),[a,t.topN]);return o?s.jsx(m,{loading:!0,children:"loading protocol fees…"}):r.length===0?s.jsx(m,{children:"no protocol fee data"}):s.jsx(l,{data:r,LeafComponent:h,getColorValue:e=>e.changePct})}const L=p({...n,component:d});export{L as protocolFeesTreemapFrame};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as n,j as e}from"./react-qoZPGuNy.js";import{p as C,f as M}from"./format-CfAcS4D8.js";import{f as S,as as f,at as T}from"./index-
|
|
1
|
+
import{r as n,j as e}from"./react-qoZPGuNy.js";import{p as C,f as M}from"./format-CfAcS4D8.js";import{f as S,as as f,at as T}from"./index-BgSQpj_B.js";import{F as p}from"./ui-Bq3RQsdJ.js";import{a,C as c}from"./chart-utils-BYIZMM9J.js";import{M as v}from"./index-DK7jWlTL.js";import"./d3-xK4fOkBU.js";import"./utils-DaT-yT0k.js";const x={"7D":{ms:10080*60*1e3,timeframe:a["7D"]},"1M":{ms:720*60*60*1e3,timeframe:a["1M"]},"3M":{ms:2160*60*60*1e3,timeframe:a["3M"]}};f.schema;function L({config:o}){const{ms:m,timeframe:u}=x[o.lookback],s=n.useMemo(()=>Date.now()-m,[m]),{history:i,isLoading:h}=T(o.protocols),l=n.useMemo(()=>o.protocols.map((t,d)=>({id:t,name:C(t),color:c[d%c.length],data:(i[t]??[]).filter(r=>r.time>=s).map(r=>({date:new Date(r.time).toISOString(),value:r.value}))})),[o.protocols,i,s]);return h?e.jsx(p,{loading:!0,children:"loading protocol TVL…"}):l.every(t=>t.data.length===0)?e.jsx(p,{children:"no protocol TVL data yet"}):e.jsx(v,{series:l,timeframe:u,height:250,formatValue:M})}const I=S({...f,component:L});export{I as protocolTvlChartFrame};
|
package/runtime/assets/{protocol-tvl-treemap-DusQ6xL2.js → protocol-tvl-treemap-I8fjLZU7.js}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as n,j as m}from"./react-qoZPGuNy.js";import{f as c}from"./format-CfAcS4D8.js";import{f as i,aq as l,ar as p}from"./index-
|
|
1
|
+
import{r as n,j as m}from"./react-qoZPGuNy.js";import{f as c}from"./format-CfAcS4D8.js";import{f as i,aq as l,ar as p}from"./index-BgSQpj_B.js";import{T as f,a as u}from"./treemap-leaf-DNIoJEK-.js";import{F as s}from"./ui-Bq3RQsdJ.js";import"./utils-DaT-yT0k.js";import"./d3-xK4fOkBU.js";l.schema;function T({width:r,height:a,data:e}){const t=c(e.tvl);return m.jsx(u,{width:r,height:a,label:e.id,secondary:t,title:`${e.id} · ${t} TVL`})}function d({config:r}){const{entries:a,isLoading:e}=p(),t=n.useMemo(()=>a.slice(0,r.topN).map(o=>({id:o.name,value:o.tvl,tvl:o.tvl,changePct:o.changePct??0})),[a,r.topN]);return e?m.jsx(s,{loading:!0,children:"loading protocol TVL…"}):t.length===0?m.jsx(s,{children:"no protocol TVL data"}):m.jsx(f,{data:t,LeafComponent:T,getColorValue:o=>o.changePct})}const C=i({...l,component:d});export{C as protocolTvlTreemapFrame};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as s,j as t}from"./react-qoZPGuNy.js";import{f as u,aH as i}from"./index-
|
|
1
|
+
import{r as s,j as t}from"./react-qoZPGuNy.js";import{f as u,aH as i}from"./index-BgSQpj_B.js";i.schema;const c="var(--color-highlight)";function d({config:a}){const e=a.quotes,[r,l]=s.useState(0);s.useEffect(()=>l(0),[a.quotes]),s.useEffect(()=>{if(a.intervalSec<=0||e.length<=1)return;const o=window.setInterval(()=>l(n=>(n+1)%e.length),a.intervalSec*1e3);return()=>window.clearInterval(o)},[a.intervalSec,e.length]);const m=e[Math.min(r,e.length-1)]??"";return t.jsx("div",{className:"flex h-full w-full items-center justify-center [container-type:size]",children:t.jsxs("figure",{className:"relative max-h-full overflow-auto px-3 text-center",children:[t.jsx("span",{"aria-hidden":!0,className:"block font-dmsans font-black leading-none",style:{fontSize:"clamp(1.5rem, 14cqmin, 3rem)",color:c},children:"“"}),t.jsx("blockquote",{className:"body-md text-normal -mt-[0.3em] whitespace-pre-wrap italic leading-snug",style:{fontSize:"clamp(0.85rem, 8cqmin, 1.25rem)"},children:m}),e.length>1&&t.jsx("figcaption",{className:"mt-2 flex justify-center gap-1.5","aria-hidden":!0,children:e.map((o,n)=>t.jsx("span",{className:"h-1 w-1 rounded-full transition-colors",style:{background:n===Math.min(r,e.length-1)?c:"var(--color-disabled)"}},n))})]})})}const x=u({...i,component:d});export{x as quoteFrame};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{j as e}from"./react-qoZPGuNy.js";import{b as a,f as g}from"./format-CfAcS4D8.js";import{M as v}from"./metric-row-BVVhjsjK.js";import{f as j,aa as f,ab as R,ac as y}from"./index-
|
|
1
|
+
import{j as e}from"./react-qoZPGuNy.js";import{b as a,f as g}from"./format-CfAcS4D8.js";import{M as v}from"./metric-row-BVVhjsjK.js";import{f as j,aa as f,ab as R,ac as y}from"./index-BgSQpj_B.js";import{F as m}from"./ui-Bq3RQsdJ.js";f.schema;function b({config:t}){var l,d;const{rates:i,isLoading:x}=R(),{rates:o,isLoading:u}=y();if(x&&u)return e.jsx(m,{loading:!0,children:"loading official rates…"});if(!i.length&&!o.length)return e.jsx(m,{children:"no rates data yet"});const n=i.slice(0,t.maxReferenceRates),r=o.slice(0,t.maxTreasuryRates),c=(l=n[0])==null?void 0:l.date,h=(d=r[0])==null?void 0:d.date;return e.jsxs("div",{className:"flex h-full min-h-0 flex-col gap-3",children:[e.jsxs("div",{className:"flex items-baseline justify-between gap-3",children:[e.jsxs("div",{children:[e.jsx("div",{className:"caption text-soft uppercase",children:"official rates"}),e.jsx("div",{className:"body-sm text-normal",children:c?`as of ${c}`:"reference rates"})]}),e.jsx("div",{className:"caption text-soft text-right",children:"daily"})]}),e.jsx("div",{className:"min-h-0 flex-1 overflow-hidden",children:n.map(s=>{const p=s.targetRateFrom!==void 0&&s.targetRateTo!==void 0?`target ${a(s.targetRateFrom)}-${a(s.targetRateTo)}`:s.volumeInBillions!==void 0?`${g(s.volumeInBillions*1e9)} volume`:s.source;return e.jsx(v,{label:s.label,value:a(s.rate),meta:p},s.code)})}),t.showTreasuryAverageRates&&r.length>0&&e.jsxs("div",{className:"border-t border-white/[0.08] pt-2",children:[e.jsxs("div",{className:"caption text-soft mb-1 flex justify-between",children:[e.jsx("span",{children:"Treasury average rates"}),e.jsx("span",{children:h})]}),e.jsx("div",{className:"grid grid-cols-2 gap-1.5",children:r.map(s=>e.jsxs("div",{className:"rounded bg-white/[0.04] px-2 py-1.5",children:[e.jsx("div",{className:"caption text-soft truncate",children:s.security}),e.jsx("div",{className:"body-sm text-strong font-bold tabular-nums",children:a(s.rate)})]},`${s.date}-${s.security}`))})]})]})}const B=j({...f,component:b});export{B as ratesBoardFrame};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as n,j as e}from"./react-qoZPGuNy.js";import{i as y}from"./content-shared-BZ1XzrJx.js";import{f as g,a as k,c as w}from"./format-CfAcS4D8.js";import{f as F,b9 as b}from"./index-
|
|
1
|
+
import{r as n,j as e}from"./react-qoZPGuNy.js";import{i as y}from"./content-shared-BZ1XzrJx.js";import{f as g,a as k,c as w}from"./format-CfAcS4D8.js";import{f as F,b9 as b}from"./index-BgSQpj_B.js";import{M as R}from"./mini-line-chart-CHM5UBjJ.js";import"./d3-xK4fOkBU.js";import"./utils-DaT-yT0k.js";b.schema;function o({label:s,value:t,onChange:l}){return e.jsxs("label",{className:`flex flex-col gap-0.5 px-2 py-1 ${y}`,children:[e.jsx("span",{className:"caption text-soft truncate",children:s}),e.jsx("input",{type:"number",value:Number.isFinite(t)?t:0,onChange:a=>l(Number(a.target.value)),className:"body-sm text-strong w-full bg-transparent outline-none"})]})}function E({config:s}){const[t,l]=n.useState(s.principal),[a,j]=n.useState(s.ratePct),[c,v]=n.useState(s.periods),[i,N]=n.useState(s.contribution),{series:C,ending:P,contributed:p,gain:d}=n.useMemo(()=>{const M=a/100,S=Math.max(0,Math.min(600,Math.floor(c))),f=[{date:"0",value:t}];let r=t,m=t;for(let u=1;u<=S;u++)r=r*(1+M)+i,m+=i,f.push({date:String(u),value:r});return{series:f,ending:r,contributed:m,gain:r-m}},[t,a,c,i]),x=p>0?d/p*100:0,h=s.label.trim();return e.jsxs("div",{className:"flex h-full w-full flex-col gap-2",children:[h&&e.jsx("div",{className:"caption text-soft shrink-0 uppercase tracking-[0.12em]",children:h}),e.jsxs("div",{className:"shrink-0",children:[e.jsx("div",{className:"caption text-soft",children:"projected value"}),e.jsx("div",{className:"metric-lg text-strong",children:g(P)}),e.jsxs("div",{className:"body-sm",style:{color:w(x)},children:[k(x)," · ",g(d)," gain"]})]}),e.jsx("div",{className:"min-h-0 flex-1",children:e.jsx(R,{data:C,width:260,height:48,variant:"green",className:"w-full"})}),e.jsxs("div",{className:"grid shrink-0 grid-cols-2 gap-1.5",children:[e.jsx(o,{label:"principal",value:t,onChange:l}),e.jsx(o,{label:"rate %/period",value:a,onChange:j}),e.jsx(o,{label:"periods",value:c,onChange:v}),e.jsx(o,{label:"contribution",value:i,onChange:N})]})]})}const D=F({...b,component:E});export{D as returnsProjectorFrame};
|