septima-widget 3.13.5 → 3.13.7
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/package.json +1 -1
- package/widgetapi.mjs +10 -3
package/package.json
CHANGED
package/widgetapi.mjs
CHANGED
|
@@ -6,7 +6,7 @@ export default class WidgetAPI {
|
|
|
6
6
|
|
|
7
7
|
_target = null
|
|
8
8
|
|
|
9
|
-
VERSION = '3.13.
|
|
9
|
+
VERSION = '3.13.7'
|
|
10
10
|
|
|
11
11
|
isReady = false
|
|
12
12
|
|
|
@@ -16,7 +16,7 @@ export default class WidgetAPI {
|
|
|
16
16
|
}
|
|
17
17
|
|
|
18
18
|
async _load(target, config, options) {
|
|
19
|
-
const { load } = await import('https://widget.cdn.septima.dk/3.13.
|
|
19
|
+
const { load } = await import('https://widget.cdn.septima.dk/3.13.7/core/load.mjs')
|
|
20
20
|
this._widget = await load(target, config, options, this)
|
|
21
21
|
this.on('controlsready', () => {
|
|
22
22
|
this._controlsReady()
|
|
@@ -203,6 +203,13 @@ export default class WidgetAPI {
|
|
|
203
203
|
this._controlsReady(() => this._widget.reloadLayer(layerId))
|
|
204
204
|
}
|
|
205
205
|
|
|
206
|
+
getLayers(filter) {
|
|
207
|
+
if (this._controlsAreReady) {
|
|
208
|
+
return this._widget.getLayers(filter)
|
|
209
|
+
}
|
|
210
|
+
return []
|
|
211
|
+
}
|
|
212
|
+
|
|
206
213
|
updateLayerParams(layerId, params) {
|
|
207
214
|
this._controlsReady(() => this._widget.updateLayerParams(layerId, params))
|
|
208
215
|
}
|
|
@@ -229,7 +236,7 @@ export default class WidgetAPI {
|
|
|
229
236
|
|
|
230
237
|
transform(geojson, options, callback) {
|
|
231
238
|
this._controlsReady(async () => {
|
|
232
|
-
const { transform } = await import('https://widget.cdn.septima.dk/3.13.
|
|
239
|
+
const { transform } = await import('https://widget.cdn.septima.dk/3.13.7/core/load.mjs')
|
|
233
240
|
if (callback) {
|
|
234
241
|
callback(transform(geojson, options))
|
|
235
242
|
} else {
|