refactor: background removal

This commit is contained in:
Ibrahima G. Coulibaly
2025-03-26 04:14:19 +00:00
parent a7c3e47ba1
commit c0297a187d
3 changed files with 75 additions and 73 deletions

View File

@@ -69,30 +69,13 @@ export default function RemoveBackgroundFromPng({ title }: ToolComponentProps) {
/>
}
resultComponent={
<>
{isProcessing ? (
<Box
sx={{
display: 'flex',
flexDirection: 'column',
alignItems: 'center',
justifyContent: 'center',
minHeight: '200px'
}}
>
<CircularProgress />
<Typography variant="body2" sx={{ mt: 2 }}>
Removing background... This may take a moment.
</Typography>
</Box>
) : (
<ToolFileResult
title={'Transparent PNG'}
value={result}
extension={'png'}
/>
)}
</>
<ToolFileResult
title={'Transparent PNG'}
value={result}
extension={'png'}
loading={isProcessing}
loadingText={'Removing background'}
/>
}
toolInfo={{
title: 'Remove Background from PNG',