npm-cts-ui
Version:
UI KIT for Taro
67 lines (63 loc) • 1.45 kB
TypeScript
import { ComponentClass } from 'react'
import { CommonEventFunction } from '@tarojs/components/types/common'
import CtsComponent from './base'
export interface CtsUploadImageFileProps extends CtsComponent {
/**
* 文件列表
*/
list: any[]
/**
* 最多上传的文件数量
* @default 1
*/
max: number
/**
* 限制上传的文件大小(单位M)
* @default 2
*/
size?: number
/**
* 是否从相册选图
* @default true
*/
isAlbum?: boolean
/**
* 是否使用相机
* @default true
*/
isCamera?: boolean
/**
* bizCode
*/
bizCode: string
/**
* 是否是详情不可编辑
* @default false
*/
isDetail?: boolean
/**
* 上传类型,image:图片,pdf:pdf文件,docx:docx文件
* @description 可选择的值 'image', 'pdf', 'docx'
* @type {('image'|'pdf'|'docx')}
* @default 'image'
*/
// type?: string
/**
* 上传类型,image:图片,file:文件
* @description 可选择的值 'image', 'file'
* @type {('image'|'file')}
* @default ['image']
*/
type?: any[]
/**
* 图片的类型,如jpg,jpeg,png,gif,pdf等
* @default 'jpg,jpeg,png'
*/
typeStr?: string
/**
* 选择图片事件
*/
onChange: CommonEventFunction
}
declare const CtsUploadImageFile: ComponentClass<CtsUploadImageFileProps>
export default CtsUploadImageFile