-
Notifications
You must be signed in to change notification settings - Fork 667
Add Topology Edge Selection w/ Side Panel #4003
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
Add Topology Edge Selection w/ Side Panel #4003
Conversation
55bfa5b to
538c22b
Compare
|
/kind feature |
538c22b to
4751826
Compare
serenamarie125
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@jeff-phillips-18 this looks great, you don't have the Actual traffic connector shown here, but I assume that's coming in a follow up PR?
Correct, we do not have those connectors in yet. see #4026 |
|
Used the The I don't think we should disable the current target node in the
|
4751826 to
9a8ba97
Compare
|
Updated as suggested. Not seeing errors any more. Still see some warnings due to patternfly/patternfly-react#3549 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@jeff-phillips-18
The move action on a visual connector allows event source as a valid dropdown option as target for a deployment. and throws an error on submit (Move)
|
The |
|
@nemesis09 Did you try that after my last push? |
Sorry, I didn't try it after the latest push when I got the errors.
|
9a8ba97 to
2797f70
Compare
|
Fixed modal to show the correct error. Errors updated the edges are reported already in https://issues.redhat.com/browse/ODC-2726 which is fixed in #3986 |
|
The modal doesn't show any error now, and submitting( |
|
I tried locally with changes pulled from #3986, |
|
Removed event sources from the list of available targets.. |
|
The modal disables the submit( |
serenamarie125
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
looks good!
|
tested locally. works as expected. |
andrewballantyne
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The type issues are minor since they are not exposed methods yet... We definitely need tests for the utilities so when that is being done we can add the types as likely we'll want to export those functions for tests.
@jeff-phillips-18 please log a Task, assign it to yourself, and put it in the next sprint (179), next week we'll need to write the missing tests. Also please fix the types at the same time.
| }; | ||
| }; | ||
|
|
||
| const deleteConnection = (edge: BaseEdge) => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| const deleteConnection = (edge: BaseEdge) => { | |
| const deleteConnection = (edge: BaseEdge): KebabOption => { |
We need to make sure we type output of newly created objects to insure they stay properly typed (if anything in the type changes later).
| } from '../const'; | ||
| import { moveConnectionModal } from '../components/MoveConnectionModal'; | ||
|
|
||
| const moveConnection = (edge: BaseEdge, availableTargets: Node[]) => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same here...
| const moveConnection = (edge: BaseEdge, availableTargets: Node[]) => { | |
| const moveConnection = (edge: BaseEdge, availableTargets: Node[]): KebabOption => { |
| actions.push(deleteConnection(edge)); | ||
| break; | ||
| default: | ||
| break; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| break; |
Default clauses almost never need a break unless you're doing conditional paths within it.
|
|
||
| const ConnectedMoveConnectionModal = connect(mapStateToProps)(MoveConnectionModal); | ||
|
|
||
| export const moveConnectionModal = createModalLauncher((props: MoveConnectionModalProps) => ( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
😕 There are a lot of different ways to make modals in our codebase. I'll need to take an action up to talk to Christian and find out what the best way is and try to centralize around it.
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: andrewballantyne, jeff-phillips-18, nemesis09, serenamarie125 The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
|
/retest |
|
/retest Please review the full test history for this PR and help us cut down flakes. |
|
Added task https://issues.redhat.com/browse/ODC-2823 |
|
/retest Please review the full test history for this PR and help us cut down flakes. |
1 similar comment
|
/retest Please review the full test history for this PR and help us cut down flakes. |
|
/retest Looks like a flake...
|
|
/retest Please review the full test history for this PR and help us cut down flakes. |
1 similar comment
|
/retest Please review the full test history for this PR and help us cut down flakes. |
|
/retest |
|
/hold |
|
/hold cancel |
|
/retest Please review the full test history for this PR and help us cut down flakes. |
Addresses story: https://issues.redhat.com/browse/ODC-2354
Fixes https://issues.redhat.com/browse/ODC-2797
Fixes https://issues.redhat.com/browse/ODC-2726
/cc @openshift/team-devconsole-ux