chore: style improvements & finishing touches

This commit is contained in:
2024-08-21 21:33:46 +02:00
parent a80144cb1c
commit 7ad17fc2c5
6 changed files with 43 additions and 26 deletions
-1
View File
@@ -43,7 +43,6 @@ export default defineComponent({
width: 6em;
height: 1em;
margin: 0.5em 0;
.bar-fg,
.bar-bg {
@@ -657,10 +657,6 @@ h3.section-header {
}
@include smallScreen {
.card_controls > button.card-button > p {
display: none;
}
.slider {
flex-wrap: wrap;
justify-content: center;
+16 -12
View File
@@ -107,18 +107,6 @@ s {
flex-wrap: wrap;
align-items: center;
&[data-minor='true'] {
.date {
display: none;
}
.name {
background: none;
color: #aaa;
padding: 0;
}
}
.name {
background: $stopNameClr;
border-radius: 0.5em 0 0 0.5em;
@@ -141,6 +129,18 @@ s {
}
}
&[data-minor='true'] {
.date {
display: none;
}
.name {
background: none;
color: #aaa;
padding: 0;
}
}
.stop {
&[data-stop-types='ph'],
&[data-stop-types='ph-pm'],
@@ -156,6 +156,10 @@ s {
}
}
.stop-label > a {
z-index: 0;
}
.stop .arrival {
&[data-status='confirmed'][data-status-delayed='true'] {
span {
+11 -6
View File
@@ -76,21 +76,22 @@
<ProgressBar :progressPercent="confirmedPercentage(train.timetableData.followingStops)" />
<span class="progress-distance">
&nbsp; {{ currentDistance(train.timetableData.followingStops) }} km /
<span class="text--primary"> {{ train.timetableData.routeDistance }} km </span>
|
<span>{{ currentDistance(train.timetableData.followingStops) }} km</span>
<span>/</span>
<span class="text--primary">{{ train.timetableData.routeDistance }} km </span>
<span>|</span>
<span v-html="currentDelay(train.timetableData.followingStops)"></span>
</span>
</div>
<div class="status-badges">
<div v-if="!train.currentStationHash" class="train-badge offline">
<img src="/images/icon-offline.svg" alt="" />
<img src="/images/icon-offline.svg" alt="offline train icon" />
{{ $t('trains.scenery-offline') }}
</div>
<div v-if="!train.online" class="train-badge offline">
<img src="/images/icon-offline.svg" alt="" />
<img src="/images/icon-offline.svg" alt="offline train icon" />
Offline {{ lastSeenMessage(train.lastSeen) }}
</div>
</div>
@@ -335,10 +336,14 @@ export default defineComponent({
display: flex;
align-items: center;
flex-wrap: wrap;
gap: 0.5em;
padding: 0.5em 0;
}
.progress-distance {
margin-right: 0.25em;
display: flex;
flex-wrap: wrap;
gap: 0.25em;
}
.timetable-warnings {
+4
View File
@@ -78,6 +78,10 @@
}
.train-badge {
display: flex;
align-items: center;
gap: 0.3em;
padding: 0.1em 0.3em;
border-radius: 0.2em;
font-weight: bold;
+12 -3
View File
@@ -5,11 +5,11 @@
<div class="actions">
<router-link to="/" class="a-button btn--image">
<img src="/images/icon-back.svg" alt="train icon" />
{{ $t('trains.driver-return-link') }}
<span>{{ $t('trains.driver-return-link') }}</span>
</router-link>
<router-link :to="`/journal/timetables?search-driver=`" class="a-button btn--image">
<img src="/images/icon-train.svg" alt="train icon" />
<span>
<span class="hidable">
{{ $t('trains.driver-journal-link') }}
</span>
</router-link>
@@ -17,7 +17,7 @@
<div class="train-card">
<TrainInfo :train="chosenTrain" :extended="true" ref="trainInfo" />
<TrainSchedule :train="chosenTrain" tabindex="0" />
<TrainSchedule :train="chosenTrain" />
</div>
</div>
@@ -60,6 +60,8 @@ const chosenTrain = computed(() => mainStore.trainList.find((train) => train.id
</script>
<style lang="scss" scoped>
@import '../styles/responsive';
$viewBgCol: #1a1a1a;
.driver-view {
@@ -72,6 +74,7 @@ $viewBgCol: #1a1a1a;
display: flex;
align-items: flex-end;
justify-content: space-between;
gap: 0.5em;
}
.actions > a {
@@ -102,4 +105,10 @@ $viewBgCol: #1a1a1a;
text-decoration: underline;
}
}
@include smallScreen {
.actions > a > span.hidable {
display: none;
}
}
</style>