5c03a28f59
Use the modern async warp web framework instead of nickel (which is starting to feel a bit stale). Url routing and context passing is changed a lot.
17 lines
655 B
HTML
17 lines
655 B
HTML
@use crate::server::{Context, Link};
|
|
|
|
@(context: &Context, lpath: &[Link])
|
|
|
|
<header>
|
|
<span><a href="/" accesskey="h" title="Images from all years">Images</a>
|
|
@for p in lpath { - @p}
|
|
</span>
|
|
<span>· <a href="/tag/">Tags</a></span>
|
|
<span>· <a href="/person/">People</a></span>
|
|
<span>· <a href="/place/">Places</a></span>
|
|
<span>· <a href="/thisday">On this day</a></span>
|
|
<span>· <a href="/random" accesskey="r">Random pic</a></span>
|
|
@if let Some(ref u) = context.authorized_user() {<span class="user">@u (<a href="/logout">log out</a>)</span>}
|
|
else {<span class="user">(<a href="/login?next=@context.path_without_query()">log in</a>)</span>}
|
|
</header>
|