2025-02-01 14:22:33 +01:00
|
|
|
use askama::{
|
|
|
|
Template,
|
|
|
|
};
|
2025-02-01 18:34:14 +01:00
|
|
|
use crate::{
|
|
|
|
storage::{
|
2025-02-01 19:00:51 +01:00
|
|
|
FlakeRevision,
|
2025-02-01 18:34:14 +01:00
|
|
|
FlakeUri,
|
|
|
|
},
|
|
|
|
};
|
2025-02-01 14:22:33 +01:00
|
|
|
|
|
|
|
#[derive(Template)]
|
|
|
|
#[template(path = "index.html")]
|
|
|
|
pub struct IndexTemplate {
|
|
|
|
}
|
2025-02-01 18:34:14 +01:00
|
|
|
|
|
|
|
#[derive(Template)]
|
|
|
|
#[template(path = "flakes.html")]
|
|
|
|
pub struct FlakesTemplate {
|
|
|
|
pub flakes: Vec<FlakeUri>,
|
|
|
|
}
|
2025-02-01 19:00:51 +01:00
|
|
|
|
|
|
|
#[derive(Template)]
|
|
|
|
#[template(path = "flake-info.html")]
|
|
|
|
pub struct FlakeInfoTemplate {
|
|
|
|
pub uri: String,
|
|
|
|
pub flake_revisions: Vec<FlakeRevision>,
|
|
|
|
}
|