diff --git a/web/src/components/SessionList.tsx b/web/src/components/SessionList.tsx index 0462c46f..0b88dd32 100644 --- a/web/src/components/SessionList.tsx +++ b/web/src/components/SessionList.tsx @@ -679,7 +679,7 @@ function SessionListSearch(props: { return (
-
+
+
+
{renderHeader ? ( -
+
-
+
+
{groups.map((group) => { const isCollapsed = isGroupCollapsed(group) const visibleGroupSessions = getVisibleGroupSessions(group) @@ -1294,7 +1297,7 @@ export function SessionList(props: { return (
toggleGroup(group.key, isCollapsed)} title={group.directory} > @@ -1347,7 +1350,7 @@ export function SessionList(props: { ? showMoreSessions(group) : collapseSessionGroup(group)} className={cn( - 'mx-2 my-1 rounded-md px-2 py-1 text-center text-xs text-[var(--app-hint)] transition-colors hover:bg-[var(--app-subtle-bg)] hover:text-[var(--app-fg)]', + 'ml-2.5 mr-2 my-1 rounded-md px-2 py-1 text-center text-xs text-[var(--app-hint)] transition-colors hover:bg-[var(--app-subtle-bg)] hover:text-[var(--app-fg)]', hiddenSessionCount > 0 && 'border border-dashed border-[var(--app-border)]' )} > @@ -1363,6 +1366,7 @@ export function SessionList(props: { ) })}
+
) } diff --git a/web/src/index.css b/web/src/index.css index a4f76e1b..ce06f199 100644 --- a/web/src/index.css +++ b/web/src/index.css @@ -352,19 +352,26 @@ body { } } +/* Keep the session list scrollbar on the left at every viewport size. */ +.session-list-scrollbar-left { + direction: rtl; + scrollbar-gutter: stable; +} + +.session-list-scrollbar-left > * { + direction: ltr; +} + +/* Match fixed sidebar controls to the space reserved for the left scrollbar. */ +.session-list-scrollbar-offset { + padding-left: 8px; +} + /* Desktop sidebar: use custom width from CSS variable. Kept in sync with the Tailwind `split` breakpoint (see tailwind.config.ts) so the sidebar width/resize applies as soon as the split view appears on compact tablets. */ @media (min-width: 920px) { - .desktop-scrollbar-left { - direction: rtl; - } - - .desktop-scrollbar-left > * { - direction: ltr; - } - /* Apply resizable width to sidebar. Cap it against the viewport so a wide persisted width (up to 600px, from resizing on desktop) can't crush the detail pane on a compact split. diff --git a/web/src/lib/locales/zh-CN.ts b/web/src/lib/locales/zh-CN.ts index 68aaafbf..5a53c439 100644 --- a/web/src/lib/locales/zh-CN.ts +++ b/web/src/lib/locales/zh-CN.ts @@ -146,18 +146,18 @@ export default { 'session.tooltip.scheduled.next': '下次 {when} · 另有 {more} 条', 'session.tooltip.moreCount': '另有 {count} 条', 'session.time.justNow': '刚刚', - 'session.time.minutesAgo': '{n} 分钟前', - 'session.time.hoursAgo': '{n} 小时前', - 'session.time.daysAgo': '{n} 天前', - 'session.time.inLessThanMinute': '不到 1 分钟', - 'session.time.inMinutes': '{n} 分钟后', - 'session.time.inHours': '{n} 小时后', - 'session.time.inDays': '{n} 天后', + 'session.time.minutesAgo': '{n}分钟前', + 'session.time.hoursAgo': '{n}小时前', + 'session.time.daysAgo': '{n}天前', + 'session.time.inLessThanMinute': '不到1分钟', + 'session.time.inMinutes': '{n}分钟后', + 'session.time.inHours': '{n}小时后', + 'session.time.inDays': '{n}天后', 'session.time.soon': '即将', 'session.time.importedFromCodex.justNow': '刚刚从codex客户端导入', - 'session.time.importedFromCodex.minutesAgo': '{n} 分钟前从codex客户端导入', - 'session.time.importedFromCodex.hoursAgo': '{n} 小时前从codex客户端导入', - 'session.time.importedFromCodex.daysAgo': '{n} 天前从codex客户端导入', + 'session.time.importedFromCodex.minutesAgo': '{n}分钟前从codex客户端导入', + 'session.time.importedFromCodex.hoursAgo': '{n}小时前从codex客户端导入', + 'session.time.importedFromCodex.daysAgo': '{n}天前从codex客户端导入', 'session.cursorMigration.banner.title': '正在升级 Cursor 会话', 'session.cursorMigration.banner.body': '正在将此旧版会话切换到更安全的 ACP 协议。历史较长的会话需要 15-20 秒;对话会自动恢复,已输入但未发送的草稿不会丢失。', 'session.cursorMigration.bannerAmbiguous.title': 'Cursor 会话升级需要人工处理', diff --git a/web/src/router.tsx b/web/src/router.tsx index 5b6fe25e..9744cfc4 100644 --- a/web/src/router.tsx +++ b/web/src/router.tsx @@ -535,8 +535,8 @@ function SessionsPage() { className={`${isSessionsIndex ? 'flex' : 'hidden split:flex'} w-full shrink-0 flex-col bg-[var(--app-bg)]`} style={{ '--sidebar-w': `${sidebar.width}px` } as React.CSSProperties} > -
-
+
+
-
+
{error ? (
{error}