BUG: Inline entity creation in Rich Text when an image is selected deletes the image

If an image is part of the current text selection when using Ctrl/Cmd+E to create a new entity, the image is deleted.