-
-
Notifications
You must be signed in to change notification settings - Fork 398
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
fix(edgeless): add a paragraph block when clicking on empty space on the note block #6870
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
1 Ignored Deployment
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the work. In this case, when the last block is a non-text block, a paragraph block will always be added at the bottom. The logic here should be to focus on the nearest text block first when clicking. If the nearest block is not text block, and the last block is not a text block, then add an empty block
packages/blocks/src/root-block/edgeless/components/block-portal/note/edgeless-note.ts
Outdated
Show resolved
Hide resolved
…ite into radhu/fix/edgeless_note
When I tested this, I found that a paragraph block wasn't added at the bottom as described when adding a non-text. We need to click on the empty area in the doc to add a new text block. Thing.mp4 |
You can add some paragraph blocks before the table, and click at the top or left or right near the paragraph blocks, in this case, should focus on the paragraph first like in doc mode. In the video you uploaded, there are no text blocks before table, |
@donteatfriedrice How is this behavior? Thing2.mp4 |
…ite into radhu/fix/edgeless_note
Looks great! Thanks! Could you add tests for it ? |
Sure! |
## Features - toeverything/blocksuite#6863 @regischen - toeverything/blocksuite#6852 @doouding - toeverything/blocksuite#6860 @pengx17 - toeverything/blocksuite#6856 @donteatfriedrice - toeverything/blocksuite#6849 @fundon ## Bugfix - toeverything/blocksuite#6873 @pengx17 - toeverything/blocksuite#6870 @golok727 - toeverything/blocksuite#6851 @golok727 - toeverything/blocksuite#6848 @pengx17 - toeverything/blocksuite#6847 @fundon - toeverything/blocksuite#6867 @EYHN - toeverything/blocksuite#6868 @fundon - toeverything/blocksuite#6869 @donteatfriedrice - toeverything/blocksuite#6865 @donteatfriedrice - toeverything/blocksuite#6866 @fundon - toeverything/blocksuite#6864 @donteatfriedrice - toeverything/blocksuite#6824 @undefined - toeverything/blocksuite#6859 @fundon - toeverything/blocksuite#6853 @fundon - toeverything/blocksuite#6854 @fundon - toeverything/blocksuite#6845 @fourdim ## Refactor - toeverything/blocksuite#6872 @fundon ## Misc
close #6631