Move the focus into the first input field in dialogs
authorAlexander Ebert <ebert@woltlab.com>
Tue, 19 Jul 2022 10:26:06 +0000 (12:26 +0200)
committerAlexander Ebert <ebert@woltlab.com>
Tue, 19 Jul 2022 10:26:06 +0000 (12:26 +0200)
wcfsetup/install/files/js/3rdParty/redactor2/plugins/WoltLabImage.js

index 85bb0b0cfa8b4ed117fde41e3be300e3abc72c4d..a7edb051c596e8182f5f349fb00f522742532d3f 100644 (file)
@@ -124,6 +124,10 @@ $.Redactor.prototype.WoltLabImage = function() {
                        button.textContent = WCF.Language.get('wcf.global.button.insert');
                        
                        this.WoltLabModal.rebuild();
+
+                       if (this.detect.isDesktop()) {
+                               document.getElementById("redactor-image-source").focus();
+                       }
                },
                
                insert: function(event) {