diff --git a/web/pgadmin/browser/static/js/collection.js b/web/pgadmin/browser/static/js/collection.js index 483f57b7..0549ebc9 100644 --- a/web/pgadmin/browser/static/js/collection.js +++ b/web/pgadmin/browser/static/js/collection.js @@ -93,12 +93,10 @@ define([ // All buttons will be created within a single // div area. var btnGroup = - $('
').addClass( - 'pg-prop-btn-group' - ), + $('
'), // Template used for creating a button tmpl = _.template([ - '', diff --git a/web/pgadmin/browser/static/js/node.js b/web/pgadmin/browser/static/js/node.js index 10427f0e..278a7ddc 100644 --- a/web/pgadmin/browser/static/js/node.js +++ b/web/pgadmin/browser/static/js/node.js @@ -1092,12 +1092,10 @@ define('pgadmin.browser.node', [ // All buttons will be created within a single // div area. var btnGroup = - $('
').addClass( - 'pg-prop-btn-group' - ), + $('
'), // Template used for creating a button tmpl = _.template([ - '', diff --git a/web/pgadmin/static/js/backform.pgadmin.js b/web/pgadmin/static/js/backform.pgadmin.js index 5db18cf3..2a8792b2 100644 --- a/web/pgadmin/static/js/backform.pgadmin.js +++ b/web/pgadmin/static/js/backform.pgadmin.js @@ -444,7 +444,7 @@ define([ template: _.template([ '', '
', - ' 0) { @@ -69,4 +78,4 @@ export function getGCD(inp_arr) { } return result; -} \ No newline at end of file +} diff --git a/web/pgadmin/tools/import_export/static/js/import_export.js b/web/pgadmin/tools/import_export/static/js/import_export.js index 4fbdf882..74499d11 100644 --- a/web/pgadmin/tools/import_export/static/js/import_export.js +++ b/web/pgadmin/tools/import_export/static/js/import_export.js @@ -591,6 +591,11 @@ define([ break; } }, + + onshow: function() { + var container = $(this.elements.body).find('.tab-content:first > .tab-pane.active:first'); + commonUtils.findAndSetFocus(container); + }, }, prepare: function() { @@ -656,8 +661,6 @@ define([ }); view.$el.attr('tabindex', -1); - var container = view.$el.find('.tab-content:first > .tab-pane.active:first'); - commonUtils.findAndSetFocus(container); setTimeout(function() { pgBrowser.keyboardNavigation.getDialogTabNavigator($(self.elements.dialog)); }, 200); diff --git a/web/pgadmin/tools/maintenance/static/js/maintenance.js b/web/pgadmin/tools/maintenance/static/js/maintenance.js index 4d696c31..2311b506 100644 --- a/web/pgadmin/tools/maintenance/static/js/maintenance.js +++ b/web/pgadmin/tools/maintenance/static/js/maintenance.js @@ -76,18 +76,24 @@ define([ '
', ' <% for (var i=0; i < options.length; i++) { %>', ' <% var option = options[i]; %>', - '
', ].join('\n')), + render: function() { + Backform.RadioControl.prototype.render.apply(this, arguments); + this.$el.find('.pg-maintenance-op .btn').on('keyup', (e)=>{ + switch(e.keyCode) { + case 32: /* Spacebar click */ + $(e.currentTarget).trigger('click'); + break; + } + }); + return this; + }, }), - select2: { - allowClear: false, - width: '100%', - placeholder: gettext('Select from list...'), - }, }, { type: 'nested', @@ -423,6 +429,10 @@ define([ }); } }, + onshow: function() { + var container = $(this.elements.body).find('.tab-content:first > .tab-pane.active:first'); + commonUtils.findAndSetFocus(container); + }, }, prepare: function() { // Main maintenance tool dialog container @@ -466,9 +476,6 @@ define([ } view.$el.attr('tabindex', -1); - var container = view.$el.find('.tab-content:first > .tab-pane.active:first'); - commonUtils.findAndSetFocus(container); - this.elements.content.appendChild($container.get(0)); }, };