;
const selectedCheckpoint = ref(
props.station?.generalInfo?.checkpoints?.length == 0
@@ -176,7 +197,7 @@ export default defineComponent({
currentURL,
selectedCheckpoint,
computedScheduledTrains,
- timetableDataStatus,
+ trainsDataStatus,
};
},
@@ -317,11 +338,12 @@ h3 {
&-schedule {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(30px, 1fr));
- font-size: 1.3em;
+ font-size: 1.15em;
@include smallScreen() {
width: 100%;
margin: 0.5em 0;
+ font-size: 1.4em;
}
}
}
@@ -378,7 +400,6 @@ h3 {
.general-info {
.info-number {
color: $accentCol;
-
}
.info-route {
@@ -396,6 +417,8 @@ h3 {
}
.general-status {
+ margin-left: 0.5em;
+
span.arriving {
color: #aaa;
}
@@ -449,6 +472,6 @@ h3 {
.arrival-time.begins,
.departure-time.terminates {
- font-size: 0.75em;
+ font-size: 0.85em;
}
diff --git a/src/components/StationsView/StationTable.vue b/src/components/StationsView/StationTable.vue
index bb50e78..9a03170 100644
--- a/src/components/StationsView/StationTable.vue
+++ b/src/components/StationsView/StationTable.vue
@@ -87,7 +87,7 @@
|
{{ $t(`status.${station.onlineInfo.statusID}`) }}
- {{ station.onlineInfo.statusID == 'online' ? station.onlineInfo.statusTimeString : '' }}
+ {{ station.onlineInfo.statusID == 'online' ? timestampToString(station.onlineInfo.statusTimestamp) : '' }}
@@ -102,7 +102,7 @@
|
{{ 2 > station.onlineInfo.dispatcherExp ? 'L' : station.onlineInfo.dispatcherExp }}
@@ -231,6 +231,8 @@ import { computed, ComputedRef, defineComponent } from '@vue/runtime-core';
import { useStore } from '@/store';
import { GETTERS } from '@/constants/storeConstants';
import Station from '@/scripts/interfaces/Station';
+import { StoreData } from '@/scripts/interfaces/StoreData';
+import dateMixin from '@/mixins/dateMixin';
export default defineComponent({
props: {
@@ -248,7 +250,7 @@ export default defineComponent({
changeSorter: { type: Function, required: true },
},
- mixins: [styleMixin],
+ mixins: [styleMixin, dateMixin],
data: () => ({
likeIcon: require('@/assets/icon-like.svg'),
@@ -275,10 +277,10 @@ export default defineComponent({
setup() {
const store = useStore();
- const dataConnectionStatus: ComputedRef = computed(() => store.getters[GETTERS.dataStatus]);
+ const data: ComputedRef = computed(() => store.getters[GETTERS.allData]);
const isDataLoaded = computed(() => {
- return dataConnectionStatus.value == DataStatus.Loaded;
+ return data.value.sceneryDataStatus == DataStatus.Loaded;
});
return {
diff --git a/src/components/TrainsView/TrainSchedule.vue b/src/components/TrainsView/TrainSchedule.vue
index 6c170d8..bcedd22 100644
--- a/src/components/TrainsView/TrainSchedule.vue
+++ b/src/components/TrainsView/TrainSchedule.vue
@@ -22,51 +22,8 @@
-
-
-
- {{ stop.arrivalTimeString }}
- {{ stop.arrivalRealTimeString }}
- ({{ stop.arrivalDelay > 0 ? '+' : '' }}{{ stop.arrivalDelay }})
-
-
- {{ stop.arrivalTimeString }}
-
-
-
-
- {{ stop.stopTime }} {{ stop.stopType == '' ? 'pt' : stop.stopType }}
-
-
-
-
- {{ stop.departureTimeString }}
- {{ stop.departureRealTimeString }}
-
- ({{ stop.departureDelay > 0 ? '+' : '' }}{{ stop.departureDelay }})
-
-
-
- {{ stop.departureTimeString }}
-
-
-
+
@@ -88,10 +45,13 @@
diff --git a/src/views/StationsView.vue b/src/views/StationsView.vue
index be76659..97ce7ec 100644
--- a/src/views/StationsView.vue
+++ b/src/views/StationsView.vue
@@ -90,18 +90,6 @@ export default defineComponent({
return filterManager.getFilteredStationList(store.getters[GETTERS.stationList]);
});
- const getStatusClass = computed(() => {
- if (data.value.dataConnectionStatus == DataStatus.Loading) return 'loading';
- if (data.value.dataConnectionStatus == DataStatus.Error) return 'error';
- return 'success';
- });
-
- const timetableDataStatusClass = computed(() => {
- if (data.value.timetableDataStatus == DataStatus.Loading) return 'loading';
- if (data.value.timetableDataStatus == DataStatus.Error) return 'error';
- return 'success';
- });
-
const focusedStationInfo = computed(() =>
computedStations.value.find((station) => station.name === focusedStationName)
);
@@ -110,8 +98,6 @@ export default defineComponent({
data,
computedStations,
filterManager,
- getStatusClass,
- timetableDataStatusClass,
focusedStationName,
focusedStationInfo,
};
|