switch to m.* prefixes for tags before it's too late

pull/342/head
Matthew Hodgson 2015-11-06 21:00:34 +01:00
parent c884c5fc33
commit 886ffbf158
3 changed files with 13 additions and 13 deletions

View File

@ -139,8 +139,8 @@ module.exports = {
var me = room.getMember(MatrixClientPeg.get().credentials.userId); var me = room.getMember(MatrixClientPeg.get().credentials.userId);
if (me && me.membership == "invite") { if (me && me.membership == "invite") {
s.lists["invites"] = s.lists["invites"] || []; s.lists["m.invite"] = s.lists["m.invite"] || [];
s.lists["invites"].push(room); s.lists["m.invite"].push(room);
} }
else { else {
var shouldShowRoom = ( var shouldShowRoom = (
@ -172,8 +172,8 @@ module.exports = {
} }
} }
else { else {
s.lists["recents"] = s.lists["recents"] || []; s.lists["m.recent"] = s.lists["m.recent"] || [];
s.lists["recents"].push(room); s.lists["m.recent"].push(room);
} }
} }
} }

View File

@ -77,7 +77,7 @@ var roomTileSource = {
var newOrder= {}; var newOrder= {};
if (item.targetList.props.order === 'manual') { if (item.targetList.props.order === 'manual') {
newOrder['order' = item.targetList.calcManualOrderTagData(item.room); newOrder['order'] = item.targetList.calcManualOrderTagData(item.room);
} }
// if we moved lists or the ordering changed, add the new tag // if we moved lists or the ordering changed, add the new tag

View File

@ -44,7 +44,7 @@ module.exports = React.createClass({
<div className="mx_RoomList" onScroll={self._repositionTooltip}> <div className="mx_RoomList" onScroll={self._repositionTooltip}>
{ expandButton } { expandButton }
<RoomSubList list={ self.state.lists['invites'] } <RoomSubList list={ self.state.lists['m.invite'] }
label="Invites" label="Invites"
editable={ false } editable={ false }
order="recent" order="recent"
@ -52,9 +52,9 @@ module.exports = React.createClass({
selectedRoom={ self.props.selectedRoom } selectedRoom={ self.props.selectedRoom }
collapsed={ self.props.collapsed } /> collapsed={ self.props.collapsed } />
<RoomSubList list={ self.state.lists['favourite'] } <RoomSubList list={ self.state.lists['m.favourite'] }
label="Favourites" label="Favourites"
tagName="favourite" tagName="m.favourite"
verb="favourite" verb="favourite"
editable={ true } editable={ true }
order="manual" order="manual"
@ -62,7 +62,7 @@ module.exports = React.createClass({
selectedRoom={ self.props.selectedRoom } selectedRoom={ self.props.selectedRoom }
collapsed={ self.props.collapsed } /> collapsed={ self.props.collapsed } />
<RoomSubList list={ self.state.lists['recents'] } <RoomSubList list={ self.state.lists['m.recent'] }
label="Conversations" label="Conversations"
editable={ true } editable={ true }
order="recent" order="recent"
@ -70,9 +70,9 @@ module.exports = React.createClass({
selectedRoom={ self.props.selectedRoom } selectedRoom={ self.props.selectedRoom }
collapsed={ self.props.collapsed } /> collapsed={ self.props.collapsed } />
<RoomSubList list={ self.state.lists['lowpriority'] } <RoomSubList list={ self.state.lists['m.lowpriority'] }
label="Low priority" label="Low priority"
tagName="lowpriority" tagName="m.lowpriority"
verb="deprioritize" verb="deprioritize"
editable={ true } editable={ true }
order="recent" order="recent"
@ -81,7 +81,7 @@ module.exports = React.createClass({
collapsed={ self.props.collapsed } /> collapsed={ self.props.collapsed } />
{ Object.keys(self.state.lists).map(function(tagName) { { Object.keys(self.state.lists).map(function(tagName) {
if (!tagName.match(/^(invites|favourite|recents|lowpriority|archived)$/)) { if (!tagName.match(/^m\.(invite|favourite|recent|lowpriority|archived)$/)) {
return <RoomSubList list={ self.state.lists[tagName] } return <RoomSubList list={ self.state.lists[tagName] }
key={ tagName } key={ tagName }
label={ tagName } label={ tagName }
@ -96,7 +96,7 @@ module.exports = React.createClass({
} }
}) } }) }
<RoomSubList list={ self.state.lists['archived'] } <RoomSubList list={ self.state.lists['m.archived'] }
label="Historical" label="Historical"
editable={ false } editable={ false }
order="recent" order="recent"