Sha256: fc0396bcd008625d17f59d04e535a7f6a13dc62f73d02afd8db7eaadc94114eb

Contents?: true

Size: 465 Bytes

Versions: 22

Compression:

Stored size: 465 Bytes

Contents

module Garage
  module Docs
    class Renderer < ::Redcarpet::Render::HTML
      include ConsoleLinkBuilding
      include AnchorBuilding

      def header(text, header_level)
        if header_level == 2
          id = to_anchor(text)
          %!<a href="##{id}"><h#{header_level} id="#{id}">#{text} #{build_console_link(text)}</h#{header_level}></a>!
        else
          %!<h#{header_level}>#{text}</h#{header_level}>!
        end
      end
    end
  end
end

Version data entries

22 entries across 22 versions & 1 rubygems

Version Path
the_garage-2.8.2 lib/garage/docs/renderer.rb
the_garage-2.8.1 lib/garage/docs/renderer.rb
the_garage-2.8.0 lib/garage/docs/renderer.rb
the_garage-2.7.0 lib/garage/docs/renderer.rb
the_garage-2.6.1 lib/garage/docs/renderer.rb
the_garage-2.6.0 lib/garage/docs/renderer.rb
the_garage-2.5.0 lib/garage/docs/renderer.rb
the_garage-2.4.4 lib/garage/docs/renderer.rb
the_garage-2.4.3 lib/garage/docs/renderer.rb
the_garage-2.4.2 lib/garage/docs/renderer.rb
the_garage-2.4.1 lib/garage/docs/renderer.rb
the_garage-2.4.0 lib/garage/docs/renderer.rb
the_garage-2.3.3 lib/garage/docs/renderer.rb
the_garage-2.3.2 lib/garage/docs/renderer.rb
the_garage-2.3.1 lib/garage/docs/renderer.rb
the_garage-2.3.0 lib/garage/docs/renderer.rb
the_garage-2.2.0 lib/garage/docs/renderer.rb
the_garage-2.1.0 lib/garage/docs/renderer.rb
the_garage-2.0.3 lib/garage/docs/renderer.rb
the_garage-2.0.2 lib/garage/docs/renderer.rb