incubator-allura-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tvansteenbu...@apache.org
Subject [31/39] git commit: [#6545] tweak graph point size
Date Tue, 10 Sep 2013 15:55:27 GMT
[#6545] tweak graph point size


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

Branch: refs/heads/db/6545
Commit: 73bb7caec845aa4ccc05350fdb3fcededd53677c
Parents: c1685f6
Author: Dave Brondsema <dbrondsema@slashdotmedia.com>
Authored: Fri Sep 6 20:17:20 2013 +0000
Committer: Tim Van Steenburgh <tvansteenburgh@gmail.com>
Committed: Tue Sep 10 14:35:48 2013 +0000

----------------------------------------------------------------------
 .../templates/discussionforums/stats_graph.html         | 12 ++++++++++--
 1 file changed, 10 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-allura/blob/73bb7cae/ForgeDiscussion/forgediscussion/templates/discussionforums/stats_graph.html
----------------------------------------------------------------------
diff --git a/ForgeDiscussion/forgediscussion/templates/discussionforums/stats_graph.html b/ForgeDiscussion/forgediscussion/templates/discussionforums/stats_graph.html
index e05506b..39e4ef8 100644
--- a/ForgeDiscussion/forgediscussion/templates/discussionforums/stats_graph.html
+++ b/ForgeDiscussion/forgediscussion/templates/discussionforums/stats_graph.html
@@ -65,9 +65,17 @@
   /*global chartProjectStats */
   $(document).ready(function () {
     var series = function(data){
+      var size;
+      if (data.length < 20) {
+        size = 3;
+      } else if (data.length < 100) {
+        size = 2;
+      } else  {
+        size = 1;
+      }
       return [{label: "Posts",
-              lines: {show: true, lineWidth: 3},
-              points: {show:true, radius:2, fill: true, fillColor: '#0685c6'},
+              lines: {show: true, lineWidth: size},
+              points: {show:true, radius:size, fill: true, fillColor: '#0685c6'},
               data: data, shadowSize: 0}
              ];
     };


Mime
View raw message