-
Notifications
You must be signed in to change notification settings - Fork 0
/
41050.61b5b0a4.async.js
22 lines (22 loc) · 13.2 KB
/
41050.61b5b0a4.async.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
"use strict";(self.webpackChunkantd=self.webpackChunkantd||[]).push([[41050],{941050:function(gn,Z,a){a.r(Z),a.d(Z,{default:function(){return p}});var B=a(627424),I=a.n(B),$=a(459400),e=a.n($),H=a(667294),w=a(857278),R=a(363606),X=a(297937),T=a(98651),V=a(879587),F=a(373656),A=a(11739),J=a(483465),U=a(963918),Y=a(469181),Q=a(432210),E=a(527211),G=a(559372),y=a(329573),j=a(988872),W=a(979331),K=a(7575),k=a(309819),q=a(302559),_=a(242122),N=a.n(_),nn=a(670215),an=a.n(nn),en=a(442662),tn=a.n(en),l=a(785893),b=["options"],ln={scale:1.02,max:8,speed:1500,glare:!0,"max-glare":.8},O=function(o){var h=o.options,c=an()(o,b),C=(0,H.useRef)(null);return(0,H.useEffect)(function(){return C.current&&tn().init(C.current,N()(N()({},ln),h)),function(){var f;(f=C.current)===null||f===void 0||f.vanillaTilt.destroy()}},[]),(0,l.jsx)("div",N()({ref:C},c))},cn=O,r,n,t,i,g,d,u=T.Z._InternalPanelDoNotUseOrYouWillBeFired,m=V.Z._InternalPanelDoNotUseOrYouWillBeFired,s=F.ZP._InternalPanelDoNotUseOrYouWillBeFired,x={cn:{range:"\u8BBE\u7F6E\u8303\u56F4",text:"Ant Design 5.0 \u4F7F\u7528 CSS-in-JS \u6280\u672F\u4EE5\u63D0\u4F9B\u52A8\u6001\u4E0E\u6DF7\u5408\u4E3B\u9898\u7684\u80FD\u529B\u3002\u4E0E\u6B64\u540C\u65F6\uFF0C\u6211\u4EEC\u4F7F\u7528\u7EC4\u4EF6\u7EA7\u522B\u7684 CSS-in-JS \u89E3\u51B3\u65B9\u6848\uFF0C\u8BA9\u4F60\u7684\u5E94\u7528\u83B7\u5F97\u66F4\u597D\u7684\u6027\u80FD\u3002",infoText:"\u4FE1\u606F\u5185\u5BB9\u5C55\u793A",dropdown:"\u4E0B\u62C9\u83DC\u5355",finished:"\u5DF2\u5B8C\u6210",inProgress:"\u8FDB\u884C\u4E2D",waiting:"\u7B49\u5F85\u4E2D",option:"\u9009\u9879",apple:"\u82F9\u679C",banana:"\u9999\u8549",orange:"\u6A58\u5B50",watermelon:"\u897F\u74DC",primary:"\u4E3B\u8981\u6309\u94AE",danger:"\u5371\u9669\u6309\u94AE",default:"\u9ED8\u8BA4\u6309\u94AE",dashed:"\u865A\u7EBF\u6309\u94AE",icon:"\u56FE\u6807\u6309\u94AE",hello:"\u4F60\u597D\uFF0CAnt Design!",release:"Ant Design 5.0 \u6B63\u5F0F\u53D1\u5E03\uFF01"},en:{range:"Set Range",text:"Ant Design 5.0 use CSS-in-JS technology to provide dynamic & mix theme ability. And which use component level CSS-in-JS solution get your application a better performance.",infoText:"Info Text",dropdown:"Dropdown",finished:"Finished",inProgress:"In Progress",waiting:"Waiting",option:"Option",apple:"Apple",banana:"Banana",orange:"Orange",watermelon:"Watermelon",primary:"Primary",danger:"Danger",default:"Default",dashed:"Dashed",icon:"Icon",hello:"Hello, Ant Design!",release:"Ant Design 5.0 is released!"}},S=(0,k.kc)(function(v){var o=v.token,h=v.css,c=o.padding;return{holder:h(r||(r=e()([`
width: 500px;
display: flex;
flex-direction: column;
row-gap: `,`px;
opacity: 0.8;
`])),c),flex:h(n||(n=e()([`
display: flex;
flex-wrap: nowrap;
column-gap: `,`px;
`])),c),ptg_20:h(t||(t=e()([`
flex: 0 1 20%;
`]))),ptg_none:h(i||(i=e()([`
flex: none;
`]))),block:h(g||(g=e()([`
background-color: `,`;
padding: `,"px ",`px;
border-radius: `,`px;
border: 1px solid `,`;
`])),o.colorBgContainer,o.paddingXS,o.paddingSM,o.borderRadius,o.colorBorder),noMargin:h(d||(d=e()([`
margin: 0;
`])))}}),M=function(){var o=(0,q.Z)(x),h=I()(o,1),c=h[0],C=S(),f=C.styles;return(0,l.jsxs)(cn,{options:{max:20,glare:!0,scale:1},className:f.holder,children:[(0,l.jsx)(u,{title:"Ant Design 5.0",width:"100%",children:c.text}),(0,l.jsx)(A.Z,{message:c.infoText,type:"info"}),(0,l.jsxs)("div",{className:f.flex,children:[(0,l.jsx)(J.Z,{style:{flex:"none"}}),(0,l.jsx)("div",{style:{flex:"none"},children:(0,l.jsx)(U.Z.Button,{menu:{items:new Array(5).fill(null).map(function(rn,z){return{key:"opt".concat(z),label:"".concat(c.option," ").concat(z)}})},children:c.dropdown})}),(0,l.jsx)(Y.Z,{style:{flex:"auto"},mode:"multiple",maxTagCount:"responsive",defaultValue:[{value:"apple"},{value:"banana"}],options:[{value:"apple",label:c.apple},{value:"banana",label:c.banana},{value:"orange",label:c.orange},{value:"watermelon",label:c.watermelon}]}),(0,l.jsx)(Q.Z,{style:{flex:"none",width:120}})]}),(0,l.jsx)(E.Z,{style:{margin:0},percent:100,strokeColor:{"0%":"#108ee9","100%":"#87d068"}}),(0,l.jsx)(E.Z,{style:{margin:0},percent:33,status:"exception"}),(0,l.jsx)(G.Z,{current:1,items:[{title:c.finished},{title:c.inProgress},{title:c.waiting}]}),(0,l.jsx)("div",{className:f.block,children:(0,l.jsx)(y.Z,{style:{marginInline:20},range:!0,marks:{0:"0\xB0C",26:"26\xB0C",37:"37\xB0C",100:{style:{color:"#f50"},label:(0,l.jsx)("strong",{children:"100\xB0C"})}},defaultValue:[26,37]})}),(0,l.jsxs)("div",{className:f.flex,children:[(0,l.jsx)(j.ZP,{className:f.ptg_20,type:"primary",children:c.primary}),(0,l.jsx)(j.ZP,{className:f.ptg_20,type:"primary",danger:!0,children:c.danger}),(0,l.jsx)(j.ZP,{className:f.ptg_20,children:c.default}),(0,l.jsx)(j.ZP,{className:f.ptg_20,type:"dashed",children:c.dashed}),(0,l.jsx)(j.ZP,{className:f.ptg_20,icon:(0,l.jsx)(w.Z,{}),children:c.icon})]}),(0,l.jsx)("div",{className:f.block,children:(0,l.jsxs)("div",{className:f.flex,children:[(0,l.jsx)(W.Z,{className:f.ptg_none,defaultChecked:!0,checkedChildren:(0,l.jsx)(R.Z,{}),unCheckedChildren:(0,l.jsx)(X.Z,{})}),(0,l.jsx)(K.Z.Group,{className:f.ptg_none,options:[c.apple,c.banana,c.orange],defaultValue:[c.apple]})]})}),(0,l.jsx)("div",{children:(0,l.jsx)(s,{content:c.release,type:"success"})}),(0,l.jsx)(m,{title:c.hello,placement:"topLeft",className:f.noMargin}),(0,l.jsx)(A.Z,{message:"Ant Design love you!",type:"success"})]})},p=M},979331:function(gn,Z,a){a.d(Z,{Z:function(){return cn}});var B=a(242122),I=a.n(B),$=a(238416),e=a.n($),H=a(627424),w=a.n(H),R=a(670215),X=a.n(R),T=a(667294),V=a(100628),F=a.n(V),A=a(294184),J=a.n(A),U=a(33413),Y=a(189265),Q=a(73287),E=a(147315),G=a(947170),y=a(615624),j=a(510274),W=a(548073),K=a(286665),k=a(986943),q=function(n){var t,i,g,d,u,m=n.componentCls,s=n.trackHeightSM,x=n.trackPadding,S=n.trackMinWidthSM,M=n.innerMinMarginSM,p=n.innerMaxMarginSM,v=n.handleSizeSM,o=n.calc,h="".concat(m,"-inner"),c=(0,y.bf)(o(v).add(o(x).mul(2)).equal()),C=(0,y.bf)(o(p).mul(2).equal());return e()({},m,e()({},"&".concat(m,"-small"),(u={minWidth:S,height:s,lineHeight:(0,y.bf)(s)},e()(u,"".concat(m,"-inner"),(t={paddingInlineStart:p,paddingInlineEnd:M},e()(t,"".concat(h,"-checked"),{marginInlineStart:"calc(-100% + ".concat(c," - ").concat(C,")"),marginInlineEnd:"calc(100% - ".concat(c," + ").concat(C,")")}),e()(t,"".concat(h,"-unchecked"),{marginTop:o(s).mul(-1).equal(),marginInlineStart:0,marginInlineEnd:0}),t)),e()(u,"".concat(m,"-handle"),{width:v,height:v}),e()(u,"".concat(m,"-loading-icon"),{top:o(o(v).sub(n.switchLoadingIconSize)).div(2).equal(),fontSize:n.switchLoadingIconSize}),e()(u,"&".concat(m,"-checked"),(g={},e()(g,"".concat(m,"-inner"),(i={paddingInlineStart:M,paddingInlineEnd:p},e()(i,"".concat(h,"-checked"),{marginInlineStart:0,marginInlineEnd:0}),e()(i,"".concat(h,"-unchecked"),{marginInlineStart:"calc(100% - ".concat(c," + ").concat(C,")"),marginInlineEnd:"calc(-100% + ".concat(c," - ").concat(C,")")}),i)),e()(g,"".concat(m,"-handle"),{insetInlineStart:"calc(100% - ".concat((0,y.bf)(o(v).add(x).equal()),")")}),g)),e()(u,"&:not(".concat(m,"-disabled):active"),(d={},e()(d,"&:not(".concat(m,"-checked) ").concat(h),e()({},"".concat(h,"-unchecked"),{marginInlineStart:o(n.marginXXS).div(2).equal(),marginInlineEnd:o(n.marginXXS).mul(-1).div(2).equal()})),e()(d,"&".concat(m,"-checked ").concat(h),e()({},"".concat(h,"-checked"),{marginInlineStart:o(n.marginXXS).mul(-1).div(2).equal(),marginInlineEnd:o(n.marginXXS).div(2).equal()})),d)),u)))},_=function(n){var t,i=n.componentCls,g=n.handleSize,d=n.calc;return e()({},i,(t={},e()(t,"".concat(i,"-loading-icon").concat(n.iconCls),{position:"relative",top:d(d(g).sub(n.fontSize)).div(2).equal(),color:n.switchLoadingIconColor,verticalAlign:"top"}),e()(t,"&".concat(i,"-checked ").concat(i,"-loading-icon"),{color:n.switchColor}),t))},N=function(n){var t,i,g=n.componentCls,d=n.trackPadding,u=n.handleBg,m=n.handleShadow,s=n.handleSize,x=n.calc,S="".concat(g,"-handle");return e()({},g,(i={},e()(i,S,{position:"absolute",top:d,insetInlineStart:d,width:s,height:s,transition:"all ".concat(n.switchDuration," ease-in-out"),"&::before":{position:"absolute",top:0,insetInlineEnd:0,bottom:0,insetInlineStart:0,backgroundColor:u,borderRadius:x(s).div(2).equal(),boxShadow:m,transition:"all ".concat(n.switchDuration," ease-in-out"),content:'""'}}),e()(i,"&".concat(g,"-checked ").concat(S),{insetInlineStart:"calc(100% - ".concat((0,y.bf)(x(s).add(d).equal()),")")}),e()(i,"&:not(".concat(g,"-disabled):active"),(t={},e()(t,"".concat(S,"::before"),{insetInlineEnd:n.switchHandleActiveInset,insetInlineStart:0}),e()(t,"&".concat(g,"-checked ").concat(S,"::before"),{insetInlineEnd:0,insetInlineStart:n.switchHandleActiveInset}),t)),i))},nn=function(n){var t,i,g,d,u=n.componentCls,m=n.trackHeight,s=n.trackPadding,x=n.innerMinMargin,S=n.innerMaxMargin,M=n.handleSize,p=n.calc,v="".concat(u,"-inner"),o=(0,y.bf)(p(M).add(p(s).mul(2)).equal()),h=(0,y.bf)(p(S).mul(2).equal());return e()({},u,(d={},e()(d,v,(t={display:"block",overflow:"hidden",borderRadius:100,height:"100%",paddingInlineStart:S,paddingInlineEnd:x,transition:"padding-inline-start ".concat(n.switchDuration," ease-in-out, padding-inline-end ").concat(n.switchDuration," ease-in-out")},e()(t,"".concat(v,"-checked, ").concat(v,"-unchecked"),{display:"block",color:n.colorTextLightSolid,fontSize:n.fontSizeSM,transition:"margin-inline-start ".concat(n.switchDuration," ease-in-out, margin-inline-end ").concat(n.switchDuration," ease-in-out"),pointerEvents:"none"}),e()(t,"".concat(v,"-checked"),{marginInlineStart:"calc(-100% + ".concat(o," - ").concat(h,")"),marginInlineEnd:"calc(100% - ".concat(o," + ").concat(h,")")}),e()(t,"".concat(v,"-unchecked"),{marginTop:p(m).mul(-1).equal(),marginInlineStart:0,marginInlineEnd:0}),t)),e()(d,"&".concat(u,"-checked ").concat(v),(i={paddingInlineStart:x,paddingInlineEnd:S},e()(i,"".concat(v,"-checked"),{marginInlineStart:0,marginInlineEnd:0}),e()(i,"".concat(v,"-unchecked"),{marginInlineStart:"calc(100% - ".concat(o," + ").concat(h,")"),marginInlineEnd:"calc(-100% + ".concat(o," - ").concat(h,")")}),i)),e()(d,"&:not(".concat(u,"-disabled):active"),(g={},e()(g,"&:not(".concat(u,"-checked) ").concat(v),e()({},"".concat(v,"-unchecked"),{marginInlineStart:p(s).mul(2).equal(),marginInlineEnd:p(s).mul(-1).mul(2).equal()})),e()(g,"&".concat(u,"-checked ").concat(v),e()({},"".concat(v,"-checked"),{marginInlineStart:p(s).mul(-1).mul(2).equal(),marginInlineEnd:p(s).mul(2).equal()})),g)),d))},an=function(n){var t,i=n.componentCls,g=n.trackHeight,d=n.trackMinWidth;return e()({},i,I()(I()(I()({},(0,W.Wf)(n)),{},e()({position:"relative",display:"inline-block",boxSizing:"border-box",minWidth:d,height:g,lineHeight:"".concat((0,y.bf)(g)),verticalAlign:"middle",background:n.colorTextQuaternary,border:"0",borderRadius:100,cursor:"pointer",transition:"all ".concat(n.motionDurationMid),userSelect:"none"},"&:hover:not(".concat(i,"-disabled)"),{background:n.colorTextTertiary}),(0,W.Qy)(n)),{},(t={},e()(t,"&".concat(i,"-checked"),e()({background:n.switchColor},"&:hover:not(".concat(i,"-disabled)"),{background:n.colorPrimaryHover})),e()(t,"&".concat(i,"-loading, &").concat(i,"-disabled"),{cursor:"not-allowed",opacity:n.switchDisabledOpacity,"*":{boxShadow:"none",cursor:"not-allowed"}}),e()(t,"&".concat(i,"-rtl"),{direction:"rtl"}),t)))},en=function(n){var t=n.fontSize,i=n.lineHeight,g=n.controlHeight,d=n.colorWhite,u=t*i,m=g/2,s=2,x=u-s*2,S=m-s*2;return{trackHeight:u,trackHeightSM:m,trackMinWidth:x*2+s*4,trackMinWidthSM:S*2+s*2,trackPadding:s,handleBg:d,handleSize:x,handleSizeSM:S,handleShadow:"0 2px 4px 0 ".concat(new j.C("#00230b").setAlpha(.2).toRgbString()),innerMinMargin:x/2,innerMaxMargin:x+s+s*2,innerMinMarginSM:S/2,innerMaxMarginSM:S+s+s*2}},tn=(0,K.I$)("Switch",function(r){var n=(0,k.TS)(r,{switchDuration:r.motionDurationMid,switchColor:r.colorPrimary,switchDisabledOpacity:r.opacityLoading,switchLoadingIconSize:r.calc(r.fontSizeIcon).mul(.75).equal(),switchLoadingIconColor:"rgba(0, 0, 0, ".concat(r.opacityLoading,")"),switchHandleActiveInset:"-30%"});return[an(n),nn(n),N(n),_(n),q(n)]},en),l=a(260869),b=a(785893),ln=["prefixCls","size","disabled","loading","className","rootClassName","style","checked","value","defaultChecked","defaultValue","onChange"],O=T.forwardRef(function(r,n){var t,i=r.prefixCls,g=r.size,d=r.disabled,u=r.loading,m=r.className,s=r.rootClassName,x=r.style,S=r.checked,M=r.value,p=r.defaultChecked,v=r.defaultValue,o=r.onChange,h=X()(r,ln),c=(0,l.default)(!1,{value:S!=null?S:M,defaultValue:p!=null?p:v}),C=w()(c,2),f=C[0],rn=C[1],z=T.useContext(Q.E_),hn=z.getPrefixCls,un=z.direction,D=z.switch,vn=T.useContext(E.Z),mn=(d!=null?d:vn)||u,P=hn("switch",i),Sn=(0,b.jsx)("div",{className:"".concat(P,"-handle"),children:u&&(0,b.jsx)(F(),{className:"".concat(P,"-loading-icon")})}),fn=tn(P),dn=w()(fn,2),pn=dn[0],xn=dn[1],Cn=(0,G.Z)(g),yn=J()(D==null?void 0:D.className,(t={},e()(t,"".concat(P,"-small"),Cn==="small"),e()(t,"".concat(P,"-loading"),u),e()(t,"".concat(P,"-rtl"),un==="rtl"),t),m,s,xn),In=I()(I()({},D==null?void 0:D.style),x),Mn=function(){for(var sn=arguments.length,on=new Array(sn),L=0;L<sn;L++)on[L]=arguments[L];rn(on[0]),o==null||o.apply(void 0,on)};return pn((0,b.jsx)(Y.Z,{component:"Switch",children:(0,b.jsx)(U.Z,I()(I()({},h),{},{checked:f,onChange:Mn,prefixCls:P,className:yn,style:In,disabled:mn,ref:n,loadingIcon:Sn}))}))});O.__ANT_SWITCH=!0;var cn=O}}]);