-
Notifications
You must be signed in to change notification settings - Fork 4.5k
Closed
Labels
Needs Technical FeedbackNeeds testing from a developer perspective.Needs testing from a developer perspective.[Feature] Rich TextRelated to the Rich Text component that allows developers to render a contenteditableRelated to the Rich Text component that allows developers to render a contenteditable
Description
Describe the bug
Create a RichText node in edit function. Fill with text content. Remove text with backspace key (selecting the text and deleting it all together does not cause this issue).
To Reproduce
Steps to reproduce the behavior:
0. Create Richtext, e.g.
<RichText
tagName={ 'span' }
value={ citation }
placeholder={ __( 'Write citation…' ) }
onChange={
( nextCitation ) => setAttributes( {
citation: nextCitation,
} )
}
/>
- Enter content into rich text field
- Safe Document
- Reload
- Click into text
- Delete text by hitting backspace multiple times
- Last digit can not be removed
Error occurs:
index.js?ver=1542114671:1 The given range isn't in document.
Expected behavior
Text should be cleared if user tries to delete content letter by letter with backspace.
Screenshots
If applicable, add screenshots to help explain your problem.
Desktop (please complete the following information):
- OS: macOS 10.14.1
- Browser: all
Additional context
- Gutenberg Version 4.3.0
- Wordpress Version 4.9.8
Metadata
Metadata
Assignees
Labels
Needs Technical FeedbackNeeds testing from a developer perspective.Needs testing from a developer perspective.[Feature] Rich TextRelated to the Rich Text component that allows developers to render a contenteditableRelated to the Rich Text component that allows developers to render a contenteditable