Sha256: cfd49b8b3ba30cda021ec03a84b42d8bb890f17f60d44e5604a82b92c54aebc7

Contents?: true

Size: 433 Bytes

Versions: 8

Compression:

Stored size: 433 Bytes

Contents

require "fileutils"

module IsoDoc
  module M3AAWG
    module BaseRender
      def cleanup(docxml)
        super
        term_cleanup(docxml)
      end

      def term_cleanup(docxml)
        docxml.xpath("//p[@class = 'Terms']").each do |d|
          h2 = d.at("./preceding-sibling::*[@class = 'TermNum'][1]")
          h2.add_child(" ")
          h2.add_child(d.remove)
        end
        docxml
      end
    end
  end
end

Version data entries

8 entries across 8 versions & 2 rubygems

Version Path
metanorma-m3aawg-1.5.6 lib/isodoc/m3aawg/base_convert.rb
metanorma-m3aawg-1.5.5 lib/isodoc/m3aawg/base_convert.rb
metanorma-m3aawg-1.5.4 lib/isodoc/m3aawg/base_convert.rb
metanorma-m3aawg-1.5.3 lib/isodoc/m3aawg/base_convert.rb
metanorma-m3aawg-1.5.2 lib/isodoc/m3aawg/base_convert.rb
metanorma-m3aawg-1.5.1 lib/isodoc/m3aawg/base_convert.rb
metanorma-cli-1.3.4 gems/ruby/2.6.0/gems/metanorma-m3aawg-1.5.0/lib/isodoc/m3aawg/base_convert.rb
metanorma-m3aawg-1.5.0 lib/isodoc/m3aawg/base_convert.rb