+
- {{ $t("app.loading") }}
+ {{ $t('app.loading') }}
-
- {{ $t("scenery.no-timetables") }}
+
+ {{ $t('scenery.no-timetables') }}
@@ -50,45 +33,32 @@
class="timetable-item"
v-for="(scheduledTrain, i) in computedScheduledTrains"
:key="i + 1"
+ tabindex="0"
+ @click="navigateToTrain(scheduledTrain.trainNo)"
+ @keydown="
+ (e) => {
+ if (e.keyCode == 13) navigateToTrain(scheduledTrain.trainNo);
+ }
+ "
>
-
-
- {{ scheduledTrain.category }}
- {{ scheduledTrain.trainNo }}
-
-
- |
- {{ scheduledTrain.driverName }}
+ {{ scheduledTrain.category }}
+ {{ scheduledTrain.trainNo }}
+
+ |
+
+ {{ scheduledTrain.driverName }}
- {{ scheduledTrain.beginsAt }} -
- {{ scheduledTrain.terminatesAt }}
+ {{ scheduledTrain.beginsAt }} - {{ scheduledTrain.terminatesAt }}
- {{ $t(`timetables.${scheduledTrain.stopStatus}`) }}
-
+ {{ $t(`timetables.${scheduledTrain.stopStatus}`) }}
@@ -101,9 +71,7 @@
>
- {{ scheduledTrain.stopInfo.arrivalTimeString }} ({{
- scheduledTrain.stopInfo.arrivalDelay
- }})
+ {{ scheduledTrain.stopInfo.arrivalTimeString }} ({{ scheduledTrain.stopInfo.arrivalDelay }})
@@ -122,9 +90,7 @@
>
- {{ scheduledTrain.stopInfo.departureTimeString }} ({{
- scheduledTrain.stopInfo.departureDelay
- }})
+ {{ scheduledTrain.stopInfo.departureTimeString }} ({{ scheduledTrain.stopInfo.departureDelay }})
@@ -134,14 +100,14 @@
\ No newline at end of file
+
diff --git a/src/components/StationsView/StationTable.vue b/src/components/StationsView/StationTable.vue
index 00b360b..1abdff0 100644
--- a/src/components/StationsView/StationTable.vue
+++ b/src/components/StationsView/StationTable.vue
@@ -38,6 +38,8 @@
v-for="(station, i) in stations"
:key="i + station.name"
@click="() => setScenery(station.name)"
+ @keydown="(e) => { if(e.keyCode == 13) setScenery(station.name) }"
+ tabindex="0"
>
- {{ $t("trains.distance-exceeded") }}
+ {{ $t('trains.distance-exceeded') }}
- {{ $t("trains.no-trains") }}
+ {{ $t('trains.no-trains') }}
-
- {{ $t("trains.loading") }}
+
+ {{ $t('trains.loading') }}
@@ -20,6 +17,12 @@
class="train-row"
v-for="(train, i) in computedTrains"
:key="i"
+ tabindex="0"
+ @keydown="
+ (e) => {
+ if (e.keyCode == 13) changeScheduleShowState(train.timetableData?.timetableId);
+ }
+ "
:ref="
(el) => {
if (!train.timetableData) return;
@@ -27,17 +30,14 @@
}
"
>
-
+
- {{ train.timetableData.route.replace("|", " - ") }}
+ {{ train.timetableData.route.replace('|', ' - ') }}
- {{ $t("trains.via-title") }}
+ {{ $t('trains.via-title') }}
-
+
@@ -103,10 +90,7 @@
-
+
{{ train.driverName }}
@@ -119,54 +103,37 @@
- {{ $t("trains.cars") }}:
+ {{ $t('trains.cars') }}:
{{ train.cars.length }}
{{ displayLocoInfo(train.locoType) }}
-
+
-
- {{
- `${~~(train[stat.name] * (stat.multiplier || 1))}${stat.unit}`
- }}
+
+ {{ `${~~(train[stat.name] * (stat.multiplier || 1))}${stat.unit}` }}
- ![]()
+
- {{ (train[stat.prop] || "---") + (stat.unit || "") }}
+ {{ (train[stat.prop] || '---') + (stat.unit || '') }}
-
+
\ No newline at end of file
+
diff --git a/src/styles/global.scss b/src/styles/global.scss
index e439316..fcaf417 100644
--- a/src/styles/global.scss
+++ b/src/styles/global.scss
@@ -201,18 +201,23 @@ ul {
}
.btn {
+ background: none;
+ cursor: pointer;
+ font-size: 1em;
+
&--text {
- background: none;
color: white;
- font-size: 1em;
-
- cursor: pointer;
-
transition: color 0.3s;
-
&:hover, &:focus {
color: $accentCol;
}
}
+
+ &--image {
+ color: white;
+ transition: color 0.3s;
+
+
+ }
}
\ No newline at end of file
diff --git a/src/views/SceneryHistoryView.vue b/src/views/SceneryHistoryView.vue
deleted file mode 100644
index cb054ec..0000000
--- a/src/views/SceneryHistoryView.vue
+++ /dev/null
@@ -1,388 +0,0 @@
-
-
- Historia rozkładów jazdy
-
-
-
-
-
-
-
- Ładowanie...
-
-
- Wystąpił błąd!
-
-
-
- Brak wyników!
-
-
-
- -
-
-
-
- {{ item.trainCategoryCode }}
- {{ item.trainNo }}
-
-
-
- {{ item.route.replace("|", " - ") }}
-
-
-
- {{ item.sceneriesString.replaceAll("%", " - ") }}
-
-
-
-
- {{
- !item.terminated
- ? "AKTYWNY"
- : item.fulfilled
- ? "WYPEŁNIONY"
- : "NIEWYPEŁNIONY"
- }}
-
-
-
-
-
- Maszynista:
- {{ item.driverName }}
-
-
- Kilometraż:
- {{ !item.fulfilled ? item.currentDistance + " /" : "" }}
- {{ item.routeDistance }} km
-
-
-
- Stacje:
- {{ item.confirmedStopsCount }} /
- {{ item.allStopsCount }}
-
-
-
- Rozpoczęcie:
- {{ localeDate(item.beginDate) }}
-
-
-
- Zakończenie (planowe):
- {{ localeDate(item.scheduledEndDate) }}
-
-
-
- Zakończenie (rzeczywiste):
- {{ localeDate(item.endDate) }}
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/src/views/SceneryView.vue b/src/views/SceneryView.vue
index 3eb3fd7..89a0ae1 100644
--- a/src/views/SceneryView.vue
+++ b/src/views/SceneryView.vue
@@ -12,13 +12,16 @@
+
+
-
@@ -42,6 +45,12 @@ import { useRoute } from "vue-router";
export default defineComponent({
components: { SceneryInfo, SceneryTimetable, SceneryHistory, ActionButton },
+ data: () => ({
+ icons: {
+ history: require("@/assets/icon-history.svg")
+ }
+ }),
+
setup() {
const route = useRoute();
const store = useStore();
@@ -110,6 +119,8 @@ $sceneryBgCol: #333;
}
&-wrapper {
+ position: relative;
+
width: 75%;
max-width: 950px;
@@ -126,4 +137,18 @@ $sceneryBgCol: #333;
text-align: center;
}
}
+
+button.history-btn {
+ position: absolute;
+ top: 0.5em;
+ right: 0.5em;
+
+ padding: 0.25em;
+
+ img {
+ width: 2em;
+ }
+
+
+}
\ No newline at end of file
|