W3C home > Mailing lists > Public > www-style@w3.org > May 2008

border-radius on replaced elements

From: David Hyatt <hyatt@apple.com>
Date: Wed, 14 May 2008 15:23:43 -0500
To: www-style <www-style@w3.org>
Message-id: <E8A297FA-DA67-4F81-8319-743903C5993B@apple.com>

With the image-fit and image-position properties and border-radius,  
we're clearly moving in a direction where overflow needs to be  
supported on replaced elements.  One of the use cases that has come up  
over and over again for Apple has been rounded corners on <img> and  
<video> elements.  I believe that - by default - a border-radius  
should clip the foreground content of replaced elements.  However I  
also think that the foreground content of replaced elements could be  
considered overflow (for compatibility with the image-fit and image- 
position properties).

I'd like to propose that the suggested UA default be:

img, video, input[type=image] { overflow: hidden }

For these elements (and possibly some others that I might not be  
thinking of).

Alternatively we could just allow UAs to apply the border-radius clip  
to replaced elements at their discretion.  I believe it's important  
that authors not have to do anything to get the right behavior,  
though, since the author expectation is that the border-radius should  
clip the image.

Received on Wednesday, 14 May 2008 20:24:24 UTC

This archive was generated by hypermail 2.3.1 : Monday, 2 May 2016 14:27:36 UTC