Merge pull request #116 from nickago/MM-1341

MM-1341 mention auto-complete now goes away if you move off it's specific textbox
Этот коммит содержится в:
Joram Wilander
2015-07-03 15:05:33 -04:00
родитель 5b59e38a21 d47c86b921
Коммит 4a3003c0dc

Просмотреть файл

@@ -23,6 +23,11 @@ module.exports = React.createClass({
} }
} }
); );
$(document).click(function() {
if($('#'+self.props.id).length && $('#'+self.props.id).get(0) !== $(':focus').get(0)) {
self.setState({mentionText: "-1"})
}
});
}, },
componentWillUnmount: function() { componentWillUnmount: function() {
PostStore.removeMentionDataChangeListener(this._onChange); PostStore.removeMentionDataChangeListener(this._onChange);