ENG-2256 Implement new relation menu empty state - #1491
Merged
trangdoan982 merged 3 commits intoOct 2, 2026
Merged
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
This pull request has been ignored for the connected project Preview Branches by Supabase. |
Contributor
There was a problem hiding this comment.
Devin Review found 1 potential issue.
1 flag not posted on this PR by your GitHub settings — view it in Devin Review. (Configure)
3 tasks done
trangdoan982
added this pull request to stack #1495
September 28, 2026 14:44
3 tasks done
mdroidian
approved these changes
Sep 30, 2026
| }, []); | ||
|
|
||
| // A pending arrow found on mount was abandoned when the canvas last closed | ||
| useEffect(() => { |
Member
There was a problem hiding this comment.
Why can't we remove the arrow based on the action, whether you click away from the canvas or unfocus or something? Why do we have to catch it on the next canvas load?
trangdoan982
force-pushed
the
eng-2256-implement-new-relation-menu-empty-state
branch
from
September 30, 2026 15:23
2404361 to
0387c3b
Compare
Open the relation type menu for node-type pairs with no relation types, showing Add existing… and Create new. The populated menu exposes the same actions behind a "+" flyout. The actions are wired in ENG-2257/ENG-2258. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Entire-Checkpoint: 01M3J7D2EQ0H3DABC2RRBSB0J8
The save loop persists the pending arrow while the relation type menu is open. Tag it in shape meta, clear the tag on pick, and delete tagged leftovers when the overlay mounts. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Entire-Checkpoint: 01M3J8XJJDB6JNC6JZZXN4FMSQ
… the canvas Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Entire-Checkpoint: 01M3Q8WG83DQNA246QGTM0X0YP
trangdoan982
force-pushed
the
eng-2256-implement-new-relation-menu-empty-state
branch
from
October 2, 2026 19:39
6ff29b6 to
3ec7d51
Compare
trangdoan982
deleted the
eng-2256-implement-new-relation-menu-empty-state
branch
October 2, 2026 20:56
This branch was successfully deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
https://entire.io/gh/DiscourseGraphs/discourse-graph/trails/31
Reviewer brief
Add existing…andCreate new. The populated menu shows the same two actions in a flyout behind a "+" in the header.meta.pendingRelationMenu, andDragHandleOverlaydeletes tagged leftovers on mount (fixes the Devin thread). Also,DragHandleOverlay.tsxno longer removes the arrow for pairs with no relation types. It still removes it when either node has no node type, now with the toast "Both nodes need a node type to create a relation".Add existing…andCreate newdo nothing yet. ENG-2257 wires the picker and ENG-2258 wires the create dialog. The three PRs are stacked and should merge close together; the ENG-2256 Linear comment records this.Look at the "no types" branch: it's the new path. The other path is unchanged apart from the "+".
flowchart LR A[Drag arrow to a discourse node] --> B{DragHandleOverlay:<br/>both nodes have nodeTypeId?} B -- no --> T[Remove arrow, toast:<br/>'Both nodes need a node type'] B -- yes --> C[RelationTypeDropdown:<br/>getValidRelationTypesForNodePair] C -- no types --> D[Empty state:<br/>Add existing… / Create new] C -- some types --> E[Type list + '+' in header] E -- click '+' --> F[Flyout inside dropdownRef:<br/>Add existing… / Create new] F -- Escape --> EVerification
pnpm ci:validatepasses. Live checks ran in Obsidian over CDP (dg-obsidian-cdp-verify) with real pointer input.Add existing…Create newin flyoutsupportsnodeTypeIdjustify-content: flex-start; 22 × 22supports, wait 2.5s, close and reopen canvaspendingRelationMenu: falseNo unit tests were added. The change is UI wiring, which the Vitest scope in
apps/obsidian/AGENTS.mdexcludes.Not verified: the last two edits (removing a code comment, and changing the header text to
Relation type, which still displays as all caps) weren't re-run live, since neither changes behavior or rendering.Loom video
https://www.loom.com/share/f066e35e4e9e46ba8a7e6920d323480a
Scope check
$scope-checkagainst the ENG ticket and final diff.Done When: None. Done When (3) is deferred on purpose: the actions are rendered but not wired. ENG-2257 (Add existing) and ENG-2258 (Create new) wire them in this stack. The team accepted this; see the ENG-2256 Linear comment. The new toast for nodes without a node type replaces the old guard's message, which no longer fits once pairs with no relation types reach the menu.Standards check
$dg-pr-adherence-checkagainst the final diff and PR metadata.I fixed two findings: the code comment about the ticket split moved to this brief, and the header is now in sentence case. The hardcoded gray colors are left as is to match the existing dropdown. The Loom video is still missing.
Local delegated full review
$dg-delegated-full-reviewwhen no other full-review workflow is available.No findings.
🤖 Generated with Claude Code