35 lines
858 B
JavaScript
35 lines
858 B
JavaScript
// LoaderWithImage.jsx
|
|
import React from 'react';
|
|
import { Box, CircularProgress } from '@mui/material';
|
|
import nelogo from '../../assets/images/doormile-mark.png';
|
|
|
|
export default function LoaderWithImage({ size = 70, imgSize = 40, alt = 'loader' }) {
|
|
return (
|
|
<Box position="relative" display="inline-flex" justifyContent="center" alignItems="center">
|
|
<CircularProgress size={size} />
|
|
|
|
<Box
|
|
position="absolute"
|
|
display="flex"
|
|
justifyContent="center"
|
|
alignItems="center"
|
|
sx={{
|
|
width: imgSize,
|
|
height: imgSize
|
|
}}
|
|
>
|
|
<img
|
|
src={nelogo}
|
|
alt={alt}
|
|
style={{
|
|
width: '100%',
|
|
height: '100%',
|
|
borderRadius: '50%',
|
|
objectFit: 'contain'
|
|
}}
|
|
/>
|
|
</Box>
|
|
</Box>
|
|
);
|
|
}
|