UI adjustments: Import link in header, matching font sizes, cook history titles, click-to-upload images

- Add Import link to all page headers (landing, recipe, cook history, import)
- Match ingredient list font size to recipe method text (both 15px)
- Show recipe titles instead of filenames on Cook History page
- Make clicking anywhere on recipe hero image/placeholder trigger file upload dialog
This commit is contained in:
2026-05-27 20:59:24 -04:00
parent 2124630146
commit 0eb6e6ea3c
2 changed files with 25 additions and 15 deletions
+5 -1
View File
@@ -667,7 +667,11 @@ handleRequest recipeDir state db request respond = do
["cook-history"] -> do
entries <- CookLog.fetchAllEntries db
let grouped = groupEntries entries
respond $ htmlResponse (Html.cookHistoryPage grouped)
recipeTitleLookup fn =
case Map.lookup (map toLower (stripCookExt (T.unpack fn))) recipes of
Just info -> Idx.riTitle info
Nothing -> fn
respond $ htmlResponse (Html.cookHistoryPage recipeTitleLookup grouped)
-- Cook log JSON endpoint for all entries
["cook-log"] -> do
entries <- CookLog.fetchAllEntries db