chore(scenery): changed appearance of the return button

This commit is contained in:
2025-07-02 18:50:11 +02:00
parent bb5fc395d2
commit 4af856b833
6 changed files with 51 additions and 84 deletions
-23
View File
@@ -2,12 +2,6 @@
<div class="scenery-view">
<div class="scenery-wrapper" ref="card-wrapper">
<div class="scenery-left">
<div class="scenery-actions">
<button class="back-btn" :title="$t('scenery.return-btn')" @click="onReturnButtonClick">
<img src="/images/icon-back.svg" alt="return button" />
</button>
</div>
<SceneryHeader
:stationName="station"
:station="stationInfo"
@@ -63,14 +57,11 @@ import SceneryTimetablesHistory from '../components/SceneryView/SceneryTimetable
import SceneryDispatchersHistory from '../components/SceneryView/SceneryDispatchersHistory.vue';
import { useApiStore } from '../store/apiStore';
import { ref } from 'vue';
import { Status } from '../typings/common';
const route = useRoute();
const router = useRouter();
const prevPath = ref('/');
const props = defineProps({
region: {
type: String,
@@ -101,10 +92,6 @@ const viewModes = [
}
];
onMounted(() => {
prevPath.value = (route.meta['prevPath'] as string) ?? '/';
});
const currentMode = computed(() => {
return route.query.view?.toString() ?? 'SceneryTimetable';
});
@@ -139,21 +126,11 @@ function setViewMode(componentName: string) {
}
});
}
function onReturnButtonClick() {
router.push(prevPath.value);
}
</script>
<style lang="scss" scoped>
@use '../styles/responsive';
button.back-btn {
img {
width: 2em;
}
}
.scenery {
&-view {
display: flex;