(self.webpackChunkant_design_pro=self.webpackChunkant_design_pro||[]).push([[3400],{49:function(R,u,n){"use strict";n.r(u),n.d(u,{default:function(){return F}});var p=n(11849),M=n(43185),h=n(93009),D=n(57663),f=n(71577),v=n(2824),g=n(67294),S=n(84391),i=n(96486),t=n(9669),e=n.n(t),d=n(39428),a=n(3182),j=n(48971);function Z(C){return y.apply(this,arguments)}function y(){return y=(0,a.Z)((0,d.Z)().mark(function C(P){return(0,d.Z)().wrap(function(r){for(;;)switch(r.prev=r.next){case 0:return r.abrupt("return",(0,j.WY)("/kitchen/api/systemconfig/GetCosRequestSignURL",{method:"POST",data:P}));case 1:case"end":return r.stop()}},C)})),y.apply(this,arguments)}var m=n(85893),A=function(){var P=(0,g.useState)({domain:"",fileUrl:"",param:"",allUrl:"",seeUrl:""}),E=(0,v.Z)(P,2),r=E[0],I=E[1],G={beforeUpload:function(o){var s=o.name.lastIndexOf("."),l=o.name.substr(s+1);Z({directory:"adv",fileExtension:l,method:"PUT"}).then(function(x){I(x)})},name:"file",showUploadList:!1,multiple:!1,accept:".png, .jpg, .jpeg, .gif",action:r.fileUrl+"?"+r.param,headers:{"Content-Type":"application/octet-stream"},onStart:function(o){console.log("onStart",o,o.name)},onSuccess:function(o,s){console.log("onSuccess",o,s),that.props.getData("/cos/bb/21aa1.jpg")},onProgress:function(o,s){var l=o.percent;console.log("onProgress","".concat(l,"%"),s.name)},onError:function(o){console.log("onError",o)},customRequest:function(o){var s=o.action,l=o.file,x=o.headers,w=o.onError,K=o.onProgress,W=o.onSuccess,B=o.withCredentials,U=new FileReader;U.readAsArrayBuffer(l);var T=null;return U.onload=function(L){T=L.target.result,e().put(s,T,{withCredentials:B,headers:x,onUploadProgress:function(b){var N=b.total,V=b.loaded;K({percent:Math.round(V/N*100).toFixed(2)},l)}}).then(function(O){W(O,l)}).catch(w)},{abort:function(){console.log("upload progress is aborted.")}}}};return(0,m.jsx)("div",{children:(0,m.jsx)(h.Z,(0,p.Z)((0,p.Z)({},G),{},{children:(0,m.jsx)(f.Z,{icon:(0,m.jsx)(S.Z,{}),children:"\u4E0A\u4F20"})}))})},F=A},64217:function(R,u,n){"use strict";n.d(u,{Z:function(){return S}});var p=n(28991),M=`accept acceptCharset accessKey action allowFullScreen allowTransparency alt async autoComplete autoFocus autoPlay capture cellPadding cellSpacing challenge charSet checked classID className colSpan cols content contentEditable contextMenu controls coords crossOrigin data dateTime default defer dir disabled download draggable encType form formAction formEncType formMethod formNoValidate formTarget frameBorder headers height hidden high href hrefLang htmlFor httpEquiv icon id inputMode integrity is keyParams keyType kind label lang list loop low manifest marginHeight marginWidth max maxLength media mediaGroup method min minLength multiple muted name noValidate nonce open optimum pattern placeholder poster preload radioGroup readOnly rel required reversed role rowSpan rows sandbox scope scoped scrolling seamless selected shape size sizes span spellCheck src srcDoc srcLang srcSet start step style summary tabIndex target title type useMap value width wmode wrap`,h=`onCopy onCut onPaste onCompositionEnd onCompositionStart onCompositionUpdate onKeyDown onKeyPress onKeyUp onFocus onBlur onChange onInput onSubmit onClick onContextMenu onDoubleClick onDrag onDragEnd onDragEnter onDragExit onDragLeave onDragOver onDragStart onDrop onMouseDown onMouseEnter onMouseLeave onMouseMove onMouseOut onMouseOver onMouseUp onSelect onTouchCancel onTouchEnd onTouchMove onTouchStart onScroll onWheel onAbort onCanPlay onCanPlayThrough onDurationChange onEmptied onEncrypted onEnded onError onLoadedData onLoadedMetadata onLoadStart onPause onPlay onPlaying onProgress onRateChange onSeeked onSeeking onStalled onSuspend onTimeUpdate onVolumeChange onWaiting onLoad onError`,D="".concat(M," ").concat(h).split(/[\s\n]+/),f="aria-",v="data-";function g(i,t){return i.indexOf(t)===0}function S(i){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,e;t===!1?e={aria:!0,data:!0,attr:!0}:t===!0?e={aria:!0}:e=(0,p.Z)({},t);var d={};return Object.keys(i).forEach(function(a){(e.aria&&(a==="role"||g(a,f))||e.data&&g(a,v)||e.attr&&D.includes(a))&&(d[a]=i[a])}),d}}}]);