No commit activity in last 3 years
No release in over 3 years
Adds a bootstrap date picker simple form input with wrapper. Creates an input group with a calendar icon with support for Bootstrap, FontAwesome, and Foundation glyph libraries.
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

~> 1.7
~> 10.0
 Project Readme

Simple Form Bootstrap Datepicker

Gem Version

Adds a bootstrap date picker for Simple Form.

Includes support for Bootstrap, FontAwesome, and Foundation icon libraries used in the bootstrap input group.

Requirements

Optional

Installation

Add it to your Gemfile:

gem 'simple_form_bootstrap_datepicker'

Run the following command to install it:

bundle install

Run the generator:

rails generate simple_form_bootstrap_datepicker:install

Usage

<%= simple_form_for @user do |f| %>
  <%= f.input :start_date, as: :date_picker, wrapper: date_picker, input_html: {icon: :bs} %>
  <%= f.button :submit %>
<% end %>

A default placeholder is added mm/dd/yyyy if one is not specified. There are currently three icon libraries which can be specified with :bs for bootstrap, :fa for font-awesome, and :fi for foundation. If an icon library isn't specified then a default Date will be added the icon section.

Contributing

  1. Fork it ( https://github.com/arian-amador/biostars-api/fork )
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create a new Pull Request