/
App.vue
49 lines (45 loc) · 1.14 KB
/
App.vue
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
<template>
<v-app id="openpaas">
<template v-if="$auth.ready()">
<v-toolbar clipped-left app fixed color="primary" v-if="$auth.check()">
<v-toolbar-title>
<img id="header-logo" src="@/assets/logo.svg"/>
</v-toolbar-title>
<v-spacer></v-spacer>
<op-user-menu/>
</v-toolbar>
<v-content>
<v-container fluid fill-height pa-0>
<v-layout justify-center align-center>
<router-view/>
</v-layout>
</v-container>
</v-content>
</template>
<template v-else>
<v-progress-circular indeterminate :size="50" color="primary"></v-progress-circular>
</template>
<op-snackbar/>
</v-app>
</template>
<script>
import UserMenu from "@/components/UserMenu.vue";
import Snackbar from "@/components/Snackbar.vue";
export default {
components: {
"op-user-menu": UserMenu,
"op-snackbar": Snackbar
},
created() {
this.$auth.ready(() => {
this.$store.dispatch("session/init");
this.$store.dispatch("user/fetchUser");
});
}
};
</script>
<style lang="stylus">
#header-logo
height: 35px;
width: 150px;
</style>