import React from 'react';
import i18n from 'ui-i18n';
import CloseIcon from '@mui/icons-material/Close';
import Snackbar from '@mui/material/Snackbar';
import { SmallIconButtonWithTooltip } from '../../../SmallIconButton';
import { useStyles } from './styles';
export var ErrorSnackbar = function (_a) {
    var error = _a.error, onClose = _a.onClose;
    var styles = useStyles();
    return (React.createElement(Snackbar, { open: Boolean(error), onClose: onClose, message: error, action: React.createElement(SmallIconButtonWithTooltip, { className: styles.closeIcon, tooltipTitle: i18n.text('Close'), icon: CloseIcon, onClick: onClose }) }));
};
