@kalisio/kdk 1.6.0 → 1.7.0
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/.travis.test.sh +1 -1
- package/CHANGELOG.md +63 -13
- package/extras/tours/map/catalog-panel.js +61 -10
- package/extras/tours/map/create-view.js +25 -0
- package/extras/tours/map/fab.js +10 -1
- package/extras/tours/map/navigation-bar.js +7 -9
- package/lib/core/api/application.js +9 -1
- package/lib/core/api/application.js.map +1 -1
- package/lib/core/client/components/chart/KChart.vue +115 -0
- package/lib/core/client/components/chart/KStatsChart.vue +76 -0
- package/lib/core/client/components/chart/index.js +20 -0
- package/lib/core/client/components/chart/index.js.map +1 -0
- package/lib/core/client/components/collection/KFilter.vue +6 -0
- package/lib/core/client/components/collection/KHistoryEntry.vue +1 -1
- package/lib/core/client/components/collection/KItem.vue +4 -4
- package/lib/core/client/components/form/KChipsField.vue +4 -4
- package/lib/core/client/components/form/KView.vue +1 -1
- package/lib/core/client/components/frame/KAction.vue +40 -5
- package/lib/core/client/components/frame/KBlock.vue +7 -7
- package/lib/core/client/components/frame/KContent.vue +1 -1
- package/lib/core/client/components/frame/KOpener.vue +1 -1
- package/lib/core/client/components/frame/KPanel.vue +8 -7
- package/lib/core/client/components/frame/KPopupAction.vue +6 -0
- package/lib/core/client/components/frame/KScreen.vue +1 -1
- package/lib/core/client/components/frame/KStamp.vue +4 -2
- package/lib/core/client/components/frame/index.js +1 -6
- package/lib/core/client/components/frame/index.js.map +1 -1
- package/lib/core/client/components/input/KIconChooser.vue +5 -2
- package/lib/core/client/components/input/KPalette.vue +1 -1
- package/lib/core/client/components/input/index.js +14 -4
- package/lib/core/client/components/input/index.js.map +1 -1
- package/lib/core/client/components/layout/KFab.vue +1 -1
- package/lib/core/client/components/layout/KLayout.vue +10 -2
- package/lib/core/client/components/layout/KPage.vue +19 -18
- package/lib/core/client/components/layout/KTour.vue +5 -3
- package/lib/core/client/components/layout/KWindow.vue +211 -59
- package/lib/core/client/components/media/KMediaBrowser.vue +6 -6
- package/lib/core/client/components/menu/KMenu.vue +13 -5
- package/lib/core/client/components/menu/KRadialFab.vue +22 -24
- package/lib/core/client/components/menu/KRadialFabItem.vue +17 -18
- package/lib/core/client/components/team/KGroupsActivity.vue +1 -1
- package/lib/core/client/components/team/KJoinGroup.vue +2 -2
- package/lib/core/client/components/time/KAbsoluteTimeRange.vue +190 -0
- package/lib/core/client/components/time/KRelativeTimeRanges.vue +192 -0
- package/lib/core/client/components/time/index.js +20 -0
- package/lib/core/client/components/time/index.js.map +1 -0
- package/lib/core/client/i18n/core_en.json +35 -12
- package/lib/core/client/i18n/core_fr.json +36 -13
- package/lib/core/client/index.js +1 -1
- package/lib/core/client/index.js.map +1 -1
- package/lib/core/client/mixins/mixin.base-collection.js +11 -1
- package/lib/core/client/mixins/mixin.base-collection.js.map +1 -1
- package/lib/core/client/mixins/mixin.base-widget.js +25 -13
- package/lib/core/client/mixins/mixin.base-widget.js.map +1 -1
- package/lib/core/client/services/index.js +2 -1
- package/lib/core/client/services/index.js.map +1 -1
- package/lib/core/client/services/local-settings.service.js +4 -0
- package/lib/core/client/services/local-settings.service.js.map +1 -1
- package/lib/core/client/time.js +25 -15
- package/lib/core/client/time.js.map +1 -1
- package/lib/core/client/units.js +12 -0
- package/lib/core/client/units.js.map +1 -1
- package/lib/core/client/utils.js +11 -0
- package/lib/core/client/utils.js.map +1 -1
- package/lib/core/common/schemas/settings.update.json +14 -4
- package/lib/map/api/hooks/hooks.catalog.js +20 -0
- package/lib/map/api/hooks/hooks.catalog.js.map +1 -1
- package/lib/map/api/models/catalog.model.mongodb.js +6 -1
- package/lib/map/api/models/catalog.model.mongodb.js.map +1 -1
- package/lib/map/api/models/features.model.mongodb.js +5 -0
- package/lib/map/api/models/features.model.mongodb.js.map +1 -1
- package/lib/map/api/services/catalog/catalog.hooks.js +3 -1
- package/lib/map/api/services/catalog/catalog.hooks.js.map +1 -1
- package/lib/map/client/components/KColorLegend.vue +22 -21
- package/lib/map/client/components/KFeaturesChart.vue +81 -110
- package/lib/map/client/components/KLayerStyleForm.vue +119 -47
- package/lib/map/client/components/KLevelSlider.vue +30 -29
- package/lib/map/client/components/KLocationMap.vue +2 -2
- package/lib/map/client/components/KMeasureTool.vue +30 -6
- package/lib/map/client/components/KPositionIndicator.vue +4 -4
- package/lib/map/client/components/KTimeline.vue +25 -27
- package/lib/map/client/components/KTimezoneMap.vue +156 -0
- package/lib/map/client/components/KUrlLegend.vue +11 -10
- package/lib/map/client/components/catalog/KBaseLayersSelector.vue +1 -1
- package/lib/map/client/components/catalog/KCatalogLayersPanel.vue +56 -0
- package/lib/map/client/components/catalog/KCreateView.vue +91 -0
- package/lib/map/client/components/catalog/KLayerCategories.vue +2 -1
- package/lib/map/client/components/catalog/{KCatalog.vue → KLayersPanel.vue} +19 -37
- package/lib/map/client/components/catalog/KUserLayersPanel.vue +40 -0
- package/lib/map/client/components/catalog/KViewSelector.vue +46 -0
- package/lib/map/client/components/catalog/KViewsPanel.vue +110 -0
- package/lib/map/client/components/catalog/KWeatherLayersSelector.vue +4 -13
- package/lib/map/client/components/form/KTimezoneField.vue +135 -0
- package/lib/map/client/components/widget/KElevationProfile.vue +488 -0
- package/lib/map/client/components/widget/KInformationBox.vue +48 -23
- package/lib/map/client/components/widget/KMapillaryViewer.vue +26 -20
- package/lib/map/client/components/widget/KTimeSeries.vue +267 -347
- package/lib/map/client/i18n/map_en.json +63 -40
- package/lib/map/client/i18n/map_fr.json +65 -42
- package/lib/map/client/leaflet/GradientPath.js +40 -19
- package/lib/map/client/leaflet/GradientPath.js.map +1 -1
- package/lib/map/client/leaflet/TiledFeatureLayer.js +527 -93
- package/lib/map/client/leaflet/TiledFeatureLayer.js.map +1 -1
- package/lib/map/client/leaflet/TiledMeshLayer.js +58 -35
- package/lib/map/client/leaflet/TiledMeshLayer.js.map +1 -1
- package/lib/map/client/leaflet/utils.js +44 -3
- package/lib/map/client/leaflet/utils.js.map +1 -1
- package/lib/map/client/mixins/globe/mixin.base-globe.js +16 -1
- package/lib/map/client/mixins/globe/mixin.base-globe.js.map +1 -1
- package/lib/map/client/mixins/globe/mixin.file-layers.js +12 -2
- package/lib/map/client/mixins/globe/mixin.file-layers.js.map +1 -1
- package/lib/map/client/mixins/globe/mixin.geojson-layers.js +7 -6
- package/lib/map/client/mixins/globe/mixin.geojson-layers.js.map +1 -1
- package/lib/map/client/mixins/globe/mixin.popup.js +4 -2
- package/lib/map/client/mixins/globe/mixin.popup.js.map +1 -1
- package/lib/map/client/mixins/globe/mixin.style.js +8 -4
- package/lib/map/client/mixins/globe/mixin.style.js.map +1 -1
- package/lib/map/client/mixins/globe/mixin.tooltip.js +4 -2
- package/lib/map/client/mixins/globe/mixin.tooltip.js.map +1 -1
- package/lib/map/client/mixins/index.js +23 -18
- package/lib/map/client/mixins/index.js.map +1 -1
- package/lib/map/client/mixins/map/mixin.base-map.js +20 -2
- package/lib/map/client/mixins/map/mixin.base-map.js.map +1 -1
- package/lib/map/client/mixins/map/mixin.edit-layers.js +8 -4
- package/lib/map/client/mixins/map/mixin.edit-layers.js.map +1 -1
- package/lib/map/client/mixins/map/mixin.geojson-layers.js +27 -5
- package/lib/map/client/mixins/map/mixin.geojson-layers.js.map +1 -1
- package/lib/map/client/mixins/map/mixin.heatmap-layers.js +6 -1
- package/lib/map/client/mixins/map/mixin.heatmap-layers.js.map +1 -1
- package/lib/map/client/mixins/map/mixin.popup.js +1 -1
- package/lib/map/client/mixins/map/mixin.popup.js.map +1 -1
- package/lib/map/client/mixins/map/mixin.style.js +8 -4
- package/lib/map/client/mixins/map/mixin.style.js.map +1 -1
- package/lib/map/client/mixins/map/mixin.tiled-mesh-layers.js +4 -11
- package/lib/map/client/mixins/map/mixin.tiled-mesh-layers.js.map +1 -1
- package/lib/map/client/mixins/map/mixin.tiled-wind-layers.js +0 -11
- package/lib/map/client/mixins/map/mixin.tiled-wind-layers.js.map +1 -1
- package/lib/map/client/mixins/map/mixin.tooltip.js +1 -1
- package/lib/map/client/mixins/map/mixin.tooltip.js.map +1 -1
- package/lib/map/client/mixins/mixin.activity.js +150 -150
- package/lib/map/client/mixins/mixin.activity.js.map +1 -1
- package/lib/map/client/mixins/mixin.catalog-panel.js +36 -0
- package/lib/map/client/mixins/mixin.catalog-panel.js.map +1 -0
- package/lib/map/client/mixins/mixin.feature-selection.js +17 -8
- package/lib/map/client/mixins/mixin.feature-selection.js.map +1 -1
- package/lib/map/client/mixins/mixin.feature-service.js +36 -16
- package/lib/map/client/mixins/mixin.feature-service.js.map +1 -1
- package/lib/map/client/mixins/mixin.infobox.js +1 -1
- package/lib/map/client/mixins/mixin.infobox.js.map +1 -1
- package/lib/map/client/mixins/mixin.levels.js +26 -12
- package/lib/map/client/mixins/mixin.levels.js.map +1 -1
- package/lib/map/client/mixins/mixin.style.js +1 -0
- package/lib/map/client/mixins/mixin.style.js.map +1 -1
- package/lib/map/client/mixins/mixin.weacast.js +15 -23
- package/lib/map/client/mixins/mixin.weacast.js.map +1 -1
- package/lib/map/client/pixi-utils.js +8 -177
- package/lib/map/client/pixi-utils.js.map +1 -1
- package/lib/map/client/utils.js +1 -0
- package/lib/map/client/utils.js.map +1 -1
- package/lib/map/common/grid.js +131 -0
- package/lib/map/common/grid.js.map +1 -1
- package/lib/map/common/index.js +22 -11
- package/lib/map/common/index.js.map +1 -1
- package/lib/map/common/meteo-model-grid-source.js +5 -2
- package/lib/map/common/meteo-model-grid-source.js.map +1 -1
- package/lib/map/common/time-based-grid-source.js +5 -2
- package/lib/map/common/time-based-grid-source.js.map +1 -1
- package/lib/test/client/core/collection.js +31 -13
- package/lib/test/client/core/collection.js.map +1 -1
- package/lib/test/client/core/layout.js +137 -49
- package/lib/test/client/core/layout.js.map +1 -1
- package/lib/test/client/core/utils.js +89 -22
- package/lib/test/client/core/utils.js.map +1 -1
- package/lib/test/client/map/catalog.js +134 -41
- package/lib/test/client/map/catalog.js.map +1 -1
- package/lib/test/client/map/controls.js +7 -4
- package/lib/test/client/map/controls.js.map +1 -1
- package/lib/test/client/map/index.js +12 -0
- package/lib/test/client/map/index.js.map +1 -1
- package/lib/test/client/map/utils.js +67 -0
- package/lib/test/client/map/utils.js.map +1 -0
- package/package.json +5 -5
- package/extras/tours/map/favorite-views.js +0 -53
- package/lib/core/client/components/frame/KChart.vue +0 -60
- package/lib/core/client/components/input/KCodeInput.vue +0 -50
- package/lib/core/client/components/input/KTimeRangeChooser.vue +0 -109
- package/lib/core/client/components/time/KTimeRange.vue +0 -144
- package/lib/map/client/components/KFavoriteViews.vue +0 -217
|
@@ -1,13 +1,16 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
<div :style="widgetStyle">
|
|
2
|
+
<div id="information-box" class="column" :style="widgetStyle">
|
|
3
3
|
<div v-if="schema && properties" class="fit row">
|
|
4
|
-
<k-panel id="information-box-actions" class="q-pa-sm" :content="actions" direction="vertical" />
|
|
5
4
|
<k-scroll-area class="col" :maxHeight="widgetHeight">
|
|
6
5
|
<k-view class="q-pa-md" :schema="schema" :values="properties" :separators="true" />
|
|
7
6
|
</k-scroll-area>
|
|
8
7
|
</div>
|
|
9
8
|
<div v-else class="absolute-center">
|
|
10
|
-
<k-stamp
|
|
9
|
+
<k-stamp
|
|
10
|
+
icon="las la-exclamation-circle"
|
|
11
|
+
icon-size="3rem"
|
|
12
|
+
:text="$t('KInformationBox.NO_FEATURE_PROPERTIES')"
|
|
13
|
+
text-size="1rem" />
|
|
11
14
|
</div>
|
|
12
15
|
</div>
|
|
13
16
|
</template>
|
|
@@ -35,19 +38,49 @@ export default {
|
|
|
35
38
|
data () {
|
|
36
39
|
return {
|
|
37
40
|
schema: null,
|
|
38
|
-
properties: null
|
|
39
|
-
actions: []
|
|
41
|
+
properties: null
|
|
40
42
|
}
|
|
41
43
|
},
|
|
42
44
|
watch: {
|
|
43
|
-
feature:
|
|
44
|
-
|
|
45
|
+
feature: {
|
|
46
|
+
handler () {
|
|
47
|
+
this.refresh()
|
|
48
|
+
},
|
|
49
|
+
immediate: true
|
|
45
50
|
}
|
|
46
51
|
},
|
|
47
52
|
methods: {
|
|
53
|
+
refreshActions () {
|
|
54
|
+
this.$store.patch('window', {
|
|
55
|
+
widgetActions: [
|
|
56
|
+
{
|
|
57
|
+
id: 'center-view',
|
|
58
|
+
icon: 'las la-eye',
|
|
59
|
+
tooltip: this.$t('KInformationBox.CENTER_ON'),
|
|
60
|
+
visible: this.feature,
|
|
61
|
+
handler: this.onCenterOn
|
|
62
|
+
},
|
|
63
|
+
{
|
|
64
|
+
id: 'copy-properties',
|
|
65
|
+
icon: 'las la-clipboard',
|
|
66
|
+
tooltip: this.$t('KInformationBox.COPY_PROPERTIES'),
|
|
67
|
+
visible: this.properties,
|
|
68
|
+
handler: this.onCopyProperties
|
|
69
|
+
},
|
|
70
|
+
{
|
|
71
|
+
id: 'export-feature',
|
|
72
|
+
icon: 'img:statics/json-icon.svg',
|
|
73
|
+
tooltip: this.$t('KInformationBox.EXPORT_FEATURE'),
|
|
74
|
+
visible: this.feature,
|
|
75
|
+
handler: this.onExportFeature
|
|
76
|
+
}
|
|
77
|
+
]
|
|
78
|
+
})
|
|
79
|
+
},
|
|
48
80
|
refresh () {
|
|
49
81
|
this.properties = null
|
|
50
82
|
this.schema = null
|
|
83
|
+
this.refreshActions()
|
|
51
84
|
if (this.feature && this.layer) {
|
|
52
85
|
this.kActivity.centerOnSelection()
|
|
53
86
|
this.kActivity.addSelectionHighlight('information-box')
|
|
@@ -75,6 +108,8 @@ export default {
|
|
|
75
108
|
})
|
|
76
109
|
this.schema = schema
|
|
77
110
|
this.properties = properties
|
|
111
|
+
// Refresh the actions
|
|
112
|
+
this.refreshActions()
|
|
78
113
|
}
|
|
79
114
|
},
|
|
80
115
|
onCenterOn () {
|
|
@@ -92,10 +127,12 @@ export default {
|
|
|
92
127
|
},
|
|
93
128
|
onExportFeature () {
|
|
94
129
|
if (this.feature) {
|
|
95
|
-
const name = _.get(this.feature, 'name'
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
130
|
+
const name = _.get(this.feature, 'name') ||
|
|
131
|
+
_.get(this.feature, 'label') ||
|
|
132
|
+
_.get(this.feature, 'properties.name') ||
|
|
133
|
+
_.get(this.feature, 'properties.label') ||
|
|
134
|
+
_.get(this.layer, 'name') ||
|
|
135
|
+
_.get(this.layer, 'properties.name')
|
|
99
136
|
const file = name + '.geojson'
|
|
100
137
|
const status = exportFile(file, JSON.stringify(this.feature))
|
|
101
138
|
if (status) this.$toast({ type: 'error', message: this.$t('KInformationBox.FEATURE_EXPORTED', { file }) })
|
|
@@ -110,18 +147,6 @@ export default {
|
|
|
110
147
|
this.$options.components['k-view'] = this.$load('form/KView')
|
|
111
148
|
this.$options.components['k-stamp'] = this.$load('frame/KStamp')
|
|
112
149
|
},
|
|
113
|
-
created () {
|
|
114
|
-
// Registers the actions
|
|
115
|
-
this.actions = {
|
|
116
|
-
default: [
|
|
117
|
-
{ id: 'center-view', icon: 'las la-eye', tooltip: this.$t('KInformationBox.CENTER_ON'), handler: this.onCenterOn },
|
|
118
|
-
{ id: 'copy-properties', icon: 'las la-clipboard', tooltip: this.$t('KInformationBox.COPY_PROPERTIES'), handler: this.onCopyProperties },
|
|
119
|
-
{ id: 'export-feature', icon: 'img:statics/json-icon.svg', tooltip: this.$t('KInformationBox.EXPORT_FEATURE'), handler: this.onExportFeature }
|
|
120
|
-
]
|
|
121
|
-
}
|
|
122
|
-
// Refresh the component
|
|
123
|
-
this.refresh()
|
|
124
|
-
},
|
|
125
150
|
beforeDestroy () {
|
|
126
151
|
this.kActivity.removeSelectionHighlight('information-box')
|
|
127
152
|
}
|
|
@@ -1,10 +1,6 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
<div :style="widgetStyle">
|
|
3
|
-
<div class="
|
|
4
|
-
<q-resize-observer @resize="onResized" />
|
|
5
|
-
<k-panel id="mapillary-actions" class="q-pa-sm" :content="actions" direction="vertical" />
|
|
6
|
-
<div class="col" id="mapillary-container"></div>
|
|
7
|
-
</div>
|
|
2
|
+
<div id="mapillary-widget" class="column" :style="widgetStyle">
|
|
3
|
+
<div class="col" id="mapillary-container" />
|
|
8
4
|
</div>
|
|
9
5
|
</template>
|
|
10
6
|
|
|
@@ -24,13 +20,17 @@ export default {
|
|
|
24
20
|
mixins: [baseWidget],
|
|
25
21
|
data () {
|
|
26
22
|
return {
|
|
27
|
-
selection: this.$store.get('selection')
|
|
28
|
-
actions: []
|
|
23
|
+
selection: this.$store.get('selection')
|
|
29
24
|
}
|
|
30
25
|
},
|
|
31
26
|
watch: {
|
|
32
27
|
'selection.location': function () {
|
|
33
28
|
this.refresh()
|
|
29
|
+
},
|
|
30
|
+
widgetHeight: {
|
|
31
|
+
handler () {
|
|
32
|
+
if (this.mapillaryViewer) this.mapillaryViewer.resize()
|
|
33
|
+
}
|
|
34
34
|
}
|
|
35
35
|
},
|
|
36
36
|
methods: {
|
|
@@ -62,7 +62,22 @@ export default {
|
|
|
62
62
|
}
|
|
63
63
|
}
|
|
64
64
|
},
|
|
65
|
+
refreshActions () {
|
|
66
|
+
this.$store.patch('window', {
|
|
67
|
+
widgetActions: [
|
|
68
|
+
{
|
|
69
|
+
id: 'center',
|
|
70
|
+
icon: 'las la-eye',
|
|
71
|
+
tooltip: 'KMapillaryViewer.CENTER_ON',
|
|
72
|
+
visible: !_.isNil(this.imageId),
|
|
73
|
+
handler: this.centerMap
|
|
74
|
+
}
|
|
75
|
+
]
|
|
76
|
+
})
|
|
77
|
+
},
|
|
65
78
|
async refresh () {
|
|
79
|
+
// Refresh the actions
|
|
80
|
+
this.refreshActions()
|
|
66
81
|
if (_.has(this.selection, 'states.mapillary')) {
|
|
67
82
|
this.restoreStates()
|
|
68
83
|
if (this.imageId) await this.refreshView()
|
|
@@ -71,6 +86,8 @@ export default {
|
|
|
71
86
|
const location = this.selection.location
|
|
72
87
|
if (location) await this.moveCloseTo(location.lat, location.lng)
|
|
73
88
|
}
|
|
89
|
+
// Refresh the actions
|
|
90
|
+
this.refreshActions()
|
|
74
91
|
},
|
|
75
92
|
async moveCloseTo (lat, lon) {
|
|
76
93
|
// Query the images according a bbox that contains the given position
|
|
@@ -100,7 +117,7 @@ export default {
|
|
|
100
117
|
})
|
|
101
118
|
this.refreshView()
|
|
102
119
|
} else {
|
|
103
|
-
this.$toast({ type: 'negative', message: this.$t('
|
|
120
|
+
this.$toast({ type: 'negative', message: this.$t('KMapillaryViewer.NO_IMAGE_FOUND_CLOSE_TO') })
|
|
104
121
|
}
|
|
105
122
|
},
|
|
106
123
|
centerMap () {
|
|
@@ -124,23 +141,12 @@ export default {
|
|
|
124
141
|
this.bearing = await this.mapillaryViewer.getBearing()
|
|
125
142
|
this.centerMap()
|
|
126
143
|
this.kActivity.updateSelectionHighlight('mapillary', this.getMarkerFeature())
|
|
127
|
-
},
|
|
128
|
-
onResized () {
|
|
129
|
-
if (this.mapillaryViewer) this.mapillaryViewer.resize()
|
|
130
144
|
}
|
|
131
145
|
},
|
|
132
146
|
beforeCreate () {
|
|
133
147
|
// laod the required components
|
|
134
148
|
this.$options.components['k-panel'] = this.$load('frame/KPanel')
|
|
135
149
|
},
|
|
136
|
-
created () {
|
|
137
|
-
// Registers the actions
|
|
138
|
-
this.actions = {
|
|
139
|
-
default: [
|
|
140
|
-
{ id: 'center', icon: 'las la-eye', tooltip: this.$t('KMapillaryWidget.CENTER_ON'), handler: this.centerMap }
|
|
141
|
-
]
|
|
142
|
-
}
|
|
143
|
-
},
|
|
144
150
|
mounted () {
|
|
145
151
|
// Create the viewer
|
|
146
152
|
this.mapillaryViewer = new Viewer({
|