Skip to content

Dodaios is an open-source agent OS for your desktop: it runs your coding agents, browser and apps by voice or chat, on your own machine. Formerly Personal Jarvis.

feat(ui): add a Home button to the window caption

rubenluetke10-beep07e70708141b
diff --git a/jarvis/ui/web/frontend/src/components/layout/SectionNavButtons.test.tsx b/jarvis/ui/web/frontend/src/components/layout/SectionNavButtons.test.tsx
index 2a8ddf8009..c2fa8c5d1b 100644
--- a/jarvis/ui/web/frontend/src/components/layout/SectionNavButtons.test.tsx
+++ b/jarvis/ui/web/frontend/src/components/layout/SectionNavButtons.test.tsx
@@ -53,6 +53,17 @@ describe("SectionNavButtons", () => {
expect(useEventStore.getState().activeSection).toBe("chats");
});
+ it("goes home to a fresh front-page chat from any section", () => {
+ useEventStore.setState({ activeSection: "agentic-ide" });
+ render(<SectionNavButtons />);
+
+ const home = screen.getByTestId("section-nav-home") as HTMLButtonElement;
+ expect(home.disabled).toBe(false);
+ expect(home.getAttribute("title")).toBe(home.getAttribute("aria-label"));
+ fireEvent.click(home);
+ expect(useEventStore.getState().activeSection).toBe("chats");
+ });
+
it("walks back to the last visited section on every section", () => {
render(<SectionNavButtons />);
diff --git a/jarvis/ui/web/frontend/src/components/layout/SectionNavButtons.tsx b/jarvis/ui/web/frontend/src/components/layout/SectionNavButtons.tsx
index 9438f36af4..41f4efcaf2 100644
--- a/jarvis/ui/web/frontend/src/components/layout/SectionNavButtons.tsx
+++ b/jarvis/ui/web/frontend/src/components/layout/SectionNavButtons.tsx
@@ -1,8 +1,9 @@
-import { ArrowLeft, ArrowRight } from "lucide-react";
+import { ArrowLeft, ArrowRight, House } from "lucide-react";
import { useT } from "@/i18n";
import { useEventStore } from "@/store/events";
import { useSectionHistory } from "@/hooks/useSectionHistory";
+import { startNewTextChat } from "@/lib/newChat";
/**
* One shape for every caption control in this group.
@@ -18,13 +19,15 @@ const NAV_BUTTON =
"disabled:cursor-default disabled:opacity-40 disabled:hover:bg-transparent disabled:hover:text-muted-foreground";
/**
- * The caption's leading navigation: back and forward.
+ * The caption's leading navigation: home, back and forward.
*
* Rendered at the far left of the window caption (see TopBar), so it is on
* screen for EVERY section — chat, agents, voice, settings — with no second
* bar per view. Back/forward walk the visited-section history
* (`useSectionHistory`): back returns to the previously visited section, and
* forward only re-applies an undone step, staying disabled until one exists.
+ * Home is always live: it opens the front page with a fresh chat, the same
+ * screen Jarvis starts on, from wherever the window is.
* A detached solo window is pinned to one view, so the group stays out of it.
*/
export function SectionNavButtons() {
@@ -36,6 +39,7 @@ export function SectionNavButtons() {
const backLabel = t("topbar.nav_back");
const forwardLabel = t("topbar.nav_forward");
+ const homeLabel = t("topbar.nav_home");
return (
<div
@@ -44,6 +48,16 @@ export function SectionNavButtons() {
role="group"
aria-label={t("sidebar.sections")}
>
+ <button
+ type="button"
+ data-testid="section-nav-home"
+ onClick={() => startNewTextChat()}
+ aria-label={homeLabel}
+ title={homeLabel}
+ className={NAV_BUTTON}
+ >
+ <House className="h-4 w-4" aria-hidden />
+ </button>
<button
type="button"
data-testid="section-nav-back"
diff --git a/jarvis/ui/web/frontend/src/i18n/locales/de.json b/jarvis/ui/web/frontend/src/i18n/locales/de.json
index 626c04196f..e751057350 100644
--- a/jarvis/ui/web/frontend/src/i18n/locales/de.json
+++ b/jarvis/ui/web/frontend/src/i18n/locales/de.json
@@ -174,7 +174,8 @@
"restore": "Wiederherstellen",
"close": "Schließen",
"nav_back": "Zurück",
- "nav_forward": "Vor"
+ "nav_forward": "Vor",
+ "nav_home": "Startseite"
},
"nav": {
"chat_workspace": "Chat",
diff --git a/jarvis/ui/web/frontend/src/i18n/locales/en.json b/jarvis/ui/web/frontend/src/i18n/locales/en.json
index 8b7c3e06d2..ff27df3530 100644
--- a/jarvis/ui/web/frontend/src/i18n/locales/en.json
+++ b/jarvis/ui/web/frontend/src/i18n/locales/en.json
@@ -174,7 +174,8 @@
"restore": "Restore",
"close": "Close",
"nav_back": "Go back",
- "nav_forward": "Go forward"
+ "nav_forward": "Go forward",
+ "nav_home": "Home"
},
"nav": {
"chat_workspace": "Chat",
diff --git a/jarvis/ui/web/frontend/src/i18n/locales/es.json b/jarvis/ui/web/frontend/src/i18n/locales/es.json
index 9afd58ff7f..5b462b6d06 100644
--- a/jarvis/ui/web/frontend/src/i18n/locales/es.json
+++ b/jarvis/ui/web/frontend/src/i18n/locales/es.json
@@ -174,7 +174,8 @@
"restore": "Restaurar",
"close": "Cerrar",
"nav_back": "Atrás",
- "nav_forward": "Adelante"
+ "nav_forward": "Adelante",
+ "nav_home": "Inicio"
},
"nav": {
"chat_workspace": "Chat",