Skip to content

The agent that grows with you

feat(desktop): allow hiding thread timeline bars

brooklyn!ee56d38d977e
diff --git a/apps/desktop/src/app/settings/appearance-settings.tsx b/apps/desktop/src/app/settings/appearance-settings.tsx
index c596f9f55ff..49b740fc004 100644
--- a/apps/desktop/src/app/settings/appearance-settings.tsx
+++ b/apps/desktop/src/app/settings/appearance-settings.tsx
@@ -24,6 +24,7 @@ import { $reactionsEnabled, setReactionsEnabled } from '@/store/reactions-enable
import { $reasoningCollapsedByDefault, setReasoningCollapsedByDefault } from '@/store/reasoning-disclosure'
import { $sessionListDensity, type SessionListDensity, setSessionListDensity } from '@/store/session-list-density'
import { $tabStripDefault, setTabStripDefault, type TabStripDefault } from '@/store/tabstrip-prefs'
+import { $hideThreadTimeline, setHideThreadTimeline } from '@/store/thread-timeline'
import { $spentTipCount, $tipsEnabled, resetTips, setTipsEnabled } from '@/store/tips'
import {
$titlebarAppActionsSide,
@@ -403,6 +404,7 @@ export function AppearanceSettings() {
const { themeName, mode, resolvedMode, availableThemes, setTheme, setMode } = useTheme()
const toolViewMode = useStore($toolViewMode)
const hideCodeDiffs = useStore($hideCodeDiffs)
+ const hideThreadTimeline = useStore($hideThreadTimeline)
const reasoningCollapsedByDefault = useStore($reasoningCollapsedByDefault)
const sessionListDensity = useStore($sessionListDensity)
const tabStripDefault = useStore($tabStripDefault)
@@ -965,6 +967,25 @@ export function AppearanceSettings() {
title={a.hideCodeDiffsTitle}
/>
+ <ListRow
+ action={
+ <SegmentedControl
+ onChange={id => {
+ triggerHaptic('selection')
+ setHideThreadTimeline(id === 'on')
+ }}
+ options={[
+ { id: 'off', label: t.common.off },
+ { id: 'on', label: t.common.on }
+ ]}
+ value={hideThreadTimeline ? 'on' : 'off'}
+ />
+ }
+ description={a.hideThreadTimelineDesc}
+ id={appearanceSettingElementId(APPEARANCE_SETTING_IDS.hideThreadTimeline)}
+ title={a.hideThreadTimelineTitle}
+ />
+
<ListRow
action={
<SegmentedControl
diff --git a/apps/desktop/src/app/settings/settings-search.ts b/apps/desktop/src/app/settings/settings-search.ts
index 80ea6b03150..4c41b30c64b 100644
--- a/apps/desktop/src/app/settings/settings-search.ts
+++ b/apps/desktop/src/app/settings/settings-search.ts
@@ -15,6 +15,7 @@ export const APPEARANCE_SETTING_IDS = {
backdrop: 'appearance.backdrop',
embeds: 'appearance.embeds',
hideCodeDiffs: 'appearance.hide-code-diffs',
+ hideThreadTimeline: 'appearance.hide-thread-timeline',
introSplash: 'appearance.intro-splash',
language: 'appearance.language',
theme: 'appearance.theme',
diff --git a/apps/desktop/src/app/settings/use-settings-search.ts b/apps/desktop/src/app/settings/use-settings-search.ts
index f5dfc5437f7..89f2066ad90 100644
--- a/apps/desktop/src/app/settings/use-settings-search.ts
+++ b/apps/desktop/src/app/settings/use-settings-search.ts
@@ -207,6 +207,15 @@ export function useSettingsSearchCatalog(enabled: boolean) {
label: appearance.hideCodeDiffsTitle,
target: { setting: APPEARANCE_SETTING_IDS.hideCodeDiffs, view: 'config:appearance' }
},
+ {
+ context: appearanceContext,
+ description: appearance.hideThreadTimelineDesc,
+ icon: Palette,
+ id: `setting:${APPEARANCE_SETTING_IDS.hideThreadTimeline}`,
+ keywords: ['thread', 'conversation', 'timeline', 'bars', 'rail', 'navigation', 'hide'],
+ label: appearance.hideThreadTimelineTitle,
+ target: { setting: APPEARANCE_SETTING_IDS.hideThreadTimeline, view: 'config:appearance' }
+ },
{
context: appearanceContext,
description: appearance.appActionsDesc,
diff --git a/apps/desktop/src/components/assistant-ui/thread/timeline.tsx b/apps/desktop/src/components/assistant-ui/thread/timeline.tsx
index 5423b07d2ff..178dac06e35 100644
--- a/apps/desktop/src/components/assistant-ui/thread/timeline.tsx
+++ b/apps/desktop/src/components/assistant-ui/thread/timeline.tsx
@@ -1,4 +1,5 @@
import { useAui, useAuiState } from '@assistant-ui/react'
+import { useStore } from '@nanostores/react'
import { type FC, useCallback, useEffect, useMemo, useRef, useState } from 'react'
import { useSessionView } from '@/app/chat/session-view'
@@ -6,6 +7,7 @@ import { usePaneVisible } from '@/components/pane-shell/pane-visibility'
import { useI18n } from '@/i18n'
import { triggerHaptic } from '@/lib/haptics'
import { useStoreSelector } from '@/lib/use-session-slice'
+import { $hideThreadTimeline } from '@/store/thread-timeline'
import { messageContentText } from './content'
import {
@@ -27,8 +29,13 @@ const VIEWPORT = '[data-slot="aui_thread-viewport"]'
export const ownViewport = (root: HTMLElement | null): HTMLElement | null =>
(root?.closest('[data-session-anchor]') ?? document).querySelector<HTMLElement>(VIEWPORT)
-/** Hidden panes do not subscribe to streaming messages or measure layout. */
-export const ThreadTimeline: FC = () => (usePaneVisible() ? <ActiveThreadTimeline /> : null)
+/** Hidden rails do not subscribe to streaming messages or measure layout. */
+export const ThreadTimeline: FC = () => {
+ const paneVisible = usePaneVisible()
+ const hidden = useStore($hideThreadTimeline)
+
+ return paneVisible && !hidden ? <ActiveThreadTimeline /> : null
+}
const ActiveThreadTimeline: FC = () => {
const view = useSessionView()
diff --git a/apps/desktop/src/i18n/ar.ts b/apps/desktop/src/i18n/ar.ts
index 30b55b810e4..e2468fa5dc2 100644
--- a/apps/desktop/src/i18n/ar.ts
+++ b/apps/desktop/src/i18n/ar.ts
@@ -556,6 +556,8 @@ export const ar = defineLocale({
toolViewDesc: 'تحكم في كيفية عرض نشاط الأدوات داخل المحادثة.',
hideCodeDiffsTitle: 'إخفاء فروق الكود',
hideCodeDiffsDesc: 'عرض تعديلات الملفات كسطور أدوات مضمّنة مع عدد الأسطر المضافة والمحذوفة، دون عرض الكود.',
+ hideThreadTimelineTitle: 'إخفاء أشرطة المخطط الزمني للمحادثة',
+ hideThreadTimelineDesc: 'إخفاء أشرطة التنقل على الحافة اليمنى لكل محادثة.',
reasoningCollapsedTitle: 'طي التفكير افتراضيًا',
reasoningCollapsedDesc: 'أبقِ التفكير المتدفق متاحًا دون توسيعه حتى تفتحه.',
translucencyTitle: 'شفافية النافذة',
diff --git a/apps/desktop/src/i18n/en.ts b/apps/desktop/src/i18n/en.ts
index 1e652760eff..7d06005e472 100644
--- a/apps/desktop/src/i18n/en.ts
+++ b/apps/desktop/src/i18n/en.ts
@@ -732,6 +732,8 @@ export const en: Translations = {
toolViewDesc: 'Product hides raw tool payloads; Technical shows full input/output.',
hideCodeDiffsTitle: 'Hide code diffs',
hideCodeDiffsDesc: 'Show file edits as inline tool rows with added/removed line counts, without the code.',
+ hideThreadTimelineTitle: 'Hide thread timeline bars',
+ hideThreadTimelineDesc: 'Hide the navigation bars along the right edge of each conversation.',
reasoningCollapsedTitle: 'Collapse thinking by default',
reasoningCollapsedDesc: 'Keep streamed reasoning available without expanding it until you open it.',
uiScaleTitle: 'UI Scale',
diff --git a/apps/desktop/src/i18n/ja.ts b/apps/desktop/src/i18n/ja.ts
index 8a848708bcb..e324c6f9bb4 100644
--- a/apps/desktop/src/i18n/ja.ts
+++ b/apps/desktop/src/i18n/ja.ts
@@ -490,6 +490,8 @@ export const ja = defineLocale({
toolViewDesc: 'プロダクト表示は生のツールペイロードを隠し、テクニカル表示は入出力をすべて表示します。',
hideCodeDiffsTitle: 'コードの差分を非表示',
hideCodeDiffsDesc: 'ファイル編集は追加・削除行数付きのインラインツール行で表示し、コードは表示しません。',
+ hideThreadTimelineTitle: 'スレッドのタイムラインバーを非表示',
+ hideThreadTimelineDesc: '各会話の右端にあるナビゲーションバーを非表示にします。',
reasoningCollapsedTitle: '思考ブロックをデフォルトで折りたたむ',
reasoningCollapsedDesc: 'ストリーミング中の推論を、開くまで折りたたんだまま利用できるようにします。',
uiScaleTitle: 'UI スケール',
diff --git a/apps/desktop/src/i18n/ru.ts b/apps/desktop/src/i18n/ru.ts
index 216fdedcddd..5e0d66b9665 100644
--- a/apps/desktop/src/i18n/ru.ts
+++ b/apps/desktop/src/i18n/ru.ts
@@ -559,6 +559,8 @@ export const ru = defineLocale({
toolViewDesc: 'Режим «Продукт» скрывает сырые данные инструментов, «Технический» показывает полный вход/выход.',
hideCodeDiffsTitle: 'Скрывать изменения кода',
hideCodeDiffsDesc: 'Показывать правки файлов строками инструментов с числом добавленных и удалённых строк, без кода.',
+ hideThreadTimelineTitle: 'Скрывать полоски истории диалога',
+ hideThreadTimelineDesc: 'Скрывать полоски навигации вдоль правого края каждого диалога.',
reasoningCollapsedTitle: 'Сворачивать «мышление» по умолчанию',
reasoningCollapsedDesc:
'Стриминговое рассуждение остаётся доступным, но не разворачивается, пока вы его не откроете.',
diff --git a/apps/desktop/src/i18n/types.ts b/apps/desktop/src/i18n/types.ts
index de2ef2cdf7d..fcaa17887c1 100644
--- a/apps/desktop/src/i18n/types.ts
+++ b/apps/desktop/src/i18n/types.ts
@@ -620,6 +620,8 @@ export interface Translations {
toolViewDesc: string
hideCodeDiffsTitle: string
hideCodeDiffsDesc: string
+ hideThreadTimelineTitle: string
+ hideThreadTimelineDesc: string
reasoningCollapsedTitle: string
reasoningCollapsedDesc: string
uiScaleTitle: string
diff --git a/apps/desktop/src/i18n/zh-hant.ts b/apps/desktop/src/i18n/zh-hant.ts
index 9517aad3345..f0d056f0435 100644
--- a/apps/desktop/src/i18n/zh-hant.ts
+++ b/apps/desktop/src/i18n/zh-hant.ts
@@ -475,6 +475,8 @@ export const zhHant = defineLocale({
toolViewDesc: '產品模式會隱藏原始工具 payload;技術模式會顯示完整輸入/輸出。',
hideCodeDiffsTitle: '隱藏程式碼差異',
hideCodeDiffsDesc: '將檔案編輯顯示為附有新增和刪除行數的行內工具列,不顯示程式碼。',
+ hideThreadTimelineTitle: '隱藏對話時間軸列',
+ hideThreadTimelineDesc: '隱藏每個對話右側邊緣的導覽列。',
reasoningCollapsedTitle: '預設摺疊推理過程',
reasoningCollapsedDesc: '保留串流推理內容,但在您開啟前維持摺疊。',
uiScaleTitle: '介面縮放',
diff --git a/apps/desktop/src/i18n/zh.ts b/apps/desktop/src/i18n/zh.ts
index 5601f1827e6..708738c8ed4 100644
--- a/apps/desktop/src/i18n/zh.ts
+++ b/apps/desktop/src/i18n/zh.ts
@@ -682,6 +682,8 @@ export const zh = defineLocale({
toolViewDesc: '产品模式隐藏原始工具数据;技术模式显示完整输入/输出。',
hideCodeDiffsTitle: '隐藏代码差异',
hideCodeDiffsDesc: '将文件编辑显示为带有新增和删除行数的内联工具行,不显示代码。',
+ hideThreadTimelineTitle: '隐藏对话时间线条',
+ hideThreadTimelineDesc: '隐藏每个对话右侧边缘的导航条。',
reasoningCollapsedTitle: '默认折叠推理过程',
reasoningCollapsedDesc: '保留流式推理内容,但在您打开前保持折叠。',
uiScaleTitle: '界面缩放',
diff --git a/apps/desktop/src/store/thread-timeline.ts b/apps/desktop/src/store/thread-timeline.ts
new file mode 100644
index 00000000000..12167f38806
--- /dev/null
+++ b/apps/desktop/src/store/thread-timeline.ts
@@ -0,0 +1,14 @@
+import { atom } from 'nanostores'
+
+import { persistBoolean, storedBoolean } from '@/lib/storage'
+
+const HIDE_THREAD_TIMELINE_STORAGE_KEY = 'hermes.desktop.hideThreadTimeline'
+
+/** Desktop-local appearance preference, shared by all threads in this window. */
+export const $hideThreadTimeline = atom(storedBoolean(HIDE_THREAD_TIMELINE_STORAGE_KEY, false))
+
+$hideThreadTimeline.subscribe(value => persistBoolean(HIDE_THREAD_TIMELINE_STORAGE_KEY, value))
+
+export function setHideThreadTimeline(value: boolean) {
+ $hideThreadTimeline.set(value)
+}