# File lib/wicked_pdf/wicked_pdf_helper/assets.rb, line 15 def wicked_pdf_stylesheet_link_tag(*sources) stylesheet_contents = sources.collect do |source| source = WickedPdfHelper.add_extension(source, 'css') "<style type='text/css'>#{read_asset(source)}</style>" end.join("\n") stylesheet_contents.gsub(ASSET_URL_REGEX) do if Regexp.last_match[1].starts_with?('data:') "url(#{Regexp.last_match[1]})" else "url(#{wicked_pdf_asset_path(Regexp.last_match[1])})" end end.html_safe end