WordPress / gutenberg

The Block Editor project for WordPress and beyond. Plugin is available from the official repository.
https://wordpress.org/gutenberg/
Other
10.32k stars 4.12k forks source link

Quote: empty block appender is mispositioned #63517

Open ellatrix opened 2 months ago

ellatrix commented 2 months ago

Description

image

Step-by-step reproduction instructions

Just create an empty quote in TT4

Screenshots, screen recording, code snippet

No response

Environment info

No response

Please confirm that you have searched existing issues in the repo.

Yes

Please confirm that you have tested with all plugins deactivated except Gutenberg.

Yes

t-hamano commented 2 months ago

Perhaps this problem occurs when __experimentalCaptureToolbars is true and renderAppender is false.

This is because the EmptyBlockInserter component prioritizes its parent's clientId, i.e. capturingClientId, over the current clientId:

https://github.com/WordPress/gutenberg/blob/a48b1ff02197db57589536ea287aec75fa104401/packages/block-editor/src/components/block-tools/empty-block-inserter.js#L32