matrix-react-sdk
Version:
SDK for matrix.org using React
47 lines (46 loc) • 1.71 kB
TypeScript
import { MatrixEvent, Room, RoomMember, User } from "matrix-js-sdk/src/matrix";
import { VerificationRequest } from "matrix-js-sdk/src/crypto-api";
import { RightPanelPhases } from "./RightPanelStorePhases";
export interface IRightPanelCardState {
member?: RoomMember | User;
verificationRequest?: VerificationRequest;
verificationRequestPromise?: Promise<VerificationRequest>;
widgetId?: string;
spaceId?: string;
memberInfoEvent?: MatrixEvent;
threadHeadEvent?: MatrixEvent;
initialEvent?: MatrixEvent;
isInitialEventHighlighted?: boolean;
initialEventScrollIntoView?: boolean;
focusRoomSearch?: boolean;
}
export interface IRightPanelCardStateStored {
memberId?: string;
widgetId?: string;
spaceId?: string;
memberInfoEventId?: string;
threadHeadEventId?: string;
initialEventId?: string;
isInitialEventHighlighted?: boolean;
initialEventScrollIntoView?: boolean;
}
export interface IRightPanelCard {
phase: RightPanelPhases | null;
state?: IRightPanelCardState;
}
export interface IRightPanelCardStored {
phase: RightPanelPhases | null;
state?: IRightPanelCardStateStored;
}
export interface IRightPanelForRoom {
isOpen: boolean;
history: Array<IRightPanelCard>;
}
interface IRightPanelForRoomStored {
isOpen: boolean;
history: Array<IRightPanelCardStored>;
}
export declare function convertToStorePanel(cacheRoom?: IRightPanelForRoom): IRightPanelForRoomStored | undefined;
export declare function convertToStatePanel(storeRoom: IRightPanelForRoomStored, room: Room): IRightPanelForRoom;
export declare function convertCardToStore(panelState: IRightPanelCard): IRightPanelCardStored;
export {};