Opened 12 years ago
Closed 12 years ago
#9136 closed Bug (fixed)
[Webkit] Enter key scrolls down the page when CKEditor is in absolutely-positioned div
Reported by: | mike1 | Owned by: | |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | General | Version: | 3.6.3 |
Keywords: | Webkit | Cc: |
Description (last modified by )
Ckeditor 3.6.3 + Windows XP SP3 + latest Chrome browser. When I hit 'Enter' inside the editor, the cursor goes to the next line AND the entire page scrolls down to the end. See the attached sample. Ckeditor 3.6.2 does not have this bug.
This is happening when position: absolute is set on surrounding <div> element or when body has height:100% set or when editor is inside a float element.
Attachments (4)
Change History (14)
Changed 12 years ago by
comment:1 Changed 12 years ago by
Keywords: | Chrome added |
---|---|
Status: | new → confirmed |
Summary: | 'Enter' key scrolls down the page → [Chrome] Enter key scrolls down the page when CKEditor is in absolutely-positioned div |
Version: | → 3.6.3 |
Broken by [7399].
Use the attached replacebyclass sample to reproduce. When position: absolute
is removed from surrounding <div> element, everything works as expected.
Changed 12 years ago by
Attachment: | replacebyclass.html added |
---|
comment:3 Changed 12 years ago by
Please fix this soon. I am experiencing the same issue. Some more details that I've noticed are that the problem doesn't happen unless the bottom of the CKEditor text area is out of view in the browser window. Also, the cursor seems to stay in the same position on the page once the whole page starts scrolling, until the bottom of the page is hit and it can't scroll down anymore.
comment:4 Changed 12 years ago by
I've discovered this also occurs when height: 100% is set on the html and body tags of the parent HTML page, which is a fairly common occurrence.
To reproduce:
- Visit ckeditor.com/demo
- Shrink your browser window so a sizeable scrollbar is shown
- Using the inspector tool, add "style='height: 100%' " to the html tag and body tag
- Place your cursor in CK Editor and press enter
In certain cases workaround to height:100% might be usage of height:auto;.
comment:5 Changed 12 years ago by
Description: | modified (diff) |
---|
comment:6 Changed 12 years ago by
Description: | modified (diff) |
---|---|
Keywords: | Webkit added; Chrome removed |
Summary: | [Chrome] Enter key scrolls down the page when CKEditor is in absolutely-positioned div → [Webkit] Enter key scrolls down the page when CKEditor is in absolutely-positioned div |
Changed 12 years ago by
Attachment: | 9523_tc.html added |
---|
comment:8 follow-up: 9 Changed 12 years ago by
I managed to resolve this issue by adding these lines in CKEditor/trunk/_source/core/dom/element.js on line 1418
if ( parent.is( 'body' ) ) { overflowed = false; }
comment:9 Changed 12 years ago by
Replying to thijs:
I managed to resolve this issue by adding these lines in CKEditor/trunk/_source/core/dom/element.js on line 1418
if ( parent.is( 'body' ) ) { overflowed = false; }
Could you specify please surrounding lines?
comment:10 Changed 12 years ago by
Resolution: | → fixed |
---|---|
Status: | confirmed → closed |
I have checked test case files attached to this ticket and issue seems to be working fine in latest Webkit and CKEditor 4.1.2. I'm closing this issue as fixed.
'enter' scrolls down