about summary refs log tree commit diff
path: root/app/helpers/admin/dashboard_helper.rb
blob: 4ee2cdef473f545cb0a43ac05c7a02f9a471379c (plain) (blame)
1
2
3
4
5
6
7
8
9
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