busdepartures/index.html

51 lines
1.4 KiB
HTML

<!DOCTYPE html>
<html lang="nl">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="application-name" content="Busvertrektijden">
<meta name="theme-color" content="#000000">
<meta name="description" content="Actuele busvertrektijden">
<meta name="robots" content="noindex">
<link rel="icon" type="img/png" href="/static/img/bus16x16.png" sizes="16x16">
<link rel="icon" type="img/png" href="/static/img/bus32x32.png" sizes="32x32">
<link rel="icon" type="img/png" href="/static/img/bus192x192.png" sizes="192x192">
<link rel="stylesheet" href="/static/css/busdepartures.css">
<title>Busvertrektijden</title>
</head>
<body>
<header>
<h1>Busvertrektijden</h1>
</header>
<main>
{{ range .Quays }}
<article>
<h2>{{ .Name }}</h2>
<p>{{ .Town }}</p>
<table>
<tbody>
{{ range $i, $val := .Departures }}
{{ if lt $i 3 }}
<tr>
<td>{{ $val.RouteShortName }}</td>
<td>{{ $val.StopHeadsign }}</td>
{{ if $val.HasRealtimeDepartureTime }}
<td><time class="{{ if $val.IsDelayed }}delayed{{ else }}on-time{{ end }}">{{ formatTime $val.RealtimeDepartureTime }}</time></td>
{{ else }}
<td><time>{{ formatTime $val.DepartureTime }}</time></td>
{{ end }}
</tr>
{{ end }}
{{ end }}
</tbody>
</table>
</article>
{{ end }}
</main>
</body>
</html>