Add road type color mode to route visualization
Extract highway=* tags from BRouter tiledesc messages alongside surface data and add a new "Road Type" color mode that colors the route polyline and elevation chart by OSM highway classification (cycleway, residential, path, etc.). Includes color palette, legend, hover labels, i18n (EN+DE), unit tests for tag extraction, and E2E tests. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
f4f0cbc4c8
commit
1e2f6beded
18 changed files with 690 additions and 21 deletions
|
|
@ -32,7 +32,14 @@ const MOCK_ROUTE_3WP = {
|
|||
segmentBoundaries: [0, 4],
|
||||
totalLength: 3200,
|
||||
totalAscend: 8,
|
||||
surfaces: [],
|
||||
surfaces: [
|
||||
"asphalt", "asphalt", "cobblestone", "cobblestone", "gravel",
|
||||
"gravel", "asphalt", "asphalt", "asphalt", "asphalt",
|
||||
],
|
||||
highways: [
|
||||
"residential", "residential", "cycleway", "cycleway", "path",
|
||||
"path", "tertiary", "tertiary", "residential", "residential",
|
||||
],
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
@ -63,7 +70,12 @@ const MOCK_ROUTE_2WP = {
|
|||
segmentBoundaries: [0],
|
||||
totalLength: 3800,
|
||||
totalAscend: 6,
|
||||
surfaces: [],
|
||||
surfaces: [
|
||||
"asphalt", "asphalt", "gravel", "gravel", "asphalt", "asphalt",
|
||||
],
|
||||
highways: [
|
||||
"secondary", "secondary", "cycleway", "cycleway", "residential", "residential",
|
||||
],
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue