14 lines
295 B
TypeScript
14 lines
295 B
TypeScript
import React from 'react';
|
|
|
|
export type ModalType<T> = React.ElementType<
|
|
T & { close: (...args: any[]) => void }
|
|
>;
|
|
|
|
export interface ModalDetail<T> {
|
|
component: ModalType<T>;
|
|
props: any;
|
|
target?: HTMLElement;
|
|
resolve?: (...args: any[]) => void;
|
|
close?: (...args: any[]) => void;
|
|
}
|