[Webkit-unassigned] [Bug 37944] New: last-child of a list are not styled correctly when the entire list is replaced at once

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed Apr 21 12:57:34 PDT 2010


https://bugs.webkit.org/show_bug.cgi?id=37944

           Summary: last-child of a list are not styled correctly when the
                    entire list is replaced at once
           Product: WebKit
           Version: 528+ (Nightly build)
          Platform: All
               URL: http://media.rawdod.com/webkit_last_child_regen_bug.ht
                    ml
        OS/Version: All
            Status: UNCONFIRMED
          Severity: Normal
          Priority: P2
         Component: CSS
        AssignedTo: webkit-unassigned at lists.webkit.org
        ReportedBy: rawdod at gmail.com
                CC: hyatt at apple.com


Here is a link to a demo:

http://media.rawdod.com/webkit_last_child_regen_bug.html

This is a hacked up copy and paste of the source of:
http://www.quirksmode.org/css/firstchild.html

I have confirmed this bug happens on the latest chromium for linux and also the
latest safari for windows.

I have confirmed this works fine on the latest firefox for linux.   

I expect nothing platform specific about this bug from that...


>From what I am told, webkit should know to reparse the list and style it
correctly when you replace the whole list, but it does not. 

This also happens when styling based on the last child of a class, thats how I
found it, for example, if I replace this entire admin menu at once, I loose the
border-right property being 0 on the last navigation class:

Example of structure:

    ul.navigation {

    float: left;
    display: block;
    height: 75px;
    margin: 0 12px 0 2px;
    border-right: 1px dotted #9a9a9a;
    padding: 0 14px 0 0;
    list-style-image: none;    
    list-style-type: none;    
    line-height: 25px;

    }

    ul.navigation:last-child {

    border-right: 0;

    }


<ul class="navigation">
 <li><%= link_to "Realtor Appointments", :controller =>
"admin/realtorappointments/list" %></li>
 <li><%= link_to "Lender Appointments", :controller =>
"admin/mortgagelenderappointments/list" %></li>
 <li><%= link_to "Moving Appointments", :controller =>
"admin/moving_and_storage_appointments/list" %></li>
</ul>
<ul class="navigation">
 <li><%= link_to "Messages", :controller => "admin/messages", :action => "list"
%></li>    
 <li><%= link_to "Reports", :controller => "admin/reports", :action => "list"
%></li>    
 <li><%= link_to "Recent Logins", :controller => "admin/logs", :action =>
"recent_logins" %></li>    
</ul>
<ul class="navigation">
 <li><%= link_to "Logs", :controller => "admin/logs", :action => "view" %></li>
 <li><%= link_to "Console", :controller => "admin/logs", :action => "console"
%></li>
 <li><%= link_to "Imports", :controller => "admin/imports", :action => "view"
%></li>
</ul>
<ul class="navigation">
 <li><%= link_to "Marketing Material Orders", :controller =>
"admin/logs/material_orders" %></li>
</ul>

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list