Sha256: c449d65f7cf049c35614a0a24d6eb97ad9dca90e592ee842bef20a71cded138d

Contents?: true

Size: 551 Bytes

Versions: 10

Compression:

Stored size: 551 Bytes

Contents

# frozen_string_literal: true

module BootstrapLeather
  # Badges, i.e. tiny counts in a pill shape
  module BadgesHelper
    def badge_to(text, value, link, html_options = {})
      html_options[:href] = url_for link
      render(
        partial: 'bootstrap_leather/badges/badge_to',
        locals: { text: text, value: value, html_options: html_options }
      )
    end

    def badge(content, type = nil)
      render(
        partial: 'bootstrap_leather/badges/badge',
        locals: { content: content, type: type }
      )
    end
  end
end

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
bootstrap_leather-0.10.14 app/helpers/bootstrap_leather/badges_helper.rb
bootstrap_leather-0.10.13 app/helpers/bootstrap_leather/badges_helper.rb
bootstrap_leather-0.10.11 app/helpers/bootstrap_leather/badges_helper.rb
bootstrap_leather-0.10.10 app/helpers/bootstrap_leather/badges_helper.rb
bootstrap_leather-0.10.9 app/helpers/bootstrap_leather/badges_helper.rb
bootstrap_leather-0.10.8 app/helpers/bootstrap_leather/badges_helper.rb
bootstrap_leather-0.10.7 app/helpers/bootstrap_leather/badges_helper.rb
bootstrap_leather-0.10.6 app/helpers/bootstrap_leather/badges_helper.rb
bootstrap_leather-0.10.5 app/helpers/bootstrap_leather/badges_helper.rb
bootstrap_leather-0.10.4 app/helpers/bootstrap_leather/badges_helper.rb