From dfec7587305fee59f8304000994ca16a495f7389 Mon Sep 17 00:00:00 2001
From: Tyler Hoang <tyler@tylerhoang.xyz>
Date: Mon, 29 Jun 2026 01:41:22 -0700
Subject: feat: update financial overview components

---
 frontend/components/prism/FinancialsCard.tsx | 16 ++++++++++------
 1 file changed, 10 insertions(+), 6 deletions(-)

(limited to 'frontend/components/prism/FinancialsCard.tsx')

diff --git a/frontend/components/prism/FinancialsCard.tsx b/frontend/components/prism/FinancialsCard.tsx
index 43a2dc2..6e2fe01 100644
--- a/frontend/components/prism/FinancialsCard.tsx
+++ b/frontend/components/prism/FinancialsCard.tsx
@@ -1,6 +1,7 @@
 "use client";
 import type { FinancialRow, FinancialsResponse } from "@/types/api";
 import { fmtLarge } from "@/lib/format";
+import { CurrencyWarning } from "./CurrencyWarning";
 
 type StatementKey = "income" | "balance" | "cash_flow";
 type PeriodKey = "annual" | "quarterly";
@@ -12,13 +13,13 @@ type Props = {
   onChangePeriod: (p: PeriodKey) => void;
 };
 
-function fmtFinVal(val: number | null | undefined, isMargin: boolean): string {
+function fmtFinVal(val: number | null | undefined, isMargin: boolean, currency: string): string {
   if (val === null || val === undefined) return "—";
   if (isMargin) return `${(val * 100).toFixed(1)}%`;
-  return fmtLarge(val);
+  return fmtLarge(val, currency);
 }
 
-function FinRow({ row, lastColIdx }: { row: FinancialRow; lastColIdx: number }) {
+function FinRow({ row, lastColIdx, currency }: { row: FinancialRow; lastColIdx: number; currency: string }) {
   if (row.is_section) {
     return (
       <tr className="psm-fin-section-row">
@@ -52,7 +53,7 @@ function FinRow({ row, lastColIdx }: { row: FinancialRow; lastColIdx: number })
             .filter(Boolean)
             .join(" ")}
         >
-          {fmtFinVal(val, row.is_margin)}
+          {fmtFinVal(val, row.is_margin, currency)}
         </td>
       ))}
     </tr>
@@ -92,7 +93,10 @@ export function FinancialsCard({
           <table className="psm-fin-table">
             <thead>
               <tr>
-                <th className="psm-fin-label-col">USD (millions)</th>
+                <th className="psm-fin-label-col">
+                  {data.currency} (millions)
+                  <CurrencyWarning warning={data.currency_warning} />
+                </th>
                 {stmt.columns.map((col, i) => (
                   <th
                     key={i}
@@ -105,7 +109,7 @@ export function FinancialsCard({
             </thead>
             <tbody>
               {stmt.rows.map((row, i) => (
-                <FinRow key={i} row={row} lastColIdx={lastColIdx} />
+                <FinRow key={i} row={row} lastColIdx={lastColIdx} currency={data.currency} />
               ))}
             </tbody>
           </table>
-- 
cgit v1.3-2-g0d8e

