From e2dc2e31eec2482dd04df2c68f716c8ea3474cc5 Mon Sep 17 00:00:00 2001 From: artoscinote <85488244+artoscinote@users.noreply.github.com> Date: Tue, 21 Mar 2023 15:24:40 +0100 Subject: [PATCH] Revert "Cursor position improvements, focused fields - part 2 (more in addons) [SCI-8147]" --- app/assets/javascripts/reports/new.js | 5 ----- app/assets/javascripts/repositories/index.js | 6 ------ .../javascripts/repositories/renderers/new_renderers.js | 1 - .../javascripts/repositories/renderers/view_renderers.js | 4 ++-- .../javascripts/repositories/repository_datatable.js | 1 - app/assets/javascripts/repository_columns/index.js | 7 +++---- app/assets/javascripts/sitewide/repository_helper.js | 3 --- app/assets/javascripts/sitewide/two_factor_wizard.js | 4 ---- app/views/reports/new.html.erb | 2 +- 9 files changed, 6 insertions(+), 27 deletions(-) diff --git a/app/assets/javascripts/reports/new.js b/app/assets/javascripts/reports/new.js index 451afe395..963a6123b 100644 --- a/app/assets/javascripts/reports/new.js +++ b/app/assets/javascripts/reports/new.js @@ -1054,10 +1054,6 @@ function reportHandsonTableConverter() { return reportData; } - function initNameContainerFocus() { - $('#newReportNameContainer').focus() - } - function initGenerateButton() { $('.reports-new').on('click', '.generate-button', function() { $.ajax({ @@ -1445,7 +1441,6 @@ function reportHandsonTableConverter() { $('#reportWizardEditWarning').modal('show'); $('.experiment-contents').sortable(); - initNameContainerFocus(); initGenerateButton(); initReportWizard(); initDropdowns(); diff --git a/app/assets/javascripts/repositories/index.js b/app/assets/javascripts/repositories/index.js index d33d23f94..e3c68b97c 100644 --- a/app/assets/javascripts/repositories/index.js +++ b/app/assets/javascripts/repositories/index.js @@ -197,12 +197,6 @@ } }); - $(document).on('shown.bs.modal', function() { - var inputField = $('#repository_name'); - var value = inputField.val(); - inputField.focus().val('').val(value); - }); - $('.create-new-repository').initSubmitModal('#create-repo-modal', 'repository'); if (notTurbolinksPreview()) { initRepositoriesDataTable('#repositoriesList', $('.repositories-index').hasClass('archived')); diff --git a/app/assets/javascripts/repositories/renderers/new_renderers.js b/app/assets/javascripts/repositories/renderers/new_renderers.js index 672db7862..c626f98d0 100644 --- a/app/assets/javascripts/repositories/renderers/new_renderers.js +++ b/app/assets/javascripts/repositories/renderers/new_renderers.js @@ -7,7 +7,6 @@ $.fn.dataTable.render.newRowName = function(formId, $cell) { $cell.html(`
${data.tasks}