mirror of
https://github.com/muety/wakapi.git
synced 2023-08-10 21:12:56 +03:00
50 lines
1.5 KiB
HTML
50 lines
1.5 KiB
HTML
<!DOCTYPE html>
|
|
<html lang="en">
|
|
|
|
{{ template "head.tpl.html" . }}
|
|
|
|
<script>
|
|
const defaultTab = 'total'
|
|
</script>
|
|
|
|
<body class="relative bg-gray-900 text-gray-700 p-4 pt-10 flex flex-col min-h-screen {{ if .User }} max-w-screen-xl {{ else }} max-w-screen-lg {{end}} mx-auto justify-center">
|
|
|
|
{{ template "alerts.tpl.html" . }}
|
|
|
|
{{ if .User }}
|
|
{{ template "menu-main.tpl.html" . }}
|
|
{{ else }}
|
|
{{ template "header.tpl.html" . }}
|
|
{{ template "login-btn.tpl.html" . }}
|
|
{{ end }}
|
|
|
|
<main class="mt-10 flex-grow flex justify-center w-full" id="leaderboard-page">
|
|
<div class="flex flex-col flex-grow mt-10">
|
|
<h1 class="font-semibold text-3xl text-white m-0 mb-4">Leaderboard</h1>
|
|
|
|
<ul class="flex space-x-4 mb-16 text-gray-600">
|
|
<li class="font-semibold text-2xl {{ if eq .By "" }} text-gray-300 {{ else }} hover:text-gray-500 {{ end }}">
|
|
<a href="leaderboard">Total</a>
|
|
</li>
|
|
<li class="font-semibold text-2xl {{ if eq .By "language" }} text-gray-300 {{ else }} hover:text-gray-500 {{ end }}">
|
|
<a href="leaderboard?by=language">By Language</a>
|
|
</li>
|
|
</ul>
|
|
|
|
<div id="total" class="tab flex flex-col space-y-4">
|
|
<ol>
|
|
{{ range $i, $item := .Items }}
|
|
<li>{{ $item.Rank }} - {{ $item.UserID }} - {{ $item.Total | duration }}</li>
|
|
{{ end }}
|
|
</ol>
|
|
</div>
|
|
</div>
|
|
</main>
|
|
|
|
{{ template "footer.tpl.html" . }}
|
|
|
|
{{ template "foot.tpl.html" . }}
|
|
</body>
|
|
|
|
</html>
|