Sha256: efe29f13533cdd609cb2f509ad1f41a3d6e1303676bec9a6aa013519d22102e0
Contents?: true
Size: 410 Bytes
Versions: 18
Compression:
Stored size: 410 Bytes
Contents
module Lookbook class PageTabs::Component < Lookbook::BaseComponent renders_many :tabs, ->(**attrs, &block) do @tabs ||= [] attrs[:content] = capture(&block) attrs[:markdown] ||= @markdown @tabs << attrs end def initialize(markdown: true, **html_attrs) @markdown = markdown super(**html_attrs) end def before_render tabs.size end end end
Version data entries
18 entries across 18 versions & 1 rubygems