diff options
| author | Robert Speicher <rspeicher@gmail.com> | 2015-06-05 15:53:57 -0400 |
|---|---|---|
| committer | Robert Speicher <rspeicher@gmail.com> | 2015-06-13 17:58:16 -0400 |
| commit | 8112f7550b70c83bde2f74ed48e7781c5424ebb9 (patch) | |
| tree | 901945d778c172754ff408832f26c8a2b39a3def /app/helpers/application_helper.rb | |
| parent | 844d72716e2175dcd5e39b4d1eecb9e3560aa0b9 (diff) | |
| download | gitlab-ce-8112f7550b70c83bde2f74ed48e7781c5424ebb9.tar.gz | |
Add PreferencesHelper module
Consolidates the helpers related to user preferences.
Renames `app_theme` to `user_application_theme` to better explain what
it is.
Diffstat (limited to 'app/helpers/application_helper.rb')
| -rw-r--r-- | app/helpers/application_helper.rb | 29 |
1 files changed, 0 insertions, 29 deletions
diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb index 62794bc5f4c..10d7aa11209 100644 --- a/app/helpers/application_helper.rb +++ b/app/helpers/application_helper.rb @@ -2,26 +2,6 @@ require 'digest/md5' require 'uri' module ApplicationHelper - COLOR_SCHEMES = { - 1 => 'white', - 2 => 'dark', - 3 => 'solarized-light', - 4 => 'solarized-dark', - 5 => 'monokai', - } - COLOR_SCHEMES.default = 'white' - - # Helper method to access the COLOR_SCHEMES - # - # The keys are the `color_scheme_ids` - # The values are the `name` of the scheme. - # - # The preview images are `name-scheme-preview.png` - # The stylesheets should use the css class `.name` - def color_schemes - COLOR_SCHEMES.freeze - end - # Check if a particular controller is the current one # # args - One or more controller names to check @@ -138,15 +118,6 @@ module ApplicationHelper Emoji.names.to_s end - def app_theme - theme = Gitlab::Themes.by_id(current_user.try(:theme_id)) - theme.css_class - end - - def user_color_scheme_class - COLOR_SCHEMES[current_user.try(:color_scheme_id)] if defined?(current_user) - end - # Define whenever show last push event # with suggestion to create MR def show_last_push_widget?(event) |
