[wp-trac] [WordPress Trac] #42029: Editor: Improve keeping text selection between Visual and Text modes

WordPress Trac noreply at wordpress.org
Sun Oct 1 09:33:30 UTC 2017


#42029: Editor: Improve keeping text selection between Visual and Text modes
-------------------------------------+-------------------------
 Reporter:  biskobe                  |       Owner:
     Type:  enhancement              |      Status:  new
 Priority:  normal                   |   Milestone:  4.9
Component:  Editor                   |     Version:  trunk
 Severity:  normal                   |  Resolution:
 Keywords:  has-patch needs-testing  |     Focuses:  javascript
-------------------------------------+-------------------------

Comment (by azaozz):

 Still to do:
 - There are couple of places where Underscore/Lodash is used, but it is
 not guaranteed it will be available. Refactor them to use similar helper
 methods in `window.tinymce`.
 - Add support for disabling this from the editor settings?
 - Perhaps use `editor.on( 'beforeGetContent', ...)` to always remove the
 selection marker. Can filter the editor DOM before serializing. This will
 remove it on switching editors, on saving, and when other plugins extract
 (some of) the content.

--
Ticket URL: <https://core.trac.wordpress.org/ticket/42029#comment:5>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list