Sha256: dd544bdcadefb16a25bdbf43d88c8faa5fe15904963e81ca8eb5604999541831

Contents?: true

Size: 389 Bytes

Versions: 1

Compression:

Stored size: 389 Bytes

Contents

class MappingInput < SimpleForm::Inputs::MappingInput
  def label_input
    content = "".html_safe
    [ :input, :error, :hint ].each do |component|
      next if options[component] == false
      rendered = send(component)
      content.safe_concat rendered.to_s if rendered
    end
    (options[:label] == false ? "" : label) + "<div class=\"input\">#{content}</div>".html_safe
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
bootstrap-generators-0.0.3 lib/generators/bootstrap/install/templates/app/inputs/mapping_input.rb