@trailstash/ultra 3.4.4 → 3.4.6

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.
@@ -47,7 +47,7 @@ export class UltraMap extends HTMLElement {
47
47
  querySources: ["ultra"],
48
48
  options: {},
49
49
  controls: [],
50
- fitBounds: false,
50
+ fitBounds: undefined,
51
51
  queryProviders,
52
52
  persistState: false,
53
53
  };
@@ -281,11 +281,15 @@ export class UltraMap extends HTMLElement {
281
281
  }
282
282
 
283
283
  get #fitBounds() {
284
- if (this.fitBounds) {
284
+ if (this.fitBounds !== undefined) {
285
285
  return this.fitBounds;
286
286
  }
287
287
  const queryProvider = this.queryProviders[this.type];
288
- if (queryProvider && queryProvider.fitBounds) {
288
+ if (
289
+ queryProvider &&
290
+ queryProvider.fitBounds &&
291
+ setQueryBounds(this.query, this.refs.mapLibre.bounds) === this.query
292
+ ) {
289
293
  return queryProvider.fitBounds;
290
294
  }
291
295
  return this.fitBounds;
package/docs/index.md CHANGED
@@ -54,7 +54,7 @@ style:
54
54
  }
55
55
  ```
56
56
 
57
- For more examples, see the [Examples](./Examples) and [MapLibre Examples](./MapLibre Examples)
57
+ For more examples, see the [Examples](./Examples) and [MapLibre Examples](./MapLibre-Examples)
58
58
  sections.
59
59
 
60
60
  ## Configuration
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "publishConfig": {
4
4
  "access": "public"
5
5
  },
6
- "version": "3.4.4",
6
+ "version": "3.4.6",
7
7
  "description": "A web based tool for making MapLibre GL maps with data from sources such as Overpass, GeoJSON, GPX, KML, TCX, etc",
8
8
  "main": "index.js",
9
9
  "scripts": {