Commit ae3b0fd
RichText: Don't forget ref passing in Preview mode (#73062)
Let RichText forward the ref that it receives to the element it returns,
even when this element is the lightweight alternative returned when the
block editor is in preview mode.
Fixes any kind of bug arising from the fact that refs passed to RichText
were ignored when the block editor is in preview mode. Particularly,
`useBlockProps`, with its many merged refs, was systematically ignored.
This was revealed while debugging the bug that #73020 sought to fix:
`useBlockElement` could never return elements because the ref callback
of `useBlockElementRef` was never called.
Co-authored-by: mcsf <mcsf@git.wordpress.org>
Co-authored-by: jorgefilipecosta <jorgefilipecosta@git.wordpress.org>1 parent 636c4ef commit ae3b0fd
1 file changed
+1
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
569 | 569 | | |
570 | 570 | | |
571 | 571 | | |
| 572 | + | |
572 | 573 | | |
573 | 574 | | |
574 | 575 | | |
| |||
0 commit comments