All child checkboxes in section unchecked on hide
Hi there,
This iteration on hide is causing child checkboxes to be unchecked when the section is hidden.
$section.find('select, input').each(function(){ if ( ($(this).attr('type')=='radio') || ($(this).attr('type')=='checkbox') ) { $(this).prop('checked', false).trigger('change'); } else{ $(this).val('').trigger('change'); } });
For my purpose, this is unwanted behaviour as the settings should "stay" intact by their default value state (checked or unchecked). For now I removed this part in my copy of the library, but it would be nice to have more control over what to uncheck in the underlaying section and what not.
Hi, I agree. I am going to add it soon in this way.
I have the same issue with select HTML tag.
After commenting the following lines, the selected stated is saved and not cleared after change
if ( ($(this).attr('type')=='radio') || ($(this).attr('type')=='checkbox') ) {
//$(this).prop('checked', false).trigger('change');
}
else{
//$(this).val('').trigger('change');
}
``
This issue is fixed in the conditionize2.js Also, take a look at my last comment here