use std::sync::Arc; use crate::cached_wattpad::*; use crate::components::header::{Header, HeaderLink}; use crate::WATTPAD; use axum::extract::{Extension, Query, State as AxumState}; use maud::{html, Markup, PreEscaped, DOCTYPE}; use regex::Regex; use serde::Deserialize; pub async fn render() -> Markup { html! { (DOCTYPE) title {"Home | Voltpad"}; meta name="viewport" content="width=device-width, initial-scale=1.0"; style {(PreEscaped( grass::include!("./css/index.scss") ))} script {(PreEscaped( include_str!("../../scripts/History.js") ))} ( Header(vec![ HeaderLink { name: "Home".to_string(), path: "/".to_string(), prefix: None, postfix: None }, HeaderLink { name: "Search".to_string(), path: "/search".to_string(), prefix: None, postfix: None }, HeaderLink { name: "History".to_string(), path: "/history".to_string(), prefix: None, postfix: None }, HeaderLink { name: "About".to_string(), path: "/about".to_string(), prefix: None, postfix: None }, ], "/history".to_string()) ) div .index-content { h1 { "History" } noscript { h3 { "This won't work without JS. Run off now, GNU LibreJS looking motherfuckers." } } div .story-list #story-list; } } }