FEATURE: Add hot as a homepage option (#25325)

This commit is contained in:
Blake Erickson
2024-01-18 16:36:18 -07:00
committed by GitHub
parent 6ec4ffdee1
commit 561851b104
4 changed files with 13 additions and 0 deletions

View File

@@ -44,6 +44,10 @@ export default Controller.extend({
this._super(...arguments);
this.set("selectedDarkColorSchemeId", this.session.userDarkSchemeId);
if (this.siteSettings.experimental_hot_topics) {
USER_HOMES[8] = "hot";
}
},
@discourseComputed("makeThemeDefault")

View File

@@ -185,6 +185,12 @@ class UserOption < ActiveRecord::Base
"bookmarks"
when 7
"unseen"
when 8
if SiteSetting.experimental_hot_topics
"hot"
else
SiteSetting.homepage
end
else
SiteSetting.homepage
end