summaryrefslogblamecommitdiffstats
path: root/templates/base.rs.html
blob: 64a8d4e8bd816168c98bb1e2982af2c9c1bad779 (plain) (tree)
1
2
3
4
                       
                         
 
                                                                         













                                                                          


                                           



                               


                                                                              



          
@use super::statics::*;
@use crate::Notification;

@(authenticated: bool, 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 authenticated {
    <form action="/logout" method="post">
      <button type="submit">logout</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>