eslink-ui-plus
Version:
vue3 component library, css framework
40 lines (38 loc) • 1.21 kB
text/typescript
/*
* @Author: xiaobo
* @Description:
* @Date: 2021-04-22 08:48:41
* @LastEditTime: 2022-01-20 15:51:55
* @FilePath: \eslink-ui-plus\components\page-operater-bar\type.ts
*/
import { keyConfigType } from '../utils'
export interface operaterType {
key: string
label: string
type?: 'select' | 'button' | 'date'
selected?: string
// type为button时可配置否则无效
buttonType?: 'success' | 'error' | 'warn' | 'default' | 'pure' | 'icon'
// type为button时可配置否则无效
buttonPlain?: boolean
// type为button|select时可配置否则无效
buttonDisabled?: boolean
// type为select时可配置否则无效
source?: { [key: string]: string }[]
// type为select时配置im-option是键值匹配
keyConfig?: keyConfigType
// type为button|select时可配置否则无效
click?: (item?: operaterType) => any
// type为select时可配置否则无效
select?: ($event: optionSelectedEventType, item: operaterType) => any
// buttonType为icon时可配置否则无效
icon?: string
classList?: string
}
export type operateSourceType = operaterType[]
export type optionSelectedEventType = {
item: {
[key: string]: string
}
value: string
}