Skip to content

Commit

Permalink
Refactor/footer (#414)
Browse files Browse the repository at this point in the history
  • Loading branch information
TheGreatRefrigerator authored Apr 9, 2024
2 parents dc8fd1d + a8e3584 commit 33a267d
Show file tree
Hide file tree
Showing 14 changed files with 30 additions and 45 deletions.
34 changes: 12 additions & 22 deletions src/fragments/footer/Footer.vue
Original file line number Diff line number Diff line change
@@ -1,27 +1,17 @@
<template>
<v-footer dark
:style="{'margin-top': $vuetify.breakpoint.smAndDown ? '-' + $store.getters.footerMiniHeight + 'px': '-' + $store.getters.footerFullHeight + 'px'}"
:height="$vuetify.breakpoint.smAndDown? $store.getters.footerMiniHeight : $store.getters.footerFullHeight" :class="{'small': $vuetify.breakpoint.smAndDown}">
<p>
<strong>
<a target="_blank" href="https://github.com/GIScience/ors-map-client">v{{ appVersion }}</a>
</strong>
<span>&nbsp;© {{currentYear}} <strong>{{footerMainSiteName}}</strong></span>
<span > | {{ $t('global.developedByIntro') }}
<strong>
<a target="_blank" :title="$t('global.developedBy')" :href="footerLink">{{ $t('global.developedBy') }}</a>
</strong>
</span><br>
<span>
<strong>
<a class="link" :title="$t('about.privacyPolicy')" :href="constants.links.privacyPolicy" target="_blank">{{$t('about.privacyPolicy')}}</a>
</strong>
&nbsp; &nbsp;
<strong>
<a class="link" :title="$t('about.termsOfService')" :href="constants.links.termsOfService" target="_blank">{{$t('about.termsOfService')}}</a>
</strong>
</span>
</p>
:style="{'margin-top':'-' + $store.getters.footerHeight + 'px'}"
:height="$store.getters.footerHeight">
<v-layout justify-center column wrap >
<span><a :style="linkColor" target="_blank" href="https://github.com/GIScience/ors-map-client">v{{ appVersion }}</a>&nbsp;|&nbsp;© {{currentYear}} <strong>{{footerMainSiteName}}</strong></span>
<div>{{ $t('global.developedByIntro') }}
<a :style="linkColor" target="_blank" :title="$t('global.developedBy')" :href="footerLink">{{ $t('global.developedBy') }}</a>
</div><br>
<a :style="linkColor" class="link" :title="$t('about.privacyPolicy')" :href="constants.links.privacyPolicy"
target="_blank">{{ $t('about.privacyPolicy') }}</a>
<v-spacer shrink></v-spacer>
<a :style="linkColor" class="link" :title="$t('about.termsOfService')" :href="constants.links.termsOfService" target="_blank">{{$t('about.termsOfService')}}</a>
</v-layout>
</v-footer>
</template>

Expand Down
7 changes: 1 addition & 6 deletions src/fragments/footer/footer.css
Original file line number Diff line number Diff line change
@@ -1,14 +1,9 @@

footer {
text-align: center;
padding-top: 25px;
padding-bottom: 25px;
padding: 5px;
}

footer.small {
padding-top: 10px;
padding-bottom: 10px;
}
footer p{
color: #cbcbcb;
margin: auto;
Expand Down
4 changes: 4 additions & 0 deletions src/fragments/footer/footer.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import appConfig from '@/config/app-config'
import theme from '@/config/theme'
export default {
data () {
return {
Expand All @@ -10,6 +11,9 @@ export default {
currentYear () {
return (new Date()).getFullYear()
},
linkColor () {
return 'color: ' + theme.primary + ';'
},
appVersion () {
let env = process.env
let version = env.PACKAGE_JSON.version
Expand Down
2 changes: 1 addition & 1 deletion src/fragments/sidebar/Sidebar.vue
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@

<!-- sidebar-content padding-bottom must be the same that is calculated in footer component height -->
<div class="sidebar-content" :style="{height: sidebarContentHeightFormula}">
<div class="sidebar-content-form" :style="{'padding-bottom': $vuetify.breakpoint.smAndDown ? $store.getters.footerMiniHeight + 'px': $store.getters.footerFullHeight + 'px'}">
<div class="sidebar-content-form" :style="{'padding-bottom': $store.getters.footerHeight + 'px'}">
<map-form v-if="$store.getters.mapReady" class="map-search"></map-form>
<v-expansion-panel :value="null" v-if="!$highResolution">
<v-expansion-panel-content style="background: transparent;">
Expand Down
2 changes: 1 addition & 1 deletion src/i18n/translations/cs-cz/global.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ export default {
ok: 'OK',
polygon: 'polygon',
developedByIntro: 'Služby vyvinuté',
developedBy: 'Heidelberským institutem pro geoinformační technologie',
developedBy: 'HeiGIT gGmbH',
duration: 'Trvání',
distance: 'Vzdálenost',
elevation: 'Nadmořská výška',
Expand Down
2 changes: 1 addition & 1 deletion src/i18n/translations/de-de/global.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ export default {
ok: 'Ok',
polygon: 'Polygon',
developedByIntro: 'Services entwickelt von',
developedBy: 'Heidelberg Institute for Geoinformation Technology',
developedBy: 'HeiGIT gGmbH',
duration: 'Dauer',
distance: 'Entfernung',
elevation: 'Höhe',
Expand Down
2 changes: 1 addition & 1 deletion src/i18n/translations/en-us/global.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ export default {
ok: 'OK',
polygon: 'polygon',
developedByIntro: 'Services developed by',
developedBy: 'Heidelberg Institute for Geoinformation Technology',
developedBy: 'HeiGIT gGmbH',
duration: 'Duration',
distance: 'Distance',
elevation: 'Elevation',
Expand Down
2 changes: 1 addition & 1 deletion src/i18n/translations/es-es/global.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ export default {
ok: 'OK',
polygon: 'polígono',
developedByIntro: 'Servicios desarrollados por',
developedBy: 'Instituto de Tecnología de Geoinformación de Heidelberg',
developedBy: 'HeiGIT gGmbH',
duration: 'Duración',
distance: 'Distancia',
elevation: 'Elevación',
Expand Down
2 changes: 1 addition & 1 deletion src/i18n/translations/fr-fr/global.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ export default {
'ok': 'OK',
'polygon': 'polygone',
'developedByIntro': 'Services développés par',
'developedBy': 'Heidelberg Institute for Geoinformation Technology (HeiGIT)',
'developedBy': 'HeiGIT gGmbH',
'duration': 'Durée',
'distance': 'Distance',
'elevation': 'Élévation',
Expand Down
2 changes: 1 addition & 1 deletion src/i18n/translations/hu-hu/global.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ export default {
'ok': 'OK',
'polygon': 'sokszög',
'developedByIntro': 'A szolgáltatások fejlesztője',
'developedBy': 'a Heidelbergi Geoinformációs Technológiai Intézet',
'developedBy': 'HeiGIT gGmbH',
'duration': 'Időtartam',
'distance': 'Távolság',
'elevation': 'Magasság',
Expand Down
2 changes: 1 addition & 1 deletion src/i18n/translations/it-it/global.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ export default {
'ok': 'OK',
'polygon': 'poligono',
'developedByIntro': 'Servizio sviluppato dall',
'developedBy': 'Heidelberg Institute for Geoinformation Technology',
'developedBy': 'HeiGIT gGmbH',
'duration': 'Durata',
'distance': 'Distanza',
'elevation': 'Altitudine',
Expand Down
2 changes: 1 addition & 1 deletion src/i18n/translations/pt-br/global.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ export default {
ok: 'OK',
polygon: 'polígono',
developedByIntro: 'Serviços desenvolvidos por',
developedBy: 'Heidelberg Institute for Geoinformation Technology',
developedBy: 'HeiGIT gGmbH',
duration: 'Duração',
distance: 'Distância',
elevation: 'Elevação',
Expand Down
2 changes: 1 addition & 1 deletion src/i18n/translations/ro-ro/global.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ export default {
'ok': 'OK',
'polygon': 'poligon',
'developedByIntro': 'Servicii dezvoltate de',
'developedBy': 'Institutul Heidelberg pentru tehnologia geoinformațiilor',
'developedBy': 'HeiGIT gGmbH',
'duration': 'Durată',
'distance': 'Distanță',
'elevation': 'Elevație',
Expand Down
10 changes: 3 additions & 7 deletions src/store/modules/app-ui.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,7 @@ const state = {
pickPlaceIndex: null,
pickPlaceId: null,
mainMenu: [],
footerFullHeight: 89,
footerMiniHeight: 140,
footerHeight: 89,
sidebarFullWidth: 400,
sidebarShrunkWidth: 290,
sidebarHeaderHeight: 175,
Expand All @@ -28,11 +27,8 @@ const getters = {
mainMenu: state => {
return state.mainMenu
},
footerFullHeight: state => {
return state.footerFullHeight
},
footerMiniHeight: state => {
return state.footerMiniHeight
footerHeight: state => {
return state.footerHeight
},
sidebarHeaderHeight: state => {
return state.sidebarHeaderHeight
Expand Down

0 comments on commit 33a267d

Please sign in to comment.