Press n or j to go to the next uncovered block, b, p or k for the previous block.
| 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 | 1297x 1583x | import type React from "react";
import { Overlay } from "~components/overlay";
import { Spinner } from "~components/spinner";
import type { ViewReactNode } from "~components/view";
type Props = {
isPending?: boolean;
children?: ViewReactNode;
};
export const SuspendedOverlay: React.FC<Props> = ({ isPending, children }) => (
<Overlay
className="gap-2"
overlay={isPending ? <Spinner size="lg" /> : undefined}
testID="suspended-overlay"
>
{children}
</Overlay>
);
|