Bug 175131 - Context menu change selection in table, which leaks to next cell
Summary: Context menu change selection in table, which leaks to next cell
Status: NEW
Alias: None
Product: WebKit
Classification: Unclassified
Component: HTML Editing (show other bugs)
Version: Safari 10
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2017-08-03 06:19 PDT by m.samsel
Modified: 2017-12-01 08:51 PST (History)
5 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description m.samsel 2017-08-03 06:19:54 PDT
Problem seems to be related to: #32622, behaviour is the same but not for the empty cell.

Steps to reproduce the problem:
1. Open this code snippet https://codepen.io/msamsel/pen/yoaRWP
2. Put cursor caret at the end of cell. After last letter in specific cell
3. Right click to open context menu

You can also use just regular table, with some tools which investigate current selection.

What is the expected behaviour?
Selection won't change, or selection remain inside this same cell

What went wrong?
Selection is enlarged, changed to range type and focusNode point to next cell.
We had caret type selection inside one cell and this create range type selection with 2 cells.

Does this work in other browsers? No
 Behaviour is the same in Chrome

Problem doesn't exist on Firefox.

OS Version: OS X 10.12.6
Flash Version: 

It seems that problem is related to feature which automatically highlight and select word which is right clicked. Unfortunately here selection point to next cell what seems to be not ok.
You can make this same type of selection if you put caret after last letter in cell, and then use Shift + Right Arrow to select next character. This will select 2 cells but not first character in next cell.
Comment 1 Radar WebKit Bug Importer 2017-08-07 23:12:32 PDT
<rdar://problem/33769924>
Comment 2 Piotrek Koszuliński (Reinmar) 2017-09-13 03:21:25 PDT
Is there any progress on this issue? It's literally destroying a table selection in CKEditor.
Comment 3 m.lewandowski 2017-09-13 03:35:15 PDT
Same thing happens in Chrome https://bugs.chromium.org/p/chromium/issues/detail?id=752091