text: import React from "react";
  import PropTypes from "prop-types";
  import clsx from "clsx";
  import Button from "@material-ui/core/Button";
  import CheckCircleIcon from "@material-ui/icons/CheckCircle";
  import ErrorIcon from "@material-ui/icons/Error";
  import InfoIcon from "@material-ui/icons/Info";
  import CloseIcon from "@material-ui/icons/Close";
  import { amber, green } from "@material-ui/core/colors";
  import IconButton from "@material-ui/core/IconButton";
  import Snackbar from "@material-ui/core/Snackbar";
  import SnackbarContent from "@material-ui/core/SnackbarContent";
  import WarningIcon from "@material-ui/icons/Warning";
  import { makeStyles } from "@material-ui/core/styles";
  import MySnackbarContentWrapper from "./MySnackbarContentWrapper";
  
  const useStyles2 = makeStyles(theme => ({
    margin: {
      margin: theme.spacing(1)
    }
  }));
  
  export default class CustomizedSnackbars extends React.Component {
    //classes = useStyles2();
    state = {
      open: false,
      variant: "success",
      message: "success"
    };
    handleOpen = (message, variant) => {
      console.log(message, variant);
      this.setState({ open: true, variant, message });
    };
  
    handleClose = () => {
      this.setState({ open: false });
    };
    render() {
      return (
        <div>
          <Snackbar
            anchorOrigin={{
              vertical: "bottom",
              horizontal: "left"
            }}
            open={this.state.open}
            autoHideDuration={6000}
            onClose={this.handleClose}
          >
            <MySnackbarContentWrapper
              onClose={this.handleClose}
              variant={this.state.variant}
              message={this.state.message}
            />
          </Snackbar>
        </div>
      );
    }
  }
  