Skip to content

Conversation

@lcreid
Copy link
Contributor

@lcreid lcreid commented Jul 20, 2018

Bootstrap 4 wraps check boxes and radio buttons in a div.form-check. Similar to the div.form-group around other controls, this PR allows the programmer to add classes to the "wrapper" div.form-check, like we currently allow for the div.form-group.

This PR extends the wrapper_class option to check_box and radio_button helpers, and applies the classes to the div.form-check around the label and control for the check box or radio button.

This PR also includes some refactoring in check_box and radio_button. The first commit shows the refactoring on check_box. The second adds the wrapper_class functionality. The third commit does the refactoring and adds the functionality on radio_button. (Sorry. I forgot the commit for the refactoring.) Finally, there is a commit to eliminate a test for options[:custom] in both check_box and radio_button.

Fixes #476.

@lcreid lcreid requested a review from mattbrictson July 20, 2018 23:22
@lcreid lcreid merged commit 31b5e84 into bootstrap-ruby:master Sep 13, 2018
@lcreid lcreid deleted the 476-wrapper-class branch January 23, 2019 21:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant