mirror of
https://github.com/escalante29/WealthySmart.git
synced 2026-07-17 15:28:47 +02:00
Localization sweep: shared es-CR dates module, no more en-US strays
src/lib/dates.ts is the single source for month names and date formatting; the three per-page month arrays are gone (with an off-by-one guard — the shared array is 1-indexed). formatDate and the Analytics chart tooltips now speak es-CR, Analytics headings are Spanish, and the cycle selector says 'Todo el período' (UX-19, FE-17, UX-07). Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
@@ -49,7 +49,7 @@ export default function BillingCycleSelector({ value, onChange }: Props) {
|
||||
<SelectValue />
|
||||
</SelectTrigger>
|
||||
<SelectContent>
|
||||
<SelectItem value="all">All time</SelectItem>
|
||||
<SelectItem value="all">Todo el período</SelectItem>
|
||||
{cycles.map((c) => (
|
||||
<SelectItem key={`${c.year}-${c.month}`} value={`${c.year}-${c.month}`}>
|
||||
{c.label} ({c.count})
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
import ConfirmDialog from '@/components/ConfirmDialog';
|
||||
import { MONTH_NAMES_ES_SHORT as MONTH_NAMES } from '@/lib/dates';
|
||||
import { useState, useRef, useEffect } from 'react';
|
||||
import { Pencil } from 'lucide-react';
|
||||
|
||||
@@ -15,10 +16,6 @@ import {
|
||||
TableRow,
|
||||
} from '@/components/ui/table';
|
||||
|
||||
const MONTH_NAMES = [
|
||||
'', 'Ene', 'Feb', 'Mar', 'Abr', 'May', 'Jun',
|
||||
'Jul', 'Ago', 'Sep', 'Oct', 'Nov', 'Dic',
|
||||
];
|
||||
|
||||
const FRESH_START_YEAR = 2026;
|
||||
const FRESH_START_MONTH = 3;
|
||||
|
||||
Reference in New Issue
Block a user