Add favicon and make profile picture editable per page
- Favicon: emoji-based inline SVG (🍯), the old /images/favicon/favicon.ico reference never resolved to an actual file. - Profile picture (the circular image at the top) is now a per-page "profile_image" field editable in /admin, instead of a hardcoded URL in the template. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
1 parent
ada56f846b
commit
2a45abc0eb
4 files changed
+11
-2
No files matched your search
@@ -24,6 +24,7 @@ DEFAULT_DATA = {
|
||||
"subtitle2": "",
|
||||
"footer_label": "",
|
||||
"footer_href": "",
|
||||
"profile_image": "",
|
||||
"sections": [],
|
||||
}
|
||||
}
|
||||
@@ -119,6 +120,7 @@ def edit_header(page_key):
|
||||
page["subtitle2"] = request.form.get("subtitle2", page.get("subtitle2", "")).strip()
|
||||
page["footer_label"] = request.form.get("footer_label", page.get("footer_label", "")).strip()
|
||||
page["footer_href"] = request.form.get("footer_href", page.get("footer_href", "")).strip()
|
||||
page["profile_image"] = request.form.get("profile_image", page.get("profile_image", "")).strip()
|
||||
save_data(data)
|
||||
return redirect(url_for("admin_dashboard"))
|
||||
|
||||
@@ -137,6 +139,7 @@ def add_page():
|
||||
"subtitle2": "",
|
||||
"footer_label": "",
|
||||
"footer_href": "",
|
||||
"profile_image": "",
|
||||
"sections": [],
|
||||
}
|
||||
save_data(data)
|
||||
|
||||
Reference in new issue
Block a user