The "gf_inline" Ready Class sets the width of the inputs/select containers to "auto" so they work inline properly.. the inputs are set to percentage widths so they inherit from that parent container width. If you target an individual container ( list item ) correctly with a new CSS rule, you can override the auto and define a specific width if you prefer. There's nothing broken there.
I can't tell you anything specifically about your form since you only included a screen capture.
The "enhanced UI" elements are basically divs that replace the default form select element at runtime and the widths are defined dynamically by the script. You can still view the source, grab the element ID's/classes and then redefine their width values with a few CSS rules. See my test here.
http://screencast.com/t/Fjca2ElNrft
The second select that has the "set width" was resized by adding these new rules to the stylesheet.
[css]
body .gform_wrapper .top_label li#field_104_7.gfield.gf_inline div#input_104_7_chzn[style] {
width: 300px !important
}
body .gform_wrapper .top_label li#field_104_7.gfield.gf_inline div.chzn-drop[style] {
width: 298px !important
}
body .gform_wrapper .top_label li#field_104_7.gfield.gf_inline div.chzn-search input[style] {
width: 260px !important
}
So, if you're going to start mixing custom styles with the enhanced UI scripts then you're probably going to end up needing to tweak the layout a bit here and there. The Ready Styles are a good place to start, but they're still just generic CSS rules and aren't bulletproof by any means.
Posted 13 years ago on Saturday October 8, 2011 |
Permalink