Skip to content

Commit

Permalink
refactor(layouts): responsive images
Browse files Browse the repository at this point in the history
  • Loading branch information
alebabai committed Mar 28, 2024
1 parent 2d9a77a commit ff12139
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion layouts/404.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<h1>{{ .Title }}</h1>
{{ .Content }}
{{- with resources.Get "images/apache.jpg"}}
<img src="{{ .RelPermalink }}" width="500" alt="Attack helicopter">
<img src="{{ .RelPermalink }}" alt="Attack helicopter" style="width:100%; max-width: 500px; height: auto;">
{{- end }}
{{- end }}
{{- end }}
2 changes: 1 addition & 1 deletion layouts/index.html
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{{- define "main" }}
{{ .Content }}
{{- with resources.Get "images/luffy.png"}}
<img src="{{ .RelPermalink }}" alt="Monkey D. Luffy" height="400">
<img src="{{ .RelPermalink }}" alt="Monkey D. Luffy" style="max-width: 100%; height: auto; max-height: 350px;">
{{- end }}
{{- end }}

0 comments on commit ff12139

Please sign in to comment.