feat(dashboard): refina experiencia dos widgets

This commit is contained in:
Felipe Coutinho
2026-05-31 15:18:43 -03:00
parent 402f0072af
commit 35abe1b0bf
39 changed files with 887 additions and 592 deletions

View File

@@ -5,7 +5,7 @@ import { capitalize } from "@/shared/utils/string";
type InstallmentExpenseDisplay = {
compactLabel: string | null;
isLast: boolean;
remainingLabel: "Próx." | "Aberto";
remainingLabel: "Próximas" | "Em aberto";
remainingInstallments: number;
remainingAmount: number;
endDate: string | null;
@@ -17,7 +17,7 @@ const buildInstallmentCompactLabel = (
installmentCount: number | null,
) => {
if (currentInstallment && installmentCount) {
return `${currentInstallment} de ${installmentCount}`;
return `Parcela ${currentInstallment} de ${installmentCount}`;
}
return null;
@@ -111,7 +111,7 @@ export const buildInstallmentExpenseDisplay = (
installmentCount,
),
isLast: isInstallmentLast(currentInstallment, installmentCount),
remainingLabel: isSettled === true ? "Próx." : "Aberto",
remainingLabel: isSettled === true ? "Próximas" : "Em aberto",
remainingInstallments: calculateInstallmentRemainingCount(
currentInstallment,
installmentCount,