import { autocompleteClasses } from '@mui/material/Autocomplete';
export const MuiAutocomplete = {
    styleOverrides: {
        root({ theme }) {
            return {
                [`&.${autocompleteClasses.hasPopupIcon}.${autocompleteClasses.hasClearIcon}`]: {
                    [`.${autocompleteClasses.inputRoot}`]: {
                        paddingRight: `${theme.spacing(14)}`,
                    },
                },
            };
        },
        inputRoot({ theme, ownerState: { size } }) {
            return {
                paddingTop: `${theme.spacing(1)} !important`,
                paddingBottom: `${theme.spacing(1)} !important`,
                paddingLeft: `${theme.spacing(3)} !important`,
                minHeight: size === 'small' ? '32px' : '40px',
            };
        },
        input() {
            return {
                padding: '0 !important',
            };
        },
        popupIndicator({ theme }) {
            return {
                color: theme.palette.grey[800],
            };
        },
        endAdornment({ theme }) {
            return {
                display: 'flex',
                alignItems: 'center',
                justifyContent: 'flex-end',
                color: theme.palette.grey[800],
                transform: 'unset',
                top: 'unset',
                right: '8px !important',
                flexGrow: 1,
                '.MuiButtonBase-root': {
                    marginRight: `${theme.spacing(1)} !important`,
                },
            };
        },
        paper({ theme }) {
            return {
                marginTop: theme.spacing(2),
                borderRadius: theme.shape.medium,
            };
        },
        noOptions({ theme }) {
            return {
                display: 'flex',
                justifyContent: 'center',
                alignItems: 'center',
                height: '64px',
                color: theme.palette.grey['600'],
            };
        },
        clearIndicator({ theme }) {
            return {
                color: theme.palette.grey[800],
                visibility: 'visible',
            };
        },
        loading() {
            return {
                display: 'flex',
                justifyContent: 'center',
                alignItems: 'center',
                height: '64px',
            };
        },
        tagSizeMedium({ theme }) {
            return {
                marginLeft: 0,
                marginRight: `${theme.spacing(1)}`,
            };
        },
    },
};
