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

How to Implement Graphical Nodes Similar to FastGPT in a Node Project #123

Closed
zt199510 opened this issue Jul 18, 2024 · 7 comments · Fixed by #124
Closed

How to Implement Graphical Nodes Similar to FastGPT in a Node Project #123

zt199510 opened this issue Jul 18, 2024 · 7 comments · Fixed by #124
Assignees
Labels
question Further information is requested

Comments

@zt199510
Copy link

Hello,

Once again, I need to trouble you for some assistance. I am working on a Workflow project and have encountered some challenges that I hope you can help me with. The project involves implementing functionalities similar to graphical nodes in a flowchart, as shown in the attached image.

I have encountered an issue in Nodify.Shapes. I see that there are 4 connectors, but I am at a loss about how to create a new Out connector on the right side. Could you please provide some guidance on how to achieve this?

Thank you very much for your help!

72c82ccb-e6cf-4266-bff4-0dab10639b2d

@zt199510 zt199510 added the question Further information is requested label Jul 18, 2024
@zt199510
Copy link
Author

I really enjoy this type of UI design, but I found it quite challenging when I started working on it. 😅

@miroiu
Copy link
Owner

miroiu commented Jul 18, 2024

Hi,

You can use a StackPanel to add more connectors on any side.

<StackPanel DockPanel.Dock="Right" VerticalAlignment="Center">
    <nodify:Connector DataContext="{Binding RightConnector}"
                        Anchor="{Binding Anchor, Mode=OneWayToSource}"
                        HorizontalContentAlignment="Right"
                        Margin="0 0 -11 10"
                        Visibility="Hidden"
                        Height="Auto"
                        Width="25"
                        x:Name="RightConnector" />
    <nodify:Connector DataContext="{Binding RightConnector2}"
                        Anchor="{Binding Anchor, Mode=OneWayToSource}"
                        HorizontalContentAlignment="Right"
                        Margin="0 0 -11 0"
                        Visibility="Hidden"
                        Height="Auto"
                        Width="25"
                        x:Name="RightConnector2" />
</StackPanel>

image

Is this what you are having trouble with?

@zt199510
Copy link
Author

Thank you. Could you provide some insights or a detailed approach on how to implement a feature similar to a bird's-eye view?

@miroiu
Copy link
Owner

miroiu commented Jul 19, 2024

Do you mean a minimap?

@zt199510
Copy link
Author

Yes

@miroiu
Copy link
Owner

miroiu commented Jul 20, 2024

I created a PR that adds a Minimap control to the library #124

@zt199510
Copy link
Author

Thank you

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants