IO-3515 Add translations and logging.

This commit is contained in:
Patrick Fic
2026-02-19 13:54:39 -08:00
parent ae1408012f
commit b2bc19c5c9
7 changed files with 463 additions and 78 deletions

View File

@@ -36,11 +36,9 @@ const ConfidenceDisplay = ({ rowValue: { confidence, actual_price, actual_cost }
<Tooltip
title={
<div style={{ padding: "4px 0" }}>
<div style={{ marginBottom: 8, fontWeight: 600 }}>
{t("billlines.confidence.breakdown", { defaultValue: "Confidence Breakdown" })}
</div>
<div style={{ marginBottom: 8, fontWeight: 600 }}>{t("bills.labels.ai.confidence.breakdown")}</div>
<div style={{ marginBottom: 4 }}>
<strong>{t("billlines.confidence.overall", { defaultValue: "Overall" })}:</strong> {total.toFixed(1)}%
<strong>{t("bills.labels.ai.confidence.overall")}:</strong> {total.toFixed(1)}%
<Progress
percent={total}
size="small"
@@ -50,7 +48,7 @@ const ConfidenceDisplay = ({ rowValue: { confidence, actual_price, actual_cost }
/>
</div>
<div style={{ marginBottom: 4 }}>
<strong>{t("billlines.confidence.ocr", { defaultValue: "OCR" })}:</strong> {ocr.toFixed(1)}%
<strong>{t("bills.labels.ai.confidence.ocr")}:</strong> {ocr.toFixed(1)}%
<Progress
percent={ocr}
size="small"
@@ -60,7 +58,7 @@ const ConfidenceDisplay = ({ rowValue: { confidence, actual_price, actual_cost }
/>
</div>
<div>
<strong>{t("billlines.confidence.match", { defaultValue: "Job Match" })}:</strong> {jobMatch.toFixed(1)}%
<strong>{t("bills.labels.ai.confidence.match")}:</strong> {jobMatch.toFixed(1)}%
<Progress
percent={jobMatch}
size="small"
@@ -75,7 +73,7 @@ const ConfidenceDisplay = ({ rowValue: { confidence, actual_price, actual_cost }
<Space size="small">
{!parsed_actual_cost || !parsed_actual_price || parsed_actual_cost === 0 || parsed_actual_price === 0 ? (
<Tag color="red" style={{ margin: 0, cursor: "help", userSelect: "none" }}>
{t("billlines.confidence.missing_data", { defaultValue: "Missing Data" })}
{t("bills.labels.ai.confidence.missing_data")}
</Tag>
) : null}
<Tag color={color} style={{ margin: 0, cursor: "help", userSelect: "none" }}>