Sha256: 8f05cd604fe28e7082a98a824410a46776034fdf52ffdde85d7633e67e368664

Contents?: true

Size: 494 Bytes

Versions: 2

Compression:

Stored size: 494 Bytes

Contents

require 'railsstrap/core_ext/rails/form/base_helper'

module Railsstrap
  module Form
    module RadioButtonHelper
      include BaseHelper

      def radio_button(method, tag_value, options = {})
        options.merge! offset: true, use_label: false
        options[:label] ||= tag_value
        base_field method, :radio_button, options do
          label_and_field 'radio', method, options do
            super method, tag_value, options
          end
        end
      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
railsstrap-4.0.0.beta3 lib/railsstrap/core_ext/rails/form/radio_button_helper.rb
railsstrap-4.0.0.beta2 lib/railsstrap/core_ext/rails/form/radio_button_helper.rb