Open kmob2 opened 8 years ago
Calling$.redux.initFields();
when the value of a field is changed, seems to do the trick.
wp.customize( 'mytheme[demo_buttons]', function( value ) {
value.bind( function( newval ) {
$.redux.initFields();
} );
} );
When the customizer panel is loaded, and a redux field is hidden on page load, and then made visible, the redux style is not applied to the field. Only the raw HTML field is shown, everything redux related is stripped from the style. Only once you click into the field, the redux style is being applied. The fields are being hidden using the official Customizer API.
Any idea on how I could fix this? Clicking the radio button again, to hide the slider again, and then making them visible again, applies the style again. It seems that something doesn't fire when the customizer is first loaded and a redux field is hidden.