Просмотр исходного кода

fix: mute the project path in the sidebar that proceeds the final directory

David Hill 2 месяцев назад
Родитель
Сommit
7cb5a77ba6
1 измененных файлов с 4 добавлено и 1 удалено
  1. 4 1
      packages/opencode/src/cli/cmd/tui/routes/session/sidebar.tsx

+ 4 - 1
packages/opencode/src/cli/cmd/tui/routes/session/sidebar.tsx

@@ -277,7 +277,10 @@ export function Sidebar(props: { sessionID: string }) {
               </box>
             </box>
           </Show>
-          <text fg={theme.text}>{directory()}</text>
+          <text>
+            <span style={{ fg: theme.textMuted }}>{directory().split("/").slice(0, -1).join("/")}/</span>
+            <span style={{ fg: theme.text }}>{directory().split("/").at(-1)}</span>
+          </text>
           <text fg={theme.textMuted}>
             <span style={{ fg: theme.success }}>•</span> <b>Open</b>
             <span style={{ fg: theme.text }}>