mirror of
https://github.com/discourse/discourse.git
synced 2024-11-30 23:05:48 +08:00
FEATURE: enter on search will take you to full page search
This commit is contained in:
parent
1408563a7f
commit
93b5af716c
|
@ -2,5 +2,11 @@ export default Discourse.View.extend({
|
||||||
tagName: 'div',
|
tagName: 'div',
|
||||||
classNames: ['d-dropdown'],
|
classNames: ['d-dropdown'],
|
||||||
elementId: 'search-dropdown',
|
elementId: 'search-dropdown',
|
||||||
templateName: 'search'
|
templateName: 'search',
|
||||||
|
keyDown: function(e){
|
||||||
|
var term = this.get('controller.term');
|
||||||
|
if (e.which === 13 && term && term.length > 2) {
|
||||||
|
this.get('controller').send('moreOfType', 'topic');
|
||||||
|
}
|
||||||
|
}
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in New Issue
Block a user