Skip to content

Add favourites support to Django website#50

Merged
andreagrandi merged 1 commit intomasterfrom
add-favourites-website
Apr 5, 2026
Merged

Add favourites support to Django website#50
andreagrandi merged 1 commit intomasterfrom
add-favourites-website

Conversation

@andreagrandi
Copy link
Copy Markdown
Owner

Summary

  • Add heart icon next to library title on detail page for logged-in users, toggleable via HTMX without page reload
  • Add "My Favourites" section to the user dashboard listing saved libraries in the same card grid layout as submissions
  • Grey filled heart for unliked, red filled heart for liked — both same solid SVG, colour only changes
  • Non-HTMX fallback redirects back to library detail page
  • Italian translations for all new strings

Test plan

  • All 630 unit tests pass (nox -s tests)
  • All 32 E2E tests pass (nox -s e2e)
  • Log in, visit an approved library detail page, verify grey heart appears next to the title
  • Click heart — verify it turns red without page reload
  • Click again — verify it turns grey without page reload
  • Visit dashboard — verify "My Favourites" section appears with the favourited library
  • Un-favourite all libraries — verify empty state with "Explore libraries" link
  • Visit as anonymous user — verify no heart icon is shown

Expose the existing favourites feature to the website for logged-in
users. A heart icon next to the library title toggles favourite status
via HTMX without page reload. The dashboard now includes a
"My Favourites" section listing saved libraries.
@andreagrandi andreagrandi merged commit 37ef2b0 into master Apr 5, 2026
6 checks passed
@andreagrandi andreagrandi deleted the add-favourites-website branch April 5, 2026 14:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant