Skip to content
This repository

Calling controlgroup constructor causes fieldset width to shrink #4716

Closed
gracezlive opened this Issue July 17, 2012 · 3 comments

2 participants

Grace Wong Jasper de Groot
Grace Wong

Hello,

I call controlgroup constructor when data is updated on a page using knockoutjs, so that jqm control styles can be re-applied correctly. The following code used to work, until I upgraded to jqm 1.1.1. Every time the constructor is called, the fieldset width would shrink. This only happens when a fieldset controlgroup is inside of a div fieldcontain. Fieldset not nested inside of a div fieldcontain still works fine. The problem is observed in Google Chrome in Windows and Safari on iPad. I have not tried other browsers yet. Here is the sample code:

http://jsbin.com/icoxek/4/edit#preview

Thanks.

Jasper de Groot
Owner

@gracezlive

Thanks for reporting the issue with a test page.
Actually we noticed the bug ourselves while we were updating the JQM ThemeRoller to 1.1.1., when it is was already too late to fix this.
This regression is caused by a change we made to have the buttons of the controlgroup always being wrapped in a div with class ui-controlgroup-controls (for styling purposes) and not only if there is a legend. What happens now is that each time controlgroup() is called, the div is wrapped again.
Besides a fix I am looking into a temporary workaround for people. If I have one, I will post it in a comment here.

Jasper de Groot uGoMobi closed this issue from a commit August 02, 2012
Jasper de Groot Controlgroup: Prevent the controls from being wrapped multiple times.…
… Fixes #4716 - Calling controlgroup constructor causes fieldset width to shrink.
352d4b3
Jasper de Groot uGoMobi closed this in 352d4b3 August 02, 2012
Jasper de Groot
Owner

@gracezlive

I committed a fix for this. Unfortunately there is not a workaround that you can add to your custom script. Good news is that it will be fixed in 1.2 which is on its way.

Jasper de Groot uGoMobi referenced this issue from a commit August 02, 2012
Jasper de Groot Controlgroup: Prevent the controls from being wrapped multiple times.…
… Fixes #4716 - Calling controlgroup constructor causes fieldset width to shrink.
4bf78fd
Grace Wong

Thank you very much!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.