Recount-Server/web/templates/index.html
2024-01-20 15:05:06 -08:00

76 lines
2.6 KiB
HTML

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="stylesheet" href="/static/site.css">
<script src="/static/htmx.min.js"></script>
<script src="/static/feather.min.js"></script>
<title>{{ .ActivePage }}</title>
</head>
<body class="latte">
<header>
</header>
<div class="d-flex" id="below-header">
<div id="left-col">
<nav>
<ul>
<li>
<a id="logo-a">Recount</a>
</li>
<li>
<a
hx-get="/"
hx-swap="innerHtml swap:0.2s settle:0.2s"
hx-push-url="true"
hx-boost="true"
hx-target="#main-body-content"
{{ if (eq .ActivePage "Dashboard") }}
class="active"
{{ end }}
>
Dashboard
</a>
</li>
<li>
<a
hx-get="/transactions"
hx-swap="innerHtml swap:0.2s settle:0.2s"
hx-push-url="true"
hx-boost="true"
hx-target="#main-body-content"
{{ if (eq .ActivePage "Transactions") }}
class="active"
{{ end }}
>
Transactions
</a>
</li>
</ul>
</nav>
</div>
<div id="main-body-content">
{{.InnerHtml}}
</div>
<div id="right-col">
</div>
</div>
<script src="https://cdnjs.cloudflare.com/ajax/libs/Chart.js/4.4.1/chart.umd.min.js" integrity="sha512-CQBWl4fJHWbryGE+Pc7UAxWMUMNMWzWxF4SQo9CgkJIN1kx6djDQZjh3Y8SZ1d+6I+1zze6Z7kHXO7q3UyZAWw==" crossorigin="anonymous" referrerpolicy="no-referrer"></script>
<script type="module" src="/static/index.js"></script>
<script type="module">
import {trigger_reset_handlers, trigger_table_animation} from "/static/index.js";
feather.replace();
htmx.onLoad(function (element) {
if (element.localName === "tr") {
trigger_table_animation();
} else {
trigger_reset_handlers();
}
});
</script>
</body>
</html>