The below is the basic px-accordion tag which I am using.
<px-accordion class="start-expanded" header-value="Report">
....
</px>
Trying to toggle it by default on selecting the respective tab. Below is the snippet for toggle functionality.
MD.ui.panels
.getActivePanel()
.el.find('px-accordion.start-expanded')
.each(function() {
$(this)[0].toggle();
});
};
Unfortunately, the toggle function is throwing an error in firefox browser saying "TypeError: $(...).toggle is not a function".
note: the same code is working fine in chrome. I believe in firefox, the toggle() is called before the px-accordion element loads which throws the error.