module InfoHelpers

helpers for info fields in documents

Public Instance Methods

navbar?() click to toggle source
navbar_brand() click to toggle source
page_info(**options) click to toggle source
# File lib/paperwork/tasks/middleman_template/lib/info_helpers.rb, line 15
def page_info(**options)
    content_for :page_infos do
        options.keys.map do |name|
            partial("layouts/info", locals: { name: name, value: options[name] })
        end.join
    end
end
paperwork?() click to toggle source
# File lib/paperwork/tasks/middleman_template/lib/info_helpers.rb, line 38
def paperwork?
    data.respond_to?(:paperwork)
end
text_for(**options) click to toggle source
# File lib/paperwork/tasks/middleman_template/lib/info_helpers.rb, line 7
def text_for(**options)
    options.keys.map do |key|
        content_for key do
            options[key].to_s
        end
    end
end