chore: added icons to storage items

This commit is contained in:
2025-05-02 17:56:02 +02:00
parent 35ded92a64
commit 4a96ed3852
3 changed files with 20 additions and 4 deletions
@@ -27,9 +27,23 @@
class="bg-zinc-900 p-2 w-full cursor-pointer hover:bg-zinc-800 text-left" class="bg-zinc-900 p-2 w-full cursor-pointer hover:bg-zinc-800 text-left"
@click="selectTimetable(timetable)" @click="selectTimetable(timetable)"
> >
<div class="text-zinc-300"> <div class="text-zinc-300 flex gap-x-2 items-center flex-wrap">
#{{ timetable.timetableId }} &bull; <span>#{{ timetable.timetableId }}</span>
{{ new Date(timetable.savedTimestamp!).toLocaleString() }}
<i class="flex items-center gap-1"><ArchiveIcon :size="18" :stroke-width="3" /> {{ new Date(timetable.savedTimestamp!).toLocaleString() }}</i>
<i
v-if="timetable.journalCreatedAt"
class="flex items-center gap-0.5"
:title="
$t('storage-journal-timetable-placeholder', {
date: new Date(timetable.journalCreatedAt).toLocaleDateString('pl-PL')
})
"
>
<HistoryIcon :size="18" :stroke-width="3" />
{{ new Date(timetable.journalCreatedAt).toLocaleDateString('pl-PL') }}
</i>
</div> </div>
<b>{{ timetable.driverName }} | {{ timetable.category }} {{ timetable.trainNo }}</b> <b>{{ timetable.driverName }} | {{ timetable.category }} {{ timetable.trainNo }}</b>
{{ timetable.route.replace('|', ' > ') }} {{ timetable.route.replace('|', ' > ') }}
@@ -51,7 +65,7 @@ import { computed } from 'vue';
import { useI18n } from 'vue-i18n'; import { useI18n } from 'vue-i18n';
import { useGlobalStore } from '../../stores/global.store'; import { useGlobalStore } from '../../stores/global.store';
import type { TimetableData } from '../../types/common.types'; import type { TimetableData } from '../../types/common.types';
import { ArchiveIcon, Trash2Icon } from 'lucide-vue-next'; import { ArchiveIcon, HistoryIcon, Trash2Icon } from 'lucide-vue-next';
const globalStore = useGlobalStore(); const globalStore = useGlobalStore();
const i18n = useI18n(); const i18n = useI18n();
+1
View File
@@ -32,6 +32,7 @@
"storage-preview-empty": "No entries found for given parameters", "storage-preview-empty": "No entries found for given parameters",
"storage-preview-info": "Archived timetable {id} for user {driverName} from: {date}", "storage-preview-info": "Archived timetable {id} for user {driverName} from: {date}",
"storage-preview-button-text": "Return", "storage-preview-button-text": "Return",
"storage-journal-timetable-placeholder": "Saved historical timetable from day {date}",
"delete-timetable-confirm": "Are you sure that you want to delete this timetable?", "delete-timetable-confirm": "Are you sure that you want to delete this timetable?",
"journal-preview-title": "TIMETABLES JOURNAL", "journal-preview-title": "TIMETABLES JOURNAL",
+1
View File
@@ -32,6 +32,7 @@
"storage-preview-empty": "Nie znaleziono żadnych wpisów dla podanych parametrów", "storage-preview-empty": "Nie znaleziono żadnych wpisów dla podanych parametrów",
"storage-preview-info": "Rozkład archiwalny {id} maszynisty {driverName} z dnia {date}", "storage-preview-info": "Rozkład archiwalny {id} maszynisty {driverName} z dnia {date}",
"storage-preview-button-text": "Powróć", "storage-preview-button-text": "Powróć",
"storage-journal-timetable-placeholder": "Zapisany historyczny rozkład jazdy z dnia {date}",
"delete-timetable-confirm": "Czy na pewno chcesz usunąć ten rozkład jazdy z archiwum?", "delete-timetable-confirm": "Czy na pewno chcesz usunąć ten rozkład jazdy z archiwum?",
"journal-preview-title": "DZIENNIK ROZKŁADÓW JAZDY", "journal-preview-title": "DZIENNIK ROZKŁADÓW JAZDY",