class Jekyll::PDF::AssetsTag
Constants
- AcceptableTags
Tags that we allow our users to use.
Public Class Methods
new(tag, args, tokens)
click to toggle source
Calls superclass method
# File lib/jekyll/pdf/liquid/tags/jekyll-assets.rb, line 22 def initialize(tag, args, tokens) tag = tag.to_s.sub!("pdf_", "") super(tag, args, tokens) end
Public Instance Methods
render(context)
click to toggle source
Calls superclass method
# File lib/jekyll/pdf/liquid/tags/jekyll-assets.rb, line 27 def render(context) @path_prefix = "file://" + context.registers[:site].dest super end
Private Instance Methods
build_html(args, sprockets, asset, path = get_path(sprockets, asset))
click to toggle source
# File lib/jekyll/pdf/liquid/tags/jekyll-assets.rb, line 33 def build_html(args, sprockets, asset, path = get_path(sprockets, asset)) data = @path_prefix + (args.key?(:data) && args[:data].key?(:uri) ? asset.data_uri : path) format(Jekyll::Assets::Liquid::Tag::Tags[@tag], data, args.to_html) end