NEW 23507
pressing enter inside a list item doesn't create new list item
https://bugs.webkit.org/show_bug.cgi?id=23507
Summary pressing enter inside a list item doesn't create new list item
Deepak Jindal
Reported 2009-01-23 11:39:53 PST
Take the following html in which the list item is inside a div: <ul><li><div>foobar</div></li></ul> Place your cursor between foo and bar and press enter. A new list item should be created.
Attachments
Ryosuke Niwa
Comment 1 2009-06-19 01:20:17 PDT
(In reply to comment #0) > Take the following html in which the list item is inside a div: > > <ul><li><div>foobar</div></li></ul> > > Place your cursor between foo and bar and press enter. A new list item should > be created. > I tried three different browsers (Firefox 3, MSIE 7, and Safari). Only Firefox inserts new list. Because div is a block element, I don't think inserting a new line within a div shouldn't be splitting the div. On the other hand, when I'm at the end of "foobar", I feel like I should be able to start new item by pressing enter (MSIE and WebKit doesn't let you create new list item at all.)
Ryosuke Niwa
Comment 2 2009-06-19 01:23:22 PDT
Sorry, I submitted the comment prematurely with lots of typo. Here's a slightly better version of it: I tried three different browsers (Firefox 3, MSIE 7, and Safari), and only Firefox inserted a new list item. Because div is a block element, I don't think inserting a new line within a div should be splitting the div. On the other hand, when I'm at the end of "foobar", I feel like I should be able to insert a new list item by pressing enter (MSIE and WebKit don't let you create new list item at all.)
Ryosuke Niwa
Comment 3 2009-08-03 16:01:23 PDT
Apparently, MSIE8 DOES create new list item. Perhaps they have changed the behavior since MSIE7 or that I didn't test well.
Marcos Almeida
Comment 4 2009-09-29 13:22:47 PDT
This is still an issue and affects Google properties.
Aryeh Gregor
Comment 5 2011-08-19 12:31:38 PDT
Currently my spec agrees with WebKit, but I agree with comment #0 that splitting the list item makes more sense. I've filed a spec bug: http://www.w3.org/Bugs/Public/show_bug.cgi?id=13841
Note You need to log in before you can comment on or make changes to this bug.