r n=this,c=this.props.enter,l=e,d=this.getTimeouts();e||c?(this.props.onEnter&&this.props.onEnter(this.node,l),this.safeSetState({status:C},function(){n.props.onEntering&&n.props.onEntering(n.node,l),n.onTransitionEnd(d.enter,function(){n.safeSetState({status:T},function(){n.props.onEntered&&n.props.onEntered(n.node,l)})})})):this.safeSetState({status:T},function(){n.props.onEntered&&n.props.onEntered(n.node,l)})},n.performExit=function performExit(){var e=this,n=this.props.exit,c=this.getTimeouts();n?(this.props.onExit&&this.props.onExit(this.node),this.safeSetState({status:O},function(){e.props.onExiting&&e.props.onExiting(e.node),e.onTransitionEnd(c.exit,function(){e.safeSetState({status:S},function(){e.props.onExited&&e.props.onExited(e.node)})})})):this.safeSetState({status:S},function(){e.props.onExited&&e.props.onExited(e.node)})},n.cancelNextCallback=function cancelNextCallback(){null!==this.nextCallback&&this.nextCallback.cancel&&(this.nextCallback.cancel(),this.nextCallback=null)},n.safeSetState=function safeSetState(e,n){n=this.setNextCallback(n),this.setState(e,n)},n.setNextCallback=function setNextCallback(e){var n=this,c=!0;return this.nextCallback=function(){c&&(c=!1,n.nextCallback=null,e())},this.nextCallback.cancel=function(){c=!1},this.nextCallback},n.onTransitionEnd=function onTransitionEnd(e,n){this.setNextCallback(n);var c=null==e&&!this.props.addEndListener;this.node&&!c?(this.props.addEndListener&&this.props.addEndListener(this.node,this.nextCallback),null!=e&&setTimeout(this.nextCallback,e)):setTimeout(this.nextCallback,0)},n.render=function render(){var e=this.state.status;if(e===w)return null;var n=this.props;return(0,n.children)(e,_objectWithoutPropertiesLoose(n,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]))},_createClass(Transition,[{key:"node",get:function get(){var e,n=null===(e=this.props.nodeRef)||void 0===e?void 0:e.current;if(!n)throw new Error("notistack - Custom snackbar is not refForwarding");return n}}]),Transition}(d().Component);function noop(){}function setRef(e,n){"function"==typeof e?e(n):e&&(e.current=n)}function useForkRef(e,n){return(0,l.useMemo)(function(){return null==e&&null==n?null:function(c){setRef(e,c),setRef(n,c)}},[e,n])}function getTransitionProps(e){var n=e.timeout,c=e.style,l=void 0===c?{}:c,d=e.mode;return{duration:"object"==typeof n?n[d]||0:n,easing:l.transitionTimingFunction,delay:l.transitionDelay}}L.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:noop,onEntering:noop,onEntered:noop,onExit:noop,onExiting:noop,onExited:noop};var P="cubic-bezier(0.4, 0, 0.2, 1)",D="cubic-bezier(0.0, 0, 0.2, 1)",N="cubic-bezier(0.4, 0, 0.6, 1)",R=function reflow(e){e.scrollTop=e.scrollTop},q=function formatMs(e){return Math.round(e)+"ms"};function createTransition(e,n){void 0===e&&(e=["all"]);var c=n||{},l=c.duration,d=void 0===l?300:l,f=c.easing,h=void 0===f?P:f,g=c.delay,x=void 0===g?0:g;return(Array.isArray(e)?e:[e]).map(function(e){var n="string"==typeof d?d:q(d),c="string"==typeof x?x:q(x);return e+" "+n+" "+h+" "+c}).join(",")}function ownerWindow(e){var n=function ownerDocument(e){return e&&e.ownerDocument||document}(e);return n.defaultView||window}function setTranslateValue(e,n){if(n){var c=function getTranslateValue(e,n){var c,l=n.getBoundingClientRect(),d=ownerWindow(n);if(n.fakeTransform)c=n.fakeTransform;else{var f=d.getComputedStyle(n);c=f.getPropertyValue("-webkit-transform")||f.getPropertyValue("transform")}var h=0,g=0;if(c&&"none"!==c&&"string"==typeof c){var x=c.split("(")[1].split(")")[0].split(",");h=parseInt(x[4],10),g=parseInt(x[5],10)}switch(e){case"left":return"translateX("+(d.innerWidth+h-l.left)+"px)";case"right":return"translateX(-"+(l.left+l.width-h)+"px)";case"up":return"translateY("+(d.innerHeight+g-l.top)+"px)";default:return"translateY(-"+(l.top+l.height-g)+"px)"}}(e,n);c&&(n.style.webkitTransform=c,n.style.transform=c)}}var A=(0,l.forwardRef)(function(e,n){var c=e.children,d=e.direction,f=void 0===d?"down":d,h=e.in,g=e.style,x=e.timeout,k=void 0===x?0:x,b=e.onEnter,v=e.onEntered,E=e.onExit,y=e.onExited,_=_objectWithoutPropertiesLoose(e,["children","direction","in","style","timeout","onEnter","onEntered","onExit","onExited"]),w=(0,l.useRef)(null),S=useForkRef(c.ref,w),C=useForkRef(S,n),T=(0,l.useCallback)(function(){w.current&&setTranslateValue(f,w.current)},[f]);return(0,l.useEffect)(function(){if(!h&&"down"!==f&&"right"!==f){var e=function debounce(e,n){var c;function debounced(){for(var l=this,d=arguments.length,f=new Array(d),h=0;h<d;h++)f[h]=arguments[h];clearTimeout(c),c=setTimeout(function later(){e.apply(l,f)},n)}return void 0===n&&(n=166),debounced.clear=function(){clearTimeout(c)},debounced}(function(){w.current&&setTranslateValue(f,w.current)}),n=ownerWindow(w.current);return n.addEventListener("resize",e),function(){e.clear(),n.removeEventListener("resize",e)}}},[f,h]),(0,l.useEffect)(function(){h||T()},[h,T]),(0,l.createElement)(L,Object.assign({appear:!0,nodeRef:w,onEnter:function handleEnter(e,n){setTranslateValue(f,e),R(e),b&&b(e,n)},onEntered:v,onEntering:function handleEntering(e){var n=(null==g?void 0:g.transitionTimingFunction)||D,c=getTransitionProps({timeout:k,mode:"enter",style:_extends({},g,{transitionTimingFunction:n})});e.style.webkitTransition=createTransition("-webkit-transform",c),e.style.transition=createTransition("transform",c),e.style.webkitTransform="none",e.style.transform="none"},onExit:function handleExit(e){var n=(null==g?void 0:g.transitionTimingFunction)||N,c=getTransitionProps({timeout:k,mode:"exit",style:_extends({},g,{transitionTimingFunction:n})});e.style.webkitTransition=createTransition("-webkit-transform",c),e.style.transition=createTransition("transform",c),setTranslateValue(f,e),E&&E(e)},onExited:function handleExited(e){e.style.webkitTransition="",e.style.transition="",y&&y(e)},in:h,timeout:k},_),function(e,n){return(0,l.cloneElement)(c,_extends({ref:C,style:_extends({visibility:"exited"!==e||h?void 0:"hidden"},g,{},c.props.style)},n))})});A.displayName="Slide";var M=function SvgIcon(e){return d().createElement("svg",Object.assign({viewBox:"0 0 24 24",focusable:"false",style:{fontSize:20,marginInlineEnd:8,userSelect:"none",width:"1em",height:"1em",display:"inline-block",fill:"currentColor",flexShrink:0}},e))},W=function CheckIcon(){return d().createElement(M,null,d().createElement("path",{d:"M12 2C6.5 2 2 6.5 2 12S6.5 22 12 22 22 17.5 22 12 17.5 2 12 2M10 17L5 12L6.41\n        10.59L10 14.17L17.59 6.58L19 8L10 17Z"}))},V=function WarningIcon(){return d().createElement(M,null,d().createElement("path",{d:"M13,14H11V10H13M13,18H11V16H13M1,21H23L12,2L1,21Z"}))},I=function ErrorIcon(){return d().createElement(M,null,d().createElement("path",{d:"M12,2C17.53,2 22,6.47 22,12C22,17.53 17.53,22 12,22C6.47,22 2,17.53 2,12C2,\n        6.47 6.47,2 12,2M15.59,7L12,10.59L8.41,7L7,8.41L10.59,12L7,15.59L8.41,17L12,\n        13.41L15.59,17L17,15.59L13.41,12L17,8.41L15.59,7Z"}))},H=function InfoIcon(){return d().createElement(M,null,d().createElement("path",{d:"M13,9H11V7H13M13,17H11V11H13M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,\n        0 22,12A10,10 0 0,0 12,2Z"}))},F={maxSnack:3,persist:!1,hideIconVariant:!1,disableWindowBlurListener:!1,variant:"default",autoHideDuration:5e3,iconVariant:{default:void 0,success:d().createElement(W,null),warning:d().createElement(V,null),error:d().createElement(I,null),info:d().createElement(H,null)},anchorOrigin:{vertical:"bottom",horizontal:"left"},TransitionComponent:A,transitionDuration:{enter:225,exit:195}},z=function merge(e,n){return function(c,l){return void 0===l&&(l=!1),l?_extends({},F[c],{},n[c],{},e[c]):"autoHideDuration"===c?function getAutoHideDuration(e,n){var c=function isNumberOrNull(e){return"number"==typeof e||null===e};return c(e)?e:c(n)?n:F.autoHideDuration}(e.autoHideDuration,n.autoHideDuration):"transitionDuration"===c?function getTransitionDuration(e,n){var c=function is(e,n){return n.some(function(n){return typeof e===n})};return c(e,["string","number"])?e:c(e,["object"])?_extends({},F.transitionDuration,{},c(n,["object"])&&n,{},e):c(n,["string","number"])?n:c(n,["object"])?_extends({},F.transitionDuration,{},n):F.transitionDuration}(e.transitionDuration,n.transitionDuration):e[c]||n[c]||F[c]}};function makeStyles(e){return Object.entries(e).reduce(function(e,n){var c,l=n[0],d=n[1];return _extends({},e,((c={})[l]=(0,g.css)(d),c))},{})}var B="notistack-SnackbarContainer",U="notistack-Snackbar",Z="notistack-CollapseWrapper",X="notistack-MuiContent",G=function MuiContentVariant(e){return"notistack-MuiContent-"+e},Q=makeStyles({root:{height:0},entered:{height:"auto"}}),K="0px",Y=(0,l.forwardRef)(function(e,n){var c=e.children,d=e.in,f=e.onExited,g=(0,l.useRef)(null),x=(0,l.useRef)(null),k=useForkRef(n,x),b=function getWrapperSize(){return g.current?g.current.clientHeight:0};return(0,l.createElement)(L,{in:d,unmountOnExit:!0,onEnter:function handleEnter(e){e.style.height=K},onEntered:function handleEntered(e){e.style.height="auto"},onEntering:function handleEntering(e){var n=b(),c=getTransitionProps({timeout:175,mode:"enter"}),l=c.duration,d=c.easing;e.style.transitionDuration="string"==typeof l?l:l+"ms",e.style.height=n+"px",e.style.transitionTimingFunction=d||""},onExit:function handleExit(e){e.style.height=b()+"px"},onExited:f,onExiting:function handleExiting(e){R(e);var n=getTransitionProps({timeout:175,mode:"exit"}),c=n.duration,l=n.easing;e.style.transitionDuration="string"==typeof c?c:c+"ms",e.style.height=K,e.style.transitionTimingFunction=l||""},nodeRef:x,timeout:175},function(e,n){return(0,l.createElement)("div",Object.assign({ref:k,className:(0,h.default)(Q.root,"entered"===e&&Q.entered),style:_extends({pointerEvents:"all",overflow:"hidden",minHeight:K,transition:createTransition("height")},"entered"===e&&{overflow:"visible"},{},"exited"===e&&!d&&{visibility:"hidden"})},n),(0,l.createElement)("div",{ref:g,className:Z,style:{display:"flex",width:"100%"}},c))})});Y.displayName="Collapse";var $={right:"left",left:"right",bottom:"up",top:"down"},J=function getSlideDirection(e){return"center"!==e.horizontal?$[e.horizontal]:$[e.vertical]},ee=function toSnackbarAnchorOrigin(e){return"anchorOrigin"+y(e)},ne=function noOp(){};function createChainedFunction(e,n){return e.reduce(function(e,c){return null==c?e:function chainedFunction(){for(var l=arguments.length,d=new Array(l),f=0;f<l;f++)d[f]=arguments[f];var h=[].concat(d);n&&-1===h.indexOf(n)&&h.push(n),e.apply(this,h),c.apply(this,h)}},ne)}var te="undefined"!=typeof window?l.useLayoutEffect:l.useEffect;function useEventCallback(e){var n=(0,l.useRef)(e);return te(function(){n.current=e}),(0,l.useCallback)(function(){return n.current.apply(void 0,arguments)},[])}var re,ie=(0,l.forwardRef)(function(e,n){var c=e.children,d=e.className,f=e.autoHideDuration,g=e.disableWindowBlurListener,x=void 0!==g&&g,k=e.onClose,b=e.id,v=e.open,E=e.SnackbarProps,y=void 0===E?{}:E,_=(0,l.useRef)(),w=useEventCallback(function(){k&&k.apply(void 0,arguments)}),S=useEventCallback(function(e){k&&null!=e&&(_.current&&clearTimeout(_.current),_.current=setTimeout(function(){w(null,"timeout",b)},e))});(0,l.useEffect)(function(){return v&&S(f),function(){_.current&&clearTimeout(_.current)}},[v,f,S]);var C=function handlePause(){_.current&&clearTimeout(_.current)},T=(0,l.useCallback)(function(){null!=f&&S(.5*f)},[f,S]);return(0,l.useEffect)(function(){if(!x&&v)return window.addEventListener("focus",T),window.addEventListener("blur",C),function(){window.removeEventListener("focus",T),window.removeEventListener("blur",C)}},[x,T,v]),(0,l.createElement)("div",Object.assign({ref:n},y,{className:(0,h.default)(U,d),onMouseEnter:function handleMouseEnter(e){y.onMouseEnter&&y.onMouseEnter(e),C()},onMouseLeave:function handleMouseLeave(e){y.onMouseLeave&&y.onMouseLeave(e),T()}}),c)});ie.displayName="Snackbar";var oe=makeStyles({root:(re={display:"flex",flexWrap:"wrap",flexGrow:1},re[v]={flexGrow:"initial",minWidth:"288px"},re)}),ae=(0,l.forwardRef)(function(e,n){var c=e.className,l=_objectWithoutPropertiesLoose(e,["className"]);return d().createElement("div",Object.assign({ref:n,className:(0,h.default)(oe.root,c)},l))});ae.displayName="SnackbarContent";var se=makeStyles({root:{backgroundColor:"#313131",fontSize:"0.875rem",lineHeight:1.43,letterSpacing:"0.01071em",color:"#fff",alignItems:"center",padding:"6px 16px",borderRadius:"4px",boxShadow:"0px 3px 5px -1px rgba(0,0,0,0.2),0px 6px 10px 0px rgba(0,0,0,0.14),0px 1px 18px 0px rgba(0,0,0,0.12)"},lessPadding:{paddingLeft:"20px"},default:{backgroundColor:"#313131"},success:{backgroundColor:"#43a047"},error:{backgroundColor:"#d32f2f"},warning:{backgroundColor:"#ff9800"},info:{backgroundColor:"#2196f3"},message:{display:"flex",alignItems:"center",padding:"8px 0"},action:{display:"flex",alignItems:"center",marginLeft:"auto",paddingLeft:"16px",marginRight:"-8px"}}),ce="notistack-snackbar",ue=(0,l.forwardRef)(function(e,n){var c=e.id,l=e.message,f=e.action,g=e.iconVariant,x=e.variant,k=e.hideIconVariant,b=e.style,v=e.className,E=g[x],y=f;return"function"==typeof y&&(y=y(c)),d().createElement(ae,{ref:n,role:"alert","aria-describedby":ce,style:b,className:(0,h.default)(X,G(x),se.root,se[x],v,!k&&E&&se.lessPadding)},d().createElement("div",{id:ce,className:se.message},k?null:E,l),y&&d().createElement("div",{className:se.action},y))});ue.displayName="MaterialDesignContent";var le,de,fe,pe,me,he,ge,xe=(0,l.memo)(ue),ke=makeStyles({wrappedRoot:{width:"100%",position:"relative",transform:"translateX(0)",top:0,right:0,bottom:0,left:0,minWidth:"288px"}}),be=function SnackbarItem(e){var n=(0,l.useRef)(),c=(0,l.useState)(!0),f=c[0],g=c[1],x=createChainedFunction([e.snack.onClose,e.onClose]),k=(0,l.useCallback)(function(){n.current=setTimeout(function(){g(function(e){return!e})},125)},[]);(0,l.useEffect)(function(){return function(){n.current&&clearTimeout(n.current)}},[]);var b=e.snack,v=e.classes,E=e.Component,y=void 0===E?xe:E,_=(0,l.useMemo)(function(){return function keepSnackbarClassKeys(e){void 0===e&&(e={});var n={containerRoot:!0,containerAnchorOriginTopCenter:!0,containerAnchorOriginBottomCenter:!0,containerAnchorOriginTopRight:!0,containerAnchorOriginBottomRight:!0,containerAnchorOriginTopLeft:!0,containerAnchorOriginBottomLeft:!0};return Object.keys(e).filter(function(e){return!n[e]}).reduce(function(n,c){var l;return _extends({},n,((l={})[c]=e[c],l))},{})}(v)},[v]),w=b.open,S=b.SnackbarProps,C=b.TransitionComponent,T=b.TransitionProps,O=b.transitionDuration,L=b.disableWindowBlurListener,P=b.content,D=_objectWithoutPropertiesLoose(b,["open","SnackbarProps","TransitionComponent","TransitionProps","transitionDuration","disableWindowBlurListener","content","entered","requestClose","onEnter","onEntered","onExit","onExited"]),N=_extends({direction:J(D.anchorOrigin),timeout:O},T),R=P;"function"==typeof R&&(R=R(D.id,D.message));var q=["onEnter","onEntered","onExit","onExited"].reduce(function(n,c){var l;return _extends({},n,((l={})[c]=createChainedFunction([e.snack[c],e[c]],D.id),l))},{});return d().createElement(Y,{in:f,onExited:q.onExited},d().createElement(ie,{open:w,id:D.id,disableWindowBlurListener:L,autoHideDuration:D.autoHideDuration,className:(0,h.default)(ke.wrappedRoot,_.root,_[ee(D.anchorOrigin)]),SnackbarProps:S,onClose:x},d().createElement(C,Object.assign({},N,{