Skip to content

Commit 70de9ff

Browse files
committed
fix: keep debug and logs on top-level routes (#100928)
1 parent 598a6ff commit 70de9ff

4 files changed

Lines changed: 8 additions & 8 deletions

File tree

ui/src/app-navigation.test.ts

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,8 +41,6 @@ const SETTINGS_ROUTE_PATHS = [
4141
},
4242
{ routeId: "worktrees", path: "/settings/worktrees", alias: "/worktrees" },
4343
{ routeId: "ai-agents", path: "/settings/ai-agents", alias: "/ai-agents" },
44-
{ routeId: "debug", path: "/settings/debug", alias: "/debug" },
45-
{ routeId: "logs", path: "/settings/logs", alias: "/logs" },
4644
] as const satisfies readonly { routeId: RouteId; path: string; alias: string }[];
4745

4846
const leadingSlashNormalizerCases = [
@@ -200,6 +198,8 @@ describe("pathForRoute", () => {
200198
it("returns correct path without base", () => {
201199
expect(pathForRoute("chat")).toBe("/chat");
202200
expect(pathForRoute("overview")).toBe("/overview");
201+
expect(pathForRoute("debug")).toBe("/debug");
202+
expect(pathForRoute("logs")).toBe("/logs");
203203
});
204204

205205
it("prepends base path", () => {
@@ -214,6 +214,8 @@ describe("routeIdFromPath", () => {
214214
expect(routeIdFromPath("/overview")).toBe("overview");
215215
expect(routeIdFromPath("/activity")).toBe("activity");
216216
expect(routeIdFromPath("/sessions")).toBe("sessions");
217+
expect(routeIdFromPath("/debug")).toBe("debug");
218+
expect(routeIdFromPath("/logs")).toBe("logs");
217219
expect(routeIdFromPath("/dreaming")).toBe("dreams");
218220
expect(routeIdFromPath("/dreams")).toBe("dreams");
219221
});

ui/src/app-route-paths.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,8 @@ export const APP_ROUTE_DEFINITIONS = {
1919
instances: { path: "/instances" },
2020
sessions: { path: "/sessions" },
2121
usage: { path: "/usage" },
22-
debug: { path: "/settings/debug", aliases: ["/debug"] },
23-
logs: { path: "/settings/logs", aliases: ["/logs"] },
22+
debug: { path: "/debug" },
23+
logs: { path: "/logs" },
2424
"skill-workshop": { path: "/skills/workshop" },
2525
skills: { path: "/skills" },
2626
cron: { path: "/cron" },

ui/src/pages/debug/route.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,7 @@ import { html } from "lit";
33

44
export const page = definePage({
55
id: "debug",
6-
path: "/settings/debug",
7-
aliases: ["/debug"],
6+
path: "/debug",
87
component: () =>
98
import("./debug-page.ts").then(() => ({
109
header: true,

ui/src/pages/logs/route.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,7 @@ import { html } from "lit";
33

44
export const page = definePage({
55
id: "logs",
6-
path: "/settings/logs",
7-
aliases: ["/logs"],
6+
path: "/logs",
87
component: () =>
98
import("./logs-page.ts").then(() => ({
109
header: true,

0 commit comments

Comments
 (0)