[Rt-commit] rt branch, 4.4/scroll-mode-fill-browser-window, created. rt-4.4.4-45-gf428d696d

? sunnavy sunnavy at bestpractical.com
Thu May 30 11:54:29 EDT 2019

The branch, 4.4/scroll-mode-fill-browser-window has been created
        at  f428d696d39b519a2922f22643f4581fcfdd146d (commit)

- Log -----------------------------------------------------------------
commit f428d696d39b519a2922f22643f4581fcfdd146d
Author: sunnavy <sunnavy at bestpractical.com>
Date:   Thu May 30 02:42:01 2019 +0800

    Automatically load more txns to fill browser window on scroll history mode
    For various reasons(e.g. ticket metadata section is collpased or some
    txns are skipped), it's possbile that ticket display page only shows a
    couple of txns by default, leaving space at the bottom of the page
    without scroll bar, which could mislead people to think that all the
    txns are already loaded.
    This commit fixes this issue by automatically loading more txns when
    there is still space left in the browser window.

diff --git a/share/html/Ticket/Elements/ScrollShowHistory b/share/html/Ticket/Elements/ScrollShowHistory
index d2aca08a8..73e51febd 100644
--- a/share/html/Ticket/Elements/ScrollShowHistory
+++ b/share/html/Ticket/Elements/ScrollShowHistory
@@ -149,6 +149,13 @@ jQuery(function(){
+                    if( jQuery(document).height() <= jQuery(window).height() + loadDistanceFromBottom ) {
+                        // if there are still space left, automatically load more
+                        isLoading = false;
+                        loadHistoryPage();
+                        return;
+                    }
                     if (hashTransactionId) { // focus transaction if we are following a link to it
                         hashTransactionId = null;
                         location.href = hash;


More information about the rt-commit mailing list