mirror of
https://gitee.com/ant-design/ant-design.git
synced 2024-12-01 11:39:28 +08:00
Format (#15027)
This commit is contained in:
parent
cca47ac3be
commit
94814d955f
@ -24,15 +24,18 @@ export default class ActionButton extends React.Component<ActionButtonProps, Act
|
|||||||
loading: false,
|
loading: false,
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
componentDidMount() {
|
componentDidMount() {
|
||||||
if (this.props.autoFocus) {
|
if (this.props.autoFocus) {
|
||||||
const $this = ReactDOM.findDOMNode(this) as HTMLInputElement;
|
const $this = ReactDOM.findDOMNode(this) as HTMLInputElement;
|
||||||
this.timeoutId = setTimeout(() => $this.focus());
|
this.timeoutId = setTimeout(() => $this.focus());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
componentWillUnmount() {
|
componentWillUnmount() {
|
||||||
clearTimeout(this.timeoutId);
|
clearTimeout(this.timeoutId);
|
||||||
}
|
}
|
||||||
|
|
||||||
onClick = () => {
|
onClick = () => {
|
||||||
const { actionFn, closeModal } = this.props;
|
const { actionFn, closeModal } = this.props;
|
||||||
if (actionFn) {
|
if (actionFn) {
|
||||||
|
Loading…
Reference in New Issue
Block a user