This commit is contained in:
Marcelo
2026-04-26 16:31:04 +00:00
parent 66c89f9bf4
commit 7e0fe5c2e1
28 changed files with 5310 additions and 2741 deletions

View File

@@ -1,6 +1,7 @@
"use client";
import { useI18n } from "@/lib/i18n/useI18n";
import { formatRecapProgressPercent } from "@/lib/recap/progressDisplay";
import type { RecapSkuRow } from "@/lib/recap/types";
type Props = {
@@ -8,7 +9,7 @@ type Props = {
};
export default function RecapProductionBySku({ rows }: Props) {
const { t } = useI18n();
const { t, locale } = useI18n();
return (
<div className="rounded-2xl border border-white/10 bg-black/40 p-4">
@@ -30,7 +31,8 @@ export default function RecapProductionBySku({ rows }: Props) {
</thead>
<tbody>
{rows.slice(0, 10).map((row) => {
const progress = row.progressPct == null ? "--" : `${Math.round(row.progressPct)}%`;
const progress =
row.progressPct == null ? "—" : formatRecapProgressPercent(row.progressPct, locale);
return (
<tr key={`${row.sku}:${row.machineName}`} className="border-b border-white/5">
<td className="py-2 pr-3">{row.sku}</td>