Sha256: f809e1d2abecfbadf307cf52d9a4ecebb6d4d00a0e2dd78349478f619aa49c50

Contents?: true

Size: 339 Bytes

Versions: 163

Compression:

Stored size: 339 Bytes

Contents

require "octicons_v2"
require "action_view"

module OcticonsV2Helper

  include ActionView::Helpers::TagHelper

  def octicon_v2(symbol, options = {})
    return "" if symbol.nil?

    icon = OcticonsV2::OcticonV2.new(symbol, options)
    content_tag(:svg, icon.path.html_safe, icon.options) # rubocop:disable Rails/OutputSafety
  end
end

Version data entries

163 entries across 163 versions & 1 rubygems

Version Path
octicons_v2_helper-0.0.0.pre.7c415e0 lib/octicons_v2_helper/helper.rb
octicons_v2_helper-0.0.0.pre.c36f7e4 lib/octicons_v2_helper/helper.rb
octicons_v2_helper-0.0.0.pre.ba70d35 lib/octicons_v2_helper/helper.rb
octicons_v2_helper-0.0.0.pre.a1fb469 lib/octicons_v2_helper/helper.rb
octicons_v2_helper-0.0.0.pre.24cce42 lib/octicons_v2_helper/helper.rb
octicons_v2_helper-0.0.0.pre.92d68d5 lib/octicons_v2_helper/helper.rb
octicons_v2_helper-0.0.0.pre.ae29ea7 lib/octicons_v2_helper/helper.rb
octicons_v2_helper-0.0.0.pre.eaf310a lib/octicons_v2_helper/helper.rb
octicons_v2_helper-0.0.0.pre.4938735 lib/octicons_v2_helper/helper.rb
octicons_v2_helper-0.0.0.pre.c49ba32 lib/octicons_v2_helper/helper.rb
octicons_v2_helper-0.0.0.pre.2956111 lib/octicons_v2_helper/helper.rb
octicons_v2_helper-0.0.0.pre.5c1ca6d lib/octicons_v2_helper/helper.rb
octicons_v2_helper-0.0.0.pre.816ac2c lib/octicons_v2_helper/helper.rb
octicons_v2_helper-0.0.0.pre.fc97238 lib/octicons_v2_helper/helper.rb
octicons_v2_helper-0.0.0.pre.dddece5 lib/octicons_v2_helper/helper.rb
octicons_v2_helper-0.0.0.pre.0c5fcfc lib/octicons_v2_helper/helper.rb
octicons_v2_helper-0.0.0.pre.d8dffb8 lib/octicons_v2_helper/helper.rb
octicons_v2_helper-0.0.0.pre.79962a1 lib/octicons_v2_helper/helper.rb
octicons_v2_helper-0.0.0.pre.07a0bc8 lib/octicons_v2_helper/helper.rb
octicons_v2_helper-0.0.0.pre.3751a86 lib/octicons_v2_helper/helper.rb