Uh oh!
There was an error while loading. Please reload this page.
fix(subflows): make edges inside subflows directly clickable - #3969
Conversation
Edges inside subflows defaulted to z-index 0, causing the subflow body area (pointer-events: auto) to intercept clicks. Derive edge z-index from the container's depth so edges sit just above their parent container but below canvas blocks and child blocks.
The latest updates on your projects. Learn more about Vercel for GitHub. |
PR SummaryMedium Risk Overview Tightens interaction edge cases: filters out cross-nesting additive multi-select changes (and ignores shift-click across contexts) to prevent transient invalid selection states, and avoids multi-node drag reparenting unless the drag actually moved over a different container. Reviewed by Cursor Bugbot for commit 4a53beb. Bugbot is set up for automated code reviews on this repo. Configure here. |
Greptile SummaryThis PR fixes a bug where edges inside subflow containers (loop/parallel blocks) were not directly clickable because their z-index was
Confidence Score: 5/5Safe to merge — targeted, minimal fix with correct z-index logic and no regressions to non-subflow edges Single useMemo change with clear intent, correct depth-based z-index derivation, safe fallback to 0 when container not found, and no impact on existing edge behavior outside subflows. No P0 or P1 issues found. No files require special attention Important Files Changed
Flowchart%%{init: {'theme': 'neutral'}}%%
flowchart TD
A[Edge in edgesWithSelection] --> B{connectedToElevated?}
B -->|Yes| C[elevatedZIndex = max 22 sourceZ+1 targetZ+1]
B -->|No| D{parentLoopId exists?}
D -->|Yes| E[containerNode = nodeMap.get parentLoopId]
E --> F{containerNode found?}
F -->|Yes| G[baseZIndex = containerNode.zIndex + 1]
F -->|No| H[baseZIndex = 0]
D -->|No| H
C --> I[Edge above selected blocks z22+]
G --> J[Edge clickable - above container body, below canvas z21+ and child blocks z1000]
H --> K[Edge at z=0 default]
Reviews (1): Last reviewed commit: "fix(subflows): make edges inside subflow..." | Re-trigger Greptile |
Uh oh!
There was an error while loading. Please reload this page.
* fix(subflows): make edges inside subflows directly clickable Edges inside subflows defaulted to z-index 0, causing the subflow body area (pointer-events: auto) to intercept clicks. Derive edge z-index from the container's depth so edges sit just above their parent container but below canvas blocks and child blocks. * Fix edge deletion in nested subflows * Fix bug with multi selecting nested subblock --------- Co-authored-by: Theodore Li <theo@sim.ai>
Summary
Type of Change
Testing
Tested manually
Checklist