{"version":3,"sources":["webpack:///./node_modules/ant-design-vue/es/upload/interface.js","webpack:///./node_modules/ant-design-vue/es/upload/Dragger.js","webpack:///./node_modules/ant-design-vue/es/upload/utils.js","webpack:///./node_modules/ant-design-vue/es/upload/UploadList.js","webpack:///./node_modules/ant-design-vue/es/upload/Upload.js","webpack:///./node_modules/ant-design-vue/es/upload/index.js"],"names":["oneOf","UploadFile","_ref","uid","name","includes","custom","arrayOf","object","ShowUploadListInterface","shape","showRemoveIcon","bool","showPreviewIcon","loose","UploadLocale","uploading","string","removeFile","downloadFile","uploadError","previewFile","UploadProps","type","defaultFileList","fileList","action","oneOfType","func","directory","data","method","headers","showUploadList","multiple","accept","beforeUpload","listType","remove","supportServerRender","disabled","prefixCls","customRequest","withCredentials","openFileDialogOnClick","locale","height","number","id","transformFile","UploadListProps","items","progressAttr","showDownloadIcon","props","render","h","arguments","this","draggerProps","on","style","Upload","$slots","T","fileToObject","file","lastModified","lastModifiedDate","size","percent","originFileObj","genPercentAdd","k","i","end","s","start","getFileItem","matchKey","undefined","filter","item","removeFileItem","removed","length","extname","url","temp","split","filename","filenameWithoutSuffix","exec","isImageFileType","indexOf","isImageUrl","thumbUrl","extension","test","MEASURE_SIZE","previewImage","Promise","resolve","canvas","document","createElement","width","cssText","body","appendChild","ctx","getContext","img","Image","onload","drawWidth","drawHeight","offsetX","offsetY","drawImage","dataURL","toDataURL","removeChild","src","window","URL","createObjectURL","mixins","BaseMixin","strokeWidth","showInfo","inject","configProvider","updated","_this","$nextTick","_$props","$props","forEach","FileReader","File","Blob","then","previewDataUrl","$forceUpdate","methods","handlePreview","e","_getListeners","preview","preventDefault","$emit","handleDownload","_getListeners2","download","open","handleClose","_classNames4","_this2","_getOptionProps","customizePrefixCls","_getOptionProps$items","getPrefixCls","list","map","_classNames","_classNames2","progress","icon","attrs","status","thumbnail","alt","theme","href","target","rel","progressProps","loadingProgress","key","infoUploadingClass","linkProps","JSON","parse","removeIcon","title","downloadIcon","downloadOrDelete","listItemNameClass","x","pointerEvents","opacity","previewIcon","actions","message","response","error","statusText","iconAndPreview","transitionProps","getTransitionProps","dom","listContainerNameClass","listClassNames","animationDirection","transitionGroupProps","tag","inheritAttrs","Dragger","progressTimer","sFileList","dragState","watch","val","beforeDestroy","clearProgressTimer","onStart","targetItem","nextFileList","concat","fileIndex","push","onChange","TEST_IE","autoUpdateProgress","onSuccess","xhr","onProgress","event","onError","onReject","handleRemove","onRemove","$data","ret","removedFileList","upload","abort","handleManualRemove","$refs","uploadRef","info","setState","onFileDrop","reBeforeUpload","stateFileList","result","clearInterval","_","getPercent","curPercent","setInterval","renderUploadList","$createElement","_getOptionProps$showU","propLocale","uploadListProps","UploadList","_getOptionProps2","_$data","vcUploadProps","success","reject","ref","$attrs","children","uploadList","LocaleReceiver","componentName","defaultLocale","scopedSlots","dragCls","some","uploadButtonCls","uploadButton","display","install","Vue","use","component"],"mappings":"0XAG8B,OAAWA,MAAM,CAAC,QAAS,UAAW,OAAQ,YAAa,YA2BzF,SAASC,EAAWC,GAClB,IAAIC,EAAMD,EAAKC,IACXC,EAAOF,EAAKE,KAEhB,SAAKD,GAAe,IAARA,OACP,CAAC,SAAU,UAAUE,SAAwB,qBAARF,EAAsB,YAAc,IAAQA,MACzE,KAATC,GAA+B,kBAATA,IAKpB,OAAWE,OAAOL,GACd,OAAWM,QAAQ,OAAWD,OAAOL,IACxC,OAAWO,OAHb,IAMIC,EAA0B,OAAWC,MAAM,CACpDC,eAAgB,OAAWC,KAC3BC,gBAAiB,OAAWD,OAC3BE,MAEQC,EAAe,OAAWL,MAAM,CACzCM,UAAW,OAAWC,OACtBC,WAAY,OAAWD,OACvBE,aAAc,OAAWF,OACzBG,YAAa,OAAWH,OACxBI,YAAa,OAAWJ,SACvBH,MAEQQ,EAAc,CACvBC,KAAM,OAAWvB,MAAM,CAAC,OAAQ,WAChCI,KAAM,OAAWa,OACjBO,gBAAiB,OAAWjB,QAAQ,OAAWD,OAAOL,IACtDwB,SAAU,OAAWlB,Q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,KAAM0D,GAC3BuN,EAAIE,UAAUvE,EAAQ5M,KAAM4M,IAGf","file":"js/chunk-vendors~3f03297a.e76c764c.js","sourcesContent":["import _typeof from 'babel-runtime/helpers/typeof';\nimport PropsTypes from '../_util/vue-types';\n\nexport var UploadFileStatus = PropsTypes.oneOf(['error', 'success', 'done', 'uploading', 'removed']);\n\n// export const HttpRequestHeader {\n// [key: string]: string;\n// }\n\n// export const UploadFile = PropsTypes.shape({\n// uid: PropsTypes.oneOfType([\n// PropsTypes.string,\n// PropsTypes.number,\n// ]),\n// size: PropsTypes.number,\n// name: PropsTypes.string,\n// filename: PropsTypes.string,\n// lastModified: PropsTypes.number,\n// lastModifiedDate: PropsTypes.any,\n// url: PropsTypes.string,\n// status: UploadFileStatus,\n// percent: PropsTypes.number,\n// thumbUrl: PropsTypes.string,\n// originFileObj: PropsTypes.any,\n// response: PropsTypes.any,\n// error: PropsTypes.any,\n// linkProps: PropsTypes.any,\n// type: PropsTypes.string,\n// }).loose\n\nfunction UploadFile(_ref) {\n var uid = _ref.uid,\n name = _ref.name;\n\n if (!uid && uid !== 0) return false;\n if (!['string', 'number'].includes(typeof uid === 'undefined' ? 'undefined' : _typeof(uid))) return false;\n if (name === '' || typeof name !== 'string') return false;\n return true;\n}\n\nexport var UploadChangeParam = {\n file: PropsTypes.custom(UploadFile),\n fileList: PropsTypes.arrayOf(PropsTypes.custom(UploadFile)),\n event: PropsTypes.object\n};\n\nexport var ShowUploadListInterface = PropsTypes.shape({\n showRemoveIcon: PropsTypes.bool,\n showPreviewIcon: PropsTypes.bool\n}).loose;\n\nexport var UploadLocale = PropsTypes.shape({\n uploading: PropsTypes.string,\n removeFile: PropsTypes.string,\n downloadFile: PropsTypes.string,\n uploadError: PropsTypes.string,\n previewFile: PropsTypes.string\n}).loose;\n\nexport var UploadProps = {\n type: PropsTypes.oneOf(['drag', 'select']),\n name: PropsTypes.string,\n defaultFileList: PropsTypes.arrayOf(PropsTypes.custom(UploadFile)),\n fileList: PropsTypes.arrayOf(PropsTypes.custom(UploadFile)),\n action: PropsTypes.oneOfType([PropsTypes.string, PropsTypes.func]),\n directory: PropsTypes.bool,\n data: PropsTypes.oneOfType([PropsTypes.object, PropsTypes.func]),\n method: PropsTypes.oneOf(['POST', 'PUT', 'post', 'put']),\n headers: PropsTypes.object,\n showUploadList: PropsTypes.oneOfType([PropsTypes.bool, ShowUploadListInterface]),\n multiple: PropsTypes.bool,\n accept: PropsTypes.string,\n beforeUpload: PropsTypes.func,\n // onChange: PropsTypes.func,\n listType: PropsTypes.oneOf(['text', 'picture', 'picture-card']),\n // className: PropsTypes.string,\n // onPreview: PropsTypes.func,\n remove: PropsTypes.func,\n supportServerRender: PropsTypes.bool,\n // style: PropsTypes.object,\n disabled: PropsTypes.bool,\n prefixCls: PropsTypes.string,\n customRequest: PropsTypes.func,\n withCredentials: PropsTypes.bool,\n openFileDialogOnClick: PropsTypes.bool,\n locale: UploadLocale,\n height: PropsTypes.number,\n id: PropsTypes.string,\n previewFile: PropsTypes.func,\n transformFile: PropsTypes.func\n};\n\nexport var UploadState = {\n fileList: PropsTypes.arrayOf(PropsTypes.custom(UploadFile)),\n dragState: PropsTypes.string\n};\n\nexport var UploadListProps = {\n listType: PropsTypes.oneOf(['text', 'picture', 'picture-card']),\n // onPreview: PropsTypes.func,\n // onRemove: PropsTypes.func,\n // items: PropsTypes.arrayOf(UploadFile),\n items: PropsTypes.arrayOf(PropsTypes.custom(UploadFile)),\n // items: PropsTypes.any,\n progressAttr: PropsTypes.object,\n prefixCls: PropsTypes.string,\n showRemoveIcon: PropsTypes.bool,\n showDownloadIcon: PropsTypes.bool,\n showPreviewIcon: PropsTypes.bool,\n locale: UploadLocale,\n previewFile: PropsTypes.func\n};","import _extends from 'babel-runtime/helpers/extends';\nimport { getOptionProps, getListeners } from '../_util/props-util';\nimport Upload from './Upload';\nimport { UploadProps } from './interface';\n\nexport default {\n name: 'AUploadDragger',\n props: UploadProps,\n render: function render() {\n var h = arguments[0];\n\n var props = getOptionProps(this);\n var draggerProps = {\n props: _extends({}, props, {\n type: 'drag'\n }),\n on: getListeners(this),\n style: { height: this.height }\n };\n return h(\n Upload,\n draggerProps,\n [this.$slots['default']]\n );\n }\n};","import _extends from 'babel-runtime/helpers/extends';\nexport function T() {\n return true;\n}\n\n// Fix IE file.status problem\n// via coping a new Object\nexport function fileToObject(file) {\n return _extends({}, file, {\n lastModified: file.lastModified,\n lastModifiedDate: file.lastModifiedDate,\n name: file.name,\n size: file.size,\n type: file.type,\n uid: file.uid,\n percent: 0,\n originFileObj: file\n });\n}\n\n/**\n * 生成Progress percent: 0.1 -> 0.98\n * - for ie\n */\nexport function genPercentAdd() {\n var k = 0.1;\n var i = 0.01;\n var end = 0.98;\n return function (s) {\n var start = s;\n if (start >= end) {\n return start;\n }\n\n start += k;\n k = k - i;\n if (k < 0.001) {\n k = 0.001;\n }\n return start;\n };\n}\n\nexport function getFileItem(file, fileList) {\n var matchKey = file.uid !== undefined ? 'uid' : 'name';\n return fileList.filter(function (item) {\n return item[matchKey] === file[matchKey];\n })[0];\n}\n\nexport function removeFileItem(file, fileList) {\n var matchKey = file.uid !== undefined ? 'uid' : 'name';\n var removed = fileList.filter(function (item) {\n return item[matchKey] !== file[matchKey];\n });\n if (removed.length === fileList.length) {\n return null;\n }\n return removed;\n}\n\n// ==================== Default Image Preview ====================\nvar extname = function extname() {\n var url = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : '';\n\n var temp = url.split('/');\n var filename = temp[temp.length - 1];\n var filenameWithoutSuffix = filename.split(/#|\\?/)[0];\n return (/\\.[^./\\\\]*$/.exec(filenameWithoutSuffix) || [''])[0];\n};\n\nvar isImageFileType = function isImageFileType(type) {\n return !!type && type.indexOf('image/') === 0;\n};\n\nexport var isImageUrl = function isImageUrl(file) {\n if (isImageFileType(file.type)) {\n return true;\n }\n var url = file.thumbUrl || file.url;\n var extension = extname(url);\n if (/^data:image\\//.test(url) || /(webp|svg|png|gif|jpg|jpeg|jfif|bmp|dpg|ico)$/i.test(extension)) {\n return true;\n }\n if (/^data:/.test(url)) {\n // other file types of base64\n return false;\n }\n if (extension) {\n // other file types which have extension\n return false;\n }\n return true;\n};\n\nvar MEASURE_SIZE = 200;\nexport function previewImage(file) {\n return new Promise(function (resolve) {\n if (!isImageFileType(file.type)) {\n resolve('');\n return;\n }\n\n var canvas = document.createElement('canvas');\n canvas.width = MEASURE_SIZE;\n canvas.height = MEASURE_SIZE;\n canvas.style.cssText = 'position: fixed; left: 0; top: 0; width: ' + MEASURE_SIZE + 'px; height: ' + MEASURE_SIZE + 'px; z-index: 9999; display: none;';\n document.body.appendChild(canvas);\n var ctx = canvas.getContext('2d');\n var img = new Image();\n img.onload = function () {\n var width = img.width,\n height = img.height;\n\n\n var drawWidth = MEASURE_SIZE;\n var drawHeight = MEASURE_SIZE;\n var offsetX = 0;\n var offsetY = 0;\n\n if (width < height) {\n drawHeight = height * (MEASURE_SIZE / width);\n offsetY = -(drawHeight - drawWidth) / 2;\n } else {\n drawWidth = width * (MEASURE_SIZE / height);\n offsetX = -(drawWidth - drawHeight) / 2;\n }\n\n ctx.drawImage(img, offsetX, offsetY, drawWidth, drawHeight);\n var dataURL = canvas.toDataURL();\n document.body.removeChild(canvas);\n\n resolve(dataURL);\n };\n img.src = window.URL.createObjectURL(file);\n });\n}","import _mergeJSXProps from 'babel-helper-vue-jsx-merge-props';\nimport _defineProperty from 'babel-runtime/helpers/defineProperty';\nimport _extends from 'babel-runtime/helpers/extends';\nimport BaseMixin from '../_util/BaseMixin';\nimport { getOptionProps, initDefaultProps, getListeners } from '../_util/props-util';\nimport getTransitionProps from '../_util/getTransitionProps';\nimport { ConfigConsumerProps } from '../config-provider/configConsumerProps';\nimport { previewImage, isImageUrl } from './utils';\nimport Icon from '../icon';\nimport Tooltip from '../tooltip';\nimport Progress from '../progress';\nimport classNames from 'classnames';\nimport { UploadListProps } from './interface';\n\nexport default {\n name: 'AUploadList',\n mixins: [BaseMixin],\n props: initDefaultProps(UploadListProps, {\n listType: 'text', // or picture\n progressAttr: {\n strokeWidth: 2,\n showInfo: false\n },\n showRemoveIcon: true,\n showDownloadIcon: false,\n showPreviewIcon: true,\n previewFile: previewImage\n }),\n inject: {\n configProvider: { 'default': function _default() {\n return ConfigConsumerProps;\n } }\n },\n updated: function updated() {\n var _this = this;\n\n this.$nextTick(function () {\n var _$props = _this.$props,\n listType = _$props.listType,\n items = _$props.items,\n previewFile = _$props.previewFile;\n\n if (listType !== 'picture' && listType !== 'picture-card') {\n return;\n }\n (items || []).forEach(function (file) {\n if (typeof document === 'undefined' || typeof window === 'undefined' || !window.FileReader || !window.File || !(file.originFileObj instanceof File || file.originFileObj instanceof Blob) || file.thumbUrl !== undefined) {\n return;\n }\n /*eslint-disable */\n file.thumbUrl = '';\n if (previewFile) {\n previewFile(file.originFileObj).then(function (previewDataUrl) {\n // Need append '' to avoid dead loop\n file.thumbUrl = previewDataUrl || '';\n _this.$forceUpdate();\n });\n }\n });\n });\n },\n\n methods: {\n handlePreview: function handlePreview(file, e) {\n var _getListeners = getListeners(this),\n preview = _getListeners.preview;\n\n if (!preview) {\n return;\n }\n e.preventDefault();\n return this.$emit('preview', file);\n },\n handleDownload: function handleDownload(file) {\n var _getListeners2 = getListeners(this),\n download = _getListeners2.download;\n\n if (typeof download === 'function') {\n download(file);\n } else if (file.url) {\n window.open(file.url);\n }\n },\n handleClose: function handleClose(file) {\n this.$emit('remove', file);\n }\n },\n render: function render() {\n var _this2 = this,\n _classNames4;\n\n var h = arguments[0];\n\n var _getOptionProps = getOptionProps(this),\n customizePrefixCls = _getOptionProps.prefixCls,\n _getOptionProps$items = _getOptionProps.items,\n items = _getOptionProps$items === undefined ? [] : _getOptionProps$items,\n listType = _getOptionProps.listType,\n showPreviewIcon = _getOptionProps.showPreviewIcon,\n showRemoveIcon = _getOptionProps.showRemoveIcon,\n showDownloadIcon = _getOptionProps.showDownloadIcon,\n locale = _getOptionProps.locale,\n progressAttr = _getOptionProps.progressAttr;\n\n var getPrefixCls = this.configProvider.getPrefixCls;\n var prefixCls = getPrefixCls('upload', customizePrefixCls);\n\n var list = items.map(function (file) {\n var _classNames, _classNames2;\n\n var progress = void 0;\n var icon = h(Icon, {\n attrs: { type: file.status === 'uploading' ? 'loading' : 'paper-clip' }\n });\n\n if (listType === 'picture' || listType === 'picture-card') {\n if (listType === 'picture-card' && file.status === 'uploading') {\n icon = h(\n 'div',\n { 'class': prefixCls + '-list-item-uploading-text' },\n [locale.uploading]\n );\n } else if (!file.thumbUrl && !file.url) {\n icon = h(Icon, { 'class': prefixCls + '-list-item-thumbnail', attrs: { type: 'picture', theme: 'twoTone' }\n });\n } else {\n var thumbnail = isImageUrl(file) ? h('img', {\n attrs: {\n src: file.thumbUrl || file.url,\n alt: file.name\n },\n 'class': prefixCls + '-list-item-image'\n }) : h(Icon, {\n attrs: { type: 'file', theme: 'twoTone' },\n 'class': prefixCls + '-list-item-icon' });\n icon = h(\n 'a',\n {\n 'class': prefixCls + '-list-item-thumbnail',\n on: {\n 'click': function click(e) {\n return _this2.handlePreview(file, e);\n }\n },\n attrs: {\n href: file.url || file.thumbUrl,\n target: '_blank',\n rel: 'noopener noreferrer'\n }\n },\n [thumbnail]\n );\n }\n }\n\n if (file.status === 'uploading') {\n var progressProps = {\n props: _extends({}, progressAttr, {\n type: 'line',\n percent: file.percent\n })\n };\n // show loading icon if upload progress listener is disabled\n var loadingProgress = 'percent' in file ? h(Progress, progressProps) : null;\n\n progress = h(\n 'div',\n { 'class': prefixCls + '-list-item-progress', key: 'progress' },\n [loadingProgress]\n );\n }\n var infoUploadingClass = classNames((_classNames = {}, _defineProperty(_classNames, prefixCls + '-list-item', true), _defineProperty(_classNames, prefixCls + '-list-item-' + file.status, true), _defineProperty(_classNames, prefixCls + '-list-item-list-type-' + listType, true), _classNames));\n var linkProps = typeof file.linkProps === 'string' ? JSON.parse(file.linkProps) : file.linkProps;\n\n var removeIcon = showRemoveIcon ? h(Icon, {\n attrs: { type: 'delete', title: locale.removeFile },\n on: {\n 'click': function click() {\n return _this2.handleClose(file);\n }\n }\n }) : null;\n var downloadIcon = showDownloadIcon && file.status === 'done' ? h(Icon, {\n attrs: {\n type: 'download',\n title: locale.downloadFile\n },\n on: {\n 'click': function click() {\n return _this2.handleDownload(file);\n }\n }\n }) : null;\n var downloadOrDelete = listType !== 'picture-card' && h(\n 'span',\n {\n key: 'download-delete',\n 'class': prefixCls + '-list-item-card-actions ' + (listType === 'picture' ? 'picture' : '')\n },\n [downloadIcon && h(\n 'a',\n {\n attrs: { title: locale.downloadFile }\n },\n [downloadIcon]\n ), removeIcon && h(\n 'a',\n {\n attrs: { title: locale.removeFile }\n },\n [removeIcon]\n )]\n );\n var listItemNameClass = classNames((_classNames2 = {}, _defineProperty(_classNames2, prefixCls + '-list-item-name', true), _defineProperty(_classNames2, prefixCls + '-list-item-name-icon-count-' + [downloadIcon, removeIcon].filter(function (x) {\n return x;\n }).length, true), _classNames2));\n\n var preview = file.url ? [h(\n 'a',\n _mergeJSXProps([{\n attrs: {\n target: '_blank',\n rel: 'noopener noreferrer',\n\n title: file.name\n },\n 'class': listItemNameClass }, linkProps, {\n attrs: {\n href: file.url\n },\n on: {\n 'click': function click(e) {\n return _this2.handlePreview(file, e);\n }\n }\n }]),\n [file.name]\n ), downloadOrDelete] : [h(\n 'span',\n {\n key: 'view',\n 'class': prefixCls + '-list-item-name',\n on: {\n 'click': function click(e) {\n return _this2.handlePreview(file, e);\n }\n },\n attrs: {\n title: file.name\n }\n },\n [file.name]\n ), downloadOrDelete];\n var style = file.url || file.thumbUrl ? undefined : {\n pointerEvents: 'none',\n opacity: 0.5\n };\n var previewIcon = showPreviewIcon ? h(\n 'a',\n {\n attrs: {\n href: file.url || file.thumbUrl,\n target: '_blank',\n rel: 'noopener noreferrer',\n\n title: locale.previewFile\n },\n style: style,\n on: {\n 'click': function click(e) {\n return _this2.handlePreview(file, e);\n }\n }\n },\n [h(Icon, {\n attrs: { type: 'eye-o' }\n })]\n ) : null;\n var actions = listType === 'picture-card' && file.status !== 'uploading' && h(\n 'span',\n { 'class': prefixCls + '-list-item-actions' },\n [previewIcon, file.status === 'done' && downloadIcon, removeIcon]\n );\n var message = void 0;\n if (file.response && typeof file.response === 'string') {\n message = file.response;\n } else {\n message = file.error && file.error.statusText || locale.uploadError;\n }\n var iconAndPreview = h('span', [icon, preview]);\n var transitionProps = getTransitionProps('fade');\n var dom = h(\n 'div',\n { 'class': infoUploadingClass, key: file.uid },\n [h(\n 'div',\n { 'class': prefixCls + '-list-item-info' },\n [iconAndPreview]\n ), actions, h(\n 'transition',\n transitionProps,\n [progress]\n )]\n );\n var listContainerNameClass = classNames(_defineProperty({}, prefixCls + '-list-picture-card-container', listType === 'picture-card'));\n return h(\n 'div',\n { key: file.uid, 'class': listContainerNameClass },\n [file.status === 'error' ? h(\n Tooltip,\n {\n attrs: { title: message }\n },\n [dom]\n ) : h('span', [dom])]\n );\n });\n var listClassNames = classNames((_classNames4 = {}, _defineProperty(_classNames4, prefixCls + '-list', true), _defineProperty(_classNames4, prefixCls + '-list-' + listType, true), _classNames4));\n var animationDirection = listType === 'picture-card' ? 'animate-inline' : 'animate';\n var transitionGroupProps = getTransitionProps(prefixCls + '-' + animationDirection);\n return h(\n 'transition-group',\n _mergeJSXProps([transitionGroupProps, {\n attrs: { tag: 'div' },\n 'class': listClassNames }]),\n [list]\n );\n }\n};","import _mergeJSXProps from 'babel-helper-vue-jsx-merge-props';\nimport _defineProperty from 'babel-runtime/helpers/defineProperty';\nimport _extends from 'babel-runtime/helpers/extends';\nimport classNames from 'classnames';\nimport uniqBy from 'lodash/uniqBy';\nimport findIndex from 'lodash/findIndex';\nimport pick from 'lodash/pick';\nimport VcUpload from '../vc-upload';\nimport BaseMixin from '../_util/BaseMixin';\nimport { getOptionProps, initDefaultProps, hasProp, getListeners } from '../_util/props-util';\nimport LocaleReceiver from '../locale-provider/LocaleReceiver';\nimport defaultLocale from '../locale-provider/default';\nimport { ConfigConsumerProps } from '../config-provider/configConsumerProps';\nimport Dragger from './Dragger';\nimport UploadList from './UploadList';\nimport { UploadProps } from './interface';\nimport { T, fileToObject, genPercentAdd, getFileItem, removeFileItem } from './utils';\n\nexport { UploadProps };\n\nexport default {\n name: 'AUpload',\n mixins: [BaseMixin],\n inheritAttrs: false,\n Dragger: Dragger,\n props: initDefaultProps(UploadProps, {\n type: 'select',\n multiple: false,\n action: '',\n data: {},\n accept: '',\n beforeUpload: T,\n showUploadList: true,\n listType: 'text', // or pictrue\n disabled: false,\n supportServerRender: true\n }),\n inject: {\n configProvider: { 'default': function _default() {\n return ConfigConsumerProps;\n } }\n },\n // recentUploadStatus: boolean | PromiseLike;\n data: function data() {\n this.progressTimer = null;\n return {\n sFileList: this.fileList || this.defaultFileList || [],\n dragState: 'drop'\n };\n },\n\n watch: {\n fileList: function fileList(val) {\n this.sFileList = val || [];\n }\n },\n beforeDestroy: function beforeDestroy() {\n this.clearProgressTimer();\n },\n\n methods: {\n onStart: function onStart(file) {\n var targetItem = fileToObject(file);\n targetItem.status = 'uploading';\n var nextFileList = this.sFileList.concat();\n var fileIndex = findIndex(nextFileList, function (_ref) {\n var uid = _ref.uid;\n return uid === targetItem.uid;\n });\n if (fileIndex === -1) {\n nextFileList.push(targetItem);\n } else {\n nextFileList[fileIndex] = targetItem;\n }\n this.onChange({\n file: targetItem,\n fileList: nextFileList\n });\n // fix ie progress\n if (!window.File || process.env.TEST_IE) {\n this.autoUpdateProgress(0, targetItem);\n }\n },\n onSuccess: function onSuccess(response, file, xhr) {\n this.clearProgressTimer();\n try {\n if (typeof response === 'string') {\n response = JSON.parse(response);\n }\n } catch (e) {\n /* do nothing */\n }\n var fileList = this.sFileList;\n var targetItem = getFileItem(file, fileList);\n // removed\n if (!targetItem) {\n return;\n }\n targetItem.status = 'done';\n targetItem.response = response;\n targetItem.xhr = xhr;\n this.onChange({\n file: _extends({}, targetItem),\n fileList: fileList\n });\n },\n onProgress: function onProgress(e, file) {\n var fileList = this.sFileList;\n var targetItem = getFileItem(file, fileList);\n // removed\n if (!targetItem) {\n return;\n }\n targetItem.percent = e.percent;\n this.onChange({\n event: e,\n file: _extends({}, targetItem),\n fileList: this.sFileList\n });\n },\n onError: function onError(error, response, file) {\n this.clearProgressTimer();\n var fileList = this.sFileList;\n var targetItem = getFileItem(file, fileList);\n // removed\n if (!targetItem) {\n return;\n }\n targetItem.error = error;\n targetItem.response = response;\n targetItem.status = 'error';\n this.onChange({\n file: _extends({}, targetItem),\n fileList: fileList\n });\n },\n onReject: function onReject(fileList) {\n this.$emit('reject', fileList);\n },\n handleRemove: function handleRemove(file) {\n var _this = this;\n\n var onRemove = this.remove;\n var fileList = this.$data.sFileList;\n\n\n Promise.resolve(typeof onRemove === 'function' ? onRemove(file) : onRemove).then(function (ret) {\n // Prevent removing file\n if (ret === false) {\n return;\n }\n\n var removedFileList = removeFileItem(file, fileList);\n\n if (removedFileList) {\n file.status = 'removed'; // eslint-disable-line\n\n if (_this.upload) {\n _this.upload.abort(file);\n }\n\n _this.onChange({\n file: file,\n fileList: removedFileList\n });\n }\n });\n },\n handleManualRemove: function handleManualRemove(file) {\n if (this.$refs.uploadRef) {\n this.$refs.uploadRef.abort(file);\n }\n this.handleRemove(file);\n },\n onChange: function onChange(info) {\n if (!hasProp(this, 'fileList')) {\n this.setState({ sFileList: info.fileList });\n }\n this.$emit('change', info);\n },\n onFileDrop: function onFileDrop(e) {\n this.setState({\n dragState: e.type\n });\n },\n reBeforeUpload: function reBeforeUpload(file, fileList) {\n var beforeUpload = this.$props.beforeUpload;\n var stateFileList = this.$data.sFileList;\n\n if (!beforeUpload) {\n return true;\n }\n var result = beforeUpload(file, fileList);\n if (result === false) {\n this.onChange({\n file: file,\n fileList: uniqBy(stateFileList.concat(fileList.map(fileToObject)), function (item) {\n return item.uid;\n })\n });\n return false;\n }\n if (result && result.then) {\n return result;\n }\n return true;\n },\n clearProgressTimer: function clearProgressTimer() {\n clearInterval(this.progressTimer);\n },\n autoUpdateProgress: function autoUpdateProgress(_, file) {\n var _this2 = this;\n\n var getPercent = genPercentAdd();\n var curPercent = 0;\n this.clearProgressTimer();\n this.progressTimer = setInterval(function () {\n curPercent = getPercent(curPercent);\n _this2.onProgress({\n percent: curPercent * 100\n }, file);\n }, 200);\n },\n renderUploadList: function renderUploadList(locale) {\n var h = this.$createElement;\n\n var _getOptionProps = getOptionProps(this),\n _getOptionProps$showU = _getOptionProps.showUploadList,\n showUploadList = _getOptionProps$showU === undefined ? {} : _getOptionProps$showU,\n listType = _getOptionProps.listType,\n previewFile = _getOptionProps.previewFile,\n disabled = _getOptionProps.disabled,\n propLocale = _getOptionProps.locale;\n\n var showRemoveIcon = showUploadList.showRemoveIcon,\n showPreviewIcon = showUploadList.showPreviewIcon,\n showDownloadIcon = showUploadList.showDownloadIcon;\n var fileList = this.$data.sFileList;\n\n var uploadListProps = {\n props: {\n listType: listType,\n items: fileList,\n previewFile: previewFile,\n showRemoveIcon: !disabled && showRemoveIcon,\n showPreviewIcon: showPreviewIcon,\n showDownloadIcon: showDownloadIcon,\n locale: _extends({}, locale, propLocale)\n },\n on: _extends({\n remove: this.handleManualRemove\n }, pick(getListeners(this), ['download', 'preview']))\n };\n return h(UploadList, uploadListProps);\n }\n },\n render: function render() {\n var _classNames2;\n\n var h = arguments[0];\n\n var _getOptionProps2 = getOptionProps(this),\n customizePrefixCls = _getOptionProps2.prefixCls,\n showUploadList = _getOptionProps2.showUploadList,\n listType = _getOptionProps2.listType,\n type = _getOptionProps2.type,\n disabled = _getOptionProps2.disabled;\n\n var _$data = this.$data,\n fileList = _$data.sFileList,\n dragState = _$data.dragState;\n\n var getPrefixCls = this.configProvider.getPrefixCls;\n var prefixCls = getPrefixCls('upload', customizePrefixCls);\n\n var vcUploadProps = {\n props: _extends({}, this.$props, {\n prefixCls: prefixCls,\n beforeUpload: this.reBeforeUpload\n }),\n on: {\n start: this.onStart,\n error: this.onError,\n progress: this.onProgress,\n success: this.onSuccess,\n reject: this.onReject\n },\n ref: 'uploadRef',\n attrs: _extends({}, this.$attrs)\n };\n var children = this.$slots['default'];\n // Remove id to avoid open by label when trigger is hidden\n // https://github.com/ant-design/ant-design/issues/14298\n if (!children || disabled) {\n delete vcUploadProps.props.id;\n delete vcUploadProps.attrs.id;\n }\n var uploadList = showUploadList ? h(LocaleReceiver, {\n attrs: {\n componentName: 'Upload',\n defaultLocale: defaultLocale.Upload\n },\n scopedSlots: { 'default': this.renderUploadList }\n }) : null;\n\n if (type === 'drag') {\n var _classNames;\n\n var dragCls = classNames(prefixCls, (_classNames = {}, _defineProperty(_classNames, prefixCls + '-drag', true), _defineProperty(_classNames, prefixCls + '-drag-uploading', fileList.some(function (file) {\n return file.status === 'uploading';\n })), _defineProperty(_classNames, prefixCls + '-drag-hover', dragState === 'dragover'), _defineProperty(_classNames, prefixCls + '-disabled', disabled), _classNames));\n return h('span', [h(\n 'div',\n {\n 'class': dragCls,\n on: {\n 'drop': this.onFileDrop,\n 'dragover': this.onFileDrop,\n 'dragleave': this.onFileDrop\n }\n },\n [h(\n VcUpload,\n _mergeJSXProps([vcUploadProps, { 'class': prefixCls + '-btn' }]),\n [h(\n 'div',\n { 'class': prefixCls + '-drag-container' },\n [children]\n )]\n )]\n ), uploadList]);\n }\n\n var uploadButtonCls = classNames(prefixCls, (_classNames2 = {}, _defineProperty(_classNames2, prefixCls + '-select', true), _defineProperty(_classNames2, prefixCls + '-select-' + listType, true), _defineProperty(_classNames2, prefixCls + '-disabled', disabled), _classNames2));\n\n var uploadButton = h(\n 'div',\n { 'class': uploadButtonCls, style: children ? undefined : { display: 'none' } },\n [h(\n VcUpload,\n vcUploadProps,\n [children]\n )]\n );\n\n if (listType === 'picture-card') {\n return h(\n 'span',\n { 'class': prefixCls + '-picture-card-wrapper' },\n [uploadList, uploadButton]\n );\n }\n return h('span', [uploadButton, uploadList]);\n }\n};","import Upload from './Upload';\nimport Dragger from './Dragger';\nimport Base from '../base';\n\nexport { UploadProps, UploadListProps, UploadChangeParam } from './interface';\n\nUpload.Dragger = Dragger;\n\n/* istanbul ignore next */\nUpload.install = function (Vue) {\n Vue.use(Base);\n Vue.component(Upload.name, Upload);\n Vue.component(Dragger.name, Dragger);\n};\n\nexport default Upload;"],"sourceRoot":""}