Sha256: b78d585cc768a3d068197f00aff9442c7a48ccaba266ae2711d3aac95a7572a9
Contents?: true
Size: 1.17 KB
Versions: 9
Compression:
Stored size: 1.17 KB
Contents
- if (checklist = (option? :checklist) ? 'checklist' : nil) - if option? :interactive - marker_checked = '<input type="checkbox" data-item-complete="1" checked>' - marker_unchecked = '<input type="checkbox" data-item-complete="0">' - else - if @document.attr? :icons, 'font' - marker_checked = '<i class="icon-check"></i>' - marker_unchecked = '<i class="icon-check-empty"></i>' - else / could use ☑ (checked ballot) and ☐ (ballot) w/o font instead - marker_checked = '<input type="checkbox" data-item-complete="1" checked disabled>' - marker_unchecked = '<input type="checkbox" data-item-complete="0" disabled>' = html_tag('div', { :id => @id, :class => ['ulist', checklist, @style, role] }.merge(data_attrs(@attributes))) - if title? .title=title ul class=(checklist || @style) - items.each do |item| li class=('fragment' if (option? :step) || (has_role? 'step') || (attr? 'step')) p - if checklist && (item.attr? :checkbox) =%(#{(item.attr? :checked) ? marker_checked : marker_unchecked}#{item.text}) - else =item.text - if item.blocks? =item.content
Version data entries
9 entries across 9 versions & 1 rubygems