I
I
Igor Lanko2015-06-22 22:15:01
css
Igor Lanko, 2015-06-22 22:15:01

Is it possible to wrap an element inside a Flexbox container?

Greetings!
Has a parent:

.wrap {
   display: flex;
   flex-wrap: wrap;
}

And two children:
.block {
   height: 100%;
}

.mini {
   height: 25%;
}

I want like this:
ae16073a02d44be5850dc472e90570db.PNG
But it turns out like this:
ffbdb6937ccf43718a72a0d1300105cd.PNG
Important:
1. Flexbox must be used
2. There must be no third-party attachments to the .wrap parent
3. Is this even real?
Current sample code on JSFiddle

Answer the question

In order to leave comments, you need to log in

1 answer(s)
V
Valery, 2015-06-22
@zzloy

jsfiddle.net/4cghpvyo/19

.wrap {
    flex-wrap: wrap;
    flex-direction: column;
}

.mini {
    box-sizing: border-box;
}

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question