Sha256: 9a3414d3c22ef8e7823be440bb2255f74e64de62cfc28f0ca56c28d98c893d48
Contents?: true
Size: 402 Bytes
Versions: 2
Compression:
Stored size: 402 Bytes
Contents
# frozen_string_literal: true module Kitchen module Directions module BakeNoteSubtitle def self.v1(note:) title = note.title&.cut return unless title title.name = 'h4' title.add_class('os-subtitle') title.wrap_children('span', class: 'os-subtitle-label') note.first!('.os-note-body').prepend(child: title.to_s) end end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
openstax_kitchen-3.2.0 | lib/kitchen/directions/bake_notes/bake_note_subtitle.rb |
openstax_kitchen-3.1.0 | lib/kitchen/directions/bake_notes/bake_note_subtitle.rb |