feat: replace all hardcoded en-US and $ formatting with locale-aware helpers

This commit is contained in:
Your Name
2026-02-17 23:39:31 +02:00
parent fe0b20f247
commit 519bdabe61
7 changed files with 23 additions and 53 deletions

View File

@@ -231,6 +231,7 @@ import AppSelect from '../components/AppSelect.vue'
import AppDatePicker from '../components/AppDatePicker.vue'
import { useEntriesStore, type TimeEntry } from '../stores/entries'
import { useProjectsStore } from '../stores/projects'
import { formatDate } from '../utils/locale'
const entriesStore = useEntriesStore()
const projectsStore = useProjectsStore()
@@ -316,16 +317,6 @@ function formatDuration(seconds: number): string {
return `${minutes}m`
}
// Format date
function formatDate(dateString: string): string {
const date = new Date(dateString)
return date.toLocaleDateString('en-US', {
month: 'short',
day: 'numeric',
year: 'numeric'
})
}
// Apply filters
function applyFilters() {
entriesStore.fetchEntries(startDate.value || undefined, endDate.value || undefined)