summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMorris Jobke <hey@morrisjobke.de>2016-11-18 21:11:46 +0100
committerGitHub <noreply@github.com>2016-11-18 21:11:46 +0100
commitcdf248f92eb907da7017c731be315758be5185b2 (patch)
treeaea95802a8656b39490bcd6d9f3c7818d419f897
parentece22051a0645f9ba88e559fdc79d82fd81e0837 (diff)
parent494c3b1533caa2a604777f378384319b6ae9e0a8 (diff)
downloadnextcloud-server-cdf248f92eb907da7017c731be315758be5185b2.tar.gz
nextcloud-server-cdf248f92eb907da7017c731be315758be5185b2.zip
Merge pull request #1855 from nextcloud/focus-onslidetoggle
Add focus to autofocus form element on slide toggle
-rw-r--r--core/js/apps.js4
1 files changed, 4 insertions, 0 deletions
diff --git a/core/js/apps.js b/core/js/apps.js
index a2d3460c907..3b94aa1d87e 100644
--- a/core/js/apps.js
+++ b/core/js/apps.js
@@ -79,6 +79,10 @@
area.slideDown(OC.menuSpeed*4, function() {
area.trigger(new $.Event('show'));
});
+ var input = $(areaSelector + ' [autofocus]');
+ if (input.length === 1) {
+ input.focus();
+ }
}
// do nothing if the area is animated