docs: 完善全局变量注释

Former-commit-id: c948921fb994a12b16b210265181c89571d0a296
This commit is contained in:
haoxr
2023-03-11 21:51:13 +08:00
parent b7cdcd1f59
commit d3698a8a0f

48
src/types/global.d.ts vendored
View File

@@ -1,23 +1,55 @@
declare global {
/**
* 分页查询参数
*/
interface PageQuery {
pageNum: number;
pageSize: number;
}
/**
* 分页响应对象
*/
interface PageResult<T> {
/**
* 数据列表
*/
list: T;
/**
* 数据总数
*/
total: number;
}
type DialogType = {
title?: string;
visible: boolean;
};
type OptionType = {
value: string;
/**
* 弹窗属性
*/
interface DialogOption {
/**
* 弹窗标题
*/
title?: string;
/**
* 是否显示
*/
visible: boolean;
}
/**
* 组件数据源
*/
interface OptionType {
/**
* 值
*/
value: number;
/**
* 文本
*/
label: string;
checked?: boolean;
/**
* 子列表
*/
children?: OptionType[];
};
}
}
export {};