fixed typo and adding about page route in server
This commit is contained in:
parent
38b7b7e26c
commit
780e8b26bb
@ -35,7 +35,7 @@ fn rocket() -> rocket::Rocket {
|
|||||||
rocket::ignite()
|
rocket::ignite()
|
||||||
.mount("/static", StaticFiles::from("/static"))
|
.mount("/static", StaticFiles::from("/static"))
|
||||||
.mount("/", routes![
|
.mount("/", routes![
|
||||||
homepage, login_page, server_info,
|
homepage, login_page, about_page, server_info,
|
||||||
static_css,
|
static_css,
|
||||||
])
|
])
|
||||||
.attach(Template::fairing())
|
.attach(Template::fairing())
|
||||||
|
@ -34,7 +34,7 @@ fn context() -> PageAttrs {
|
|||||||
favicon: "https://images.pexels.com/photos/146071/pexels-photo-146071.jpeg?auto=compress&cs=tinysrgb&dpr=2&h=750&w=1260",
|
favicon: "https://images.pexels.com/photos/146071/pexels-photo-146071.jpeg?auto=compress&cs=tinysrgb&dpr=2&h=750&w=1260",
|
||||||
brand_url: "freechat.io",
|
brand_url: "freechat.io",
|
||||||
brand_motto: "Freedom respecting chat platform",
|
brand_motto: "Freedom respecting chat platform",
|
||||||
brand_quip: "Join an realm",
|
brand_quip: "Join an instance",
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -51,6 +51,12 @@ pub fn login_page() -> Template {
|
|||||||
let ctx = context();
|
let ctx = context();
|
||||||
Template::render("login", &ctx)
|
Template::render("login", &ctx)
|
||||||
}
|
}
|
||||||
|
#[get("/about")]
|
||||||
|
pub fn about_page() -> Template {
|
||||||
|
let ctx = context();
|
||||||
|
Template::render("about", &ctx)
|
||||||
|
}
|
||||||
|
|
||||||
#[get("/servers")]
|
#[get("/servers")]
|
||||||
pub fn server_info() -> Template {
|
pub fn server_info() -> Template {
|
||||||
let ctx = context();
|
let ctx = context();
|
||||||
|
Loading…
Reference in New Issue
Block a user