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(edgeless): support rotating shapes #2931

Merged
merged 90 commits into from
Jul 3, 2023

Conversation

fundon
Copy link
Contributor

@fundon fundon commented Jun 1, 2023

close #2608

  • update selected-rect
  • update hover-rect
  • rotate cursor
  • rotate shapes
  • flip shapes removed this feature
  • update grid
  • hitTest shapes
  • pick/select shapes
  • fix connector tests
  • tests
Screenshot 2023-06-01 at 12 41 31 PM
Screen.Recording.2023-06-21.at.2.48.16.AM.mov
Screen.Recording.2023-06-21.at.5.19.09.AM.mov
Screen.Recording.2023-06-23.at.12.06.36.PM.mov

@codesandbox
Copy link

codesandbox bot commented Jun 1, 2023

This branch is running in CodeSandbox. Use the links below to review this PR faster.


CodeSandbox logoCodeSandbox logo  Open in CodeSandbox Web Editor | VS Code | VS Code Insiders | Preview

@vercel
Copy link

vercel bot commented Jun 1, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
blocksuite ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jul 3, 2023 5:26am
blocksuite-docs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jul 3, 2023 5:26am


color: string;
}

export const DebugElementDefaultProps: IElementDefaultProps<'debug'> = {
type: 'debug',
xywh: '[0,0,0,0]',
rotate: 0,
Copy link
Member

Choose a reason for hiding this comment

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

I think using xywhr that packs rotate value may be a better choice.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Well, we can add rotate at the end.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I think we can consider adding the matrix, width height fields.

@@ -9,26 +9,31 @@ import type { ShapeMethods } from '../types.js';
export const DiamondMethods: ShapeMethods = {
render(
ctx: CanvasRenderingContext2D,
matrix: DOMMatrix,
Copy link
Member

Choose a reason for hiding this comment

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

@Flrande are there render methods still being used after you switch to roughjs?

* master:
  feat: update edgeless toolbar ui and zoom bar position (toeverything#3281)
Copy link
Member

@doodlewind doodlewind 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 fixing all the test cases!

With this landed, I'd suggest postpone new arch-refactoring-required features in edgeless mode for a while. We need to focus on bug fixes and housekeepings in the next stage.

@doodlewind doodlewind merged commit feb509b into toeverything:master Jul 3, 2023
@fundon fundon deleted the 0601-support-rotating-shapes branch July 3, 2023 12:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Archived in project
Development

Successfully merging this pull request may close these issues.

Support rotating shapes in edgeless mode
3 participants