Skip to content

Commit

Permalink
Rename and hide on homepage
Browse files Browse the repository at this point in the history
  • Loading branch information
CamLamb committed Jan 6, 2025
1 parent 3f49b43 commit cab1d69
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/core/templatetags/sidebar.py
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,7 @@ def get_part_context(self):
}


class Bookmarks(SidebarPart):
class Bookmark(SidebarPart):
template_name = "tags/sidebar/parts/bookmark.html"

def is_visible(self):
Expand Down Expand Up @@ -194,7 +194,7 @@ def sidebar(context):
SidebarSection(
title="Primary page actions",
parts=[
Bookmarks,
Bookmark,
],
context=context,
template_name="tags/sidebar/sections/primary_page_actions.html",
Expand Down
4 changes: 4 additions & 0 deletions src/interactions/templatetags/bookmarks.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
from waffle import flag_is_active
from wagtail.models import Page

from home.models import HomePage
from interactions.services import bookmarks as bookmarks_service


Expand All @@ -21,6 +22,9 @@ def bookmark_page_input(user, page, request):
if not isinstance(page, Page):
return {}

if isinstance(page, HomePage):
return {}

is_bookmarked = bookmarks_service.is_page_bookmarked(user, page)

return {
Expand Down

0 comments on commit cab1d69

Please sign in to comment.