Skip to content

Conversation

jonnyz32
Copy link

@jonnyz32 jonnyz32 commented Jul 17, 2025

Introduce a new CytoscapeGraph class to manage graph elements and display them in a webview. Enable node selection to show detailed information.

Tasks:

Screen.Recording.2025-07-17.at.1.51.15.PM.mov

worksofliam and others added 4 commits March 15, 2025 22:02
Signed-off-by: worksofliam <mrliamallan@live.co.uk>
Signed-off-by: worksofliam <mrliamallan@live.co.uk>
Signed-off-by: worksofliam <mrliamallan@live.co.uk>
@jonnyz32 jonnyz32 marked this pull request as draft July 17, 2025 17:40
@jonnyz32 jonnyz32 marked this pull request as ready for review July 17, 2025 17:52
@jonnyz32 jonnyz32 marked this pull request as draft July 18, 2025 17:41
@jonnyz32 jonnyz32 force-pushed the feature/dove_graph branch from 37e9b2a to eb0d8ea Compare July 23, 2025 14:18
@jonnyz32 jonnyz32 marked this pull request as ready for review July 23, 2025 14:43
@worksofliam worksofliam added this to the Fix day milestone Aug 23, 2025
Copy link
Member

@worksofliam worksofliam left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The UX is looking really good, but there are some things in the code we'll need to cleanup before merge.

context

We don't typically want to store the extension context as a global, and we usually want to pass it all the way down where possible. The route I would take is to start by deleing the contextProvider.ts file and seeing how you can mangle it down there.

build files (media)

We add a new dependency in this PR - cytoscape - but, we should not be checking in this file into our git repository. Instead, at build time, we should be pulling it from the installed node_modules.

The remaining files make sense, since it's written outside of a package and is part of the extension.

console.log(`Congratulations, your extension "vscode-db2i" is now active!`);

loadBase(context);
ContextProvider.setContext(context);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So typically in extension, we don't store the context globally. We always pass the instance down in the activate function. For example, you might pass it down to resultsProvider.initialise and do the work there.

}

private getUri(path: string[], webview: vscode.Webview): vscode.Uri {
const context = ContextProvider.getContext();
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

again, shouldn't be using this context provider. Instead, the context could be stored as a private member property passed in from the constructor.

@worksofliam worksofliam removed this from the Fix day August milestone Aug 26, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants