2010-07-23 20:09:54 +00:00
|
|
|
module Locomotive
|
|
|
|
module Liquid
|
|
|
|
module Drops
|
|
|
|
class Stylesheets < ::Liquid::Drop
|
|
|
|
|
2010-05-30 23:57:33 +00:00
|
|
|
def initialize(site)
|
|
|
|
@site = site
|
|
|
|
end
|
2010-07-23 20:09:54 +00:00
|
|
|
|
|
|
|
def before_method(meth)
|
2010-05-30 23:57:33 +00:00
|
|
|
asset = @site.theme_assets.where(:content_type => 'stylesheet', :slug => meth.to_s).first
|
|
|
|
!asset.nil? ? asset.source.url : nil
|
|
|
|
end
|
2010-07-23 20:09:54 +00:00
|
|
|
|
2010-05-30 23:57:33 +00:00
|
|
|
end
|
2010-07-23 20:09:54 +00:00
|
|
|
|
|
|
|
end
|
2010-05-30 23:57:33 +00:00
|
|
|
end
|
2010-07-23 20:09:54 +00:00
|
|
|
end
|