Sha256: 02926e1dd383d488cbf7e4a938cfd23968c5c33725487fd9f0d0d6583f810387
Contents?: true
Size: 534 Bytes
Versions: 1
Compression:
Stored size: 534 Bytes
Contents
require 'epubber/models/concerns/has_endnotes' # Represents a book's chapter module Epubber::Models class Chapter include Epubber::Models::Concerns::HasHTML def initialize @id = 0 @title = 'Not specified' @content = '<p>Not specified</p>' end def id(idx) @id = idx end def title(text) @title = text end def content(text) @content = clean_html(text) end def contextify { 'id' => @id, 'title' => @title, 'content' => @content } end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
epubber-0.1.1 | lib/epubber/models/chapter.rb |