Mercurial > gemma
comparison client/src/components/App.vue @ 1272:bc55ffaeb639
cleaned up client/src directory
better organization of files and directories, better naming, separation of admin and map context
author | Markus Kottlaender <markus@intevation.de> |
---|---|
date | Thu, 22 Nov 2018 07:07:12 +0100 |
parents | |
children | aec9ed491dad |
comparison
equal
deleted
inserted
replaced
1268:aca692e73028 | 1272:bc55ffaeb639 |
---|---|
1 <template> | |
2 <div id="app" class="main"> | |
3 <div v-if="isAuthenticated" class="d-flex flex-column userinterface"> | |
4 <div class="topbar d-flex pt-3 mx-3"> | |
5 <div class="mr-auto d-flex"> | |
6 <Sidebar :routeName="routeName"></Sidebar> | |
7 <div class="d-flex flex-column" style="max-width: 600px;"> | |
8 <Search v-if="routeName == 'mainview'"></Search> | |
9 <Contextbox v-if="routeName == 'mainview'"></Contextbox> | |
10 </div> | |
11 </div> | |
12 <div class="ml-auto d-flex"> | |
13 <Pdftool v-if="routeName == 'mainview'"></Pdftool> | |
14 <Layers v-if="routeName == 'mainview'"></Layers> | |
15 <Identify v-if="routeName == 'mainview'"></Identify> | |
16 <Toolbar v-if="routeName == 'mainview'"></Toolbar> | |
17 </div> | |
18 </div> | |
19 <div class="flex-fill"></div> | |
20 <div class="d-flex flex-row align-items-end"> | |
21 <Surveys v-if="routeName == 'mainview'"></Surveys> | |
22 <Infobar v-if="routeName == 'mainview'"></Infobar> | |
23 </div> | |
24 <Zoom v-if="routeName == 'mainview'"></Zoom> | |
25 </div> | |
26 <div class="d-flex flex-column"> | |
27 <router-view/> | |
28 </div> | |
29 </div> | |
30 </template> | |
31 | |
32 <style lang="sass" scoped> | |
33 .userinterface | |
34 position: absolute | |
35 top: 0 | |
36 left: 0 | |
37 height: 100vh | |
38 width: 100vw | |
39 z-index: 4 | |
40 pointer-events: none | |
41 | |
42 .topbar | |
43 position: relative | |
44 z-index: 2 | |
45 | |
46 #app | |
47 height: 100vh | |
48 width: 100vw | |
49 font-family: "Avenir", Helvetica, Arial, sans-serif | |
50 -webkit-font-smoothing: antialiased | |
51 -moz-osx-font-smoothing: grayscale | |
52 text-align: center | |
53 color: #2c3e50 | |
54 </style> | |
55 | |
56 <script> | |
57 /* | |
58 * This is Free Software under GNU Affero General Public License v >= 3.0 | |
59 * without warranty, see README.md and license for details. | |
60 * | |
61 * SPDX-License-Identifier: AGPL-3.0-or-later | |
62 * License-Filename: LICENSES/AGPL-3.0.txt | |
63 * | |
64 * Copyright (C) 2018 by via donau | |
65 * – Österreichische Wasserstraßen-Gesellschaft mbH | |
66 * Software engineering by Intevation GmbH | |
67 * | |
68 * Author(s): | |
69 * Thomas Junk <thomas.junk@intevation.de> | |
70 * Markus Kottländer <markus.kottlaender@intevation.de> | |
71 */ | |
72 import { mapState } from "vuex"; | |
73 | |
74 export default { | |
75 name: "app", | |
76 computed: { | |
77 ...mapState("user", ["isAuthenticated"]), | |
78 routeName() { | |
79 const routeName = this.$route.name; | |
80 return routeName; | |
81 } | |
82 }, | |
83 components: { | |
84 Surveys: () => import("./map/fairway/Surveys"), | |
85 Infobar: () => import("./map/fairway/Infobar"), | |
86 Pdftool: () => import("./map/Pdftool"), | |
87 Zoom: () => import("./map/Zoom"), | |
88 Identify: () => import("./map/Identify"), | |
89 Layers: () => import("./map/layers/Layers"), | |
90 Sidebar: () => import("./Sidebar"), | |
91 Search: () => import("./map/Search"), | |
92 Contextbox: () => import("./map/Contextbox"), | |
93 Toolbar: () => import("./map/toolbar/Toolbar") | |
94 } | |
95 }; | |
96 </script> |