Skip to content

Commit 0675c7c

Browse files
committed
include the ability again to re-parent to itself to change ordering
1 parent 4ddf9ea commit 0675c7c

File tree

2 files changed

+2
-4
lines changed

2 files changed

+2
-4
lines changed

web/src/components/OutcomeConnectors/OutcomeConnectors.component.tsx

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,6 @@ const OutcomeConnector = ({
9595

9696
// shared code for mouse event handlers
9797
const connectionConnectMouseDown = (direction, validity) => (event: React.MouseEvent) => {
98-
console.log('event', event.shiftKey)
9998
if (!fromAddress) {
10099
// if the action is being performed from
101100
// a top port, then there's two options:
@@ -105,7 +104,6 @@ const OutcomeConnector = ({
105104
// definitely don't override any existing connection
106105
// ASSUMPTION: one parent
107106
const connectionAddressToOverride = (direction === RELATION_AS_CHILD && !event.shiftKey) ? ownExistingParentConnectionAddress : undefined
108-
console.log('connectionAddressToOverride', connectionAddressToOverride)
109107
setOutcomeConnectorFrom(
110108
address,
111109
direction,

web/src/tree-logic.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -63,8 +63,8 @@ function calculateValidParents(
6363
// filter out self-address in the process
6464
outcomeActionHash !== fromAddress &&
6565
// filter out any descendants
66-
!descendants.includes(outcomeActionHash) &&
67-
!isAncestor(fromAddress, outcomeActionHash, connections)
66+
!descendants.includes(outcomeActionHash) // &&
67+
// !isAncestor(fromAddress, outcomeActionHash, connections)
6868
)
6969
})
7070
}

0 commit comments

Comments
 (0)