import { Grid, Typography, Box, FormControlLabel, Checkbox } from '@mui/material';

const SuspendPallets = ({ state = {}, handleChange = (name = '', val = '') => {} }) => {
	return (
		<Grid container spacing={1} flex mt={3} mb={3}>
			<Grid item flex={1} xs={4}>
				<Typography variant='subtitle1' fontWeight='bold'>
					Pallet packaging
				</Typography>
			</Grid>
			<Grid item flex={2} xs={8}>
				<Box component='div'>
					<FormControlLabel
						control={
							<Checkbox
								checked={state?.suspend_pallets || false}
								onChange={e => handleChange('suspend_pallets', e.target.checked)}
							/>
						}
						label='Suspend use for only this provider.'
					/>
				</Box>
			</Grid>
		</Grid>
	);
};

export default SuspendPallets;
