T1: Finalize empty states & onboarding — geofence point format fix

- Handle both [lat, lng] array and {lat, lng} object formats in geofence rendering
- All empty states verified: consistent icon + heading + description + CTA pattern
- Onboarding welcome overlay with localStorage flag
This commit is contained in:
2026-05-20 23:00:07 -04:00
parent 51f9bcfacd
commit 1a87427295
+4 -1
View File
@@ -6906,7 +6906,10 @@
geofences.forEach(gf => {
const points = typeof gf.points === 'string' ? JSON.parse(gf.points) : gf.points;
const latlngs = points.map(p => [p.lat, p.lng]);
// Handle both [lat, lng] arrays and {lat, lng} objects
const latlngs = points.map(p =>
Array.isArray(p) ? [p[0], p[1]] : [p.lat, p.lng]
);
const polygon = L.polygon(latlngs, {
color: gf.color || '#3388ff',
fillColor: gf.color || '#3388ff',