diff --git a/dist/index.js b/dist/index.js index 5047133..30d99d8 100644 --- a/dist/index.js +++ b/dist/index.js @@ -1,4 +1,4 @@ -!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("react"),require("@material-ui/core"),require("@material-ui/core/ButtonBase"),require("clsx")):"function"==typeof define&&define.amd?define(["react","@material-ui/core","@material-ui/core/ButtonBase","clsx"],t):"object"==typeof exports?exports.MaterialUiBanner=t(require("react"),require("@material-ui/core"),require("@material-ui/core/ButtonBase"),require("clsx")):e.MaterialUiBanner=t(e.React,e["@material-ui/core"],e["@material-ui/core/ButtonBase"],e.clsx)}(window,(function(e,t,n,r){return function(e){var t={};function n(r){if(t[r])return t[r].exports;var i=t[r]={i:r,l:!1,exports:{}};return e[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var i in e)n.d(r,i,function(t){return e[t]}.bind(null,i));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=11)}([function(t,n){t.exports=e},function(e,n){e.exports=t},function(e,t,n){e.exports=n(7)()},,function(e,t){e.exports=n},function(e,t){e.exports=r},function(e,t,n){"use strict";e.exports=n(9)},function(e,t,n){"use strict";var r=n(8);function i(){}function o(){}o.resetWarningCache=i,e.exports=function(){function e(e,t,n,i,o,s){if(s!==r){var a=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw a.name="Invariant Violation",a}}function t(){return e}e.isRequired=e;var n={array:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:o,resetWarningCache:i};return n.PropTypes=n,n}},function(e,t,n){"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},function(e,t,n){"use strict"; +!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("react"),require("@mui/material"),require("@mui/material/ButtonBase"),require("clsx")):"function"==typeof define&&define.amd?define(["react","@mui/material","@mui/material/ButtonBase","clsx"],t):"object"==typeof exports?exports.MaterialUiBanner=t(require("react"),require("@mui/material"),require("@mui/material/ButtonBase"),require("clsx")):e.MaterialUiBanner=t(e.React,e["@mui/material"],e["@mui/material/ButtonBase"],e.clsx)}(window,(function(e,t,n,r){return function(e){var t={};function n(r){if(t[r])return t[r].exports;var i=t[r]={i:r,l:!1,exports:{}};return e[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var i in e)n.d(r,i,function(t){return e[t]}.bind(null,i));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=11)}([function(t,n){t.exports=e},function(e,n){e.exports=t},function(e,t,n){e.exports=n(7)()},,function(e,t){e.exports=n},function(e,t){e.exports=r},function(e,t,n){"use strict";e.exports=n(9)},function(e,t,n){"use strict";var r=n(8);function i(){}function o(){}o.resetWarningCache=i,e.exports=function(){function e(e,t,n,i,o,s){if(s!==r){var a=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw a.name="Invariant Violation",a}}function t(){return e}e.isRequired=e;var n={array:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:o,resetWarningCache:i};return n.PropTypes=n,n}},function(e,t,n){"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},function(e,t,n){"use strict"; /** @license React v17.0.2 * react-jsx-runtime.production.min.js * @@ -11,11 +11,12 @@ object-assign (c) Sindre Sorhus @license MIT -*/var r=Object.getOwnPropertySymbols,i=Object.prototype.hasOwnProperty,o=Object.prototype.propertyIsEnumerable;function s(e){if(null==e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}e.exports=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},n=0;n<10;n++)t["_"+String.fromCharCode(n)]=n;if("0123456789"!==Object.getOwnPropertyNames(t).map((function(e){return t[e]})).join(""))return!1;var r={};return"abcdefghijklmnopqrst".split("").forEach((function(e){r[e]=e})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},r)).join("")}catch(e){return!1}}()?Object.assign:function(e,t){for(var n,a,u=s(e),l=1;l=0||(i[n]=e[n]);return i}function p(){return(p=Object.assign||function(e){for(var t=1;t<+~=|^:(),"'`\s])/g,E="undefined"!=typeof CSS&&CSS.escape,B=function(e){return E?E(e):e.replace(j,"\\$1")},A=function(){function e(e,t,n){this.type="style",this.key=void 0,this.isProcessed=!1,this.style=void 0,this.renderer=void 0,this.renderable=void 0,this.options=void 0;var r=n.sheet,i=n.Renderer;this.key=e,this.options=n,this.style=t,r?this.renderer=r.renderer:i&&(this.renderer=new i)}return e.prototype.prop=function(e,t,n){if(void 0===t)return this.style[e];var r=!!n&&n.force;if(!r&&this.style[e]===t)return this;var i=t;n&&!1===n.process||(i=this.options.jss.plugins.onChangeValue(t,e,this));var o=null==i||!1===i,s=e in this.style;if(o&&!s&&!r)return this;var a=o&&s;if(a?delete this.style[e]:this.style[e]=i,this.renderable&&this.renderer)return a?this.renderer.removeProperty(this.renderable,e):this.renderer.setProperty(this.renderable,e,i),this;var u=this.options.sheet;return u&&u.attached,this},e}(),I=function(e){function t(t,n,r){var i;(i=e.call(this,t,n,r)||this).selectorText=void 0,i.id=void 0,i.renderable=void 0;var o=r.selector,s=r.scoped,a=r.sheet,u=r.generateId;return o?i.selectorText=o:!1!==s&&(i.id=u(x(x(i)),a),i.selectorText="."+B(i.id)),i}b(t,e);var n=t.prototype;return n.applyTo=function(e){var t=this.renderer;if(t){var n=this.toJSON();for(var r in n)t.setProperty(e,r,n[r])}return this},n.toJSON=function(){var e={};for(var t in this.style){var n=this.style[t];"object"!=typeof n?e[t]=n:Array.isArray(n)&&(e[t]=O(n))}return e},n.toString=function(e){var t=this.options.sheet,n=!!t&&t.options.link?p({},e,{allowEmpty:!0}):e;return R(this.selectorText,this.style,n)},m(t,[{key:"selector",set:function(e){if(e!==this.selectorText){this.selectorText=e;var t=this.renderer,n=this.renderable;if(n&&t)t.setSelector(n,e)||t.replaceRule(n,this)}},get:function(){return this.selectorText}}]),t}(A),_={onCreateRule:function(e,t,n){return"@"===e[0]||n.parent&&"keyframes"===n.parent.type?null:new I(e,t,n)}},N={indent:1,children:!0},T=/@([\w-]+)/,M=function(){function e(e,t,n){this.type="conditional",this.at=void 0,this.key=void 0,this.query=void 0,this.rules=void 0,this.options=void 0,this.isProcessed=!1,this.renderable=void 0,this.key=e;var r=e.match(T);for(var i in this.at=r?r[1]:"unknown",this.query=n.name||"@"+this.at,this.options=n,this.rules=new oe(p({},n,{parent:this})),t)this.rules.add(i,t[i]);this.rules.process()}var t=e.prototype;return t.getRule=function(e){return this.rules.get(e)},t.indexOf=function(e){return this.rules.indexOf(e)},t.addRule=function(e,t,n){var r=this.rules.add(e,t,n);return r?(this.options.jss.plugins.onProcessRule(r),r):null},t.toString=function(e){if(void 0===e&&(e=N),null==e.indent&&(e.indent=N.indent),null==e.children&&(e.children=N.children),!1===e.children)return this.query+" {}";var t=this.rules.toString(e);return t?this.query+" {\n"+t+"\n}":""},e}(),q=/@media|@supports\s+/,D={onCreateRule:function(e,t,n){return q.test(e)?new M(e,t,n):null}},L={indent:1,children:!0},U=/@keyframes\s+([\w-]+)/,$=function(){function e(e,t,n){this.type="keyframes",this.at="@keyframes",this.key=void 0,this.name=void 0,this.id=void 0,this.rules=void 0,this.options=void 0,this.isProcessed=!1,this.renderable=void 0;var r=e.match(U);r&&r[1]?this.name=r[1]:this.name="noname",this.key=this.type+"-"+this.name,this.options=n;var i=n.scoped,o=n.sheet,s=n.generateId;for(var a in this.id=!1===i?this.name:B(s(this,o)),this.rules=new oe(p({},n,{parent:this})),t)this.rules.add(a,t[a],p({},n,{parent:this}));this.rules.process()}return e.prototype.toString=function(e){if(void 0===e&&(e=L),null==e.indent&&(e.indent=L.indent),null==e.children&&(e.children=L.children),!1===e.children)return this.at+" "+this.id+" {}";var t=this.rules.toString(e);return t&&(t="\n"+t+"\n"),this.at+" "+this.id+" {"+t+"}"},e}(),G=/@keyframes\s+/,V=/\$([\w-]+)/g,W=function(e,t){return"string"==typeof e?e.replace(V,(function(e,n){return n in t?t[n]:e})):e},z=function(e,t,n){var r=e[t],i=W(r,n);i!==r&&(e[t]=i)},F={onCreateRule:function(e,t,n){return"string"==typeof e&&G.test(e)?new $(e,t,n):null},onProcessStyle:function(e,t,n){return"style"===t.type&&n?("animation-name"in e&&z(e,"animation-name",n.keyframes),"animation"in e&&z(e,"animation",n.keyframes),e):e},onChangeValue:function(e,t,n){var r=n.options.sheet;if(!r)return e;switch(t){case"animation":case"animation-name":return W(e,r.keyframes);default:return e}}},J=function(e){function t(){for(var t,n=arguments.length,r=new Array(n),i=0;i=this.index)t.push(e);else for(var r=0;rn)return void t.splice(r,0,e)},t.reset=function(){this.registry=[]},t.remove=function(e){var t=this.registry.indexOf(e);this.registry.splice(t,1)},t.toString=function(e){for(var t=void 0===e?{}:e,n=t.attached,r=d(t,["attached"]),i="",o=0;o0){var n=function(e,t){for(var n=0;nt.index&&r.options.insertionPoint===t.insertionPoint)return r}return null}(t,e);if(n&&n.renderer)return{parent:n.renderer.element.parentNode,node:n.renderer.element};if((n=function(e,t){for(var n=e.length-1;n>=0;n--){var r=e[n];if(r.attached&&r.options.insertionPoint===t.insertionPoint)return r}return null}(t,e))&&n.renderer)return{parent:n.renderer.element.parentNode,node:n.renderer.element.nextSibling}}var r=e.insertionPoint;if(r&&"string"==typeof r){var i=function(e){for(var t=ge(),n=0;nn?n:t},Pe=function(){function e(e){this.getPropertyValue=he,this.setProperty=ye,this.removeProperty=ve,this.setSelector=me,this.element=void 0,this.sheet=void 0,this.hasInsertedRules=!1,this.cssRules=[],e&&ue.add(e),this.sheet=e;var t=this.sheet?this.sheet.options:{},n=t.media,r=t.meta,i=t.element;this.element=i||function(){var e=document.createElement("style");return e.textContent="\n",e}(),this.element.setAttribute("data-jss",""),n&&this.element.setAttribute("media",n),r&&this.element.setAttribute("data-meta",r);var o=xe();o&&this.element.setAttribute("nonce",o)}var t=e.prototype;return t.attach=function(){if(!this.element.parentNode&&this.sheet){!function(e,t){var n=t.insertionPoint,r=be(t);if(!1!==r&&r.parent)r.parent.insertBefore(e,r.node);else if(n&&"number"==typeof n.nodeType){var i=n,o=i.parentNode;o&&o.insertBefore(e,i.nextSibling)}else ge().appendChild(e)}(this.element,this.sheet.options);var e=Boolean(this.sheet&&this.sheet.deployed);this.hasInsertedRules&&e&&(this.hasInsertedRules=!1,this.deploy())}},t.detach=function(){if(this.sheet){var e=this.element.parentNode;e&&e.removeChild(this.element),this.sheet.options.link&&(this.cssRules=[],this.element.textContent="\n")}},t.deploy=function(){var e=this.sheet;e&&(e.options.link?this.insertRules(e.rules):this.element.textContent="\n"+e.toString()+"\n")},t.insertRules=function(e,t){for(var n=0;n=0||(i[n]=e[n]);return i}function d(){return(d=Object.assign||function(e){for(var t=1;t<+~=|^:(),"'`\s])/g,B="undefined"!=typeof CSS&&CSS.escape,A=function(e){return B?B(e):e.replace(E,"\\$1")},I=function(){function e(e,t,n){this.type="style",this.isProcessed=!1;var r=n.sheet,i=n.Renderer;this.key=e,this.options=n,this.style=t,r?this.renderer=r.renderer:i&&(this.renderer=new i)}return e.prototype.prop=function(e,t,n){if(void 0===t)return this.style[e];var r=!!n&&n.force;if(!r&&this.style[e]===t)return this;var i=t;n&&!1===n.process||(i=this.options.jss.plugins.onChangeValue(t,e,this));var o=null==i||!1===i,s=e in this.style;if(o&&!s&&!r)return this;var a=o&&s;if(a?delete this.style[e]:this.style[e]=i,this.renderable&&this.renderer)return a?this.renderer.removeProperty(this.renderable,e):this.renderer.setProperty(this.renderable,e,i),this;var u=this.options.sheet;return u&&u.attached,this},e}(),_=function(e){function t(t,n,r){var i;i=e.call(this,t,n,r)||this;var o=r.selector,s=r.scoped,a=r.sheet,u=r.generateId;return o?i.selectorText=o:!1!==s&&(i.id=u(x(x(i)),a),i.selectorText="."+A(i.id)),i}b(t,e);var n=t.prototype;return n.applyTo=function(e){var t=this.renderer;if(t){var n=this.toJSON();for(var r in n)t.setProperty(e,r,n[r])}return this},n.toJSON=function(){var e={};for(var t in this.style){var n=this.style[t];"object"!=typeof n?e[t]=n:Array.isArray(n)&&(e[t]=O(n))}return e},n.toString=function(e){var t=this.options.sheet,n=!!t&&t.options.link?d({},e,{allowEmpty:!0}):e;return j(this.selectorText,this.style,n)},v(t,[{key:"selector",set:function(e){if(e!==this.selectorText){this.selectorText=e;var t=this.renderer,n=this.renderable;if(n&&t)t.setSelector(n,e)||t.replaceRule(n,this)}},get:function(){return this.selectorText}}]),t}(I),N={onCreateRule:function(e,t,n){return"@"===e[0]||n.parent&&"keyframes"===n.parent.type?null:new _(e,t,n)}},T={indent:1,children:!0},M=/@([\w-]+)/,q=function(){function e(e,t,n){this.type="conditional",this.isProcessed=!1,this.key=e;var r=e.match(M);for(var i in this.at=r?r[1]:"unknown",this.query=n.name||"@"+this.at,this.options=n,this.rules=new se(d({},n,{parent:this})),t)this.rules.add(i,t[i]);this.rules.process()}var t=e.prototype;return t.getRule=function(e){return this.rules.get(e)},t.indexOf=function(e){return this.rules.indexOf(e)},t.addRule=function(e,t,n){var r=this.rules.add(e,t,n);return r?(this.options.jss.plugins.onProcessRule(r),r):null},t.toString=function(e){void 0===e&&(e=T);var t=C(e).linebreak;if(null==e.indent&&(e.indent=T.indent),null==e.children&&(e.children=T.children),!1===e.children)return this.query+" {}";var n=this.rules.toString(e);return n?this.query+" {"+t+n+t+"}":""},e}(),D=/@media|@supports\s+/,L={onCreateRule:function(e,t,n){return D.test(e)?new q(e,t,n):null}},U={indent:1,children:!0},$=/@keyframes\s+([\w-]+)/,G=function(){function e(e,t,n){this.type="keyframes",this.at="@keyframes",this.isProcessed=!1;var r=e.match($);r&&r[1]?this.name=r[1]:this.name="noname",this.key=this.type+"-"+this.name,this.options=n;var i=n.scoped,o=n.sheet,s=n.generateId;for(var a in this.id=!1===i?this.name:A(s(this,o)),this.rules=new se(d({},n,{parent:this})),t)this.rules.add(a,t[a],d({},n,{parent:this}));this.rules.process()}return e.prototype.toString=function(e){void 0===e&&(e=U);var t=C(e).linebreak;if(null==e.indent&&(e.indent=U.indent),null==e.children&&(e.children=U.children),!1===e.children)return this.at+" "+this.id+" {}";var n=this.rules.toString(e);return n&&(n=""+t+n+t),this.at+" "+this.id+" {"+n+"}"},e}(),V=/@keyframes\s+/,W=/\$([\w-]+)/g,z=function(e,t){return"string"==typeof e?e.replace(W,(function(e,n){return n in t?t[n]:e})):e},F=function(e,t,n){var r=e[t],i=z(r,n);i!==r&&(e[t]=i)},J={onCreateRule:function(e,t,n){return"string"==typeof e&&V.test(e)?new G(e,t,n):null},onProcessStyle:function(e,t,n){return"style"===t.type&&n?("animation-name"in e&&F(e,"animation-name",n.keyframes),"animation"in e&&F(e,"animation",n.keyframes),e):e},onChangeValue:function(e,t,n){var r=n.options.sheet;if(!r)return e;switch(t){case"animation":case"animation-name":return z(e,r.keyframes);default:return e}}},H=function(e){function t(){return e.apply(this,arguments)||this}return b(t,e),t.prototype.toString=function(e){var t=this.options.sheet,n=!!t&&t.options.link?d({},e,{allowEmpty:!0}):e;return j(this.key,this.style,n)},t}(I),Y={onCreateRule:function(e,t,n){return n.parent&&"keyframes"===n.parent.type?new H(e,t,n):null}},Q=function(){function e(e,t,n){this.type="font-face",this.at="@font-face",this.isProcessed=!1,this.key=e,this.style=t,this.options=n}return e.prototype.toString=function(e){var t=C(e).linebreak;if(Array.isArray(this.style)){for(var n="",r=0;r=this.index)t.push(e);else for(var r=0;rn)return void t.splice(r,0,e)},t.reset=function(){this.registry=[]},t.remove=function(e){var t=this.registry.indexOf(e);this.registry.splice(t,1)},t.toString=function(e){for(var t=void 0===e?{}:e,n=t.attached,r=p(t,["attached"]),i=C(r).linebreak,o="",s=0;s0){var n=function(e,t){for(var n=0;nt.index&&r.options.insertionPoint===t.insertionPoint)return r}return null}(t,e);if(n&&n.renderer)return{parent:n.renderer.element.parentNode,node:n.renderer.element};if((n=function(e,t){for(var n=e.length-1;n>=0;n--){var r=e[n];if(r.attached&&r.options.insertionPoint===t.insertionPoint)return r}return null}(t,e))&&n.renderer)return{parent:n.renderer.element.parentNode,node:n.renderer.element.nextSibling}}var r=e.insertionPoint;if(r&&"string"==typeof r){var i=function(e){for(var t=be(),n=0;nn?n:t},ke=function(){function e(e){this.getPropertyValue=ye,this.setProperty=me,this.removeProperty=ve,this.setSelector=ge,this.hasInsertedRules=!1,this.cssRules=[],e&&le.add(e),this.sheet=e;var t=this.sheet?this.sheet.options:{},n=t.media,r=t.meta,i=t.element;this.element=i||function(){var e=document.createElement("style");return e.textContent="\n",e}(),this.element.setAttribute("data-jss",""),n&&this.element.setAttribute("media",n),r&&this.element.setAttribute("data-meta",r);var o=we();o&&this.element.setAttribute("nonce",o)}var t=e.prototype;return t.attach=function(){if(!this.element.parentNode&&this.sheet){!function(e,t){var n=t.insertionPoint,r=xe(t);if(!1!==r&&r.parent)r.parent.insertBefore(e,r.node);else if(n&&"number"==typeof n.nodeType){var i=n,o=i.parentNode;o&&o.insertBefore(e,i.nextSibling)}else be().appendChild(e)}(this.element,this.sheet.options);var e=Boolean(this.sheet&&this.sheet.deployed);this.hasInsertedRules&&e&&(this.hasInsertedRules=!1,this.deploy())}},t.detach=function(){if(this.sheet){var e=this.element.parentNode;e&&e.removeChild(this.element),this.sheet.options.link&&(this.cssRules=[],this.element.textContent="\n")}},t.deploy=function(){var e=this.sheet;e&&(e.options.link?this.insertRules(e.rules):this.element.textContent="\n"+e.toString()+"\n")},t.insertRules=function(e,t){for(var n=0;n{n[e]&&(i[e]=`${t[e]} ${n[e]}`)}),i}var Ee={set:(e,t,n,r)=>{let i=e.get(t);i||(i=new Map,e.set(t,i)),i.set(n,r)},get:(e,t,n)=>{const r=e.get(t);return r?r.get(n):void 0},delete:(e,t,n)=>{e.get(t).delete(n)}};var Be=r.createContext(null);var Ae="function"==typeof Symbol&&Symbol.for?Symbol.for("mui.nested"):"__THEME_NESTED__";const Ie=["checked","disabled","error","focused","focusVisible","required","expanded","selected"];var _e=Date.now(),Ne="fnValues"+_e,Te="fnStyle"+ ++_e,Me=function(){return{onCreateRule:function(e,t,n){if("function"!=typeof t)return null;var r=P(e,{},n);return r[Te]=t,r},onProcessStyle:function(e,t){if(Ne in t||Te in t)return e;var n={};for(var r in e){var i=e[r];"function"==typeof i&&(delete e[r],n[r]=i)}return t[Ne]=n,e},onUpdate:function(e,t,n,r){var i=t,o=i[Te];o&&(i.style=o(e)||{});var s=i[Ne];if(s)for(var a in s)i.prop(a,s[a](e),r)}}},qe="@global",De=function(){function e(e,t,n){for(var r in this.type="global",this.at=qe,this.rules=void 0,this.options=void 0,this.key=void 0,this.isProcessed=!1,this.key=e,this.options=n,this.rules=new oe(p({},n,{parent:this})),t)this.rules.add(r,t[r]);this.rules.process()}var t=e.prototype;return t.getRule=function(e){return this.rules.get(e)},t.addRule=function(e,t,n){var r=this.rules.add(e,t,n);return r&&this.options.jss.plugins.onProcessRule(r),r},t.indexOf=function(e){return this.rules.indexOf(e)},t.toString=function(){return this.rules.toString()},e}(),Le=function(){function e(e,t,n){this.type="global",this.at=qe,this.options=void 0,this.rule=void 0,this.isProcessed=!1,this.key=void 0,this.key=e,this.options=n;var r=e.substr("@global ".length);this.rule=n.jss.createRule(r,t,p({},n,{parent:this}))}return e.prototype.toString=function(e){return this.rule?this.rule.toString(e):""},e}(),Ue=/\s*,\s*/g;function $e(e,t){for(var n=e.split(Ue),r="",i=0;ie.length)&&(t=e.length);for(var n=0,r=new Array(t);n-1){var i=Vt[e];if(!Array.isArray(i))return mt+Rt(i)in t&>+i;if(!r)return!1;for(var o=0;ot?1:-1:e.length-t.length};return{onProcessStyle:function(t,n){if("style"!==n.type)return t;for(var r={},i=Object.keys(t).sort(e),o=0;o(o+=1,o);return(e,o)=>{const a=o.options.name;if(a&&0===a.indexOf("Mui")&&!o.options.link&&!t){if(-1!==Ie.indexOf(e.key))return"Mui-"+e.key;const t=`${i}${a}-${e.key}`;return o.options.theme[Ae]&&""===r?`${t}-${s()}`:t}return`${i}${n}${s()}`}}(),jss:ln,sheetsCache:null,sheetsManager:new Map,sheetsRegistry:null},fn=r.createContext(cn);let dn=-1e9;function pn(e){return null!==e&&"object"==typeof e&&e.constructor===Object}function hn(e,t,n={clone:!0}){const r=n.clone?p({},e):e;return pn(e)&&pn(t)&&Object.keys(t).forEach(i=>{"__proto__"!==i&&(pn(t[i])&&i in e&&pn(e[i])?r[i]=hn(e[i],t[i],n):r[i]=t[i])}),r}function yn(e){if("string"!=typeof e)throw new Error(function(e){let t="https://material-ui.com/production-error/?code="+e;for(let e=1;e{let i;try{i=t?e(n):e}catch(e){throw e}if(!r||!n.components||!n.components[r]||!n.components[r].styleOverrides&&!n.components[r].variants)return i;const o=n.components[r].styleOverrides||{},s=n.components[r].variants||[],a=p({},i);return Object.keys(o).forEach(e=>{a[e]=hn(a[e]||{},o[e])}),s.forEach(e=>{const t=function(e){const{variant:t}=e,n=d(e,["variant"]);let r=t||"";return Object.keys(n).sort().forEach(t=>{r+="color"===t?vn(r)?e[t]:yn(e[t]):`${vn(r)?t:yn(t)}${yn(e[t].toString())}`}),r}(e.props);a[t]=hn(a[t]||{},e.style)}),a},options:{}}}var gn={};function bn({state:e,theme:t,stylesOptions:n,stylesCreator:r,name:i},o){if(n.disableGeneration)return;let s=Ee.get(n.sheetsManager,r,t);s||(s={refs:0,staticSheet:null,dynamicStyles:null},Ee.set(n.sheetsManager,r,t,s));const a=p({},r.options,n,{theme:t,flip:"boolean"==typeof n.flip?n.flip:"rtl"===t.direction});a.generateId=a.serverGenerateClassName||a.generateClassName;const u=n.sheetsRegistry;if(0===s.refs){let e;n.sheetsCache&&(e=Ee.get(n.sheetsCache,r,t));const o=r.create(t,i);e||(e=n.jss.createStyleSheet(o,p({link:!1},a)),e.attach(),n.sheetsCache&&Ee.set(n.sheetsCache,r,t,e)),u&&u.add(e),s.staticSheet=e,s.dynamicStyles=function e(t){var n=null;for(var r in t){var i=t[r],o=typeof i;if("function"===o)n||(n={}),n[r]=i;else if("object"===o&&null!==i&&!Array.isArray(i)){var s=e(i);s&&(n||(n={}),n[r]=s)}}return n}(o)}if(s.dynamicStyles){const t=n.jss.createStyleSheet(s.dynamicStyles,p({link:!0},a));t.update(o),t.attach(),e.dynamicSheet=t,e.classes=je({baseClasses:s.staticSheet.classes,newClasses:t.classes}),u&&u.add(t)}else e.classes=s.staticSheet.classes;s.refs+=1}var xn=function(){return Object(f.useMediaQuery)((function(e){return e.breakpoints.down("md")}),{noSsr:!0})},wn=function(e){var t=e.mdUp,n=void 0!==t&&t,r=e.mdDown,i=void 0!==r&&r,o=e.children,s=xn();return n&&!s||i&&s?null:o};function Sn(){return(Sn=Object.assign||function(e){for(var t=1;t{const t=r.useContext(Be)||s,i=p({},r.useContext(fn),a),l=r.useRef(),c=r.useRef();!function(e,t){const n=r.useRef([]);let i;const o=r.useMemo(()=>({}),t);n.current!==o&&(n.current=o,i=e()),r.useEffect(()=>()=>{i&&i()},[o])}(()=>{const r={name:n,state:{},stylesCreator:u,stylesOptions:i,theme:t};return bn(r,e),c.current=!1,l.current=r,()=>{!function({state:e,theme:t,stylesOptions:n,stylesCreator:r}){if(n.disableGeneration)return;const i=Ee.get(n.sheetsManager,r,t);i.refs-=1;const o=n.sheetsRegistry;0===i.refs&&(Ee.delete(n.sheetsManager,r,t),n.jss.removeStyleSheet(i.staticSheet),o&&o.remove(i.staticSheet)),e.dynamicSheet&&(n.jss.removeStyleSheet(e.dynamicSheet),o&&o.remove(e.dynamicSheet))}(r)}},[t,u]),r.useEffect(()=>{c.current&&function({state:e},t){e.dynamicSheet&&e.dynamicSheet.update(t)}(l.current,e),c.current=!0});return function({state:e,stylesOptions:t},n,r){if(t.disableGeneration)return n||{};e.cacheClasses||(e.cacheClasses={value:null,lastProp:null,lastJSS:{}});let i=!1;return e.classes!==e.cacheClasses.lastJSS&&(e.cacheClasses.lastJSS=e.classes,i=!0),n!==e.cacheClasses.lastProp&&(e.cacheClasses.lastProp=n,i=!0),i&&(e.cacheClasses.value=je({baseClasses:e.cacheClasses.lastJSS,newClasses:n,Component:r})),e.cacheClasses.value}(l.current,e.classes,o)}}((function(e){return{root:{display:"block",width:"100%",marginLeft:"auto",marginRight:"auto"},cardContent:{paddingBottom:8,paddingRight:8},cardContentIconAppBar:{paddingLeft:16,paddingTop:16},cardContentIconAppBarMobile:{paddingLeft:16,paddingTop:24},cardContentIconNoAppBar:{paddingLeft:16,paddingTop:24},cardContentNoIconAppBar:{paddingLeft:24,paddingTop:8},cardContentNoIconNoAppBar:{paddingLeft:16,paddingTop:24},avatar:{height:40,width:40},flex:{flexGrow:1},buttons:{whiteSpace:"nowrap",alignSelf:"flex-end",paddingLeft:"90px !important"},label:{alignSelf:"center"}}}),{name:"MuiBanner"}),kn=i.a.forwardRef((function(e,t){var n=e.open,o=e.label,s=e.icon,a=e.iconProps,u=e.appBar,l=e.showDismissButton,d=e.dismissButtonLabel,p=e.dismissButtonProps,h=e.buttonOnClick,y=e.buttonLabel,v=e.buttonComponent,m=e.buttonProps,g=e.paperProps,b=e.cardProps,x=e.onClose,w=Pn(),S=xn(),P=Boolean(l||y),k=Object(r.useMemo)((function(){return i.a.createElement(i.a.Fragment,null,i.a.createElement("span",{className:w.flex}),i.a.createElement(f.Grid,{item:!0,className:w.buttons},l&&i.a.createElement(f.Button,Sn({variant:"text",onClick:x},p),d),!!y&&i.a.createElement(f.Button,Sn({variant:"text",onClick:h,component:v},m),y)))}),[l,x,p,d,h,y,v,m]),O={};return u&&(O={component:f.Container,maxWidth:"lg"}),i.a.createElement(f.Collapse,{in:n,ref:t},i.a.createElement(f.Paper,Sn({elevation:0,className:w.root},g),i.a.createElement(f.Card,Sn({elevation:0},O,b),i.a.createElement(f.CardContent,{className:c()(w.cardContent,s&&u&&!S&&w.cardContentIconAppBar,s&&u&&S&&w.cardContentIconAppBarMobile,s&&!u&&w.cardContentIconNoAppBar,!s&&u&&w.cardContentNoIconAppBar,!s&&!u&&w.cardContentNoIconNoAppBar)},i.a.createElement(f.Grid,{container:!0,wrap:"nowrap",spacing:u?3:2,direction:"row",justifyContent:"flex-start",alignItems:"flex-start"},s&&i.a.createElement(f.Grid,{item:!0},i.a.createElement(f.Avatar,Sn({className:w.avatar,sx:{bgcolor:"primary.main"}},a),s)),i.a.createElement(f.Grid,{item:!0,className:w.label},i.a.createElement(f.Typography,{variant:"body2"},o)),i.a.createElement(wn,{mdDown:!0},u&&P&&k))),!u&&P&&i.a.createElement(wn,{mdDown:!0},i.a.createElement(f.CardActions,null,k)),P&&i.a.createElement(wn,{mdUp:!0},i.a.createElement(f.CardActions,null,k)),i.a.createElement(wn,{mdDown:!0},i.a.createElement("div",null))),i.a.createElement(f.Divider,null)))}));kn.propTypes={open:u.a.bool.isRequired,label:u.a.string.isRequired,buttonLabel:u.a.string,buttonOnClick:u.a.func,buttonComponent:u.a.any,buttonProps:u.a.object,showDismissButton:u.a.bool,dismissButtonLabel:u.a.string,dismissButtonProps:u.a.object,onClose:u.a.func,icon:u.a.element,iconProps:u.a.object,appBar:u.a.bool,paperProps:u.a.object,cardProps:u.a.object},kn.defaultProps={open:!0,buttonOnClick:function(){},showDismissButton:!0,dismissButtonLabel:"Dismiss",dismissButtonProps:{},appBar:!1,buttonComponent:f.ButtonBase,buttonProps:{},iconProps:{},paperProps:{},cardProps:{}},kn.displayName="MuiBanner";var On=kn;function Cn(e){return(Cn="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Rn(){return(Rn=Object.assign||function(e){for(var t=1;t{n[e]&&(i[e]=`${t[e]} ${n[e]}`)}),i}var Be={set:(e,t,n,r)=>{let i=e.get(t);i||(i=new Map,e.set(t,i)),i.set(n,r)},get:(e,t,n)=>{const r=e.get(t);return r?r.get(n):void 0},delete:(e,t,n)=>{e.get(t).delete(n)}};var Ae=r.createContext(null);var Ie="function"==typeof Symbol&&Symbol.for?Symbol.for("mui.nested"):"__THEME_NESTED__";const _e=["checked","disabled","error","focused","focusVisible","required","expanded","selected"];var Ne=Date.now(),Te="fnValues"+Ne,Me="fnStyle"+ ++Ne,qe=function(){return{onCreateRule:function(e,t,n){if("function"!=typeof t)return null;var r=P(e,{},n);return r[Me]=t,r},onProcessStyle:function(e,t){if(Te in t||Me in t)return e;var n={};for(var r in e){var i=e[r];"function"==typeof i&&(delete e[r],n[r]=i)}return t[Te]=n,e},onUpdate:function(e,t,n,r){var i=t,o=i[Me];o&&(i.style=o(e)||{});var s=i[Te];if(s)for(var a in s)i.prop(a,s[a](e),r)}}},De="@global",Le=function(){function e(e,t,n){for(var r in this.type="global",this.at=De,this.isProcessed=!1,this.key=e,this.options=n,this.rules=new se(d({},n,{parent:this})),t)this.rules.add(r,t[r]);this.rules.process()}var t=e.prototype;return t.getRule=function(e){return this.rules.get(e)},t.addRule=function(e,t,n){var r=this.rules.add(e,t,n);return r&&this.options.jss.plugins.onProcessRule(r),r},t.indexOf=function(e){return this.rules.indexOf(e)},t.toString=function(){return this.rules.toString()},e}(),Ue=function(){function e(e,t,n){this.type="global",this.at=De,this.isProcessed=!1,this.key=e,this.options=n;var r=e.substr("@global ".length);this.rule=n.jss.createRule(r,t,d({},n,{parent:this}))}return e.prototype.toString=function(e){return this.rule?this.rule.toString(e):""},e}(),$e=/\s*,\s*/g;function Ge(e,t){for(var n=e.split($e),r="",i=0;ie.length)&&(t=e.length);for(var n=0,r=new Array(t);n-1){var i=Wt[e];if(!Array.isArray(i))return gt+jt(i)in t&&bt+i;if(!r)return!1;for(var o=0;ot?1:-1:e.length-t.length};return{onProcessStyle:function(t,n){if("style"!==n.type)return t;for(var r={},i=Object.keys(t).sort(e),o=0;o(o+=1,o);return(e,o)=>{const a=o.options.name;if(a&&0===a.indexOf("Mui")&&!o.options.link&&!t){if(-1!==_e.indexOf(e.key))return"Mui-"+e.key;const t=`${i}${a}-${e.key}`;return o.options.theme[Ie]&&""===r?`${t}-${s()}`:t}return`${i}${n}${s()}`}}(),jss:cn,sheetsCache:null,sheetsManager:new Map,sheetsRegistry:null},pn=r.createContext(fn);let dn=-1e9;function hn(e){return null!==e&&"object"==typeof e&&e.constructor===Object}function yn(e,t,n={clone:!0}){const r=n.clone?d({},e):e;return hn(e)&&hn(t)&&Object.keys(t).forEach(i=>{"__proto__"!==i&&(hn(t[i])&&i in e&&hn(e[i])?r[i]=yn(e[i],t[i],n):r[i]=t[i])}),r}function mn(e){if("string"!=typeof e)throw new Error(function(e){let t="https://mui.com/production-error/?code="+e;for(let e=1;e{let i;try{i=t?e(n):e}catch(e){throw e}if(!r||!n.components||!n.components[r]||!n.components[r].styleOverrides&&!n.components[r].variants)return i;const o=n.components[r].styleOverrides||{},s=n.components[r].variants||[],a=d({},i);return Object.keys(o).forEach(e=>{a[e]=yn(a[e]||{},o[e])}),s.forEach(e=>{const t=function(e){const{variant:t}=e,n=p(e,vn);let r=t||"";return Object.keys(n).sort().forEach(t=>{r+="color"===t?gn(r)?e[t]:mn(e[t]):`${gn(r)?t:mn(t)}${mn(e[t].toString())}`}),r}(e.props);a[t]=yn(a[t]||{},e.style)}),a},options:{}}}var xn={};const wn=["name","classNamePrefix","Component","defaultTheme"];function Sn({state:e,theme:t,stylesOptions:n,stylesCreator:r,name:i},o){if(n.disableGeneration)return;let s=Be.get(n.sheetsManager,r,t);s||(s={refs:0,staticSheet:null,dynamicStyles:null},Be.set(n.sheetsManager,r,t,s));const a=d({},r.options,n,{theme:t,flip:"boolean"==typeof n.flip?n.flip:"rtl"===t.direction});a.generateId=a.serverGenerateClassName||a.generateClassName;const u=n.sheetsRegistry;if(0===s.refs){let e;n.sheetsCache&&(e=Be.get(n.sheetsCache,r,t));const o=r.create(t,i);e||(e=n.jss.createStyleSheet(o,d({link:!1},a)),e.attach(),n.sheetsCache&&Be.set(n.sheetsCache,r,t,e)),u&&u.add(e),s.staticSheet=e,s.dynamicStyles=function e(t){var n=null;for(var r in t){var i=t[r],o=typeof i;if("function"===o)n||(n={}),n[r]=i;else if("object"===o&&null!==i&&!Array.isArray(i)){var s=e(i);s&&(n||(n={}),n[r]=s)}}return n}(o)}if(s.dynamicStyles){const t=n.jss.createStyleSheet(s.dynamicStyles,d({link:!0},a));t.update(o),t.attach(),e.dynamicSheet=t,e.classes=Ee({baseClasses:s.staticSheet.classes,newClasses:t.classes}),u&&u.add(t)}else e.classes=s.staticSheet.classes;s.refs+=1}var Pn=function(){return Object(f.useMediaQuery)((function(e){return e.breakpoints.down("md")}),{noSsr:!0})},kn=function(e){var t=e.mdUp,n=void 0!==t&&t,r=e.mdDown,i=void 0!==r&&r,o=e.children,s=Pn();return n&&!s||i&&s?null:o};function On(){return(On=Object.assign||function(e){for(var t=1;t{const t=r.useContext(Ae)||s,i=d({},r.useContext(pn),a),l=r.useRef(),c=r.useRef();!function(e,t){const n=r.useRef([]);let i;const o=r.useMemo(()=>({}),t);n.current!==o&&(n.current=o,i=e()),r.useEffect(()=>()=>{i&&i()},[o])}(()=>{const r={name:n,state:{},stylesCreator:u,stylesOptions:i,theme:t};return Sn(r,e),c.current=!1,l.current=r,()=>{!function({state:e,theme:t,stylesOptions:n,stylesCreator:r}){if(n.disableGeneration)return;const i=Be.get(n.sheetsManager,r,t);i.refs-=1;const o=n.sheetsRegistry;0===i.refs&&(Be.delete(n.sheetsManager,r,t),n.jss.removeStyleSheet(i.staticSheet),o&&o.remove(i.staticSheet)),e.dynamicSheet&&(n.jss.removeStyleSheet(e.dynamicSheet),o&&o.remove(e.dynamicSheet))}(r)}},[t,u]),r.useEffect(()=>{c.current&&function({state:e},t){e.dynamicSheet&&e.dynamicSheet.update(t)}(l.current,e),c.current=!0});return function({state:e,stylesOptions:t},n,r){if(t.disableGeneration)return n||{};e.cacheClasses||(e.cacheClasses={value:null,lastProp:null,lastJSS:{}});let i=!1;return e.classes!==e.cacheClasses.lastJSS&&(e.cacheClasses.lastJSS=e.classes,i=!0),n!==e.cacheClasses.lastProp&&(e.cacheClasses.lastProp=n,i=!0),i&&(e.cacheClasses.value=Ee({baseClasses:e.cacheClasses.lastJSS,newClasses:n,Component:r})),e.cacheClasses.value}(l.current,e.classes,o)}}((function(e){return{root:{display:"block",width:"100%",marginLeft:"auto",marginRight:"auto"},cardContent:{paddingBottom:8,paddingRight:8},cardContentIconAppBar:{paddingLeft:16,paddingTop:16},cardContentIconAppBarMobile:{paddingLeft:16,paddingTop:24},cardContentIconNoAppBar:{paddingLeft:16,paddingTop:24},cardContentNoIconAppBar:{paddingLeft:24,paddingTop:8},cardContentNoIconNoAppBar:{paddingLeft:16,paddingTop:24},avatar:{height:40,width:40},flex:{flexGrow:1},buttons:{whiteSpace:"nowrap",alignSelf:"flex-end",paddingLeft:"90px !important"},label:{alignSelf:"center"}}}),{name:"MuiBanner"}),Rn=i.a.forwardRef((function(e,t){var n=e.open,o=e.label,s=e.icon,a=e.iconProps,u=e.appBar,l=e.showDismissButton,p=e.dismissButtonLabel,d=e.dismissButtonProps,h=e.buttonOnClick,y=e.buttonLabel,m=e.buttonComponent,v=e.buttonProps,g=e.paperProps,b=e.cardProps,x=e.onClose,w=Cn(),S=Pn(),P=Boolean(l||y),k=Object(r.useMemo)((function(){return i.a.createElement(i.a.Fragment,null,i.a.createElement("span",{className:w.flex}),i.a.createElement(f.Grid,{item:!0,className:w.buttons},l&&i.a.createElement(f.Button,On({variant:"text",onClick:x},d),p),!!y&&i.a.createElement(f.Button,On({variant:"text",onClick:h,component:m},v),y)))}),[l,x,d,p,h,y,m,v]),O={};return u&&(O={component:f.Container,maxWidth:"lg"}),i.a.createElement(f.Collapse,{in:n,ref:t},i.a.createElement(f.Paper,On({elevation:0,className:w.root},g),i.a.createElement(f.Card,On({elevation:0},O,b),i.a.createElement(f.CardContent,{className:c()(w.cardContent,s&&u&&!S&&w.cardContentIconAppBar,s&&u&&S&&w.cardContentIconAppBarMobile,s&&!u&&w.cardContentIconNoAppBar,!s&&u&&w.cardContentNoIconAppBar,!s&&!u&&w.cardContentNoIconNoAppBar)},i.a.createElement(f.Grid,{container:!0,wrap:"nowrap",spacing:u?3:2,direction:"row",justifyContent:"flex-start",alignItems:"flex-start"},s&&i.a.createElement(f.Grid,{item:!0},i.a.createElement(f.Avatar,On({className:w.avatar,sx:{bgcolor:"primary.main"}},a),s)),i.a.createElement(f.Grid,{item:!0,className:w.label},i.a.createElement(f.Typography,{variant:"body2"},o)),i.a.createElement(kn,{mdDown:!0},u&&P&&k))),!u&&P&&i.a.createElement(kn,{mdDown:!0},i.a.createElement(f.CardActions,null,k)),P&&i.a.createElement(kn,{mdUp:!0},i.a.createElement(f.CardActions,null,k)),i.a.createElement(kn,{mdDown:!0},i.a.createElement("div",null))),i.a.createElement(f.Divider,null)))}));Rn.propTypes={open:u.a.bool.isRequired,label:u.a.string.isRequired,buttonLabel:u.a.string,buttonOnClick:u.a.func,buttonComponent:u.a.any,buttonProps:u.a.object,showDismissButton:u.a.bool,dismissButtonLabel:u.a.string,dismissButtonProps:u.a.object,onClose:u.a.func,icon:u.a.element,iconProps:u.a.object,appBar:u.a.bool,paperProps:u.a.object,cardProps:u.a.object},Rn.defaultProps={open:!0,buttonOnClick:function(){},showDismissButton:!0,dismissButtonLabel:"Dismiss",dismissButtonProps:{},appBar:!1,buttonComponent:f.ButtonBase,buttonProps:{},iconProps:{},paperProps:{},cardProps:{}},Rn.displayName="MuiBanner";var jn=Rn;function En(e){return(En="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function Bn(){return(Bn=Object.assign||function(e){for(var t=1;t ({ diff --git a/src/components/Hide.jsx b/src/components/Hide.jsx index 00c7560..7d2b156 100644 --- a/src/components/Hide.jsx +++ b/src/components/Hide.jsx @@ -1,4 +1,4 @@ -import { useMediaQuery } from '@material-ui/core'; +import { useMediaQuery } from '@mui/material'; /** * Checks whether or not the current device is a mobile device, based on device width diff --git a/src/components/StaticBanner.jsx b/src/components/StaticBanner.jsx index 19e8844..b463b2c 100644 --- a/src/components/StaticBanner.jsx +++ b/src/components/StaticBanner.jsx @@ -1,5 +1,5 @@ import React from 'react'; -import ButtonBase from '@material-ui/core/ButtonBase'; +import ButtonBase from '@mui/material/ButtonBase'; import Banner from './Banner'; export default class StaticBanner extends React.Component { diff --git a/src/demo/components/App.jsx b/src/demo/components/App.jsx index 6bce100..7bd8ee9 100644 --- a/src/demo/components/App.jsx +++ b/src/demo/components/App.jsx @@ -2,8 +2,8 @@ import React, { useCallback } from 'react'; import { AppBar, Toolbar, Typography, Button, Grid, Card, -} from '@material-ui/core'; -import makeStyles from '@material-ui/styles/makeStyles'; +} from '@mui/material'; +import makeStyles from '@mui/styles/makeStyles'; import { Banner, StaticBanner } from '../../index'; const useStyles = makeStyles((theme) => ({ diff --git a/src/demo/index.js b/src/demo/index.js index 4baad36..ed63a92 100644 --- a/src/demo/index.js +++ b/src/demo/index.js @@ -1,7 +1,7 @@ import React from 'react'; import { render } from 'react-dom'; -import createTheme from '@material-ui/core/styles/createTheme'; -import ThemeProvider from '@material-ui/core/styles/ThemeProvider'; +import createTheme from '@mui/material/styles/createTheme'; +import ThemeProvider from '@mui/material/styles/ThemeProvider'; import App from './components/App'; const theme = createTheme(); diff --git a/webpack.config.build.js b/webpack.config.build.js index b2481f1..fc3a4fa 100644 --- a/webpack.config.build.js +++ b/webpack.config.build.js @@ -25,8 +25,8 @@ module.exports = merge(common, { amd: 'react-dom', }, }, - "@material-ui/core", - /@material-ui\/core\/*./, + "@mui/material", + /@mui\/material\/*./, 'clsx', ], plugins: [