how can i set a div to adjust to its current content height? in this particualr project i wanna make the supporting project to set its heigth when the columns stops, without setting the height property.
index.html
<!doctype html>
<html>
<head>
<link rel="stylesheet" href="https://s3.amazonaws.com/codecademy-content/projects/bootstrap.min.css">
<link href='https://fonts.googleapis.com/css?family=Oxygen:300,400,700' rel='stylesheet' type='text/css'>
<link rel="stylesheet" type="text/css" href="style.css">
</head>
<body>
<div class="jumbotron">
This file has been truncated. show original
style.css
html, body {
font-family: "Oxygen", sans-serif;
font-weight: 300;
margin: 0;
padding: 0;
}
.jumbotron{
background-color:black;
height:400px;
This file has been truncated. show original
mtf
May 18, 2017, 6:42am
2
The real trick to setting height is not setting it. Let the content dictate. If marrying other objects to the same height when they are shorter… ? That’s a pickle, ain’t it?
index.html
<!doctype html>
<html>
<head>
<link rel="stylesheet" href="https://s3.amazonaws.com/codecademy-content/projects/bootstrap.min.css">
<link href='https://fonts.googleapis.com/css?family=Oxygen:300,400,700' rel='stylesheet' type='text/css'>
<link rel="stylesheet" type="text/css" href="style.css">
</head>
<body>
<div class="jumbotron">
This file has been truncated. show original
style.css
html, body {
font-family: "Oxygen", sans-serif;
font-weight: 300;
margin: 0;
padding: 0;
}
.jumbotron{
background-color:black;
height:400px;
This file has been truncated. show original
there is a white gap between the supporting and the feature div? what cause this?
mtf
May 18, 2017, 6:55am
5
Can’t really say, we have no link to the exercise.
mtf
May 18, 2017, 6:56am
7
No, I mean the actual exercise, not a gist.
mtf
May 18, 2017, 6:59am
9
Yes. We cannot test without it.
ok, sorry. I thhought that the gist has the project information.
mtf
May 18, 2017, 7:16am
11
Now someone may come along who can help you.