tilde.town/age2.html

43 lines
991 B
HTML

<!DOCTYPE html>
<meta charset="utf-8">
<title>how old am I?</title>
<style>
body {
min-height: 100vh;
margin: 0; padding: 0;
display: flex;
flex: column nowrap;
align-items: center;
background: #455;
font: 18px/1.23 monospace;
} main {
max-width: 70ch;
width: 100%;
padding: 2ch;
margin: auto;
border: 1px solid;
color: #455;
background: #fee;
} .age,.countdown {
padding: 4px;
} .age { background: yellow; }
.cumulative .desc:not(:last-child)::after {
content: ", ";
}
.cumulative .desc:nth-last-child(2)::after {
content: ", and" !important;
}
.countdown { background: lime; }
aside{position:absolute;bottom:0;right:0;background:white;}
</style>
<body>
<aside>cf. also <a href="age.html">another accounting</a>,
or <a href="index.html">return</a>.</aside>
<main id="main">hmm....</main>
<script src="age.js"> </script>
<script>
window.onload = init;
var updateID = window.setInterval(update, 1000);
</script>
</body>