-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathwork_case.rs
More file actions
30 lines (25 loc) · 844 Bytes
/
work_case.rs
File metadata and controls
30 lines (25 loc) · 844 Bytes
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
use bon::Builder;
use maud::Render;
use crate::views::{page, partials};
#[derive(Clone, Debug, Builder)]
pub struct WorkCase {
pub slug: partials::components::portfolio::content::WorkCaseSlug,
}
impl Render for WorkCase {
fn render(&self) -> maud::Markup {
let content = partials::components::portfolio::content::work_case_content(self.slug);
let body = partials::components::portfolio::Page {
content: maud::html! {
(partials::components::portfolio::WorkCaseDetail { content })
},
}
.render();
page::Layout::builder()
.title(&content.page_title.to_string())
.content(body)
.nav_mode(page::NavMode::Portfolio)
.current_route(crate::paths::Route::Work)
.build()
.render()
}
}