Right panel: view third party invite info without clearing history (#11934)
* add View3pidInvite to actions enum, replace uses * extract out action handler * push card instead, test * comment
This commit is contained in:
parent
fbd64d37f2
commit
0bbb9e8c89
7 changed files with 124 additions and 10 deletions
|
@ -55,6 +55,7 @@ import PosthogTrackers from "../../../PosthogTrackers";
|
|||
import { SDKContext } from "../../../contexts/SDKContext";
|
||||
import { canInviteTo } from "../../../utils/room/canInviteTo";
|
||||
import { inviteToRoom } from "../../../utils/room/inviteToRoom";
|
||||
import { Action } from "../../../dispatcher/actions";
|
||||
|
||||
const INITIAL_LOAD_NUM_MEMBERS = 30;
|
||||
const INITIAL_LOAD_NUM_INVITED = 5;
|
||||
|
@ -275,7 +276,7 @@ export default class MemberList extends React.Component<IProps, IState> {
|
|||
|
||||
private onPending3pidInviteClick = (inviteEvent: MatrixEvent): void => {
|
||||
dis.dispatch({
|
||||
action: "view_3pid_invite",
|
||||
action: Action.View3pidInvite,
|
||||
event: inviteEvent,
|
||||
});
|
||||
};
|
||||
|
|
|
@ -27,6 +27,7 @@ import RoomAvatar from "../avatars/RoomAvatar";
|
|||
import RoomName from "../elements/RoomName";
|
||||
import ErrorDialog from "../dialogs/ErrorDialog";
|
||||
import AccessibleButton from "../elements/AccessibleButton";
|
||||
import { Action } from "../../../dispatcher/actions";
|
||||
|
||||
interface IProps {
|
||||
event: MatrixEvent;
|
||||
|
@ -91,7 +92,7 @@ export default class ThirdPartyMemberInfo extends React.Component<IProps, IState
|
|||
|
||||
public onCancel = (): void => {
|
||||
dis.dispatch({
|
||||
action: "view_3pid_invite",
|
||||
action: Action.View3pidInvite,
|
||||
event: null,
|
||||
});
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue