#36780 closed defect (bug) (duplicate)
Bug with selecting rendered shortcodes in TinyMCE
Reported by: | isabisa | Owned by: | |
---|---|---|---|
Milestone: | Priority: | normal | |
Severity: | normal | Version: | 4.5 |
Component: | TinyMCE | Keywords: | |
Focuses: | javascript, administration | Cc: |
Description
I first noticed this issue when I updated my site to WP 4.5. In an attempt to troubleshoot it on my own, I disabled all plugins and changed the theme to Twenty Sixteen on my local development site. It is still happening, which makes me think it's a bug in core or TinyMCE.
Here's what's happening:
In a post that contains 2 or more shortcodes that are rendered into the editor (like [gallery] for example), without clicking inside the editor, scroll down and try to click on the second rendered shortcode. It will select the first rendered shortcode instead and jump back up to the top. This seems to happen sporadically. I can prevent this behavior by clicking and placing the cursor in text near the rendered shortcode I want to select.
I noticed that when this happens, the wpview-wrap div that I click on gains the data-mce-selected="1" attribute for a split second before the attribute is removed and then added to the first .wpview-wrap in the TinyMCE body.
I took a screen capture video of this strange behavior and uploaded it to YouTube: https://www.youtube.com/watch?v=g4an2qpmVEk
Here's some more technical info:
WP version: 4.5.2
Theme: Twenty Sixteen
Plugins: NONE
System: VVV on OSX 10.10.4 (also happening on live site hosted on WP Engine and on another local dev site in HGV).
Browser: Chrome Version 50.0.2661.94 (64-bit)
Duplicate of #28322.