I am a beginner with Angular 4 and I have implemented an accordion with the structure of Categories, Groups, and Subgroups.
When I click on a category, it displays all the groups within that category. Similarly, when I click on a group, it shows all the subgroups.
Currently, everything is functioning as expected.
What I am trying to achieve is that when I click on a Category again, I want the accordion to close along with all the previously opened groups.
In my current setup, if I open some groups, then close the accordion, and reopen it, it displays the previously opened groups.
I have shared a link to my code on StackBlitz: https://stackblitz.com/edit/angular-bootstrap-carousel-dynamic2-ghebrf?file=app/app.component.html
Can anyone offer assistance in resolving this issue?