diff options
Diffstat (limited to 'templates')
-rw-r--r-- | templates/base.crotmp | 17 | ||||
-rw-r--r-- | templates/gallery.crotmp | 36 | ||||
-rw-r--r-- | templates/login.crotmp | 21 |
3 files changed, 34 insertions, 40 deletions
diff --git a/templates/base.crotmp b/templates/base.crotmp index f200241..41c0420 100644 --- a/templates/base.crotmp +++ b/templates/base.crotmp @@ -1,14 +1,15 @@ <:macro page($title)> -<!doctype html> -<html lang="en"> + <!doctype html> + <html lang="en"> <head> - <meta charset="utf-8"> - <meta name="viewport" content="width=device-width, initial-scale=1"> - <title><$title> - Crater</title> - <link rel="stylesheet" href="/resources/css/style.css"> + <meta charset="utf-8"> + <meta name="viewport" content="width=device-width, initial-scale=1"> + <title><$title> - Crater</title> + <link rel="stylesheet" href="/resources/css/colors.css"> + <link rel="stylesheet" href="/resources/css/style.css"> </head> <body> - <:body> + <:body> </body> -</html> + </html> </:macro> diff --git a/templates/gallery.crotmp b/templates/gallery.crotmp index 25c55ea..6afef0a 100644 --- a/templates/gallery.crotmp +++ b/templates/gallery.crotmp @@ -1,24 +1,18 @@ <:use 'templates/base.crotmp'> -<|page(.title)> -<div id="gallery"> - <@gallery : $i> - - <?{ $i.<type> eq 'img' }> - <img src="<$i.<src>>" loading="lazy"> - </?> - - <?{ $i.<type> eq 'text' }> - <div class="text"> - <$i.<text>> + <|page(.title)> + <div id="gallery"> + <@gallery : $i> + <?{ $i.<type> eq 'img' }> + <img alt="<$i.<alt>>" src="<$i.<src>>" loading="lazy"> + </?> + <?{ $i.<type> eq 'text' }> + <div class="text"><$i.<text>></div> + </?> + <?{ $i.<type> eq 'heading' }> + <h1 class="heading"><$i.<text>></h1> + </?> + </@> </div> - </?> - - <?{ $i.<type> eq 'heading' }> - <h1 class="heading"><$i.<text>></h1> - </?> - - </@> -</div> -<script type="text/javascript" src="/resources/js/bricks.js"></script> -<script type="text/javascript" src="/resources/js/gallery.js"></script> + <script type="text/javascript" src="/resources/js/bricks.js"></script> + <script type="text/javascript" src="/resources/js/gallery.js"></script> </|> diff --git a/templates/login.crotmp b/templates/login.crotmp index 2a5587c..343f768 100644 --- a/templates/login.crotmp +++ b/templates/login.crotmp @@ -1,15 +1,14 @@ <:use 'templates/base.crotmp'> -<|page('Log In')> -<form method="post" action="/login"> - <?.error> - <div class="alert" role="alert"> + <|page('Log In')> + <form method="post" action="/login"> + <?.error> + <div class="alert" role="alert"> <.error> - </div> - </?> + </div> + </?> - <input type="password" name="pass" id="pass" placeholder="Password" required> - <br> - <input type="submit" value="Log In" /> -</form> -</div> + <input type="password" name="pass" id="pass" placeholder="Password" required> + <br> + <input type="submit" value="Log In" /> + </form> </|> |