File tree Expand file tree Collapse file tree 1 file changed +23
-0
lines changed
packages/element-web-module-api/src/api Expand file tree Collapse file tree 1 file changed +23
-0
lines changed Original file line number Diff line number Diff line change @@ -14,6 +14,22 @@ import { JSX } from "react";
1414 */
1515export type LocationRenderFunction = ( ) => JSX . Element ;
1616
17+ /**
18+ * The options available for changing the open behaviour.
19+ * @public
20+ */
21+ export interface OpenRoomOptions {
22+ /**
23+ * The list of servers to join via.
24+ */
25+ viaServers ?: string [ ] ;
26+
27+ /**
28+ * Whether to automatically join the room if we are not already in it.
29+ */
30+ autoJoin ?: boolean ;
31+ }
32+
1733/**
1834 * API methods to navigate the application.
1935 * @public
@@ -33,4 +49,11 @@ export interface NavigationApi {
3349 * @alpha
3450 */
3551 registerLocationRenderer ( path : string , renderer : LocationRenderFunction ) : void ;
52+
53+ /**
54+ * Open a room in element-web.
55+ * @param roomIdOrAlias - id/alias of the room to open
56+ * @param opts - Options to control the open action, see {@link OpenRoomOptions}
57+ */
58+ openRoom ( roomIdOrAlias : string , opts ?: OpenRoomOptions ) : void ;
3659}
You can’t perform that action at this time.
0 commit comments