mirror of
https://github.com/Hopiu/jquery-mobile.git
synced 2026-05-21 04:41:52 +00:00
controlgroup only gets innerwrapped if there's a controlgroup label (legend element)
This commit is contained in:
parent
9ccead23b6
commit
82c041b23d
1 changed files with 1 additions and 2 deletions
|
|
@ -16,10 +16,9 @@ $.fn.controlgroup = function(options){
|
|||
flCorners = o.direction == 'horizontal' ? ['ui-corner-left', 'ui-corner-right'] : ['ui-corner-top', 'ui-corner-bottom'],
|
||||
type = $(this).find('input:eq(0)').attr('type');
|
||||
|
||||
$(this).wrapInner('<div class="ui-controlgroup-controls"></div>');
|
||||
|
||||
//replace legend with more stylable replacement div
|
||||
if( groupheading.length ){
|
||||
$(this).wrapInner('<div class="ui-controlgroup-controls"></div>');
|
||||
$('<div role="heading" class="ui-controlgroup-label">'+ groupheading.html() +'</div>').insertBefore( $(this).children(0) );
|
||||
groupheading.remove();
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue