Skip to content

Conversation

Rohan2460
Copy link

Implements navigation in node catalog using up and down arrow keys and node selection using enter key.
Selected node is emphasized.

Closes #3235

@timon-schelling
Copy link
Member

!build

Copy link

📦 Build Complete for 39bbf67
https://c732d0b5.graphite.pages.dev

Copy link
Member

@timon-schelling timon-schelling left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the PR, Good UX improvement. Personally looking forward to using this.

{disabled}
label={nodeType.name}
tooltip={$nodeGraph.nodeDescriptions.get(nodeType.name)}
emphasized={nodeType == flatNodeList[focusedNodeIndex]}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Image

I think emph is not ideal could you use the color used for mouse hover.

Replaced emphasized with focused in NodeCatalog
@Rohan2460
Copy link
Author

@timon-schelling I added 'focused' prop to TextButton, is that ok ?
graphite_node

@timon-schelling
Copy link
Member

!build

@timon-schelling
Copy link
Member

I will take a look once the build is done.

Copy link

github-actions bot commented Oct 3, 2025

📦 Build Complete for 838c927
https://a35828fd.graphite.pages.dev

@timon-schelling
Copy link
Member

!build

});
}
function keyboardNavigationHandler(e: KeyboardEvent) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm relatively sure keavon will not like that this doesn't use the standard keyboard mapping. Should probably be handled in editor and only the visual aspect should be in the frontend. Would also allow showing the shortcuts in the bar at the bottom of the screen. You will need to look into how similar things are implemented.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If it doesn't break editor interactions, that's an ok compromise for now to not route this through the editor backend. The intention is to fully replace the node catalog menu in the future, it has always been a placeholder.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It doesn't break editor interactions. Then LGTM

Copy link

github-actions bot commented Oct 3, 2025

📦 Build Complete for 7665ca8
https://690a0632.graphite.pages.dev

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

Successfully merging this pull request may close these issues.

Keyboard navigation for node catalog
3 participants