// Small hand-authored monoline SVG icons for the sidebar, so the app // doesn't need to vendor an icon font/library for four glyphs. export const LAYERS_ICON = ` `; export const GPX_ICON = ` `; export const RADAR_ICON = ` `; export const GNSS_ICON = ` `; export const NEW_FOLDER_ICON = ` `; export const UPLOAD_ICON = ` `; // Shown next to each file in the GPX tree, indicating whether it has // waypoints, a track, or both. export const WAYPOINT_ICON = ` `; export const TRACK_ICON = GPX_ICON; // Same shape as TRACK_ICON, dashed — a route is planned rather than // recorded, the same visual convention most map apps use for the // distinction. export const ROUTE_ICON = ` `; // A rounded-square badge — used as the map marker for individual waypoints, // tinted by category color via icon-color (see gpx.js). Not a plain dot, // which blended in with a base map style's own small circular POI icons, // and not a pin/teardrop either — a rounded square is the National Park // Service's own convention for framing these exact category symbols // (POI_ICONS below), so pairing the two looks native rather than like two // mismatched icon styles. Centered on the coordinate (no tip to anchor at), // which also means the category glyph on top needs no offset — both layers // just share the same center anchor at [0, 0]. export const MAP_MARKER_ICON = ` `; // POI category glyphs (park4night/OsmAnd exports), keyed by the OsmAnd icon // name a file's extension carries — a small curated set for // the categories park4night actually uses (see waypoint_style in // lib/maptool/gpx.rb), not an exhaustive OsmAnd icon set. // // These are the National Park Service's own map pictograms, not // hand-drawn — a professional, widely-recognized icon set built for // exactly this job (small monochrome map markers) beats reinventing "fuel // pump"/"picnic table" glyphs from scratch. Pulled from // github.com/nationalparkservice/npmap5-plugins's bundled `symbol-library` // (src/-22.svg) — an actively-maintained monorepo that's the // designated replacement for the same org's older standalone // `symbol-library` repo (confirmed by its maintainer: // github.com/nationalparkservice/npmap5-plugins/issues/4), with a much // larger icon vocabulary. CC0-licensed (public domain) — no attribution // required. // // All filled shapes — these render at ~14px on the map, where a hairline // stroke disappears — and rasterized (non-SDF; a plain colored raster, not // tinted at render time, see gpx.js's _registerCategoryGlyphs) so only the // alpha shape matters, not the actual `currentColor` value. // src/bicycle-trail-22.svg — pulled out to its own constant since it's also // used unrasterized, inline, as PARK4NIGHT_TAGS.vtt below. const BICYCLE_TRAIL_ICON = ` `; export const POI_ICONS = { // src/parking-22.svg amenity_parking: ` `, // src/campground-22.svg tourism_camp_site: ` `, // src/picnic-area-22.svg leisure_picnic_table: ` `, // src/gas-station-22.svg amenity_fuel: ` `, // src/lodging-22.svg tourism_hotel: ` `, // src/wilderness-22.svg forest: ` `, // src/bicycle-trail-22.svg sport_cycling: BICYCLE_TRAIL_ICON, }; // National Park Service map symbols (same source/license as POI_ICONS above) // used as small inline glyphs next to a park4night waypoint's Services/ // Activities tags (see PARK4NIGHT_TAGS and formatDescription in // public/js/gpx.js) — pulled into named constants first since a few codes // share the same real-world facility (eau_noire/eau_usee are both a dump // station, gaz/gpl are both a propane refill, peche/peche_pied are both // fishing) and BICYCLE_TRAIL_ICON is also POI_ICONS.sport_cycling above. const PETS_ON_LEASH_ICON = ` `; const SHOWERS_ICON = ` `; const SANITARY_DISPOSAL_ICON = ` `; const ELECTRICAL_HOOKUP_ICON = ` `; const PROPANE_ICON = ` `; const LAUNDRY_ICON = ` `; const SWIMMING_ICON = ` `; const DRINKING_WATER_ICON = ` `; const TRASH_DUMPSTER_ICON = ` `; const RESTROOMS_ICON = ` `; const RIVER_RAFTING_ICON = ` `; const CLIMBING_ICON = ` `; const PLAYGROUND_ICON = ` `; const MOTOR_BIKE_TRAIL_ICON = ` `; const FISHING_ICON = ` `; const SCENIC_VIEWPOINT_ICON = ` `; const WALKING_ICON = ` `; const GUIDED_TOURS_ICON = ` `; const WIND_SURFING_ICON = ` `; // These three have no equivalent in the older standalone symbol-library // repo (see POI_ICONS above) — pulled from npmap5-plugins' bundled, // actively-maintained symbol-library instead (CC0-licensed), which has a // much larger vocabulary. const WIFI_ICON = ` `; const CELLULAR_SIGNAL_ICON = ` `; const WINTER_RECREATION_AREA_ICON = ` `; // park4night's fixed vocabulary of Services/Activities codes (the ones // p4n2gpx exports actually use — not necessarily park4night's entire API), // each with a human label (always shown) and an icon where the NPS set has // a reasonable match. formatDescription (public/js/gpx.js) reads this; // an unrecognized code just renders as its raw text, same as before this // existed, so nothing p4n2gpx might add later is ever hidden. export const PARK4NIGHT_TAGS = { // Services animaux: { icon: PETS_ON_LEASH_ICON, label: "Pets allowed" }, boulangerie: { label: "Bakery nearby" }, caravaneige: { icon: WINTER_RECREATION_AREA_ICON, label: "Winter/snow camping" }, donnees_mobile: { icon: CELLULAR_SIGNAL_ICON, label: "Mobile data coverage" }, douche: { icon: SHOWERS_ICON, label: "Showers" }, eau_noire: { icon: SANITARY_DISPOSAL_ICON, label: "Black water disposal" }, eau_usee: { icon: SANITARY_DISPOSAL_ICON, label: "Grey water disposal" }, electricite: { icon: ELECTRICAL_HOOKUP_ICON, label: "Electricity" }, gaz: { icon: PROPANE_ICON, label: "Gas/propane refill" }, gpl: { icon: PROPANE_ICON, label: "LPG refill" }, lavage: { label: "Vehicle wash" }, laverie: { icon: LAUNDRY_ICON, label: "Laundry" }, piscine: { icon: SWIMMING_ICON, label: "Swimming pool" }, point_eau: { icon: DRINKING_WATER_ICON, label: "Drinking water" }, poubelle: { icon: TRASH_DUMPSTER_ICON, label: "Trash disposal" }, wc_public: { icon: RESTROOMS_ICON, label: "Public toilet" }, wifi: { icon: WIFI_ICON, label: "Wi-Fi" }, // Activities baignade: { icon: SWIMMING_ICON, label: "Swimming" }, eaux_vives: { icon: RIVER_RAFTING_ICON, label: "Whitewater sports" }, escalade: { icon: CLIMBING_ICON, label: "Climbing" }, jeux_enfants: { icon: PLAYGROUND_ICON, label: "Playground" }, moto: { icon: MOTOR_BIKE_TRAIL_ICON, label: "Motorcycling" }, peche: { icon: FISHING_ICON, label: "Fishing" }, peche_pied: { icon: FISHING_ICON, label: "Shore fishing" }, point_de_vue: { icon: SCENIC_VIEWPOINT_ICON, label: "Scenic viewpoint" }, rando: { icon: WALKING_ICON, label: "Hiking" }, visites: { icon: GUIDED_TOURS_ICON, label: "Sightseeing" }, vtt: { icon: BICYCLE_TRAIL_ICON, label: "Mountain biking" }, windsurf: { icon: WIND_SURFING_ICON, label: "Windsurfing" }, }; export const LIVETRACK_ICON = ` `;