[wp-trac] [WordPress Trac] #22257: Visual editor is locked after inserting an image/a gallery

WordPress Trac noreply at wordpress.org
Fri Nov 9 18:36:36 UTC 2012


#22257: Visual editor is locked after inserting an image/a gallery
--------------------------+--------------------
 Reporter:  ocean90       |       Owner:
     Type:  defect (bug)  |      Status:  new
 Priority:  high          |   Milestone:  3.5
Component:  TinyMCE       |     Version:  trunk
 Severity:  normal        |  Resolution:
 Keywords:  needs-patch   |
--------------------------+--------------------

Comment (by azaozz):

 Yeah, that's when the view wrapper is floated. The spaces are normal text
 nodes around it, so they follow the normal css logic and move to the
 opposite side of the floated view.

 [[Image(floated-views.png​)]]

 Another thing I've tested was to add space only after a view (if there's
 no text node or if the text doesn't start with a space). This wouldn't let
 the caret to go before a view but that will be a problem only if the view
 is the first element in the post, pretty much the same as images behave in
 3.4.

 Then we can insert a zero-width text node and force the caret in it when
 the left arrow key is used for navigation.

 Yet another possibility would be to do that on both sides, i.e. when a
 view is selected, pressing the left/right arrow key would insert zero-
 width text note and force the caret there. Tried that too but didn't work
 straight away (currently the views "lock" the caret when it reaches them
 and attempts to get it out of there don't work).

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/22257#comment:7>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list