Browse Source

Keep auto-center enabled by default

Previously auto-center was turned off after the first GPS fix.
Now it stays on, keeping the map centered on the player's position.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
master
HikeMap User 1 month ago
parent
commit
f75f178aeb
  1. 6
      index.html

6
index.html

@ -4208,11 +4208,7 @@
if (gpsFirstFix) {
map.setView([lat, lng], 17);
gpsFirstFix = false;
// After first fix, turn off auto-center (user must manually enable)
autoCenterMode = false;
const btn = document.getElementById('autoCenterBtn');
btn.textContent = 'Auto-Center: OFF';
btn.classList.remove('active');
// Keep auto-center on by default
} else if (autoCenterMode) {
map.setView([lat, lng], map.getZoom());
}

Loading…
Cancel
Save