Change default routing profile to fastbike, move hiking to end
The app is primarily for cycling. Default profile is now "Cycling (fast)" instead of "Hiking". Profile order: fastbike, safety, shortest, car, trekking. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
0ff04aaec7
commit
be36a5f650
3 changed files with 4 additions and 4 deletions
|
|
@ -2,7 +2,7 @@ import { useEffect, useState, useCallback } from "react";
|
|||
import { useTranslation } from "react-i18next";
|
||||
import type { YjsState } from "~/lib/use-yjs";
|
||||
|
||||
const PROFILE_IDS = ["trekking", "fastbike", "safety", "shortest", "car"] as const;
|
||||
const PROFILE_IDS = ["fastbike", "safety", "shortest", "car", "trekking"] as const;
|
||||
|
||||
interface ProfileSelectorProps {
|
||||
yjs: YjsState;
|
||||
|
|
@ -10,7 +10,7 @@ interface ProfileSelectorProps {
|
|||
|
||||
export function ProfileSelector({ yjs }: ProfileSelectorProps) {
|
||||
const { t } = useTranslation("planner");
|
||||
const [profile, setProfile] = useState("trekking");
|
||||
const [profile, setProfile] = useState("fastbike");
|
||||
|
||||
useEffect(() => {
|
||||
const update = () => {
|
||||
|
|
|
|||
|
|
@ -91,7 +91,7 @@ export function useRouting(yjs: YjsState | null) {
|
|||
headers: { "Content-Type": "application/json" },
|
||||
body: JSON.stringify({
|
||||
waypoints,
|
||||
profile: (yjs.routeData.get("profile") as string) ?? "trekking",
|
||||
profile: (yjs.routeData.get("profile") as string) ?? "fastbike",
|
||||
noGoAreas: noGoAreas.length > 0 ? noGoAreas : undefined,
|
||||
}),
|
||||
});
|
||||
|
|
|
|||
|
|
@ -43,7 +43,7 @@ test.describe("Planner", () => {
|
|||
|
||||
const profileSelect = page.getByLabel("Profile:");
|
||||
await expect(profileSelect).toBeVisible();
|
||||
await expect(profileSelect).toHaveValue("trekking");
|
||||
await expect(profileSelect).toHaveValue("fastbike");
|
||||
});
|
||||
|
||||
test("session has export GPX button", async ({ page, request }) => {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue