"use strict";
var __importDefault = (this && this.__importDefault) || function (mod) {
    return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", { value: true });
exports.ErrorSnackbar = void 0;
var react_1 = __importDefault(require("react"));
var ui_i18n_1 = __importDefault(require("ui-i18n"));
var Close_1 = __importDefault(require("@mui/icons-material/Close"));
var Snackbar_1 = __importDefault(require("@mui/material/Snackbar"));
var SmallIconButton_1 = require("../SmallIconButton");
var ErrorSnackbar_module_css_1 = __importDefault(require("./ErrorSnackbar.module.css"));
var ErrorSnackbar = function (_a) {
    var error = _a.error, onClose = _a.onClose;
    return (react_1.default.createElement(Snackbar_1.default, { open: Boolean(error), onClose: onClose, message: error, action: react_1.default.createElement(SmallIconButton_1.SmallIconButtonWithTooltip, { className: ErrorSnackbar_module_css_1.default.closeIcon, tooltipTitle: ui_i18n_1.default.text('Close'), icon: Close_1.default, onClick: onClose }) }));
};
exports.ErrorSnackbar = ErrorSnackbar;
