@daoyi/nmtl-ui 1.1.34 → 1.1.38
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +45 -45
- package/lib/components/ContactModal.js +3 -3
- package/lib/components/Drawer.js +1 -1
- package/lib/components/ExportButton.js +1 -1
- package/lib/components/Footer.js +1 -1
- package/lib/components/Header.js +1 -1
- package/lib/components/{KeywordSearch-561d0099.js → KeywordSearch-1a4e22fd.js} +1 -1
- package/lib/components/KeywordSearch.js +1 -1
- package/lib/components/Keywords.js +1 -1
- package/lib/components/MUITheme.js +1 -1
- package/lib/components/{createSvgIcon-b31f2034.js → createSvgIcon-8a1a5d79.js} +1 -1
- package/package.json +114 -114
|
@@ -1 +1 @@
|
|
|
1
|
-
import*as e from"react";import t,{useMemo as n}from"react";import{s as o,c as r}from"./style-inject.es-22541f49.js";import i from"prop-types";import{Button as a,CircularProgress as l,Fade as c,Dialog as s,DialogTitle as u,IconButton as d,DialogContent as f,DialogActions as m}from"@material-ui/core";import{CloseSharp as p}from"@material-ui/icons";import{c as y,u as v}from"./_commonjsHelpers-ae1b5db5.js";import{f as b,w as h,e as x,c as g}from"./withStyles-12e04256.js";import*as _ from"react-dom";o(".button {\n border: 1px solid #ffffff99;\n border-radius: 45px;\n padding: 8px 16px;\n background: #007bff;\n color: white;\n cursor: pointer; }\n .button:hover {\n opacity: 0.9; }\n");const w=e=>{const{style:n,className:o,tabIndex:i,alt:c,text:s,size:u,variant:d}=e,{type:f,color:m,loading:p,disabled:y,icon:v,endIcon:b,children:h,onClick:x}=e;return t.createElement(a,{style:n,className:r("button",o),tabIndex:i,alt:c,size:u,variant:d,color:f||m,disabled:p||y,onClick:x,startIcon:v,endIcon:p?t.createElement(l,{size:16}):b},s,h)};w.defaultProps={style:void 0,className:void 0,tabIndex:void 0,alt:void 0,text:void 0,loading:!1,disabled:!1,variant:void 0,size:"small",color:"primary",type:void 0,children:void 0,icon:void 0,endIcon:void 0,onClick:()=>{}},w.propTypes={style:i.objectOf(i.any),className:i.string,tabIndex:i.number,alt:i.string,text:i.string,loading:i.bool,disabled:i.bool,variant:i.oneOf(["contained","outlined","text"]),size:i.oneOf(["small","medium","large"]),color:i.oneOf(["default","inherit","primary","secondary"]),type:i.oneOf(["default","inherit","primary","secondary"]),children:i.node,icon:i.node,endIcon:i.node,onClick:i.func};o(".customSpin {\n width: 100%;\n min-height: 100px;\n position: relative; }\n .customSpin__spin {\n width: 100%;\n height: 100%;\n position: absolute;\n z-index: 2;\n display: flex;\n justify-content: center;\n align-items: center; }\n");const E=e=>{const{className:o,spinning:i,children:a,size:s,style:u}=e,d={small:16,middle:24,large:40},f=e=>{const t=e<16?16:e;return t>300?300:t},m=n((()=>"string"==typeof s?Number(s)&&"number"==typeof Number(s)?f(Number(s)):d[s]||40:"number"==typeof s?f(s):40),[s]);return t.createElement("div",{className:r("customSpin",o),style:u||{}},t.createElement(c,{in:i,style:{transitionDelay:"300ms"},unmountOnExit:!0},t.createElement("div",{className:"customSpin__spin"},t.createElement(l,{size:m}))),a)};E.defaultProps={className:void 0,spinning:!1,children:null,size:void 0,style:void 0},E.propTypes={className:i.string,spinning:i.bool,children:i.node,size:i.oneOfType([i.string,i.number]),style:i.objectOf(i.any)};o(".modal__title h2 {\n display: flex;\n align-items: center; }\n\n.modal__title__text {\n flex: 1;\n font-size: 16px;\n padding: 8px 0;\n color: white; }\n\n.modal__title__close {\n cursor: pointer;\n color: white; }\n\n.modal--transparent .MuiPaper-root {\n background: transparent !important;\n box-shadow: none; }\n\n.modal--transparent .modal__title {\n background: transparent !important; }\n");const S=e=>{const{className:n,title:o,children:i,footer:a,cancelText:c,okText:y,visible:v,onOk:b,onCancel:h}=e,{closable:x,loading:g,fullWidth:_,transparent:S}=e,k=g&&t.createElement(l,{size:14});return t.createElement(s,{className:r("modal",{"modal--transparent":S},n),fullWidth:_,open:v||!1,onClose:()=>x&&h()},t.createElement(u,{className:"modal__title"},t.createElement("span",{className:"modal__title__text"},o),x&&t.createElement(d,{onClick:h},t.createElement(p,{className:"modal__title__close"}))),t.createElement(f,null,t.createElement(E,{spinning:g},i)),null!==a&&t.createElement(m,null,void 0===a&&(c||y)?t.createElement(t.Fragment,null,c&&t.createElement(w,{onClick:h,color:"default",endIcon:k,disabled:g},c),y&&t.createElement(w,{onClick:b,color:"primary",endIcon:k,disabled:g,autoFocus:!0},y)):a))};function k(e){var t,n,o="";if("string"==typeof e||"number"==typeof e)o+=e;else if("object"==typeof e)if(Array.isArray(e))for(t=0;t<e.length;t++)e[t]&&(n=k(e[t]))&&(o&&(o+=" "),o+=n);else for(t in e)e[t]&&(o&&(o+=" "),o+=t);return o}function N(){for(var e,t,n=0,o="";n<arguments.length;)(e=arguments[n++])&&(t=k(e))&&(o&&(o+=" "),o+=t);return o}function O(e){if("string"!=typeof e)throw new Error(b(7));return e.charAt(0).toUpperCase()+e.slice(1)}S.defaultProps={className:void 0,loading:void 0,transparent:void 0,closable:!0,title:void 0,children:void 0,fullWidth:void 0,footer:void 0,cancelText:"Cancel",okText:"Ok",visible:void 0,onOk:()=>{},onCancel:()=>{}},S.propTypes={className:i.string,loading:i.bool,transparent:i.bool,closable:i.bool,title:i.node,children:i.node,fullWidth:i.bool,footer:i.node,cancelText:i.string,okText:i.string,visible:i.bool,onOk:i.func,onCancel:i.func};var z=y((function(e){e.exports=function(e){return e&&e.__esModule?e:{default:e}},e.exports.default=e.exports,e.exports.__esModule=!0}));v(z);var C=y((function(e){function t(n){return"function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?(e.exports=t=function(e){return typeof e},e.exports.default=e.exports,e.exports.__esModule=!0):(e.exports=t=function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},e.exports.default=e.exports,e.exports.__esModule=!0),t(n)}e.exports=t,e.exports.default=e.exports,e.exports.__esModule=!0}));v(C);var T=y((function(e){var t=C.default;function n(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,o=new WeakMap;return(n=function(e){return e?o:t})(e)}e.exports=function(e,o){if(!o&&e&&e.__esModule)return e;if(null===e||"object"!==t(e)&&"function"!=typeof e)return{default:e};var r=n(o);if(r&&r.has(e))return r.get(e);var i={},a=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var l in e)if("default"!==l&&Object.prototype.hasOwnProperty.call(e,l)){var c=a?Object.getOwnPropertyDescriptor(e,l):null;c&&(c.get||c.set)?Object.defineProperty(i,l,c):i[l]=e[l]}return i.default=e,r&&r.set(e,i),i},e.exports.default=e.exports,e.exports.__esModule=!0}));v(T);var I=e.forwardRef((function(t,n){var o=t.children,r=t.classes,i=t.className,a=t.color,l=void 0===a?"inherit":a,c=t.component,s=void 0===c?"svg":c,u=t.fontSize,d=void 0===u?"medium":u,f=t.htmlColor,m=t.titleAccess,p=t.viewBox,y=void 0===p?"0 0 24 24":p,v=x(t,["children","classes","className","color","component","fontSize","htmlColor","titleAccess","viewBox"]);return e.createElement(s,g({className:N(r.root,i,"inherit"!==l&&r["color".concat(O(l))],"default"!==d&&"medium"!==d&&r["fontSize".concat(O(d))]),focusable:"false",viewBox:y,color:f,"aria-hidden":!m||void 0,role:m?"img":void 0,ref:n},v),o,m?e.createElement("title",null,m):null)}));I.muiName="SvgIcon";var M=h((function(e){return{root:{userSelect:"none",width:"1em",height:"1em",display:"inline-block",fill:"currentColor",flexShrink:0,fontSize:e.typography.pxToRem(24),transition:e.transitions.create("fill",{duration:e.transitions.duration.shorter})},colorPrimary:{color:e.palette.primary.main},colorSecondary:{color:e.palette.secondary.main},colorAction:{color:e.palette.action.active},colorError:{color:e.palette.error.main},colorDisabled:{color:e.palette.action.disabled},fontSizeInherit:{fontSize:"inherit"},fontSizeSmall:{fontSize:e.typography.pxToRem(20)},fontSizeLarge:{fontSize:e.typography.pxToRem(35)}}}),{name:"MuiSvgIcon"})(I);function j(e){return e&&e.ownerDocument||document}function P(e,t){"function"==typeof e?e(t):e&&(e.current=t)}var A="undefined"!=typeof window?e.useLayoutEffect:e.useEffect;var R=!0,D=!1,W=null,F={text:!0,search:!0,url:!0,tel:!0,email:!0,password:!0,number:!0,date:!0,month:!0,week:!0,time:!0,datetime:!0,"datetime-local":!0};function L(e){e.metaKey||e.altKey||e.ctrlKey||(R=!0)}function B(){R=!1}function V(){"hidden"===this.visibilityState&&D&&(R=!0)}function K(e){var t,n,o,r=e.target;try{return r.matches(":focus-visible")}catch(e){}return R||(n=(t=r).type,!("INPUT"!==(o=t.tagName)||!F[n]||t.readOnly)||"TEXTAREA"===o&&!t.readOnly||!!t.isContentEditable)}function U(){D=!0,window.clearTimeout(W),W=window.setTimeout((function(){D=!1}),100)}var q=Object.freeze({__proto__:null,capitalize:O,createChainedFunction:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return t.reduce((function(e,t){return null==t?e:function(){for(var n=arguments.length,o=new Array(n),r=0;r<n;r++)o[r]=arguments[r];e.apply(this,o),t.apply(this,o)}}),(function(){}))},createSvgIcon:function(e,n){var o=function(n,o){return t.createElement(M,g({ref:o},n),e)};return o.muiName=M.muiName,t.memo(t.forwardRef(o))},debounce:function(e){var t,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:166;function o(){for(var o=arguments.length,r=new Array(o),i=0;i<o;i++)r[i]=arguments[i];var a=this,l=function(){e.apply(a,r)};clearTimeout(t),t=setTimeout(l,n)}return o.clear=function(){clearTimeout(t)},o},deprecatedPropType:function(e,t){return function(){return null}},isMuiElement:function(t,n){return e.isValidElement(t)&&-1!==n.indexOf(t.type.muiName)},ownerDocument:j,ownerWindow:function(e){return j(e).defaultView||window},requirePropFactory:function(e){return function(){return null}},setRef:P,unsupportedProp:function(e,t,n,o,r){return null},useControlled:function(t){var n=t.controlled,o=t.default;t.name,t.state;var r=e.useRef(void 0!==n).current,i=e.useState(o),a=i[0],l=i[1];return[r?n:a,e.useCallback((function(e){r||l(e)}),[])]},useEventCallback:function(t){var n=e.useRef(t);return A((function(){n.current=t})),e.useCallback((function(){return n.current.apply(void 0,arguments)}),[])},useForkRef:function(t,n){return e.useMemo((function(){return null==t&&null==n?null:function(e){P(t,e),P(n,e)}}),[t,n])},unstable_useId:function(t){var n=e.useState(t),o=n[0],r=n[1],i=t||o;return e.useEffect((function(){null==o&&r("mui-".concat(Math.round(1e5*Math.random())))}),[o]),i},useIsFocusVisible:function(){return{isFocusVisible:K,onBlurVisible:U,ref:e.useCallback((function(e){var t,n=_.findDOMNode(e);null!=n&&((t=n.ownerDocument).addEventListener("keydown",L,!0),t.addEventListener("mousedown",B,!0),t.addEventListener("pointerdown",B,!0),t.addEventListener("touchstart",B,!0),t.addEventListener("visibilitychange",V,!0))}),[])}}}),H=y((function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"default",{enumerable:!0,get:function(){return q.createSvgIcon}})}));v(H);var X=H;export{S as M,E as S,O as a,z as b,N as c,T as i,X as r};
|
|
1
|
+
import*as e from"react";import t,{useMemo as n}from"react";import{s as o,c as r}from"./style-inject.es-22541f49.js";import i from"prop-types";import{Button as a,CircularProgress as l,Fade as c,Dialog as s,DialogTitle as u,IconButton as d,DialogContent as f,DialogActions as m}from"@material-ui/core";import{CloseSharp as p}from"@material-ui/icons";import{c as y,u as v}from"./_commonjsHelpers-ae1b5db5.js";import{f as b,w as h,e as x,c as g}from"./withStyles-12e04256.js";import*as _ from"react-dom";o(".button {\n border: 1px solid #ffffff99;\n border-radius: 45px;\n padding: 8px 16px;\n background: #007bff;\n color: white;\n cursor: pointer; }\n .button:hover {\n opacity: 0.9; }\n");const w=e=>{const{style:n,className:o,tabIndex:i,alt:c,text:s,size:u,variant:d}=e,{type:f,color:m,loading:p,disabled:y,icon:v,endIcon:b,children:h,onClick:x}=e;return t.createElement(a,{style:n,className:r("button",o),tabIndex:i,alt:c,size:u,variant:d,color:f||m,disabled:p||y,onClick:x,startIcon:v,endIcon:p?t.createElement(l,{size:16}):b},s,h)};w.defaultProps={style:void 0,className:void 0,tabIndex:void 0,alt:void 0,text:void 0,loading:!1,disabled:!1,variant:void 0,size:"small",color:"primary",type:void 0,children:void 0,icon:void 0,endIcon:void 0,onClick:()=>{}},w.propTypes={style:i.objectOf(i.any),className:i.string,tabIndex:i.number,alt:i.string,text:i.string,loading:i.bool,disabled:i.bool,variant:i.oneOf(["contained","outlined","text"]),size:i.oneOf(["small","medium","large"]),color:i.oneOf(["default","inherit","primary","secondary"]),type:i.oneOf(["default","inherit","primary","secondary"]),children:i.node,icon:i.node,endIcon:i.node,onClick:i.func};o(".customSpin {\n width: 100%;\n min-height: 100px;\n position: relative; }\n .customSpin__spin {\n width: 100%;\n height: 100%;\n position: absolute;\n z-index: 2;\n display: flex;\n justify-content: center;\n align-items: center; }\n");const E=e=>{const{className:o,spinning:i,children:a,size:s,style:u}=e,d={small:16,middle:24,large:40},f=e=>{const t=e<16?16:e;return t>300?300:t},m=n((()=>"string"==typeof s?Number(s)&&"number"==typeof Number(s)?f(Number(s)):d[s]||40:"number"==typeof s?f(s):40),[s]);return t.createElement("div",{className:r("customSpin",o),style:u||{}},t.createElement(c,{in:i,style:{transitionDelay:"300ms"},unmountOnExit:!0},t.createElement("div",{className:"customSpin__spin"},t.createElement(l,{size:m}))),a)};E.defaultProps={className:void 0,spinning:!1,children:null,size:void 0,style:void 0},E.propTypes={className:i.string,spinning:i.bool,children:i.node,size:i.oneOfType([i.string,i.number]),style:i.objectOf(i.any)};o(".modal__title h2 {\n display: flex;\n align-items: center; }\n\n.modal__title__text {\n flex: 1;\n font-size: 16px;\n padding: 8px 0;\n color: white; }\n\n.modal__title__close {\n cursor: pointer;\n color: white; }\n\n.modal--transparent .MuiPaper-root {\n background: transparent !important;\n box-shadow: none; }\n\n.modal--transparent .modal__title {\n background: transparent !important; }\n");const S=e=>{const{className:n,title:o,children:i,footer:a,cancelText:c,okText:y,visible:v,onOk:b,onCancel:h}=e,{closable:x,loading:g,fullWidth:_,transparent:S}=e,k=g&&t.createElement(l,{size:14});return t.createElement(s,{className:r("modal",{"modal--transparent":S},n),fullWidth:_,open:v||!1,onClose:()=>x&&h()},t.createElement(u,{className:"modal__title"},t.createElement("span",{className:"modal__title__text"},o),x&&t.createElement(d,{onClick:h},t.createElement(p,{className:"modal__title__close"}))),t.createElement(f,null,t.createElement(E,{spinning:g},i)),null!==a&&t.createElement(m,null,void 0===a&&(c||y)?t.createElement(t.Fragment,null,c&&t.createElement(w,{onClick:h,color:"default",endIcon:k,disabled:g},c),y&&t.createElement(w,{onClick:b,color:"primary",endIcon:k,disabled:g,autoFocus:!0},y)):a))};S.defaultProps={className:void 0,loading:void 0,transparent:void 0,closable:!0,title:void 0,children:void 0,fullWidth:void 0,footer:void 0,cancelText:"Cancel",okText:"Ok",visible:void 0,onOk:()=>{},onCancel:()=>{}},S.propTypes={className:i.string,loading:i.bool,transparent:i.bool,closable:i.bool,title:i.node,children:i.node,fullWidth:i.bool,footer:i.node,cancelText:i.string,okText:i.string,visible:i.bool,onOk:i.func,onCancel:i.func};var k=y((function(e){e.exports=function(e){return e&&e.__esModule?e:{default:e}},e.exports.default=e.exports,e.exports.__esModule=!0}));v(k);var N=y((function(e){function t(n){return"function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?(e.exports=t=function(e){return typeof e},e.exports.default=e.exports,e.exports.__esModule=!0):(e.exports=t=function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},e.exports.default=e.exports,e.exports.__esModule=!0),t(n)}e.exports=t,e.exports.default=e.exports,e.exports.__esModule=!0}));v(N);var O=y((function(e){var t=N.default;function n(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,o=new WeakMap;return(n=function(e){return e?o:t})(e)}e.exports=function(e,o){if(!o&&e&&e.__esModule)return e;if(null===e||"object"!==t(e)&&"function"!=typeof e)return{default:e};var r=n(o);if(r&&r.has(e))return r.get(e);var i={},a=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var l in e)if("default"!==l&&Object.prototype.hasOwnProperty.call(e,l)){var c=a?Object.getOwnPropertyDescriptor(e,l):null;c&&(c.get||c.set)?Object.defineProperty(i,l,c):i[l]=e[l]}return i.default=e,r&&r.set(e,i),i},e.exports.default=e.exports,e.exports.__esModule=!0}));function z(e){if("string"!=typeof e)throw new Error(b(7));return e.charAt(0).toUpperCase()+e.slice(1)}function C(e){var t,n,o="";if("string"==typeof e||"number"==typeof e)o+=e;else if("object"==typeof e)if(Array.isArray(e))for(t=0;t<e.length;t++)e[t]&&(n=C(e[t]))&&(o&&(o+=" "),o+=n);else for(t in e)e[t]&&(o&&(o+=" "),o+=t);return o}function T(){for(var e,t,n=0,o="";n<arguments.length;)(e=arguments[n++])&&(t=C(e))&&(o&&(o+=" "),o+=t);return o}v(O);var I=e.forwardRef((function(t,n){var o=t.children,r=t.classes,i=t.className,a=t.color,l=void 0===a?"inherit":a,c=t.component,s=void 0===c?"svg":c,u=t.fontSize,d=void 0===u?"medium":u,f=t.htmlColor,m=t.titleAccess,p=t.viewBox,y=void 0===p?"0 0 24 24":p,v=x(t,["children","classes","className","color","component","fontSize","htmlColor","titleAccess","viewBox"]);return e.createElement(s,g({className:T(r.root,i,"inherit"!==l&&r["color".concat(z(l))],"default"!==d&&"medium"!==d&&r["fontSize".concat(z(d))]),focusable:"false",viewBox:y,color:f,"aria-hidden":!m||void 0,role:m?"img":void 0,ref:n},v),o,m?e.createElement("title",null,m):null)}));I.muiName="SvgIcon";var M=h((function(e){return{root:{userSelect:"none",width:"1em",height:"1em",display:"inline-block",fill:"currentColor",flexShrink:0,fontSize:e.typography.pxToRem(24),transition:e.transitions.create("fill",{duration:e.transitions.duration.shorter})},colorPrimary:{color:e.palette.primary.main},colorSecondary:{color:e.palette.secondary.main},colorAction:{color:e.palette.action.active},colorError:{color:e.palette.error.main},colorDisabled:{color:e.palette.action.disabled},fontSizeInherit:{fontSize:"inherit"},fontSizeSmall:{fontSize:e.typography.pxToRem(20)},fontSizeLarge:{fontSize:e.typography.pxToRem(35)}}}),{name:"MuiSvgIcon"})(I);function j(e){return e&&e.ownerDocument||document}function P(e,t){"function"==typeof e?e(t):e&&(e.current=t)}var A="undefined"!=typeof window?e.useLayoutEffect:e.useEffect;var R=!0,D=!1,W=null,F={text:!0,search:!0,url:!0,tel:!0,email:!0,password:!0,number:!0,date:!0,month:!0,week:!0,time:!0,datetime:!0,"datetime-local":!0};function L(e){e.metaKey||e.altKey||e.ctrlKey||(R=!0)}function B(){R=!1}function V(){"hidden"===this.visibilityState&&D&&(R=!0)}function K(e){var t,n,o,r=e.target;try{return r.matches(":focus-visible")}catch(e){}return R||(n=(t=r).type,!("INPUT"!==(o=t.tagName)||!F[n]||t.readOnly)||"TEXTAREA"===o&&!t.readOnly||!!t.isContentEditable)}function U(){D=!0,window.clearTimeout(W),W=window.setTimeout((function(){D=!1}),100)}var q=Object.freeze({__proto__:null,capitalize:z,createChainedFunction:function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return t.reduce((function(e,t){return null==t?e:function(){for(var n=arguments.length,o=new Array(n),r=0;r<n;r++)o[r]=arguments[r];e.apply(this,o),t.apply(this,o)}}),(function(){}))},createSvgIcon:function(e,n){var o=function(n,o){return t.createElement(M,g({ref:o},n),e)};return o.muiName=M.muiName,t.memo(t.forwardRef(o))},debounce:function(e){var t,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:166;function o(){for(var o=arguments.length,r=new Array(o),i=0;i<o;i++)r[i]=arguments[i];var a=this,l=function(){e.apply(a,r)};clearTimeout(t),t=setTimeout(l,n)}return o.clear=function(){clearTimeout(t)},o},deprecatedPropType:function(e,t){return function(){return null}},isMuiElement:function(t,n){return e.isValidElement(t)&&-1!==n.indexOf(t.type.muiName)},ownerDocument:j,ownerWindow:function(e){return j(e).defaultView||window},requirePropFactory:function(e){return function(){return null}},setRef:P,unsupportedProp:function(e,t,n,o,r){return null},useControlled:function(t){var n=t.controlled,o=t.default;t.name,t.state;var r=e.useRef(void 0!==n).current,i=e.useState(o),a=i[0],l=i[1];return[r?n:a,e.useCallback((function(e){r||l(e)}),[])]},useEventCallback:function(t){var n=e.useRef(t);return A((function(){n.current=t})),e.useCallback((function(){return n.current.apply(void 0,arguments)}),[])},useForkRef:function(t,n){return e.useMemo((function(){return null==t&&null==n?null:function(e){P(t,e),P(n,e)}}),[t,n])},unstable_useId:function(t){var n=e.useState(t),o=n[0],r=n[1],i=t||o;return e.useEffect((function(){null==o&&r("mui-".concat(Math.round(1e5*Math.random())))}),[o]),i},useIsFocusVisible:function(){return{isFocusVisible:K,onBlurVisible:U,ref:e.useCallback((function(e){var t,n=_.findDOMNode(e);null!=n&&((t=n.ownerDocument).addEventListener("keydown",L,!0),t.addEventListener("mousedown",B,!0),t.addEventListener("pointerdown",B,!0),t.addEventListener("touchstart",B,!0),t.addEventListener("visibilitychange",V,!0))}),[])}}}),H=y((function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"default",{enumerable:!0,get:function(){return q.createSvgIcon}})}));v(H);var X=H;export{S as M,E as S,k as a,O as i,X as r};
|
package/package.json
CHANGED
|
@@ -1,114 +1,114 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "@daoyi/nmtl-ui",
|
|
3
|
-
"version": "1.1.
|
|
4
|
-
"description": "This project is to be used as a starter kit for building React component using Storybook and Rollup",
|
|
5
|
-
"author": "daoyi",
|
|
6
|
-
"main": "lib/index.js",
|
|
7
|
-
"typings": "lib/index.d.ts",
|
|
8
|
-
"files": [
|
|
9
|
-
"lib"
|
|
10
|
-
],
|
|
11
|
-
"repository": {
|
|
12
|
-
"type": "git",
|
|
13
|
-
"url": "https://github.com/HsunTsai/react-storybook-jsx-starter"
|
|
14
|
-
},
|
|
15
|
-
"dependencies": {
|
|
16
|
-
"@material-ui/core": "4.12.3",
|
|
17
|
-
"@material-ui/icons": "4.11.2",
|
|
18
|
-
"@material-ui/lab": "4.0.0-alpha.60",
|
|
19
|
-
"@material-ui/styles": "4.11.4",
|
|
20
|
-
"@rollup/plugin-json": "4.1.0",
|
|
21
|
-
"axios": "0.21.1",
|
|
22
|
-
"classnames": "2.3.1",
|
|
23
|
-
"emailjs-com": "2.6.4",
|
|
24
|
-
"formik": "2.2.9",
|
|
25
|
-
"http-proxy-middleware": "1.3.1",
|
|
26
|
-
"jquery": "3.6.0",
|
|
27
|
-
"js-file-download": "0.4.12",
|
|
28
|
-
"lodash": "4.17.21",
|
|
29
|
-
"moment": "2.29.1",
|
|
30
|
-
"node-sass": "4.14.1",
|
|
31
|
-
"notistack": "1.0.10",
|
|
32
|
-
"prop-types": "15.7.2",
|
|
33
|
-
"query-string": "6.12.1",
|
|
34
|
-
"react": "16.14.0",
|
|
35
|
-
"react-awesome-lightbox": "^1.8.1",
|
|
36
|
-
"react-dom": "16.14.0",
|
|
37
|
-
"react-dropzone": "11.3.2",
|
|
38
|
-
"react-facebook-login": "4.1.1",
|
|
39
|
-
"react-google-login": "5.2.2",
|
|
40
|
-
"react-intl": "5.8.0",
|
|
41
|
-
"react-redux": "7.2.5",
|
|
42
|
-
"react-router-dom": "5.2.0",
|
|
43
|
-
"react-slick": "^0.28.1",
|
|
44
|
-
"redux": "4.1.0",
|
|
45
|
-
"sass": "1.41.1",
|
|
46
|
-
"slick-carousel": "^1.8.1"
|
|
47
|
-
},
|
|
48
|
-
"devDependencies": {
|
|
49
|
-
"@babel/core": "7.15.5",
|
|
50
|
-
"@babel/plugin-proposal-class-properties": "7.14.5",
|
|
51
|
-
"@babel/plugin-proposal-private-methods": "7.14.5",
|
|
52
|
-
"@babel/plugin-syntax-dynamic-import": "7.8.3",
|
|
53
|
-
"@babel/preset-env": "7.15.6",
|
|
54
|
-
"@babel/preset-react": "7.14.5",
|
|
55
|
-
"@rollup/plugin-image": "2.1.1",
|
|
56
|
-
"@storybook/addon-essentials": "6.3.5",
|
|
57
|
-
"@storybook/addon-links": "6.3.8",
|
|
58
|
-
"@storybook/addon-notes": "5.3.21",
|
|
59
|
-
"@storybook/addons": "6.3.8",
|
|
60
|
-
"@storybook/preset-scss": "1.0.3",
|
|
61
|
-
"@storybook/react": "6.3.8",
|
|
62
|
-
"autoprefixer": "9.8.6",
|
|
63
|
-
"babel-loader": "8.2.2",
|
|
64
|
-
"css-loader": "1.0.1",
|
|
65
|
-
"eslint": "7.2.0",
|
|
66
|
-
"eslint-config-airbnb": "18.2.1",
|
|
67
|
-
"eslint-config-node": "4.1.0",
|
|
68
|
-
"eslint-config-prettier": "8.3.0",
|
|
69
|
-
"eslint-loader": "4.0.2",
|
|
70
|
-
"eslint-plugin-import": "2.22.1",
|
|
71
|
-
"eslint-plugin-jsx-a11y": "6.4.1",
|
|
72
|
-
"eslint-plugin-node": "11.1.0",
|
|
73
|
-
"eslint-plugin-prettier": "3.4.1",
|
|
74
|
-
"eslint-plugin-react": "7.21.5",
|
|
75
|
-
"eslint-plugin-react-hooks": "1.7.0",
|
|
76
|
-
"prettier": "2.4.1",
|
|
77
|
-
"rollup": "2.56.3",
|
|
78
|
-
"rollup-plugin-babel": "4.4.0",
|
|
79
|
-
"rollup-plugin-cleaner": "1.0.0",
|
|
80
|
-
"rollup-plugin-commonjs": "10.1.0",
|
|
81
|
-
"rollup-plugin-node-resolve": "5.2.0",
|
|
82
|
-
"rollup-plugin-postcss": "4.0.1",
|
|
83
|
-
"rollup-plugin-replace": "2.2.0",
|
|
84
|
-
"rollup-plugin-terser": "7.0.2",
|
|
85
|
-
"sass-loader": "7.1.0",
|
|
86
|
-
"style-loader": "0.22.1"
|
|
87
|
-
},
|
|
88
|
-
"browserslist": {
|
|
89
|
-
"production": [
|
|
90
|
-
">0.2%",
|
|
91
|
-
"not dead",
|
|
92
|
-
"not op_mini all"
|
|
93
|
-
],
|
|
94
|
-
"development": [
|
|
95
|
-
"last 1 chrome version",
|
|
96
|
-
"last 1 firefox version",
|
|
97
|
-
"last 1 safari version"
|
|
98
|
-
]
|
|
99
|
-
},
|
|
100
|
-
"scripts": {
|
|
101
|
-
"start": "set NODE_OPTIONS=--max_old_space_size=16384 && yarn storybook",
|
|
102
|
-
"lint": "eslint ./src/**/*.{js,jsx}",
|
|
103
|
-
"format": "prettier --write --tab-width 4 --use-tabs true \"{,src/**/}*.{js,jsx}\"",
|
|
104
|
-
"storybook": "start-storybook -p 6006",
|
|
105
|
-
"build": "rollup -c && npm run build-index",
|
|
106
|
-
"build-index": "node ./rollup.index.js",
|
|
107
|
-
"build-storybook": "build-storybook -c .storybook -o public",
|
|
108
|
-
"create": "node ./buildUtils/create.js",
|
|
109
|
-
"updateStory": "node ./buildUtils/updateStories.js",
|
|
110
|
-
"pub": "npm version patch -m Publish && npm publish",
|
|
111
|
-
"pub-alpha": "npm version prerelease --preid=alpha && npm publish --tag alpha",
|
|
112
|
-
"pub-beta": "npm version prerelease --preid=beta && npm publish --tag beta"
|
|
113
|
-
}
|
|
114
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"name": "@daoyi/nmtl-ui",
|
|
3
|
+
"version": "1.1.38",
|
|
4
|
+
"description": "This project is to be used as a starter kit for building React component using Storybook and Rollup",
|
|
5
|
+
"author": "daoyi",
|
|
6
|
+
"main": "lib/index.js",
|
|
7
|
+
"typings": "lib/index.d.ts",
|
|
8
|
+
"files": [
|
|
9
|
+
"lib"
|
|
10
|
+
],
|
|
11
|
+
"repository": {
|
|
12
|
+
"type": "git",
|
|
13
|
+
"url": "https://github.com/HsunTsai/react-storybook-jsx-starter"
|
|
14
|
+
},
|
|
15
|
+
"dependencies": {
|
|
16
|
+
"@material-ui/core": "4.12.3",
|
|
17
|
+
"@material-ui/icons": "4.11.2",
|
|
18
|
+
"@material-ui/lab": "4.0.0-alpha.60",
|
|
19
|
+
"@material-ui/styles": "4.11.4",
|
|
20
|
+
"@rollup/plugin-json": "4.1.0",
|
|
21
|
+
"axios": "0.21.1",
|
|
22
|
+
"classnames": "2.3.1",
|
|
23
|
+
"emailjs-com": "2.6.4",
|
|
24
|
+
"formik": "2.2.9",
|
|
25
|
+
"http-proxy-middleware": "1.3.1",
|
|
26
|
+
"jquery": "3.6.0",
|
|
27
|
+
"js-file-download": "0.4.12",
|
|
28
|
+
"lodash": "4.17.21",
|
|
29
|
+
"moment": "2.29.1",
|
|
30
|
+
"node-sass": "4.14.1",
|
|
31
|
+
"notistack": "1.0.10",
|
|
32
|
+
"prop-types": "15.7.2",
|
|
33
|
+
"query-string": "6.12.1",
|
|
34
|
+
"react": "16.14.0",
|
|
35
|
+
"react-awesome-lightbox": "^1.8.1",
|
|
36
|
+
"react-dom": "16.14.0",
|
|
37
|
+
"react-dropzone": "11.3.2",
|
|
38
|
+
"react-facebook-login": "4.1.1",
|
|
39
|
+
"react-google-login": "5.2.2",
|
|
40
|
+
"react-intl": "5.8.0",
|
|
41
|
+
"react-redux": "7.2.5",
|
|
42
|
+
"react-router-dom": "5.2.0",
|
|
43
|
+
"react-slick": "^0.28.1",
|
|
44
|
+
"redux": "4.1.0",
|
|
45
|
+
"sass": "1.41.1",
|
|
46
|
+
"slick-carousel": "^1.8.1"
|
|
47
|
+
},
|
|
48
|
+
"devDependencies": {
|
|
49
|
+
"@babel/core": "7.15.5",
|
|
50
|
+
"@babel/plugin-proposal-class-properties": "7.14.5",
|
|
51
|
+
"@babel/plugin-proposal-private-methods": "7.14.5",
|
|
52
|
+
"@babel/plugin-syntax-dynamic-import": "7.8.3",
|
|
53
|
+
"@babel/preset-env": "7.15.6",
|
|
54
|
+
"@babel/preset-react": "7.14.5",
|
|
55
|
+
"@rollup/plugin-image": "2.1.1",
|
|
56
|
+
"@storybook/addon-essentials": "6.3.5",
|
|
57
|
+
"@storybook/addon-links": "6.3.8",
|
|
58
|
+
"@storybook/addon-notes": "5.3.21",
|
|
59
|
+
"@storybook/addons": "6.3.8",
|
|
60
|
+
"@storybook/preset-scss": "1.0.3",
|
|
61
|
+
"@storybook/react": "6.3.8",
|
|
62
|
+
"autoprefixer": "9.8.6",
|
|
63
|
+
"babel-loader": "8.2.2",
|
|
64
|
+
"css-loader": "1.0.1",
|
|
65
|
+
"eslint": "7.2.0",
|
|
66
|
+
"eslint-config-airbnb": "18.2.1",
|
|
67
|
+
"eslint-config-node": "4.1.0",
|
|
68
|
+
"eslint-config-prettier": "8.3.0",
|
|
69
|
+
"eslint-loader": "4.0.2",
|
|
70
|
+
"eslint-plugin-import": "2.22.1",
|
|
71
|
+
"eslint-plugin-jsx-a11y": "6.4.1",
|
|
72
|
+
"eslint-plugin-node": "11.1.0",
|
|
73
|
+
"eslint-plugin-prettier": "3.4.1",
|
|
74
|
+
"eslint-plugin-react": "7.21.5",
|
|
75
|
+
"eslint-plugin-react-hooks": "1.7.0",
|
|
76
|
+
"prettier": "2.4.1",
|
|
77
|
+
"rollup": "2.56.3",
|
|
78
|
+
"rollup-plugin-babel": "4.4.0",
|
|
79
|
+
"rollup-plugin-cleaner": "1.0.0",
|
|
80
|
+
"rollup-plugin-commonjs": "10.1.0",
|
|
81
|
+
"rollup-plugin-node-resolve": "5.2.0",
|
|
82
|
+
"rollup-plugin-postcss": "4.0.1",
|
|
83
|
+
"rollup-plugin-replace": "2.2.0",
|
|
84
|
+
"rollup-plugin-terser": "7.0.2",
|
|
85
|
+
"sass-loader": "7.1.0",
|
|
86
|
+
"style-loader": "0.22.1"
|
|
87
|
+
},
|
|
88
|
+
"browserslist": {
|
|
89
|
+
"production": [
|
|
90
|
+
">0.2%",
|
|
91
|
+
"not dead",
|
|
92
|
+
"not op_mini all"
|
|
93
|
+
],
|
|
94
|
+
"development": [
|
|
95
|
+
"last 1 chrome version",
|
|
96
|
+
"last 1 firefox version",
|
|
97
|
+
"last 1 safari version"
|
|
98
|
+
]
|
|
99
|
+
},
|
|
100
|
+
"scripts": {
|
|
101
|
+
"start": "set NODE_OPTIONS=--max_old_space_size=16384 && yarn storybook",
|
|
102
|
+
"lint": "eslint ./src/**/*.{js,jsx}",
|
|
103
|
+
"format": "prettier --write --tab-width 4 --use-tabs true \"{,src/**/}*.{js,jsx}\"",
|
|
104
|
+
"storybook": "start-storybook -p 6006",
|
|
105
|
+
"build": "rollup -c && npm run build-index",
|
|
106
|
+
"build-index": "node ./rollup.index.js",
|
|
107
|
+
"build-storybook": "build-storybook -c .storybook -o public",
|
|
108
|
+
"create": "node ./buildUtils/create.js",
|
|
109
|
+
"updateStory": "node ./buildUtils/updateStories.js",
|
|
110
|
+
"pub": "npm version patch -m Publish && npm publish",
|
|
111
|
+
"pub-alpha": "npm version prerelease --preid=alpha && npm publish --tag alpha",
|
|
112
|
+
"pub-beta": "npm version prerelease --preid=beta && npm publish --tag beta"
|
|
113
|
+
}
|
|
114
|
+
}
|