mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-16 21:00:31 +00:00
25 lines
480 B
JavaScript
25 lines
480 B
JavaScript
import React from 'react';
|
|
import { Choose } from 'components';
|
|
import BigcapitalLoading from './BigcapitalLoading';
|
|
|
|
/**
|
|
* Dashboard loading indicator.
|
|
*/
|
|
export default function DashboardLoadingIndicator({
|
|
isLoading = false,
|
|
className,
|
|
children,
|
|
}) {
|
|
return (
|
|
<Choose>
|
|
<Choose.When condition={isLoading}>
|
|
<BigcapitalLoading />
|
|
</Choose.When>
|
|
|
|
<Choose.Otherwise>
|
|
{ children }
|
|
</Choose.Otherwise>
|
|
</Choose>
|
|
);
|
|
}
|