Sha256: 8ddd62f8c1692ca0d7733b262c480ed40c4eae2c99797358f61c3fbf00275d3f

Contents?: true

Size: 306 Bytes

Versions: 43

Compression:

Stored size: 306 Bytes

Contents

module HoboFields
  module Types
    class MarkdownString < RawMarkdownString

      include SanitizeHtml

      HoboFields.register_type(:markdown, self)

      def to_html(xmldoctype = true)
        blank? ? "" : HoboFields::SanitizeHtml.sanitize(Markdown.new(self).to_html)
      end

    end
  end
end

Version data entries

43 entries across 43 versions & 1 rubygems

Version Path
hobo_fields-1.3.3 lib/hobo_fields/types/markdown_string.rb
hobo_fields-2.0.0.pre7 lib/hobo_fields/types/markdown_string.rb
hobo_fields-2.0.0.pre6 lib/hobo_fields/types/markdown_string.rb
hobo_fields-2.0.0.pre5 lib/hobo_fields/types/markdown_string.rb
hobo_fields-2.0.0.pre4 lib/hobo_fields/types/markdown_string.rb
hobo_fields-1.3.2 lib/hobo_fields/types/markdown_string.rb
hobo_fields-1.3.1 lib/hobo_fields/types/markdown_string.rb
hobo_fields-2.0.0.pre3 lib/hobo_fields/types/markdown_string.rb
hobo_fields-2.0.0.pre2 lib/hobo_fields/types/markdown_string.rb
hobo_fields-2.0.0.pre1 lib/hobo_fields/types/markdown_string.rb
hobo_fields-1.4.0.pre8 lib/hobo_fields/types/markdown_string.rb
hobo_fields-1.4.0.pre7 lib/hobo_fields/types/markdown_string.rb
hobo_fields-1.4.0.pre6 lib/hobo_fields/types/markdown_string.rb
hobo_fields-1.4.0.pre5 lib/hobo_fields/types/markdown_string.rb
hobo_fields-1.4.0.pre4 lib/hobo_fields/types/markdown_string.rb
hobo_fields-1.4.0.pre3 lib/hobo_fields/types/markdown_string.rb
hobo_fields-1.4.0.pre2 lib/hobo_fields/types/markdown_string.rb
hobo_fields-1.3.0 lib/hobo_fields/types/markdown_string.rb
hobo_fields-1.3.0.RC4 lib/hobo_fields/types/markdown_string.rb
hobo_fields-1.3.0.RC3 lib/hobo_fields/types/markdown_string.rb