mirror of
https://github.com/labring/FastGPT.git
synced 2025-07-28 00:56:26 +00:00
26 lines
583 B
TypeScript
26 lines
583 B
TypeScript
import React, { memo } from 'react';
|
|
import { Box } from '@chakra-ui/react';
|
|
|
|
const Loading = ({ text }: { text?: string }) => {
|
|
return (
|
|
<Box>
|
|
<Box
|
|
minW={'100px'}
|
|
w={'100%'}
|
|
h={'80px'}
|
|
backgroundImage={'url("/imgs/loading.gif")'}
|
|
backgroundSize={'contain'}
|
|
backgroundRepeat={'no-repeat'}
|
|
backgroundPosition={'center'}
|
|
/>
|
|
{text && (
|
|
<Box mt={1} textAlign={'center'} fontSize={'sm'} color={'myGray.600'}>
|
|
{text}
|
|
</Box>
|
|
)}
|
|
</Box>
|
|
);
|
|
};
|
|
|
|
export default memo(Loading);
|