Sha256: 3bb9bdac522d020212798d51513a25d99bfaba9aa7968f3db3ac867389c0bbb4

Contents?: true

Size: 241 Bytes

Versions: 4

Compression:

Stored size: 241 Bytes

Contents

require_relative 'processor'

module SSMD::Processors
  class EmphasisProcessor < Processor
    def result
      text = match.captures.first

      "<emphasis>#{text}</emphasis>"
    end

    def regex
      /\*([^\*]+)\*/
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
ssmd-0.2.2 lib/ssmd/processors/emphasis_processor.rb
ssmd-0.2.1 lib/ssmd/processors/emphasis_processor.rb
ssmd-0.2.0 lib/ssmd/processors/emphasis_processor.rb
ssmd-0.1.0 lib/ssmd/processors/emphasis_processor.rb