mirror of
https://github.com/tusen-ai/naive-ui.git
synced 2025-02-05 13:00:47 +08:00
docs(upload): fix api table
This commit is contained in:
parent
21411d17dd
commit
ee62f8a82d
@ -14,16 +14,16 @@ default-files
|
|||||||
### Upload Props
|
### Upload Props
|
||||||
|Name|Type|Default|Description|
|
|Name|Type|Default|Description|
|
||||||
|-|-|-|-|
|
|-|-|-|-|
|
||||||
|accept|`string`'`undefined`|The accept type of upload. See <n-a href="https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input/file#accept">accept</n-a>.|
|
|accept|`string`|`undefined`|The accept type of upload. See <n-a href="https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input/file#accept">accept</n-a>.|
|
||||||
|action|`string`'`undefined`|The URL to submit data to.|
|
|action|`string`|`undefined`|The URL to submit data to.|
|
||||||
|data|`Object \| ({ file: UploadFile }) => Object`'`undefined`|The additional fileds data of HTTP request's form data.|
|
|data|`Object \| ({ file: UploadFile }) => Object`|`undefined`|The additional fileds data of HTTP request's form data.|
|
||||||
|default-file-list|`Array<UploadFile>`|`[]`|The default file list in uncontrolled manner.|
|
|default-file-list|`Array<UploadFile>`|`[]`|The default file list in uncontrolled manner.|
|
||||||
|default-upload|`boolean`|`false`|If file uploaded immediatelly after file is selected.|
|
|default-upload|`boolean`|`false`|If file uploaded immediatelly after file is selected.|
|
||||||
|directory|`boolean`|`false`|If directory upload supported. Browser support needed. See <n-a href="https://caniuse.com/#feat=input-file-directory">input-file-directory</n-a>.|
|
|directory|`boolean`|`false`|If directory upload supported. Browser support needed. See <n-a href="https://caniuse.com/#feat=input-file-directory">input-file-directory</n-a>.|
|
||||||
|disabled|`boolean`|`false`||
|
|disabled|`boolean`|`false`||
|
||||||
|file-list-style|`Object`'`undefined`|The style of file list area|
|
|file-list-style|`Object`|`undefined`|The style of file list area|
|
||||||
|file-list|`Array<UploadFile>`|`undefined`|The file list of component. If set, the component will work in controlled manner.|
|
|file-list|`Array<UploadFile>`|`undefined`|The file list of component. If set, the component will work in controlled manner.|
|
||||||
|headers|`Object \| ({ file: UploadFile }) => Object`'`undefined`|The additional HTTP Headers of request.|
|
|headers|`Object \| ({ file: UploadFile }) => Object`|`undefined`|The additional HTTP Headers of request.|
|
||||||
|method|`string`|`'POST'`|The method of HTTP request.|
|
|method|`string`|`'POST'`|The method of HTTP request.|
|
||||||
|multiple|`boolean`|`false`|If multiple files selection supported.|
|
|multiple|`boolean`|`false`|If multiple files selection supported.|
|
||||||
|name|`string`|`'file'`|The field name of file in form data.|
|
|name|`string`|`'file'`|The field name of file in form data.|
|
||||||
|
@ -13,16 +13,16 @@ default-files
|
|||||||
### Upload Props
|
### Upload Props
|
||||||
|名称|类型|默认值|说明|
|
|名称|类型|默认值|说明|
|
||||||
|-|-|-|-|
|
|-|-|-|-|
|
||||||
|accept|`string`'`undefined`|接受的文件类型,参考 <n-a href="https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input/file#accept">accept</n-a>|
|
|accept|`string`|`undefined`|接受的文件类型,参考 <n-a href="https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input/file#accept">accept</n-a>|
|
||||||
|action|`string`'`undefined`|请求提交的地址|
|
|action|`string`|`undefined`|请求提交的地址|
|
||||||
|data|`Object \| ({ file: UploadFile }) => Object`'`undefined`|提交表单需要附加的数据|
|
|data|`Object \| ({ file: UploadFile }) => Object`|`undefined`|提交表单需要附加的数据|
|
||||||
|default-file-list|`Array<UploadFile>`|`[]`|非受控状态下默认的文件列表|
|
|default-file-list|`Array<UploadFile>`|`[]`|非受控状态下默认的文件列表|
|
||||||
|default-upload|`boolean`|`false`|选择文件时候是否默认上传|
|
|default-upload|`boolean`|`false`|选择文件时候是否默认上传|
|
||||||
|directory|`boolean`|`false`|是否支持目录上传,需要浏览器支持,参考 <n-a href="https://caniuse.com/#feat=input-file-directory">input-file-directory</n-a>|
|
|directory|`boolean`|`false`|是否支持目录上传,需要浏览器支持,参考 <n-a href="https://caniuse.com/#feat=input-file-directory">input-file-directory</n-a>|
|
||||||
|disabled|`boolean`|`false`||
|
|disabled|`boolean`|`false`||
|
||||||
|file-list-style|`Object`'`undefined`|文件列表区域的样式|
|
|file-list-style|`Object`|`undefined`|文件列表区域的样式|
|
||||||
|file-list|`Array<UploadFile>`|`undefined`|文件列表,如果传入组件会处于受控状态|
|
|file-list|`Array<UploadFile>`|`undefined`|文件列表,如果传入组件会处于受控状态|
|
||||||
|headers|`Object \| ({ file: UploadFile }) => Object`'`undefined`|HTTP 请求需要附加的 Headers|
|
|headers|`Object \| ({ file: UploadFile }) => Object`|`undefined`|HTTP 请求需要附加的 Headers|
|
||||||
|method|`string`|`'POST'`|HTTP 请求的方法|
|
|method|`string`|`'POST'`|HTTP 请求的方法|
|
||||||
|multiple|`boolean`|`false`|是否支持多个文件|
|
|multiple|`boolean`|`false`|是否支持多个文件|
|
||||||
|name|`string`|`'file'`|文件在提交表单中的字段名|
|
|name|`string`|`'file'`|文件在提交表单中的字段名|
|
||||||
|
Loading…
Reference in New Issue
Block a user