Skip to content

Commit

Permalink
FIX: hide theme selector if only 1 theme
Browse files Browse the repository at this point in the history
  • Loading branch information
SamSaffron committed May 12, 2017
1 parent 2d96a07 commit 3113a6a
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
Expand Up @@ -26,6 +26,11 @@ export default Ember.Controller.extend(PreferencesTabController, {
return listThemes(this.site);
}.property(),

@computed("userSelectableThemes")
showThemeSelector(themes) {
return themes && themes.length > 1;
},

@observes("model.user_option.theme_key")
themeKeyChanged() {
let key = this.get("model.user_option.theme_key");
Expand Down
@@ -1,4 +1,4 @@
{{#if userSelectableThemes}}
{{#if showThemeSelector}}
<div class="control-group theme">
<label class="control-label">{{i18n 'user.theme'}}</label>
<div class="controls">
Expand Down

0 comments on commit 3113a6a

Please sign in to comment.