igar/templates/index.html

128 lines
2.3 KiB
HTML

<!DOCTYPE html>
<html lang="es">
<head>
<title>bitácora fotográfica de danoloan</title>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel=stylesheet href="/static/style.css">
<link rel="shortcut icon" type="image/jpg" href="/favicon.jpg">
<style>
body {
max-width: 990px;
position: relative;
}
header {
padding: 0px 5px;
margin-bottom: 10px;
}
main {
margin: 0px auto;
text-align: center;
font-size: 0px;
}
nav {
position: absolute;
top: 25px;
right: 25px;
}
nav > a {
margin: 5px 0px;
}
.elem {
margin: 0px auto;
padding: 5px;
width: calc((100% - 30px) / 3);
max-width: 320px;
aspect-ratio: 1/1;
transition: transform .2s;
position: relative;
display: inline-block;
}
.elem:hover {
transform: scale(1.025);
z-index: 10;
}
.elem > * {
width: 100%;
}
.type {
width: 10%;
position: absolute;
top: 7%;
right: 7%;
}
@media screen and (max-width: 990px) {
body {
padding: 0px;
}
header {
padding: 0px 1em;
}
nav {
position: initial;
text-align: center;
margin-bottom: 1em;
}
.elem {
padding: 1px;
width: calc((100% - 6px) / 3);
}
}
@media (prefers-color-scheme: light) {
nav > a {
background-color: #eee;
}
nav > a:hover {
background-color: #ddd;
}
}
</style>
</head>
<body>
<header>
<h1>
<a href="..">danoloan</a>
</h1>
<p>
bitácora fotográfica
</p>
<p style="font-size: 70%">
la representación gráfica de mi déficit de atención, ordenada de forma cronológica
</p>
</header>
<nav>
<a class="button" href="rss">RSS</a>
<a class="button" href="json">JSON</a>
<a class="button" href="atom">Atom</a>
<a class="button" href="admin/">Zona del admin 😎</a>
</nav>
<main>
{{ range . }}
<a id="{{ .Post }}"
href="view?uuid={{ .Post }}"
class="elem">
<img class="thumb" src="img/{{ .Post }}/thumb.jpg" loading="lazy">
{{ if gt (len .Media) 1 }}
<img class="type" alt="galería" src="static/gallery.png" loading="lazy">
{{ else if eq (index .Media 0).Type "GraphVideo" }}
<img class="type" alt="galería" src="static/video.png" loading="lazy">
{{ end }}
</a>
{{ end }}
</main>
<div id="load">
</div>
</body>
</html>