Change background color as needed
giulianok opened this issue · 0 comments
giulianok commented
Is your feature request related to a problem? Please describe.
The item has a fixed color (white) that can only be customizable by providing custom styles or by overriding the item class. See https://github.com/sandstreamdev/react-swipeable-list/blob/master/src/SwipeableListItem.css#L15. The problem comes when the list is needed in different colors.
Describe the solution you'd like
Add an optional className
prop to SwipeableListItem
to let the user makes any overrides needed.
Describe alternatives you've considered
- Add an optional
bgColor
prop toSwipeableListItem
to let the user customize it. - Use CSS variables to let the user customize it via CSS. This only adds some flexibility but does not help to fix the issue of using the list with different bg colors.
Additional context
N/A
Note: Happy to open a PR with a solution after discussing the options