@aplus-frontend/ui
Version:
30 lines (29 loc) • 1.15 kB
TypeScript
import { SpaceProps } from '@aplus-frontend/antdv';
import { ApButtonProps } from '../../ap-button';
import { ApBatchActionGroupProps } from '../ap-batch-action-group/interface';
import { ApExportGroupProps } from '../ap-export-group/interface';
import { VNodeChild } from 'vue';
export type ApButtonGroupType = {
button: ApButtonProps & {
content?: VNodeChild;
ifShow?: () => boolean;
auth?: string;
};
actionButton: ApButtonProps & {
content?: VNodeChild;
ifShow?: () => boolean;
auth?: string;
};
batchActionGroup: Omit<ApBatchActionGroupProps, 'selectedRows'>;
exportGroup: Omit<ApExportGroupProps, 'selectedRowKeys'>;
};
export type ApButtonGroupTypeKey = keyof ApButtonGroupType & {};
export type ApButtonGroupListProps<ButtonType extends ApButtonGroupTypeKey = ApButtonGroupTypeKey> = ButtonType extends ApButtonGroupTypeKey ? {
valueType: ButtonType;
} & ApButtonGroupType[ButtonType] : never;
export type ApButtonGroupProps = {
spaceProps?: Partial<SpaceProps>;
selectedRows?: any[];
selectedRowKeys?: any[];
groupList?: ApButtonGroupListProps[];
};