Module: Pageflow::NavigationBarHelper
- Defined in:
- app/helpers/pageflow/navigation_bar_helper.rb
Instance Method Summary collapse
- #mobile_share_providers_only?(entry) ⇒ Boolean
- #navigation_bar_css_class(entry, options = {}) ⇒ Object
Instance Method Details
#mobile_share_providers_only?(entry) ⇒ Boolean
13 14 15 |
# File 'app/helpers/pageflow/navigation_bar_helper.rb', line 13 def mobile_share_providers_only?(entry) entry.active_share_providers.sort.eql?(%w[telegram whats_app].sort) end |
#navigation_bar_css_class(entry, options = {}) ⇒ Object
3 4 5 6 7 8 9 10 11 |
# File 'app/helpers/pageflow/navigation_bar_helper.rb', line 3 def (entry, = {}) [ [:class], entry..enabled? ? 'with_home_button' : nil, entry..enabled? ? 'with_overview_button' : nil, entry.active_share_providers.empty? ? 'without_sharing_button' : nil, mobile_share_providers_only?(entry) ? 'mobile_sharing_only' : nil ].compact.join(' ') end |