You've already forked matrix-react-sdk
mirror of
https://github.com/matrix-org/matrix-react-sdk.git
synced 2025-11-07 10:46:24 +03:00
Add currentRoomId / Alias to getInitialState
with docs
This commit is contained in:
@@ -64,6 +64,13 @@ module.exports = React.createClass({
|
|||||||
|
|
||||||
getInitialState: function() {
|
getInitialState: function() {
|
||||||
var s = {
|
var s = {
|
||||||
|
// If we are viewing a room by alias, this contains the alias
|
||||||
|
currentRoomAlias: null,
|
||||||
|
|
||||||
|
// The ID of the room we're viewing. This is either populated directly
|
||||||
|
// in the case where we view a room by ID or by RoomView when it resolves
|
||||||
|
// what ID an alias points at.
|
||||||
|
currentRoomId: null,
|
||||||
logged_in: !!(MatrixClientPeg.get() && MatrixClientPeg.get().credentials),
|
logged_in: !!(MatrixClientPeg.get() && MatrixClientPeg.get().credentials),
|
||||||
collapse_lhs: false,
|
collapse_lhs: false,
|
||||||
collapse_rhs: false,
|
collapse_rhs: false,
|
||||||
|
|||||||
Reference in New Issue
Block a user