feat: show generation prompts in previews and fix fluid page layout

This commit is contained in:
2026-11-04 01:19:42 +08:00
parent bef8af53ed
commit 5f3cebcb38
8 changed files with 57 additions and 9 deletions
+2
View File
@@ -42,6 +42,7 @@ def _meta_by_file() -> dict[tuple[str, str], dict[str, Any]]:
"model": row["model"],
"provider_name": row["provider_name"],
"created_at": row["created_at"],
"prompt": row["prompt"],
},
)
return index
@@ -108,6 +109,7 @@ def list_gallery(profile_name: str) -> list[dict[str, Any]]:
"bytes": stat.st_size,
"model": info.get("model", "—"),
"provider_name": info.get("provider_name", "—"),
"prompt": info.get("prompt", ""),
"created_at": info.get("created_at")
or datetime.fromtimestamp(stat.st_mtime).strftime("%Y-%m-%d %H:%M"),
}