1
Fork 0

Constrain image item

This commit is contained in:
Jake Howard 2017-05-09 09:36:14 +01:00
parent de0ecb1e4b
commit 4e000eb359
2 changed files with 9 additions and 8 deletions

View file

@ -6,6 +6,9 @@
</header> </header>
{{ if .Content }} {{ if .Content }}
<div class="box"> <div class="box">
{{ if .Params.image }}
<span class="image featured"><img src="{{ .Params.image }}" alt="{{ .Title }} image" /></span>
{{ end }}
{{ .Content }} {{ .Content }}
</div> </div>
{{ end }} {{ end }}

View file

@ -8,14 +8,8 @@ $fa-font-path: "../fonts";
@import "alpha"; @import "alpha";
.box { .box .box {
&:not(.image) { border-radius: 0;
padding: 2em;
}
.box {
border-radius: 0;
}
} }
.dropotron { .dropotron {
@ -37,3 +31,7 @@ pre code {
background: none; background: none;
padding: 0; padding: 0;
} }
.image.featured {
max-height: 45vh;
}