Add hint box with dynamic join button

This commit is contained in:
zbettenbuk
2018-02-16 10:06:03 -06:00
committed by Lyubo Marinov
parent 547ddee3a5
commit e23d4317eb
8 changed files with 178 additions and 17 deletions

View File

@@ -28,8 +28,8 @@ class RecentList extends AbstractRecentList {
*
* @inheritdoc
*/
constructor() {
super();
constructor(props) {
super(props);
// Bind event handlers so they are only bound once per instance.
this._getAvatarStyle = this._getAvatarStyle.bind(this);
@@ -47,16 +47,22 @@ class RecentList extends AbstractRecentList {
* @returns {ReactElement}
*/
render() {
if (!this.props || !this.props._recentList) {
const { _recentList, disabled } = this.props;
if (!_recentList) {
return null;
}
const listViewDataSource
= this.dataSource.cloneWithRows(
getRecentRooms(this.props._recentList));
getRecentRooms(_recentList));
return (
<View style = { styles.container }>
<View
style = { [
styles.container,
disabled ? styles.containerDisabled : null
] }>
<ListView
dataSource = { listViewDataSource }
enableEmptySections = { true }