From 328ccb0e21a13beb1eb3c253afe08ee1bd094b5e Mon Sep 17 00:00:00 2001 From: Brett Saviano Date: Thu, 3 Oct 2024 07:31:17 -0400 Subject: [PATCH 1/2] Use more granular symbols for class members --- src/providers/WorkspaceSymbolProvider.ts | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/src/providers/WorkspaceSymbolProvider.ts b/src/providers/WorkspaceSymbolProvider.ts index 824434a5..58fe0767 100644 --- a/src/providers/WorkspaceSymbolProvider.ts +++ b/src/providers/WorkspaceSymbolProvider.ts @@ -38,19 +38,27 @@ export class WorkspaceSymbolProvider implements vscode.WorkspaceSymbolProvider { for (const element of data.result.content) { const kind: vscode.SymbolKind = (() => { switch (element.Type) { - case "Query": case "Method": return vscode.SymbolKind.Method; + case "Query": + return vscode.SymbolKind.Function; + case "Trigger": + return vscode.SymbolKind.Event; case "Parameter": return vscode.SymbolKind.Constant; case "Index": + return vscode.SymbolKind.Array; + case "ForeignKey": return vscode.SymbolKind.Key; case "XData": - case "Storage": return vscode.SymbolKind.Struct; + case "Storage": + return vscode.SymbolKind.Object; + case "Projection": + return vscode.SymbolKind.Interface; case "Class": return vscode.SymbolKind.Class; - default: + default: // Property and Relationship return vscode.SymbolKind.Property; } })(); From 51fb154207c2a100ddae31920e316657837e6be0 Mon Sep 17 00:00:00 2001 From: Brett Saviano Date: Thu, 3 Oct 2024 07:33:56 -0400 Subject: [PATCH 2/2] Update WorkspaceSymbolProvider.ts --- src/providers/WorkspaceSymbolProvider.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/providers/WorkspaceSymbolProvider.ts b/src/providers/WorkspaceSymbolProvider.ts index 58fe0767..ee8126d0 100644 --- a/src/providers/WorkspaceSymbolProvider.ts +++ b/src/providers/WorkspaceSymbolProvider.ts @@ -58,7 +58,8 @@ export class WorkspaceSymbolProvider implements vscode.WorkspaceSymbolProvider { return vscode.SymbolKind.Interface; case "Class": return vscode.SymbolKind.Class; - default: // Property and Relationship + default: + // Property and Relationship return vscode.SymbolKind.Property; } })();