ketr.photos/clusters-pre
James Ketrenos 0ed48fd7f7 Clustering scanner
Signed-off-by: James Ketrenos <james_gitlab@ketrenos.com>
2020-01-07 23:17:24 -08:00

35 lines
794 B
Plaintext

<html>
<script>'<base href="BASEPATH">';</script>
<script>
document.addEventListener("DOMContentLoaded", (event) => {
clusters.forEach((cluster, index) => {
var div = document.createElement("div");
div.textContent = "Cluster " + (index + 1);
document.body.appendChild(div);
cluster.forEach((id) => {
var div = document.createElement("div");
div.classList.add("face");
div.style.backgroundImage = "url(face-data/" + (id % 100) + "/" + id + "-original.png)";
document.body.appendChild(div);
});
});
});
</script>
<style>
body {
margin: 0;
padding: 0;
}
.face {
width: 128px;
height: 128px;
background-size: contain;
background-position: center center;
display: inline-block;
border: 1px solid black;
margin: 0.5em;
}
</style>