1
0
mirror of https://github.com/chylex/Nextcloud-News.git synced 2025-04-09 19:15:42 +02:00

add keyboard shortcut for focussing the search input field

This commit is contained in:
Bernhard Posselt 2015-03-21 12:27:19 +01:00
parent 6c2ff7efef
commit 80d779aef6
6 changed files with 20 additions and 4 deletions

File diff suppressed because one or more lines are too long

View File

@ -2459,6 +2459,12 @@ app.service('SettingsResource', ["$http", "BASE_URL", function ($http, BASE_URL)
event.preventDefault();
nextFolder(navigationArea);
// q
} else if ([81].indexOf(keyCode) >= 0) {
event.preventDefault();
$('#searchbox').focus();
// page up
} else if ([33].indexOf(keyCode) >= 0) {
tryReload(navigationArea, scrollArea);

4
js/build/app.min.js vendored

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -428,6 +428,12 @@
event.preventDefault();
nextFolder(navigationArea);
// q
} else if ([81].indexOf(keyCode) >= 0) {
event.preventDefault();
$('#searchbox').focus();
// page up
} else if ([33].indexOf(keyCode) >= 0) {
tryReload(navigationArea, scrollArea);

View File

@ -65,6 +65,10 @@
<td>a</td>
<td><?php p($l->t('Scroll to active navigation entry')); ?></td>
</tr>
<tr>
<td>q</td>
<td><?php p($l->t('Focus search field')); ?></td>
</tr>
</table>
</div>
</div>