From 6f977c5caecaa972aa0f105f72a24e322b313f8f Mon Sep 17 00:00:00 2001 From: Aleksander Machniak Date: Fri, 27 Oct 2017 11:15:12 +0200 Subject: [PATCH] Fix scrolling issue in iframe'd forms with tabs --- skins/elastic/ui.js | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/skins/elastic/ui.js b/skins/elastic/ui.js index 5b4fa4e8a..2cc113eab 100644 --- a/skins/elastic/ui.js +++ b/skins/elastic/ui.js @@ -567,7 +567,12 @@ function rcube_elastic_ui() $('').addClass('nav-link') .attr({role: 'tab', 'href': '#' + id}) .text($('legend:first', fieldset).text()) - .click(function() { $(this).tab('show'); }) + .click(function() { + $(this).tab('show'); + // Returning false here prevents from strange scrolling issue + // when the form is in an iframe, e.g. contact edit form + return false; + }) ); $('legend:first', fieldset).hide();