Poprawiono animacje rozkładów jazdy.

This commit is contained in:
2020-11-17 15:00:07 +01:00
parent a38d7bd27c
commit 8ec61bef8b
4 changed files with 25 additions and 17 deletions
+5 -11
View File
@@ -21,12 +21,8 @@
</span> </span>
<span class="header-links"> <span class="header-links">
<router-link class="route" active-class="route-active" to="/" exact <router-link class="route" active-class="route-active" to="/" exact>SCENERIE</router-link>/
>SCENERIE</router-link <router-link class="route" active-class="route-active" to="/trains">POCIĄGI</router-link>
>/
<router-link class="route" active-class="route-active" to="/trains"
>POCIĄGI</router-link
>
</span> </span>
</div> </div>
</header> </header>
@@ -43,9 +39,7 @@
<transition name="message-anim" mode="out-in"> <transition name="message-anim" mode="out-in">
<span :key="data.dataConnectionStatus"> <span :key="data.dataConnectionStatus">
<div class="message loading" v-if="data.dataConnectionStatus == 0"> <div class="message loading" v-if="data.dataConnectionStatus == 0">Pobieranie danych...</div>
Pobieranie danych...
</div>
<div class="message error" v-if="data.dataConnectionStatus == 1"> <div class="message error" v-if="data.dataConnectionStatus == 1">
<img :src="ErrorIcon" alt="Error" /> <img :src="ErrorIcon" alt="Error" />
@@ -67,7 +61,6 @@ import Clock from "@/components/App/Clock.vue";
// import stationData from "@/data/stations.json"; // import stationData from "@/data/stations.json";
@Component({ @Component({
components: { Clock }, components: { Clock },
}) })
@@ -91,7 +84,6 @@ export default class App extends Vue {
// console.log("-----"); // console.log("-----");
// }); // });
} }
} }
</script> </script>
@@ -175,6 +167,8 @@ export default class App extends Vue {
font-size: calc(1.1rem + 2.1vw); font-size: calc(1.1rem + 2.1vw);
overflow: hidden;
@include smallScreen() { @include smallScreen() {
font-size: 2.5rem; font-size: 2.5rem;
} }
@@ -37,7 +37,7 @@
>Brak aktywnych rozkładów!</span> >Brak aktywnych rozkładów!</span>
<transition-group name="list-anim"> <transition-group name="list-anim">
<div class="timetable-item" v-for="(scheduledTrain, i) in computedScheduledTrains" :key="i"> <div class="timetable-item" v-for="(scheduledTrain, i) in computedScheduledTrains" :key="i+1">
<span class="timetable-general"> <span class="timetable-general">
<span class="general-info"> <span class="general-info">
<router-link <router-link
@@ -126,6 +126,13 @@ export default class SceneryTimetable extends Vue {
listOpen: boolean = false; listOpen: boolean = false;
selectedOption: string = ""; selectedOption: string = "";
mounted() {
if (!this.stationInfo.checkpoints) return;
if (this.selectedOption == "")
this.selectedOption = this.stationInfo.checkpoints[0].checkpointName;
}
activated() { activated() {
if (!this.stationInfo) return; if (!this.stationInfo) return;
if (!this.stationInfo.checkpoints) return; if (!this.stationInfo.checkpoints) return;
@@ -205,9 +212,15 @@ h3 {
&-leave-active { &-leave-active {
transition: all 250ms ease-out; transition: all 250ms ease-out;
} }
&-enter, &-leave-to /* .list-leave-active below version 2.1.8 */ {
&-enter,
&-leave-to {
opacity: 0; opacity: 0;
transform: scale(0.95); transform: scale(0.9);
}
&-move {
transition: transform 100ms;
} }
} }
@@ -420,7 +433,7 @@ h3 {
} }
span.terminated { span.terminated {
color: red; color: #e00000;
font-weight: bold; font-weight: bold;
} }
} }
+2 -1
View File
@@ -121,7 +121,8 @@
} }
}, },
"default": true, "default": true,
"nonPublic": false "nonPublic": false,
"subStations": ["Grabów Miasto", "Grabów Wieś"]
}, },
{ {
"stationName": "Parzęczewo", "stationName": "Parzęczewo",
+1 -1
View File
@@ -95,12 +95,12 @@ h3 {
display: flex; display: flex;
justify-content: center; justify-content: center;
align-items: flex-start;
font-size: calc(0.5rem + 0.65vw); font-size: calc(0.5rem + 0.65vw);
@include bigScreen() { @include bigScreen() {
font-size: 1.25rem; font-size: 1.25rem;
align-items: flex-start;
} }
@include smallScreen { @include smallScreen {