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


From: Nick Manning <nmanning@inc.com>
Date: Tue, 16 Sep 2014 08:48:50 +0000
Message-ID: <CAAe=mF+cwJ7hC28i4bvMTkOdg7H48zRpuCdxxdAiQn30YjXuiA@mail.gmail.com> (sfid-20140916_084857_874824_41D55437)
To: www-style@w3.org
I have a suggestion for flex box. Can there be a max-lines or max-rows
attribute? What if I have a flex box (justify-content:space-between) with
*n* flex items whose widths are determined by the text inside. As the
browser shrinks to the point where there is no more space in between the
flex-items, you want it to wrap to two rows of items. No problem, just
apply flex-wrap:wrap,...but then when you shrink the flexbox further, once
this double rowed flexbox has no more space in between the flex-items, you
do not want it to wrap to three rows---rather you want it to begin to
shrink the flex-items themselves. You can't change to flex-wrap:nowrap
because then it will go back to one row. The only option is to use

This problem could be solved with the following elegant style:

..container {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;

Received on Wednesday, 17 September 2014 15:52:18 UTC

This archive was generated by hypermail 2.3.1 : Monday, 2 May 2016 14:39:24 UTC