Increase sidebar width, improve auto-panning #30

Merged
raucao merged 2 commits from ui/autopan into feature/app_menu 2026-03-17 09:20:46 +00:00
Showing only changes of commit 8877a9e1c8 - Show all commits

View File

@@ -647,10 +647,10 @@ export default class MapComponent extends Component {
// = sidebarWidth/2 + totalWidth/2
// Map Center is totalWidth/2
// Offset = sidebarWidth/2 (to the right)
const offsetPixels = sidebarWidth / 2;
const offsetMapUnits = offsetPixels * resolution;
// We want pin at center + offset.
// So map center must be pin - offset.
// X increases to the right.