- Added title and meta info to current views
This commit is contained in:
@@ -9,7 +9,10 @@
|
|||||||
|
|
||||||
<script>
|
<script>
|
||||||
export default {
|
export default {
|
||||||
name: 'app'
|
name: 'app',
|
||||||
|
metaInfo: {
|
||||||
|
title: 'Auracle',
|
||||||
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|||||||
@@ -2,6 +2,12 @@
|
|||||||
import Vue from 'vue'
|
import Vue from 'vue'
|
||||||
import VueRouter from 'vue-router'
|
import VueRouter from 'vue-router'
|
||||||
import App from './app.vue'
|
import App from './app.vue'
|
||||||
|
import VueMeta from 'vue-meta'
|
||||||
|
|
||||||
|
Vue.use(VueMeta, {
|
||||||
|
// optional pluginOptions
|
||||||
|
refreshOnceOnNavigation: true
|
||||||
|
})
|
||||||
|
|
||||||
// Environment
|
// Environment
|
||||||
require('dotenv').config()
|
require('dotenv').config()
|
||||||
|
|||||||
@@ -5,9 +5,14 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
export default {
|
|
||||||
name: 'schools-page'
|
export default {
|
||||||
}
|
name: 'schools-page',
|
||||||
|
metaInfo: {
|
||||||
|
titleTemplate: '%s - Maîtrises'
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style>
|
<style>
|
||||||
|
|||||||
@@ -1,9 +1,9 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="container-fluid p-4" id="spell-container">
|
<div class="container-fluid p-4" id="spell-container">
|
||||||
<h1 class="display-3 font-display mb-3">{{ school.name }}</h1>
|
<h1 class="display-3 font-display mb-3">{{ school.name }}</h1>
|
||||||
<p>{{ school.description }}</p>
|
<p>{{ school.description }}</p>
|
||||||
<spell-list :school_id="id"/>
|
<spell-list :school_id="id"/>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
@@ -14,32 +14,35 @@ import { RepositoryFactory } from "~/api/repositories"
|
|||||||
const Schools = RepositoryFactory.get('schools')
|
const Schools = RepositoryFactory.get('schools')
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'single-school-page',
|
name: 'single-school-page',
|
||||||
components: {
|
metaInfo: {
|
||||||
'spell-list': SpellsList,
|
titleTemplate: '%s - Maîtrise I'
|
||||||
},
|
},
|
||||||
data() {
|
components: {
|
||||||
return {
|
'spell-list': SpellsList,
|
||||||
loading: false,
|
},
|
||||||
school: {},
|
data() {
|
||||||
id: this.$route.params.id
|
return {
|
||||||
}
|
loading: false,
|
||||||
},
|
school: {},
|
||||||
created() {
|
id: this.$route.params.id
|
||||||
this.computeSchool()
|
|
||||||
},
|
|
||||||
methods: {
|
|
||||||
async fetchSchool(id) {
|
|
||||||
const { data } = await Schools.getOne(id)
|
|
||||||
return data
|
|
||||||
},
|
|
||||||
async computeSchool() {
|
|
||||||
this.loading = true
|
|
||||||
const displaySchool = await this.fetchSchool(this.id)
|
|
||||||
this.loading = false
|
|
||||||
this.school = displaySchool
|
|
||||||
},
|
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
created() {
|
||||||
|
this.computeSchool();
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
async fetchSchool(id) {
|
||||||
|
const { data } = await Schools.getOne(id);
|
||||||
|
return data;
|
||||||
|
},
|
||||||
|
async computeSchool() {
|
||||||
|
this.loading = true;
|
||||||
|
const displaySchool = await this.fetchSchool(this.id);
|
||||||
|
this.loading = false;
|
||||||
|
this.school = displaySchool;
|
||||||
|
},
|
||||||
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|||||||
@@ -1,12 +1,15 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="container-fluid p-4" id="spell-container">
|
<div class="container-fluid p-4" id="spell-container">
|
||||||
<h1 class="display-3 font-display mb-3">Sortilège</h1>
|
<h1 class="display-3 font-display mb-3">Sortilège I</h1>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
export default {
|
export default {
|
||||||
|
name: 'single-spell-page',
|
||||||
|
metaInfo: {
|
||||||
|
titleTemplate: '%s - Sortilège I'
|
||||||
|
},
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|||||||
@@ -1,8 +1,8 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="container-fluid p-4" id="spell-container">
|
<div class="container-fluid p-4" id="spell-container">
|
||||||
<h1 class="display-3 font-display mb-3">Sortilèges</h1>
|
<h1 class="display-3 font-display mb-3">Sortilèges</h1>
|
||||||
<spell-list/>
|
<spell-list/>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
@@ -10,6 +10,9 @@ import SpellsList from "~/components/spells/spells-list"
|
|||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'spells-page',
|
name: 'spells-page',
|
||||||
|
metaInfo: {
|
||||||
|
titleTemplate: '%s - Grimoire'
|
||||||
|
},
|
||||||
components: {
|
components: {
|
||||||
'spell-list': SpellsList,
|
'spell-list': SpellsList,
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -6,7 +6,10 @@
|
|||||||
|
|
||||||
<script>
|
<script>
|
||||||
export default {
|
export default {
|
||||||
name: 'timeline-page',
|
name: 'timeline-page',
|
||||||
|
metaInfo: {
|
||||||
|
titleTemplate: '%s - Âges'
|
||||||
|
},
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|||||||
@@ -88,6 +88,9 @@
|
|||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'login-page',
|
name: 'login-page',
|
||||||
|
metaInfo: {
|
||||||
|
titleTemplate: '%s - Connexion'
|
||||||
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
email: "",
|
email: "",
|
||||||
|
|||||||
@@ -6,12 +6,6 @@
|
|||||||
>
|
>
|
||||||
<h2 class="display-3 font-display mb-3">
|
<h2 class="display-3 font-display mb-3">
|
||||||
<span class="username">{{ user.name }}</span>
|
<span class="username">{{ user.name }}</span>
|
||||||
<span
|
|
||||||
v-if="user.verified"
|
|
||||||
class="verified"
|
|
||||||
>
|
|
||||||
<i class="mad">check_circle</i>
|
|
||||||
</span>
|
|
||||||
</h2>
|
</h2>
|
||||||
<span>Membre depuis le {{ registered_date }}</span>
|
<span>Membre depuis le {{ registered_date }}</span>
|
||||||
|
|
||||||
@@ -41,6 +35,9 @@ export default {
|
|||||||
|
|
||||||
return new Intl.DateTimeFormat("fr", date_options).format(raw_date);
|
return new Intl.DateTimeFormat("fr", date_options).format(raw_date);
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
metaInfo: {
|
||||||
|
titleTemplate: '%s - Profil'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@@ -118,6 +118,9 @@
|
|||||||
<script>
|
<script>
|
||||||
export default {
|
export default {
|
||||||
name: 'register-page',
|
name: 'register-page',
|
||||||
|
metaInfo: {
|
||||||
|
titleTemplate: '%s - Inscription'
|
||||||
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
name: "",
|
name: "",
|
||||||
|
|||||||
Reference in New Issue
Block a user