Open fadion opened 4 years ago
Well, you could throw your own list component using SwipeOut base component, the list component just loops items and renders individual swipeouts.
That would work, although more involved. In my view, having a with-transition
prop on the SwipeList component that instead of rendering a plain <div>
, renders a <transition-group>
would be much more usable.
Maybe that's a functionality that only a few need, so not sure how much it makes sense. Just a thought.
Maybe that's a functionality that only a few need, so not sure how much it makes sense. Just a thought.
Well it totally makes sense, and we are more than open for PRs.
As I am not the biggest expert on transition groups, I have to do some analysis on how one would define all the possibilities that would be passed to the transition-group
element so we could decide on some simple, but yet feature-rich, api.
I may try and implement a version that uses transition groups in the following days. Will investigate it further and open a PR when it's ready.
Is there any way to wrap the swipe-list in a transition group? It would be really useful when doing deletes (for animating the row removal) or when dynamically inserting new rows.