Blame view

src/App.vue 2.87 KB
93a68cfa1   Jatinder Singh   first commit
1
  <template>
c1fd43e24   Jatinder Singh   changes
2

93a68cfa1   Jatinder Singh   first commit
3
4
5
6
    <div id="appRoot">
      <template v-if="!$route.meta.public">
        <v-app id="inspire" class="app">
          <app-drawer class="app--drawer"></app-drawer>
c1fd43e24   Jatinder Singh   changes
7
8
          <app-toolbar class="app--toolbar">
        </app-toolbar>
93a68cfa1   Jatinder Singh   first commit
9
10
11
12
13
14
15
16
17
18
19
20
21
22
          <v-content>
            <!-- Page Header -->
            <page-header v-if="$route.meta.breadcrumb"></page-header>
            <div class="page-wrapper">
              <router-view></router-view>
            </div>   
             <!-- App Footer -->
            <v-footer height="auto" class="grey darken-2 pa-3 app--footer" fixed>
             <!-- <span class="caption">isocked.com Design &copy; {{ new Date().getFullYear() }}</span>
              <v-spacer></v-spacer>
              <span class="caption mr-1"> Make With Love </span> <v-icon color="pink" small>favorite</v-icon>-->
            </v-footer>
          </v-content>
          <!-- Go to top -->
a259e694f   Jatinder Singh   minor change
23
          <app-fab></app-fab>
93a68cfa1   Jatinder Singh   first commit
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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
          <!-- theme setting -->
          <!-- <v-btn small fab dark falt fixed top="top" right="right" class="setting-fab" color="red" @click="openThemeSettings">
            <v-icon>settings</v-icon>
          </v-btn> -->
          <v-navigation-drawer
            class="setting-drawer"
            temporary
            right
            v-model="rightDrawer"
            hide-overlay
            fixed
            >
            <theme-settings></theme-settings>
          </v-navigation-drawer>        
        </v-app>
      </template>
      <template v-else>
        <transition>
          <keep-alive>
            <router-view></router-view>
          </keep-alive>
        </transition>
      </template>
      <v-snackbar
        :timeout="3000"
        bottom
        right
        :color="snackbar.color"
        v-model="snackbar.show"
      >
        {{ snackbar.text }}
        <v-btn dark flat @click.native="snackbar.show = false" icon> 
          <v-icon>close</v-icon>
        </v-btn>
      </v-snackbar>    
    </div>
  </template>
  <script>
  import AppDrawer from '@/components/AppDrawer';
  import AppToolbar from '@/components/AppToolbar';
  import AppFab from '@/components/AppFab';
  import PageHeader from '@/components/PageHeader';
  import menu from '@/api/menu';
  import ThemeSettings from '@/components/ThemeSettings';
  import AppEvents from  './event';
  export default {
    components: {
      AppDrawer,
      AppToolbar,
      AppFab,
      PageHeader,
      ThemeSettings
    },
    data: () => ({
      expanded: true,
      rightDrawer: false,
      snackbar: {
        show: false,
        text: '',
        color: '',
      }
    }),
  
    computed: {
  
    },
  
    created () {
      AppEvents.forEach(item => {
        this.$on(item.name, item.callback);
      });
      window.getApp = this;
    },
    methods: {
      openThemeSettings () {
        this.$vuetify.goTo(0);
        this.rightDrawer = (!this.rightDrawer);
      }
    },
  
  };
  </script>
  
  
  <style lang="stylus" scoped>
    .setting-fab 
      top:50%!important; 
      right:0;
      border-radius:0  
    .page-wrapper
      min-height:calc(100vh - 64px - 50px - 81px );  
  
  </style>