annotate client/src/morphtool/Morphtool.vue @ 1217:ba8cd80d68b6

made more use of bootstrap classes instead of custom css
author Markus Kottlaender <markus@intevation.de>
date Mon, 19 Nov 2018 15:20:22 +0100
parents 9d93968db2cd
children c14353e2cdb9
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
823
d7ae7338872d client: add morphtool again
Bernhard Reiter <bernhard@intevation.de>
parents:
diff changeset
1 <template>
1217
ba8cd80d68b6 made more use of bootstrap classes instead of custom css
Markus Kottlaender <markus@intevation.de>
parents: 1213
diff changeset
2 <div class="mb-3 ml-auto rounded position-relative">
1213
9d93968db2cd replaced custom css with bootstrap classes
Markus Kottlaender <markus@intevation.de>
parents: 1191
diff changeset
3 <div v-if="selectedBottleneck && surveys && !selectedSurvey" class="ui-element bg-white rounded p-3 shadow">
1217
ba8cd80d68b6 made more use of bootstrap classes instead of custom css
Markus Kottlaender <markus@intevation.de>
parents: 1213
diff changeset
4 <h4 class="text-center mx-4">{{ selectedBottleneck }}</h4>
ba8cd80d68b6 made more use of bootstrap classes instead of custom css
Markus Kottlaender <markus@intevation.de>
parents: 1213
diff changeset
5 <hr>
ba8cd80d68b6 made more use of bootstrap classes instead of custom css
Markus Kottlaender <markus@intevation.de>
parents: 1213
diff changeset
6 <div
ba8cd80d68b6 made more use of bootstrap classes instead of custom css
Markus Kottlaender <markus@intevation.de>
parents: 1213
diff changeset
7 @click="$store.dispatch('fairwayprofile/clearSelection');"
ba8cd80d68b6 made more use of bootstrap classes instead of custom css
Markus Kottlaender <markus@intevation.de>
parents: 1213
diff changeset
8 class="ui-element d-flex morphtoolminus position-absolute"
ba8cd80d68b6 made more use of bootstrap classes instead of custom css
Markus Kottlaender <markus@intevation.de>
parents: 1213
diff changeset
9 >
ba8cd80d68b6 made more use of bootstrap classes instead of custom css
Markus Kottlaender <markus@intevation.de>
parents: 1213
diff changeset
10 <i class="fa fa-close p-2"></i>
ba8cd80d68b6 made more use of bootstrap classes instead of custom css
Markus Kottlaender <markus@intevation.de>
parents: 1213
diff changeset
11 </div>
ba8cd80d68b6 made more use of bootstrap classes instead of custom css
Markus Kottlaender <markus@intevation.de>
parents: 1213
diff changeset
12 <div>
1111
f106aee673e7 selected bottleneck and surveys now handled by bottleneck store
Markus Kottlaender <markus@intevation.de>
parents: 1064
diff changeset
13 <div
f106aee673e7 selected bottleneck and surveys now handled by bottleneck store
Markus Kottlaender <markus@intevation.de>
parents: 1064
diff changeset
14 v-for="survey of surveys"
f106aee673e7 selected bottleneck and surveys now handled by bottleneck store
Markus Kottlaender <markus@intevation.de>
parents: 1064
diff changeset
15 :key="survey.data_info"
1217
ba8cd80d68b6 made more use of bootstrap classes instead of custom css
Markus Kottlaender <markus@intevation.de>
parents: 1213
diff changeset
16 class="my-1"
1111
f106aee673e7 selected bottleneck and surveys now handled by bottleneck store
Markus Kottlaender <markus@intevation.de>
parents: 1064
diff changeset
17 @click.prevent="$store.commit('bottlenecks/setSelectedSurvey', survey)"
f106aee673e7 selected bottleneck and surveys now handled by bottleneck store
Markus Kottlaender <markus@intevation.de>
parents: 1064
diff changeset
18 >
f106aee673e7 selected bottleneck and surveys now handled by bottleneck store
Markus Kottlaender <markus@intevation.de>
parents: 1064
diff changeset
19 <a href="#" @click.prevent>{{ survey.date_info }}</a>
1217
ba8cd80d68b6 made more use of bootstrap classes instead of custom css
Markus Kottlaender <markus@intevation.de>
parents: 1213
diff changeset
20 </div>
ba8cd80d68b6 made more use of bootstrap classes instead of custom css
Markus Kottlaender <markus@intevation.de>
parents: 1213
diff changeset
21 </div>
892
81b84ad962f8 morphtool streamlined
Thomas Junk <thomas.junk@intevation.de>
parents: 891
diff changeset
22 </div>
1217
ba8cd80d68b6 made more use of bootstrap classes instead of custom css
Markus Kottlaender <markus@intevation.de>
parents: 1213
diff changeset
23 <div v-if="selectedSurvey && !showSplitscreen" class="ui-element shadow morphtool rounded position-relative bg-white my-auto">
892
81b84ad962f8 morphtool streamlined
Thomas Junk <thomas.junk@intevation.de>
parents: 891
diff changeset
24 <div class="d-flex flex-row justify-content-between">
1146
74e180ad3d6b fairway profile UI improvements
Markus Kottlaender <markus@intevation.de>
parents: 1144
diff changeset
25 <h6 class="my-auto px-2">
1111
f106aee673e7 selected bottleneck and surveys now handled by bottleneck store
Markus Kottlaender <markus@intevation.de>
parents: 1064
diff changeset
26 {{ selectedBottleneck }}
1146
74e180ad3d6b fairway profile UI improvements
Markus Kottlaender <markus@intevation.de>
parents: 1144
diff changeset
27 ({{ selectedSurvey.date_info }})
1027
04a9e78dcc5f refac: remove morphstore. not necessary
Thomas Junk <thomas.junk@intevation.de>
parents: 1019
diff changeset
28 </h6>
1146
74e180ad3d6b fairway profile UI improvements
Markus Kottlaender <markus@intevation.de>
parents: 1144
diff changeset
29 <i class="fa fa-angle-up py-2 px-2 border-left" @click="$store.commit('application/showSplitscreen', true)" v-if="Object.keys(currentProfile).length"></i>
74e180ad3d6b fairway profile UI improvements
Markus Kottlaender <markus@intevation.de>
parents: 1144
diff changeset
30 <i class="fa fa-close text-danger py-2 px-2 border-left" @click="$store.dispatch('fairwayprofile/clearSelection');"></i>
886
b1489669ba52 morphtool layout fixed
Thomas Junk <thomas.junk@intevation.de>
parents: 836
diff changeset
31 </div>
b1489669ba52 morphtool layout fixed
Thomas Junk <thomas.junk@intevation.de>
parents: 836
diff changeset
32 </div>
826
90a601884ff2 client: improve survey selection for Morphtool
Bernhard Reiter <bernhard@intevation.de>
parents: 823
diff changeset
33 </div>
823
d7ae7338872d client: add morphtool again
Bernhard Reiter <bernhard@intevation.de>
parents:
diff changeset
34 </template>
d7ae7338872d client: add morphtool again
Bernhard Reiter <bernhard@intevation.de>
parents:
diff changeset
35
1191
b23622905a3f switched entirely to sass instead of scss
Markus Kottlaender <markus@intevation.de>
parents: 1146
diff changeset
36 <style scoped lang="sass">
b23622905a3f switched entirely to sass instead of scss
Markus Kottlaender <markus@intevation.de>
parents: 1146
diff changeset
37 .morphtool
b23622905a3f switched entirely to sass instead of scss
Markus Kottlaender <markus@intevation.de>
parents: 1146
diff changeset
38 height: $icon-width
b23622905a3f switched entirely to sass instead of scss
Markus Kottlaender <markus@intevation.de>
parents: 1146
diff changeset
39 z-index: 2
892
81b84ad962f8 morphtool streamlined
Thomas Junk <thomas.junk@intevation.de>
parents: 891
diff changeset
40
1191
b23622905a3f switched entirely to sass instead of scss
Markus Kottlaender <markus@intevation.de>
parents: 1146
diff changeset
41 .morphtoolminus
b23622905a3f switched entirely to sass instead of scss
Markus Kottlaender <markus@intevation.de>
parents: 1146
diff changeset
42 top: 0
b23622905a3f switched entirely to sass instead of scss
Markus Kottlaender <markus@intevation.de>
parents: 1146
diff changeset
43 right: 0
b23622905a3f switched entirely to sass instead of scss
Markus Kottlaender <markus@intevation.de>
parents: 1146
diff changeset
44 height: $icon-width
b23622905a3f switched entirely to sass instead of scss
Markus Kottlaender <markus@intevation.de>
parents: 1146
diff changeset
45 width: $icon-height
b23622905a3f switched entirely to sass instead of scss
Markus Kottlaender <markus@intevation.de>
parents: 1146
diff changeset
46 z-index: 2
823
d7ae7338872d client: add morphtool again
Bernhard Reiter <bernhard@intevation.de>
parents:
diff changeset
47 </style>
d7ae7338872d client: add morphtool again
Bernhard Reiter <bernhard@intevation.de>
parents:
diff changeset
48
d7ae7338872d client: add morphtool again
Bernhard Reiter <bernhard@intevation.de>
parents:
diff changeset
49 <script>
1019
ca628dce90dd Licensing information added
Thomas Junk <thomas.junk@intevation.de>
parents: 1015
diff changeset
50 /*
ca628dce90dd Licensing information added
Thomas Junk <thomas.junk@intevation.de>
parents: 1015
diff changeset
51 * This is Free Software under GNU Affero General Public License v >= 3.0
ca628dce90dd Licensing information added
Thomas Junk <thomas.junk@intevation.de>
parents: 1015
diff changeset
52 * without warranty, see README.md and license for details.
ca628dce90dd Licensing information added
Thomas Junk <thomas.junk@intevation.de>
parents: 1015
diff changeset
53 *
ca628dce90dd Licensing information added
Thomas Junk <thomas.junk@intevation.de>
parents: 1015
diff changeset
54 * SPDX-License-Identifier: AGPL-3.0-or-later
ca628dce90dd Licensing information added
Thomas Junk <thomas.junk@intevation.de>
parents: 1015
diff changeset
55 * License-Filename: LICENSES/AGPL-3.0.txt
ca628dce90dd Licensing information added
Thomas Junk <thomas.junk@intevation.de>
parents: 1015
diff changeset
56 *
ca628dce90dd Licensing information added
Thomas Junk <thomas.junk@intevation.de>
parents: 1015
diff changeset
57 * Copyright (C) 2018 by via donau
ca628dce90dd Licensing information added
Thomas Junk <thomas.junk@intevation.de>
parents: 1015
diff changeset
58 * – Österreichische Wasserstraßen-Gesellschaft mbH
ca628dce90dd Licensing information added
Thomas Junk <thomas.junk@intevation.de>
parents: 1015
diff changeset
59 * Software engineering by Intevation GmbH
ca628dce90dd Licensing information added
Thomas Junk <thomas.junk@intevation.de>
parents: 1015
diff changeset
60 *
ca628dce90dd Licensing information added
Thomas Junk <thomas.junk@intevation.de>
parents: 1015
diff changeset
61 * Author(s):
ca628dce90dd Licensing information added
Thomas Junk <thomas.junk@intevation.de>
parents: 1015
diff changeset
62 * Thomas Junk <thomas.junk@intevation.de>
ca628dce90dd Licensing information added
Thomas Junk <thomas.junk@intevation.de>
parents: 1015
diff changeset
63 */
1140
2e06bc53b002 separating line/polygon/cut tools in UI
Markus Kottlaender <markus@intevation.de>
parents: 1123
diff changeset
64 import { mapState, mapGetters } from "vuex";
826
90a601884ff2 client: improve survey selection for Morphtool
Bernhard Reiter <bernhard@intevation.de>
parents: 823
diff changeset
65
823
d7ae7338872d client: add morphtool again
Bernhard Reiter <bernhard@intevation.de>
parents:
diff changeset
66 export default {
d7ae7338872d client: add morphtool again
Bernhard Reiter <bernhard@intevation.de>
parents:
diff changeset
67 name: "morphtool",
d7ae7338872d client: add morphtool again
Bernhard Reiter <bernhard@intevation.de>
parents:
diff changeset
68 computed: {
1140
2e06bc53b002 separating line/polygon/cut tools in UI
Markus Kottlaender <markus@intevation.de>
parents: 1123
diff changeset
69 ...mapGetters("map", ["getLayerByName"]),
2e06bc53b002 separating line/polygon/cut tools in UI
Markus Kottlaender <markus@intevation.de>
parents: 1123
diff changeset
70 ...mapState("map", ["openLayersMap", "cutTool"]),
1146
74e180ad3d6b fairway profile UI improvements
Markus Kottlaender <markus@intevation.de>
parents: 1144
diff changeset
71 ...mapState("application", ["showSplitscreen"]),
74e180ad3d6b fairway profile UI improvements
Markus Kottlaender <markus@intevation.de>
parents: 1144
diff changeset
72 ...mapState("fairwayprofile", ["currentProfile"]),
1118
7e788814cbde removed unnecessary imports and formatted code
Markus Kottlaender <markus@intevation.de>
parents: 1115
diff changeset
73 ...mapState("bottlenecks", [
7e788814cbde removed unnecessary imports and formatted code
Markus Kottlaender <markus@intevation.de>
parents: 1115
diff changeset
74 "selectedBottleneck",
7e788814cbde removed unnecessary imports and formatted code
Markus Kottlaender <markus@intevation.de>
parents: 1115
diff changeset
75 "surveys",
7e788814cbde removed unnecessary imports and formatted code
Markus Kottlaender <markus@intevation.de>
parents: 1115
diff changeset
76 "selectedSurvey"
7e788814cbde removed unnecessary imports and formatted code
Markus Kottlaender <markus@intevation.de>
parents: 1115
diff changeset
77 ])
823
d7ae7338872d client: add morphtool again
Bernhard Reiter <bernhard@intevation.de>
parents:
diff changeset
78 }
d7ae7338872d client: add morphtool again
Bernhard Reiter <bernhard@intevation.de>
parents:
diff changeset
79 };
d7ae7338872d client: add morphtool again
Bernhard Reiter <bernhard@intevation.de>
parents:
diff changeset
80 </script>