Change hero details size
This commit is contained in:
parent
9e7567ab25
commit
2ee0108d97
2 changed files with 30 additions and 14 deletions
|
@ -3,13 +3,15 @@
|
|||
<link rel="stylesheet" href="./index.scss" />
|
||||
</head>
|
||||
<body>
|
||||
<div class="hero">
|
||||
<div class="hero" id="hero">
|
||||
<div class="details-wrapper" id="details">
|
||||
<div class="details">
|
||||
<small>Breadcrumb</small>
|
||||
<h1>Title</h1>
|
||||
<p>Details</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="content-wrapper">
|
||||
<p>Content</p>
|
||||
<img src="https://placehold.co/2000x200" />
|
||||
|
@ -17,6 +19,21 @@
|
|||
<img src="https://placehold.co/2000x200" class="inset" />
|
||||
<img src="https://placehold.co/2000x200" class="half-bleed" />
|
||||
<img src="https://placehold.co/2000x200" class="full-bleed" />
|
||||
<p>Content</p>
|
||||
<p>Content</p>
|
||||
<p>Content</p>
|
||||
<p>Content</p>
|
||||
<p>Content</p>
|
||||
<p>Content</p>
|
||||
<p>Content</p>
|
||||
<p>Content</p>
|
||||
<p>Content</p>
|
||||
<p>Content</p>
|
||||
<p>Content</p>
|
||||
<p>Content</p>
|
||||
<p>Content</p>
|
||||
<p>Content</p>
|
||||
<p>Content</p>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
|
|
|
@ -9,26 +9,25 @@ html {
|
|||
$content-width: 85ch;
|
||||
$content-padding: 16px;
|
||||
$bleed-ratio: 0.2;
|
||||
$details-padding: 1rem;
|
||||
|
||||
.hero {
|
||||
height: 45vh;
|
||||
height: 50vh;
|
||||
background-color: red;
|
||||
display: flex;
|
||||
align-items: flex-end;
|
||||
|
||||
.details {
|
||||
padding: $details-padding;
|
||||
.details-wrapper {
|
||||
padding: 1rem;
|
||||
background-color: rgba(0, 0, 0, 0.4);
|
||||
color: white;
|
||||
line-height: 1;
|
||||
width: calc(#{$content-width} - 2 * $details-padding);
|
||||
margin: 0 auto;
|
||||
|
||||
&:hover {
|
||||
opacity: 1;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.details {
|
||||
width: $content-width;
|
||||
margin: 0 auto;
|
||||
|
||||
h1 {
|
||||
margin: 0;
|
||||
margin-bottom: 0.75rem;
|
||||
|
|
Loading…
Reference in a new issue