Lazy load images
This commit is contained in:
parent
48086358d2
commit
04d5f20b46
@ -8,27 +8,29 @@
|
||||
<!-- <link rel="stylesheet" href="https://unpkg.com/bulma-dracula"> -->
|
||||
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bulma@0.9.4/css/bulma.min.css">
|
||||
|
||||
<style>
|
||||
.cardpreview {
|
||||
<style>
|
||||
.cardpreview {
|
||||
position: relative;
|
||||
display: inline-block;
|
||||
border-bottom: 1px dotted black;
|
||||
}
|
||||
}
|
||||
|
||||
.cardpreview .cardpreviewtext {
|
||||
.cardpreview .cardpreviewtext {
|
||||
visibility: hidden;
|
||||
display: none;
|
||||
width: 300px;
|
||||
color: #fff;
|
||||
|
||||
/* Position the cardpreview */
|
||||
position: absolute;
|
||||
z-index: 1;
|
||||
}
|
||||
}
|
||||
|
||||
.cardpreview:hover .cardpreviewtext {
|
||||
.cardpreview:hover .cardpreviewtext {
|
||||
visibility: visible;
|
||||
}
|
||||
</style>
|
||||
display: inline-block;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
|
||||
|
||||
@ -64,7 +66,8 @@
|
||||
<select name="set" id="set" form="searchform">
|
||||
<option value="">-</option>
|
||||
{{range .sets}}
|
||||
<option value="{{ index . "code" }}">{{ printf "%.25s" (index . "_id") }} ({{ index . "count" }})</option>
|
||||
<option value="{{ index . "code" }}">{{ printf "%.25s" (index . "_id") }} ({{ index . "count" }})
|
||||
</option>
|
||||
{{end}}
|
||||
</select>
|
||||
</div>
|
||||
@ -141,12 +144,12 @@
|
||||
<tr>
|
||||
<td>{{.SerraCount}}</td>
|
||||
<td>
|
||||
<div class="cardpreview"><strong>{{.Name }}</strong>
|
||||
<div class="cardpreview"><strong>{{.Name }}</strong>
|
||||
<span class="cardpreviewtext">
|
||||
<img src="{{ .ImageUris.Normal }}" alt="" />
|
||||
<img loading="lazy" src="{{ .ImageUris.Normal }}" alt="" />
|
||||
</span>
|
||||
</div>
|
||||
</td>
|
||||
</div>
|
||||
</td>
|
||||
<td>{{.TypeLine}}</td>
|
||||
<td>{{.Set}}</td>
|
||||
<td>{{.CollectorNumber}}</td>
|
||||
@ -160,7 +163,7 @@
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
</body>
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user