feat: Add display name to user profiles

Introduce `display_name` field to `User` struct for human-readable names
in the UI.
This falls back to the user's `slug` if not provided.

Update `AuthenticatedWebUser` and `MyCasesTemplate` to use this new
field for rendering.
Add tests for parsing `display_name` and ensure fallback logic works
correctly.
Update `users.toml.example` to document the new field.
This commit is contained in:
2026-05-04 11:46:19 +02:00
parent 03129ad592
commit 2fc7f8ddd2
6 changed files with 97 additions and 24 deletions
+5
View File
@@ -8,6 +8,11 @@ slug = "dr_mueller"
api_key = "change-me-to-a-secure-key"
web_password = "$2b$12$..."
role = "doctor"
# Optional: human-readable name shown in the web UI page header
# in place of the slug (the slug stays the on-disk directory and
# login identifier). Free-form UTF-8 — accents and spaces are fine.
# Defaults to the slug when omitted.
display_name = "Dr. Müller"
# Optional: how many visual lines of the LLM analysis preview the case
# list renders under each row. The preview itself is always the first
# paragraph of document.md; this value only caps the visible lines