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

refactor: Remove block and workspace drag surfaces #6758

Merged
merged 9 commits into from
Jan 20, 2023

Conversation

gonfunko
Copy link
Contributor

The basics

  • I branched from develop
  • My pull request is against develop
  • My code follows the style guide
  • I ran npm run format and npm run lint

The details

Resolves

#6160, #781, #5759

Proposed Changes

This PR removes block and workspace drag surfaces in favor of directly translating the relevant SVGs.

Reason for Changes

Performance for both panning the workspace and dragging blocks, particularly when large block stacks are involved, is substantially improved on Chrome, essentially unchanged on Firefox (where it was already excellent) ands slightly reduced on Safari, yet still much better than it was on Chrome before this change.

In addition to generally improved performance, this also removes a good bit of code, improving future maintainability.

Test Coverage

Verified that tests are passing and manually tested in Chrome, Firefox and Safari.

@BeksOmega
Copy link
Collaborator

@gonfunko Are you cool waiting to merge this until after the release next week? or do you want it to go in? Personally I would rather have longer to test it if possible.

@gonfunko
Copy link
Contributor Author

@gonfunko Are you cool waiting to merge this until after the release next week? or do you want it to go in? Personally I would rather have longer to test it if possible.

Yes, absolutely was not expecting this to land in the imminent release.

Copy link
Collaborator

@BeksOmega BeksOmega left a comment

Choose a reason for hiding this comment

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

Generally LGTM! One nit, and then we need to decide whether this is a breaking change or not.

core/blockly.ts Show resolved Hide resolved
core/block_svg.ts Outdated Show resolved Hide resolved
core/blockly.ts Show resolved Hide resolved
@gonfunko gonfunko added the breaking change Used to mark a PR or issue that changes our public APIs. label Jan 11, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
breaking change Used to mark a PR or issue that changes our public APIs. PR: refactor
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants