@fle-ui/next 1.0.0-alpha.12 → 1.0.0-alpha.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.history/package_20211011190148.json +141 -0
- package/.history/package_20211011193053.json +141 -0
- package/dist/@fle-ui/next.css +2 -2
- package/dist/@fle-ui/next.css.map +1 -1
- package/dist/@fle-ui/next.js +1 -1
- package/dist/@fle-ui/next.min.css +2 -2
- package/dist/@fle-ui/next.min.css.map +1 -1
- package/dist/@fle-ui/next.min.js +1 -1
- package/docs-dist/components__affix__affix.md.js +701 -1
- package/docs-dist/components__affix__affix.md~components__alert__alert.md~components__anchor__anchor.md~components__au~00d1741d.js +22482 -1
- package/docs-dist/components__alert__alert.md.js +942 -1
- package/docs-dist/components__anchor__anchor.md.js +789 -1
- package/docs-dist/components__auto-complete__autoComplete.md.js +1145 -1
- package/docs-dist/components__avatar__avatar.md.js +854 -1
- package/docs-dist/components__back-top__backTop.md.js +581 -1
- package/docs-dist/components__badge__badge.md.js +972 -1
- package/docs-dist/components__breadcrumb__breadcrumb.md.js +914 -1
- package/docs-dist/components__button__button.md.js +1037 -1
- package/docs-dist/components__calendar__calendar.md.js +897 -1
- package/docs-dist/components__card__card.md.js +1106 -1
- package/docs-dist/components__carousel__carousel.md.js +770 -1
- package/docs-dist/components__cascader__cascader.md.js +1378 -1
- package/docs-dist/components__checkbox__checkbox.md.js +876 -1
- package/docs-dist/components__collapse__collapse.md.js +959 -1
- package/docs-dist/components__comment__comment.md.js +586 -1
- package/docs-dist/components__config-provider__configProvider.md.js +1055 -1
- package/docs-dist/components__date-picker__date-picker.md.js +2622 -1
- package/docs-dist/components__descriptions__descriptions.md.js +863 -1
- package/docs-dist/components__divider__divider.md.js +681 -1
- package/docs-dist/components__drawer__drawer.md.js +997 -1
- package/docs-dist/components__dropdown__dropdown.md.js +1170 -1
- package/docs-dist/components__empty__empty.md.js +692 -1
- package/docs-dist/components__form__form.md.js +4099 -1
- package/docs-dist/components__grid__grid.md.js +999 -1
- package/docs-dist/components__icon__icon.md.js +739 -1
- package/docs-dist/components__image__image.md.js +745 -1
- package/docs-dist/components__input-number__inputNumber.md.js +1006 -1
- package/docs-dist/components__input__input.md.js +1579 -1
- package/docs-dist/components__layout__layout.md.js +1220 -1
- package/docs-dist/components__list__list.md.js +1255 -1
- package/docs-dist/components__mentions__mentions.md.js +943 -1
- package/docs-dist/components__menu__menu.md.js +1370 -1
- package/docs-dist/components__message__message.md.js +1223 -1
- package/docs-dist/components__modal__modal.md.js +1808 -1
- package/docs-dist/components__notification__notification.md.js +1192 -1
- package/docs-dist/components__page-header__page-header.md.js +781 -1
- package/docs-dist/components__pagination__pagination.md.js +954 -1
- package/docs-dist/components__popconfirm__popconfirm.md.js +792 -1
- package/docs-dist/components__popover__popover.md.js +665 -1
- package/docs-dist/components__progress__progress.md.js +1139 -1
- package/docs-dist/components__radio__radio.md.js +999 -1
- package/docs-dist/components__rate__rate.md.js +851 -1
- package/docs-dist/components__result__result.md.js +681 -1
- package/docs-dist/components__select__select.md.js +2081 -1
- package/docs-dist/components__slider__slider.md.js +1053 -1
- package/docs-dist/components__space__space.md.js +746 -1
- package/docs-dist/components__spin__spin.md.js +730 -1
- package/docs-dist/components__statistic__statistic.md.js +827 -1
- package/docs-dist/components__steps__steps.md.js +1097 -1
- package/docs-dist/components__switch__switch.md.js +763 -1
- package/docs-dist/components__table__table.md.js +3692 -1
- package/docs-dist/components__tabs__tabs.md.js +1213 -1
- package/docs-dist/components__tag__tag.md.js +779 -1
- package/docs-dist/components__time-picker__time-picker.md.js +1232 -1
- package/docs-dist/components__timeline__timeline.md.js +799 -1
- package/docs-dist/components__tooltip__tooltip.md.js +888 -1
- package/docs-dist/components__transfer__transfer.md.js +1226 -1
- package/docs-dist/components__tree-select__tree-select.md.js +1042 -1
- package/docs-dist/components__typography__typography.md.js +1793 -1
- package/docs-dist/components__upload__upload.md.js +1798 -1
- package/docs-dist/demos_bmurcdaerb.js +603 -1
- package/docs-dist/demos_bmurcdaerb~demos_citsitats~demos_dirg~demos_drac~demos_ecaps~demos_egami~demos_egassem~demos_e~57973d2f.chunk.css +1 -1
- package/docs-dist/demos_bmurcdaerb~demos_citsitats~demos_dirg~demos_drac~demos_ecaps~demos_egami~demos_egassem~demos_e~57973d2f.js +21570 -1
- package/docs-dist/demos_citsitats.js +549 -1
- package/docs-dist/demos_daolpu.chunk.css +1 -1
- package/docs-dist/demos_daolpu.js +22680 -1
- package/docs-dist/demos_dirg.js +47 -1
- package/docs-dist/demos_drac.js +748 -1
- package/docs-dist/demos_ecaps.js +529 -1
- package/docs-dist/demos_egami.js +153 -1
- package/docs-dist/demos_egassem.js +187 -1
- package/docs-dist/demos_egdab.js +872 -1
- package/docs-dist/demos_elbat.chunk.css +1 -1
- package/docs-dist/demos_elbat.js +27626 -1
- package/docs-dist/demos_enilemit.js +627 -1
- package/docs-dist/demos_espalloc.js +705 -1
- package/docs-dist/demos_etar.js +547 -1
- package/docs-dist/demos_etelpmoc-otua.js +613 -1
- package/docs-dist/demos_gat.js +487 -1
- package/docs-dist/demos_hctiws.js +439 -1
- package/docs-dist/demos_ladom.js +791 -1
- package/docs-dist/demos_lesuorac.js +193 -1
- package/docs-dist/demos_mrifnocpop.js +671 -1
- package/docs-dist/demos_mrof.js +3082 -1
- package/docs-dist/demos_nips.js +461 -1
- package/docs-dist/demos_noitacifiton.js +765 -1
- package/docs-dist/demos_noitanigap.js +233 -1
- package/docs-dist/demos_nottub.js +847 -1
- package/docs-dist/demos_nwodpord.js +965 -1
- package/docs-dist/demos_oidar.js +340 -1
- package/docs-dist/demos_pitloot.js +204 -1
- package/docs-dist/demos_pot-kcab.js +62 -1
- package/docs-dist/demos_radnelac.js +285 -1
- package/docs-dist/demos_ratava.js +647 -1
- package/docs-dist/demos_rebmun-tupni.js +209 -1
- package/docs-dist/demos_redacsac.js +576 -1
- package/docs-dist/demos_redaeh-egap.js +761 -1
- package/docs-dist/demos_redils.js +659 -1
- package/docs-dist/demos_redivid.js +167 -1
- package/docs-dist/demos_redivorp-gifnoc.js +2154 -1
- package/docs-dist/demos_refsnart.js +774 -1
- package/docs-dist/demos_rekcip-emit.js +183 -1
- package/docs-dist/demos_rekcip-etad.js +469 -1
- package/docs-dist/demos_revopop.js +335 -1
- package/docs-dist/demos_reward.js +484 -1
- package/docs-dist/demos_rohcna.js +194 -1
- package/docs-dist/demos_sbat.chunk.css +1 -1
- package/docs-dist/demos_sbat.js +22358 -1
- package/docs-dist/demos_snoitnem.js +202 -1
- package/docs-dist/demos_snoitpircsed.js +351 -1
- package/docs-dist/demos_spets.js +910 -1
- package/docs-dist/demos_ssergorp.js +698 -1
- package/docs-dist/demos_tceles.js +1416 -1
- package/docs-dist/demos_tluser.js +530 -1
- package/docs-dist/demos_tnemmoc.js +560 -1
- package/docs-dist/demos_trela.js +341 -1
- package/docs-dist/demos_tsil.js +603 -1
- package/docs-dist/demos_tuoyal.js +872 -1
- package/docs-dist/demos_tupni.js +1245 -1
- package/docs-dist/demos_unem.js +1012 -1
- package/docs-dist/demos_xiffa.js +93 -1
- package/docs-dist/demos_xobkcehc.js +186 -1
- package/docs-dist/demos_yhpargopyt.js +798 -1
- package/docs-dist/demos_ytpme.js +433 -1
- package/docs-dist/docs__document__getting-started.md.js +193 -1
- package/docs-dist/docs__document__introduce.md.js +441 -1
- package/docs-dist/docs__document__practical-projects.md.js +117 -1
- package/docs-dist/docs__index.md.js +27 -1
- package/docs-dist/docs__story__index.md.js +89 -1
- package/docs-dist/dumi_demos.js +456 -1
- package/docs-dist/umi.js +28727 -1
- package/docs-dist/vendors~components__affix__affix.md~components__alert__alert.md~components__anchor__anchor.md~compon~3ba4f4a1.js +2590 -1
- package/docs-dist/vendors~components__affix__affix.md~components__alert__alert.md~components__anchor__anchor.md~compon~ac3aca9a.js +8970 -1
- package/docs-dist/vendors~components__affix__affix.md~components__alert__alert.md~components__anchor__anchor.md~compon~e29e5a37.js +2619 -1
- package/docs-dist/vendors~demos_bmurcdaerb~demos_citsitats~demos_daolpu~demos_dirg~demos_drac~demos_ecaps~demos_egami~~4cc402e9.js +57323 -1
- package/docs-dist/vendors~demos_daolpu~demos_elbat.js +1649 -1
- package/docs-dist/vendors~demos_daolpu~demos_elbat~demos_sbat.js +4169 -1
- package/docs-dist/vendors~demos_gat.js +4673 -1
- package/docs-dist/vendors~demos_ladom.js +1855 -1
- package/docs-dist/vendors~demos_redivorp-gifnoc.js +9666 -1
- package/docs-dist/vendors~demos_sbat.js +1601 -1
- package/docs-dist/vendors~demos_trela.js +1722 -1
- package/docs-dist/vendors~demos_tsil.js +4970 -1
- package/docs-dist/vendors~demos_tuoyal.js +748 -1
- package/docs-dist/vendors~wrappers.js +1360 -1
- package/docs-dist/wrappers.js +21 -1
- package/es/drawer/style/drawer.less +8 -4
- package/es/drawer/style/index.css +1 -1
- package/es/style/themes/default.less +57 -29
- package/lib/drawer/style/drawer.less +8 -4
- package/lib/drawer/style/index.css +1 -1
- package/lib/style/themes/default.less +57 -29
- package/package.json +1 -1
- package/report.html +1 -1
@@ -1 +1,1798 @@
|
|
1
|
-
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([[68],{"6apH":function(e,t,a){"use strict";a.r(t);var l=a("q1tI"),n=a.n(l),r=a("dEAq"),c=a("Zxc8"),o=a("H1Ra"),m=a("JjdP"),d=n.a.memo(m["default"]["upload-basic"].component),i=n.a.memo(m["default"]["upload-avatar"].component),u=n.a.memo(m["default"]["upload-defaultfilelist"].component),E=n.a.memo(m["default"]["upload-picture-card"].component),s=n.a.memo(m["default"]["upload-filelist"].component),p=n.a.memo(m["default"]["upload-drag"].component),f=n.a.memo(m["default"]["upload-directory"].component),h=n.a.memo(m["default"]["upload-upload-manually"].component),b=n.a.memo(m["default"]["upload-upload-png-only"].component),v=n.a.memo(m["default"]["upload-picture-style"].component),k=n.a.memo(m["default"]["upload-preview-file"].component),g=n.a.memo(m["default"]["upload-max-count"].component),w=n.a.memo(m["default"]["upload-transform-file"].component),N=n.a.memo(m["default"]["upload-transform-file"].component),L=n.a.memo(m["default"]["upload-upload-custom-action-icon"].component),x=n.a.memo(m["default"]["upload-drag-sorting"].component),I=n.a.memo(m["default"]["upload-crop-image"].component),y=n.a.memo(m["default"]["upload-customize-progress-bar"].component);t["default"]=e=>(n.a.useEffect((()=>{var t;null!==e&&void 0!==e&&null!==(t=e.location)&&void 0!==t&&t.hash&&r["AnchorLink"].scrollToAnchor(decodeURIComponent(e.location.hash.slice(1)))}),[]),n.a.createElement(n.a.Fragment,null,n.a.createElement(n.a.Fragment,null,n.a.createElement("div",{className:"markdown"},n.a.createElement("h1",{id:"upload-\u4e0a\u4f20"},n.a.createElement(r["AnchorLink"],{to:"#upload-\u4e0a\u4f20","aria-hidden":"true",tabIndex:-1},n.a.createElement("span",{className:"icon icon-link"})),"Upload \u4e0a\u4f20"),n.a.createElement("p",null,"\u6587\u4ef6\u9009\u62e9\u4e0a\u4f20\u548c\u62d6\u62fd\u4e0a\u4f20\u63a7\u4ef6\u3002"),n.a.createElement("h2",{id:"\u4f55\u65f6\u4f7f\u7528"},n.a.createElement(r["AnchorLink"],{to:"#\u4f55\u65f6\u4f7f\u7528","aria-hidden":"true",tabIndex:-1},n.a.createElement("span",{className:"icon icon-link"})),"\u4f55\u65f6\u4f7f\u7528"),n.a.createElement("p",null,"\u4e0a\u4f20\u662f\u5c06\u4fe1\u606f\uff08\u7f51\u9875\u3001\u6587\u5b57\u3001\u56fe\u7247\u3001\u89c6\u9891\u7b49\uff09\u901a\u8fc7\u7f51\u9875\u6216\u8005\u4e0a\u4f20\u5de5\u5177\u53d1\u5e03\u5230\u8fdc\u7a0b\u670d\u52a1\u5668\u4e0a\u7684\u8fc7\u7a0b\u3002"),n.a.createElement("ul",null,n.a.createElement("li",null,"\u5f53\u9700\u8981\u4e0a\u4f20\u4e00\u4e2a\u6216\u4e00\u4e9b\u6587\u4ef6\u65f6\u3002"),n.a.createElement("li",null,"\u5f53\u9700\u8981\u5c55\u73b0\u4e0a\u4f20\u7684\u8fdb\u5ea6\u65f6\u3002"),n.a.createElement("li",null,"\u5f53\u9700\u8981\u4f7f\u7528\u62d6\u62fd\u4ea4\u4e92\u65f6\u3002")),n.a.createElement("h2",{id:"\u4ee3\u7801\u6f14\u793a"},n.a.createElement(r["AnchorLink"],{to:"#\u4ee3\u7801\u6f14\u793a","aria-hidden":"true",tabIndex:-1},n.a.createElement("span",{className:"icon icon-link"})),"\u4ee3\u7801\u6f14\u793a"),n.a.createElement("h3",{id:"\u57fa\u672c\u7528\u6cd5"},n.a.createElement(r["AnchorLink"],{to:"#\u57fa\u672c\u7528\u6cd5","aria-hidden":"true",tabIndex:-1},n.a.createElement("span",{className:"icon icon-link"})),"\u57fa\u672c\u7528\u6cd5")),n.a.createElement(c["default"],m["default"]["upload-basic"].previewerProps,n.a.createElement(d,null)),n.a.createElement("div",{className:"markdown"},n.a.createElement("h3",{id:"\u7528\u6237\u5934\u50cf"},n.a.createElement(r["AnchorLink"],{to:"#\u7528\u6237\u5934\u50cf","aria-hidden":"true",tabIndex:-1},n.a.createElement("span",{className:"icon icon-link"})),"\u7528\u6237\u5934\u50cf"),n.a.createElement("blockquote",null,n.a.createElement("p",null,n.a.createElement("code",null,"beforeUpload")," \u7684\u8fd4\u56de\u503c\u53ef\u4ee5\u662f\u4e00\u4e2a Promise \u4ee5\u652f\u6301\u5f02\u6b65\u5904\u7406\uff0c\u5982\u670d\u52a1\u7aef\u6821\u9a8c\u7b49\uff1a",n.a.createElement(r["Link"],{to:"https://upload-react-component.vercel.app/demo/before-upload#beforeupload"},"\u793a\u4f8b"),"\u3002"))),n.a.createElement(c["default"],m["default"]["upload-avatar"].previewerProps,n.a.createElement(i,null)),n.a.createElement("div",{className:"markdown"},n.a.createElement("h3",{id:"\u5df2\u4e0a\u4f20\u7684\u6587\u4ef6\u5217\u8868"},n.a.createElement(r["AnchorLink"],{to:"#\u5df2\u4e0a\u4f20\u7684\u6587\u4ef6\u5217\u8868","aria-hidden":"true",tabIndex:-1},n.a.createElement("span",{className:"icon icon-link"})),"\u5df2\u4e0a\u4f20\u7684\u6587\u4ef6\u5217\u8868")),n.a.createElement(c["default"],m["default"]["upload-defaultfilelist"].previewerProps,n.a.createElement(u,null)),n.a.createElement("div",{className:"markdown"},n.a.createElement("h3",{id:"\u7167\u7247\u5899"},n.a.createElement(r["AnchorLink"],{to:"#\u7167\u7247\u5899","aria-hidden":"true",tabIndex:-1},n.a.createElement("span",{className:"icon icon-link"})),"\u7167\u7247\u5899")),n.a.createElement(c["default"],m["default"]["upload-picture-card"].previewerProps,n.a.createElement(E,null)),n.a.createElement("div",{className:"markdown"},n.a.createElement("h3",{id:"\u5b8c\u5168\u63a7\u5236\u7684\u4e0a\u4f20\u5217\u8868"},n.a.createElement(r["AnchorLink"],{to:"#\u5b8c\u5168\u63a7\u5236\u7684\u4e0a\u4f20\u5217\u8868","aria-hidden":"true",tabIndex:-1},n.a.createElement("span",{className:"icon icon-link"})),"\u5b8c\u5168\u63a7\u5236\u7684\u4e0a\u4f20\u5217\u8868")),n.a.createElement(c["default"],m["default"]["upload-filelist"].previewerProps,n.a.createElement(s,null)),n.a.createElement("div",{className:"markdown"},n.a.createElement("h3",{id:"\u62d6\u62fd\u4e0a\u4f20"},n.a.createElement(r["AnchorLink"],{to:"#\u62d6\u62fd\u4e0a\u4f20","aria-hidden":"true",tabIndex:-1},n.a.createElement("span",{className:"icon icon-link"})),"\u62d6\u62fd\u4e0a\u4f20")),n.a.createElement(c["default"],m["default"]["upload-drag"].previewerProps,n.a.createElement(p,null)),n.a.createElement("div",{className:"markdown"},n.a.createElement("h3",{id:"\u6587\u4ef6\u5939\u4e0a\u4f20"},n.a.createElement(r["AnchorLink"],{to:"#\u6587\u4ef6\u5939\u4e0a\u4f20","aria-hidden":"true",tabIndex:-1},n.a.createElement("span",{className:"icon icon-link"})),"\u6587\u4ef6\u5939\u4e0a\u4f20")),n.a.createElement(c["default"],m["default"]["upload-directory"].previewerProps,n.a.createElement(f,null)),n.a.createElement("div",{className:"markdown"},n.a.createElement("h3",{id:"\u624b\u52a8\u4e0a\u4f20"},n.a.createElement(r["AnchorLink"],{to:"#\u624b\u52a8\u4e0a\u4f20","aria-hidden":"true",tabIndex:-1},n.a.createElement("span",{className:"icon icon-link"})),"\u624b\u52a8\u4e0a\u4f20")),n.a.createElement(c["default"],m["default"]["upload-upload-manually"].previewerProps,n.a.createElement(h,null)),n.a.createElement("div",{className:"markdown"},n.a.createElement("h3",{id:"\u53ea\u4e0a\u4f20-png-\u56fe\u7247"},n.a.createElement(r["AnchorLink"],{to:"#\u53ea\u4e0a\u4f20-png-\u56fe\u7247","aria-hidden":"true",tabIndex:-1},n.a.createElement("span",{className:"icon icon-link"})),"\u53ea\u4e0a\u4f20 png \u56fe\u7247")),n.a.createElement(c["default"],m["default"]["upload-upload-png-only"].previewerProps,n.a.createElement(b,null)),n.a.createElement("div",{className:"markdown"},n.a.createElement("h3",{id:"\u56fe\u7247\u5217\u8868\u6837\u5f0f"},n.a.createElement(r["AnchorLink"],{to:"#\u56fe\u7247\u5217\u8868\u6837\u5f0f","aria-hidden":"true",tabIndex:-1},n.a.createElement("span",{className:"icon icon-link"})),"\u56fe\u7247\u5217\u8868\u6837\u5f0f")),n.a.createElement(c["default"],m["default"]["upload-picture-style"].previewerProps,n.a.createElement(v,null)),n.a.createElement("div",{className:"markdown"},n.a.createElement("h3",{id:"\u81ea\u5b9a\u4e49\u9884\u89c8"},n.a.createElement(r["AnchorLink"],{to:"#\u81ea\u5b9a\u4e49\u9884\u89c8","aria-hidden":"true",tabIndex:-1},n.a.createElement("span",{className:"icon icon-link"})),"\u81ea\u5b9a\u4e49\u9884\u89c8")),n.a.createElement(c["default"],m["default"]["upload-preview-file"].previewerProps,n.a.createElement(k,null)),n.a.createElement("div",{className:"markdown"},n.a.createElement("h3",{id:"\u9650\u5236\u6570\u91cf"},n.a.createElement(r["AnchorLink"],{to:"#\u9650\u5236\u6570\u91cf","aria-hidden":"true",tabIndex:-1},n.a.createElement("span",{className:"icon icon-link"})),"\u9650\u5236\u6570\u91cf")),n.a.createElement(c["default"],m["default"]["upload-max-count"].previewerProps,n.a.createElement(g,null)),n.a.createElement("div",{className:"markdown"},n.a.createElement("h3",{id:"\u4e0a\u4f20\u524d\u8f6c\u6362\u6587\u4ef6"},n.a.createElement(r["AnchorLink"],{to:"#\u4e0a\u4f20\u524d\u8f6c\u6362\u6587\u4ef6","aria-hidden":"true",tabIndex:-1},n.a.createElement("span",{className:"icon icon-link"})),"\u4e0a\u4f20\u524d\u8f6c\u6362\u6587\u4ef6")),n.a.createElement(c["default"],m["default"]["upload-transform-file"].previewerProps,n.a.createElement(w,null)),n.a.createElement("div",{className:"markdown"},n.a.createElement("h3",{id:"\u963f\u91cc\u4e91-oss"},n.a.createElement(r["AnchorLink"],{to:"#\u963f\u91cc\u4e91-oss","aria-hidden":"true",tabIndex:-1},n.a.createElement("span",{className:"icon icon-link"})),"\u963f\u91cc\u4e91 OSS")),n.a.createElement(c["default"],m["default"]["upload-transform-file"].previewerProps,n.a.createElement(N,null)),n.a.createElement("div",{className:"markdown"},n.a.createElement("h3",{id:"\u81ea\u5b9a\u4e49\u4ea4\u4e92\u56fe\u6807"},n.a.createElement(r["AnchorLink"],{to:"#\u81ea\u5b9a\u4e49\u4ea4\u4e92\u56fe\u6807","aria-hidden":"true",tabIndex:-1},n.a.createElement("span",{className:"icon icon-link"})),"\u81ea\u5b9a\u4e49\u4ea4\u4e92\u56fe\u6807")),n.a.createElement(c["default"],m["default"]["upload-upload-custom-action-icon"].previewerProps,n.a.createElement(L,null)),n.a.createElement("div",{className:"markdown"},n.a.createElement("h3",{id:"\u4e0a\u4f20\u5217\u8868\u62d6\u62fd\u6392\u5e8f"},n.a.createElement(r["AnchorLink"],{to:"#\u4e0a\u4f20\u5217\u8868\u62d6\u62fd\u6392\u5e8f","aria-hidden":"true",tabIndex:-1},n.a.createElement("span",{className:"icon icon-link"})),"\u4e0a\u4f20\u5217\u8868\u62d6\u62fd\u6392\u5e8f")),n.a.createElement(c["default"],m["default"]["upload-drag-sorting"].previewerProps,n.a.createElement(x,null)),n.a.createElement("div",{className:"markdown"},n.a.createElement("h3",{id:"\u4e0a\u4f20\u524d\u88c1\u5207\u56fe\u7247"},n.a.createElement(r["AnchorLink"],{to:"#\u4e0a\u4f20\u524d\u88c1\u5207\u56fe\u7247","aria-hidden":"true",tabIndex:-1},n.a.createElement("span",{className:"icon icon-link"})),"\u4e0a\u4f20\u524d\u88c1\u5207\u56fe\u7247")),n.a.createElement(c["default"],m["default"]["upload-crop-image"].previewerProps,n.a.createElement(I,null)),n.a.createElement("div",{className:"markdown"},n.a.createElement("h3",{id:"\u81ea\u5b9a\u4e49\u8fdb\u5ea6\u6761\u6837\u5f0f"},n.a.createElement(r["AnchorLink"],{to:"#\u81ea\u5b9a\u4e49\u8fdb\u5ea6\u6761\u6837\u5f0f","aria-hidden":"true",tabIndex:-1},n.a.createElement("span",{className:"icon icon-link"})),"\u81ea\u5b9a\u4e49\u8fdb\u5ea6\u6761\u6837\u5f0f")),n.a.createElement(c["default"],m["default"]["upload-customize-progress-bar"].previewerProps,n.a.createElement(y,null)),n.a.createElement("div",{className:"markdown"},n.a.createElement("h2",{id:"api"},n.a.createElement(r["AnchorLink"],{to:"#api","aria-hidden":"true",tabIndex:-1},n.a.createElement("span",{className:"icon icon-link"})),"API"),n.a.createElement("table",null,n.a.createElement("thead",null,n.a.createElement("tr",null,n.a.createElement("th",null,"\u53c2\u6570"),n.a.createElement("th",null,"\u8bf4\u660e"),n.a.createElement("th",null,"\u7c7b\u578b"),n.a.createElement("th",null,"\u9ed8\u8ba4\u503c"),n.a.createElement("th",null,"\u7248\u672c"))),n.a.createElement("tbody",null,n.a.createElement("tr",null,n.a.createElement("td",null,"accept"),n.a.createElement("td",null,"\u63a5\u53d7\u4e0a\u4f20\u7684\u6587\u4ef6\u7c7b\u578b, \u8be6\u89c1 ",n.a.createElement(r["Link"],{to:"https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input/file#accept"},"input accept Attribute")),n.a.createElement("td",null,"string"),n.a.createElement("td",null,"-"),n.a.createElement("td",null)),n.a.createElement("tr",null,n.a.createElement("td",null,"action"),n.a.createElement("td",null,"\u4e0a\u4f20\u7684\u5730\u5740"),n.a.createElement("td",null,"string | (file) => Promise<string>"),n.a.createElement("td",null,"-"),n.a.createElement("td",null)),n.a.createElement("tr",null,n.a.createElement("td",null,"beforeUpload"),n.a.createElement("td",null,"\u4e0a\u4f20\u6587\u4ef6\u4e4b\u524d\u7684\u94a9\u5b50\uff0c\u53c2\u6570\u4e3a\u4e0a\u4f20\u7684\u6587\u4ef6\uff0c\u82e5\u8fd4\u56de ",n.a.createElement("code",null,"false")," \u5219\u505c\u6b62\u4e0a\u4f20\u3002\u652f\u6301\u8fd4\u56de\u4e00\u4e2a Promise \u5bf9\u8c61\uff0cPromise \u5bf9\u8c61 reject \u65f6\u5219\u505c\u6b62\u4e0a\u4f20\uff0cresolve \u65f6\u5f00\u59cb\u4e0a\u4f20\uff08 resolve \u4f20\u5165 ",n.a.createElement("code",null,"File")," \u6216 ",n.a.createElement("code",null,"Blob")," \u5bf9\u8c61\u5219\u4e0a\u4f20 resolve \u4f20\u5165\u5bf9\u8c61\uff09\uff1b\u4e5f\u53ef\u4ee5\u8fd4\u56de ",n.a.createElement("code",null,"Upload.LIST_IGNORE"),"\uff0c\u6b64\u65f6\u5217\u8868\u4e2d\u5c06\u4e0d\u5c55\u793a\u6b64\u6587\u4ef6\u3002 ",n.a.createElement("strong",null,"\u6ce8\u610f\uff1aIE9 \u4e0d\u652f\u6301\u8be5\u65b9\u6cd5")),n.a.createElement("td",null,"(file, fileList) => boolean | Promise<File> | ",n.a.createElement("code",null,"Upload.LIST_IGNORE")),n.a.createElement("td",null,"-"),n.a.createElement("td",null)),n.a.createElement("tr",null,n.a.createElement("td",null,"customRequest"),n.a.createElement("td",null,"\u901a\u8fc7\u8986\u76d6\u9ed8\u8ba4\u7684\u4e0a\u4f20\u884c\u4e3a\uff0c\u53ef\u4ee5\u81ea\u5b9a\u4e49\u81ea\u5df1\u7684\u4e0a\u4f20\u5b9e\u73b0"),n.a.createElement("td",null,"function"),n.a.createElement("td",null,"-"),n.a.createElement("td",null)),n.a.createElement("tr",null,n.a.createElement("td",null,"data"),n.a.createElement("td",null,"\u4e0a\u4f20\u6240\u9700\u989d\u5916\u53c2\u6570\u6216\u8fd4\u56de\u4e0a\u4f20\u989d\u5916\u53c2\u6570\u7684\u65b9\u6cd5"),n.a.createElement("td",null,"object|(file) => object | Promise<object>"),n.a.createElement("td",null,"-"),n.a.createElement("td",null)),n.a.createElement("tr",null,n.a.createElement("td",null,"defaultFileList"),n.a.createElement("td",null,"\u9ed8\u8ba4\u5df2\u7ecf\u4e0a\u4f20\u7684\u6587\u4ef6\u5217\u8868"),n.a.createElement("td",null,"object[]"),n.a.createElement("td",null,"-"),n.a.createElement("td",null)),n.a.createElement("tr",null,n.a.createElement("td",null,"directory"),n.a.createElement("td",null,"\u652f\u6301\u4e0a\u4f20\u6587\u4ef6\u5939\uff08",n.a.createElement(r["Link"],{to:"https://caniuse.com/#feat=input-file-directory"},"caniuse"),"\uff09"),n.a.createElement("td",null,"boolean"),n.a.createElement("td",null,"false"),n.a.createElement("td",null)),n.a.createElement("tr",null,n.a.createElement("td",null,"disabled"),n.a.createElement("td",null,"\u662f\u5426\u7981\u7528"),n.a.createElement("td",null,"boolean"),n.a.createElement("td",null,"false"),n.a.createElement("td",null)),n.a.createElement("tr",null,n.a.createElement("td",null,"fileList"),n.a.createElement("td",null,"\u5df2\u7ecf\u4e0a\u4f20\u7684\u6587\u4ef6\u5217\u8868\uff08\u53d7\u63a7\uff09\uff0c\u4f7f\u7528\u6b64\u53c2\u6570\u65f6\uff0c\u5982\u679c\u9047\u5230 ",n.a.createElement("code",null,"onChange")," \u53ea\u8c03\u7528\u4e00\u6b21\u7684\u95ee\u9898\uff0c\u8bf7\u53c2\u8003 ",n.a.createElement(r["Link"],{to:"https://github.com/ant-design/ant-design/issues/2423"},"#2423")),n.a.createElement("td",null,n.a.createElement(r["AnchorLink"],{to:"#UploadFile"},"UploadFile"),"[]"),n.a.createElement("td",null,"-"),n.a.createElement("td",null)),n.a.createElement("tr",null,n.a.createElement("td",null,"headers"),n.a.createElement("td",null,"\u8bbe\u7f6e\u4e0a\u4f20\u7684\u8bf7\u6c42\u5934\u90e8\uff0cIE10 \u4ee5\u4e0a\u6709\u6548"),n.a.createElement("td",null,"object"),n.a.createElement("td",null,"-"),n.a.createElement("td",null)),n.a.createElement("tr",null,n.a.createElement("td",null,"iconRender"),n.a.createElement("td",null,"\u81ea\u5b9a\u4e49\u663e\u793a icon"),n.a.createElement("td",null,"(file: UploadFile, listType?: UploadListType) => ReactNode"),n.a.createElement("td",null,"-"),n.a.createElement("td",null)),n.a.createElement("tr",null,n.a.createElement("td",null,"isImageUrl"),n.a.createElement("td",null,"\u81ea\u5b9a\u4e49\u7f29\u7565\u56fe\u662f\u5426\u4f7f\u7528 <img /> \u6807\u7b7e\u8fdb\u884c\u663e\u793a"),n.a.createElement("td",null,"(file: UploadFile) => boolean"),n.a.createElement("td",null,n.a.createElement(r["Link"],{to:"https://github.com/ant-design/ant-design/blob/4ad5830eecfb87471cd8ac588c5d992862b70770/components/upload/utils.tsx#L47-L68"},"(\u5185\u90e8\u5b9e\u73b0)")),n.a.createElement("td",null)),n.a.createElement("tr",null,n.a.createElement("td",null,"itemRender"),n.a.createElement("td",null,"\u81ea\u5b9a\u4e49\u4e0a\u4f20\u5217\u8868\u9879"),n.a.createElement("td",null,"(originNode: ReactElement, file: UploadFile, fileList: object[], actions: ","{"," download: function, preview: function, remove: function ","}",") => React.ReactNode"),n.a.createElement("td",null,"-"),n.a.createElement("td",null,"4.16.0")),n.a.createElement("tr",null,n.a.createElement("td",null,"listType"),n.a.createElement("td",null,"\u4e0a\u4f20\u5217\u8868\u7684\u5185\u5efa\u6837\u5f0f\uff0c\u652f\u6301\u4e09\u79cd\u57fa\u672c\u6837\u5f0f ",n.a.createElement("code",null,"text"),", ",n.a.createElement("code",null,"picture")," \u548c ",n.a.createElement("code",null,"picture-card")),n.a.createElement("td",null,"string"),n.a.createElement("td",null,n.a.createElement("code",null,"text")),n.a.createElement("td",null)),n.a.createElement("tr",null,n.a.createElement("td",null,"maxCount"),n.a.createElement("td",null,"\u9650\u5236\u4e0a\u4f20\u6570\u91cf\u3002\u5f53\u4e3a 1 \u65f6\uff0c\u59cb\u7ec8\u7528\u6700\u65b0\u4e0a\u4f20\u7684\u6587\u4ef6\u4ee3\u66ff\u5f53\u524d\u6587\u4ef6"),n.a.createElement("td",null,"number"),n.a.createElement("td",null,"-"),n.a.createElement("td",null,"4.10.0")),n.a.createElement("tr",null,n.a.createElement("td",null,"method"),n.a.createElement("td",null,"\u4e0a\u4f20\u8bf7\u6c42\u7684 http method"),n.a.createElement("td",null,"string"),n.a.createElement("td",null,n.a.createElement("code",null,"post")),n.a.createElement("td",null)),n.a.createElement("tr",null,n.a.createElement("td",null,"multiple"),n.a.createElement("td",null,"\u662f\u5426\u652f\u6301\u591a\u9009\u6587\u4ef6\uff0c",n.a.createElement("code",null,"ie10+")," \u652f\u6301\u3002\u5f00\u542f\u540e\u6309\u4f4f ctrl \u53ef\u9009\u62e9\u591a\u4e2a\u6587\u4ef6"),n.a.createElement("td",null,"boolean"),n.a.createElement("td",null,"false"),n.a.createElement("td",null)),n.a.createElement("tr",null,n.a.createElement("td",null,"name"),n.a.createElement("td",null,"\u53d1\u5230\u540e\u53f0\u7684\u6587\u4ef6\u53c2\u6570\u540d"),n.a.createElement("td",null,"string"),n.a.createElement("td",null,n.a.createElement("code",null,"file")),n.a.createElement("td",null)),n.a.createElement("tr",null,n.a.createElement("td",null,"openFileDialogOnClick"),n.a.createElement("td",null,"\u70b9\u51fb\u6253\u5f00\u6587\u4ef6\u5bf9\u8bdd\u6846"),n.a.createElement("td",null,"boolean"),n.a.createElement("td",null,"true"),n.a.createElement("td",null)),n.a.createElement("tr",null,n.a.createElement("td",null,"previewFile"),n.a.createElement("td",null,"\u81ea\u5b9a\u4e49\u6587\u4ef6\u9884\u89c8\u903b\u8f91"),n.a.createElement("td",null,"(file: File | Blob) => Promise<dataURL: string>"),n.a.createElement("td",null,"-"),n.a.createElement("td",null)),n.a.createElement("tr",null,n.a.createElement("td",null,"progress"),n.a.createElement("td",null,"\u81ea\u5b9a\u4e49\u8fdb\u5ea6\u6761\u6837\u5f0f"),n.a.createElement("td",null,n.a.createElement(r["AnchorLink"],{to:"/components/progress/#API"},"ProgressProps"),"\uff08\u4ec5\u652f\u6301 ",n.a.createElement("code",null,'type="line"'),"\uff09"),n.a.createElement("td",null,"{"," strokeWidth: 2, showInfo: false ","}"),n.a.createElement("td",null,"4.3.0")),n.a.createElement("tr",null,n.a.createElement("td",null,"showUploadList"),n.a.createElement("td",null,"\u662f\u5426\u5c55\u793a\u6587\u4ef6\u5217\u8868, \u53ef\u8bbe\u4e3a\u4e00\u4e2a\u5bf9\u8c61\uff0c\u7528\u4e8e\u5355\u72ec\u8bbe\u5b9a ",n.a.createElement("code",null,"showPreviewIcon"),", ",n.a.createElement("code",null,"showRemoveIcon"),", ",n.a.createElement("code",null,"showDownloadIcon"),", ",n.a.createElement("code",null,"removeIcon")," \u548c ",n.a.createElement("code",null,"downloadIcon")),n.a.createElement("td",null,"boolean | ","{"," showPreviewIcon?: boolean, showRemoveIcon?: boolean, showDownloadIcon?: boolean, removeIcon?: ReactNode | (file: UploadFile) => ReactNode, downloadIcon?: ReactNode | (file: UploadFile) => ReactNode ","}"),n.a.createElement("td",null,"true"),n.a.createElement("td",null,"function: 4.7.0")),n.a.createElement("tr",null,n.a.createElement("td",null,"withCredentials"),n.a.createElement("td",null,"\u4e0a\u4f20\u8bf7\u6c42\u65f6\u662f\u5426\u643a\u5e26 cookie"),n.a.createElement("td",null,"boolean"),n.a.createElement("td",null,"false"),n.a.createElement("td",null)),n.a.createElement("tr",null,n.a.createElement("td",null,"onChange"),n.a.createElement("td",null,"\u4e0a\u4f20\u6587\u4ef6\u6539\u53d8\u65f6\u7684\u72b6\u6001\uff0c\u8be6\u89c1 ",n.a.createElement(r["AnchorLink"],{to:"#onChange"},"onChange")),n.a.createElement("td",null,"function"),n.a.createElement("td",null,"-"),n.a.createElement("td",null)),n.a.createElement("tr",null,n.a.createElement("td",null,"onDrop"),n.a.createElement("td",null,"\u5f53\u6587\u4ef6\u88ab\u62d6\u5165\u4e0a\u4f20\u533a\u57df\u65f6\u6267\u884c\u7684\u56de\u8c03\u529f\u80fd"),n.a.createElement("td",null,"(event: React.DragEvent) => void"),n.a.createElement("td",null,"-"),n.a.createElement("td",null,"4.16.0")),n.a.createElement("tr",null,n.a.createElement("td",null,"onDownload"),n.a.createElement("td",null,"\u70b9\u51fb\u4e0b\u8f7d\u6587\u4ef6\u65f6\u7684\u56de\u8c03\uff0c\u5982\u679c\u6ca1\u6709\u6307\u5b9a\uff0c\u5219\u9ed8\u8ba4\u8df3\u8f6c\u5230\u6587\u4ef6 url \u5bf9\u5e94\u7684\u6807\u7b7e\u9875"),n.a.createElement("td",null,"function(file): void"),n.a.createElement("td",null,"(\u8df3\u8f6c\u65b0\u6807\u7b7e\u9875)"),n.a.createElement("td",null)),n.a.createElement("tr",null,n.a.createElement("td",null,"onPreview"),n.a.createElement("td",null,"\u70b9\u51fb\u6587\u4ef6\u94fe\u63a5\u6216\u9884\u89c8\u56fe\u6807\u65f6\u7684\u56de\u8c03"),n.a.createElement("td",null,"function(file)"),n.a.createElement("td",null,"-"),n.a.createElement("td",null)),n.a.createElement("tr",null,n.a.createElement("td",null,"onRemove \xa0"),n.a.createElement("td",null,"\u70b9\u51fb\u79fb\u9664\u6587\u4ef6\u65f6\u7684\u56de\u8c03\uff0c\u8fd4\u56de\u503c\u4e3a false \u65f6\u4e0d\u79fb\u9664\u3002\u652f\u6301\u8fd4\u56de\u4e00\u4e2a Promise \u5bf9\u8c61\uff0cPromise \u5bf9\u8c61 resolve(false) \u6216 reject \u65f6\u4e0d\u79fb\u9664 \xa0 \xa0 \xa0 \xa0 \xa0 \xa0 \xa0"),n.a.createElement("td",null,"function(file): boolean | Promise"),n.a.createElement("td",null,"- \xa0"),n.a.createElement("td",null)))),n.a.createElement("h3",{id:"uploadfile"},n.a.createElement(r["AnchorLink"],{to:"#uploadfile","aria-hidden":"true",tabIndex:-1},n.a.createElement("span",{className:"icon icon-link"})),"UploadFile"),n.a.createElement("p",null,"\u7ee7\u627f\u81ea File\uff0c\u9644\u5e26\u989d\u5916\u5c5e\u6027\u7528\u4e8e\u6e32\u67d3\u3002"),n.a.createElement("table",null,n.a.createElement("thead",null,n.a.createElement("tr",null,n.a.createElement("th",null,"\u53c2\u6570"),n.a.createElement("th",null,"\u8bf4\u660e"),n.a.createElement("th",null,"\u7c7b\u578b"),n.a.createElement("th",null,"\u9ed8\u8ba4\u503c"))),n.a.createElement("tbody",null,n.a.createElement("tr",null,n.a.createElement("td",null,"name"),n.a.createElement("td",null,"\u6587\u4ef6\u540d"),n.a.createElement("td",null,"string"),n.a.createElement("td",null,"-")),n.a.createElement("tr",null,n.a.createElement("td",null,"percent"),n.a.createElement("td",null,"\u4e0a\u4f20\u8fdb\u5ea6"),n.a.createElement("td",null,"number"),n.a.createElement("td",null,"-")),n.a.createElement("tr",null,n.a.createElement("td",null,"status"),n.a.createElement("td",null,"\u4e0a\u4f20\u72b6\u6001\uff0c\u4e0d\u540c\u72b6\u6001\u5c55\u793a\u989c\u8272\u4e5f\u4f1a\u6709\u6240\u4e0d\u540c"),n.a.createElement("td",null,n.a.createElement("code",null,"error")," | ",n.a.createElement("code",null,"success")," | ",n.a.createElement("code",null,"done")," | ",n.a.createElement("code",null,"uploading")," | ",n.a.createElement("code",null,"removed")),n.a.createElement("td",null,"-")),n.a.createElement("tr",null,n.a.createElement("td",null,"thumbUrl"),n.a.createElement("td",null,"\u7f29\u7565\u56fe\u5730\u5740"),n.a.createElement("td",null,"string"),n.a.createElement("td",null,"-")),n.a.createElement("tr",null,n.a.createElement("td",null,"uid"),n.a.createElement("td",null,"\u552f\u4e00\u6807\u8bc6\u7b26\uff0c\u4e0d\u8bbe\u7f6e\u65f6\u4f1a\u81ea\u52a8\u751f\u6210"),n.a.createElement("td",null,"string"),n.a.createElement("td",null,"-")),n.a.createElement("tr",null,n.a.createElement("td",null,"url"),n.a.createElement("td",null,"\u4e0b\u8f7d\u5730\u5740"),n.a.createElement("td",null,"string"),n.a.createElement("td",null,"-")))),n.a.createElement("h3",{id:"onchange"},n.a.createElement(r["AnchorLink"],{to:"#onchange","aria-hidden":"true",tabIndex:-1},n.a.createElement("span",{className:"icon icon-link"})),"onChange"),n.a.createElement("blockquote",null,n.a.createElement("p",null,"\u4e0a\u4f20\u4e2d\u3001\u5b8c\u6210\u3001\u5931\u8d25\u90fd\u4f1a\u8c03\u7528\u8fd9\u4e2a\u51fd\u6570\u3002")),n.a.createElement("p",null,"\u6587\u4ef6\u72b6\u6001\u6539\u53d8\u7684\u56de\u8c03\uff0c\u8fd4\u56de\u4e3a\uff1a"),n.a.createElement(o["a"],{code:"{\n file: { /* ... */ },\n fileList: [ /* ... */ ],\n event: { /* ... */ },\n}",lang:"bash"}),n.a.createElement("ol",null,n.a.createElement("li",null,n.a.createElement("p",null,n.a.createElement("code",null,"file")," \u5f53\u524d\u64cd\u4f5c\u7684\u6587\u4ef6\u5bf9\u8c61\u3002"),n.a.createElement(o["a"],{code:"{\n uid: 'uid', // \u6587\u4ef6\u552f\u4e00\u6807\u8bc6\uff0c\u5efa\u8bae\u8bbe\u7f6e\u4e3a\u8d1f\u6570\uff0c\u9632\u6b62\u548c\u5185\u90e8\u4ea7\u751f\u7684 id \u51b2\u7a81\n name: 'xx.png' // \u6587\u4ef6\u540d\n status: 'done', // \u72b6\u6001\u6709\uff1auploading done error removed\uff0c\u88ab beforeUpload \u62e6\u622a\u7684\u6587\u4ef6\u6ca1\u6709 status \u5c5e\u6027\n response: '{\"status\": \"success\"}', // \u670d\u52a1\u7aef\u54cd\u5e94\u5185\u5bb9\n linkProps: '{\"download\": \"image\"}', // \u4e0b\u8f7d\u94fe\u63a5\u989d\u5916\u7684 HTML \u5c5e\u6027\n}",lang:"bash"})),n.a.createElement("li",null,n.a.createElement("p",null,n.a.createElement("code",null,"fileList")," \u5f53\u524d\u7684\u6587\u4ef6\u5217\u8868\u3002")),n.a.createElement("li",null,n.a.createElement("p",null,n.a.createElement("code",null,"event")," \u4e0a\u4f20\u4e2d\u7684\u670d\u52a1\u7aef\u54cd\u5e94\u5185\u5bb9\uff0c\u5305\u542b\u4e86\u4e0a\u4f20\u8fdb\u5ea6\u7b49\u4fe1\u606f\uff0c\u9ad8\u7ea7\u6d4f\u89c8\u5668\u652f\u6301\u3002"))),n.a.createElement("h2",{id:"faq"},n.a.createElement(r["AnchorLink"],{to:"#faq","aria-hidden":"true",tabIndex:-1},n.a.createElement("span",{className:"icon icon-link"})),"FAQ"),n.a.createElement("h3",{id:"\u670d\u52a1\u7aef\u5982\u4f55\u5b9e\u73b0"},n.a.createElement(r["AnchorLink"],{to:"#\u670d\u52a1\u7aef\u5982\u4f55\u5b9e\u73b0","aria-hidden":"true",tabIndex:-1},n.a.createElement("span",{className:"icon icon-link"})),"\u670d\u52a1\u7aef\u5982\u4f55\u5b9e\u73b0\uff1f"),n.a.createElement("ul",null,n.a.createElement("li",null,"\u670d\u52a1\u7aef\u4e0a\u4f20\u63a5\u53e3\u5b9e\u73b0\u53ef\u4ee5\u53c2\u8003 ",n.a.createElement(r["Link"],{to:"https://github.com/blueimp/jQuery-File-Upload/wiki#server-side"},"jQuery-File-Upload"),"\u3002"),n.a.createElement("li",null,"\u5982\u679c\u8981\u505a\u672c\u5730 mock \u53ef\u4ee5\u53c2\u8003\u8fd9\u4e2a ",n.a.createElement(r["Link"],{to:"https://github.com/react-component/upload/blob/master/server.js"},"express \u7684\u4f8b\u5b50"),"\u3002")),n.a.createElement("h3",{id:"\u5982\u4f55\u663e\u793a\u4e0b\u8f7d\u94fe\u63a5"},n.a.createElement(r["AnchorLink"],{to:"#\u5982\u4f55\u663e\u793a\u4e0b\u8f7d\u94fe\u63a5","aria-hidden":"true",tabIndex:-1},n.a.createElement("span",{className:"icon icon-link"})),"\u5982\u4f55\u663e\u793a\u4e0b\u8f7d\u94fe\u63a5\uff1f"),n.a.createElement("p",null,"\u8bf7\u4f7f\u7528 fileList \u5c5e\u6027\u8bbe\u7f6e\u6570\u7ec4\u9879\u7684 url \u5c5e\u6027\u8fdb\u884c\u5c55\u793a\u63a7\u5236\u3002"),n.a.createElement("h3",{id:"customrequest-\u600e\u4e48\u4f7f\u7528"},n.a.createElement(r["AnchorLink"],{to:"#customrequest-\u600e\u4e48\u4f7f\u7528","aria-hidden":"true",tabIndex:-1},n.a.createElement("span",{className:"icon icon-link"})),n.a.createElement("code",null,"customRequest")," \u600e\u4e48\u4f7f\u7528\uff1f"),n.a.createElement("p",null,"\u8bf7\u53c2\u8003 ",n.a.createElement(r["Link"],{to:"https://github.com/react-component/upload#customrequest"},"https://github.com/react-component/upload#customrequest"),"\u3002"),n.a.createElement("h3",{id:"\u4e3a\u4f55-filelist-\u53d7\u63a7\u65f6\u4e0a\u4f20\u4e0d\u5728\u5217\u8868\u4e2d\u7684\u6587\u4ef6\u4e0d\u4f1a\u89e6\u53d1-onchange-\u540e\u7eed\u7684-status-\u66f4\u65b0\u4e8b\u4ef6"},n.a.createElement(r["AnchorLink"],{to:"#\u4e3a\u4f55-filelist-\u53d7\u63a7\u65f6\u4e0a\u4f20\u4e0d\u5728\u5217\u8868\u4e2d\u7684\u6587\u4ef6\u4e0d\u4f1a\u89e6\u53d1-onchange-\u540e\u7eed\u7684-status-\u66f4\u65b0\u4e8b\u4ef6","aria-hidden":"true",tabIndex:-1},n.a.createElement("span",{className:"icon icon-link"})),"\u4e3a\u4f55 ",n.a.createElement("code",null,"fileList")," \u53d7\u63a7\u65f6\uff0c\u4e0a\u4f20\u4e0d\u5728\u5217\u8868\u4e2d\u7684\u6587\u4ef6\u4e0d\u4f1a\u89e6\u53d1 ",n.a.createElement("code",null,"onChange")," \u540e\u7eed\u7684 ",n.a.createElement("code",null,"status")," \u66f4\u65b0\u4e8b\u4ef6\uff1f"),n.a.createElement("p",null,n.a.createElement("code",null,"onChange")," \u4e8b\u4ef6\u4ec5\u4f1a\u4f5c\u7528\u4e8e\u5728\u5217\u8868\u4e2d\u7684\u6587\u4ef6\uff0c\u56e0\u800c ",n.a.createElement("code",null,"fileList")," \u4e0d\u5b58\u5728\u5bf9\u5e94\u6587\u4ef6\u65f6\u540e\u7eed\u4e8b\u4ef6\u4f1a\u88ab\u5ffd\u7565\u3002\u8bf7\u6ce8\u610f\uff0c\u5728 ",n.a.createElement("code",null,"4.13.0")," \u7248\u672c\u4e4b\u524d\u53d7\u63a7\u72b6\u6001\u5b58\u5728 bug \u5bfc\u81f4\u4e0d\u5728\u5217\u8868\u4e2d\u7684\u6587\u4ef6\u4e5f\u4f1a\u89e6\u53d1\u3002"),n.a.createElement("h3",{id:"onchange-\u4e3a\u4ec0\u4e48\u6709\u65f6\u5019\u8fd4\u56de-file-\u6709\u65f6\u5019\u8fd4\u56de--originfileobj-file-"},n.a.createElement(r["AnchorLink"],{to:"#onchange-\u4e3a\u4ec0\u4e48\u6709\u65f6\u5019\u8fd4\u56de-file-\u6709\u65f6\u5019\u8fd4\u56de--originfileobj-file-","aria-hidden":"true",tabIndex:-1},n.a.createElement("span",{className:"icon icon-link"})),n.a.createElement("code",null,"onChange")," \u4e3a\u4ec0\u4e48\u6709\u65f6\u5019\u8fd4\u56de File \u6709\u65f6\u5019\u8fd4\u56de ","{"," originFileObj: File ","}","\uff1f"),n.a.createElement("p",null,"\u5386\u53f2\u539f\u56e0\uff0c\u5728 ",n.a.createElement("code",null,"beforeUpload")," \u8fd4\u56de ",n.a.createElement("code",null,"false")," \u65f6\uff0c\u4f1a\u8fd4\u56de File \u5bf9\u8c61\u3002\u5728\u4e0b\u4e2a\u5927\u7248\u672c\u6211\u4eec\u4f1a\u7edf\u4e00\u8fd4\u56de ",n.a.createElement("code",null,"{"," originFileObj: File ","}")," \u5bf9\u8c61\u3002\u5f53\u524d\u7248\u672c\u5df2\u7ecf\u517c\u5bb9\u6240\u6709\u573a\u666f\u4e0b ",n.a.createElement("code",null,"info.file.originFileObj")," \u83b7\u53d6\u539f File \u5199\u6cd5\u3002\u4f60\u53ef\u4ee5\u63d0\u524d\u5207\u6362\u3002"),n.a.createElement("style",{dangerouslySetInnerHTML:{__html:"\n.avatar-uploader > .ant-upload {\n width: 128px;\n height: 128px;\n}\n\n.upload-list-inline .ant-upload-list-item {\n float: left;\n width: 200px;\n margin-right: 8px;\n}\n\n.upload-list-inline [class*='-upload-list-rtl'] .ant-upload-list-item {\n float: right;\n}\n\n.ant-upload-draggable-list-item {\n border-top: 2px dashed rgba(0, 0, 0, 0);\n border-bottom: 2px dashed rgba(0, 0, 0, 0);\n}\n.ant-upload-draggable-list-item.drop-over-downward {\n border-bottom-color: #1890ff;\n}\n.ant-upload-draggable-list-item.drop-over-upward {\n border-top-color: #1890ff;\n}\n\n"}})))))},MZF8:function(e,t,a){"use strict";var l=a("ogwx");a.d(t,"a",(function(){return l["b"]}));a("VCU9")},RZMt:function(e,t,a){},Zxc8:function(e,t,a){"use strict";a.r(t);var l=a("q1tI"),n=a.n(l),r=a("k3GJ"),c=a("MZF8"),o=a("dEAq"),m=a("H1Ra");a("RZMt");function d(e,t){return p(e)||s(e,t)||u(e,t)||i()}function i(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function u(e,t){if(e){if("string"===typeof e)return E(e,t);var a=Object.prototype.toString.call(e).slice(8,-1);return"Object"===a&&e.constructor&&(a=e.constructor.name),"Map"===a||"Set"===a?Array.from(e):"Arguments"===a||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(a)?E(e,t):void 0}}function E(e,t){(null==t||t>e.length)&&(t=e.length);for(var a=0,l=new Array(t);a<t;a++)l[a]=e[a];return l}function s(e,t){var a=null==e?null:"undefined"!==typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var l,n,r=[],c=!0,o=!1;try{for(a=a.call(e);!(c=(l=a.next()).done);c=!0)if(r.push(l.value),t&&r.length===t)break}catch(m){o=!0,n=m}finally{try{c||null==a["return"]||a["return"]()}finally{if(o)throw n}}return r}}function p(e){if(Array.isArray(e))return e}function f(e,t){var a,l=null===(a=e.match(/\.(\w+)$/))||void 0===a?void 0:a[1];return l||(l=t.tsx?"tsx":"jsx"),l}var h=function(e){var t,a,i,u=Object(l["useRef"])(),E=Object(l["useContext"])(o["context"]),s=E.locale,p=Object(o["useLocaleProps"])(s,e),h=Object(o["useDemoUrl"])(p.identifier),b=p.demoUrl||h,v=(null===c["a"]||void 0===c["a"]?void 0:c["a"].location.hash)==="#".concat(p.identifier),k=1===Object.keys(p.sources).length,g=Object(o["useCodeSandbox"])((null===(t=p.hideActions)||void 0===t?void 0:t.includes("CSB"))?null:p),w=Object(o["useRiddle"])((null===(a=p.hideActions)||void 0===a?void 0:a.includes("RIDDLE"))?null:p),N=Object(o["useMotions"])(p.motions||[],u.current),L=d(N,2),x=L[0],I=L[1],y=Object(o["useCopy"])(),A=d(y,2),_=A[0],P=A[1],j=Object(l["useState"])("_"),C=d(j,2),R=C[0],F=C[1],O=Object(l["useState"])(f(R,p.sources[R])),U=d(O,2),S=U[0],T=U[1],q=Object(l["useState"])(Boolean(p.defaultShowCode)),M=d(q,2),D=M[0],H=M[1],Z=Object(l["useState"])(Math.random()),B=d(Z,2),J=B[0],G=B[1],$=p.sources[R][S]||p.sources[R].content,z=Object(o["useTSPlaygroundUrl"])(s,$),Q=Object(l["useRef"])(),W=Object(o["usePrefersColor"])(),X=d(W,1),K=X[0];function V(e){F(e),T(f(e,p.sources[e]))}return Object(l["useEffect"])((function(){G(Math.random())}),[K]),n.a.createElement("div",{style:p.style,className:[p.className,"__dumi-default-previewer",v?"__dumi-default-previewer-target":""].filter(Boolean).join(" "),id:p.identifier,"data-debug":p.debug||void 0,"data-iframe":p.iframe||void 0},p.iframe&&n.a.createElement("div",{className:"__dumi-default-previewer-browser-nav"}),n.a.createElement("div",{ref:u,className:"__dumi-default-previewer-demo",style:{transform:p.transform?"translate(0, 0)":void 0,padding:p.compact||p.iframe&&!1!==p.compact?"0":void 0,background:p.background}},p.iframe?n.a.createElement("iframe",{title:"dumi-previewer",style:{height:String(p.iframe).replace(/(\d)$/,"$1px")},key:J,src:b,ref:Q}):p.children),n.a.createElement("div",{className:"__dumi-default-previewer-desc","data-title":p.title},p.title&&n.a.createElement(o["AnchorLink"],{to:"#".concat(p.identifier)},p.title),p.description&&n.a.createElement("div",{dangerouslySetInnerHTML:{__html:p.description}})),n.a.createElement("div",{className:"__dumi-default-previewer-actions"},g&&n.a.createElement("button",{title:"Open demo on CodeSandbox.io",className:"__dumi-default-icon",role:"codesandbox",onClick:g}),w&&n.a.createElement("button",{title:"Open demo on Riddle",className:"__dumi-default-icon",role:"riddle",onClick:w}),p.motions&&n.a.createElement("button",{title:"Execute motions",className:"__dumi-default-icon",role:"motions",disabled:I,onClick:function(){return x()}}),p.iframe&&n.a.createElement("button",{title:"Reload demo iframe page",className:"__dumi-default-icon",role:"refresh",onClick:function(){return G(Math.random())}}),!(null===(i=p.hideActions)||void 0===i?void 0:i.includes("EXTERNAL"))&&n.a.createElement(o["Link"],{target:"_blank",to:b},n.a.createElement("button",{title:"Open demo in new tab",className:"__dumi-default-icon",role:"open-demo",type:"button"})),n.a.createElement("span",null),n.a.createElement("button",{title:"Copy source code",className:"__dumi-default-icon",role:"copy","data-status":P,onClick:function(){return _($)}}),"tsx"===S&&D&&n.a.createElement(o["Link"],{target:"_blank",to:z},n.a.createElement("button",{title:"Get JSX via TypeScript Playground",className:"__dumi-default-icon",role:"change-tsx",type:"button"})),n.a.createElement("button",{title:"Toggle source code panel",className:"__dumi-default-icon".concat(D?" __dumi-default-btn-expand":""),role:"source",type:"button",onClick:function(){return H(!D)}})),D&&n.a.createElement("div",{className:"__dumi-default-previewer-source-wrapper"},!k&&n.a.createElement(r["b"],{className:"__dumi-default-previewer-source-tab",prefixCls:"__dumi-default-tabs",moreIcon:"\xb7\xb7\xb7",defaultActiveKey:R,onChange:V},Object.keys(p.sources).map((function(e){return n.a.createElement(r["a"],{tab:"_"===e?"index.".concat(f(e,p.sources[e])):e,key:e})}))),n.a.createElement("div",{className:"__dumi-default-previewer-source"},n.a.createElement(m["a"],{code:$,lang:S,showCopy:!1}))))};t["default"]=h}}]);
|
1
|
+
(window['webpackJsonp'] = window['webpackJsonp'] || []).push([
|
2
|
+
[68],
|
3
|
+
{
|
4
|
+
'6apH': function (e, t, a) {
|
5
|
+
'use strict';
|
6
|
+
a.r(t);
|
7
|
+
var l = a('q1tI'),
|
8
|
+
n = a.n(l),
|
9
|
+
r = a('dEAq'),
|
10
|
+
c = a('Zxc8'),
|
11
|
+
o = a('H1Ra'),
|
12
|
+
m = a('JjdP'),
|
13
|
+
d = n.a.memo(m['default']['upload-basic'].component),
|
14
|
+
i = n.a.memo(m['default']['upload-avatar'].component),
|
15
|
+
u = n.a.memo(m['default']['upload-defaultfilelist'].component),
|
16
|
+
E = n.a.memo(m['default']['upload-picture-card'].component),
|
17
|
+
s = n.a.memo(m['default']['upload-filelist'].component),
|
18
|
+
p = n.a.memo(m['default']['upload-drag'].component),
|
19
|
+
f = n.a.memo(m['default']['upload-directory'].component),
|
20
|
+
h = n.a.memo(m['default']['upload-upload-manually'].component),
|
21
|
+
b = n.a.memo(m['default']['upload-upload-png-only'].component),
|
22
|
+
v = n.a.memo(m['default']['upload-picture-style'].component),
|
23
|
+
k = n.a.memo(m['default']['upload-preview-file'].component),
|
24
|
+
g = n.a.memo(m['default']['upload-max-count'].component),
|
25
|
+
w = n.a.memo(m['default']['upload-transform-file'].component),
|
26
|
+
N = n.a.memo(m['default']['upload-transform-file'].component),
|
27
|
+
L = n.a.memo(
|
28
|
+
m['default']['upload-upload-custom-action-icon'].component,
|
29
|
+
),
|
30
|
+
x = n.a.memo(m['default']['upload-drag-sorting'].component),
|
31
|
+
I = n.a.memo(m['default']['upload-crop-image'].component),
|
32
|
+
y = n.a.memo(m['default']['upload-customize-progress-bar'].component);
|
33
|
+
t['default'] = (e) => (
|
34
|
+
n.a.useEffect(() => {
|
35
|
+
var t;
|
36
|
+
null !== e &&
|
37
|
+
void 0 !== e &&
|
38
|
+
null !== (t = e.location) &&
|
39
|
+
void 0 !== t &&
|
40
|
+
t.hash &&
|
41
|
+
r['AnchorLink'].scrollToAnchor(
|
42
|
+
decodeURIComponent(e.location.hash.slice(1)),
|
43
|
+
);
|
44
|
+
}, []),
|
45
|
+
n.a.createElement(
|
46
|
+
n.a.Fragment,
|
47
|
+
null,
|
48
|
+
n.a.createElement(
|
49
|
+
n.a.Fragment,
|
50
|
+
null,
|
51
|
+
n.a.createElement(
|
52
|
+
'div',
|
53
|
+
{ className: 'markdown' },
|
54
|
+
n.a.createElement(
|
55
|
+
'h1',
|
56
|
+
{ id: 'upload-\u4e0a\u4f20' },
|
57
|
+
n.a.createElement(
|
58
|
+
r['AnchorLink'],
|
59
|
+
{
|
60
|
+
to: '#upload-\u4e0a\u4f20',
|
61
|
+
'aria-hidden': 'true',
|
62
|
+
tabIndex: -1,
|
63
|
+
},
|
64
|
+
n.a.createElement('span', { className: 'icon icon-link' }),
|
65
|
+
),
|
66
|
+
'Upload \u4e0a\u4f20',
|
67
|
+
),
|
68
|
+
n.a.createElement(
|
69
|
+
'p',
|
70
|
+
null,
|
71
|
+
'\u6587\u4ef6\u9009\u62e9\u4e0a\u4f20\u548c\u62d6\u62fd\u4e0a\u4f20\u63a7\u4ef6\u3002',
|
72
|
+
),
|
73
|
+
n.a.createElement(
|
74
|
+
'h2',
|
75
|
+
{ id: '\u4f55\u65f6\u4f7f\u7528' },
|
76
|
+
n.a.createElement(
|
77
|
+
r['AnchorLink'],
|
78
|
+
{
|
79
|
+
to: '#\u4f55\u65f6\u4f7f\u7528',
|
80
|
+
'aria-hidden': 'true',
|
81
|
+
tabIndex: -1,
|
82
|
+
},
|
83
|
+
n.a.createElement('span', { className: 'icon icon-link' }),
|
84
|
+
),
|
85
|
+
'\u4f55\u65f6\u4f7f\u7528',
|
86
|
+
),
|
87
|
+
n.a.createElement(
|
88
|
+
'p',
|
89
|
+
null,
|
90
|
+
'\u4e0a\u4f20\u662f\u5c06\u4fe1\u606f\uff08\u7f51\u9875\u3001\u6587\u5b57\u3001\u56fe\u7247\u3001\u89c6\u9891\u7b49\uff09\u901a\u8fc7\u7f51\u9875\u6216\u8005\u4e0a\u4f20\u5de5\u5177\u53d1\u5e03\u5230\u8fdc\u7a0b\u670d\u52a1\u5668\u4e0a\u7684\u8fc7\u7a0b\u3002',
|
91
|
+
),
|
92
|
+
n.a.createElement(
|
93
|
+
'ul',
|
94
|
+
null,
|
95
|
+
n.a.createElement(
|
96
|
+
'li',
|
97
|
+
null,
|
98
|
+
'\u5f53\u9700\u8981\u4e0a\u4f20\u4e00\u4e2a\u6216\u4e00\u4e9b\u6587\u4ef6\u65f6\u3002',
|
99
|
+
),
|
100
|
+
n.a.createElement(
|
101
|
+
'li',
|
102
|
+
null,
|
103
|
+
'\u5f53\u9700\u8981\u5c55\u73b0\u4e0a\u4f20\u7684\u8fdb\u5ea6\u65f6\u3002',
|
104
|
+
),
|
105
|
+
n.a.createElement(
|
106
|
+
'li',
|
107
|
+
null,
|
108
|
+
'\u5f53\u9700\u8981\u4f7f\u7528\u62d6\u62fd\u4ea4\u4e92\u65f6\u3002',
|
109
|
+
),
|
110
|
+
),
|
111
|
+
n.a.createElement(
|
112
|
+
'h2',
|
113
|
+
{ id: '\u4ee3\u7801\u6f14\u793a' },
|
114
|
+
n.a.createElement(
|
115
|
+
r['AnchorLink'],
|
116
|
+
{
|
117
|
+
to: '#\u4ee3\u7801\u6f14\u793a',
|
118
|
+
'aria-hidden': 'true',
|
119
|
+
tabIndex: -1,
|
120
|
+
},
|
121
|
+
n.a.createElement('span', { className: 'icon icon-link' }),
|
122
|
+
),
|
123
|
+
'\u4ee3\u7801\u6f14\u793a',
|
124
|
+
),
|
125
|
+
n.a.createElement(
|
126
|
+
'h3',
|
127
|
+
{ id: '\u57fa\u672c\u7528\u6cd5' },
|
128
|
+
n.a.createElement(
|
129
|
+
r['AnchorLink'],
|
130
|
+
{
|
131
|
+
to: '#\u57fa\u672c\u7528\u6cd5',
|
132
|
+
'aria-hidden': 'true',
|
133
|
+
tabIndex: -1,
|
134
|
+
},
|
135
|
+
n.a.createElement('span', { className: 'icon icon-link' }),
|
136
|
+
),
|
137
|
+
'\u57fa\u672c\u7528\u6cd5',
|
138
|
+
),
|
139
|
+
),
|
140
|
+
n.a.createElement(
|
141
|
+
c['default'],
|
142
|
+
m['default']['upload-basic'].previewerProps,
|
143
|
+
n.a.createElement(d, null),
|
144
|
+
),
|
145
|
+
n.a.createElement(
|
146
|
+
'div',
|
147
|
+
{ className: 'markdown' },
|
148
|
+
n.a.createElement(
|
149
|
+
'h3',
|
150
|
+
{ id: '\u7528\u6237\u5934\u50cf' },
|
151
|
+
n.a.createElement(
|
152
|
+
r['AnchorLink'],
|
153
|
+
{
|
154
|
+
to: '#\u7528\u6237\u5934\u50cf',
|
155
|
+
'aria-hidden': 'true',
|
156
|
+
tabIndex: -1,
|
157
|
+
},
|
158
|
+
n.a.createElement('span', { className: 'icon icon-link' }),
|
159
|
+
),
|
160
|
+
'\u7528\u6237\u5934\u50cf',
|
161
|
+
),
|
162
|
+
n.a.createElement(
|
163
|
+
'blockquote',
|
164
|
+
null,
|
165
|
+
n.a.createElement(
|
166
|
+
'p',
|
167
|
+
null,
|
168
|
+
n.a.createElement('code', null, 'beforeUpload'),
|
169
|
+
' \u7684\u8fd4\u56de\u503c\u53ef\u4ee5\u662f\u4e00\u4e2a Promise \u4ee5\u652f\u6301\u5f02\u6b65\u5904\u7406\uff0c\u5982\u670d\u52a1\u7aef\u6821\u9a8c\u7b49\uff1a',
|
170
|
+
n.a.createElement(
|
171
|
+
r['Link'],
|
172
|
+
{
|
173
|
+
to: 'https://upload-react-component.vercel.app/demo/before-upload#beforeupload',
|
174
|
+
},
|
175
|
+
'\u793a\u4f8b',
|
176
|
+
),
|
177
|
+
'\u3002',
|
178
|
+
),
|
179
|
+
),
|
180
|
+
),
|
181
|
+
n.a.createElement(
|
182
|
+
c['default'],
|
183
|
+
m['default']['upload-avatar'].previewerProps,
|
184
|
+
n.a.createElement(i, null),
|
185
|
+
),
|
186
|
+
n.a.createElement(
|
187
|
+
'div',
|
188
|
+
{ className: 'markdown' },
|
189
|
+
n.a.createElement(
|
190
|
+
'h3',
|
191
|
+
{ id: '\u5df2\u4e0a\u4f20\u7684\u6587\u4ef6\u5217\u8868' },
|
192
|
+
n.a.createElement(
|
193
|
+
r['AnchorLink'],
|
194
|
+
{
|
195
|
+
to: '#\u5df2\u4e0a\u4f20\u7684\u6587\u4ef6\u5217\u8868',
|
196
|
+
'aria-hidden': 'true',
|
197
|
+
tabIndex: -1,
|
198
|
+
},
|
199
|
+
n.a.createElement('span', { className: 'icon icon-link' }),
|
200
|
+
),
|
201
|
+
'\u5df2\u4e0a\u4f20\u7684\u6587\u4ef6\u5217\u8868',
|
202
|
+
),
|
203
|
+
),
|
204
|
+
n.a.createElement(
|
205
|
+
c['default'],
|
206
|
+
m['default']['upload-defaultfilelist'].previewerProps,
|
207
|
+
n.a.createElement(u, null),
|
208
|
+
),
|
209
|
+
n.a.createElement(
|
210
|
+
'div',
|
211
|
+
{ className: 'markdown' },
|
212
|
+
n.a.createElement(
|
213
|
+
'h3',
|
214
|
+
{ id: '\u7167\u7247\u5899' },
|
215
|
+
n.a.createElement(
|
216
|
+
r['AnchorLink'],
|
217
|
+
{
|
218
|
+
to: '#\u7167\u7247\u5899',
|
219
|
+
'aria-hidden': 'true',
|
220
|
+
tabIndex: -1,
|
221
|
+
},
|
222
|
+
n.a.createElement('span', { className: 'icon icon-link' }),
|
223
|
+
),
|
224
|
+
'\u7167\u7247\u5899',
|
225
|
+
),
|
226
|
+
),
|
227
|
+
n.a.createElement(
|
228
|
+
c['default'],
|
229
|
+
m['default']['upload-picture-card'].previewerProps,
|
230
|
+
n.a.createElement(E, null),
|
231
|
+
),
|
232
|
+
n.a.createElement(
|
233
|
+
'div',
|
234
|
+
{ className: 'markdown' },
|
235
|
+
n.a.createElement(
|
236
|
+
'h3',
|
237
|
+
{
|
238
|
+
id: '\u5b8c\u5168\u63a7\u5236\u7684\u4e0a\u4f20\u5217\u8868',
|
239
|
+
},
|
240
|
+
n.a.createElement(
|
241
|
+
r['AnchorLink'],
|
242
|
+
{
|
243
|
+
to: '#\u5b8c\u5168\u63a7\u5236\u7684\u4e0a\u4f20\u5217\u8868',
|
244
|
+
'aria-hidden': 'true',
|
245
|
+
tabIndex: -1,
|
246
|
+
},
|
247
|
+
n.a.createElement('span', { className: 'icon icon-link' }),
|
248
|
+
),
|
249
|
+
'\u5b8c\u5168\u63a7\u5236\u7684\u4e0a\u4f20\u5217\u8868',
|
250
|
+
),
|
251
|
+
),
|
252
|
+
n.a.createElement(
|
253
|
+
c['default'],
|
254
|
+
m['default']['upload-filelist'].previewerProps,
|
255
|
+
n.a.createElement(s, null),
|
256
|
+
),
|
257
|
+
n.a.createElement(
|
258
|
+
'div',
|
259
|
+
{ className: 'markdown' },
|
260
|
+
n.a.createElement(
|
261
|
+
'h3',
|
262
|
+
{ id: '\u62d6\u62fd\u4e0a\u4f20' },
|
263
|
+
n.a.createElement(
|
264
|
+
r['AnchorLink'],
|
265
|
+
{
|
266
|
+
to: '#\u62d6\u62fd\u4e0a\u4f20',
|
267
|
+
'aria-hidden': 'true',
|
268
|
+
tabIndex: -1,
|
269
|
+
},
|
270
|
+
n.a.createElement('span', { className: 'icon icon-link' }),
|
271
|
+
),
|
272
|
+
'\u62d6\u62fd\u4e0a\u4f20',
|
273
|
+
),
|
274
|
+
),
|
275
|
+
n.a.createElement(
|
276
|
+
c['default'],
|
277
|
+
m['default']['upload-drag'].previewerProps,
|
278
|
+
n.a.createElement(p, null),
|
279
|
+
),
|
280
|
+
n.a.createElement(
|
281
|
+
'div',
|
282
|
+
{ className: 'markdown' },
|
283
|
+
n.a.createElement(
|
284
|
+
'h3',
|
285
|
+
{ id: '\u6587\u4ef6\u5939\u4e0a\u4f20' },
|
286
|
+
n.a.createElement(
|
287
|
+
r['AnchorLink'],
|
288
|
+
{
|
289
|
+
to: '#\u6587\u4ef6\u5939\u4e0a\u4f20',
|
290
|
+
'aria-hidden': 'true',
|
291
|
+
tabIndex: -1,
|
292
|
+
},
|
293
|
+
n.a.createElement('span', { className: 'icon icon-link' }),
|
294
|
+
),
|
295
|
+
'\u6587\u4ef6\u5939\u4e0a\u4f20',
|
296
|
+
),
|
297
|
+
),
|
298
|
+
n.a.createElement(
|
299
|
+
c['default'],
|
300
|
+
m['default']['upload-directory'].previewerProps,
|
301
|
+
n.a.createElement(f, null),
|
302
|
+
),
|
303
|
+
n.a.createElement(
|
304
|
+
'div',
|
305
|
+
{ className: 'markdown' },
|
306
|
+
n.a.createElement(
|
307
|
+
'h3',
|
308
|
+
{ id: '\u624b\u52a8\u4e0a\u4f20' },
|
309
|
+
n.a.createElement(
|
310
|
+
r['AnchorLink'],
|
311
|
+
{
|
312
|
+
to: '#\u624b\u52a8\u4e0a\u4f20',
|
313
|
+
'aria-hidden': 'true',
|
314
|
+
tabIndex: -1,
|
315
|
+
},
|
316
|
+
n.a.createElement('span', { className: 'icon icon-link' }),
|
317
|
+
),
|
318
|
+
'\u624b\u52a8\u4e0a\u4f20',
|
319
|
+
),
|
320
|
+
),
|
321
|
+
n.a.createElement(
|
322
|
+
c['default'],
|
323
|
+
m['default']['upload-upload-manually'].previewerProps,
|
324
|
+
n.a.createElement(h, null),
|
325
|
+
),
|
326
|
+
n.a.createElement(
|
327
|
+
'div',
|
328
|
+
{ className: 'markdown' },
|
329
|
+
n.a.createElement(
|
330
|
+
'h3',
|
331
|
+
{ id: '\u53ea\u4e0a\u4f20-png-\u56fe\u7247' },
|
332
|
+
n.a.createElement(
|
333
|
+
r['AnchorLink'],
|
334
|
+
{
|
335
|
+
to: '#\u53ea\u4e0a\u4f20-png-\u56fe\u7247',
|
336
|
+
'aria-hidden': 'true',
|
337
|
+
tabIndex: -1,
|
338
|
+
},
|
339
|
+
n.a.createElement('span', { className: 'icon icon-link' }),
|
340
|
+
),
|
341
|
+
'\u53ea\u4e0a\u4f20 png \u56fe\u7247',
|
342
|
+
),
|
343
|
+
),
|
344
|
+
n.a.createElement(
|
345
|
+
c['default'],
|
346
|
+
m['default']['upload-upload-png-only'].previewerProps,
|
347
|
+
n.a.createElement(b, null),
|
348
|
+
),
|
349
|
+
n.a.createElement(
|
350
|
+
'div',
|
351
|
+
{ className: 'markdown' },
|
352
|
+
n.a.createElement(
|
353
|
+
'h3',
|
354
|
+
{ id: '\u56fe\u7247\u5217\u8868\u6837\u5f0f' },
|
355
|
+
n.a.createElement(
|
356
|
+
r['AnchorLink'],
|
357
|
+
{
|
358
|
+
to: '#\u56fe\u7247\u5217\u8868\u6837\u5f0f',
|
359
|
+
'aria-hidden': 'true',
|
360
|
+
tabIndex: -1,
|
361
|
+
},
|
362
|
+
n.a.createElement('span', { className: 'icon icon-link' }),
|
363
|
+
),
|
364
|
+
'\u56fe\u7247\u5217\u8868\u6837\u5f0f',
|
365
|
+
),
|
366
|
+
),
|
367
|
+
n.a.createElement(
|
368
|
+
c['default'],
|
369
|
+
m['default']['upload-picture-style'].previewerProps,
|
370
|
+
n.a.createElement(v, null),
|
371
|
+
),
|
372
|
+
n.a.createElement(
|
373
|
+
'div',
|
374
|
+
{ className: 'markdown' },
|
375
|
+
n.a.createElement(
|
376
|
+
'h3',
|
377
|
+
{ id: '\u81ea\u5b9a\u4e49\u9884\u89c8' },
|
378
|
+
n.a.createElement(
|
379
|
+
r['AnchorLink'],
|
380
|
+
{
|
381
|
+
to: '#\u81ea\u5b9a\u4e49\u9884\u89c8',
|
382
|
+
'aria-hidden': 'true',
|
383
|
+
tabIndex: -1,
|
384
|
+
},
|
385
|
+
n.a.createElement('span', { className: 'icon icon-link' }),
|
386
|
+
),
|
387
|
+
'\u81ea\u5b9a\u4e49\u9884\u89c8',
|
388
|
+
),
|
389
|
+
),
|
390
|
+
n.a.createElement(
|
391
|
+
c['default'],
|
392
|
+
m['default']['upload-preview-file'].previewerProps,
|
393
|
+
n.a.createElement(k, null),
|
394
|
+
),
|
395
|
+
n.a.createElement(
|
396
|
+
'div',
|
397
|
+
{ className: 'markdown' },
|
398
|
+
n.a.createElement(
|
399
|
+
'h3',
|
400
|
+
{ id: '\u9650\u5236\u6570\u91cf' },
|
401
|
+
n.a.createElement(
|
402
|
+
r['AnchorLink'],
|
403
|
+
{
|
404
|
+
to: '#\u9650\u5236\u6570\u91cf',
|
405
|
+
'aria-hidden': 'true',
|
406
|
+
tabIndex: -1,
|
407
|
+
},
|
408
|
+
n.a.createElement('span', { className: 'icon icon-link' }),
|
409
|
+
),
|
410
|
+
'\u9650\u5236\u6570\u91cf',
|
411
|
+
),
|
412
|
+
),
|
413
|
+
n.a.createElement(
|
414
|
+
c['default'],
|
415
|
+
m['default']['upload-max-count'].previewerProps,
|
416
|
+
n.a.createElement(g, null),
|
417
|
+
),
|
418
|
+
n.a.createElement(
|
419
|
+
'div',
|
420
|
+
{ className: 'markdown' },
|
421
|
+
n.a.createElement(
|
422
|
+
'h3',
|
423
|
+
{ id: '\u4e0a\u4f20\u524d\u8f6c\u6362\u6587\u4ef6' },
|
424
|
+
n.a.createElement(
|
425
|
+
r['AnchorLink'],
|
426
|
+
{
|
427
|
+
to: '#\u4e0a\u4f20\u524d\u8f6c\u6362\u6587\u4ef6',
|
428
|
+
'aria-hidden': 'true',
|
429
|
+
tabIndex: -1,
|
430
|
+
},
|
431
|
+
n.a.createElement('span', { className: 'icon icon-link' }),
|
432
|
+
),
|
433
|
+
'\u4e0a\u4f20\u524d\u8f6c\u6362\u6587\u4ef6',
|
434
|
+
),
|
435
|
+
),
|
436
|
+
n.a.createElement(
|
437
|
+
c['default'],
|
438
|
+
m['default']['upload-transform-file'].previewerProps,
|
439
|
+
n.a.createElement(w, null),
|
440
|
+
),
|
441
|
+
n.a.createElement(
|
442
|
+
'div',
|
443
|
+
{ className: 'markdown' },
|
444
|
+
n.a.createElement(
|
445
|
+
'h3',
|
446
|
+
{ id: '\u963f\u91cc\u4e91-oss' },
|
447
|
+
n.a.createElement(
|
448
|
+
r['AnchorLink'],
|
449
|
+
{
|
450
|
+
to: '#\u963f\u91cc\u4e91-oss',
|
451
|
+
'aria-hidden': 'true',
|
452
|
+
tabIndex: -1,
|
453
|
+
},
|
454
|
+
n.a.createElement('span', { className: 'icon icon-link' }),
|
455
|
+
),
|
456
|
+
'\u963f\u91cc\u4e91 OSS',
|
457
|
+
),
|
458
|
+
),
|
459
|
+
n.a.createElement(
|
460
|
+
c['default'],
|
461
|
+
m['default']['upload-transform-file'].previewerProps,
|
462
|
+
n.a.createElement(N, null),
|
463
|
+
),
|
464
|
+
n.a.createElement(
|
465
|
+
'div',
|
466
|
+
{ className: 'markdown' },
|
467
|
+
n.a.createElement(
|
468
|
+
'h3',
|
469
|
+
{ id: '\u81ea\u5b9a\u4e49\u4ea4\u4e92\u56fe\u6807' },
|
470
|
+
n.a.createElement(
|
471
|
+
r['AnchorLink'],
|
472
|
+
{
|
473
|
+
to: '#\u81ea\u5b9a\u4e49\u4ea4\u4e92\u56fe\u6807',
|
474
|
+
'aria-hidden': 'true',
|
475
|
+
tabIndex: -1,
|
476
|
+
},
|
477
|
+
n.a.createElement('span', { className: 'icon icon-link' }),
|
478
|
+
),
|
479
|
+
'\u81ea\u5b9a\u4e49\u4ea4\u4e92\u56fe\u6807',
|
480
|
+
),
|
481
|
+
),
|
482
|
+
n.a.createElement(
|
483
|
+
c['default'],
|
484
|
+
m['default']['upload-upload-custom-action-icon'].previewerProps,
|
485
|
+
n.a.createElement(L, null),
|
486
|
+
),
|
487
|
+
n.a.createElement(
|
488
|
+
'div',
|
489
|
+
{ className: 'markdown' },
|
490
|
+
n.a.createElement(
|
491
|
+
'h3',
|
492
|
+
{ id: '\u4e0a\u4f20\u5217\u8868\u62d6\u62fd\u6392\u5e8f' },
|
493
|
+
n.a.createElement(
|
494
|
+
r['AnchorLink'],
|
495
|
+
{
|
496
|
+
to: '#\u4e0a\u4f20\u5217\u8868\u62d6\u62fd\u6392\u5e8f',
|
497
|
+
'aria-hidden': 'true',
|
498
|
+
tabIndex: -1,
|
499
|
+
},
|
500
|
+
n.a.createElement('span', { className: 'icon icon-link' }),
|
501
|
+
),
|
502
|
+
'\u4e0a\u4f20\u5217\u8868\u62d6\u62fd\u6392\u5e8f',
|
503
|
+
),
|
504
|
+
),
|
505
|
+
n.a.createElement(
|
506
|
+
c['default'],
|
507
|
+
m['default']['upload-drag-sorting'].previewerProps,
|
508
|
+
n.a.createElement(x, null),
|
509
|
+
),
|
510
|
+
n.a.createElement(
|
511
|
+
'div',
|
512
|
+
{ className: 'markdown' },
|
513
|
+
n.a.createElement(
|
514
|
+
'h3',
|
515
|
+
{ id: '\u4e0a\u4f20\u524d\u88c1\u5207\u56fe\u7247' },
|
516
|
+
n.a.createElement(
|
517
|
+
r['AnchorLink'],
|
518
|
+
{
|
519
|
+
to: '#\u4e0a\u4f20\u524d\u88c1\u5207\u56fe\u7247',
|
520
|
+
'aria-hidden': 'true',
|
521
|
+
tabIndex: -1,
|
522
|
+
},
|
523
|
+
n.a.createElement('span', { className: 'icon icon-link' }),
|
524
|
+
),
|
525
|
+
'\u4e0a\u4f20\u524d\u88c1\u5207\u56fe\u7247',
|
526
|
+
),
|
527
|
+
),
|
528
|
+
n.a.createElement(
|
529
|
+
c['default'],
|
530
|
+
m['default']['upload-crop-image'].previewerProps,
|
531
|
+
n.a.createElement(I, null),
|
532
|
+
),
|
533
|
+
n.a.createElement(
|
534
|
+
'div',
|
535
|
+
{ className: 'markdown' },
|
536
|
+
n.a.createElement(
|
537
|
+
'h3',
|
538
|
+
{ id: '\u81ea\u5b9a\u4e49\u8fdb\u5ea6\u6761\u6837\u5f0f' },
|
539
|
+
n.a.createElement(
|
540
|
+
r['AnchorLink'],
|
541
|
+
{
|
542
|
+
to: '#\u81ea\u5b9a\u4e49\u8fdb\u5ea6\u6761\u6837\u5f0f',
|
543
|
+
'aria-hidden': 'true',
|
544
|
+
tabIndex: -1,
|
545
|
+
},
|
546
|
+
n.a.createElement('span', { className: 'icon icon-link' }),
|
547
|
+
),
|
548
|
+
'\u81ea\u5b9a\u4e49\u8fdb\u5ea6\u6761\u6837\u5f0f',
|
549
|
+
),
|
550
|
+
),
|
551
|
+
n.a.createElement(
|
552
|
+
c['default'],
|
553
|
+
m['default']['upload-customize-progress-bar'].previewerProps,
|
554
|
+
n.a.createElement(y, null),
|
555
|
+
),
|
556
|
+
n.a.createElement(
|
557
|
+
'div',
|
558
|
+
{ className: 'markdown' },
|
559
|
+
n.a.createElement(
|
560
|
+
'h2',
|
561
|
+
{ id: 'api' },
|
562
|
+
n.a.createElement(
|
563
|
+
r['AnchorLink'],
|
564
|
+
{ to: '#api', 'aria-hidden': 'true', tabIndex: -1 },
|
565
|
+
n.a.createElement('span', { className: 'icon icon-link' }),
|
566
|
+
),
|
567
|
+
'API',
|
568
|
+
),
|
569
|
+
n.a.createElement(
|
570
|
+
'table',
|
571
|
+
null,
|
572
|
+
n.a.createElement(
|
573
|
+
'thead',
|
574
|
+
null,
|
575
|
+
n.a.createElement(
|
576
|
+
'tr',
|
577
|
+
null,
|
578
|
+
n.a.createElement('th', null, '\u53c2\u6570'),
|
579
|
+
n.a.createElement('th', null, '\u8bf4\u660e'),
|
580
|
+
n.a.createElement('th', null, '\u7c7b\u578b'),
|
581
|
+
n.a.createElement('th', null, '\u9ed8\u8ba4\u503c'),
|
582
|
+
n.a.createElement('th', null, '\u7248\u672c'),
|
583
|
+
),
|
584
|
+
),
|
585
|
+
n.a.createElement(
|
586
|
+
'tbody',
|
587
|
+
null,
|
588
|
+
n.a.createElement(
|
589
|
+
'tr',
|
590
|
+
null,
|
591
|
+
n.a.createElement('td', null, 'accept'),
|
592
|
+
n.a.createElement(
|
593
|
+
'td',
|
594
|
+
null,
|
595
|
+
'\u63a5\u53d7\u4e0a\u4f20\u7684\u6587\u4ef6\u7c7b\u578b, \u8be6\u89c1 ',
|
596
|
+
n.a.createElement(
|
597
|
+
r['Link'],
|
598
|
+
{
|
599
|
+
to: 'https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input/file#accept',
|
600
|
+
},
|
601
|
+
'input accept Attribute',
|
602
|
+
),
|
603
|
+
),
|
604
|
+
n.a.createElement('td', null, 'string'),
|
605
|
+
n.a.createElement('td', null, '-'),
|
606
|
+
n.a.createElement('td', null),
|
607
|
+
),
|
608
|
+
n.a.createElement(
|
609
|
+
'tr',
|
610
|
+
null,
|
611
|
+
n.a.createElement('td', null, 'action'),
|
612
|
+
n.a.createElement(
|
613
|
+
'td',
|
614
|
+
null,
|
615
|
+
'\u4e0a\u4f20\u7684\u5730\u5740',
|
616
|
+
),
|
617
|
+
n.a.createElement(
|
618
|
+
'td',
|
619
|
+
null,
|
620
|
+
'string | (file) => Promise<string>',
|
621
|
+
),
|
622
|
+
n.a.createElement('td', null, '-'),
|
623
|
+
n.a.createElement('td', null),
|
624
|
+
),
|
625
|
+
n.a.createElement(
|
626
|
+
'tr',
|
627
|
+
null,
|
628
|
+
n.a.createElement('td', null, 'beforeUpload'),
|
629
|
+
n.a.createElement(
|
630
|
+
'td',
|
631
|
+
null,
|
632
|
+
'\u4e0a\u4f20\u6587\u4ef6\u4e4b\u524d\u7684\u94a9\u5b50\uff0c\u53c2\u6570\u4e3a\u4e0a\u4f20\u7684\u6587\u4ef6\uff0c\u82e5\u8fd4\u56de ',
|
633
|
+
n.a.createElement('code', null, 'false'),
|
634
|
+
' \u5219\u505c\u6b62\u4e0a\u4f20\u3002\u652f\u6301\u8fd4\u56de\u4e00\u4e2a Promise \u5bf9\u8c61\uff0cPromise \u5bf9\u8c61 reject \u65f6\u5219\u505c\u6b62\u4e0a\u4f20\uff0cresolve \u65f6\u5f00\u59cb\u4e0a\u4f20\uff08 resolve \u4f20\u5165 ',
|
635
|
+
n.a.createElement('code', null, 'File'),
|
636
|
+
' \u6216 ',
|
637
|
+
n.a.createElement('code', null, 'Blob'),
|
638
|
+
' \u5bf9\u8c61\u5219\u4e0a\u4f20 resolve \u4f20\u5165\u5bf9\u8c61\uff09\uff1b\u4e5f\u53ef\u4ee5\u8fd4\u56de ',
|
639
|
+
n.a.createElement('code', null, 'Upload.LIST_IGNORE'),
|
640
|
+
'\uff0c\u6b64\u65f6\u5217\u8868\u4e2d\u5c06\u4e0d\u5c55\u793a\u6b64\u6587\u4ef6\u3002 ',
|
641
|
+
n.a.createElement(
|
642
|
+
'strong',
|
643
|
+
null,
|
644
|
+
'\u6ce8\u610f\uff1aIE9 \u4e0d\u652f\u6301\u8be5\u65b9\u6cd5',
|
645
|
+
),
|
646
|
+
),
|
647
|
+
n.a.createElement(
|
648
|
+
'td',
|
649
|
+
null,
|
650
|
+
'(file, fileList) => boolean | Promise<File> | ',
|
651
|
+
n.a.createElement('code', null, 'Upload.LIST_IGNORE'),
|
652
|
+
),
|
653
|
+
n.a.createElement('td', null, '-'),
|
654
|
+
n.a.createElement('td', null),
|
655
|
+
),
|
656
|
+
n.a.createElement(
|
657
|
+
'tr',
|
658
|
+
null,
|
659
|
+
n.a.createElement('td', null, 'customRequest'),
|
660
|
+
n.a.createElement(
|
661
|
+
'td',
|
662
|
+
null,
|
663
|
+
'\u901a\u8fc7\u8986\u76d6\u9ed8\u8ba4\u7684\u4e0a\u4f20\u884c\u4e3a\uff0c\u53ef\u4ee5\u81ea\u5b9a\u4e49\u81ea\u5df1\u7684\u4e0a\u4f20\u5b9e\u73b0',
|
664
|
+
),
|
665
|
+
n.a.createElement('td', null, 'function'),
|
666
|
+
n.a.createElement('td', null, '-'),
|
667
|
+
n.a.createElement('td', null),
|
668
|
+
),
|
669
|
+
n.a.createElement(
|
670
|
+
'tr',
|
671
|
+
null,
|
672
|
+
n.a.createElement('td', null, 'data'),
|
673
|
+
n.a.createElement(
|
674
|
+
'td',
|
675
|
+
null,
|
676
|
+
'\u4e0a\u4f20\u6240\u9700\u989d\u5916\u53c2\u6570\u6216\u8fd4\u56de\u4e0a\u4f20\u989d\u5916\u53c2\u6570\u7684\u65b9\u6cd5',
|
677
|
+
),
|
678
|
+
n.a.createElement(
|
679
|
+
'td',
|
680
|
+
null,
|
681
|
+
'object|(file) => object | Promise<object>',
|
682
|
+
),
|
683
|
+
n.a.createElement('td', null, '-'),
|
684
|
+
n.a.createElement('td', null),
|
685
|
+
),
|
686
|
+
n.a.createElement(
|
687
|
+
'tr',
|
688
|
+
null,
|
689
|
+
n.a.createElement('td', null, 'defaultFileList'),
|
690
|
+
n.a.createElement(
|
691
|
+
'td',
|
692
|
+
null,
|
693
|
+
'\u9ed8\u8ba4\u5df2\u7ecf\u4e0a\u4f20\u7684\u6587\u4ef6\u5217\u8868',
|
694
|
+
),
|
695
|
+
n.a.createElement('td', null, 'object[]'),
|
696
|
+
n.a.createElement('td', null, '-'),
|
697
|
+
n.a.createElement('td', null),
|
698
|
+
),
|
699
|
+
n.a.createElement(
|
700
|
+
'tr',
|
701
|
+
null,
|
702
|
+
n.a.createElement('td', null, 'directory'),
|
703
|
+
n.a.createElement(
|
704
|
+
'td',
|
705
|
+
null,
|
706
|
+
'\u652f\u6301\u4e0a\u4f20\u6587\u4ef6\u5939\uff08',
|
707
|
+
n.a.createElement(
|
708
|
+
r['Link'],
|
709
|
+
{
|
710
|
+
to: 'https://caniuse.com/#feat=input-file-directory',
|
711
|
+
},
|
712
|
+
'caniuse',
|
713
|
+
),
|
714
|
+
'\uff09',
|
715
|
+
),
|
716
|
+
n.a.createElement('td', null, 'boolean'),
|
717
|
+
n.a.createElement('td', null, 'false'),
|
718
|
+
n.a.createElement('td', null),
|
719
|
+
),
|
720
|
+
n.a.createElement(
|
721
|
+
'tr',
|
722
|
+
null,
|
723
|
+
n.a.createElement('td', null, 'disabled'),
|
724
|
+
n.a.createElement('td', null, '\u662f\u5426\u7981\u7528'),
|
725
|
+
n.a.createElement('td', null, 'boolean'),
|
726
|
+
n.a.createElement('td', null, 'false'),
|
727
|
+
n.a.createElement('td', null),
|
728
|
+
),
|
729
|
+
n.a.createElement(
|
730
|
+
'tr',
|
731
|
+
null,
|
732
|
+
n.a.createElement('td', null, 'fileList'),
|
733
|
+
n.a.createElement(
|
734
|
+
'td',
|
735
|
+
null,
|
736
|
+
'\u5df2\u7ecf\u4e0a\u4f20\u7684\u6587\u4ef6\u5217\u8868\uff08\u53d7\u63a7\uff09\uff0c\u4f7f\u7528\u6b64\u53c2\u6570\u65f6\uff0c\u5982\u679c\u9047\u5230 ',
|
737
|
+
n.a.createElement('code', null, 'onChange'),
|
738
|
+
' \u53ea\u8c03\u7528\u4e00\u6b21\u7684\u95ee\u9898\uff0c\u8bf7\u53c2\u8003 ',
|
739
|
+
n.a.createElement(
|
740
|
+
r['Link'],
|
741
|
+
{
|
742
|
+
to: 'https://github.com/ant-design/ant-design/issues/2423',
|
743
|
+
},
|
744
|
+
'#2423',
|
745
|
+
),
|
746
|
+
),
|
747
|
+
n.a.createElement(
|
748
|
+
'td',
|
749
|
+
null,
|
750
|
+
n.a.createElement(
|
751
|
+
r['AnchorLink'],
|
752
|
+
{ to: '#UploadFile' },
|
753
|
+
'UploadFile',
|
754
|
+
),
|
755
|
+
'[]',
|
756
|
+
),
|
757
|
+
n.a.createElement('td', null, '-'),
|
758
|
+
n.a.createElement('td', null),
|
759
|
+
),
|
760
|
+
n.a.createElement(
|
761
|
+
'tr',
|
762
|
+
null,
|
763
|
+
n.a.createElement('td', null, 'headers'),
|
764
|
+
n.a.createElement(
|
765
|
+
'td',
|
766
|
+
null,
|
767
|
+
'\u8bbe\u7f6e\u4e0a\u4f20\u7684\u8bf7\u6c42\u5934\u90e8\uff0cIE10 \u4ee5\u4e0a\u6709\u6548',
|
768
|
+
),
|
769
|
+
n.a.createElement('td', null, 'object'),
|
770
|
+
n.a.createElement('td', null, '-'),
|
771
|
+
n.a.createElement('td', null),
|
772
|
+
),
|
773
|
+
n.a.createElement(
|
774
|
+
'tr',
|
775
|
+
null,
|
776
|
+
n.a.createElement('td', null, 'iconRender'),
|
777
|
+
n.a.createElement(
|
778
|
+
'td',
|
779
|
+
null,
|
780
|
+
'\u81ea\u5b9a\u4e49\u663e\u793a icon',
|
781
|
+
),
|
782
|
+
n.a.createElement(
|
783
|
+
'td',
|
784
|
+
null,
|
785
|
+
'(file: UploadFile, listType?: UploadListType) => ReactNode',
|
786
|
+
),
|
787
|
+
n.a.createElement('td', null, '-'),
|
788
|
+
n.a.createElement('td', null),
|
789
|
+
),
|
790
|
+
n.a.createElement(
|
791
|
+
'tr',
|
792
|
+
null,
|
793
|
+
n.a.createElement('td', null, 'isImageUrl'),
|
794
|
+
n.a.createElement(
|
795
|
+
'td',
|
796
|
+
null,
|
797
|
+
'\u81ea\u5b9a\u4e49\u7f29\u7565\u56fe\u662f\u5426\u4f7f\u7528 <img /> \u6807\u7b7e\u8fdb\u884c\u663e\u793a',
|
798
|
+
),
|
799
|
+
n.a.createElement(
|
800
|
+
'td',
|
801
|
+
null,
|
802
|
+
'(file: UploadFile) => boolean',
|
803
|
+
),
|
804
|
+
n.a.createElement(
|
805
|
+
'td',
|
806
|
+
null,
|
807
|
+
n.a.createElement(
|
808
|
+
r['Link'],
|
809
|
+
{
|
810
|
+
to: 'https://github.com/ant-design/ant-design/blob/4ad5830eecfb87471cd8ac588c5d992862b70770/components/upload/utils.tsx#L47-L68',
|
811
|
+
},
|
812
|
+
'(\u5185\u90e8\u5b9e\u73b0)',
|
813
|
+
),
|
814
|
+
),
|
815
|
+
n.a.createElement('td', null),
|
816
|
+
),
|
817
|
+
n.a.createElement(
|
818
|
+
'tr',
|
819
|
+
null,
|
820
|
+
n.a.createElement('td', null, 'itemRender'),
|
821
|
+
n.a.createElement(
|
822
|
+
'td',
|
823
|
+
null,
|
824
|
+
'\u81ea\u5b9a\u4e49\u4e0a\u4f20\u5217\u8868\u9879',
|
825
|
+
),
|
826
|
+
n.a.createElement(
|
827
|
+
'td',
|
828
|
+
null,
|
829
|
+
'(originNode: ReactElement, file: UploadFile, fileList: object[], actions: ',
|
830
|
+
'{',
|
831
|
+
' download: function, preview: function, remove: function ',
|
832
|
+
'}',
|
833
|
+
') => React.ReactNode',
|
834
|
+
),
|
835
|
+
n.a.createElement('td', null, '-'),
|
836
|
+
n.a.createElement('td', null, '4.16.0'),
|
837
|
+
),
|
838
|
+
n.a.createElement(
|
839
|
+
'tr',
|
840
|
+
null,
|
841
|
+
n.a.createElement('td', null, 'listType'),
|
842
|
+
n.a.createElement(
|
843
|
+
'td',
|
844
|
+
null,
|
845
|
+
'\u4e0a\u4f20\u5217\u8868\u7684\u5185\u5efa\u6837\u5f0f\uff0c\u652f\u6301\u4e09\u79cd\u57fa\u672c\u6837\u5f0f ',
|
846
|
+
n.a.createElement('code', null, 'text'),
|
847
|
+
', ',
|
848
|
+
n.a.createElement('code', null, 'picture'),
|
849
|
+
' \u548c ',
|
850
|
+
n.a.createElement('code', null, 'picture-card'),
|
851
|
+
),
|
852
|
+
n.a.createElement('td', null, 'string'),
|
853
|
+
n.a.createElement(
|
854
|
+
'td',
|
855
|
+
null,
|
856
|
+
n.a.createElement('code', null, 'text'),
|
857
|
+
),
|
858
|
+
n.a.createElement('td', null),
|
859
|
+
),
|
860
|
+
n.a.createElement(
|
861
|
+
'tr',
|
862
|
+
null,
|
863
|
+
n.a.createElement('td', null, 'maxCount'),
|
864
|
+
n.a.createElement(
|
865
|
+
'td',
|
866
|
+
null,
|
867
|
+
'\u9650\u5236\u4e0a\u4f20\u6570\u91cf\u3002\u5f53\u4e3a 1 \u65f6\uff0c\u59cb\u7ec8\u7528\u6700\u65b0\u4e0a\u4f20\u7684\u6587\u4ef6\u4ee3\u66ff\u5f53\u524d\u6587\u4ef6',
|
868
|
+
),
|
869
|
+
n.a.createElement('td', null, 'number'),
|
870
|
+
n.a.createElement('td', null, '-'),
|
871
|
+
n.a.createElement('td', null, '4.10.0'),
|
872
|
+
),
|
873
|
+
n.a.createElement(
|
874
|
+
'tr',
|
875
|
+
null,
|
876
|
+
n.a.createElement('td', null, 'method'),
|
877
|
+
n.a.createElement(
|
878
|
+
'td',
|
879
|
+
null,
|
880
|
+
'\u4e0a\u4f20\u8bf7\u6c42\u7684 http method',
|
881
|
+
),
|
882
|
+
n.a.createElement('td', null, 'string'),
|
883
|
+
n.a.createElement(
|
884
|
+
'td',
|
885
|
+
null,
|
886
|
+
n.a.createElement('code', null, 'post'),
|
887
|
+
),
|
888
|
+
n.a.createElement('td', null),
|
889
|
+
),
|
890
|
+
n.a.createElement(
|
891
|
+
'tr',
|
892
|
+
null,
|
893
|
+
n.a.createElement('td', null, 'multiple'),
|
894
|
+
n.a.createElement(
|
895
|
+
'td',
|
896
|
+
null,
|
897
|
+
'\u662f\u5426\u652f\u6301\u591a\u9009\u6587\u4ef6\uff0c',
|
898
|
+
n.a.createElement('code', null, 'ie10+'),
|
899
|
+
' \u652f\u6301\u3002\u5f00\u542f\u540e\u6309\u4f4f ctrl \u53ef\u9009\u62e9\u591a\u4e2a\u6587\u4ef6',
|
900
|
+
),
|
901
|
+
n.a.createElement('td', null, 'boolean'),
|
902
|
+
n.a.createElement('td', null, 'false'),
|
903
|
+
n.a.createElement('td', null),
|
904
|
+
),
|
905
|
+
n.a.createElement(
|
906
|
+
'tr',
|
907
|
+
null,
|
908
|
+
n.a.createElement('td', null, 'name'),
|
909
|
+
n.a.createElement(
|
910
|
+
'td',
|
911
|
+
null,
|
912
|
+
'\u53d1\u5230\u540e\u53f0\u7684\u6587\u4ef6\u53c2\u6570\u540d',
|
913
|
+
),
|
914
|
+
n.a.createElement('td', null, 'string'),
|
915
|
+
n.a.createElement(
|
916
|
+
'td',
|
917
|
+
null,
|
918
|
+
n.a.createElement('code', null, 'file'),
|
919
|
+
),
|
920
|
+
n.a.createElement('td', null),
|
921
|
+
),
|
922
|
+
n.a.createElement(
|
923
|
+
'tr',
|
924
|
+
null,
|
925
|
+
n.a.createElement('td', null, 'openFileDialogOnClick'),
|
926
|
+
n.a.createElement(
|
927
|
+
'td',
|
928
|
+
null,
|
929
|
+
'\u70b9\u51fb\u6253\u5f00\u6587\u4ef6\u5bf9\u8bdd\u6846',
|
930
|
+
),
|
931
|
+
n.a.createElement('td', null, 'boolean'),
|
932
|
+
n.a.createElement('td', null, 'true'),
|
933
|
+
n.a.createElement('td', null),
|
934
|
+
),
|
935
|
+
n.a.createElement(
|
936
|
+
'tr',
|
937
|
+
null,
|
938
|
+
n.a.createElement('td', null, 'previewFile'),
|
939
|
+
n.a.createElement(
|
940
|
+
'td',
|
941
|
+
null,
|
942
|
+
'\u81ea\u5b9a\u4e49\u6587\u4ef6\u9884\u89c8\u903b\u8f91',
|
943
|
+
),
|
944
|
+
n.a.createElement(
|
945
|
+
'td',
|
946
|
+
null,
|
947
|
+
'(file: File | Blob) => Promise<dataURL: string>',
|
948
|
+
),
|
949
|
+
n.a.createElement('td', null, '-'),
|
950
|
+
n.a.createElement('td', null),
|
951
|
+
),
|
952
|
+
n.a.createElement(
|
953
|
+
'tr',
|
954
|
+
null,
|
955
|
+
n.a.createElement('td', null, 'progress'),
|
956
|
+
n.a.createElement(
|
957
|
+
'td',
|
958
|
+
null,
|
959
|
+
'\u81ea\u5b9a\u4e49\u8fdb\u5ea6\u6761\u6837\u5f0f',
|
960
|
+
),
|
961
|
+
n.a.createElement(
|
962
|
+
'td',
|
963
|
+
null,
|
964
|
+
n.a.createElement(
|
965
|
+
r['AnchorLink'],
|
966
|
+
{ to: '/components/progress/#API' },
|
967
|
+
'ProgressProps',
|
968
|
+
),
|
969
|
+
'\uff08\u4ec5\u652f\u6301 ',
|
970
|
+
n.a.createElement('code', null, 'type="line"'),
|
971
|
+
'\uff09',
|
972
|
+
),
|
973
|
+
n.a.createElement(
|
974
|
+
'td',
|
975
|
+
null,
|
976
|
+
'{',
|
977
|
+
' strokeWidth: 2, showInfo: false ',
|
978
|
+
'}',
|
979
|
+
),
|
980
|
+
n.a.createElement('td', null, '4.3.0'),
|
981
|
+
),
|
982
|
+
n.a.createElement(
|
983
|
+
'tr',
|
984
|
+
null,
|
985
|
+
n.a.createElement('td', null, 'showUploadList'),
|
986
|
+
n.a.createElement(
|
987
|
+
'td',
|
988
|
+
null,
|
989
|
+
'\u662f\u5426\u5c55\u793a\u6587\u4ef6\u5217\u8868, \u53ef\u8bbe\u4e3a\u4e00\u4e2a\u5bf9\u8c61\uff0c\u7528\u4e8e\u5355\u72ec\u8bbe\u5b9a ',
|
990
|
+
n.a.createElement('code', null, 'showPreviewIcon'),
|
991
|
+
', ',
|
992
|
+
n.a.createElement('code', null, 'showRemoveIcon'),
|
993
|
+
', ',
|
994
|
+
n.a.createElement('code', null, 'showDownloadIcon'),
|
995
|
+
', ',
|
996
|
+
n.a.createElement('code', null, 'removeIcon'),
|
997
|
+
' \u548c ',
|
998
|
+
n.a.createElement('code', null, 'downloadIcon'),
|
999
|
+
),
|
1000
|
+
n.a.createElement(
|
1001
|
+
'td',
|
1002
|
+
null,
|
1003
|
+
'boolean | ',
|
1004
|
+
'{',
|
1005
|
+
' showPreviewIcon?: boolean, showRemoveIcon?: boolean, showDownloadIcon?: boolean, removeIcon?: ReactNode | (file: UploadFile) => ReactNode, downloadIcon?: ReactNode | (file: UploadFile) => ReactNode ',
|
1006
|
+
'}',
|
1007
|
+
),
|
1008
|
+
n.a.createElement('td', null, 'true'),
|
1009
|
+
n.a.createElement('td', null, 'function: 4.7.0'),
|
1010
|
+
),
|
1011
|
+
n.a.createElement(
|
1012
|
+
'tr',
|
1013
|
+
null,
|
1014
|
+
n.a.createElement('td', null, 'withCredentials'),
|
1015
|
+
n.a.createElement(
|
1016
|
+
'td',
|
1017
|
+
null,
|
1018
|
+
'\u4e0a\u4f20\u8bf7\u6c42\u65f6\u662f\u5426\u643a\u5e26 cookie',
|
1019
|
+
),
|
1020
|
+
n.a.createElement('td', null, 'boolean'),
|
1021
|
+
n.a.createElement('td', null, 'false'),
|
1022
|
+
n.a.createElement('td', null),
|
1023
|
+
),
|
1024
|
+
n.a.createElement(
|
1025
|
+
'tr',
|
1026
|
+
null,
|
1027
|
+
n.a.createElement('td', null, 'onChange'),
|
1028
|
+
n.a.createElement(
|
1029
|
+
'td',
|
1030
|
+
null,
|
1031
|
+
'\u4e0a\u4f20\u6587\u4ef6\u6539\u53d8\u65f6\u7684\u72b6\u6001\uff0c\u8be6\u89c1 ',
|
1032
|
+
n.a.createElement(
|
1033
|
+
r['AnchorLink'],
|
1034
|
+
{ to: '#onChange' },
|
1035
|
+
'onChange',
|
1036
|
+
),
|
1037
|
+
),
|
1038
|
+
n.a.createElement('td', null, 'function'),
|
1039
|
+
n.a.createElement('td', null, '-'),
|
1040
|
+
n.a.createElement('td', null),
|
1041
|
+
),
|
1042
|
+
n.a.createElement(
|
1043
|
+
'tr',
|
1044
|
+
null,
|
1045
|
+
n.a.createElement('td', null, 'onDrop'),
|
1046
|
+
n.a.createElement(
|
1047
|
+
'td',
|
1048
|
+
null,
|
1049
|
+
'\u5f53\u6587\u4ef6\u88ab\u62d6\u5165\u4e0a\u4f20\u533a\u57df\u65f6\u6267\u884c\u7684\u56de\u8c03\u529f\u80fd',
|
1050
|
+
),
|
1051
|
+
n.a.createElement(
|
1052
|
+
'td',
|
1053
|
+
null,
|
1054
|
+
'(event: React.DragEvent) => void',
|
1055
|
+
),
|
1056
|
+
n.a.createElement('td', null, '-'),
|
1057
|
+
n.a.createElement('td', null, '4.16.0'),
|
1058
|
+
),
|
1059
|
+
n.a.createElement(
|
1060
|
+
'tr',
|
1061
|
+
null,
|
1062
|
+
n.a.createElement('td', null, 'onDownload'),
|
1063
|
+
n.a.createElement(
|
1064
|
+
'td',
|
1065
|
+
null,
|
1066
|
+
'\u70b9\u51fb\u4e0b\u8f7d\u6587\u4ef6\u65f6\u7684\u56de\u8c03\uff0c\u5982\u679c\u6ca1\u6709\u6307\u5b9a\uff0c\u5219\u9ed8\u8ba4\u8df3\u8f6c\u5230\u6587\u4ef6 url \u5bf9\u5e94\u7684\u6807\u7b7e\u9875',
|
1067
|
+
),
|
1068
|
+
n.a.createElement('td', null, 'function(file): void'),
|
1069
|
+
n.a.createElement(
|
1070
|
+
'td',
|
1071
|
+
null,
|
1072
|
+
'(\u8df3\u8f6c\u65b0\u6807\u7b7e\u9875)',
|
1073
|
+
),
|
1074
|
+
n.a.createElement('td', null),
|
1075
|
+
),
|
1076
|
+
n.a.createElement(
|
1077
|
+
'tr',
|
1078
|
+
null,
|
1079
|
+
n.a.createElement('td', null, 'onPreview'),
|
1080
|
+
n.a.createElement(
|
1081
|
+
'td',
|
1082
|
+
null,
|
1083
|
+
'\u70b9\u51fb\u6587\u4ef6\u94fe\u63a5\u6216\u9884\u89c8\u56fe\u6807\u65f6\u7684\u56de\u8c03',
|
1084
|
+
),
|
1085
|
+
n.a.createElement('td', null, 'function(file)'),
|
1086
|
+
n.a.createElement('td', null, '-'),
|
1087
|
+
n.a.createElement('td', null),
|
1088
|
+
),
|
1089
|
+
n.a.createElement(
|
1090
|
+
'tr',
|
1091
|
+
null,
|
1092
|
+
n.a.createElement('td', null, 'onRemove \xa0'),
|
1093
|
+
n.a.createElement(
|
1094
|
+
'td',
|
1095
|
+
null,
|
1096
|
+
'\u70b9\u51fb\u79fb\u9664\u6587\u4ef6\u65f6\u7684\u56de\u8c03\uff0c\u8fd4\u56de\u503c\u4e3a false \u65f6\u4e0d\u79fb\u9664\u3002\u652f\u6301\u8fd4\u56de\u4e00\u4e2a Promise \u5bf9\u8c61\uff0cPromise \u5bf9\u8c61 resolve(false) \u6216 reject \u65f6\u4e0d\u79fb\u9664 \xa0 \xa0 \xa0 \xa0 \xa0 \xa0 \xa0',
|
1097
|
+
),
|
1098
|
+
n.a.createElement(
|
1099
|
+
'td',
|
1100
|
+
null,
|
1101
|
+
'function(file): boolean | Promise',
|
1102
|
+
),
|
1103
|
+
n.a.createElement('td', null, '- \xa0'),
|
1104
|
+
n.a.createElement('td', null),
|
1105
|
+
),
|
1106
|
+
),
|
1107
|
+
),
|
1108
|
+
n.a.createElement(
|
1109
|
+
'h3',
|
1110
|
+
{ id: 'uploadfile' },
|
1111
|
+
n.a.createElement(
|
1112
|
+
r['AnchorLink'],
|
1113
|
+
{ to: '#uploadfile', 'aria-hidden': 'true', tabIndex: -1 },
|
1114
|
+
n.a.createElement('span', { className: 'icon icon-link' }),
|
1115
|
+
),
|
1116
|
+
'UploadFile',
|
1117
|
+
),
|
1118
|
+
n.a.createElement(
|
1119
|
+
'p',
|
1120
|
+
null,
|
1121
|
+
'\u7ee7\u627f\u81ea File\uff0c\u9644\u5e26\u989d\u5916\u5c5e\u6027\u7528\u4e8e\u6e32\u67d3\u3002',
|
1122
|
+
),
|
1123
|
+
n.a.createElement(
|
1124
|
+
'table',
|
1125
|
+
null,
|
1126
|
+
n.a.createElement(
|
1127
|
+
'thead',
|
1128
|
+
null,
|
1129
|
+
n.a.createElement(
|
1130
|
+
'tr',
|
1131
|
+
null,
|
1132
|
+
n.a.createElement('th', null, '\u53c2\u6570'),
|
1133
|
+
n.a.createElement('th', null, '\u8bf4\u660e'),
|
1134
|
+
n.a.createElement('th', null, '\u7c7b\u578b'),
|
1135
|
+
n.a.createElement('th', null, '\u9ed8\u8ba4\u503c'),
|
1136
|
+
),
|
1137
|
+
),
|
1138
|
+
n.a.createElement(
|
1139
|
+
'tbody',
|
1140
|
+
null,
|
1141
|
+
n.a.createElement(
|
1142
|
+
'tr',
|
1143
|
+
null,
|
1144
|
+
n.a.createElement('td', null, 'name'),
|
1145
|
+
n.a.createElement('td', null, '\u6587\u4ef6\u540d'),
|
1146
|
+
n.a.createElement('td', null, 'string'),
|
1147
|
+
n.a.createElement('td', null, '-'),
|
1148
|
+
),
|
1149
|
+
n.a.createElement(
|
1150
|
+
'tr',
|
1151
|
+
null,
|
1152
|
+
n.a.createElement('td', null, 'percent'),
|
1153
|
+
n.a.createElement('td', null, '\u4e0a\u4f20\u8fdb\u5ea6'),
|
1154
|
+
n.a.createElement('td', null, 'number'),
|
1155
|
+
n.a.createElement('td', null, '-'),
|
1156
|
+
),
|
1157
|
+
n.a.createElement(
|
1158
|
+
'tr',
|
1159
|
+
null,
|
1160
|
+
n.a.createElement('td', null, 'status'),
|
1161
|
+
n.a.createElement(
|
1162
|
+
'td',
|
1163
|
+
null,
|
1164
|
+
'\u4e0a\u4f20\u72b6\u6001\uff0c\u4e0d\u540c\u72b6\u6001\u5c55\u793a\u989c\u8272\u4e5f\u4f1a\u6709\u6240\u4e0d\u540c',
|
1165
|
+
),
|
1166
|
+
n.a.createElement(
|
1167
|
+
'td',
|
1168
|
+
null,
|
1169
|
+
n.a.createElement('code', null, 'error'),
|
1170
|
+
' | ',
|
1171
|
+
n.a.createElement('code', null, 'success'),
|
1172
|
+
' | ',
|
1173
|
+
n.a.createElement('code', null, 'done'),
|
1174
|
+
' | ',
|
1175
|
+
n.a.createElement('code', null, 'uploading'),
|
1176
|
+
' | ',
|
1177
|
+
n.a.createElement('code', null, 'removed'),
|
1178
|
+
),
|
1179
|
+
n.a.createElement('td', null, '-'),
|
1180
|
+
),
|
1181
|
+
n.a.createElement(
|
1182
|
+
'tr',
|
1183
|
+
null,
|
1184
|
+
n.a.createElement('td', null, 'thumbUrl'),
|
1185
|
+
n.a.createElement(
|
1186
|
+
'td',
|
1187
|
+
null,
|
1188
|
+
'\u7f29\u7565\u56fe\u5730\u5740',
|
1189
|
+
),
|
1190
|
+
n.a.createElement('td', null, 'string'),
|
1191
|
+
n.a.createElement('td', null, '-'),
|
1192
|
+
),
|
1193
|
+
n.a.createElement(
|
1194
|
+
'tr',
|
1195
|
+
null,
|
1196
|
+
n.a.createElement('td', null, 'uid'),
|
1197
|
+
n.a.createElement(
|
1198
|
+
'td',
|
1199
|
+
null,
|
1200
|
+
'\u552f\u4e00\u6807\u8bc6\u7b26\uff0c\u4e0d\u8bbe\u7f6e\u65f6\u4f1a\u81ea\u52a8\u751f\u6210',
|
1201
|
+
),
|
1202
|
+
n.a.createElement('td', null, 'string'),
|
1203
|
+
n.a.createElement('td', null, '-'),
|
1204
|
+
),
|
1205
|
+
n.a.createElement(
|
1206
|
+
'tr',
|
1207
|
+
null,
|
1208
|
+
n.a.createElement('td', null, 'url'),
|
1209
|
+
n.a.createElement('td', null, '\u4e0b\u8f7d\u5730\u5740'),
|
1210
|
+
n.a.createElement('td', null, 'string'),
|
1211
|
+
n.a.createElement('td', null, '-'),
|
1212
|
+
),
|
1213
|
+
),
|
1214
|
+
),
|
1215
|
+
n.a.createElement(
|
1216
|
+
'h3',
|
1217
|
+
{ id: 'onchange' },
|
1218
|
+
n.a.createElement(
|
1219
|
+
r['AnchorLink'],
|
1220
|
+
{ to: '#onchange', 'aria-hidden': 'true', tabIndex: -1 },
|
1221
|
+
n.a.createElement('span', { className: 'icon icon-link' }),
|
1222
|
+
),
|
1223
|
+
'onChange',
|
1224
|
+
),
|
1225
|
+
n.a.createElement(
|
1226
|
+
'blockquote',
|
1227
|
+
null,
|
1228
|
+
n.a.createElement(
|
1229
|
+
'p',
|
1230
|
+
null,
|
1231
|
+
'\u4e0a\u4f20\u4e2d\u3001\u5b8c\u6210\u3001\u5931\u8d25\u90fd\u4f1a\u8c03\u7528\u8fd9\u4e2a\u51fd\u6570\u3002',
|
1232
|
+
),
|
1233
|
+
),
|
1234
|
+
n.a.createElement(
|
1235
|
+
'p',
|
1236
|
+
null,
|
1237
|
+
'\u6587\u4ef6\u72b6\u6001\u6539\u53d8\u7684\u56de\u8c03\uff0c\u8fd4\u56de\u4e3a\uff1a',
|
1238
|
+
),
|
1239
|
+
n.a.createElement(o['a'], {
|
1240
|
+
code: '{\n file: { /* ... */ },\n fileList: [ /* ... */ ],\n event: { /* ... */ },\n}',
|
1241
|
+
lang: 'bash',
|
1242
|
+
}),
|
1243
|
+
n.a.createElement(
|
1244
|
+
'ol',
|
1245
|
+
null,
|
1246
|
+
n.a.createElement(
|
1247
|
+
'li',
|
1248
|
+
null,
|
1249
|
+
n.a.createElement(
|
1250
|
+
'p',
|
1251
|
+
null,
|
1252
|
+
n.a.createElement('code', null, 'file'),
|
1253
|
+
' \u5f53\u524d\u64cd\u4f5c\u7684\u6587\u4ef6\u5bf9\u8c61\u3002',
|
1254
|
+
),
|
1255
|
+
n.a.createElement(o['a'], {
|
1256
|
+
code: "{\n uid: 'uid', // \u6587\u4ef6\u552f\u4e00\u6807\u8bc6\uff0c\u5efa\u8bae\u8bbe\u7f6e\u4e3a\u8d1f\u6570\uff0c\u9632\u6b62\u548c\u5185\u90e8\u4ea7\u751f\u7684 id \u51b2\u7a81\n name: 'xx.png' // \u6587\u4ef6\u540d\n status: 'done', // \u72b6\u6001\u6709\uff1auploading done error removed\uff0c\u88ab beforeUpload \u62e6\u622a\u7684\u6587\u4ef6\u6ca1\u6709 status \u5c5e\u6027\n response: '{\"status\": \"success\"}', // \u670d\u52a1\u7aef\u54cd\u5e94\u5185\u5bb9\n linkProps: '{\"download\": \"image\"}', // \u4e0b\u8f7d\u94fe\u63a5\u989d\u5916\u7684 HTML \u5c5e\u6027\n}",
|
1257
|
+
lang: 'bash',
|
1258
|
+
}),
|
1259
|
+
),
|
1260
|
+
n.a.createElement(
|
1261
|
+
'li',
|
1262
|
+
null,
|
1263
|
+
n.a.createElement(
|
1264
|
+
'p',
|
1265
|
+
null,
|
1266
|
+
n.a.createElement('code', null, 'fileList'),
|
1267
|
+
' \u5f53\u524d\u7684\u6587\u4ef6\u5217\u8868\u3002',
|
1268
|
+
),
|
1269
|
+
),
|
1270
|
+
n.a.createElement(
|
1271
|
+
'li',
|
1272
|
+
null,
|
1273
|
+
n.a.createElement(
|
1274
|
+
'p',
|
1275
|
+
null,
|
1276
|
+
n.a.createElement('code', null, 'event'),
|
1277
|
+
' \u4e0a\u4f20\u4e2d\u7684\u670d\u52a1\u7aef\u54cd\u5e94\u5185\u5bb9\uff0c\u5305\u542b\u4e86\u4e0a\u4f20\u8fdb\u5ea6\u7b49\u4fe1\u606f\uff0c\u9ad8\u7ea7\u6d4f\u89c8\u5668\u652f\u6301\u3002',
|
1278
|
+
),
|
1279
|
+
),
|
1280
|
+
),
|
1281
|
+
n.a.createElement(
|
1282
|
+
'h2',
|
1283
|
+
{ id: 'faq' },
|
1284
|
+
n.a.createElement(
|
1285
|
+
r['AnchorLink'],
|
1286
|
+
{ to: '#faq', 'aria-hidden': 'true', tabIndex: -1 },
|
1287
|
+
n.a.createElement('span', { className: 'icon icon-link' }),
|
1288
|
+
),
|
1289
|
+
'FAQ',
|
1290
|
+
),
|
1291
|
+
n.a.createElement(
|
1292
|
+
'h3',
|
1293
|
+
{ id: '\u670d\u52a1\u7aef\u5982\u4f55\u5b9e\u73b0' },
|
1294
|
+
n.a.createElement(
|
1295
|
+
r['AnchorLink'],
|
1296
|
+
{
|
1297
|
+
to: '#\u670d\u52a1\u7aef\u5982\u4f55\u5b9e\u73b0',
|
1298
|
+
'aria-hidden': 'true',
|
1299
|
+
tabIndex: -1,
|
1300
|
+
},
|
1301
|
+
n.a.createElement('span', { className: 'icon icon-link' }),
|
1302
|
+
),
|
1303
|
+
'\u670d\u52a1\u7aef\u5982\u4f55\u5b9e\u73b0\uff1f',
|
1304
|
+
),
|
1305
|
+
n.a.createElement(
|
1306
|
+
'ul',
|
1307
|
+
null,
|
1308
|
+
n.a.createElement(
|
1309
|
+
'li',
|
1310
|
+
null,
|
1311
|
+
'\u670d\u52a1\u7aef\u4e0a\u4f20\u63a5\u53e3\u5b9e\u73b0\u53ef\u4ee5\u53c2\u8003 ',
|
1312
|
+
n.a.createElement(
|
1313
|
+
r['Link'],
|
1314
|
+
{
|
1315
|
+
to: 'https://github.com/blueimp/jQuery-File-Upload/wiki#server-side',
|
1316
|
+
},
|
1317
|
+
'jQuery-File-Upload',
|
1318
|
+
),
|
1319
|
+
'\u3002',
|
1320
|
+
),
|
1321
|
+
n.a.createElement(
|
1322
|
+
'li',
|
1323
|
+
null,
|
1324
|
+
'\u5982\u679c\u8981\u505a\u672c\u5730 mock \u53ef\u4ee5\u53c2\u8003\u8fd9\u4e2a ',
|
1325
|
+
n.a.createElement(
|
1326
|
+
r['Link'],
|
1327
|
+
{
|
1328
|
+
to: 'https://github.com/react-component/upload/blob/master/server.js',
|
1329
|
+
},
|
1330
|
+
'express \u7684\u4f8b\u5b50',
|
1331
|
+
),
|
1332
|
+
'\u3002',
|
1333
|
+
),
|
1334
|
+
),
|
1335
|
+
n.a.createElement(
|
1336
|
+
'h3',
|
1337
|
+
{ id: '\u5982\u4f55\u663e\u793a\u4e0b\u8f7d\u94fe\u63a5' },
|
1338
|
+
n.a.createElement(
|
1339
|
+
r['AnchorLink'],
|
1340
|
+
{
|
1341
|
+
to: '#\u5982\u4f55\u663e\u793a\u4e0b\u8f7d\u94fe\u63a5',
|
1342
|
+
'aria-hidden': 'true',
|
1343
|
+
tabIndex: -1,
|
1344
|
+
},
|
1345
|
+
n.a.createElement('span', { className: 'icon icon-link' }),
|
1346
|
+
),
|
1347
|
+
'\u5982\u4f55\u663e\u793a\u4e0b\u8f7d\u94fe\u63a5\uff1f',
|
1348
|
+
),
|
1349
|
+
n.a.createElement(
|
1350
|
+
'p',
|
1351
|
+
null,
|
1352
|
+
'\u8bf7\u4f7f\u7528 fileList \u5c5e\u6027\u8bbe\u7f6e\u6570\u7ec4\u9879\u7684 url \u5c5e\u6027\u8fdb\u884c\u5c55\u793a\u63a7\u5236\u3002',
|
1353
|
+
),
|
1354
|
+
n.a.createElement(
|
1355
|
+
'h3',
|
1356
|
+
{ id: 'customrequest-\u600e\u4e48\u4f7f\u7528' },
|
1357
|
+
n.a.createElement(
|
1358
|
+
r['AnchorLink'],
|
1359
|
+
{
|
1360
|
+
to: '#customrequest-\u600e\u4e48\u4f7f\u7528',
|
1361
|
+
'aria-hidden': 'true',
|
1362
|
+
tabIndex: -1,
|
1363
|
+
},
|
1364
|
+
n.a.createElement('span', { className: 'icon icon-link' }),
|
1365
|
+
),
|
1366
|
+
n.a.createElement('code', null, 'customRequest'),
|
1367
|
+
' \u600e\u4e48\u4f7f\u7528\uff1f',
|
1368
|
+
),
|
1369
|
+
n.a.createElement(
|
1370
|
+
'p',
|
1371
|
+
null,
|
1372
|
+
'\u8bf7\u53c2\u8003 ',
|
1373
|
+
n.a.createElement(
|
1374
|
+
r['Link'],
|
1375
|
+
{
|
1376
|
+
to: 'https://github.com/react-component/upload#customrequest',
|
1377
|
+
},
|
1378
|
+
'https://github.com/react-component/upload#customrequest',
|
1379
|
+
),
|
1380
|
+
'\u3002',
|
1381
|
+
),
|
1382
|
+
n.a.createElement(
|
1383
|
+
'h3',
|
1384
|
+
{
|
1385
|
+
id: '\u4e3a\u4f55-filelist-\u53d7\u63a7\u65f6\u4e0a\u4f20\u4e0d\u5728\u5217\u8868\u4e2d\u7684\u6587\u4ef6\u4e0d\u4f1a\u89e6\u53d1-onchange-\u540e\u7eed\u7684-status-\u66f4\u65b0\u4e8b\u4ef6',
|
1386
|
+
},
|
1387
|
+
n.a.createElement(
|
1388
|
+
r['AnchorLink'],
|
1389
|
+
{
|
1390
|
+
to: '#\u4e3a\u4f55-filelist-\u53d7\u63a7\u65f6\u4e0a\u4f20\u4e0d\u5728\u5217\u8868\u4e2d\u7684\u6587\u4ef6\u4e0d\u4f1a\u89e6\u53d1-onchange-\u540e\u7eed\u7684-status-\u66f4\u65b0\u4e8b\u4ef6',
|
1391
|
+
'aria-hidden': 'true',
|
1392
|
+
tabIndex: -1,
|
1393
|
+
},
|
1394
|
+
n.a.createElement('span', { className: 'icon icon-link' }),
|
1395
|
+
),
|
1396
|
+
'\u4e3a\u4f55 ',
|
1397
|
+
n.a.createElement('code', null, 'fileList'),
|
1398
|
+
' \u53d7\u63a7\u65f6\uff0c\u4e0a\u4f20\u4e0d\u5728\u5217\u8868\u4e2d\u7684\u6587\u4ef6\u4e0d\u4f1a\u89e6\u53d1 ',
|
1399
|
+
n.a.createElement('code', null, 'onChange'),
|
1400
|
+
' \u540e\u7eed\u7684 ',
|
1401
|
+
n.a.createElement('code', null, 'status'),
|
1402
|
+
' \u66f4\u65b0\u4e8b\u4ef6\uff1f',
|
1403
|
+
),
|
1404
|
+
n.a.createElement(
|
1405
|
+
'p',
|
1406
|
+
null,
|
1407
|
+
n.a.createElement('code', null, 'onChange'),
|
1408
|
+
' \u4e8b\u4ef6\u4ec5\u4f1a\u4f5c\u7528\u4e8e\u5728\u5217\u8868\u4e2d\u7684\u6587\u4ef6\uff0c\u56e0\u800c ',
|
1409
|
+
n.a.createElement('code', null, 'fileList'),
|
1410
|
+
' \u4e0d\u5b58\u5728\u5bf9\u5e94\u6587\u4ef6\u65f6\u540e\u7eed\u4e8b\u4ef6\u4f1a\u88ab\u5ffd\u7565\u3002\u8bf7\u6ce8\u610f\uff0c\u5728 ',
|
1411
|
+
n.a.createElement('code', null, '4.13.0'),
|
1412
|
+
' \u7248\u672c\u4e4b\u524d\u53d7\u63a7\u72b6\u6001\u5b58\u5728 bug \u5bfc\u81f4\u4e0d\u5728\u5217\u8868\u4e2d\u7684\u6587\u4ef6\u4e5f\u4f1a\u89e6\u53d1\u3002',
|
1413
|
+
),
|
1414
|
+
n.a.createElement(
|
1415
|
+
'h3',
|
1416
|
+
{
|
1417
|
+
id: 'onchange-\u4e3a\u4ec0\u4e48\u6709\u65f6\u5019\u8fd4\u56de-file-\u6709\u65f6\u5019\u8fd4\u56de--originfileobj-file-',
|
1418
|
+
},
|
1419
|
+
n.a.createElement(
|
1420
|
+
r['AnchorLink'],
|
1421
|
+
{
|
1422
|
+
to: '#onchange-\u4e3a\u4ec0\u4e48\u6709\u65f6\u5019\u8fd4\u56de-file-\u6709\u65f6\u5019\u8fd4\u56de--originfileobj-file-',
|
1423
|
+
'aria-hidden': 'true',
|
1424
|
+
tabIndex: -1,
|
1425
|
+
},
|
1426
|
+
n.a.createElement('span', { className: 'icon icon-link' }),
|
1427
|
+
),
|
1428
|
+
n.a.createElement('code', null, 'onChange'),
|
1429
|
+
' \u4e3a\u4ec0\u4e48\u6709\u65f6\u5019\u8fd4\u56de File \u6709\u65f6\u5019\u8fd4\u56de ',
|
1430
|
+
'{',
|
1431
|
+
' originFileObj: File ',
|
1432
|
+
'}',
|
1433
|
+
'\uff1f',
|
1434
|
+
),
|
1435
|
+
n.a.createElement(
|
1436
|
+
'p',
|
1437
|
+
null,
|
1438
|
+
'\u5386\u53f2\u539f\u56e0\uff0c\u5728 ',
|
1439
|
+
n.a.createElement('code', null, 'beforeUpload'),
|
1440
|
+
' \u8fd4\u56de ',
|
1441
|
+
n.a.createElement('code', null, 'false'),
|
1442
|
+
' \u65f6\uff0c\u4f1a\u8fd4\u56de File \u5bf9\u8c61\u3002\u5728\u4e0b\u4e2a\u5927\u7248\u672c\u6211\u4eec\u4f1a\u7edf\u4e00\u8fd4\u56de ',
|
1443
|
+
n.a.createElement(
|
1444
|
+
'code',
|
1445
|
+
null,
|
1446
|
+
'{',
|
1447
|
+
' originFileObj: File ',
|
1448
|
+
'}',
|
1449
|
+
),
|
1450
|
+
' \u5bf9\u8c61\u3002\u5f53\u524d\u7248\u672c\u5df2\u7ecf\u517c\u5bb9\u6240\u6709\u573a\u666f\u4e0b ',
|
1451
|
+
n.a.createElement('code', null, 'info.file.originFileObj'),
|
1452
|
+
' \u83b7\u53d6\u539f File \u5199\u6cd5\u3002\u4f60\u53ef\u4ee5\u63d0\u524d\u5207\u6362\u3002',
|
1453
|
+
),
|
1454
|
+
n.a.createElement('style', {
|
1455
|
+
dangerouslySetInnerHTML: {
|
1456
|
+
__html:
|
1457
|
+
"\n.avatar-uploader > .ant-upload {\n width: 128px;\n height: 128px;\n}\n\n.upload-list-inline .ant-upload-list-item {\n float: left;\n width: 200px;\n margin-right: 8px;\n}\n\n.upload-list-inline [class*='-upload-list-rtl'] .ant-upload-list-item {\n float: right;\n}\n\n.ant-upload-draggable-list-item {\n border-top: 2px dashed rgba(0, 0, 0, 0);\n border-bottom: 2px dashed rgba(0, 0, 0, 0);\n}\n.ant-upload-draggable-list-item.drop-over-downward {\n border-bottom-color: #1890ff;\n}\n.ant-upload-draggable-list-item.drop-over-upward {\n border-top-color: #1890ff;\n}\n\n",
|
1458
|
+
},
|
1459
|
+
}),
|
1460
|
+
),
|
1461
|
+
),
|
1462
|
+
)
|
1463
|
+
);
|
1464
|
+
},
|
1465
|
+
MZF8: function (e, t, a) {
|
1466
|
+
'use strict';
|
1467
|
+
var l = a('ogwx');
|
1468
|
+
a.d(t, 'a', function () {
|
1469
|
+
return l['b'];
|
1470
|
+
});
|
1471
|
+
a('VCU9');
|
1472
|
+
},
|
1473
|
+
RZMt: function (e, t, a) {},
|
1474
|
+
Zxc8: function (e, t, a) {
|
1475
|
+
'use strict';
|
1476
|
+
a.r(t);
|
1477
|
+
var l = a('q1tI'),
|
1478
|
+
n = a.n(l),
|
1479
|
+
r = a('k3GJ'),
|
1480
|
+
c = a('MZF8'),
|
1481
|
+
o = a('dEAq'),
|
1482
|
+
m = a('H1Ra');
|
1483
|
+
a('RZMt');
|
1484
|
+
function d(e, t) {
|
1485
|
+
return p(e) || s(e, t) || u(e, t) || i();
|
1486
|
+
}
|
1487
|
+
function i() {
|
1488
|
+
throw new TypeError(
|
1489
|
+
'Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.',
|
1490
|
+
);
|
1491
|
+
}
|
1492
|
+
function u(e, t) {
|
1493
|
+
if (e) {
|
1494
|
+
if ('string' === typeof e) return E(e, t);
|
1495
|
+
var a = Object.prototype.toString.call(e).slice(8, -1);
|
1496
|
+
return (
|
1497
|
+
'Object' === a && e.constructor && (a = e.constructor.name),
|
1498
|
+
'Map' === a || 'Set' === a
|
1499
|
+
? Array.from(e)
|
1500
|
+
: 'Arguments' === a ||
|
1501
|
+
/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(a)
|
1502
|
+
? E(e, t)
|
1503
|
+
: void 0
|
1504
|
+
);
|
1505
|
+
}
|
1506
|
+
}
|
1507
|
+
function E(e, t) {
|
1508
|
+
(null == t || t > e.length) && (t = e.length);
|
1509
|
+
for (var a = 0, l = new Array(t); a < t; a++) l[a] = e[a];
|
1510
|
+
return l;
|
1511
|
+
}
|
1512
|
+
function s(e, t) {
|
1513
|
+
var a =
|
1514
|
+
null == e
|
1515
|
+
? null
|
1516
|
+
: ('undefined' !== typeof Symbol && e[Symbol.iterator]) ||
|
1517
|
+
e['@@iterator'];
|
1518
|
+
if (null != a) {
|
1519
|
+
var l,
|
1520
|
+
n,
|
1521
|
+
r = [],
|
1522
|
+
c = !0,
|
1523
|
+
o = !1;
|
1524
|
+
try {
|
1525
|
+
for (a = a.call(e); !(c = (l = a.next()).done); c = !0)
|
1526
|
+
if ((r.push(l.value), t && r.length === t)) break;
|
1527
|
+
} catch (m) {
|
1528
|
+
(o = !0), (n = m);
|
1529
|
+
} finally {
|
1530
|
+
try {
|
1531
|
+
c || null == a['return'] || a['return']();
|
1532
|
+
} finally {
|
1533
|
+
if (o) throw n;
|
1534
|
+
}
|
1535
|
+
}
|
1536
|
+
return r;
|
1537
|
+
}
|
1538
|
+
}
|
1539
|
+
function p(e) {
|
1540
|
+
if (Array.isArray(e)) return e;
|
1541
|
+
}
|
1542
|
+
function f(e, t) {
|
1543
|
+
var a,
|
1544
|
+
l =
|
1545
|
+
null === (a = e.match(/\.(\w+)$/)) || void 0 === a ? void 0 : a[1];
|
1546
|
+
return l || (l = t.tsx ? 'tsx' : 'jsx'), l;
|
1547
|
+
}
|
1548
|
+
var h = function (e) {
|
1549
|
+
var t,
|
1550
|
+
a,
|
1551
|
+
i,
|
1552
|
+
u = Object(l['useRef'])(),
|
1553
|
+
E = Object(l['useContext'])(o['context']),
|
1554
|
+
s = E.locale,
|
1555
|
+
p = Object(o['useLocaleProps'])(s, e),
|
1556
|
+
h = Object(o['useDemoUrl'])(p.identifier),
|
1557
|
+
b = p.demoUrl || h,
|
1558
|
+
v =
|
1559
|
+
(null === c['a'] || void 0 === c['a']
|
1560
|
+
? void 0
|
1561
|
+
: c['a'].location.hash) === '#'.concat(p.identifier),
|
1562
|
+
k = 1 === Object.keys(p.sources).length,
|
1563
|
+
g = Object(o['useCodeSandbox'])(
|
1564
|
+
(
|
1565
|
+
null === (t = p.hideActions) || void 0 === t
|
1566
|
+
? void 0
|
1567
|
+
: t.includes('CSB')
|
1568
|
+
)
|
1569
|
+
? null
|
1570
|
+
: p,
|
1571
|
+
),
|
1572
|
+
w = Object(o['useRiddle'])(
|
1573
|
+
(
|
1574
|
+
null === (a = p.hideActions) || void 0 === a
|
1575
|
+
? void 0
|
1576
|
+
: a.includes('RIDDLE')
|
1577
|
+
)
|
1578
|
+
? null
|
1579
|
+
: p,
|
1580
|
+
),
|
1581
|
+
N = Object(o['useMotions'])(p.motions || [], u.current),
|
1582
|
+
L = d(N, 2),
|
1583
|
+
x = L[0],
|
1584
|
+
I = L[1],
|
1585
|
+
y = Object(o['useCopy'])(),
|
1586
|
+
A = d(y, 2),
|
1587
|
+
_ = A[0],
|
1588
|
+
P = A[1],
|
1589
|
+
j = Object(l['useState'])('_'),
|
1590
|
+
C = d(j, 2),
|
1591
|
+
R = C[0],
|
1592
|
+
F = C[1],
|
1593
|
+
O = Object(l['useState'])(f(R, p.sources[R])),
|
1594
|
+
U = d(O, 2),
|
1595
|
+
S = U[0],
|
1596
|
+
T = U[1],
|
1597
|
+
q = Object(l['useState'])(Boolean(p.defaultShowCode)),
|
1598
|
+
M = d(q, 2),
|
1599
|
+
D = M[0],
|
1600
|
+
H = M[1],
|
1601
|
+
Z = Object(l['useState'])(Math.random()),
|
1602
|
+
B = d(Z, 2),
|
1603
|
+
J = B[0],
|
1604
|
+
G = B[1],
|
1605
|
+
$ = p.sources[R][S] || p.sources[R].content,
|
1606
|
+
z = Object(o['useTSPlaygroundUrl'])(s, $),
|
1607
|
+
Q = Object(l['useRef'])(),
|
1608
|
+
W = Object(o['usePrefersColor'])(),
|
1609
|
+
X = d(W, 1),
|
1610
|
+
K = X[0];
|
1611
|
+
function V(e) {
|
1612
|
+
F(e), T(f(e, p.sources[e]));
|
1613
|
+
}
|
1614
|
+
return (
|
1615
|
+
Object(l['useEffect'])(
|
1616
|
+
function () {
|
1617
|
+
G(Math.random());
|
1618
|
+
},
|
1619
|
+
[K],
|
1620
|
+
),
|
1621
|
+
n.a.createElement(
|
1622
|
+
'div',
|
1623
|
+
{
|
1624
|
+
style: p.style,
|
1625
|
+
className: [
|
1626
|
+
p.className,
|
1627
|
+
'__dumi-default-previewer',
|
1628
|
+
v ? '__dumi-default-previewer-target' : '',
|
1629
|
+
]
|
1630
|
+
.filter(Boolean)
|
1631
|
+
.join(' '),
|
1632
|
+
id: p.identifier,
|
1633
|
+
'data-debug': p.debug || void 0,
|
1634
|
+
'data-iframe': p.iframe || void 0,
|
1635
|
+
},
|
1636
|
+
p.iframe &&
|
1637
|
+
n.a.createElement('div', {
|
1638
|
+
className: '__dumi-default-previewer-browser-nav',
|
1639
|
+
}),
|
1640
|
+
n.a.createElement(
|
1641
|
+
'div',
|
1642
|
+
{
|
1643
|
+
ref: u,
|
1644
|
+
className: '__dumi-default-previewer-demo',
|
1645
|
+
style: {
|
1646
|
+
transform: p.transform ? 'translate(0, 0)' : void 0,
|
1647
|
+
padding:
|
1648
|
+
p.compact || (p.iframe && !1 !== p.compact) ? '0' : void 0,
|
1649
|
+
background: p.background,
|
1650
|
+
},
|
1651
|
+
},
|
1652
|
+
p.iframe
|
1653
|
+
? n.a.createElement('iframe', {
|
1654
|
+
title: 'dumi-previewer',
|
1655
|
+
style: {
|
1656
|
+
height: String(p.iframe).replace(/(\d)$/, '$1px'),
|
1657
|
+
},
|
1658
|
+
key: J,
|
1659
|
+
src: b,
|
1660
|
+
ref: Q,
|
1661
|
+
})
|
1662
|
+
: p.children,
|
1663
|
+
),
|
1664
|
+
n.a.createElement(
|
1665
|
+
'div',
|
1666
|
+
{
|
1667
|
+
className: '__dumi-default-previewer-desc',
|
1668
|
+
'data-title': p.title,
|
1669
|
+
},
|
1670
|
+
p.title &&
|
1671
|
+
n.a.createElement(
|
1672
|
+
o['AnchorLink'],
|
1673
|
+
{ to: '#'.concat(p.identifier) },
|
1674
|
+
p.title,
|
1675
|
+
),
|
1676
|
+
p.description &&
|
1677
|
+
n.a.createElement('div', {
|
1678
|
+
dangerouslySetInnerHTML: { __html: p.description },
|
1679
|
+
}),
|
1680
|
+
),
|
1681
|
+
n.a.createElement(
|
1682
|
+
'div',
|
1683
|
+
{ className: '__dumi-default-previewer-actions' },
|
1684
|
+
g &&
|
1685
|
+
n.a.createElement('button', {
|
1686
|
+
title: 'Open demo on CodeSandbox.io',
|
1687
|
+
className: '__dumi-default-icon',
|
1688
|
+
role: 'codesandbox',
|
1689
|
+
onClick: g,
|
1690
|
+
}),
|
1691
|
+
w &&
|
1692
|
+
n.a.createElement('button', {
|
1693
|
+
title: 'Open demo on Riddle',
|
1694
|
+
className: '__dumi-default-icon',
|
1695
|
+
role: 'riddle',
|
1696
|
+
onClick: w,
|
1697
|
+
}),
|
1698
|
+
p.motions &&
|
1699
|
+
n.a.createElement('button', {
|
1700
|
+
title: 'Execute motions',
|
1701
|
+
className: '__dumi-default-icon',
|
1702
|
+
role: 'motions',
|
1703
|
+
disabled: I,
|
1704
|
+
onClick: function () {
|
1705
|
+
return x();
|
1706
|
+
},
|
1707
|
+
}),
|
1708
|
+
p.iframe &&
|
1709
|
+
n.a.createElement('button', {
|
1710
|
+
title: 'Reload demo iframe page',
|
1711
|
+
className: '__dumi-default-icon',
|
1712
|
+
role: 'refresh',
|
1713
|
+
onClick: function () {
|
1714
|
+
return G(Math.random());
|
1715
|
+
},
|
1716
|
+
}),
|
1717
|
+
!(null === (i = p.hideActions) || void 0 === i
|
1718
|
+
? void 0
|
1719
|
+
: i.includes('EXTERNAL')) &&
|
1720
|
+
n.a.createElement(
|
1721
|
+
o['Link'],
|
1722
|
+
{ target: '_blank', to: b },
|
1723
|
+
n.a.createElement('button', {
|
1724
|
+
title: 'Open demo in new tab',
|
1725
|
+
className: '__dumi-default-icon',
|
1726
|
+
role: 'open-demo',
|
1727
|
+
type: 'button',
|
1728
|
+
}),
|
1729
|
+
),
|
1730
|
+
n.a.createElement('span', null),
|
1731
|
+
n.a.createElement('button', {
|
1732
|
+
title: 'Copy source code',
|
1733
|
+
className: '__dumi-default-icon',
|
1734
|
+
role: 'copy',
|
1735
|
+
'data-status': P,
|
1736
|
+
onClick: function () {
|
1737
|
+
return _($);
|
1738
|
+
},
|
1739
|
+
}),
|
1740
|
+
'tsx' === S &&
|
1741
|
+
D &&
|
1742
|
+
n.a.createElement(
|
1743
|
+
o['Link'],
|
1744
|
+
{ target: '_blank', to: z },
|
1745
|
+
n.a.createElement('button', {
|
1746
|
+
title: 'Get JSX via TypeScript Playground',
|
1747
|
+
className: '__dumi-default-icon',
|
1748
|
+
role: 'change-tsx',
|
1749
|
+
type: 'button',
|
1750
|
+
}),
|
1751
|
+
),
|
1752
|
+
n.a.createElement('button', {
|
1753
|
+
title: 'Toggle source code panel',
|
1754
|
+
className: '__dumi-default-icon'.concat(
|
1755
|
+
D ? ' __dumi-default-btn-expand' : '',
|
1756
|
+
),
|
1757
|
+
role: 'source',
|
1758
|
+
type: 'button',
|
1759
|
+
onClick: function () {
|
1760
|
+
return H(!D);
|
1761
|
+
},
|
1762
|
+
}),
|
1763
|
+
),
|
1764
|
+
D &&
|
1765
|
+
n.a.createElement(
|
1766
|
+
'div',
|
1767
|
+
{ className: '__dumi-default-previewer-source-wrapper' },
|
1768
|
+
!k &&
|
1769
|
+
n.a.createElement(
|
1770
|
+
r['b'],
|
1771
|
+
{
|
1772
|
+
className: '__dumi-default-previewer-source-tab',
|
1773
|
+
prefixCls: '__dumi-default-tabs',
|
1774
|
+
moreIcon: '\xb7\xb7\xb7',
|
1775
|
+
defaultActiveKey: R,
|
1776
|
+
onChange: V,
|
1777
|
+
},
|
1778
|
+
Object.keys(p.sources).map(function (e) {
|
1779
|
+
return n.a.createElement(r['a'], {
|
1780
|
+
tab:
|
1781
|
+
'_' === e ? 'index.'.concat(f(e, p.sources[e])) : e,
|
1782
|
+
key: e,
|
1783
|
+
});
|
1784
|
+
}),
|
1785
|
+
),
|
1786
|
+
n.a.createElement(
|
1787
|
+
'div',
|
1788
|
+
{ className: '__dumi-default-previewer-source' },
|
1789
|
+
n.a.createElement(m['a'], { code: $, lang: S, showCopy: !1 }),
|
1790
|
+
),
|
1791
|
+
),
|
1792
|
+
)
|
1793
|
+
);
|
1794
|
+
};
|
1795
|
+
t['default'] = h;
|
1796
|
+
},
|
1797
|
+
},
|
1798
|
+
]);
|