Module: Refinery::Helpers::HeadHelper
- Defined in:
- lib/refinery/helpers/head_helper.rb
Instance Method Summary collapse
Instance Method Details
#stylesheets_for_head(stylesheets, theme = false) ⇒ Object
5 6 7 8 9 10 11 12 13 |
# File 'lib/refinery/helpers/head_helper.rb', line 5 def stylesheets_for_head(stylesheets, theme = false) # you can disable the use of the built-in refinery stylesheets by disabling the setting. stylesheets.map! {|ss| ["refinery/#{ss}", ss] }.flatten! if RefinerySetting.find_or_set(:frontend_refinery_stylesheets_enabled, true) # if theme is set, use themed stylesheet links. stylesheets.map! {|ss| ss =~ /^refinery\// ? ss : "/theme/stylesheets/#{ss}" } if theme stylesheets end |