File tree Expand file tree Collapse file tree 1 file changed +6
-3
lines changed
packages/clients/dish/src/utils Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -5,6 +5,7 @@ import { alkisWms } from '../servicesConstants'
55import { alkisMinZoom } from '../mapConfigurations/layerConfigIntern'
66
77export function watchSearchResultForAlkisSearch ( instance : MapInstance ) {
8+ console . log ( '### watchSearchResultForAlkisSearch initialized' )
89 instance . subscribe ( 'plugin/addressSearch/chosenAddress' , ( chosenAddress ) => {
910 if ( chosenAddress === null ) {
1011 return
@@ -27,9 +28,11 @@ export function watchSearchResultForAlkisSearch(instance: MapInstance) {
2728 )
2829 ) {
2930 const zoomLevel = instance . $store . getters [ 'plugin/zoom/zoomLevel' ]
30- if ( zoomLevel < alkisMinZoom ) {
31- instance . $store . getters . map . getView ( ) . setZoom ( alkisMinZoom )
32- }
31+
32+ instance . $store . getters . map
33+ . getView ( )
34+ . setZoom ( zoomLevel <= alkisMinZoom ? alkisMinZoom : zoomLevel )
35+
3336 const activeMaskIds =
3437 instance . $store . getters [ 'plugin/layerChooser/activeMaskIds' ]
3538 if ( ! activeMaskIds . includes ( alkisWms ) ) {
You can’t perform that action at this time.
0 commit comments