blob: 0bf70eb909856a6619b712e3e2110f6c6bb2fc4e (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
|
@use super::statics::*;
@use crate::Notification;
@(user: Option<String>, notification: Option<Notification>, body: Content)
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<link rel="stylesheet" type="text/css" href="/static/@style_css.name" />
<title>pinussy</title>
</head>
<body>
<nav>
@if let Some(username) = user {
<form action="/logout" method="post">
<button type="submit">logout @username</button>
</form>
} else {
<a href="/login">log in</a>
}
</nav>
@if let Some(notification) = notification {
<div class="notification @notification.kind">@notification.message</div>
}
@:body()
</body>
</html>
|