优化下拉框
This commit is contained in:
17
types/column.d.ts
vendored
17
types/column.d.ts
vendored
@@ -181,11 +181,11 @@ export namespace VxeColumnPropTypes {
|
||||
/**
|
||||
* 只对 type=radio 有效,自定义单选框模板
|
||||
*/
|
||||
radio?: string | ((params: VxeColumnSlotTypes.DefaultSlotParams<D>) => SlotVNodeType[] | SlotVNodeType) | null
|
||||
radio?: string | ((params: VxeColumnSlotTypes.RadioSlotParams<D>) => SlotVNodeType[] | SlotVNodeType) | null
|
||||
/**
|
||||
* 只对 type=checkbox 有效,自定义复选框模板
|
||||
*/
|
||||
checkbox?: string | ((params: VxeColumnSlotTypes.DefaultSlotParams<D>) => SlotVNodeType[] | SlotVNodeType) | null
|
||||
checkbox?: string | ((params: VxeColumnSlotTypes.CheckboxSlotParams<D>) => SlotVNodeType[] | SlotVNodeType) | null
|
||||
/**
|
||||
* 自定义显示内容模板
|
||||
*/
|
||||
@@ -405,7 +405,7 @@ export namespace VxeColumnSlotTypes {
|
||||
data: D[][]
|
||||
}
|
||||
|
||||
export interface HeaderSlotParams<D = VxeTableDataRow> extends VxeTableDefines.CellRenderHeaderParams<D> { }
|
||||
export interface HeaderSlotParams<D = VxeTableDataRow> extends VxeTableDefines.CellRenderHeaderParams<D> {}
|
||||
|
||||
export interface ContentSlotParams<D = VxeTableDataRow> {
|
||||
column: VxeTableDefines.ColumnInfo<D>
|
||||
@@ -421,6 +421,13 @@ export namespace VxeColumnSlotTypes {
|
||||
|
||||
export interface DefaultSlotParams<D = VxeTableDataRow> extends VxeTableDefines.CellRenderBodyParams<D> { }
|
||||
|
||||
export interface CheckboxSlotParams<D = VxeTableDataRow> extends DefaultSlotParams<D> {
|
||||
checked: boolean
|
||||
indeterminate: boolean
|
||||
}
|
||||
export interface RadioSlotParams<D = VxeTableDataRow> extends DefaultSlotParams<D> {
|
||||
checked: boolean
|
||||
}
|
||||
export interface IconSlotParams<D = VxeTableDataRow> extends DefaultSlotParams<D> { }
|
||||
}
|
||||
|
||||
@@ -444,11 +451,11 @@ export interface VxeColumnSlots<D = VxeTableDataRow> {
|
||||
/**
|
||||
* 只对 type=checkbox 有效,自定义复选框模板
|
||||
*/
|
||||
checkbox: (params: VxeColumnSlotTypes.DefaultSlotParams<D>) => any
|
||||
checkbox: (params: VxeColumnSlotTypes.CheckboxSlotParams<D>) => any
|
||||
/**
|
||||
* 只对 type=radio 有效,自定义单选框模板
|
||||
*/
|
||||
radio: (params: VxeColumnSlotTypes.DefaultSlotParams<D>) => any
|
||||
radio: (params: VxeColumnSlotTypes.RadioSlotParams<D>) => any
|
||||
/**
|
||||
* 只对 type=expand 有效,自定义展开后的内容模板
|
||||
*/
|
||||
|
||||
5
types/grid.d.ts
vendored
5
types/grid.d.ts
vendored
@@ -593,6 +593,11 @@ export interface VxeGridSlots<D = VxeTableDataRow> {
|
||||
$columnIndex: number
|
||||
_columnIndex: number
|
||||
|
||||
checked?: boolean
|
||||
indeterminate?: boolean
|
||||
|
||||
items: D[]
|
||||
|
||||
[key: string]: any
|
||||
}) => any) | undefined
|
||||
}
|
||||
|
||||
12
types/pulldown.d.ts
vendored
12
types/pulldown.d.ts
vendored
@@ -126,12 +126,24 @@ export interface VxePulldownListeners {
|
||||
}
|
||||
|
||||
export interface VxePulldownSlots {
|
||||
/**
|
||||
* 自定义弹窗容器头部模板
|
||||
*/
|
||||
header: (params: {
|
||||
[key: string]: any
|
||||
}) => any
|
||||
/**
|
||||
* 自定义显示的内容
|
||||
*/
|
||||
default: (params: {
|
||||
[key: string]: any
|
||||
}) => any
|
||||
/**
|
||||
* 自定义弹窗容器底部模板
|
||||
*/
|
||||
footer: ((params: {
|
||||
[key: string]: any
|
||||
}) => any) | undefined
|
||||
/**
|
||||
* 自定义下拉面板显示的内容
|
||||
*/
|
||||
|
||||
29
types/select.d.ts
vendored
29
types/select.d.ts
vendored
@@ -232,10 +232,39 @@ export namespace VxeSelectEvents {
|
||||
}
|
||||
|
||||
export interface VxeSelectSlots {
|
||||
/**
|
||||
* 自定义前缀图标模板
|
||||
*/
|
||||
prefix: (params: {
|
||||
[key: string]: any
|
||||
}) => any
|
||||
/**
|
||||
* 自定义弹窗容器头部模板
|
||||
*/
|
||||
header: (params: {
|
||||
[key: string]: any
|
||||
}) => any
|
||||
/**
|
||||
* 自定义弹窗容器选项模板
|
||||
*/
|
||||
option: ((params: {
|
||||
option: any
|
||||
group: any
|
||||
[key: string]: any
|
||||
}) => any) | undefined
|
||||
/**
|
||||
* 自定义弹窗容器底部模板
|
||||
*/
|
||||
footer: ((params: {
|
||||
[key: string]: any
|
||||
}) => any) | undefined
|
||||
|
||||
/**
|
||||
* 自定义插槽模板
|
||||
*/
|
||||
[key: string]: ((params: {
|
||||
option: any
|
||||
group: any
|
||||
[key: string]: any
|
||||
}) => any) | undefined
|
||||
}
|
||||
|
||||
3
types/table.d.ts
vendored
3
types/table.d.ts
vendored
@@ -2892,6 +2892,9 @@ export namespace VxeTableDefines {
|
||||
type: string
|
||||
isHidden: boolean
|
||||
hasFilter: boolean
|
||||
|
||||
checked?: boolean
|
||||
indeterminate?: boolean
|
||||
}
|
||||
|
||||
export interface CellRenderBodyParams<D = VxeTableDataRow> {
|
||||
|
||||
Reference in New Issue
Block a user