Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(editor): Update panning and selection keybindings on new canvas #11534

Conversation

alexgrozav
Copy link
Member

@alexgrozav alexgrozav commented Nov 4, 2024

Summary

Fixes #11519

Latest VueFlow update fixes some bugs, allowing us to remove workarounds for the following behaviours:

  • Use Space, Control or Meta keys to activate panning
  • Use Middle mouse button to pan natively
Screen.Recording.2024-11-04.at.13.14.05.mov

Related Linear tickets, Github issues, and Community forum posts

https://linear.app/n8n/issue/CAT-278/support-meta-left-mouse-click-to-navigate-the-canvas

Review / Merge checklist

  • PR title and summary are descriptive. (conventions)
  • Docs updated or follow-up ticket created.
  • Tests included.
  • PR Labeled with release/backport (if the PR is an urgent fix that needs to be backported)

@alexgrozav alexgrozav self-assigned this Nov 4, 2024
const selectionKeyCode = ref<true | null>(true);

onKeyDown(panningKeyCode, () => {
onKeyDown(panningKeyCode.value, () => {
setPanningEnabled(true);
Copy link
Contributor

Choose a reason for hiding this comment

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

@alexgrozav do we still need this setPanningEnabled?

Copy link
Member Author

Choose a reason for hiding this comment

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

Nope, good point. Removed it.

@n8n-assistant n8n-assistant bot added n8n team Authored by the n8n team ui Enhancement in /editor-ui or /design-system labels Nov 4, 2024
Copy link

cypress bot commented Nov 4, 2024

n8n    Run #7683

Run Properties:  status check passed Passed #7683  •  git commit aec5e7b234: 🌳 🖥️ browsers:node18.12.0-chrome107 🤖 alexgrozav 🗃️ e2e/*
Project n8n
Branch Review cat-278-support-ctrl-left-mouse-click-to-navigate-the-canvas-2
Run status status check passed Passed #7683
Run duration 04m 22s
Commit git commit aec5e7b234: 🌳 🖥️ browsers:node18.12.0-chrome107 🤖 alexgrozav 🗃️ e2e/*
Committer Alex Grozav
View all properties for this run ↗︎

Test results
Tests that failed  Failures 0
Tests that were flaky  Flaky 0
Tests that did not run due to a developer annotating a test with .skip  Pending 0
Tests that did not run due to a failure in a mocha hook  Skipped 0
Tests that passed  Passing 461
View all changes introduced in this branch ↗︎

Copy link
Contributor

github-actions bot commented Nov 4, 2024

✅ All Cypress E2E specs passed

@alexgrozav alexgrozav merged commit 5e2e205 into master Nov 4, 2024
42 checks passed
@alexgrozav alexgrozav deleted the cat-278-support-ctrl-left-mouse-click-to-navigate-the-canvas-2 branch November 4, 2024 12:36
This was referenced Nov 6, 2024
@janober
Copy link
Member

janober commented Nov 6, 2024

Got released with [email protected]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
n8n team Authored by the n8n team Released ui Enhancement in /editor-ui or /design-system
Projects
None yet
Development

Successfully merging this pull request may close these issues.

New Alpha Editor Zoom In and Pan/Drag Bug
3 participants