@mi-avalon/libs 0.0.18 → 0.0.20
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/dist/components/ItemsRow/index.d.ts +42 -0
- package/dist/components/ItemsRow/index.js +20 -0
- package/dist/components/MBreadcrumb/index.d.ts +17 -0
- package/dist/components/MBreadcrumb/index.js +34 -0
- package/dist/components/MDescriptions/index.js +2 -1
- package/dist/components/MTable/index.d.ts +7 -0
- package/dist/components/MTable/index.js +10 -0
- package/dist/components/ThemeContext/index.d.ts +11 -0
- package/dist/components/ThemeContext/index.js +17 -0
- package/dist/components/index.d.ts +4 -1
- package/dist/components/index.js +4 -5
- package/dist/index.es.js +454 -363
- package/dist/index.umd.js +11 -11
- package/dist/style.css +1 -1
- package/package.json +1 -1
- package/dist/components/MyButton/index.d.ts +0 -10
- package/dist/components/MyButton/index.js +0 -7
package/dist/index.umd.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
(function(d,
|
|
1
|
+
(function(d,j){typeof exports=="object"&&typeof module<"u"?j(exports,require("react"),require("antd")):typeof define=="function"&&define.amd?define(["exports","react","antd"],j):(d=typeof globalThis<"u"?globalThis:d||self,j(d.MiAvalonLibs={},d.React,d.antd))})(this,function(d,j,y){"use strict";var Ar=Object.defineProperty;var Pr=(d,j,y)=>j in d?Ar(d,j,{enumerable:!0,configurable:!0,writable:!0,value:y}):d[j]=y;var m=(d,j,y)=>(Pr(d,typeof j!="symbol"?j+"":j,y),y);function Le(o){if(o&&o.__esModule)return o;const a=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(o){for(const _ in o)if(_!=="default"){const c=Object.getOwnPropertyDescriptor(o,_);Object.defineProperty(a,_,c.get?c:{enumerable:!0,get:()=>o[_]})}}return a.default=o,Object.freeze(a)}const I=Le(j);var ee={exports:{}},H={};/**
|
|
2
2
|
* @license React
|
|
3
3
|
* react-jsx-runtime.production.min.js
|
|
4
4
|
*
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
*
|
|
7
7
|
* This source code is licensed under the MIT license found in the
|
|
8
8
|
* LICENSE file in the root directory of this source tree.
|
|
9
|
-
*/var
|
|
9
|
+
*/var fe;function Ue(){if(fe)return H;fe=1;var o=I.default,a=Symbol.for("react.element"),_=Symbol.for("react.fragment"),c=Object.prototype.hasOwnProperty,T=o.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,A={key:!0,ref:!0,__self:!0,__source:!0};function E(S,h,D){var R,f={},w=null,M=null;D!==void 0&&(w=""+D),h.key!==void 0&&(w=""+h.key),h.ref!==void 0&&(M=h.ref);for(R in h)c.call(h,R)&&!A.hasOwnProperty(R)&&(f[R]=h[R]);if(S&&S.defaultProps)for(R in h=S.defaultProps,h)f[R]===void 0&&(f[R]=h[R]);return{$$typeof:a,type:S,key:w,ref:M,props:f,_owner:T.current}}return H.Fragment=_,H.jsx=E,H.jsxs=E,H}var L={};/**
|
|
10
10
|
* @license React
|
|
11
11
|
* react-jsx-runtime.development.js
|
|
12
12
|
*
|
|
@@ -14,19 +14,19 @@
|
|
|
14
14
|
*
|
|
15
15
|
* This source code is licensed under the MIT license found in the
|
|
16
16
|
* LICENSE file in the root directory of this source tree.
|
|
17
|
-
*/var
|
|
18
|
-
`+
|
|
19
|
-
`),
|
|
20
|
-
`),
|
|
21
|
-
`+
|
|
17
|
+
*/var de;function Ve(){return de||(de=1,process.env.NODE_ENV!=="production"&&function(){var o=I.default,a=Symbol.for("react.element"),_=Symbol.for("react.portal"),c=Symbol.for("react.fragment"),T=Symbol.for("react.strict_mode"),A=Symbol.for("react.profiler"),E=Symbol.for("react.provider"),S=Symbol.for("react.context"),h=Symbol.for("react.forward_ref"),D=Symbol.for("react.suspense"),R=Symbol.for("react.suspense_list"),f=Symbol.for("react.memo"),w=Symbol.for("react.lazy"),M=Symbol.for("react.offscreen"),q=Symbol.iterator,N="@@iterator";function re(e){if(e===null||typeof e!="object")return null;var r=q&&e[q]||e[N];return typeof r=="function"?r:null}var Y=o.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function C(e){{for(var r=arguments.length,t=new Array(r>1?r-1:0),n=1;n<r;n++)t[n-1]=arguments[n];Ge("error",e,t)}}function Ge(e,r,t){{var n=Y.ReactDebugCurrentFrame,u=n.getStackAddendum();u!==""&&(r+="%s",t=t.concat([u]));var l=t.map(function(s){return String(s)});l.unshift("Warning: "+r),Function.prototype.apply.call(console[e],console,l)}}var Xe=!1,Qe=!1,er=!1,rr=!1,tr=!1,_e;_e=Symbol.for("react.module.reference");function nr(e){return!!(typeof e=="string"||typeof e=="function"||e===c||e===A||tr||e===T||e===D||e===R||rr||e===M||Xe||Qe||er||typeof e=="object"&&e!==null&&(e.$$typeof===w||e.$$typeof===f||e.$$typeof===E||e.$$typeof===S||e.$$typeof===h||e.$$typeof===_e||e.getModuleId!==void 0))}function ar(e,r,t){var n=e.displayName;if(n)return n;var u=r.displayName||r.name||"";return u!==""?t+"("+u+")":t}function Ee(e){return e.displayName||"Context"}function P(e){if(e==null)return null;if(typeof e.tag=="number"&&C("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case c:return"Fragment";case _:return"Portal";case A:return"Profiler";case T:return"StrictMode";case D:return"Suspense";case R:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case S:var r=e;return Ee(r)+".Consumer";case E:var t=e;return Ee(t._context)+".Provider";case h:return ar(e,e.render,"ForwardRef");case f:var n=e.displayName||null;return n!==null?n:P(e.type)||"Memo";case w:{var u=e,l=u._payload,s=u._init;try{return P(s(l))}catch{return null}}}return null}var k=Object.assign,Z=0,Re,ye,Ce,je,xe,Se,we;function Oe(){}Oe.__reactDisabledLog=!0;function ir(){{if(Z===0){Re=console.log,ye=console.info,Ce=console.warn,je=console.error,xe=console.group,Se=console.groupCollapsed,we=console.groupEnd;var e={configurable:!0,enumerable:!0,value:Oe,writable:!0};Object.defineProperties(console,{info:e,log:e,warn:e,error:e,group:e,groupCollapsed:e,groupEnd:e})}Z++}}function or(){{if(Z--,Z===0){var e={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:k({},e,{value:Re}),info:k({},e,{value:ye}),warn:k({},e,{value:Ce}),error:k({},e,{value:je}),group:k({},e,{value:xe}),groupCollapsed:k({},e,{value:Se}),groupEnd:k({},e,{value:we})})}Z<0&&C("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}}var te=Y.ReactCurrentDispatcher,ne;function K(e,r,t){{if(ne===void 0)try{throw Error()}catch(u){var n=u.stack.trim().match(/\n( *(at )?)/);ne=n&&n[1]||""}return`
|
|
18
|
+
`+ne+e}}var ae=!1,G;{var sr=typeof WeakMap=="function"?WeakMap:Map;G=new sr}function Te(e,r){if(!e||ae)return"";{var t=G.get(e);if(t!==void 0)return t}var n;ae=!0;var u=Error.prepareStackTrace;Error.prepareStackTrace=void 0;var l;l=te.current,te.current=null,ir();try{if(r){var s=function(){throw Error()};if(Object.defineProperty(s.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(s,[])}catch(O){n=O}Reflect.construct(e,[],s)}else{try{s.call()}catch(O){n=O}e.call(s.prototype)}}else{try{throw Error()}catch(O){n=O}e()}}catch(O){if(O&&n&&typeof O.stack=="string"){for(var i=O.stack.split(`
|
|
19
|
+
`),x=n.stack.split(`
|
|
20
|
+
`),p=i.length-1,b=x.length-1;p>=1&&b>=0&&i[p]!==x[b];)b--;for(;p>=1&&b>=0;p--,b--)if(i[p]!==x[b]){if(p!==1||b!==1)do if(p--,b--,b<0||i[p]!==x[b]){var $=`
|
|
21
|
+
`+i[p].replace(" at new "," at ");return e.displayName&&$.includes("<anonymous>")&&($=$.replace("<anonymous>",e.displayName)),typeof e=="function"&&G.set(e,$),$}while(p>=1&&b>=0);break}}}finally{ae=!1,te.current=l,or(),Error.prepareStackTrace=u}var z=e?e.displayName||e.name:"",F=z?K(z):"";return typeof e=="function"&&G.set(e,F),F}function ur(e,r,t){return Te(e,!1)}function lr(e){var r=e.prototype;return!!(r&&r.isReactComponent)}function X(e,r,t){if(e==null)return"";if(typeof e=="function")return Te(e,lr(e));if(typeof e=="string")return K(e);switch(e){case D:return K("Suspense");case R:return K("SuspenseList")}if(typeof e=="object")switch(e.$$typeof){case h:return ur(e.render);case f:return X(e.type,r,t);case w:{var n=e,u=n._payload,l=n._init;try{return X(l(u),r,t)}catch{}}}return""}var B=Object.prototype.hasOwnProperty,De={},$e=Y.ReactDebugCurrentFrame;function Q(e){if(e){var r=e._owner,t=X(e.type,e._source,r?r.type:null);$e.setExtraStackFrame(t)}else $e.setExtraStackFrame(null)}function cr(e,r,t,n,u){{var l=Function.call.bind(B);for(var s in e)if(l(e,s)){var i=void 0;try{if(typeof e[s]!="function"){var x=Error((n||"React class")+": "+t+" type `"+s+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof e[s]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw x.name="Invariant Violation",x}i=e[s](r,s,n,t,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(p){i=p}i&&!(i instanceof Error)&&(Q(u),C("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).",n||"React class",t,s,typeof i),Q(null)),i instanceof Error&&!(i.message in De)&&(De[i.message]=!0,Q(u),C("Failed %s type: %s",t,i.message),Q(null))}}}var fr=Array.isArray;function ie(e){return fr(e)}function dr(e){{var r=typeof Symbol=="function"&&Symbol.toStringTag,t=r&&e[Symbol.toStringTag]||e.constructor.name||"Object";return t}}function vr(e){try{return Ae(e),!1}catch{return!0}}function Ae(e){return""+e}function Pe(e){if(vr(e))return C("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",dr(e)),Ae(e)}var J=Y.ReactCurrentOwner,mr={key:!0,ref:!0,__self:!0,__source:!0},Ye,Me,oe;oe={};function pr(e){if(B.call(e,"ref")){var r=Object.getOwnPropertyDescriptor(e,"ref").get;if(r&&r.isReactWarning)return!1}return e.ref!==void 0}function hr(e){if(B.call(e,"key")){var r=Object.getOwnPropertyDescriptor(e,"key").get;if(r&&r.isReactWarning)return!1}return e.key!==void 0}function br(e,r){if(typeof e.ref=="string"&&J.current&&r&&J.current.stateNode!==r){var t=P(J.current.type);oe[t]||(C('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref',P(J.current.type),e.ref),oe[t]=!0)}}function gr(e,r){{var t=function(){Ye||(Ye=!0,C("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",r))};t.isReactWarning=!0,Object.defineProperty(e,"key",{get:t,configurable:!0})}}function _r(e,r){{var t=function(){Me||(Me=!0,C("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",r))};t.isReactWarning=!0,Object.defineProperty(e,"ref",{get:t,configurable:!0})}}var Er=function(e,r,t,n,u,l,s){var i={$$typeof:a,type:e,key:r,ref:t,props:s,_owner:l};return i._store={},Object.defineProperty(i._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(i,"_self",{configurable:!1,enumerable:!1,writable:!1,value:n}),Object.defineProperty(i,"_source",{configurable:!1,enumerable:!1,writable:!1,value:u}),Object.freeze&&(Object.freeze(i.props),Object.freeze(i)),i};function Rr(e,r,t,n,u){{var l,s={},i=null,x=null;t!==void 0&&(Pe(t),i=""+t),hr(r)&&(Pe(r.key),i=""+r.key),pr(r)&&(x=r.ref,br(r,u));for(l in r)B.call(r,l)&&!mr.hasOwnProperty(l)&&(s[l]=r[l]);if(e&&e.defaultProps){var p=e.defaultProps;for(l in p)s[l]===void 0&&(s[l]=p[l])}if(i||x){var b=typeof e=="function"?e.displayName||e.name||"Unknown":e;i&&gr(s,b),x&&_r(s,b)}return Er(e,i,x,u,n,J.current,s)}}var se=Y.ReactCurrentOwner,ke=Y.ReactDebugCurrentFrame;function W(e){if(e){var r=e._owner,t=X(e.type,e._source,r?r.type:null);ke.setExtraStackFrame(t)}else ke.setExtraStackFrame(null)}var ue;ue=!1;function le(e){return typeof e=="object"&&e!==null&&e.$$typeof===a}function Fe(){{if(se.current){var e=P(se.current.type);if(e)return`
|
|
22
22
|
|
|
23
|
-
Check the render method of \``+e+"`."}return""}}function
|
|
23
|
+
Check the render method of \``+e+"`."}return""}}function yr(e){{if(e!==void 0){var r=e.fileName.replace(/^.*[\\\/]/,""),t=e.lineNumber;return`
|
|
24
24
|
|
|
25
|
-
Check your code at `+r+":"+t+"."}return""}}var
|
|
25
|
+
Check your code at `+r+":"+t+"."}return""}}var Ie={};function Cr(e){{var r=Fe();if(!r){var t=typeof e=="string"?e:e.displayName||e.name;t&&(r=`
|
|
26
26
|
|
|
27
|
-
Check the top-level render call using <`+t+">.")}return r}}function
|
|
27
|
+
Check the top-level render call using <`+t+">.")}return r}}function Ne(e,r){{if(!e._store||e._store.validated||e.key!=null)return;e._store.validated=!0;var t=Cr(r);if(Ie[t])return;Ie[t]=!0;var n="";e&&e._owner&&e._owner!==se.current&&(n=" It was passed a child from "+P(e._owner.type)+"."),W(e),C('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.',t,n),W(null)}}function We(e,r){{if(typeof e!="object")return;if(ie(e))for(var t=0;t<e.length;t++){var n=e[t];le(n)&&Ne(n,r)}else if(le(e))e._store&&(e._store.validated=!0);else if(e){var u=re(e);if(typeof u=="function"&&u!==e.entries)for(var l=u.call(e),s;!(s=l.next()).done;)le(s.value)&&Ne(s.value,r)}}}function jr(e){{var r=e.type;if(r==null||typeof r=="string")return;var t;if(typeof r=="function")t=r.propTypes;else if(typeof r=="object"&&(r.$$typeof===h||r.$$typeof===f))t=r.propTypes;else return;if(t){var n=P(r);cr(t,e.props,"prop",n,e)}else if(r.PropTypes!==void 0&&!ue){ue=!0;var u=P(r);C("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",u||"Unknown")}typeof r.getDefaultProps=="function"&&!r.getDefaultProps.isReactClassApproved&&C("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function xr(e){{for(var r=Object.keys(e.props),t=0;t<r.length;t++){var n=r[t];if(n!=="children"&&n!=="key"){W(e),C("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",n),W(null);break}}e.ref!==null&&(W(e),C("Invalid attribute `ref` supplied to `React.Fragment`."),W(null))}}var ze={};function He(e,r,t,n,u,l){{var s=nr(e);if(!s){var i="";(e===void 0||typeof e=="object"&&e!==null&&Object.keys(e).length===0)&&(i+=" You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");var x=yr(u);x?i+=x:i+=Fe();var p;e===null?p="null":ie(e)?p="array":e!==void 0&&e.$$typeof===a?(p="<"+(P(e.type)||"Unknown")+" />",i=" Did you accidentally export a JSX literal instead of a component?"):p=typeof e,C("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",p,i)}var b=Rr(e,r,t,u,l);if(b==null)return b;if(s){var $=r.children;if($!==void 0)if(n)if(ie($)){for(var z=0;z<$.length;z++)We($[z],e);Object.freeze&&Object.freeze($)}else C("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");else We($,e)}if(B.call(r,"key")){var F=P(e),O=Object.keys(r).filter(function($r){return $r!=="key"}),ce=O.length>0?"{key: someKey, "+O.join(": ..., ")+": ...}":"{key: someKey}";if(!ze[F+ce]){var Dr=O.length>0?"{"+O.join(": ..., ")+": ...}":"{}";C(`A props object containing a "key" prop is being spread into JSX:
|
|
28
28
|
let props = %s;
|
|
29
29
|
<%s {...props} />
|
|
30
30
|
React keys must be passed directly to JSX without using spread:
|
|
31
31
|
let props = %s;
|
|
32
|
-
<%s key={someKey} {...props} />`,
|
|
32
|
+
<%s key={someKey} {...props} />`,ce,F,Dr,F),ze[F+ce]=!0}}return e===c?xr(b):jr(b),b}}function Sr(e,r,t){return He(e,r,t,!0)}function wr(e,r,t){return He(e,r,t,!1)}var Or=wr,Tr=Sr;L.Fragment=c,L.jsx=Or,L.jsxs=Tr}()),L}process.env.NODE_ENV==="production"?ee.exports=Ue():ee.exports=Ve();var g=ee.exports;const ve=j.createContext({theme:{cssVar:!0,algorithm:[y.theme.defaultAlgorithm]}}),Ze=ve.Provider;function me(){return j.useContext(ve)}function U(o){const{theme:a}=me();return g.jsx(y.ConfigProvider,{theme:a,children:o.children})}const pe=(o,a)=>{const _=o;let c=o;if(a.includes(" ")){c="";const T=a==null?void 0:a.split(" ");for(const A of T)c+=` ${_}-${A}`}else a&&(c=`${o}-${a}`);return c},he=(o="")=>pe("items-row",o),be=o=>o.items?g.jsx(U,{children:g.jsx("div",{className:`${he()} ${o.className||""}`,style:o.style,children:(o.items||[]).map((a,_)=>{const c=`${he("item")} ${a.className}`;return a.render?g.jsx("span",{className:c,children:a.render()},_):g.jsx(y.Button,{className:c,...a.btnProps,type:a.type||"primary",onClick:a.onClick,children:a.label},a.label)})})}):null,Yr="",V=(o="")=>pe("m-breadcrumb",o),Be=o=>{const{routes:a,customItems:_,style:c,className:T,offsetTop:A=64,mainAppBaseUrl:E,microAppName:S}=o,h=I.useRef(null),D=I.useCallback(()=>{var f,w;(w=(f=h.current)==null?void 0:f.updatePosition)==null||w.call(f)},[]);I.useEffect(()=>(window.addEventListener("scroll",D,!0),()=>window.removeEventListener("scroll",D)),[D]);const R=I.useCallback(f=>{if(!f)return"";const w=f.replace(/^\/+/,"");return`/${[E==null?void 0:E.replace(/\/+$/,""),S==null?void 0:S.replace(/\/+$/,""),w].filter(Boolean).join("/")}`},[E,S]);return g.jsx(U,{children:g.jsx("div",{className:`${V()} ${T||""}`,style:c,children:g.jsx(y.Affix,{ref:h,offsetTop:A,children:g.jsxs(y.Card,{className:V("container"),rootClassName:V("body"),variant:"borderless",children:[g.jsx(y.Breadcrumb,{className:V("inner-breadcrumb"),style:{fontSize:"18px"},children:a==null?void 0:a.map(f=>g.jsx(y.Breadcrumb.Item,{children:f.url?g.jsx("a",{href:`#${R(f.url)}`,children:f.name}):f.name},f.url||f.name))}),g.jsx("div",{className:V("custom-item-wrapper"),children:g.jsx(be,{items:_})})]})})})})},ge=o=>{const{data:a,title:_,column:c=3,lineHeight:T,align:A="left",itemLayout:E,colon:S=!0,bordered:h=!1,style:D,className:R,labelStyle:f,contentStyle:w}=o,M={...T?{lineHeight:`${T}px`}:{},textAlign:A,...E!=null&&E.label?{width:`${E.label}px`}:{},...f},q={...T?{lineHeight:`${T}px`}:{},...E!=null&&E.value?{width:`${E.value}px`}:{},...w};return g.jsx(U,{children:g.jsx(y.Descriptions,{title:_,column:c,colon:S,bordered:h,style:D,className:R,labelStyle:M,contentStyle:q,children:a.map((N,re)=>{var Y;return g.jsx(y.Descriptions.Item,{label:N.label,span:N.span,children:N.value||"-"},((Y=N.label)==null?void 0:Y.toString())||re)})})})};ge.displayName="MDescriptions";function Je(o){var _;const a=((_=o.columns)==null?void 0:_.map(c=>({...c,dataIndex:c.key})))??[];return g.jsxs(U,{children:[g.jsx(y.Table,{rowKey:c=>c.id,...o,columns:a}),";"]})}const qe={YMD_Hms:"YYYY-MM-DD HH:mm:ss",YMD:"YYYY-MM-DD",YMD2:"YYYYMMDD",YMD_POINT:"YYYY.M.DD",Hms:"HH:mm:ss",Hm:"HH:mm",YMD_000:"YYYY-MM-DD 00:00:00",YMD_end:"YYYY-MM-DD 23:59:59",YMD_Hm:"YYYYMMDD HHmm"},Ke=10;class v{}m(v,"integerRegex",/^-?\d+$/),m(v,"positiveIntegerRegex",/^[1-9]\d*$/),m(v,"negativeIntegerRegex",/^-[1-9]\d*$/),m(v,"floatRegex",/^-?\d+(\.\d+)?$/),m(v,"letter",/^[a-zA-Z]+$/),m(v,"chinese",/^[\u4e00-\u9fa5]+$/),m(v,"number",/^[0-9]*$/),m(v,"username",/^[a-zA-Z]\w{3,15}$/),m(v,"strongUsername",/^(?=.*[a-z])(?=.*[A-Z])(?=.*\d)[a-zA-Z\d]{6,20}$/),m(v,"password",/^(?=.*[A-Za-z])(?=.*\d)[A-Za-z\d]{8,}$/),m(v,"strongPassword",/^(?=.*[a-z])(?=.*[A-Z])(?=.*\d)(?=.*[@$!%*?&])[A-Za-z\d@$!%*?&]{8,}$/),m(v,"phone",/^1[3-9]\d{9}$/),m(v,"phoneWithAreaCode",/^\+?\d{2,3}-?\d{8,11}$/),m(v,"email",/^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$/),m(v,"idCard",/^[1-9]\d{5}[1-9]\d{3}((0\d)|(1[0-2]))(([0|1|2]\d)|3[0-1])\d{3}([0-9]|X)$/),m(v,"bankCard",/^[1-9]\d{3,30}$/),m(v,"zipCode",/^[1-9]\d{5}$/),m(v,"ip",/^(\d{1,2}|1\d\d|2[0-4]\d|25[0-5])\.(\d{1,2}|1\d\d|2[0-4]\d|25[0-5])\.(\d{1,2}|1\d\d|2[0-4]\d|25[0-5])\.(\d{1,2}|1\d\d|2[0-4]\d|25[0-5])$/),m(v,"url",/^(https?:\/\/)?([\da-z.-]+)\.([a-z.]{2,6})([/\w .-]*)*\/?$/),m(v,"carNumber",/^[京津沪渝冀豫云辽黑湘皖鲁新苏浙赣鄂桂甘晋蒙陕吉闽贵粤青藏川宁琼使领][A-HJ-NP-Z][A-HJ-NP-Z0-9]{4,5}[A-HJ-NP-Z0-9挂学警港澳]$/),m(v,"time",/^([0-1][0-9]|2[0-3]):([0-5][0-9]):([0-5][0-9])$/),m(v,"date",/^(\d{4})-(\d{2})-(\d{2})$/),d.CompThemeProvider=U,d.DATE_FORMAT=qe,d.ItemsRow=be,d.MBreadcrumb=Be,d.MDescriptions=ge,d.MTable=Je,d.MiThemeProvider=Ze,d.PAGE_SIZE=Ke,d.PatternType=v,d.useMiThemeConfig=me,Object.defineProperty(d,Symbol.toStringTag,{value:"Module"})});
|
package/dist/style.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
.
|
|
1
|
+
@keyframes m-breadcrumb_show_ani{0%{opacity:0}to{opacity:100}}.m-breadcrumb{position:relative;height:64px;width:100%}.m-breadcrumb-container{transition:padding .3s ease}.m-breadcrumb-body{border-radius:8px;height:64px;line-height:64px}.m-breadcrumb .ant-card-body{width:100%;padding:0 12px;align-items:center}.m-breadcrumb .ant-affix{z-index:999}.ant-affix>.m-breadcrumb-container{z-index:100;width:auto;box-shadow:0 6px 16px #00000014,0 3px 6px -4px #0000001f,0 9px 28px 8px #0000000d}.m-breadcrumb-inner-breadcrumb{display:inline-block;vertical-align:middle;line-height:64px}.m-breadcrumb-inner-breadcrumb .ant-breadcrumb-separator{margin:0 8px}.m-breadcrumb-inner-breadcrumb .ant-breadcrumb-link>a{transition:all .3s;padding:4px 8px;display:inline-block;line-height:1.5}.m-breadcrumb-inner-breadcrumb .ant-breadcrumb-link>a:hover{font-weight:700;text-decoration:none;opacity:.8}.m-breadcrumb-custom-item-wrapper{float:right;height:100%;display:flex;align-items:center}
|
package/package.json
CHANGED
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import './index.scss';
|
|
3
|
-
interface MyButtonProps {
|
|
4
|
-
type?: 'primary' | 'default' | 'dashed' | 'text' | 'link';
|
|
5
|
-
children: React.ReactNode;
|
|
6
|
-
onClick?: () => void;
|
|
7
|
-
custom?: string;
|
|
8
|
-
}
|
|
9
|
-
declare const MyButton: React.FC<MyButtonProps>;
|
|
10
|
-
export default MyButton;
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
-
import { Button } from 'antd';
|
|
3
|
-
import './index.scss';
|
|
4
|
-
const MyButton = ({ type = 'primary', children, onClick, custom }) => {
|
|
5
|
-
return (_jsx(Button, { type: type, onClick: onClick, className: 'my-button', children: custom || children }));
|
|
6
|
-
};
|
|
7
|
-
export default MyButton;
|