pasteHandler ignores FormattingControls prop #18637
Labels
[Feature] Paste
[Feature] Rich Text
Related to the Rich Text component that allows developers to render a contenteditable
[Type] Enhancement
A suggestion for improvement.
Describe the bug
Setting the formattingControl prop in a RichTextComponent to
['italic']
will limit the formatting options in said block to only show the italic button.The problem is that when you copy / paste some text from a word document it will keep the orignal formattimg even if it is not allowed in the component. Moreover because of the lack of the other formatting buttons the user is not able to manually remove the unwanted/unallowed formatting styles.
To reproduce
Steps to reproduce the behavior:
Expected behavior
On paste the unallowed formatting styles are ignored and treated like normal text.
Desktop (please complete the following information):
Might reference
Overview: Writing Flow #16280
https://github.com/WordPress/gutenberg/labels/%5BFeature%5D%20Raw%20Handling
The text was updated successfully, but these errors were encountered: