I'm facing a challenge in making the iframe
element stretch to occupy the remaining space within my web application. While I have ensured that the maximum space is allocated for the div
by setting a border, the iframe
's height does not automatically expand to fill the entire vertical height.
The issue lies with the row content
iframe
not utilizing the complete vertical space, despite the flexbox correctly allocating the space.
Any suggestions on how to address this?
.box {
display: flex;
flex-flow: column;
height: 100vh;
}
.box .row.header {
flex: 0 1 auto;
}
.box .row.content {
flex: 1 1 auto;
}
.box .row.footer {
flex: 0 1 40px;
}
.row.content iframe {
width: 100%;
border: 0;
}
<div class="box">
<div class="row header">
<h1>Event Details</h1>
<div id="container">
<h5>Test</h5>
</div>
<div data-role="navbar">
<ul>
<li><a href="players.html" class="ui-btn-active ui-state-persist">Players</a>
</li>
<li><a href="games.html">Games</a>
</li>
<li><a href="chat.html">Chat</a>
</li>
</ul>
</div>
</div>
<div class="row content">
<iframe src="players.html"></iframe>
</div>
<div class="row footer">
<p><b>footer</b> (fixed height)</p>
</div>
</div>