In my project I need to manipulate a standard table to act in a certain way. I need the <td>
to be both columns and rows, depending on content and resolution (responsiveness).
So far it's working in Chrome and FF, but it's completely messed up in IE, and I'm not having any luck in trying to figure out why.
Here's my code:
body {
color: #fff;
}
table,
.line2,
.line3 {
width: 100%;
}
tr {
display: flex;
flex-flow: row wrap;
}
td {
margin: 1px;
}
.line1 {
background: red;
flex: 1;
}
.line2,
.line3 {
background: blue;
}
.line3 {
background: green;
}
<table>
<tr>
<td class="line1">line 1</td>
<td class="line1">line 1</td>
<td class="line1">line 1</td>
<td class="line1">line 1</td>
<td class="line2">line 2</td>
<td class="line3">line 3</td>
</tr>
</table>
What I want is all line1's
to be columns and line2/3
to be rows below.
However, in IE11 (and I'm assuming below) they just all stack up as columns, completely messing it up.
I've looked at https://github.com/philipwalton/flexbugs but haven't been able to find a solution.
What am I doing wrong? Does this just not work in IE?