-
Notifications
You must be signed in to change notification settings - Fork 285
Open
Labels
Description
Description 📝
The formatRelativeTime() function in src/shared/utils/dateUtils.js returns hardcoded Spanish strings (e.g., “Hoy”, “Ayer”, “Hace X días”, “Hace X meses”) instead of using the project’s i18n translation system.
Because of this, any UI displaying relative time shows Spanish text to all users, regardless of their selected language. Additionally, locale defaults in the same file are inconsistent (es-ES, en-GB, en).
Link 🔗
N/A
Steps to Reproduce 🔄
- Open the application and switch the language to any non-Spanish locale (e.g., English).
- Navigate to any page displaying relative timestamps (e.g., activity logs, records, or history views).
- Observe the relative time labels.
Screenshots 📸
Expected Behavior 🤔
- Relative time strings should use the i18n system (
$t()or equivalent). - Text should display according to the user’s selected locale.
- Locale handling within
dateUtils.jsshould be consistent.
Actual Behavior 😱
- Relative time always appears in Spanish.
- Strings are hardcoded and cannot be translated.
- Locale usage is inconsistent across functions in the same file.
Environment 🌍
- Vue component / File:
src/shared/utils/dateUtils.js - Git branch: main
- OS: macOS (reproducible on any OS)
- Browser: Any (Chrome, Firefox, Safari)
Additional Information ℹ️
Nil
Reactions are currently unavailable