Skip to content

Commit f1005ed

Browse files
authored
fix(Message): types
1 parent 364ed28 commit f1005ed

File tree

1 file changed

+9
-7
lines changed

1 file changed

+9
-7
lines changed

types/message/index.d.ts

+9-7
Original file line numberDiff line numberDiff line change
@@ -69,13 +69,15 @@ export interface MessageProps extends HTMLAttributesWeak, CommonProps {
6969
animation?: boolean;
7070
}
7171

72+
type OpenProps = string | React.ReactElement | MessageProps;
73+
7274
export default class Message extends React.Component<MessageProps, any> {
73-
static show(props: {}): void;
75+
static show(props: OpenProps): void;
7476
static hide(): void;
75-
static success(props: {}): void;
76-
static warning(props: {}): void;
77-
static error(props: {}): void;
78-
static help(props: {}): void;
79-
static loading(props: {}): void;
80-
static notice(props: {}): void;
77+
static success(props: OpenProps): void;
78+
static warning(props: OpenProps): void;
79+
static error(props: OpenProps): void;
80+
static help(props: OpenProps): void;
81+
static loading(props: OpenProps): void;
82+
static notice(props: OpenProps): void;
8183
}

0 commit comments

Comments
 (0)