GotJimmy / accordion

Other
47 stars 44 forks source link

Give each instance of Accordion its own ListController #19

Closed SirObi closed 2 years ago

SirObi commented 2 years ago

What is the pre-existing problem this Pull Request is trying to solve?

Currently, it's not possible to have two Accordions in the widget tree without causing errors and unwanted behaviour (e.g. two Accordions expanding when one is clicked). This is due to the fact multiple Accordions use the same ListController instance stored by GetX.

The problem was originally raised in the following issue: https://github.com/GotJimmy/accordion/issues/20

This PR introduces the following changes