Adjust start page navigation
This commit is contained in:
parent
90f980fe09
commit
ee512dc7c2
|
|
@ -1,14 +1,14 @@
|
|||
<template>
|
||||
<div class="section-block">
|
||||
<div class="section-block" @click="navigate()" :class="{'section-block--navigatable': route}">
|
||||
<div class="section-block__title block-title">
|
||||
<h2 class="block-title__title">{{title}}</h2>
|
||||
<h3 class="block-title__subtitle small-emph">{{subtitle}}</h3>
|
||||
</div>
|
||||
<div class="section-block__content section-content">
|
||||
<div class="section-content__subsection subsection">
|
||||
<router-link :to="route" class="subsection__content small-emph" v-if="route">
|
||||
Alle Inhalte
|
||||
</router-link>
|
||||
<a class="subsection__content small-emph" v-if="route">
|
||||
{{linkText}}
|
||||
</a>
|
||||
<span class="subsection__content subsection__content--disabled" v-if="!route">Noch nicht verfügbar</span>
|
||||
</div>
|
||||
</div>
|
||||
|
|
@ -17,7 +17,14 @@
|
|||
|
||||
<script>
|
||||
export default {
|
||||
props: ['title', 'subtitle', 'route']
|
||||
props: ['title', 'subtitle', 'route', 'link-text'],
|
||||
methods: {
|
||||
navigate() {
|
||||
if (this.route) {
|
||||
this.$router.push(this.route);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
|
|
@ -32,6 +39,10 @@
|
|||
box-shadow: 5px 5px 21px 0px rgba(219, 219, 219, 1);
|
||||
overflow: hidden;
|
||||
|
||||
&--navigatable {
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
&__title {
|
||||
background-color: $color-brand;
|
||||
padding: 20px;
|
||||
|
|
|
|||
|
|
@ -6,18 +6,21 @@
|
|||
class="start-sections__section"
|
||||
title="Inhalte"
|
||||
subtitle="Lernen"
|
||||
link-text="Alle Inhalte anzeigen"
|
||||
route="/book/topic/geld-und-kauf"
|
||||
></section-block>
|
||||
<section-block
|
||||
class="start-sections__section"
|
||||
title="Räume"
|
||||
subtitle="Zusammenarbeiten"
|
||||
link-text="Alle Räume anzeigen"
|
||||
route="/rooms"
|
||||
></section-block>
|
||||
<section-block
|
||||
class="start-sections__section"
|
||||
title="Portfolio"
|
||||
subtitle="Dokumentation & reflektieren"
|
||||
link-text="Portfolio anzeigen"
|
||||
></section-block>
|
||||
</div>
|
||||
<div class="start-page__news news">
|
||||
|
|
|
|||
Loading…
Reference in New Issue