Skip to content

Commit

Permalink
Merge pull request #13 from Astylodon/lazy
Browse files Browse the repository at this point in the history
Fix preview issues
  • Loading branch information
TheIndra55 authored May 15, 2024
2 parents 045388a + b13c21d commit e319ca4
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 2 deletions.
4 changes: 4 additions & 0 deletions _internal/css/index.css
Original file line number Diff line number Diff line change
Expand Up @@ -162,4 +162,8 @@ video, audio {
.preview-title {
display: inline;
margin-right: 1em;
}

.preview-content {
margin: 1em 0;
}
2 changes: 1 addition & 1 deletion _internal/templates/displays/image.html.twig
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
{{ file.name }}
</p>
{% else %}
<img src="{{ file | getFilePath(path.full) }}" alt=""/>
<img loading="lazy" src="{{ file | getFilePath(path.full) }}" alt=""/>
{% endif %}
</div>
</a>
Expand Down
2 changes: 1 addition & 1 deletion _internal/templates/index.html.twig
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
<template id="filepreview">
<h2 class="preview-title"></h2> <a class="button" download>Download</a>

<div id="content" style="margin-bottom: 1em;">
<div class="preview-content">

</div>
</template>
Expand Down

0 comments on commit e319ca4

Please sign in to comment.