mjbellantoni / formtastic-bootstrap

Formtastic form builder to generate Twitter Bootstrap-friendly markup.
MIT License
443 stars 218 forks source link

Add ability to append buttons or content without an add-on span #77

Closed anark closed 11 years ago

anark commented 11 years ago

Adds the option to append things like buttons that do not work when they are within an span.add-on

sodabrew commented 11 years ago

Thanks! This looks interesting. Does it match with existing formtastic behavior? I would prefer not to create too much special / new behavior that only exists in formtastic-bootstrap.

anark commented 11 years ago

Formtastic has no concept of appended or prepended inputs as these are a bootstrap concept.

This pull request adds the 'append_content' and 'prepend_content' options to go along with the existing 'append' and 'prepend' options.

anark commented 11 years ago

An alternative would be to alter the existing 'append' and 'prepend' options to not include the '<span class="add-on"'>. That way it could be manually passed or excluded at the users discression. However this would not be backwards compatible as existing usages of the append option would lose the 'add-on' span wrapper

sodabrew commented 11 years ago

Sounds good, I'll take it!