@maplibre/maplibre-gl-geocoder
Advanced tools
Comparing version 1.7.0 to 1.7.1
@@ -152,2 +152,7 @@ import MaplibreGl, { FlyToOptions, Marker, Popup, MarkerOptions, Map } from 'maplibre-gl'; | ||
/** | ||
* If setting promiximity, this is the minimum zoom level at which to start taking it into account. | ||
* @default 9 | ||
*/ | ||
proximityMinZoom?: number; | ||
/** | ||
* A function that specifies how the selected result should be rendered in the search bar. HTML tags in the output string will not be rendered. Defaults to `(item) => item.place_name`. | ||
@@ -154,0 +159,0 @@ * @example |
@@ -163,2 +163,7 @@ import Typeahead from "suggestions-list"; | ||
/** | ||
* If setting promiximity, this is the minimum zoom level at which to start taking it into account. | ||
* @default 9 | ||
*/ | ||
proximityMinZoom?: number; | ||
/** | ||
* A function that specifies how the selected result should be rendered in the search bar. HTML tags in the output string will not be rendered. Defaults to `(item) => item.place_name`. | ||
@@ -276,2 +281,3 @@ * @example | ||
clearOnBlur: false, | ||
proximityMinZoom: 9, | ||
@@ -1023,3 +1029,3 @@ getItemValue: (item) => { | ||
} | ||
if (this._map.getZoom() > 9) { | ||
if (this._map.getZoom() > this.options.proximityMinZoom) { | ||
const center = this._map.getCenter().wrap(); | ||
@@ -1026,0 +1032,0 @@ this.setProximity({ longitude: center.lng, latitude: center.lat }); |
{ | ||
"name": "@maplibre/maplibre-gl-geocoder", | ||
"version": "1.7.0", | ||
"version": "1.7.1", | ||
"description": "A geocoder control for Maplibre GL JS", | ||
@@ -9,3 +9,2 @@ "main": "dist/maplibre-gl-geocoder.js", | ||
"style": "dist/maplibre-gl-geocoder.css", | ||
"type": "module", | ||
"scripts": { | ||
@@ -43,21 +42,21 @@ "watch": "rollup --configPlugin @rollup/plugin-typescript -c --watch", | ||
"devDependencies": { | ||
"@eslint/js": "^9.9.0", | ||
"@rollup/plugin-commonjs": "^26.0.1", | ||
"@rollup/plugin-node-resolve": "^15.2.3", | ||
"@rollup/plugin-typescript": "^11.1.6", | ||
"@eslint/js": "^9.17.0", | ||
"@rollup/plugin-commonjs": "^28.0.2", | ||
"@rollup/plugin-node-resolve": "^16.0.0", | ||
"@rollup/plugin-typescript": "^12.1.2", | ||
"@types/eslint__js": "^8.42.3", | ||
"@types/jest": "^29.5.12", | ||
"@types/jest": "^29.5.14", | ||
"@types/lodash.debounce": "^4.0.9", | ||
"@types/xtend": "^4.0.6", | ||
"eslint": "^9.9.0", | ||
"eslint": "^9.17.0", | ||
"jest": "^29.7.0", | ||
"jest-environment-jsdom": "^29.7.0", | ||
"maplibre-gl": "^4.5.1", | ||
"rollup": "^4.21.0", | ||
"maplibre-gl": "^5.0.0", | ||
"rollup": "^4.30.0", | ||
"rollup-plugin-dts": "^6.1.1", | ||
"ts-jest": "^29.2.4", | ||
"ts-node": "^10.9.2", | ||
"typedoc": "^0.26.5", | ||
"typescript": "^5.5.4", | ||
"typescript-eslint": "^8.1.0" | ||
"typedoc": "^0.27.6", | ||
"typescript": "^5.7.2", | ||
"typescript-eslint": "^8.19.0" | ||
}, | ||
@@ -64,0 +63,0 @@ "peerDependencies": { |
@@ -1,2 +0,2 @@ | ||
## Maplibre GL Geocoder | ||
## MapLibre GL Geocoder | ||
@@ -3,0 +3,0 @@ A geocoder control for [maplibre-gl-js](https://github.com/maplibre/maplibre-gl-js). |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
28242
7596
653642
No