Move the Wikipedia layer into its own "Overlays" panel
Wikipedia doesn't belong inside "Tracks & Points" — that panel is for files you add/remove/reorder, while Wikipedia is a live layer with nothing to manage, just on/off. Gave it its own sidebar panel (#overlays-panel, same shell as LiveTrackPanelControl) instead, sized to hold more such checklist-only layers later without a redesign. Moved all the wiki layer logic out of GpxPanelControl into a new OverlaysControl (public/js/overlays.js). svgToImageData/badgeImageId/ escapeHtml are now exported from gpx.js so it doesn't have to reimplement them — the same three helpers a second overlay would also need.
This commit is contained in:
1 parent
787df5478d
commit
c5b4a9ffb2
6 files changed
+257
-187
No files matched your search
@@ -7,6 +7,16 @@ export const LAYERS_ICON = `
|
||||
<path d="M2 14l10 6 10-6"/>
|
||||
</svg>`;
|
||||
|
||||
// Two overlapping circles — distinct from LAYERS_ICON's stacked-planes
|
||||
// look (that one picks a *base* map; this one is for the sidebar flyout
|
||||
// toggling live overlay layers, e.g. Wikipedia, on top of whichever base
|
||||
// map is showing) while still reading as "layers combining."
|
||||
export const OVERLAYS_ICON = `
|
||||
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.6" stroke-linejoin="round" stroke-linecap="round">
|
||||
<circle cx="9" cy="12" r="6"/>
|
||||
<circle cx="15" cy="12" r="6"/>
|
||||
</svg>`;
|
||||
|
||||
export const HILLSHADE_ICON = `
|
||||
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.6" stroke-linejoin="round" stroke-linecap="round">
|
||||
<path d="M2 18 9 7l3.5 5.5L15 9l7 9z"/>
|
||||
|
||||
Reference in new issue
Block a user