See how hilly a hand-drawn route is BEFORE riding it.
- parseRouteGPX reads <ele>; GPS.routeElevStats computes cumulative distance,
grade-to-next, ascent/descent (1m hysteresis) and max grade over smoothed
elevations (filterAndSmoothAlt kills SRTM vertical noise).
- Route preview screen (tap a route name): map with a wide colored casing +
tappable altitude/grade points, elevation profile chart (steep >8% in red),
length/ascent/descent/max-grade, fullscreen expand/collapse.
- Casing colored by slope (deg: lime <2, yellow 2-4, red 4-6, black >6) or by
elevation (green->yellow->brown), toggled with an on-map ∡/⛰ button. Casing
drawn in a dedicated pane below the overlay pane, so a recorded track stays on
top; the same toggle is on the track-detail map too.
- fetchElevations tries, in order: GPXZ (Copernicus GLO-30, key from GPS
settings — stored in localStorage, never in git) -> open-elevation (SRTM) ->
open-meteo -> OpenTopoData (keyless). Import auto-fetches elevations.
- db.js: updateRoutePoints persists fetched elevations into points_json;
getRoutes reports hasEle. Route points are now {lat, lon, ele?}.
Native prompt at route import replaced with in-app appPrompt.
38 lines
1 KiB
JSON
38 lines
1 KiB
JSON
{
|
|
"$schema": "https://raw.githubusercontent.com/nicegui/tauri-v2/refs/heads/main/tooling/cli/schema.json",
|
|
"productName": "BalDav",
|
|
"version": "0.1.400",
|
|
"identifier": "dev.baldav.app",
|
|
"build": {
|
|
"frontendDist": "../frontend"
|
|
},
|
|
"app": {
|
|
"withGlobalTauri": true,
|
|
"security": {
|
|
"csp": "default-src 'self' 'unsafe-inline' 'unsafe-eval'; connect-src 'self' https://4aiman.top https://*.tile.openstreetmap.org https://*.tile.thunderforest.com https://api.open-meteo.com https://wttr.in http://192.168.1.1:88; img-src 'self' blob: data: https://*.tile.openstreetmap.org https://*.tile.thunderforest.com"
|
|
},
|
|
"windows": [
|
|
{
|
|
"title": "BalDav",
|
|
"width": 400,
|
|
"height": 700,
|
|
"resizable": true
|
|
}
|
|
]
|
|
},
|
|
"bundle": {
|
|
"active": true,
|
|
"targets": "all",
|
|
"icon": [
|
|
"icons/icon.png"
|
|
],
|
|
"resources": {
|
|
"../frontend/data/products_seed.db": "data/products_seed.db"
|
|
}
|
|
},
|
|
"plugins": {
|
|
"sql": {
|
|
"preload": ["sqlite:baldav.db"]
|
|
}
|
|
}
|
|
}
|