annotate client/src/App.vue @ 553:f41c74b8af9c

fix: Sidebar/Topmenu only visible when logged in Commit 89bc8111563a dealt with restructuring the components, making the Sidebar and the topmenu part of the App-main view. While those menus were rendered as part of the router view, they were only visible, when the according view was called; they were now visible without even login. This is now fixed.
author Thomas Junk <thomas.junk@intevation.de>
date Mon, 03 Sep 2018 09:57:29 +0200
parents 89bc8111563a
children fb5d9d5ff320
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
3
1597506a2241 merge with vue-cli
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
1 <template>
551
89bc8111563a refac: Layout adjustments
Thomas Junk <thomas.junk@intevation.de>
parents: 542
diff changeset
2 <div id="app main d-flex flex-column">
553
f41c74b8af9c fix: Sidebar/Topmenu only visible when logged in
Thomas Junk <thomas.junk@intevation.de>
parents: 551
diff changeset
3 <Topbar v-if="isAuthenticated"></Topbar>
f41c74b8af9c fix: Sidebar/Topmenu only visible when logged in
Thomas Junk <thomas.junk@intevation.de>
parents: 551
diff changeset
4 <Sidebar v-if="isAuthenticated"></Sidebar>
3
1597506a2241 merge with vue-cli
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
5 <router-view/>
1597506a2241 merge with vue-cli
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
6 </div>
1597506a2241 merge with vue-cli
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
7 </template>
1597506a2241 merge with vue-cli
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
8
1597506a2241 merge with vue-cli
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
9 <style lang="scss">
161
b7ac2e4f9c5c feat: collapsible sidebar
Thomas Junk <thomas.junk@intevation.de>
parents: 30
diff changeset
10 html {
b7ac2e4f9c5c feat: collapsible sidebar
Thomas Junk <thomas.junk@intevation.de>
parents: 30
diff changeset
11 height: 100%;
539
924490b3395b refac: Loginmask reworked
Thomas Junk <thomas.junk@intevation.de>
parents: 161
diff changeset
12 width: 100%;
924490b3395b refac: Loginmask reworked
Thomas Junk <thomas.junk@intevation.de>
parents: 161
diff changeset
13 margin: 0 auto;
161
b7ac2e4f9c5c feat: collapsible sidebar
Thomas Junk <thomas.junk@intevation.de>
parents: 30
diff changeset
14 }
17
7d242100af46 Adjusted the look and feel of the login page according to ISC
Thomas Junk <thomas.junk@intevation.de>
parents: 13
diff changeset
15 body {
542
505656a9947f refac: layout refactored
Thomas Junk <thomas.junk@intevation.de>
parents: 539
diff changeset
16 height: 100%;
505656a9947f refac: layout refactored
Thomas Junk <thomas.junk@intevation.de>
parents: 539
diff changeset
17 width: 100%;
17
7d242100af46 Adjusted the look and feel of the login page according to ISC
Thomas Junk <thomas.junk@intevation.de>
parents: 13
diff changeset
18 background-color: #efefef !important;
7d242100af46 Adjusted the look and feel of the login page according to ISC
Thomas Junk <thomas.junk@intevation.de>
parents: 13
diff changeset
19 }
7d242100af46 Adjusted the look and feel of the login page according to ISC
Thomas Junk <thomas.junk@intevation.de>
parents: 13
diff changeset
20
3
1597506a2241 merge with vue-cli
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
21 #app {
542
505656a9947f refac: layout refactored
Thomas Junk <thomas.junk@intevation.de>
parents: 539
diff changeset
22 height: 100%;
505656a9947f refac: layout refactored
Thomas Junk <thomas.junk@intevation.de>
parents: 539
diff changeset
23 width: 100%;
3
1597506a2241 merge with vue-cli
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
24 font-family: "Avenir", Helvetica, Arial, sans-serif;
1597506a2241 merge with vue-cli
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
25 -webkit-font-smoothing: antialiased;
1597506a2241 merge with vue-cli
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
26 -moz-osx-font-smoothing: grayscale;
1597506a2241 merge with vue-cli
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
27 text-align: center;
1597506a2241 merge with vue-cli
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
28 color: #2c3e50;
1597506a2241 merge with vue-cli
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
29 }
1597506a2241 merge with vue-cli
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
30 </style>
551
89bc8111563a refac: Layout adjustments
Thomas Junk <thomas.junk@intevation.de>
parents: 542
diff changeset
31
89bc8111563a refac: Layout adjustments
Thomas Junk <thomas.junk@intevation.de>
parents: 542
diff changeset
32 <script>
89bc8111563a refac: Layout adjustments
Thomas Junk <thomas.junk@intevation.de>
parents: 542
diff changeset
33 import Sidebar from "./components/Sidebar";
89bc8111563a refac: Layout adjustments
Thomas Junk <thomas.junk@intevation.de>
parents: 542
diff changeset
34 import Topbar from "./components/Topbar";
553
f41c74b8af9c fix: Sidebar/Topmenu only visible when logged in
Thomas Junk <thomas.junk@intevation.de>
parents: 551
diff changeset
35 import { mapGetters } from "vuex";
f41c74b8af9c fix: Sidebar/Topmenu only visible when logged in
Thomas Junk <thomas.junk@intevation.de>
parents: 551
diff changeset
36
551
89bc8111563a refac: Layout adjustments
Thomas Junk <thomas.junk@intevation.de>
parents: 542
diff changeset
37 export default {
89bc8111563a refac: Layout adjustments
Thomas Junk <thomas.junk@intevation.de>
parents: 542
diff changeset
38 name: "app",
553
f41c74b8af9c fix: Sidebar/Topmenu only visible when logged in
Thomas Junk <thomas.junk@intevation.de>
parents: 551
diff changeset
39 computed: {
f41c74b8af9c fix: Sidebar/Topmenu only visible when logged in
Thomas Junk <thomas.junk@intevation.de>
parents: 551
diff changeset
40 ...mapGetters("user", ["isAuthenticated"])
f41c74b8af9c fix: Sidebar/Topmenu only visible when logged in
Thomas Junk <thomas.junk@intevation.de>
parents: 551
diff changeset
41 },
551
89bc8111563a refac: Layout adjustments
Thomas Junk <thomas.junk@intevation.de>
parents: 542
diff changeset
42 components: {
89bc8111563a refac: Layout adjustments
Thomas Junk <thomas.junk@intevation.de>
parents: 542
diff changeset
43 Sidebar,
89bc8111563a refac: Layout adjustments
Thomas Junk <thomas.junk@intevation.de>
parents: 542
diff changeset
44 Topbar
89bc8111563a refac: Layout adjustments
Thomas Junk <thomas.junk@intevation.de>
parents: 542
diff changeset
45 }
89bc8111563a refac: Layout adjustments
Thomas Junk <thomas.junk@intevation.de>
parents: 542
diff changeset
46 };
89bc8111563a refac: Layout adjustments
Thomas Junk <thomas.junk@intevation.de>
parents: 542
diff changeset
47 </script>