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.
2 lines
12 KiB
2 lines
12 KiB
8 months ago
|
"use strict";(self.webpackChunkant_design_pro=self.webpackChunkant_design_pro||[]).push([[430],{10178:function(k,M,t){t.d(M,{D:function(){return b}});var e=t(74165),v=t(15861),f=t(67294),B=t(48171);function b(D,g){var S=(0,B.J)(D),y=(0,f.useRef)(),C=(0,f.useCallback)(function(){y.current&&(clearTimeout(y.current),y.current=null)},[]),c=(0,f.useCallback)((0,v.Z)((0,e.Z)().mark(function n(){var a,r,s,o=arguments;return(0,e.Z)().wrap(function(p){for(;;)switch(p.prev=p.next){case 0:for(a=o.length,r=new Array(a),s=0;s<a;s++)r[s]=o[s];if(!(g===0||g===void 0)){p.next=3;break}return p.abrupt("return",S.apply(void 0,r));case 3:return C(),p.abrupt("return",new Promise(function(_){y.current=setTimeout((0,v.Z)((0,e.Z)().mark(function x(){return(0,e.Z)().wrap(function(E){for(;;)switch(E.prev=E.next){case 0:return E.t0=_,E.next=3,S.apply(void 0,r);case 3:return E.t1=E.sent,(0,E.t0)(E.t1),E.abrupt("return");case 6:case"end":return E.stop()}},x)})),g)}));case 5:case"end":return p.stop()}},n)})),[S,C,g]);return(0,f.useEffect)(function(){return C},[C]),{run:c,cancel:C}}},48171:function(k,M,t){t.d(M,{J:function(){return f}});var e=t(74902),v=t(67294),f=function(b){var D=(0,v.useRef)(null);return D.current=b,(0,v.useCallback)(function(){for(var g,S=arguments.length,y=new Array(S),C=0;C<S;C++)y[C]=arguments[C];return(g=D.current)===null||g===void 0?void 0:g.call.apply(g,[D].concat((0,e.Z)(y)))},[])}},81643:function(k,M,t){t.d(M,{Z:function(){return e}});const e=v=>v?typeof v=="function"?v():v:null},7134:function(k,M,t){t.d(M,{C:function(){return pe}});var e=t(67294),v=t(93967),f=t.n(v),B=t(9220),b=t(42550),D=t(74443),g=t(53124),S=t(98675),y=t(25378),c=e.createContext({}),n=t(54548),a=t(14747),r=t(91945),s=t(45503);const o=l=>{const{antCls:u,componentCls:m,iconCls:i,avatarBg:h,avatarColor:Q,containerSize:N,containerSizeLG:R,containerSizeSM:U,textFontSize:$,textFontSizeLG:w,textFontSizeSM:re,borderRadius:W,borderRadiusLG:z,borderRadiusSM:V,lineWidth:Y,lineType:q}=l,H=(X,K,ee)=>({width:X,height:X,borderRadius:"50%",[`&${m}-square`]:{borderRadius:ee},[`&${m}-icon`]:{fontSize:K,[`> ${i}`]:{margin:0}}});return{[m]:Object.assign(Object.assign(Object.assign(Object.assign({},(0,a.Wf)(l)),{position:"relative",display:"inline-flex",justifyContent:"center",alignItems:"center",overflow:"hidden",color:Q,whiteSpace:"nowrap",textAlign:"center",verticalAlign:"middle",background:h,border:`${(0,n.bf)(Y)} ${q} transparent`,["&-image"]:{background:"transparent"},[`${u}-image-img`]:{display:"block"}}),H(N,$,W)),{["&-lg"]:Object.assign({},H(R,w,z)),["&-sm"]:Object.assign({},H(U,re,V)),"> img":{display:"block",width:"100%",height:"100%",objectFit:"cover"}})}},d=l=>{const{componentCls:u,groupBorderColor:m,groupOverlapping:i,groupSpace:h}=l;return{[`${u}-group`]:{display:"inline-flex",[`${u}`]:{borderColor:m},["> *:not(:first-child)"]:{marginInlineStart:i}},[`${u}-group-popover`]:{[`${u} + ${u}`]:{marginInlineStart:h}}}},p=l=>{const{controlHeight:u,controlHeightLG:m,controlHeightSM:i,fontSize:h,fontSizeLG:Q,fontSizeXL:N,fontSizeHeading3:R,marginXS:U,marginXXS:$,colorBorderBg:w}=l;return{containerSize:u,containerSizeLG:m,containerSizeSM:i,textFontSize:Math.round((Q+N)/2),textFontSizeLG:R,textFontSizeSM:h,groupSpace:$,groupOverlapping:-U,groupBorderColor:w}};var _=(0,r.I$)("Avatar",l=>{const{colorTextLightSolid:u,colorTextPlaceholder:m}=l,i=(0,s.TS)(l,{avatarBg:m,avatarColor:u});return[o(i),d(i)]},p),x=t(35792),F=function(l,u){var m={};for(var i in l)Object.prototype.hasOwnProperty.call(l,i)&&u.indexOf(i)<0&&(m[i]=l[i]);if(l!=null&&typeof Object.getOwnPropertySymbols=="function")for(var h=0,i=Object.getOwnPropertySymbols(l);h<i.length;h++)u.indexOf(i[h])<0&&Object.prototype.propertyIsEnumerable.call(l,i[h])&&(m[i[h]]=l[i[h]]);return m};const E=(l,u)=>{const[m,i]=e.useState(1),[h,Q]=e.useState(!1),[N,R]=e.useState(!0),U=e.useRef(null),$=e.useRef(null),w=(0,b.sQ)(u,U),{getPrefixCls:re,avatar:W}=e.useContext(g.E_),z=e.useContext(c),V=()=>{if(!$.current||!U.current)return;const O=$.current.offsetWidth,P=U.current.offsetWidth;if(O!==0&&P!==0){const{gap:Z=4}=l;Z*2<P&&i(P-Z*
|