Skip to content

Commit 77a2ae6

Browse files
committed
Add projects dropdown filter.
Truncate workspace names. History misc improvements. Testing.
1 parent 76f363e commit 77a2ae6

File tree

7 files changed

+411
-451
lines changed

7 files changed

+411
-451
lines changed

src/shared/WebviewMessage.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ export type AudioType = "notification" | "celebration" | "progress_loop"
1111

1212
export interface WebviewMessage {
1313
type:
14+
| "action"
1415
| "apiConfiguration"
1516
| "deleteMultipleTasksWithIds"
1617
| "currentApiConfigName"
@@ -132,6 +133,7 @@ export interface WebviewMessage {
132133
| "toggleApiConfigPin"
133134
| "setHistoryPreviewCollapsed"
134135
text?: string
136+
action?: "settingsButtonClicked" | "historyButtonClicked"
135137
disabled?: boolean
136138
askResponse?: ClineAskResponse
137139
apiConfiguration?: ApiConfiguration

webview-ui/src/components/chat/ChatView.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ const ChatViewComponent: React.ForwardRefRenderFunction<ChatViewRef, ChatViewPro
8383
customModes,
8484
telemetrySetting,
8585
hasSystemPromptOverride,
86-
historyPreviewCollapsed, // Added historyPreviewCollapsed
86+
historyPreviewCollapsed,
8787
} = useExtensionState()
8888

8989
const { tasks } = useTaskSearch()

webview-ui/src/components/history/HistoryPreview.tsx

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,8 @@ import { useTaskSearch } from "./useTaskSearch"
99
import { Coins } from "lucide-react"
1010

1111
const HistoryPreview = () => {
12-
const { tasks, showAllWorkspaces } = useTaskSearch()
12+
// Force the hook to only return tasks from the current workspace
13+
const { tasks } = useTaskSearch({ forceWorkspaceFilter: "current" })
1314

1415
return (
1516
<>
@@ -49,12 +50,6 @@ const HistoryPreview = () => {
4950
</span>
5051
)}
5152
</div>
52-
{showAllWorkspaces && item.workspace && (
53-
<div className="flex flex-row gap-1 text-vscode-descriptionForeground text-xs mt-1">
54-
<span className="codicon codicon-folder scale-80" />
55-
<span>{item.workspace}</span>
56-
</div>
57-
)}
5853
</div>
5954
</div>
6055
))}

0 commit comments

Comments
 (0)