-
Notifications
You must be signed in to change notification settings - Fork 0
/
14137.dcf83c6f.async.js
4 lines (4 loc) · 12.1 KB
/
14137.dcf83c6f.async.js
1
2
3
4
"use strict";(self.webpackChunkantd=self.webpackChunkantd||[]).push([[14137],{614137:function(to,ut,r){r.d(ut,{Z:function(){return qt}});var ft=r(242122),u=r.n(ft),vt=r(627424),W=r.n(vt),gt=r(670215),D=r.n(gt),f=r(667294),mt=r(298906),ht=r.n(mt),pt=r(294184),O=r.n(pt),q=r(82225),xt=r(982673),Ct=r(658192),St=r(745171),V=r(73287),k=f.createContext(void 0),bt=k.Provider,_=k,Bt=r(238416),o=r.n(Bt),yt=r(518475),Pt=r(707898),It=r(879587),Et=r(476167),tt=r.n(Et),s=r(785893),jt=function(t){var e=t.icon,d=t.description,l=t.prefixCls,v=t.className,c=(0,s.jsx)("div",{className:"".concat(l,"-icon"),children:(0,s.jsx)(tt(),{})});return(0,s.jsx)("div",{onClick:t.onClick,onFocus:t.onFocus,onMouseEnter:t.onMouseEnter,onMouseLeave:t.onMouseLeave,className:O()(v,"".concat(l,"-content")),children:e||d?(0,s.jsxs)(s.Fragment,{children:[e&&(0,s.jsx)("div",{className:"".concat(l,"-icon"),children:e}),d&&(0,s.jsx)("div",{className:"".concat(l,"-description"),children:d})]}):c})},Nt=(0,f.memo)(jt),I=r(615624),ot=r(548073),Tt=r(691999),Ot=r(115947),zt=r(286665),Rt=r(986943),Ft=function(t){return t===0?0:t-Math.sqrt(Math.pow(t,2)/2)},nt=Ft,Mt=function(t){var e,d=t.componentCls,l=t.floatButtonSize,v=t.motionDurationSlow,c=t.motionEaseInOutCirc,i="".concat(d,"-group"),g=new I.E4("antFloatButtonMoveDownIn",{"0%":{transform:"translate3d(0, ".concat((0,I.bf)(l),", 0)"),transformOrigin:"0 0",opacity:0},"100%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1}}),n=new I.E4("antFloatButtonMoveDownOut",{"0%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1},"100%":{transform:"translate3d(0, ".concat((0,I.bf)(l),", 0)"),transformOrigin:"0 0",opacity:0}});return[o()({},"".concat(i,"-wrap"),u()({},(0,Ot.R)("".concat(i,"-wrap"),g,n,v,!0))),o()({},"".concat(i,"-wrap"),(e={},o()(e,`
&`.concat(i,`-wrap-enter,
&`).concat(i,`-wrap-appear
`),{opacity:0,animationTimingFunction:c}),o()(e,"&".concat(i,"-wrap-leave"),{animationTimingFunction:c}),e))]},Lt=function(t){var e,d,l,v=t.antCls,c=t.componentCls,i=t.floatButtonSize,g=t.margin,n=t.borderRadiusLG,h=t.borderRadiusSM,C=t.badgeOffset,p=t.floatButtonBodyPadding,S=t.calc,x="".concat(c,"-group");return l={},o()(l,x,u()(u()({},(0,ot.Wf)(t)),{},(e={zIndex:99,display:"block",border:"none",position:"fixed",width:i,height:"auto",boxShadow:"none",minHeight:i,insetInlineEnd:t.floatButtonInsetInlineEnd,insetBlockEnd:t.floatButtonInsetBlockEnd,borderRadius:n},o()(e,"".concat(x,"-wrap"),{zIndex:-1,display:"block",position:"relative",marginBottom:g}),o()(e,"&".concat(x,"-rtl"),{direction:"rtl"}),o()(e,c,{position:"static"}),e))),o()(l,"".concat(x,"-circle"),o()({},"".concat(c,"-circle:not(:last-child)"),o()({marginBottom:t.margin},"".concat(c,"-body"),{width:i,height:i,borderRadius:"50%"}))),o()(l,"".concat(x,"-square"),(d={},o()(d,"".concat(c,"-square"),o()({borderRadius:0,padding:0,"&:first-child":{borderStartStartRadius:n,borderStartEndRadius:n},"&:last-child":{borderEndStartRadius:n,borderEndEndRadius:n},"&:not(:last-child)":{borderBottom:"".concat((0,I.bf)(t.lineWidth)," ").concat(t.lineType," ").concat(t.colorSplit)}},"".concat(v,"-badge"),o()({},"".concat(v,"-badge-count"),{top:S(S(p).add(C)).mul(-1).equal(),insetInlineEnd:S(S(p).add(C)).mul(-1).equal()}))),o()(d,"".concat(x,"-wrap"),o()({display:"block",borderRadius:n,boxShadow:t.boxShadowSecondary},"".concat(c,"-square"),o()({boxShadow:"none",marginTop:0,borderRadius:0,padding:p,"&:first-child":{borderStartStartRadius:n,borderStartEndRadius:n},"&:last-child":{borderEndStartRadius:n,borderEndEndRadius:n},"&:not(:last-child)":{borderBottom:"".concat((0,I.bf)(t.lineWidth)," ").concat(t.lineType," ").concat(t.colorSplit)}},"".concat(c,"-body"),{width:t.floatButtonBodySize,height:t.floatButtonBodySize}))),d)),o()(l,"".concat(x,"-circle-shadow"),{boxShadow:"none"}),o()(l,"".concat(x,"-square-shadow"),o()({boxShadow:t.boxShadowSecondary},"".concat(c,"-square"),o()({boxShadow:"none",padding:p},"".concat(c,"-body"),{width:t.floatButtonBodySize,height:t.floatButtonBodySize,borderRadius:h}))),l},Gt=function(t){var e,d,l,v,c,i,g=t.antCls,n=t.componentCls,h=t.floatButtonBodyPadding,C=t.floatButtonIconSize,p=t.floatButtonSize,S=t.borderRadiusLG,x=t.badgeOffset,b=t.dotOffsetInSquare,N=t.dotOffsetInCircle,m=t.calc;return i={},o()(i,n,u()(u()({},(0,ot.Wf)(t)),{},(e={border:"none",position:"fixed",cursor:"pointer",zIndex:99,display:"block",width:p,height:p,insetInlineEnd:t.floatButtonInsetInlineEnd,insetBlockEnd:t.floatButtonInsetBlockEnd,boxShadow:t.boxShadowSecondary,"&-pure":{position:"relative",inset:"auto"},"&:empty":{display:"none"}},o()(e,"".concat(g,"-badge"),o()({width:"100%",height:"100%"},"".concat(g,"-badge-count"),{transform:"translate(0, 0)",transformOrigin:"center",top:m(x).mul(-1).equal(),insetInlineEnd:m(x).mul(-1).equal()})),o()(e,"".concat(n,"-body"),o()({width:"100%",height:"100%",display:"flex",justifyContent:"center",alignItems:"center",transition:"all ".concat(t.motionDurationMid)},"".concat(n,"-content"),o()({overflow:"hidden",textAlign:"center",minHeight:p,display:"flex",flexDirection:"column",justifyContent:"center",alignItems:"center",padding:"".concat((0,I.bf)(m(h).div(2).equal())," ").concat((0,I.bf)(h))},"".concat(n,"-icon"),{textAlign:"center",margin:"auto",width:C,fontSize:C,lineHeight:1}))),e))),o()(i,"".concat(n,"-rtl"),{direction:"rtl"}),o()(i,"".concat(n,"-circle"),(d={height:p,borderRadius:"50%"},o()(d,"".concat(g,"-badge"),o()({},"".concat(g,"-badge-dot"),{top:N,insetInlineEnd:N})),o()(d,"".concat(n,"-body"),{borderRadius:"50%"}),d)),o()(i,"".concat(n,"-square"),(l={height:"auto",minHeight:p,borderRadius:S},o()(l,"".concat(g,"-badge"),o()({},"".concat(g,"-badge-dot"),{top:b,insetInlineEnd:b})),o()(l,"".concat(n,"-body"),{height:"auto",borderRadius:S}),l)),o()(i,"".concat(n,"-default"),o()({backgroundColor:t.floatButtonBackgroundColor,transition:"background-color ".concat(t.motionDurationMid)},"".concat(n,"-body"),o()({backgroundColor:t.floatButtonBackgroundColor,transition:"background-color ".concat(t.motionDurationMid),"&:hover":{backgroundColor:t.colorFillContent}},"".concat(n,"-content"),(v={},o()(v,"".concat(n,"-icon"),{color:t.colorText}),o()(v,"".concat(n,"-description"),{display:"flex",alignItems:"center",lineHeight:(0,I.bf)(t.fontSizeLG),color:t.colorText,fontSize:t.fontSizeSM}),v)))),o()(i,"".concat(n,"-primary"),o()({backgroundColor:t.colorPrimary},"".concat(n,"-body"),o()({backgroundColor:t.colorPrimary,transition:"background-color ".concat(t.motionDurationMid),"&:hover":{backgroundColor:t.colorPrimaryHover}},"".concat(n,"-content"),(c={},o()(c,"".concat(n,"-icon"),{color:t.colorTextLightSolid}),o()(c,"".concat(n,"-description"),{display:"flex",alignItems:"center",lineHeight:(0,I.bf)(t.fontSizeLG),color:t.colorTextLightSolid,fontSize:t.fontSizeSM}),c)))),i},wt=function(t){return{dotOffsetInCircle:nt(t.controlHeightLG/2),dotOffsetInSquare:nt(t.borderRadiusLG)}},at=(0,zt.I$)("FloatButton",function(a){var t=a.colorTextLightSolid,e=a.colorBgElevated,d=a.controlHeightLG,l=a.marginXXL,v=a.marginLG,c=a.fontSize,i=a.fontSizeIcon,g=a.controlItemBgHover,n=a.paddingXXS,h=a.calc,C=(0,Rt.TS)(a,{floatButtonBackgroundColor:e,floatButtonColor:t,floatButtonHoverBackgroundColor:g,floatButtonFontSize:c,floatButtonIconSize:h(i).mul(1.5).equal(),floatButtonSize:d,floatButtonInsetBlockEnd:l,floatButtonInsetInlineEnd:v,floatButtonBodySize:h(d).sub(h(n).mul(2)).equal(),floatButtonBodyPadding:n,badgeOffset:h(n).mul(1.5).equal()});return[Lt(C),Gt(C),(0,Tt.J$)(a),Mt(C)]},wt),et=r(670544),Ht=["prefixCls","className","rootClassName","type","shape","icon","description","tooltip","badge"],J="float-btn",$t=f.forwardRef(function(a,t){var e=a.prefixCls,d=a.className,l=a.rootClassName,v=a.type,c=v===void 0?"default":v,i=a.shape,g=i===void 0?"circle":i,n=a.icon,h=a.description,C=a.tooltip,p=a.badge,S=p===void 0?{}:p,x=D()(a,Ht),b=(0,f.useContext)(V.E_),N=b.getPrefixCls,m=b.direction,G=(0,f.useContext)(_),P=N(J,e),M=(0,et.Z)(P),T=at(P,M),L=W()(T,2),E=L[0],w=L[1],Z=G||g,z=O()(w,M,P,d,l,"".concat(P,"-").concat(c),"".concat(P,"-").concat(Z),o()({},"".concat(P,"-rtl"),m==="rtl")),A=(0,f.useMemo)(function(){return(0,yt.default)(S,["title","children","status","text"])},[S]),H=(0,f.useMemo)(function(){return{prefixCls:P,description:h,icon:n,type:c}},[P,h,n,c]),y=(0,s.jsx)("div",{className:"".concat(P,"-body"),children:(0,s.jsx)(Nt,u()({},H))});if("badge"in a&&(y=(0,s.jsx)(Pt.Z,u()(u()({},A),{},{children:y}))),"tooltip"in a&&(y=(0,s.jsx)(It.Z,{title:C,placement:m==="rtl"?"right":"left",children:y})),!1)var U;return E(a.href?(0,s.jsx)("a",u()(u()({ref:t},x),{},{className:z,children:y})):(0,s.jsx)("button",u()(u()({ref:t},x),{},{className:z,type:"button",children:y})))}),F=$t,Dt=["prefixCls","className","type","shape","visibilityHeight","icon","target","onClick","duration"],Zt=f.forwardRef(function(a,t){var e=a.prefixCls,d=a.className,l=a.type,v=l===void 0?"default":l,c=a.shape,i=c===void 0?"circle":c,g=a.visibilityHeight,n=g===void 0?400:g,h=a.icon,C=h===void 0?(0,s.jsx)(ht(),{}):h,p=a.target,S=a.onClick,x=a.duration,b=x===void 0?450:x,N=D()(a,Dt),m=(0,f.useState)(n===0),G=W()(m,2),P=G[0],M=G[1],T=f.useRef(null);f.useImperativeHandle(t,function(){return{nativeElement:T.current}});var L=function(){return T.current&&T.current.ownerDocument?T.current.ownerDocument:window},E=(0,St.Z)(function(R){var B=(0,xt.Z)(R.target,!0);M(B>=n)});(0,f.useEffect)(function(){var R=p||L,B=R();return E({target:B}),B==null||B.addEventListener("scroll",E),function(){E.cancel(),B==null||B.removeEventListener("scroll",E)}},[p]);var w=function(B){(0,Ct.Z)(0,{getContainer:p||L,duration:b}),S==null||S(B)},Z=(0,f.useContext)(V.E_),z=Z.getPrefixCls,A=z(J,e),H=z(),y=(0,f.useContext)(_),U=y||i,Q=u()({prefixCls:A,icon:C,type:v,shape:U},N);return(0,s.jsx)(q.ZP,{visible:P,motionName:"".concat(H,"-fade"),children:function(B){var Y=B.className;return(0,s.jsx)(F,u()(u()({ref:T},Q),{},{onClick:w,className:O()(d,Y)}))}})}),rt=Zt,At=r(740753),Xt=r.n(At),Wt=r(260869),Vt=["prefixCls","className","style","shape","type","icon","closeIcon","description","trigger","children","onOpenChange","open"],Jt=function(t){var e,d=t.prefixCls,l=t.className,v=t.style,c=t.shape,i=c===void 0?"circle":c,g=t.type,n=g===void 0?"default":g,h=t.icon,C=h===void 0?(0,s.jsx)(tt(),{}):h,p=t.closeIcon,S=p===void 0?(0,s.jsx)(Xt(),{}):p,x=t.description,b=t.trigger,N=t.children,m=t.onOpenChange,G=t.open,P=D()(t,Vt),M=(0,f.useContext)(V.E_),T=M.direction,L=M.getPrefixCls,E=L(J,d),w=(0,et.Z)(E),Z=at(E,w),z=W()(Z,2),A=z[0],H=z[1],y="".concat(E,"-group"),U=O()(y,H,w,l,(e={},o()(e,"".concat(y,"-rtl"),T==="rtl"),o()(e,"".concat(y,"-").concat(i),i),o()(e,"".concat(y,"-").concat(i,"-shadow"),!b),e)),Q=O()(H,"".concat(y,"-wrap")),R=(0,Wt.default)(!1,{value:G}),B=W()(R,2),Y=B[0],K=B[1],ct=f.useRef(null),st=f.useRef(null),kt=f.useMemo(function(){var $={onMouseEnter:function(){K(!0),m==null||m(!0)},onMouseLeave:function(){K(!1),m==null||m(!1)}};return b==="hover"?$:{}},[b]),_t=function(){K(function(j){return m==null||m(!j),!j})},dt=(0,f.useCallback)(function($){var j;if((j=ct.current)!==null&&j!==void 0&&j.contains($.target)){var X;(X=st.current)!==null&&X!==void 0&&X.contains($.target)&&_t();return}K(!1),m==null||m(!1)},[b]);if((0,f.useEffect)(function(){if(b==="click")return document.addEventListener("click",dt),function(){document.removeEventListener("click",dt)}},[b]),!1)var oo;return A((0,s.jsx)(bt,{value:i,children:(0,s.jsx)("div",u()(u()({ref:ct,className:U,style:v},kt),{},{children:b&&["click","hover"].includes(b)?(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(q.ZP,{visible:Y,motionName:"".concat(y,"-wrap"),children:function(j){var X=j.className;return(0,s.jsx)("div",{className:O()(X,Q),children:N})}}),(0,s.jsx)(F,u()({ref:st,type:n,shape:i,icon:Y?S:C,description:x,"aria-label":t["aria-label"]},P))]}):N}))}))},it=(0,f.memo)(Jt),Ut=["backTop"],Yt=["className","items"],lt=function(t){var e=t.backTop,d=D()(t,Ut);return e?(0,s.jsx)(rt,u()(u()({},d),{},{visibilityHeight:0})):(0,s.jsx)(F,u()({},d))},Kt=function(t){var e=t.className,d=t.items,l=D()(t,Yt),v=l.prefixCls,c=f.useContext(V.E_),i=c.getPrefixCls,g=i(J,v),n="".concat(g,"-pure");return d?(0,s.jsx)(it,u()(u()({className:O()(e,n)},l),{},{children:d.map(function(h,C){return(0,s.jsx)(lt,u()({},h),C)})})):(0,s.jsx)(lt,u()({className:O()(e,n)},l))},Qt=Kt;F.BackTop=rt,F.Group=it,F._InternalPanelDoNotUseOrYouWillBeFired=Qt;var qt=F}}]);