fixed paths

This commit is contained in:
2026-04-12 11:20:09 +02:00
parent fe6b58c140
commit a3860a8dae
3 changed files with 8 additions and 4 deletions

View File

@@ -176,7 +176,8 @@ pub async fn home_handler(
context.insert("title", &state.app_name);
context.insert("current_sort", &sort_field);
context.insert("current_order", &order);
context.insert("current_page", "leaderboard"); // NEW
context.insert("current_page", "leaderboard");
context.insert("prefix", "");
match TEMPLATES.render("index.html", &context) {
Ok(html) => Ok(Html(html)),
@@ -205,6 +206,8 @@ pub async fn report_details_handler(
"score",
&((report.benchmark.multi_thread.score + report.benchmark.single_thread.score) / 2),
);
context.insert("current_page", "details");
context.insert("prefix", "../");
match TEMPLATES.render("details.html", &context) {
Ok(html) => Ok(Html(html)),
@@ -403,6 +406,7 @@ pub async fn analytics_handler(
context.insert("json_data", &json_data);
context.insert("data", &data);
context.insert("current_page", "analytics");
context.insert("prefix", "");
match TEMPLATES.render("analytics.html", &context) {
Ok(html) => Ok(Html(html)),