summaryrefslogtreecommitdiff
path: root/src/render/mod.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/render/mod.rs')
-rw-r--r--src/render/mod.rs14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/render/mod.rs b/src/render/mod.rs
index 3b63a68..a824bd6 100644
--- a/src/render/mod.rs
+++ b/src/render/mod.rs
@@ -32,6 +32,20 @@ fn render_in_page<'a>(content: Box<RenderBox + 'a>) -> String {
}).into_string().unwrap()
}
+pub fn login_page() -> String {
+ render_in_page(box_html! {
+ h1 { : "Log in" }
+ form(method="post") {
+ p { : "Username" }
+ input(type="text", name="username") {}
+ p { : "Password" }
+ input(type="text", name="password") {}
+ p {}
+ input(type="submit", value="Log in") {}
+ }
+ })
+}
+
fn unit_table<'a>(units: &'a [&unit::Unit]) -> Box<RenderBox + 'a> {
fn render_unit<'a>(unit: &'a unit::Unit) -> Box<RenderBox + 'a> {
box_html! {