- From: Tab Atkins Jr. <jackalmage@gmail.com>
- Date: Thu, 14 Mar 2013 16:57:47 -0700
- To: Ojan Vafai <ojan@chromium.org>
- Cc: Andrew Fedoniouk <news@terrainformatica.com>, www-style list <www-style@w3.org>
On Wed, Mar 6, 2013 at 7:50 PM, Ojan Vafai <ojan@chromium.org> wrote: > What are the use-cases for percentage margin/padding? The block approach is > easier to implement. I don't understand how this is possible. Why is it easier to compute a percentage height than a percentage padding/margin? The calculations are identical. The reason percentages on blocks work the way they do is because blocks are nearly always auto-height, so in almost all cases percentages can't be resolved, so resolving against the width instead at least gives you *something* useful. In flexbox, the height will often be a definite size, so it makes sense for percentages on vertical padding/margins to be consistent with percentages on heights. ~TJ and fantasai
Received on Thursday, 14 March 2013 23:58:34 UTC