class Locomotive::Steam::Liquid::Tags::GlobalSection
Public Instance Methods
parse(tokens)
click to toggle source
# File lib/locomotive/steam/liquid/tags/global_section.rb, line 7 def parse(tokens) notify_on_parsing(section_type, source: :site, id: "site-#{section_type}", key: section_type, placement: attributes[:placement]&.to_sym ) end
Private Instance Methods
find_section_content(context)
click to toggle source
# File lib/locomotive/steam/liquid/tags/global_section.rb, line 18 def find_section_content(context) context['site']&.sections_content&.fetch(section_type, nil) end
set_section_dom_id(context)
click to toggle source
# File lib/locomotive/steam/liquid/tags/global_section.rb, line 22 def set_section_dom_id(context) context['section_id'] = "site-#{section_type}" end