W3C home > Mailing lists > Public > www-style@w3.org > August 2014

[CSS2.1] Default margins on inputs

From: Greg Whitworth <gwhit@microsoft.com>
Date: Thu, 28 Aug 2014 21:24:37 +0000
To: Robert Hogan <robhogan@gmail.com>, Tab Atkins Jr. <jackalmage@gmail.com>, "www-style@w3.org" <www-style@w3.org>
Message-ID: <d66ee6aa282747d08c77a17f254b689a@DM2PR03MB400.namprd03.prod.outlook.com>
Hello Robert & Tab,

We are working on a bug right now and are trying to achieve interop with Blink regarding the 2px default margin on text input (which is what is causing the layout to "break" in IE) and we noticed some odd behavior regarding those margins. If a width is set on the input then margin-right and margin-left are reset to 0 (this seems to involve all input types currently besides color which behaves the same as IE/FF). If a height is set then margin-top and margin-bottom are reset to 0. I do not want to implement this inconsistent and am curious if Blink would be willing to either have the margins remain consistent no matter the dimensions, or set the defaults to 0px to achieve interop with FF and IE.

Here is a fiddle of the example with default styles:  http://jsfiddle.net/pxb5d1hh/2/
Here is a fiddle with a width and height set: http://jsfiddle.net/pxb5d1hh/3/

I'm also interested to know what other authors or implementers thoughts are on this matter.

Thank you,
Received on Thursday, 28 August 2014 21:25:09 UTC

This archive was generated by hypermail 2.4.0 : Monday, 23 January 2023 02:14:43 UTC