Skip to content

Commit 4993dc6

Browse files
committed
Make it work
1 parent 32d7548 commit 4993dc6

File tree

6 files changed

+5
-18
lines changed

6 files changed

+5
-18
lines changed

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -938,7 +938,8 @@
938938
{
939939
"command": "pr.markAllCopilotNotificationsAsRead",
940940
"title": "Mark All as Read",
941-
"category": "%command.pull.request.category%"
941+
"category": "%command.pull.request.category%",
942+
"enablement": "viewItem == copilot-query-with-notifications"
942943
},
943944
{
944945
"command": "pr.merge",
@@ -2785,7 +2786,6 @@
27852786
{
27862787
"command": "pr.markAllCopilotNotificationsAsRead",
27872788
"when": "view == pr:github && viewItem =~ /copilot-query/",
2788-
"enablement": "viewItem == copilot-query-with-notifications",
27892789
"group": "0_category@1"
27902790
},
27912791
{

src/@types/vscode.proposed.chatParticipantAdditions.d.ts

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -646,13 +646,7 @@ declare module 'vscode' {
646646
}
647647

648648
export interface ChatRequest {
649-
readonly modeInstructions?: string;
650-
readonly modeInstructions2?: ChatRequestModeInstructions;
651-
}
652-
653-
export interface ChatRequestModeInstructions {
654-
readonly content: string;
655-
readonly toolReferences?: readonly ChatLanguageModelToolReference[];
656-
readonly metadata?: Record<string, boolean | string | number>;
649+
modeInstructions?: string;
650+
modeInstructionsToolReferences?: readonly ChatLanguageModelToolReference[];
657651
}
658652
}

src/@types/vscode.proposed.chatParticipantPrivate.d.ts

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -187,8 +187,6 @@ declare module 'vscode' {
187187

188188
isQuotaExceeded?: boolean;
189189

190-
isRateLimited?: boolean;
191-
192190
level?: ChatErrorLevel;
193191

194192
code?: string;
@@ -241,7 +239,6 @@ declare module 'vscode' {
241239
export class ExtendedLanguageModelToolResult extends LanguageModelToolResult {
242240
toolResultMessage?: string | MarkdownString;
243241
toolResultDetails?: Array<Uri | Location>;
244-
toolMetadata?: unknown;
245242
}
246243

247244
// #region Chat participant detection

src/commands.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -921,7 +921,6 @@ export function registerCommands(
921921
vscode.commands.registerCommand('pr.markAllCopilotNotificationsAsRead', node => {
922922
if (node instanceof CategoryTreeNode && node.isCopilot && node.repo) {
923923
copilotRemoteAgentManager.clearAllNotifications(node.repo.owner, node.repo.repositoryName);
924-
tree.refresh(node);
925924
}
926925
}),
927926
);

src/github/copilotRemoteAgent.ts

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -879,9 +879,6 @@ export class CopilotRemoteAgentManager extends Disposable {
879879
return this._stateModel.notifications.size;
880880
}
881881

882-
getNotificationsCountForRepo(owner: string, repo: string): number {
883-
return this._stateModel.getNotificationsCount(owner, repo);
884-
}
885882

886883
public clearAllNotifications(owner?: string, repo?: string): void {
887884
this._stateModel.clearAllNotifications(owner, repo);

src/view/treeNodes/categoryNode.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -335,7 +335,7 @@ export class CategoryTreeNode extends TreeNode implements vscode.TreeItem {
335335

336336
// Update contextValue based on current notification state
337337
if (this._categoryQuery) {
338-
const hasNotifications = this.isCopilot && this._repo && this._copilotManager.getNotificationsCountForRepo(this._repo.owner, this._repo.repositoryName) > 0;
338+
const hasNotifications = this.isCopilot && this._repo && this._copilotManager.getNotificationsCount(this._repo.owner, this._repo.repositoryName) > 0;
339339
this.contextValue = this.isCopilot ?
340340
(hasNotifications ? 'copilot-query-with-notifications' : 'copilot-query') :
341341
'query';

0 commit comments

Comments
 (0)