MapView not centered, zoom working different, black box

347
2
03-12-2024 02:02 PM
GregoryBologna
Occasional Contributor II

Since 4.26, the class "esri-ui calcite-theme-light" was replaced with "esri-ui calcite-mode-light" and now the top inset pushes the widgets down. Changing the class back to version with "theme" fixes this. Could it possibly be that the wrong class was used here for versions > 4.25?

4.23 to 4.25
<div class="esri-ui calcite-theme-light" style="inset: 55px 0px 0px;">

4.26 through 4.29
<div class="esri-ui calcite-mode-light" lang="en-US" style="inset: 55px 0px 0px;">

Also,

1. Centering a featureLayer by lat\lon is no longer accurate. Looking at the featureLayer above, it looks like the right side widgets are preventing it from centering seeing that the featureLayer is aligned with the last widget. 

2. Initial zoom is too close. 

At some point in the past week, zoom 12 is now much too close. We have made no changes since July 2023.

let view = new MapView({
map: map,
container: 'aerialMapViewer',
center: [lon, lat],
zoom: 12, <-------------------- NOW TOO CLOSE
padding: padding,
constraints: {
maxScale: 0,
minScale: 300000
}
});

3. There is a large black box in an area of the map.

 

 

0 Kudos
2 Replies
GregoryBologna
Occasional Contributor II

getItemAt is no longer an issue.

0 Kudos
JohnGrayson
Esri Regular Contributor

I just tried with previous versions of the api (back to 4.7) and it seems like it's always been zero based.  It always helps to track down these types of use cases if you share a CodePen (or similar) showing the issue.

https://codepen.io/john-grayson/pen/eYozyrY

0 Kudos