From b0105bc1ed034af76fa2289e7a54920c56039e63 Mon Sep 17 00:00:00 2001 From: Asaad Mahmood Date: Wed, 29 Jul 2015 19:29:57 +0500 Subject: mm-1762 - Search improvements with some other minor Ui changes --- web/react/components/search_bar.jsx | 11 ++++++++--- web/react/components/sidebar_header.jsx | 10 ++++++++-- 2 files changed, 16 insertions(+), 5 deletions(-) (limited to 'web/react/components') diff --git a/web/react/components/search_bar.jsx b/web/react/components/search_bar.jsx index f21f0cd58..e39cf5d46 100644 --- a/web/react/components/search_bar.jsx +++ b/web/react/components/search_bar.jsx @@ -36,6 +36,9 @@ module.exports = React.createClass({ } } }, + clearFocus: function(e) { + $('.search-bar__container').removeClass('focused'); + }, handleClose: function(e) { e.preventDefault(); @@ -57,6 +60,7 @@ module.exports = React.createClass({ }, handleUserFocus: function(e) { e.target.select(); + $('.search-bar__container').addClass('focused'); }, performSearch: function(terms, isMentionSearch) { if (terms.length) { @@ -92,13 +96,14 @@ module.exports = React.createClass({ render: function() { return (
-
Cancel
- +
+ Cancel
+ -
  • +
  • @@ -107,6 +107,12 @@ module.exports = React.createClass({ }; }, + toggleDropdown: function(e) { + e.preventDefault(); + e.stopPropagation(); + $('.team__header').find('.dropdown-toggle').trigger('click'); + }, + render: function() { var me = UserStore.getCurrentUser(); @@ -116,7 +122,7 @@ module.exports = React.createClass({ return (
    - + { me.last_picture_update ? { this.state.password_error } : null; - var server_error = this.state.server_error ? : null; + var password_error = this.state.password_error ?
    : null; + var server_error = this.state.server_error ?
    : null; return (
    -- cgit v1.2.3-1-g7c22 From 1e0abf74a3cfea6a540e922abf6e038018160fc4 Mon Sep 17 00:00:00 2001 From: Asaad Mahmood Date: Wed, 29 Jul 2015 20:24:28 +0500 Subject: Removing unused id on LHS dropdown --- web/react/components/sidebar_header.jsx | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'web/react/components') diff --git a/web/react/components/sidebar_header.jsx b/web/react/components/sidebar_header.jsx index b6ca8c1a5..0156dc01a 100644 --- a/web/react/components/sidebar_header.jsx +++ b/web/react/components/sidebar_header.jsx @@ -75,7 +75,7 @@ var NavbarDropdown = React.createClass({ return (
      -
    • +
    • @@ -108,8 +108,6 @@ module.exports = React.createClass({ }, toggleDropdown: function(e) { - e.preventDefault(); - e.stopPropagation(); $('.team__header').find('.dropdown-toggle').trigger('click'); }, -- cgit v1.2.3-1-g7c22