You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@zeppelin.apache.org by co...@apache.org on 2015/12/01 08:38:23 UTC

incubator-zeppelin git commit: ZEPPELIN-463: UI freezes if table renders a lot of rows

Repository: incubator-zeppelin
Updated Branches:
  refs/heads/master d08a1214d -> c39bdb836


ZEPPELIN-463: UI freezes if table renders a lot of rows

Author: Prabhjyot Singh <pr...@gmail.com>

Closes #472 from prabhjyotsingh/ZEPPELIN-463 and squashes the following commits:

2a78466 [Prabhjyot Singh] if table length is more than 10,000 don't use perfectScrollbar


Project: http://git-wip-us.apache.org/repos/asf/incubator-zeppelin/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-zeppelin/commit/c39bdb83
Tree: http://git-wip-us.apache.org/repos/asf/incubator-zeppelin/tree/c39bdb83
Diff: http://git-wip-us.apache.org/repos/asf/incubator-zeppelin/diff/c39bdb83

Branch: refs/heads/master
Commit: c39bdb836a16f52bd80f729f150a20acc6384f03
Parents: d08a121
Author: Prabhjyot Singh <pr...@gmail.com>
Authored: Wed Nov 25 15:25:59 2015 +0530
Committer: Damien CORNEAU <co...@gmail.com>
Committed: Tue Dec 1 16:38:03 2015 +0900

----------------------------------------------------------------------
 .../src/app/notebook/paragraph/paragraph.controller.js         | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-zeppelin/blob/c39bdb83/zeppelin-web/src/app/notebook/paragraph/paragraph.controller.js
----------------------------------------------------------------------
diff --git a/zeppelin-web/src/app/notebook/paragraph/paragraph.controller.js b/zeppelin-web/src/app/notebook/paragraph/paragraph.controller.js
index 18a47a5..8114e9e 100644
--- a/zeppelin-web/src/app/notebook/paragraph/paragraph.controller.js
+++ b/zeppelin-web/src/app/notebook/paragraph/paragraph.controller.js
@@ -957,7 +957,11 @@ angular.module('zeppelinWebApp')
       html += '</table>';
 
       angular.element('#p' + $scope.paragraph.id + '_table').html(html);
-      angular.element('#p' + $scope.paragraph.id + '_table').perfectScrollbar();
+      if ($scope.paragraph.result.msgTable.length > 10000) {
+        angular.element('#p' + $scope.paragraph.id + '_table').css('overflow', 'scroll');
+      } else {
+        angular.element('#p' + $scope.paragraph.id + '_table').perfectScrollbar();
+      }
 
       // set table height
       var height = $scope.paragraph.config.graph.height;