Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

input groups #839

wants to merge 4 commits into


None yet
2 participants

trimentor commented Apr 14, 2012

Hi Justin,

In one of our projects we needed a way to create input groups (prepend and append stuff to our fields) to give our inputs more context. Instead of repeating myself over and over again I created a new Formtastic Input called IconishSegmentsInput.

I documented the code, added specs, basic CSS styles and examples.

Please take a look at the code and feel free to ask questions, modify and use the code.

Keep up the good work!

With kind regards,


justinfrench commented Jun 4, 2012

Hi, this looks interesting! I'm not going to merge it in as-is, but would like to keep talking about it if you have time!

  1. I think it's plausible that you would want this functionality on many of the input types that currently mixin Stringish, so I'm wondering if maybe this should be functionality that's mixed into the existing inputs, rather than a new type of custom input. Probably just starting with some of the Stringish inputs?
  2. From there, it would be good to think about the option names & API, as there's potential overlap with the idea of generic :prefix and (just inside the li wrapper at the start) and :suffix (just before the </li>) that have been on my radar for a while.
  3. Out of the box, the CSS should probably be a little less heavy-handed and opinionated on styling — we usually aim for the most minimal representation we can, and rounded borders is probably too much of an embellishment.

Anyway, interested in your thoughts on #1 mostly to start with.


trimentor commented Jun 16, 2012

Hi Justin,

Thank you for your time, interest and feedback!

  1. I think you're right. I'll extract my code in a new module, suggestions (naming, etc.) are always welcome!

  2. Sounds good! I would like to know more about your idea. What do you think about renaming the options :input_prepend and :input_append into :input_prefix and :input_suffix?

  3. I'll remove border-radius and border-color.


justinfrench commented Jul 4, 2013

Closing due to lack of activity.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment