keep favorite/star button's title in sync with starred status (PR #487)

Meta: ‘Favourite’ Should Read ‘Unfavourite’ When a Topic Is Favourited & Filtering topic by user is very buggy/laggy

This will keep the title of both the favorite button and the stars in sync with the starred status of the topic.


  • added 2 methods to the topic model
    • favoriteTooltipKey that will return the translation key depending on the starred status of the topic
    • favoriteTooltip that will return the translated string based on the previous method
  • binded the title attributes to favoriteTooltip for the stars (in the topic_list_item, topic and topic_extra_info templates)
  • binded the helpKey property to favoriteTooltipKey for the favorite button
  • added globalization for the 2 strings

I’ve checked the following places:

  • the star on a topic list
  • the star next to the topic title when viewing a topic
  • the star next to the topic title when viewing a topic and scrolled down
  • the favorite button when viewing a topic

Please, do not hesitate to tell me whether I missed one :wink:


You’ve signed the CLA, ZogStriP. Thank you! This pull request is ready for review.

@eviltrout I’ve made the change you recommended regarding the helpKey property :wink: