kopia lustrzana https://gitlab.com/soapbox-pub/soapbox
ScrollableList: render a spinner if placeholder isn't provided
rodzic
ae48cb2c06
commit
730556a692
|
@ -105,6 +105,8 @@ const ScrollableList: React.FC<IScrollableList> = ({
|
||||||
// Don't use Virtuoso's Footer component so it preserves spacing
|
// Don't use Virtuoso's Footer component so it preserves spacing
|
||||||
if (hasMore && Placeholder) {
|
if (hasMore && Placeholder) {
|
||||||
data.push(<Placeholder />);
|
data.push(<Placeholder />);
|
||||||
|
} else if (hasMore) {
|
||||||
|
data.push(<Spinner />);
|
||||||
}
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
|
Ładowanie…
Reference in New Issue