No description
  • JavaScript 96.9%
  • CSS 2.9%
  • HTML 0.2%
Find a file
Matt c701463283 Add theme registry for custom protomaps flavor support
Introduces src/themes/registry.js with:
- getTheme(id) - lookup theme config by ID
- getThemeColors(id) - get flavor object (namedTheme for built-ins, custom colors for others)
- getThemeSprite(id) - get sprite URL with fallback for custom themes
- themeList() - list available themes for UI

Updates MapView.jsx:
- Import registry functions instead of namedTheme directly
- buildStyle() uses getThemeColors() and getThemeSprite()
- Overlay add functions use isCurrentThemeDark() helper that checks
  registry dark flag instead of string comparison

Reference files:
- dark-flavor-reference.json - full namedTheme('dark') output (73 flat keys + pois + landcover)
- light-flavor-reference.json - full namedTheme('light') output
- README.md - schema documentation for creating custom themes

This is a refactor only - light/dark themes render identically to before.
Custom themes can now be added to registry.js with full flavor objects.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-05-01 15:27:01 +00:00
public feat: initial scaffold — Vite + React + Tailwind + MapLibre 2026-04-20 04:47:44 +00:00
src Add theme registry for custom protomaps flavor support 2026-05-01 15:27:01 +00:00
.gitignore chore: add *.bak* to .gitignore 2026-04-27 02:50:54 +00:00
deploy.sh feat: search, multi-stop routing, and route display 2026-04-20 16:50:53 +00:00
eslint.config.js feat: initial scaffold — Vite + React + Tailwind + MapLibre 2026-04-20 04:47:44 +00:00
index.html feat(navi): GPS origin + place detail panel + basic actions 2026-04-20 20:59:18 +00:00
LICENSE Initial commit 2026-04-20 06:42:56 +02:00
package-lock.json style(radial): match Navi color palette in light and dark themes 2026-04-26 06:17:48 +00:00
package.json style(radial): match Navi color palette in light and dark themes 2026-04-26 06:17:48 +00:00
postcss.config.js feat: initial scaffold — Vite + React + Tailwind + MapLibre 2026-04-20 04:47:44 +00:00
README.md Initial commit 2026-04-20 06:42:56 +02:00
vite.config.js feat: search, multi-stop routing, and route display 2026-04-20 16:50:53 +00:00

navi

Navi — self-hosted navigation web frontend for Echo6