mirror of
https://github.com/Spythere/stacjownik.git
synced 2026-05-03 05:18:11 +00:00
chore: entry details backwards comp.
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
<div>
|
||||
<div class="details-actions">
|
||||
<button class="btn--action" @click="toggleExtraInfo">
|
||||
<b>{{ $t('journal.stock-info') }}</b>
|
||||
<b>{{ $t('journal.entry-details') }}</b>
|
||||
<img :src="`/images/icon-arrow-${showExtraInfo ? 'asc' : 'desc'}.svg`" alt="Arrow icon" />
|
||||
</button>
|
||||
|
||||
@@ -16,18 +16,18 @@
|
||||
</router-link>
|
||||
</div>
|
||||
|
||||
<div class="details-body" v-if="timetable.stockString && timetable.stockMass && showExtraInfo">
|
||||
<div class="details-body" v-if="showExtraInfo">
|
||||
<hr />
|
||||
<EntryStops :timetable="timetable" />
|
||||
|
||||
<div class="stock-specs">
|
||||
<div class="stock-specs" v-if="timetable.authorName">
|
||||
<span class="badge">
|
||||
<span>{{ $t('journal.dispatcher-name') }}</span>
|
||||
<span>{{ timetable.authorName }}</span>
|
||||
</span>
|
||||
</div>
|
||||
|
||||
<div class="stock-specs">
|
||||
<div class="stock-specs" v-if="timetable.stockMass && timetable.stockHistory.length > 0">
|
||||
<span class="badge">
|
||||
<span>{{ $t('journal.stock-max-speed') }}</span>
|
||||
<span>{{ timetable.maxSpeed }}km/h</span>
|
||||
@@ -71,14 +71,16 @@
|
||||
</button>
|
||||
</div>
|
||||
|
||||
<StockList
|
||||
:trainStockList="
|
||||
(currentHistoryIndex == 0
|
||||
? timetable.stockString
|
||||
: stockHistory[currentHistoryIndex].stockString
|
||||
).split(';')
|
||||
"
|
||||
/>
|
||||
<div v-if="timetable.stockString">
|
||||
<StockList
|
||||
:trainStockList="
|
||||
(currentHistoryIndex == 0
|
||||
? timetable.stockString
|
||||
: stockHistory[currentHistoryIndex].stockString
|
||||
).split(';')
|
||||
"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div v-if="timetable.twr">TWR: {{ timetable.warningNotes }}</div>
|
||||
|
||||
@@ -124,13 +124,17 @@ export default defineComponent({
|
||||
const [arrival, name, departure] = pathEl.split(',');
|
||||
const sceneryName = name.split(' ').slice(0, -1).join(' ');
|
||||
const sceneryHash = name.split(' ').pop()?.replace('.sc', '') ?? '';
|
||||
const isVisited = this.timetable.visitedSceneries.includes(sceneryHash);
|
||||
|
||||
return {
|
||||
arrival,
|
||||
sceneryName,
|
||||
sceneryHash,
|
||||
departure,
|
||||
isVisited: this.timetable.visitedSceneries?.includes(sceneryHash) ?? false
|
||||
isVisited,
|
||||
isVisitedOffline:
|
||||
!isVisited &&
|
||||
this.timetable.visitedSceneries.includes(`${sceneryName} ${sceneryHash}.sc`)
|
||||
};
|
||||
});
|
||||
},
|
||||
@@ -162,7 +166,7 @@ export default defineComponent({
|
||||
: timetable.checkpointDeparturesScheduled.at(i);
|
||||
|
||||
const stopTime = Number(timetable.checkpointStopTypes.at(i)?.split(',')[0]) || 0;
|
||||
const stopType = timetable.checkpointStopTypes.at(i)?.split(',')[1] || '';
|
||||
const stopType = timetable.checkpointStopTypes.at(i)?.split(',').slice(1).join(',') || 'pt';
|
||||
|
||||
acc.push({
|
||||
stopName,
|
||||
@@ -209,6 +213,10 @@ export default defineComponent({
|
||||
&[data-confirmed='true'] > .stop-name {
|
||||
color: lightgreen;
|
||||
}
|
||||
|
||||
&[data-confirmed='true'] > .stop-date:not([data-preponed='true']):not([data-delayed='true']) {
|
||||
color: lightgreen;
|
||||
}
|
||||
}
|
||||
|
||||
.stop-name {
|
||||
@@ -217,6 +225,8 @@ export default defineComponent({
|
||||
}
|
||||
|
||||
.stop-date {
|
||||
color: #ccc;
|
||||
|
||||
s {
|
||||
color: #aaa;
|
||||
}
|
||||
@@ -226,7 +236,7 @@ export default defineComponent({
|
||||
}
|
||||
|
||||
&[data-preponed='true'] {
|
||||
color: lightgreen;
|
||||
color: mediumspringgreen;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
+2
-1
@@ -456,7 +456,8 @@
|
||||
"minutes": "{value} min | {value} mins",
|
||||
"seconds": "{value} s",
|
||||
|
||||
"stock-info": "DETAILS",
|
||||
"entry-details": "DETAILS",
|
||||
"no-entry-details": "NO DETAILS AVAILABLE",
|
||||
"stock-length": "Length",
|
||||
"stock-mass": "Mass",
|
||||
"stock-max-speed": "Max. speed",
|
||||
|
||||
+3
-2
@@ -394,7 +394,6 @@
|
||||
|
||||
"driver-not-found-header": "Nie znaleziono pociągu! :/",
|
||||
"driver-not-found-desc-1": "Ten pociąg prawdopodobnie zakończył już swój bieg, zmienił numer lub jest offline.",
|
||||
"driver-not-found-desc-1": "Ten pociąg prawdopodobnie zakończył już swój bieg, zmienił numer lub jest offline.",
|
||||
"driver-not-found-desc-2": "Historię rozkładów jazdy możesz przejrzeć w",
|
||||
"driver-not-found-journal": "DZIENNIKU RJ",
|
||||
"driver-not-found-others": "Gracz {driver} jest online jako:",
|
||||
@@ -442,7 +441,9 @@
|
||||
"timetable-abandoned": "PORZUCONY",
|
||||
"timetable-online-button": "RJ ONLINE",
|
||||
|
||||
"stock-info": "SZCZEGÓŁY",
|
||||
"entry-details": "SZCZEGÓŁY",
|
||||
"no-entry-details": "BRAK DOSTĘPNYCH SZCZEGÓŁÓW",
|
||||
|
||||
"stock-length": "Długość",
|
||||
"stock-mass": "Masa",
|
||||
"stock-max-speed": "Prędkość maks.",
|
||||
|
||||
@@ -227,6 +227,10 @@ a.a-button {
|
||||
&:hover {
|
||||
background-color: #424242;
|
||||
}
|
||||
|
||||
&:disabled {
|
||||
opacity: 0.75;
|
||||
}
|
||||
}
|
||||
|
||||
&.btn--option {
|
||||
|
||||
Reference in New Issue
Block a user