1
0
mirror of https://github.com/matrix-org/matrix-react-sdk.git synced 2025-11-11 20:22:36 +03:00

Add view_room to Action enum (#7203)

* Add ViewRoom action to Action enum

Signed-off-by: Renan <renancleyson.f@gmail.com>

* Change view_room occurrences to Action.ViewRoom

Signed-off-by: Renan <renancleyson.f@gmail.com>

* Add missing Action import
This commit is contained in:
Renan Cleyson
2021-11-25 17:49:43 -03:00
committed by GitHub
parent 965539da2d
commit ae0dba4e87
42 changed files with 81 additions and 58 deletions

View File

@@ -49,6 +49,7 @@ import { ActionPayload } from "../../dispatcher/payloads";
import { getDisplayAliasForAliasSet } from "../../Rooms";
import { logger } from "matrix-js-sdk/src/logger";
import { Action } from "../../dispatcher/actions";
const MAX_NAME_LENGTH = 80;
const MAX_TOPIC_LENGTH = 800;
@@ -493,7 +494,7 @@ export default class RoomDirectory extends React.Component<IProps, IState> {
private showRoom(room: IPublicRoomsChunkRoom, roomAlias?: string, autoJoin = false, shouldPeek = false) {
this.onFinished();
const payload: ActionPayload = {
action: 'view_room',
action: Action.ViewRoom,
auto_join: autoJoin,
should_peek: shouldPeek,
_type: "room_directory", // instrumentation