Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Lingua Franca Package Explorer: extensions to UI in VScode plugin #156

Open
wants to merge 39 commits into
base: main
Choose a base branch
from

Conversation

edwardalee
Copy link
Contributor

@edwardalee edwardalee commented Apr 18, 2024

This PR proposes extending the Lingua Franca VS Code extension with the following new features:

  • Run Button: Add a "Run" button next to the "Display Diagram" button, enabling users to compile and run LF programs directly within the editor.
  • Library Reactors Interface: Introduce a user-friendly interface for managing reusable reactor libraries. This allows reactor logic to be defined once and reused across multiple LF projects. Within the VS Code extension, users can access this interface by clicking the LF logo in the activity bar. The interface will feature a tree-view called "Lingua Franca Package Explorer," with two distinct sections:
    • Local Libraries: Displays a catalog of libraries defined by the programmer.
    • Lingo Libraries: Lists all libraries downloaded into the personal workspace via the Lingo package manager.

@edwardalee edwardalee added enhancement New feature or request exclude labels Apr 18, 2024
@vinzbarbuto vinzbarbuto changed the title [DO NOT MERGE!] Experimental extensions to UI in VScode plugin Lingua Franca Package Explorer: extensions to UI in VScode plugin Jul 16, 2024
@vinzbarbuto
Copy link
Collaborator

This PR is ready for review and merging. It provides all the necessary code to use the extensions in the VSCode plugin, specifically introducing the Lingua Franca Package Explorer.

@lhstrh
Copy link
Member

lhstrh commented Jul 16, 2024

Please also resolve the remaining merge conflicts.

@vinzbarbuto
Copy link
Collaborator

vinzbarbuto commented Jul 17, 2024

To-Do

  • Improve reactor highlighting for “GoToFile” action: find an alternative solution to ad-hoc string matching.
    • Solution: Highlight the entire reactor text. This method avoids edge cases and is quite robust.
  • Enhance insertion of input statements: run the parser on the current file and determine the correct edit location using the concrete syntax tree.
    • Proposed Solution: Utilize the language server to identify the precise position of the target node in the current file. Insert the new import statement immediately after the end of the target node, ensuring accurate placement within the code structure.

package.json Outdated Show resolved Hide resolved
src/lfview/lf-data-provider.ts Outdated Show resolved Hide resolved
tsconfig.json Outdated Show resolved Hide resolved
src/lfview/lf-data-provider.ts Outdated Show resolved Hide resolved
src/lfview/lf-data-provider.ts Outdated Show resolved Hide resolved
src/lfview/lf-data-provider.ts Outdated Show resolved Hide resolved
@soerendomroes

This comment has been minimized.

@petervdonovan
Copy link
Contributor

vinzbarbuto how do you build the extension after merging main? I had problems that I do not have the "lfw-pkg" file. #168

If #171 does not solve your problem, feel free to share the full output that you get when you run npm install.

@petervdonovan

This comment has been minimized.

@vinzbarbuto

This comment has been minimized.

@petervdonovan

This comment has been minimized.

Copy link
Contributor

@petervdonovan petervdonovan left a comment

Choose a reason for hiding this comment

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

It looks like my comments have been addressed

@vinzbarbuto vinzbarbuto marked this pull request as ready for review August 23, 2024 16:42
@lhstrh

This comment has been minimized.

LF_PACKAGE_EXPLORER.md Outdated Show resolved Hide resolved
@lhstrh
Copy link
Member

lhstrh commented Sep 4, 2024

@vinzbarbuto the PR description still needs to be updated. Please also mark conversations as resolved if they have been addressed fully. Once all conversations are resolved and the description is updated, we can merge this.

LF_PACKAGE_EXPLORER.md Outdated Show resolved Hide resolved
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants