diff --git a/frontend/src/pages/invitations/invitations-view.js b/frontend/src/pages/invitations/invitations-view.js index 882bf7b1e3..2ebaa318fe 100644 --- a/frontend/src/pages/invitations/invitations-view.js +++ b/frontend/src/pages/invitations/invitations-view.js @@ -43,7 +43,8 @@ class Item extends React.Component { }); } - deleteItem = () => { + deleteItem = (e) => { + e.preventDefault(); // make the icon avoid being clicked repeatedly this.setState({ isOpIconShown: false @@ -65,7 +66,8 @@ class Item extends React.Component { this.setState({deleted: true}); } - toggleRevokeDialog = () => { + toggleRevokeDialog = (e) => { + e.preventDefault(); this.setState({ isRevokeDialogOpen: !this.state.isRevokeDialogOpen }); @@ -81,7 +83,7 @@ class Item extends React.Component { const item = this.props.invitation; const desktopItem = ( - + {item.accepter} {moment(item.invite_time).format('YYYY-MM-DD')} {moment(item.expire_time).format('YYYY-MM-DD')} @@ -89,16 +91,20 @@ class Item extends React.Component { {isOpIconShown && ( item.accept_time ? - - : - : + - + )}