diff options
author | Reverite <github@reverite.sh> | 2019-03-30 23:42:55 -0700 |
---|---|---|
committer | Reverite <github@reverite.sh> | 2019-03-30 23:42:55 -0700 |
commit | 4d77314005483e53e320a82c87805c6bcca1c463 (patch) | |
tree | 99f5b05bcbb1e8278517bf9a8f9ab114ab2dec45 /app/helpers/admin/dashboard_helper.rb | |
parent | e356a902d23a0ed87c62717085a37d34550c8464 (diff) | |
parent | 925830d11bb5c132e282f82bdb2ca893d87c9c24 (diff) |
Merge branch 'glitch' into production
Diffstat (limited to 'app/helpers/admin/dashboard_helper.rb')
-rw-r--r-- | app/helpers/admin/dashboard_helper.rb | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/app/helpers/admin/dashboard_helper.rb b/app/helpers/admin/dashboard_helper.rb new file mode 100644 index 000000000..4ee2cdef4 --- /dev/null +++ b/app/helpers/admin/dashboard_helper.rb @@ -0,0 +1,10 @@ +# frozen_string_literal: true + +module Admin::DashboardHelper + def feature_hint(feature, enabled) + indicator = safe_join([enabled ? t('simple_form.yes') : t('simple_form.no'), fa_icon('power-off fw')], ' ') + class_names = enabled ? 'pull-right positive-hint' : 'pull-right neutral-hint' + + safe_join([feature, content_tag(:span, indicator, class: class_names)]) + end +end |