Aktualizacja tłumaczeń EN

This commit is contained in:
2021-03-07 02:08:59 +01:00
parent dc22e82c84
commit 2c60428599
15 changed files with 139 additions and 105 deletions
+1 -1
View File
@@ -80,7 +80,7 @@ export default class App extends Vue {
@Action("synchronizeData") synchronizeData; @Action("synchronizeData") synchronizeData;
@Getter("getAllData") data; @Getter("getAllData") data;
private VERSION = "1.4.1"; private VERSION = "1.4.2";
hasReleaseNotes = false; hasReleaseNotes = false;
updateModalVisible = false; updateModalVisible = false;
+7 -9
View File
@@ -117,17 +117,15 @@
<span class="name">{{ stationInfo.dispatcherName }}</span> <span class="name">{{ stationInfo.dispatcherName }}</span>
</div> </div>
<span <span class="status-badge" :class="stationInfo.statusID">{{
class="status-badge" $t(`status.${stationInfo.statusID}`)
:class="statusClasses(stationInfo.occupiedTo)" }}</span>
>{{ stationInfo.occupiedTo }}
</span>
</div> </div>
<div class="info-lists"> <div class="info-lists">
<div class="user-list"> <div class="user-list">
<h3 class="user-header"> <h3 class="user-header">
GRACZE ONLINE {{ $t("scenery.users") }}
<img :src="userIcon" alt="icon-user" /> <img :src="userIcon" alt="icon-user" />
</h3> </h3>
@@ -146,13 +144,13 @@
class="user offline" class="user offline"
v-if="!computedStationTrains || computedStationTrains.length == 0" v-if="!computedStationTrains || computedStationTrains.length == 0"
> >
BRAK AKTYWNYCH GRACZY {{ $t("scenery.no-users") }}
</div> </div>
</div> </div>
<div class="spawn-list"> <div class="spawn-list">
<h3 class="spawn-header"> <h3 class="spawn-header">
OTWARTE SPAWNY {{ $t("scenery.spawns") }}
<img :src="spawnIcon" alt="icon-spawn" /> <img :src="spawnIcon" alt="icon-spawn" />
</h3> </h3>
@@ -168,7 +166,7 @@
<span <span
class="spawn none" class="spawn none"
v-if="!stationInfo.spawns || stationInfo.spawns.length == 0" v-if="!stationInfo.spawns || stationInfo.spawns.length == 0"
>BRAK OTWARTYCH SPAWNÓW</span >{{ $t("scenery.no-spawns") }}</span
> >
</div> </div>
</div> </div>
+12 -10
View File
@@ -1,7 +1,7 @@
<template> <template>
<div class="scenery-timetable"> <div class="scenery-timetable">
<h3 class="timetable-header"> <h3 class="timetable-header">
<span>AKTYWNE ROZKŁADY JAZDY</span> <span>{{ $t("scenery.timetables") }}</span>
<a <a
v-if="!timetableOnly" v-if="!timetableOnly"
@@ -37,15 +37,16 @@
</div> </div>
</div> </div>
<span class="timetable-item loading" v-if="dataStatus == 0" <span class="timetable-item loading" v-if="dataStatus == 0">{{
>Ładowanie...</span $t("app.loading")
> }}</span>
<span <span
class="timetable-item empty" class="timetable-item empty"
v-else-if="computedScheduledTrains.length == 0" v-else-if="computedScheduledTrains.length == 0"
>Brak aktywnych rozkładów!</span
> >
{{ $t("scenery.no-timetables") }}
</span>
<transition-group name="list-anim"> <transition-group name="list-anim">
<div <div
@@ -66,8 +67,9 @@
<span> <span>
<strong>{{ scheduledTrain.category }}</strong> <strong>{{ scheduledTrain.category }}</strong>
{{ scheduledTrain.trainNo }} {{ scheduledTrain.trainNo }}
</span> </router-link </span>
>| </router-link>
|
<span> <span>
<a <a
:href=" :href="
@@ -87,9 +89,9 @@
</span> </span>
<span class="general-status"> <span class="general-status">
<span :class="scheduledTrain.stopStatus">{{ <span :class="scheduledTrain.stopStatus"
scheduledTrain.stopLabel >{{ $t(`timetables.${scheduledTrain.stopStatus}`) }}
}}</span> </span>
</span> </span>
</span> </span>
+1 -1
View File
@@ -4,7 +4,7 @@
<!-- <img :src="require('@/assets/icon-exit.svg')" alt="exit icon" /> --> <!-- <img :src="require('@/assets/icon-exit.svg')" alt="exit icon" /> -->
</div> </div>
<div class="card-title flex">FILTRUJ STACJE</div> <div class="card-title flex">{{ $t("filters.title") }}</div>
<div class="card-options"> <div class="card-options">
<div class="option" v-for="(option, i) in inputs.options" :key="i"> <div class="option" v-for="(option, i) in inputs.options" :key="i">
+3 -42
View File
@@ -4,17 +4,6 @@
<table> <table>
<thead> <thead>
<tr> <tr>
<!-- <th v-html="$t('sceneries.station')"></th>
<th v-html="$t('sceneries.min-lvl')"></th>
<th v-html="$t('sceneries.status')"></th>
<th v-html="$t('sceneries.dispatcher')"></th>
<th v-html="$t('sceneries.dispatcher-lvl')"></th>
<th v-html="$t('sceneries.routes')"></th>
<th v-html="$t('sceneries.general')"></th>
<th v-html="$t('sceneries.drivers-online')"></th>
<th v-html="$t('sceneries.spawns')"></th>
<th v-html="$t('sceneries.timetables')"></th> -->
<th <th
v-for="(id, i) in headIds" v-for="(id, i) in headIds"
:key="id" :key="id"
@@ -52,32 +41,6 @@
/> />
</span> </span>
</th> </th>
<!-- <th
v-for="(head, i) in headTitles"
:key="i"
@click="() => changeSorter(i)"
>
<span class="header_wrapper">
<div class="header_item">
<div v-if="head[0].includes('.svg')">
<img :src="head[0]" alt="test" :title="head[1]" />
</div>
<div v-else>
<div>{{ head[0] }}</div>
<div v-if="head.length > 1">{{ head[1] }}</div>
</div>
</div>
<img
class="sort-icon"
v-if="sorterActive.index == i"
:src="sorterActive.dir == 1 ? ascIcon : descIcon"
alt
/>
</span>
</th> -->
</tr> </tr>
</thead> </thead>
@@ -117,11 +80,9 @@
</td> </td>
<td class="station_status"> <td class="station_status">
<span <span class="status-badge" :class="station.statusID">{{
class="status-badge" $t(`status.${station.statusID}`)
:class="statusClasses(station.occupiedTo)" }}</span>
>{{ station.occupiedTo }}</span
>
</td> </td>
<td class="station_dispatcher-name"> <td class="station_dispatcher-name">
@@ -12,17 +12,6 @@
delayed: stop.departureDelay > 0, delayed: stop.departureDelay > 0,
}" }"
> >
<!-- <div class="progress-bar"></div> -->
<!--
<div
class="stop-line"
v-if="
i > 0 && followingStops[i - 1].departureLine != stop.arrivalLine
"
>
{{ stop.arrivalLine }}
</div> -->
<span class="stop_info"> <span class="stop_info">
<div class="indicator"></div> <div class="indicator"></div>
+3 -3
View File
@@ -1,7 +1,7 @@
<template> <template>
<div class="train-table"> <div class="train-table">
<div class="no-trains" v-if="computedTrains.length == 0"> <div class="no-trains" v-if="computedTrains.length == 0">
Ups! Brak pociągów do wyświetlenia :/ {{ $t("trains.no-trains") }}
</div> </div>
<ul class="train-list"> <ul class="train-list">
@@ -50,7 +50,7 @@
<span>SRJP</span> <span>SRJP</span>
<span class="tooltip-text"> <span class="tooltip-text">
Szczegółowy rozkład jazdy pociągu {{ train.trainNo }} {{ $t("trains.detailed-timetable") }} {{ train.trainNo }}
</span> </span>
</div> </div>
</div> </div>
@@ -65,7 +65,7 @@
<div class="info-stops"> <div class="info-stops">
<span v-if="train.timetableData.followingStops.length > 2"> <span v-if="train.timetableData.followingStops.length > 2">
Przez: {{ $t("trains.via-title") }}
<span <span
v-html=" v-html="
+33 -2
View File
@@ -2,7 +2,18 @@
"app": { "app": {
"sceneries": "SCENERIES", "sceneries": "SCENERIES",
"trains": "TRAINS", "trains": "TRAINS",
"journal": "JOURNAL" "journal": "JOURNAL",
"loading": "Loading data..."
},
"descs": {},
"status": {
"free": "FREE",
"ending": "ENDING",
"not-signed": "NOT SIGNED IN",
"no-limit": "NO LIMIT",
"unavailable": "UNAVAILABLE",
"brb": "AFK",
"no-space": "NO SPACE"
}, },
"options": { "options": {
"filters": "FILTERS", "filters": "FILTERS",
@@ -48,6 +59,7 @@
"timetables": "Active timetables" "timetables": "Active timetables"
}, },
"trains": { "trains": {
"no-trains": "Oops! No trains online!",
"stats": "TRAFFIC STATISTICS", "stats": "TRAFFIC STATISTICS",
"stats-speed": "TRAINS SPEED (MIN | AVG | MAX) [km/h]", "stats-speed": "TRAINS SPEED (MIN | AVG | MAX) [km/h]",
"stats-length": "TIMETABLES LENGTH (MIN | AVG | MAX) [km]", "stats-length": "TIMETABLES LENGTH (MIN | AVG | MAX) [km]",
@@ -62,12 +74,31 @@
"option-timetable": "train no.", "option-timetable": "train no.",
"search-no": "Search for train no...", "search-no": "Search for train no...",
"search-driver": "Search for driver...", "search-driver": "Search for driver...",
"detailed-timetable": "Detailed timetable for train no. " "detailed-timetable": "Detailed timetable for train no. ",
"via-title": "Via: "
}, },
"journal": { "journal": {
"title": "SCENERY ACTIVITY JOURNAL", "title": "SCENERY ACTIVITY JOURNAL",
"subtitle": "Shows all recent dispatchers on a selected scenery", "subtitle": "Shows all recent dispatchers on a selected scenery",
"disclaimer": "<b>This functionality is unfinished!</b> <br> Information shown here could be false or incorrect!", "disclaimer": "<b>This functionality is unfinished!</b> <br> Information shown here could be false or incorrect!",
"select": "Select a scenery" "select": "Select a scenery"
},
"scenery": {
"users": "PLAYERS ONLINE",
"spawns": "OPEN SPAWNS",
"timetables": "ACTIVE TIMETABLES",
"no-timetables": "No active timetables!",
"no-users": "NO ACTIVE PLAYERS",
"no-spawns": "NO OPEN SPAWNS",
"no-scenery": "Oops! This scenery doesn't exist or is offline!",
"return-btn": "Return to main site"
},
"timetables": {
"online": "At station",
"departed": "Dispatched",
"departed-away": "Departed",
"arriving": "En route",
"stopped": "Stopped",
"terminated": "Terminated"
} }
} }
+33 -2
View File
@@ -2,7 +2,18 @@
"app": { "app": {
"sceneries": "SCENERIE", "sceneries": "SCENERIE",
"trains": "POCIĄGI", "trains": "POCIĄGI",
"journal": "DZIENNIK" "journal": "DZIENNIK",
"loading": "Pobieranie danych..."
},
"descs": {},
"status": {
"free": "WOLNA",
"ending": "KOŃCZY",
"not-signed": "NIEZALOGOWANY",
"no-limit": "BEZ LIMITU",
"unavailable": "NIEDOSTĘPNY",
"brb": "Z/W",
"no-space": "BRAK MIEJSCA"
}, },
"options": { "options": {
"filters": "FILTRY", "filters": "FILTRY",
@@ -48,6 +59,7 @@
"timetables": "Aktywne rozkłady jazdy" "timetables": "Aktywne rozkłady jazdy"
}, },
"trains": { "trains": {
"no-trains": "Ups! Brak pociągów online!",
"stats": "STATYSTYKI RUCHU", "stats": "STATYSTYKI RUCHU",
"stats-speed": "PRĘDKOŚCI POCIĄGÓW (MIN | ŚR | MAX) [km/h]", "stats-speed": "PRĘDKOŚCI POCIĄGÓW (MIN | ŚR | MAX) [km/h]",
"stats-length": "DŁUGOŚCI ROZKŁADÓW (MIN | ŚR | MAX) [km]", "stats-length": "DŁUGOŚCI ROZKŁADÓW (MIN | ŚR | MAX) [km]",
@@ -62,12 +74,31 @@
"option-timetable": "numer pociagu", "option-timetable": "numer pociagu",
"search-no": "Szukaj nr pociągu...", "search-no": "Szukaj nr pociągu...",
"search-driver": "Szukaj maszynisty...", "search-driver": "Szukaj maszynisty...",
"detailed-timetable": "Szczegółowy rozkład jazdy pociągu " "detailed-timetable": "Szczegółowy rozkład jazdy pociągu ",
"via-title": "Przez: "
}, },
"journal": { "journal": {
"title": "DZIENNIK AKTYWNOŚCI SCENERII", "title": "DZIENNIK AKTYWNOŚCI SCENERII",
"subtitle": "Pokazuje dyżurnych, którzy ostatnio byli aktywni na wybranej scenerii", "subtitle": "Pokazuje dyżurnych, którzy ostatnio byli aktywni na wybranej scenerii",
"disclaimer": "<b>Ta funkcjonalność jest w testach beta!</b> <br> Informacje pokazywane na ekranie mogą znikać, a ich zawartość może być fałszywa!", "disclaimer": "<b>Ta funkcjonalność jest w testach beta!</b> <br> Informacje pokazywane na ekranie mogą znikać, a ich zawartość może być fałszywa!",
"select": "Wybierz scenerię" "select": "Wybierz scenerię"
},
"scenery": {
"users": "GRACZE ONLINE",
"spawns": "OTWARTE SPAWNY",
"timetables": "AKTYWNE ROZKŁADY JAZDY",
"no-timetables": "Brak aktywnych rozkładów!",
"no-users": "BRAK AKTYWNYCH GRACZY",
"no-spawns": "BRAK OTWARTYCH SPAWNÓW",
"no-scenery": "Ups! Nie znaleziono danej stacji bądź jest ona offline!",
"return-btn": "Wróć na stronę główną"
},
"timetables": {
"online": "Na stacji",
"departed": "Odprawiony",
"departed-away": "Odjechał",
"arriving": "W drodze",
"stopped": "Postój",
"terminated": "Skończył bieg"
} }
} }
+2 -1
View File
@@ -47,8 +47,9 @@ export default interface Station {
stops: string[] | null; stops: string[] | null;
online: boolean; online: boolean;
occupiedTo: string; // occupiedTo: string;
statusTimestamp: number; statusTimestamp: number;
statusID: string;
stationTrains: Train[]; stationTrains: Train[];
scheduledTrains: ScheduledTrain[]; scheduledTrains: ScheduledTrain[];
+1 -1
View File
@@ -36,7 +36,7 @@ export default class StationFilterManager {
.filter(station => { .filter(station => {
if ((station.nonPublic || !station.reqLevel) && this.filters['nonPublic']) return false; if ((station.nonPublic || !station.reqLevel) && this.filters['nonPublic']) return false;
if (station.online && station.occupiedTo == 'KOŃCZY' && this.filters['ending']) return false; if (station.online && station.statusID == 'ending' && this.filters['ending']) return false;
if (station.online && this.filters['occupied']) return false; if (station.online && this.filters['occupied']) return false;
if (!station.online && this.filters['free']) return false; if (!station.online && this.filters['free']) return false;
+33 -4
View File
@@ -39,6 +39,35 @@ const URLs = {
const timetableURL = (trainNo: number) => `https://api.td2.info.pl:9640/?method=readFromSWDR&value=getTimetable%3B${trainNo}%3Beu`; const timetableURL = (trainNo: number) => `https://api.td2.info.pl:9640/?method=readFromSWDR&value=getTimetable%3B${trainNo}%3Beu`;
const getLocoURL = (locoType: string) => `https://rj.td2.info.pl/dist/img/thumbnails/${locoType.includes('EN') ? locoType + 'rb' : locoType}.png`; const getLocoURL = (locoType: string) => `https://rj.td2.info.pl/dist/img/thumbnails/${locoType.includes('EN') ? locoType + 'rb' : locoType}.png`;
const getStatusID = (stationStatus: any) => {
if (!stationStatus) return 'not-signed';
const statusCode = stationStatus[2];
const statusTimestamp = stationStatus[3];
switch (statusCode) {
case 0:
if (statusTimestamp - Date.now() > 21000000) return 'no-limit';
return 'online';
case 1:
return 'brb';
case 2:
if (statusTimestamp == 0) return 'ending';
break;
case 3:
return 'no-space';
default:
break;
}
return 'unavailable';
};
const getStatusLabel = (stationStatus: any) => { const getStatusLabel = (stationStatus: any) => {
if (!stationStatus) return 'NIEZALOGOWANY'; if (!stationStatus) return 'NIEZALOGOWANY';
@@ -265,8 +294,8 @@ export default class Store extends VuexModule {
const stationStatus = onlineDispatchersData.find(status => status[0] == station.stationHash && status[1] == 'eu'); const stationStatus = onlineDispatchersData.find(status => status[0] == station.stationHash && status[1] == 'eu');
const statusLabel = getStatusLabel(stationStatus);
const statusTimestamp = getStatusTimestamp(stationStatus); const statusTimestamp = getStatusTimestamp(stationStatus);
const statusID = getStatusID(stationStatus);
const stationTrains = onlineTrainsData.filter( const stationTrains = onlineTrainsData.filter(
train => train.region === 'eu' && train.isOnline && train.station.stationName === station.stationName train => train.region === 'eu' && train.isOnline && train.station.stationName === station.stationName
@@ -283,9 +312,9 @@ export default class Store extends VuexModule {
dispatcherId: station.dispatcherId, dispatcherId: station.dispatcherId,
dispatcherExp: station.dispatcherExp, dispatcherExp: station.dispatcherExp,
dispatcherIsSupporter: station.dispatcherIsSupporter, dispatcherIsSupporter: station.dispatcherIsSupporter,
occupiedTo: statusLabel,
stationTrains, stationTrains,
statusTimestamp, statusTimestamp,
statusID,
}); });
return acc; return acc;
@@ -398,8 +427,8 @@ export default class Store extends VuexModule {
dispatcherId: 0, dispatcherId: 0,
dispatcherIsSupporter: false, dispatcherIsSupporter: false,
online: false, online: false,
occupiedTo: 'WOLNA',
statusTimestamp: -3, statusTimestamp: -3,
statusID: 'free',
stationTrains: [], stationTrains: [],
scheduledTrains: [], scheduledTrains: [],
spawns: [], spawns: [],
@@ -479,7 +508,7 @@ export default class Store extends VuexModule {
dispatcherId: 0, dispatcherId: 0,
dispatcherIsSupporter: false, dispatcherIsSupporter: false,
online: false, online: false,
occupiedTo: 'WOLNA', statusID: 'free',
statusTimestamp: -3, statusTimestamp: -3,
stationTrains: [], stationTrains: [],
scheduledTrains: [], scheduledTrains: [],
+4 -12
View File
@@ -2,9 +2,9 @@
<div class="history_view"> <div class="history_view">
<div class="history_wrapper"> <div class="history_wrapper">
<div class="header"> <div class="header">
<h2>DZIENNIK AKTYWNOŚCI SCENERII</h2> <h2>{{ $t("journal.title") }}</h2>
<p style="color: #ccc"> <p style="color: #ccc">
Pokazuje dyżurnych, którzy ostatnio byli aktywni na wybranej scenerii {{ $t("journal.subtitle") }}
</p> </p>
<div class="search-box"> <div class="search-box">
@@ -12,9 +12,7 @@
<label :class="{ disabled: dataLoading }"> <label :class="{ disabled: dataLoading }">
<select v-model="inputStationName" :disabled="dataLoading"> <select v-model="inputStationName" :disabled="dataLoading">
<option value disabled selected hidden> <option value disabled selected hidden>
{{ {{ dataLoading ? $t("app.loading") : $t("journal.select") }}
dataLoading ? "Pobieranie danych..." : "Wybierz scenerię"
}}
</option> </option>
<option <option
v-for="station in filteredStationList" v-for="station in filteredStationList"
@@ -28,13 +26,7 @@
</div> </div>
</div> </div>
<div class="disclaimer"> <div class="disclaimer" v-html="$t('journal.disclaimer')"></div>
<h4>Ta funkcjonalność jest w testach beta!</h4>
<p>
Informacje pokazywane na ekranie mogą znikać, a ich zawartość może
być fałszywa!
</p>
</div>
</div> </div>
<div class="list"> <div class="list">
+4 -4
View File
@@ -4,9 +4,9 @@
class="scenery-offline" class="scenery-offline"
v-if="!stationInfo && dataStatus == 2 && currentPath === '/scenery'" v-if="!stationInfo && dataStatus == 2 && currentPath === '/scenery'"
> >
Ups! Nie znaleziono danej stacji bądź jest ona offline! {{ $t("scenery.no-scenery") }}
<button class="button"> <button class="button">
<router-link to="/">Wróć na stronę główną</router-link> <router-link to="/">{{ $t("scenery.return-btn") }}</router-link>
</button> </button>
</div> </div>
@@ -109,9 +109,9 @@ h3 {
&-offline { &-offline {
align-self: center; align-self: center;
font-size: 2em; font-size: 1.5em;
text-align: center; text-align: center;
padding: 0 1em; padding: 2em 1em;
color: $warningCol; color: $warningCol;
+2 -2
View File
@@ -18,11 +18,11 @@
<p>{{ $t("options.filters") }}</p> <p>{{ $t("options.filters") }}</p>
</button> </button>
<button class="action-btn" @click="toggleModal"> <!-- <button class="action-btn" @click="toggleModal">
<img :src="dolarIcon" alt="icon-dolar" /> <img :src="dolarIcon" alt="icon-dolar" />
<p>{{ $t("options.donate") }}</p> <p>{{ $t("options.donate") }}</p>
</button> </button> -->
</div> </div>
<div class="bar_indicators"> <div class="bar_indicators">