Re: [css-flexbox] Flex box does not respect inline children/groupings

> > (And it doesn't matter - inline-block is still an inline-level box,
> > same as display:inline itself.)
>
> I am not sure I understand you here.to be honest.
> inline-block establishes box, inline element is a run of
> glyphs/inline-elements - is not a box by itself.

An inline-block element is inline-level, but enjoys characteristics of
block-level elements.

> >
> >> I think that inline elements should stay inline - flexbox shall not
> >> try to change "boxing nature" of its children.

I don't understand the problem. Isn't the whole idea of declaring `display:
flex` on an element that its children can become flex items?

If so, then it seems logical that anonymous boxes of text become flex items
themselves as well.

> When you apply flexbox on span's container that span gets
> treated as boxed element loosing its display:inline nature.
>
> Check this,
>
> <html>
>   <head>
>     <style>
>       div.flex { display:flex; }
>       div span { border: 1px solid; }
>     </style>
>     <script type="text/tiscript"></script>
>   </head>
> <body>
>   <div>
>     The <span>quick brown fox jumps over the lazy</span> dog
>   </div>
>   <div class="flex">
>     The <span>quick brown fox jumps over the lazy</span> dog
>   </div>
> </body>
> </html>
>
> two divs here should be rendered in the same way.
> That's what Eric was asking about I believe.

To me, in this example, the whole point of making a flex container of the
containing div would be to have the following blocks become flex items:

- "The"
- <span>quick brown fox jumps over the lazy</span>
- "dog"

That would be the whole point of using flexbox here, right?

- Stephen

Received on Wednesday, 19 February 2014 22:25:07 UTC