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

Node modal #174

Merged
merged 35 commits into from
Apr 29, 2023
Merged

Node modal #174

merged 35 commits into from
Apr 29, 2023

Conversation

anovazzi1
Copy link
Contributor

This pull request adds a new feature to the flow editor that allows users to access advanced fields of a node in a modal pop-up window. The modal pop-up is triggered by clicking on a new button on the top-right corner of the node.

The pop-up window contains all of the advanced fields for the selected node, organized in an intuitive and easy-to-use interface. Users can enter and edit data in the pop-up window, and all changes are automatically reflected in the main flow editor.

This feature is particularly useful for complex flows with nodes that have many advanced fields, as it simplifies the user interface and makes it easier to manage and edit the flow. It also helps to prevent clutter on the main flow editor by hiding advanced fields until they are needed.

Copy link
Contributor

@ogabrielluiz ogabrielluiz left a comment

Choose a reason for hiding this comment

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

The advanced condition defines if the field should be in the advanced popup, but show also does that, so, if advanced is true and show is true the field appears on both places.

Maybe we should just check if advanced or show is true since both seem to do the same thing.

…dNode classes

Add an advanced flag to the TemplateFieldCreator and FrontendNode classes to allow for fields to be hidden from the user interface. In the TemplateFieldCreator class, the advanced flag is set to False by default. In the FrontendNode class, the advanced flag is set to False for all fields except for "model_type" and "model_kwargs", which are set to True.
@anovazzi1
Copy link
Contributor Author

Strongly disagree, 'advanced' should display in the modal and 'show' in the node. two different things.

@ogabrielluiz
Copy link
Contributor

But what if we set both to True? I think right now show=True shows in both places.

One idea: what if we only show things that require another node (inputs), and all the rest go into the advanced part?

ogabrielluiz and others added 10 commits April 28, 2023 19:17
…r class

refactor(langflow): set advanced flag to False for LLMFrontendNode class' api key field
feat(langflow): add show flag to LLMFrontendNode class' model_kwargs field
refactor(langflow): set advanced flag to False and show flag to True for LLMFrontendNode class' model_name and temperature fields
feat(tests): add 'advanced' field to template properties in test files
@ogabrielluiz ogabrielluiz merged commit 5489717 into dev Apr 29, 2023
@anovazzi1 anovazzi1 deleted the NodeModal branch June 1, 2023 00:02
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