feat(web client): content pages

This commit is contained in:
Henri Bourcereau 2026-05-25 16:14:25 +02:00
parent 58f5722551
commit 6fd3499d7b
15 changed files with 312 additions and 11 deletions

View file

@ -63,15 +63,18 @@ pub struct AppState {
pub db: Pool,
/// SMTP mailer for email verification and password reset.
pub mailer: Mailer,
/// Directory containing static content pages as `{slug}/{lang}.md` files.
pub pages_dir: String,
}
impl AppState {
pub fn new(db: Pool, mailer: Mailer) -> Self {
pub fn new(db: Pool, mailer: Mailer, pages_dir: String) -> Self {
Self {
rooms: Mutex::new(HashMap::new()),
configs: RwLock::new(HashMap::new()),
db,
mailer,
pages_dir,
}
}
}