Skip to content

Commit

Permalink
minor: Figures, Quote CSS adjustments
Browse files Browse the repository at this point in the history
  • Loading branch information
chollinger93 committed Apr 8, 2023
1 parent 6cf1bd0 commit f0ebea1
Show file tree
Hide file tree
Showing 2 changed files with 38 additions and 13 deletions.
39 changes: 28 additions & 11 deletions layouts/shortcodes/figure.html
Original file line number Diff line number Diff line change
@@ -1,18 +1,35 @@
<!-- image -->
<figure {{ with .Get "class" }}class="{{.}}"{{ end }}>
{{ with .Get "link" }}<a href="{{ . }}">{{ end }}
<img src="{{ .Get "src" }}" {{ if or (.Get "alt") (.Get "caption") }}alt="{{ with .Get "alt" }}{{ . }}{{ else }}{{ .Get "caption" }}{{ end }}"{{ end }} />
<img src="{{ .Get "src" }}"
{{ if or (.Get "alt") (.Get "caption") }}alt="{{ with .Get "alt" }}{{ . }}{{ else }}{{ .Get "caption" }}{{ end }}"{{ end }} />
{{ if .Get "link" }}</a>{{ end }}

{{ if or (or (.Get "title") (.Get "caption")) (.Get "attr") }}
<figcaption>{{ if isset .Params "title" }}
{{ .Get "title" }}{{ end }}
{{ if or (.Get "caption") (.Get "attr") }}<p>
{{ .Get "caption" }}
{{ with .Get "attrlink" }}<a href="{{ . }}"> {{ end }}
{{ .Get "attr" }}
{{ if .Get "attrlink" }}</a> {{ end }}
</p> {{ end }}
</figcaption>
<figcaption>
{{ if isset .Params "title" }}
{{ .Get "title" }}
{{ end }}

{{ if or (.Get "caption") (.Get "attr") }}
<p style="margin: -0.5rem 0 0 0;">
{{ .Get "caption" }}


{{ with .Get "attrlink" }}
<a href="{{ . }}">
{{ end }}
{{ if .Get "attr" }}
<small style="margin: -0.5rem 0 0 0;">
[{{ .Get "attr" }}]
</small>
{{ end }}
{{ if .Get "attrlink" }}</a>
{{ end }}

</p>
{{ end }}
</figcaption>
{{ end }}
</figure>
<!-- image -->
<!-- image -->
12 changes: 10 additions & 2 deletions static/css/main.css
Original file line number Diff line number Diff line change
Expand Up @@ -106,11 +106,11 @@ textarea {
blockquote {
margin-left: 1rem;
font-style: italic;
font-size: 1.4rem;
font-size: 1.1rem;
font-family: Georgia, bitstream charter, serif;
border-left: 3px solid;
border-color: #3700ff;
padding-left: 20px;
padding-left: 15px;
}

blockquote cite {
Expand All @@ -122,6 +122,10 @@ blockquote em {
font-weight: 600;
}

blockquote code {
font-size: 0.8rem;
}


h1, h2, h3, h4, h5, h6 {
color: #333;
Expand Down Expand Up @@ -514,3 +518,7 @@ code:not(pre *) {
background-color: rgb(239, 241, 243);
font-size: 95%;
}

code {
font-size: 0.8rem;
}

0 comments on commit f0ebea1

Please sign in to comment.