Sha256: 092b3cb155543b57311a1576ba65810860d6c8b6adcfaedd011a249c1f0fa54f

Contents?: true

Size: 400 Bytes

Versions: 9

Compression:

Stored size: 400 Bytes

Contents

module ReverseAdoc
  module Converters
    class P < Base
      def convert(node, state = {})
        id = node['id']
        anchor = id ? "[[#{id}]]\n" : ""
        if state[:tdsinglepara]
          "#{anchor}" << treat_children(node, state).strip
        else
          "\n\n#{anchor}" << treat_children(node, state).strip << "\n\n"
        end
      end
    end

    register :p, P.new
  end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
reverse_adoc-0.3.7 lib/reverse_adoc/converters/p.rb
reverse_adoc-0.3.6 lib/reverse_adoc/converters/p.rb
reverse_adoc-0.3.5 lib/reverse_adoc/converters/p.rb
reverse_adoc-0.3.4 lib/reverse_adoc/converters/p.rb
reverse_adoc-0.3.3 lib/reverse_adoc/converters/p.rb
reverse_adoc-0.3.1 lib/reverse_adoc/converters/p.rb
reverse_adoc-0.3.0 lib/reverse_adoc/converters/p.rb
reverse_adoc-0.2.10 lib/reverse_adoc/converters/p.rb
reverse_adoc-0.2.9 lib/reverse_adoc/converters/p.rb