👨🏻‍💻👩🏻‍💻 Use Ant Design like a Pro!
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

10 lines
15 KiB

(self.webpackChunkant_design_pro=self.webpackChunkant_design_pro||[]).push([[4462],{19346:function(Y,E,o){"use strict";var r=o(93264),y=o(79685),x=o(96818),D=o(64507),$=function(p,M){return y.createElement(D.Z,(0,r.Z)((0,r.Z)({},p),{},{ref:M,icon:x.Z}))};$.displayName="PlusOutlined",E.Z=y.forwardRef($)},19409:function(Y,E,o){"use strict";var r=o(79685),y=o(81383),x=function(){return x=Object.assign||function($){for(var c,p=1,M=arguments.length;p<M;p++){c=arguments[p];for(var j in c)Object.prototype.hasOwnProperty.call(c,j)&&($[j]=c[j])}return $},x.apply(this,arguments)},D=function($){return r.createElement(y.P,x({},$,{chartType:"Radar"}))};E.Z=D},18283:function(Y,E,o){"use strict";o.d(E,{Z:function(){return f}});var r=o(79685),y=o(68591),x=o.n(y),D=o(3139),$=o(99248),c=o(73064),p=o(57196),M=o(55095),j=function(e,a){var t={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&a.indexOf(n)<0&&(t[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,n=Object.getOwnPropertySymbols(e);i<n.length;i++)a.indexOf(n[i])<0&&Object.prototype.propertyIsEnumerable.call(e,n[i])&&(t[n[i]]=e[n[i]]);return t},H=e=>{var{prefixCls:a,className:t,hoverable:n=!0}=e,i=j(e,["prefixCls","className","hoverable"]);const{getPrefixCls:g}=r.useContext($.E_),C=g("card",a),w=x()(`${C}-grid`,t,{[`${C}-grid-hoverable`]:n});return r.createElement("div",Object.assign({},i,{className:w}))},s=o(26477),T=o(4614),W=o(44244),G=o(25830);const q=e=>{const{antCls:a,componentCls:t,headerHeight:n,cardPaddingBase:i,tabsMarginBottom:g}=e;return Object.assign(Object.assign({display:"flex",justifyContent:"center",flexDirection:"column",minHeight:n,marginBottom:-1,padding:`0 ${(0,s.bf)(i)}`,color:e.colorTextHeading,fontWeight:e.fontWeightStrong,fontSize:e.headerFontSize,background:e.headerBg,borderBottom:`${(0,s.bf)(e.lineWidth)} ${e.lineType} ${e.colorBorderSecondary}`,borderRadius:`${(0,s.bf)(e.borderRadiusLG)} ${(0,s.bf)(e.borderRadiusLG)} 0 0`},(0,T.dF)()),{"&-wrapper":{width:"100%",display:"flex",alignItems:"center"},"&-title":Object.assign(Object.assign({display:"inline-block",flex:1},T.vS),{[`
> ${t}-typography,
> ${t}-typography-edit-content
`]:{insetInlineStart:0,marginTop:0,marginBottom:0}}),[`${a}-tabs-top`]:{clear:"both",marginBottom:g,color:e.colorText,fontWeight:"normal",fontSize:e.fontSize,"&-bar":{borderBottom:`${(0,s.bf)(e.lineWidth)} ${e.lineType} ${e.colorBorderSecondary}`}}})},B=e=>{const{cardPaddingBase:a,colorBorderSecondary:t,cardShadow:n,lineWidth:i}=e;return{width:"33.33%",padding:a,border:0,borderRadius:0,boxShadow:`
${(0,s.bf)(i)} 0 0 0 ${t},
0 ${(0,s.bf)(i)} 0 0 ${t},
${(0,s.bf)(i)} ${(0,s.bf)(i)} 0 0 ${t},
${(0,s.bf)(i)} 0 0 0 ${t} inset,
0 ${(0,s.bf)(i)} 0 0 ${t} inset;
`,transition:`all ${e.motionDurationMid}`,"&-hoverable:hover":{position:"relative",zIndex:1,boxShadow:n}}},P=e=>{const{componentCls:a,iconCls:t,actionsLiMargin:n,cardActionsIconSize:i,colorBorderSecondary:g,actionsBg:C}=e;return Object.assign(Object.assign({margin:0,padding:0,listStyle:"none",background:C,borderTop:`${(0,s.bf)(e.lineWidth)} ${e.lineType} ${g}`,display:"flex",borderRadius:`0 0 ${(0,s.bf)(e.borderRadiusLG)} ${(0,s.bf)(e.borderRadiusLG)}`},(0,T.dF)()),{"& > li":{margin:n,color:e.colorTextDescription,textAlign:"center","> span":{position:"relative",display:"block",minWidth:e.calc(e.cardActionsIconSize).mul(2).equal(),fontSize:e.fontSize,lineHeight:e.lineHeight,cursor:"pointer","&:hover":{color:e.colorPrimary,transition:`color ${e.motionDurationMid}`},[`a:not(${a}-btn), > ${t}`]:{display:"inline-block",width:"100%",color:e.colorTextDescription,lineHeight:(0,s.bf)(e.fontHeight),transition:`color ${e.motionDurationMid}`,"&:hover":{color:e.colorPrimary}},[`> ${t}`]:{fontSize:i,lineHeight:(0,s.bf)(e.calc(i).mul(e.lineHeight).equal())}},"&:not(:last-child)":{borderInlineEnd:`${(0,s.bf)(e.lineWidth)} ${e.lineType} ${g}`}}})},I=e=>Object.assign(Object.assign({margin:`${(0,s.bf)(e.calc(e.marginXXS).mul(-1).equal())} 0`,display:"flex"},(0,T.dF)()),{"&-avatar":{paddingInlineEnd:e.padding},"&-detail":{overflow:"hidden",flex:1,"> div:not(:last-child)":{marginBottom:e.marginXS}},"&-title":Object.assign({color:e.colorTextHeading,fontWeight:e.fontWeightStrong,fontSize:e.fontSizeLG},T.vS),"&-description":{color:e.colorTextDescription}}),A=e=>{const{componentCls:a,cardPaddingBase:t,colorFillAlter:n}=e;return{[`${a}-head`]:{padding:`0 ${(0,s.bf)(t)}`,background:n,"&-title":{fontSize:e.fontSize}},[`${a}-body`]:{padding:`${(0,s.bf)(e.padding)} ${(0,s.bf)(t)}`}}},F=e=>{const{componentCls:a}=e;return{overflow:"hidden",[`${a}-body`]:{userSelect:"none"}}},te=e=>{const{antCls:a,componentCls:t,cardShadow:n,cardHeadPadding:i,colorBorderSecondary:g,boxShadowTertiary:C,cardPaddingBase:w,extraColor:R}=e;return{[t]:Object.assign(Object.assign({},(0,T.Wf)(e)),{position:"relative",background:e.colorBgContainer,borderRadius:e.borderRadiusLG,[`&:not(${t}-bordered)`]:{boxShadow:C},[`${t}-head`]:q(e),[`${t}-extra`]:{marginInlineStart:"auto",color:R,fontWeight:"normal",fontSize:e.fontSize},[`${t}-body`]:Object.assign({padding:w,borderRadius:` 0 0 ${(0,s.bf)(e.borderRadiusLG)} ${(0,s.bf)(e.borderRadiusLG)}`},(0,T.dF)()),[`${t}-grid`]:B(e),[`${t}-cover`]:{"> *":{display:"block",width:"100%"},[`img, img + ${a}-image-mask`]:{borderRadius:`${(0,s.bf)(e.borderRadiusLG)} ${(0,s.bf)(e.borderRadiusLG)} 0 0`}},[`${t}-actions`]:P(e),[`${t}-meta`]:I(e)}),[`${t}-bordered`]:{border:`${(0,s.bf)(e.lineWidth)} ${e.lineType} ${g}`,[`${t}-cover`]:{marginTop:-1,marginInlineStart:-1,marginInlineEnd:-1}},[`${t}-hoverable`]:{cursor:"pointer",transition:`box-shadow ${e.motionDurationMid}, border-color ${e.motionDurationMid}`,"&:hover":{borderColor:"transparent",boxShadow:n}},[`${t}-contain-grid`]:{borderRadius:`${(0,s.bf)(e.borderRadiusLG)} ${(0,s.bf)(e.borderRadiusLG)} 0 0 `,[`${t}-body`]:{display:"flex",flexWrap:"wrap"},[`&:not(${t}-loading) ${t}-body`]:{marginBlockStart:e.calc(e.lineWidth).mul(-1).equal(),marginInlineStart:e.calc(e.lineWidth).mul(-1).equal(),padding:0}},[`${t}-contain-tabs`]:{[`> ${t}-head`]:{minHeight:0,[`${t}-head-title, ${t}-extra`]:{paddingTop:i}}},[`${t}-type-inner`]:A(e),[`${t}-loading`]:F(e),[`${t}-rtl`]:{direction:"rtl"}}},ne=e=>{const{componentCls:a,cardPaddingSM:t,headerHeightSM:n,headerFontSizeSM:i}=e;return{[`${a}-small`]:{[`> ${a}-head`]:{minHeight:n,padding:`0 ${(0,s.bf)(t)}`,fontSize:i,[`> ${a}-head-wrapper`]:{[`> ${a}-extra`]:{fontSize:e.fontSize}}},[`> ${a}-body`]:{padding:t}},[`${a}-small${a}-contain-tabs`]:{[`> ${a}-head`]:{[`${a}-head-title, ${a}-extra`]:{paddingTop:0,display:"flex",alignItems:"center"}}}}},ae=e=>({headerBg:"transparent",headerFontSize:e.fontSizeLG,headerFontSizeSM:e.fontSize,headerHeight:e.fontSizeLG*e.lineHeightLG+e.padding*2,headerHeightSM:e.fontSize*e.lineHeight+e.paddingXS*2,actionsBg:e.colorBgContainer,actionsLiMargin:`${e.paddingSM}px 0`,tabsMarginBottom:-e.padding-e.lineWidth,extraColor:e.colorText});var re=(0,W.I$)("Card",e=>{const a=(0,G.TS)(e,{cardShadow:e.boxShadowCard,cardHeadPadding:e.padding,cardPaddingBase:e.paddingLG,cardActionsIconSize:e.fontSize,cardPaddingSM:12});return[te(a),ne(a)]},ae),d=function(e,a){var t={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&a.indexOf(n)<0&&(t[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,n=Object.getOwnPropertySymbols(e);i<n.length;i++)a.indexOf(n[i])<0&&Object.prototype.propertyIsEnumerable.call(e,n[i])&&(t[n[i]]=e[n[i]]);return t};const l=e=>{const{prefixCls:a,actions:t=[]}=e;return r.createElement("ul",{className:`${a}-actions`},t.map((n,i)=>{const g=`action-${i}`;return r.createElement("li",{style:{width:`${100/t.length}%`},key:g},r.createElement("span",null,n))}))};var u=r.forwardRef((e,a)=>{const{prefixCls:t,className:n,rootClassName:i,style:g,extra:C,headStyle:w={},bodyStyle:R={},title:N,loading:O,bordered:U=!0,size:X,type:Z,cover:_,actions:ie,tabList:k,children:ee,activeTabKey:oe,defaultActiveTabKey:de,tabBarExtraContent:ue,hoverable:fe,tabProps:me={}}=e,ge=d(e,["prefixCls","className","rootClassName","style","extra","headStyle","bodyStyle","title","loading","bordered","size","type","cover","actions","tabList","children","activeTabKey","defaultActiveTabKey","tabBarExtraContent","hoverable","tabProps"]),{getPrefixCls:pe,direction:be,card:V}=r.useContext($.E_),ve=K=>{var L;(L=e.onTabChange)===null||L===void 0||L.call(e,K)},he=r.useMemo(()=>{let K=!1;return r.Children.forEach(ee,L=>{L&&L.type&&L.type===H&&(K=!0)}),K},[ee]),h=pe("card",t),[$e,ye]=re(h),Se=r.createElement(p.Z,{loading:!0,active:!0,paragraph:{rows:4},title:!1},ee),se=oe!==void 0,xe=Object.assign(Object.assign({},me),{[se?"activeKey":"defaultActiveKey"]:se?oe:de,tabBarExtraContent:ue});let le;const Q=(0,c.Z)(X),Ce=!Q||Q==="default"?"large":Q,ce=k?r.createElement(M.Z,Object.assign({size:Ce},xe,{className:`${h}-head-tabs`,onChange:ve,items:k.map(K=>{var{tab:L}=K,Ne=d(K,["tab"]);return Object.assign({label:L},Ne)})})):null;(N||C||ce)&&(le=r.createElement("div",{className:`${h}-head`,style:w},r.createElement("div",{className:`${h}-head-wrapper`},N&&r.createElement("div",{className:`${h}-head-title`},N),C&&r.createElement("div",{className:`${h}-extra`},C)),ce));const Oe=_?r.createElement("div",{className:`${h}-cover`},_):null,Ee=r.createElement("div",{className:`${h}-body`,style:R},O?Se:ee),Te=ie&&ie.length?r.createElement(l,{prefixCls:h,actions:ie}):null,Me=(0,D.Z)(ge,["onTabChange"]),Pe=x()(h,V==null?void 0:V.className,{[`${h}-loading`]:O,[`${h}-bordered`]:U,[`${h}-hoverable`]:fe,[`${h}-contain-grid`]:he,[`${h}-contain-tabs`]:k&&k.length,[`${h}-${Q}`]:Q,[`${h}-type-${Z}`]:!!Z,[`${h}-rtl`]:be==="rtl"},n,i,ye),ze=Object.assign(Object.assign({},V==null?void 0:V.style),g);return $e(r.createElement("div",Object.assign({ref:a},Me,{className:Pe,style:ze}),le,Oe,Ee,Te))}),S=function(e,a){var t={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&a.indexOf(n)<0&&(t[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,n=Object.getOwnPropertySymbols(e);i<n.length;i++)a.indexOf(n[i])<0&&Object.prototype.propertyIsEnumerable.call(e,n[i])&&(t[n[i]]=e[n[i]]);return t},m=e=>{const{prefixCls:a,className:t,avatar:n,title:i,description:g}=e,C=S(e,["prefixCls","className","avatar","title","description"]),{getPrefixCls:w}=r.useContext($.E_),R=w("card",a),N=x()(`${R}-meta`,t),O=n?r.createElement("div",{className:`${R}-meta-avatar`},n):null,U=i?r.createElement("div",{className:`${R}-meta-title`},i):null,X=g?r.createElement("div",{className:`${R}-meta-description`},g):null,Z=U||X?r.createElement("div",{className:`${R}-meta-detail`},U,X):null;return r.createElement("div",Object.assign({},C,{className:N}),O,Z)};const v=u;v.Grid=H,v.Meta=m;var f=v},45161:function(Y,E,o){"use strict";o.d(E,{Z:function(){return re}});var r=o(79685),y=o(28120),x=o(23196),D=o(68591),$=o.n(D),c=o(99248),p=o(57196),j=d=>{const{value:l,formatter:b,precision:u,decimalSeparator:S,groupSeparator:z="",prefixCls:m}=d;let v;if(typeof b=="function")v=b(l);else{const f=String(l),e=f.match(/^(-?)(\d*)(\.(\d+))?$/);if(!e||f==="-")v=f;else{const a=e[1];let t=e[2]||"0",n=e[4]||"";t=t.replace(/\B(?=(\d{3})+(?!\d))/g,z),typeof u=="number"&&(n=n.padEnd(u,"0").slice(0,u>0?u:0)),n&&(n=`${S}${n}`),v=[r.createElement("span",{key:"int",className:`${m}-content-value-int`},a,t),n&&r.createElement("span",{key:"decimal",className:`${m}-content-value-decimal`},n)]}}return r.createElement("span",{className:`${m}-content-value`},v)},J=o(4614),H=o(44244),s=o(25830);const T=d=>{const{componentCls:l,marginXXS:b,padding:u,colorTextDescription:S,titleFontSize:z,colorTextHeading:m,contentFontSize:v,fontFamily:f}=d;return{[`${l}`]:Object.assign(Object.assign({},(0,J.Wf)(d)),{[`${l}-title`]:{marginBottom:b,color:S,fontSize:z},[`${l}-skeleton`]:{paddingTop:u},[`${l}-content`]:{color:m,fontSize:v,fontFamily:f,[`${l}-content-value`]:{display:"inline-block",direction:"ltr"},[`${l}-content-prefix, ${l}-content-suffix`]:{display:"inline-block"},[`${l}-content-prefix`]:{marginInlineEnd:b},[`${l}-content-suffix`]:{marginInlineStart:b}}})}},W=d=>{const{fontSizeHeading3:l,fontSize:b}=d;return{titleFontSize:b,contentFontSize:l}};var G=(0,H.I$)("Statistic",d=>{const l=(0,s.TS)(d,{});return[T(l)]},W),B=d=>{const{prefixCls:l,className:b,rootClassName:u,style:S,valueStyle:z,value:m=0,title:v,valueRender:f,prefix:e,suffix:a,loading:t=!1,onMouseEnter:n,onMouseLeave:i,decimalSeparator:g=".",groupSeparator:C=","}=d,{getPrefixCls:w,direction:R,statistic:N}=r.useContext(c.E_),O=w("statistic",l),[U,X]=G(O),Z=r.createElement(j,Object.assign({decimalSeparator:g,groupSeparator:C,prefixCls:O},d,{value:m})),_=$()(O,{[`${O}-rtl`]:R==="rtl"},N==null?void 0:N.className,b,u,X);return U(r.createElement("div",{className:_,style:Object.assign(Object.assign({},N==null?void 0:N.style),S),onMouseEnter:n,onMouseLeave:i},v&&r.createElement("div",{className:`${O}-title`},v),r.createElement(p.Z,{paragraph:!1,loading:t,className:`${O}-skeleton`},r.createElement("div",{style:z,className:`${O}-content`},e&&r.createElement("span",{className:`${O}-content-prefix`},e),f?f(Z):Z,a&&r.createElement("span",{className:`${O}-content-suffix`},a)))))};const P=[["Y",1e3*60*60*24*365],["M",1e3*60*60*24*30],["D",1e3*60*60*24],["H",1e3*60*60],["m",1e3*60],["s",1e3],["S",1]];function I(d,l){let b=d;const u=/\[[^\]]*]/g,S=(l.match(u)||[]).map(f=>f.slice(1,-1)),z=l.replace(u,"[]"),m=P.reduce((f,e)=>{let[a,t]=e;if(f.includes(a)){const n=Math.floor(b/t);return b-=n*t,f.replace(new RegExp(`${a}+`,"g"),i=>{const g=i.length;return n.toString().padStart(g,"0")})}return f},z);let v=0;return m.replace(u,()=>{const f=S[v];return v+=1,f})}function A(d,l){const{format:b=""}=l,u=new Date(d).getTime(),S=Date.now(),z=Math.max(u-S,0);return I(z,b)}const F=1e3/30;function te(d){return new Date(d).getTime()}const ne=d=>{const{value:l,format:b="HH:mm:ss",onChange:u,onFinish:S}=d,z=(0,y.Z)(),m=r.useRef(null),v=()=>{S==null||S(),m.current&&(clearInterval(m.current),m.current=null)},f=()=>{const t=te(l);t>=Date.now()&&(m.current=setInterval(()=>{z(),u==null||u(t-Date.now()),t<Date.now()&&v()},F))};r.useEffect(()=>(f(),()=>{m.current&&(clearInterval(m.current),m.current=null)}),[l]);const e=(t,n)=>A(t,Object.assign(Object.assign({},n),{format:b})),a=t=>(0,x.Tm)(t,{title:void 0});return r.createElement(B,Object.assign({},d,{valueRender:a,formatter:e}))};var ae=r.memo(ne);B.Countdown=ae;var re=B},96300:function(Y){(function(E,o){Y.exports=o()})(this,function(){"use strict";return function(E,o,r){E=E||{};var y=o.prototype,x={future:"in %s",past:"%s ago",s:"a few seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"};function D(c,p,M,j){return y.fromToBase(c,p,M,j)}r.en.relativeTime=x,y.fromToBase=function(c,p,M,j,J){for(var H,s,T,W=M.$locale().relativeTime||x,G=E.thresholds||[{l:"s",r:44,d:"second"},{l:"m",r:89},{l:"mm",r:44,d:"minute"},{l:"h",r:89},{l:"hh",r:21,d:"hour"},{l:"d",r:35},{l:"dd",r:25,d:"day"},{l:"M",r:45},{l:"MM",r:10,d:"month"},{l:"y",r:17},{l:"yy",d:"year"}],q=G.length,B=0;B<q;B+=1){var P=G[B];P.d&&(H=j?r(c).diff(M,P.d,!0):M.diff(c,P.d,!0));var I=(E.rounding||Math.round)(Math.abs(H));if(T=H>0,I<=P.r||!P.r){I<=1&&B>0&&(P=G[B-1]);var A=W[P.l];J&&(I=J(""+I)),s=typeof A=="string"?A.replace("%d",I):A(I,p,P.l,T);break}}if(p)return s;var F=T?W.future:W.past;return typeof F=="function"?F(s):F.replace("%s",s)},y.to=function(c,p){return D(c,p,this,!0)},y.from=function(c,p){return D(c,p,this)};var $=function(c){return c.$u?r.utc():r()};y.toNow=function(c){return this.to($(this),c)},y.fromNow=function(c){return this.from($(this),c)}}})}}]);