Spaces:
Running
Running
| import { CONFIG } from "./config.js"; | |
| export const TRACKS = ["Backyard", "Wood"]; | |
| export function normalizeTrack(tags) { | |
| if (!Array.isArray(tags)) return null; | |
| for (const t of tags) { | |
| if (typeof t !== "string") continue; | |
| const hit = CONFIG.trackMap[t.toLowerCase()]; | |
| if (hit) return hit; | |
| } | |
| return null; | |
| } | |