Add "Show tracked topics" to User Preferences

Does what it says on the tin. Minor clean-up.
This commit is contained in:
ElTipejoLoco 2017-03-17 08:05:21 -05:00
parent e600dca268
commit e234a7821d
3 changed files with 9 additions and 1 deletions

View File

@ -146,6 +146,11 @@ const User = RestModel.extend({
return defaultHomepage() === "latest" ? Discourse.getURL('/?state=watching') : Discourse.getURL('/latest?state=watching');
},
@computed()
trackingTopicsPath() {
return defaultHomepage() === "latest" ? Discourse.getURL('/?state=tracking') : Discourse.getURL('/latest?state=tracking');
},
@computed("username")
username_lower(username) {
return username.toLowerCase();

View File

@ -263,12 +263,14 @@
<div class="controls category-controls">
<a href="{{unbound model.watchingTopicsPath}}">{{i18n 'user.watched_topics_link'}}</a>
</div>
<div class="instructions"></div>
<div class="controls category-controls">
<label><span class="icon fa fa-circle tracking"></span> {{i18n 'user.tracked_categories'}}</label>
{{category-selector categories=model.trackedCategories blacklist=selectedCategories}}
</div>
<div class="instructions">{{i18n 'user.tracked_categories_instructions'}}</div>
<div class="controls category-controls">
<a href="{{unbound model.trackingTopicsPath}}">{{i18n 'user.tracked_topics_link'}}</a>
</div>
<div class="controls category-controls">
<label><span class="icon fa fa-dot-circle-o watching-first-post"></span> {{i18n 'user.watched_first_post_categories'}}</label>
{{category-selector categories=model.watchedFirstPostCategories}}

View File

@ -627,6 +627,7 @@ en:
muted_users_instructions: "Suppress all notifications from these users."
muted_topics_link: "Show muted topics"
watched_topics_link: "Show watched topics"
tracked_topics_link: "Show tracked topics"
automatically_unpin_topics: "Automatically unpin topics when I reach the bottom."
apps: "Apps"
revoke_access: "Revoke Access"