Skip to content

feat: add copy/paste support for nodes#349

Open
avinxshKD wants to merge 1 commit intoControlCore-Project:devfrom
avinxshKD:feat/copy-paste-nodes
Open

feat: add copy/paste support for nodes#349
avinxshKD wants to merge 1 commit intoControlCore-Project:devfrom
avinxshKD:feat/copy-paste-nodes

Conversation

@avinxshKD
Copy link

Nodes couldn't be copied at all, no clipboard state, no hotkeys, nothing wired up. added it.

  • copySelected() / pasteClipboard() on the graph instance

  • clipboard in reducer (SET_CLIPBOARD + state.clipboard)

  • Copy/Paste in the toolbar with Ctrl+C / Ctrl+V

Pasted nodes offset by 20px so they don't land directly on top. Only copies ordin nodes (not the internal junction nodes)

closes #345

@avinxshKD
Copy link
Author

@pradeeban pls check,

Also one thing i noticed (as i said in description), pasted nodes offset by 20px so they don't stack on the original, but not sure if there's a preferred placement convention in the codebase

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.

1 participant