@abi-software/flatmapvuer 1.20.0 → 1.20.1-demo.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/flatmapvuer.js +2216 -2302
- package/dist/flatmapvuer.umd.cjs +16 -8
- package/dist/style.css +1 -1
- package/package.json +2 -2
- package/src/App.vue +17 -52
- package/src/components/FlatmapVuer.vue +250 -363
- package/src/components/MultiFlatmapVuer.vue +85 -151
- package/src/components/legends/DynamicLegends.vue +21 -12
- package/src/services/somaLocationMarkers.js +129 -0
package/src/App.vue
CHANGED
|
@@ -10,7 +10,8 @@
|
|
|
10
10
|
<div class="options-container">
|
|
11
11
|
<el-row :gutter="20">
|
|
12
12
|
<el-col :span="8">
|
|
13
|
-
<el-button @click="
|
|
13
|
+
<el-button @click="startHelpTour" size="small">Help Tour</el-button>
|
|
14
|
+
<el-button @click="startHelpHover" size="small">Hover Help</el-button>
|
|
14
15
|
</el-col>
|
|
15
16
|
<el-col :span="8">
|
|
16
17
|
<el-button @click="saveSettings()" size="small">Save Settings</el-button>
|
|
@@ -57,12 +58,6 @@
|
|
|
57
58
|
@ready="FlatmapReady"
|
|
58
59
|
@context-restored="FlatmapReady"
|
|
59
60
|
:initial="initial"
|
|
60
|
-
:helpMode="helpMode"
|
|
61
|
-
:helpModeDialog="useHelpModeDialog"
|
|
62
|
-
:helpModeActiveItem="helpModeActiveItem"
|
|
63
|
-
@help-mode-last-item="onHelpModeLastItem"
|
|
64
|
-
@shown-tooltip="onTooltipShown"
|
|
65
|
-
@shown-map-tooltip="onMapTooltipShown"
|
|
66
61
|
:displayMinimap="true"
|
|
67
62
|
:enableOpenMapUI="true"
|
|
68
63
|
:flatmapAPI="flatmapAPI"
|
|
@@ -72,14 +67,8 @@
|
|
|
72
67
|
@flatmapChanged="onFlatmapChanged"
|
|
73
68
|
/>
|
|
74
69
|
|
|
75
|
-
<
|
|
76
|
-
|
|
77
|
-
ref="multiflatmapHelp"
|
|
78
|
-
:multiflatmapRef="multiflatmapRef"
|
|
79
|
-
:lastItem="helpModeLastItem"
|
|
80
|
-
@show-next="onHelpModeShowNext"
|
|
81
|
-
@finish-help-mode="onFinishHelpMode"
|
|
82
|
-
/>
|
|
70
|
+
<HelpModeTour v-model="helpTourOpen" :steps="helpTourSteps" />
|
|
71
|
+
<HelpModeHover v-model="helpHoverOpen" :steps="helpTourSteps" />
|
|
83
72
|
</div>
|
|
84
73
|
</template>
|
|
85
74
|
|
|
@@ -89,14 +78,15 @@ import { markRaw, shallowRef } from 'vue';
|
|
|
89
78
|
import { Setting as ElIconSetting } from '@element-plus/icons-vue';
|
|
90
79
|
import './icons/mapicon-species-style.css';
|
|
91
80
|
import MultiFlatmapVuer from './components/MultiFlatmapVuer.vue';
|
|
92
|
-
import {
|
|
81
|
+
import { HelpModeHover, HelpModeTour } from '@abi-software/map-utilities';
|
|
93
82
|
import '@abi-software/map-utilities/dist/style.css';
|
|
94
83
|
|
|
95
84
|
export default {
|
|
96
85
|
name: 'app',
|
|
97
86
|
components: {
|
|
98
87
|
MultiFlatmapVuer,
|
|
99
|
-
|
|
88
|
+
HelpModeTour,
|
|
89
|
+
HelpModeHover,
|
|
100
90
|
},
|
|
101
91
|
methods: {
|
|
102
92
|
saveSettings: function () {
|
|
@@ -166,35 +156,18 @@ export default {
|
|
|
166
156
|
this.$refs.multi.getCurrentFlatmap().searchAndShowResult(this.searchText, true);
|
|
167
157
|
},
|
|
168
158
|
onFlatmapChanged: function (activeSpecies) {
|
|
169
|
-
this.helpMode = false;
|
|
170
159
|
// Update current flatmapImp after changing species
|
|
171
160
|
if (this.$refs.multi.$refs[activeSpecies][0].mapImp) {
|
|
172
161
|
window.flatmapImp = this.$refs.multi.$refs[activeSpecies][0].mapImp;
|
|
173
162
|
}
|
|
174
163
|
},
|
|
175
|
-
|
|
176
|
-
this.
|
|
177
|
-
|
|
178
|
-
onHelpModeLastItem: function (isLastItem) {
|
|
179
|
-
if (isLastItem) {
|
|
180
|
-
this.helpModeLastItem = true;
|
|
181
|
-
}
|
|
182
|
-
},
|
|
183
|
-
onFinishHelpMode: function () {
|
|
184
|
-
this.helpMode = false;
|
|
185
|
-
// reset help mode to default values
|
|
186
|
-
this.helpModeActiveItem = 0;
|
|
187
|
-
this.helpModeLastItem = false;
|
|
188
|
-
},
|
|
189
|
-
onTooltipShown: function () {
|
|
190
|
-
if (this.$refs.multi && this.$refs.multiflatmapHelp) {
|
|
191
|
-
this.$refs.multiflatmapHelp.toggleTooltipHighlight();
|
|
192
|
-
}
|
|
164
|
+
startHelpTour: function () {
|
|
165
|
+
this.helpTourSteps = this.$refs.multi.getHelpModeSteps();
|
|
166
|
+
this.helpTourOpen = true;
|
|
193
167
|
},
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
}
|
|
168
|
+
startHelpHover: function () {
|
|
169
|
+
this.helpTourSteps = this.$refs.multi.getHelpModeSteps();
|
|
170
|
+
this.helpHoverOpen = true;
|
|
198
171
|
},
|
|
199
172
|
},
|
|
200
173
|
provide() {
|
|
@@ -268,15 +241,14 @@ export default {
|
|
|
268
241
|
},
|
|
269
242
|
displayCloseButton: false,
|
|
270
243
|
initial: 'Human Male',
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
useHelpModeDialog: true,
|
|
244
|
+
helpTourOpen: false,
|
|
245
|
+
helpTourSteps: [],
|
|
246
|
+
helpHoverOpen: false,
|
|
275
247
|
multiflatmapRef: null,
|
|
276
248
|
mapSettings: [],
|
|
277
249
|
//flatmapAPI: "https://mapcore-demo.org/current/flatmap/v2/"
|
|
278
250
|
//flatmapAPI: "https://mapcore-demo.org/devel/flatmap/v3/"
|
|
279
|
-
flatmapAPI:
|
|
251
|
+
flatmapAPI: 'https://mapcore-demo.org/current/flatmap/v3/',
|
|
280
252
|
//flatmapAPI: 'https://mapcore-demo.org/devel/flatmap/v4/',
|
|
281
253
|
//flatmapAPI: 'https://mapcore-demo.org/curation/flatmap/',
|
|
282
254
|
//flatmapAPI: "https://mapcore-demo.org/fccb/flatmap/"
|
|
@@ -334,13 +306,6 @@ export default {
|
|
|
334
306
|
window.multiflatmapRef = this.multiflatmapRef;
|
|
335
307
|
//window.flatmapRef = this.multiflatmapRef.getCurrentFlatmap();
|
|
336
308
|
},
|
|
337
|
-
watch: {
|
|
338
|
-
helpMode: function (newVal) {
|
|
339
|
-
if (!newVal) {
|
|
340
|
-
this.helpModeActiveItem = 0;
|
|
341
|
-
}
|
|
342
|
-
},
|
|
343
|
-
},
|
|
344
309
|
};
|
|
345
310
|
</script>
|
|
346
311
|
|