generic reusable header
This commit is contained in:
parent
86a20f2982
commit
4b6b5f339f
3 changed files with 27 additions and 14 deletions
16
frontend/src/components/Header.vue
Normal file
16
frontend/src/components/Header.vue
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
<template>
|
||||||
|
<v-flex mb-4>
|
||||||
|
<h1 class="display-2 font-weight-bold mb-3">
|
||||||
|
Hello World!
|
||||||
|
</h1>
|
||||||
|
<p class="subheading font-weight-regular">
|
||||||
|
App under development, please don't submit any valuable data!
|
||||||
|
</p>
|
||||||
|
</v-flex>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
export default {
|
||||||
|
name: "Header"
|
||||||
|
}
|
||||||
|
</script>
|
|
@ -1,11 +1,7 @@
|
||||||
<template>
|
<template>
|
||||||
<v-container>
|
<v-container>
|
||||||
<v-flex mb-4>
|
<Header />
|
||||||
<h1 class="display-2 font-weight-bold mb-3">Hello World!</h1>
|
|
||||||
<p class="subheading font-weight-regular">
|
|
||||||
App under development, please don't submit any valuable data!
|
|
||||||
</p>
|
|
||||||
</v-flex>
|
|
||||||
<p>user session: {{ sessionID }}</p>
|
<p>user session: {{ sessionID }}</p>
|
||||||
<v-btn @click.native="logout">Logout</v-btn>
|
<v-btn @click.native="logout">Logout</v-btn>
|
||||||
</v-container>
|
</v-container>
|
||||||
|
@ -15,9 +11,15 @@
|
||||||
import * as Cookies from 'js-cookie'
|
import * as Cookies from 'js-cookie'
|
||||||
import axios from '@/plugins/axios'
|
import axios from '@/plugins/axios'
|
||||||
|
|
||||||
|
import Header from '@/components/Header.vue'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'About',
|
name: 'About',
|
||||||
|
|
||||||
|
components: {
|
||||||
|
Header
|
||||||
|
},
|
||||||
|
|
||||||
data: () => ({
|
data: () => ({
|
||||||
sessionID: ''
|
sessionID: ''
|
||||||
}),
|
}),
|
||||||
|
|
|
@ -1,13 +1,6 @@
|
||||||
<template>
|
<template>
|
||||||
<v-container>
|
<v-container>
|
||||||
<v-flex mb-4>
|
<Header />
|
||||||
<h1 class="display-2 font-weight-bold mb-3">
|
|
||||||
Hello World!
|
|
||||||
</h1>
|
|
||||||
<p class="subheading font-weight-regular">
|
|
||||||
App under development, please don't submit any valuable data!
|
|
||||||
</p>
|
|
||||||
</v-flex>
|
|
||||||
|
|
||||||
<LoginForm />
|
<LoginForm />
|
||||||
<RegisterForm />
|
<RegisterForm />
|
||||||
|
@ -18,6 +11,7 @@
|
||||||
import * as Cookies from 'js-cookie'
|
import * as Cookies from 'js-cookie'
|
||||||
import axios from '@/plugins/axios'
|
import axios from '@/plugins/axios'
|
||||||
|
|
||||||
|
import Header from '@/components/Header.vue'
|
||||||
import LoginForm from '@/components/forms/Login.vue'
|
import LoginForm from '@/components/forms/Login.vue'
|
||||||
import RegisterForm from '@/components/forms/Register.vue'
|
import RegisterForm from '@/components/forms/Register.vue'
|
||||||
|
|
||||||
|
@ -31,6 +25,7 @@ export default {
|
||||||
},
|
},
|
||||||
|
|
||||||
components: {
|
components: {
|
||||||
|
Header,
|
||||||
LoginForm,
|
LoginForm,
|
||||||
RegisterForm
|
RegisterForm
|
||||||
},
|
},
|
||||||
|
|
Reference in a new issue