incompatible protocol changes in authentication, version bumped to 0.8
This commit is contained in:
+8
-5
@@ -65,7 +65,8 @@
|
|||||||
|
|
||||||
// Make a data URL from public.photo
|
// Make a data URL from public.photo
|
||||||
function makeImageUrl(photo) {
|
function makeImageUrl(photo) {
|
||||||
return photo ? 'data:image/' + photo.type + ';base64,' + photo.data : null;
|
return (photo && photo.type && photo.data) ?
|
||||||
|
'data:image/' + photo.type + ';base64,' + photo.data : null;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* BEGIN Popup/dropdown menu */
|
/* BEGIN Popup/dropdown menu */
|
||||||
@@ -514,7 +515,7 @@
|
|||||||
title = "Edit Account"; break;
|
title = "Edit Account"; break;
|
||||||
case 'contacts':
|
case 'contacts':
|
||||||
title = this.props.title;
|
title = this.props.title;
|
||||||
avatar = this.props.avatar;
|
avatar = this.props.avatar ? this.props.avatar : true;
|
||||||
break;
|
break;
|
||||||
case 'new-topic':
|
case 'new-topic':
|
||||||
title = "Start New Chat";
|
title = "Start New Chat";
|
||||||
@@ -871,14 +872,16 @@
|
|||||||
},
|
},
|
||||||
handleSearch: function(e) {
|
handleSearch: function(e) {
|
||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
console.log("will search for '" + this.state.search + "'");
|
// Split query string by either space or comma, filter out empty strings.
|
||||||
|
var query = this.state.search.split(/[,\s]/).filter(Boolean);
|
||||||
|
console.log("will search for ", query);
|
||||||
},
|
},
|
||||||
render: function() {
|
render: function() {
|
||||||
return (
|
return (
|
||||||
<form className="panel-form" onSubmit={this.handleFindContacts}>
|
<form className="panel-form" onSubmit={this.handleFindContacts}>
|
||||||
<div className="panel-form-one">
|
<div className="panel-form-one">
|
||||||
<input type="text" placeholder="Emails or phones to find" value={this.state.search}
|
<input type="text" placeholder="Space or comma separated list: email:alice@example.com, tel:17025550003..."
|
||||||
onChange={this.handleSearchChange} required />
|
value={this.state.search} onChange={this.handleSearchChange} required />
|
||||||
<a href="#" onClick={this.handleSearch}>
|
<a href="#" onClick={this.handleSearch}>
|
||||||
<i className="material-icons">search</i>
|
<i className="material-icons">search</i>
|
||||||
</a>
|
</a>
|
||||||
|
|||||||
Reference in New Issue
Block a user