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.dcc6a36 lib/octicons_v2_helper/helper.rb
octicons_v2_helper-0.0.0.pre.387b0bb lib/octicons_v2_helper/helper.rb
octicons_v2_helper-0.0.0.pre.ef56016 lib/octicons_v2_helper/helper.rb
octicons_v2_helper-0.0.0.pre.0ea8199 lib/octicons_v2_helper/helper.rb
octicons_v2_helper-0.0.0.pre.0823bfd lib/octicons_v2_helper/helper.rb
octicons_v2_helper-0.0.0.pre.fb17b1e lib/octicons_v2_helper/helper.rb
octicons_v2_helper-0.0.0.pre.0a10848 lib/octicons_v2_helper/helper.rb
octicons_v2_helper-0.0.0.pre.77f2e00 lib/octicons_v2_helper/helper.rb
octicons_v2_helper-0.0.0.pre.01b17b3 lib/octicons_v2_helper/helper.rb
octicons_v2_helper-0.0.0.pre.519e9d5 lib/octicons_v2_helper/helper.rb
octicons_v2_helper-0.0.0.pre.1cb16f5 lib/octicons_v2_helper/helper.rb
octicons_v2_helper-0.0.0.pre.53dc419 lib/octicons_v2_helper/helper.rb
octicons_v2_helper-0.0.0.pre.1a093dc lib/octicons_v2_helper/helper.rb
octicons_v2_helper-0.0.0.pre.1527811 lib/octicons_v2_helper/helper.rb
octicons_v2_helper-0.0.0.pre.1623cf0 lib/octicons_v2_helper/helper.rb
octicons_v2_helper-0.0.0.pre.a58f4df lib/octicons_v2_helper/helper.rb
octicons_v2_helper-0.0.0.pre.26e8c87 lib/octicons_v2_helper/helper.rb
octicons_v2_helper-0.0.0.pre.e3d382c lib/octicons_v2_helper/helper.rb
octicons_v2_helper-0.0.0.pre.a58c58c lib/octicons_v2_helper/helper.rb
octicons_v2_helper-0.0.0.pre.f6a1df0 lib/octicons_v2_helper/helper.rb