Opened 8 years ago

Closed 8 years ago

Last modified 8 years ago

#14831 closed Bug (fixed)

[Edge] Fake selection's content bleeds into editable.

Reported by: Tomasz Jakut Owned by: Tomasz Jakut
Priority: Normal Milestone: CKEditor 4.5.11
Component: General Version: 4.5.11
Keywords: Cc:

Description

Steps to reproduce

  1. Open http://ckeditor.dev/plugins/placeholder/samples/placeholder.html.
  2. Focus the placeholder widget.
  3. Press Ctrl+B.

Expected result

Widget's content is bolded.

Actual result

Contents of hidden fake selection (sample placeholder placeholder widget) appears in the editable.

Note also the position of cursor after focusing the widget (it's at the end of the editable, but shouldn't be visible at all).

Other details (browser, OS, CKEditor version, installed plugins)

Edge 14.14393

Change History (6)

comment:1 Changed 8 years ago by Tomasz Jakut

Status: newconfirmed

comment:2 Changed 8 years ago by Tomasz Jakut

Owner: set to Tomasz Jakut
Status: confirmedassigned

comment:3 Changed 8 years ago by Tomasz Jakut

Status: assignedreview

Actually there were two issues with the fake selection in new Edge.

The main issue was connected with the removeSuperflouosElement function from wysiwygarea plugin. It was replacing the hidden selection's container after activating editor's functions via keyboard. I've added the check to ignore all temporary elements created by the editor.

The second issue was connected with the creation of hidden selection container. In the previous versions of IE and Edge everything was working fine with elements with display: none. However it seems that Edge 14+ doesn't like selection in such elements anymore, so now it uses element positioned off-screen (as all other browsers).

There was also one failing unit test for fake selection. Simple switching from element's selection to text selection for Edge 14+ seems to do the trick.

Pushed fix to branch:t/14831.

comment:4 Changed 8 years ago by Marek Lewandowski

Fix does the job.

I've added couple of commits reducing amount of changes because there were much more changes than needed compared to the master branch.

Pushed to the branch:t/14831.

comment:5 Changed 8 years ago by Tomasz Jakut

Actually the changes you reverted was introduced to the fact that our linter treated the former version of code as invalid. Therefore I had to rearrange some things just to satisfy it.

So I've reverted this commit. All other changes LGTM. Pushed back to branch:t/14831.

comment:6 Changed 8 years ago by Marek Lewandowski

Resolution: fixed
Status: reviewclosed

Sorry, I've missed that.

Merged to master with git:60d4db9.

Last edited 8 years ago by Marek Lewandowski (previous) (diff)
Note: See TracTickets for help on using tickets.
© 2003 – 2022, CKSource sp. z o.o. sp.k. All rights reserved. | Terms of use | Privacy policy