Sha256: e4d2e755b996e3566c917ac9c8782c65a9f0608e67a736ade2fa3d5f79207e20
Contents?: true
Size: 669 Bytes
Versions: 22
Compression:
Stored size: 669 Bytes
Contents
# frozen_string_literal: true module Kitchen module Directions module BakeUnclassifiedNotes def self.v1(book:) book.notes.each do |note| next unless note.classes.empty? bake_note(note: note) end end def self.bake_note(note:) note.wrap_children(class: 'os-note-body') title = note.title&.cut return unless title note.prepend(child: <<~HTML <h3 class="os-title" data-type="title"> <span class="os-title-label" data-type="" id="#{title[:id]}">#{title.children}</span> </h3> HTML ) end end end end
Version data entries
22 entries across 22 versions & 1 rubygems