Просмотр исходного кода

Make background of graphs transperant so as not to show over the cards that they are on.
Change the screen size for shrinking margins around graphs.

Lee Morgan 5 лет назад
Родитель
Сommit
a3a23c2170

+ 10 - 6
views/dashboardPage/bundle.js

@@ -3226,7 +3226,8 @@ let analytics = {
                 r: 10,
                 b: 20,
                 t: 30
-            }
+            },
+            paper_bgcolor: "rgba(0, 0, 0, 0)"
         }
 
         Plotly.newPlot("itemUseGraph", [trace], layout);
@@ -3313,7 +3314,8 @@ let analytics = {
                 r: 10,
                 b: 20,
                 t: 30
-            }
+            },
+            paper_bgcolor: "rgba(0, 0, 0, 0)"
         }
 
         Plotly.newPlot("recipeSalesGraph", [trace], layout);
@@ -3442,10 +3444,11 @@ let home = {
             },
             yaxis: {
                 title: "$"
-            }
+            },
+            paper_bgcolor: "rgba(0, 0, 0, 0)"
         }
 
-        if(screen.width < 1400){
+        if(screen.width < 1200){
             layout.margin = {
                 l: 35,
                 r: 0
@@ -3563,10 +3566,11 @@ let home = {
                 },
                 yaxis: {
                     showticklabels: false
-                }
+                },
+                paper_bgcolor: "rgba(0, 0, 0, 0)"
             }
 
-            if(screen.width < 1400){
+            if(screen.width < 1200){
                 layout.margin = {
                     l: 10,
                     r: 10,

+ 4 - 2
views/dashboardPage/js/strands/analytics.js

@@ -175,7 +175,8 @@ let analytics = {
                 r: 10,
                 b: 20,
                 t: 30
-            }
+            },
+            paper_bgcolor: "rgba(0, 0, 0, 0)"
         }
 
         Plotly.newPlot("itemUseGraph", [trace], layout);
@@ -262,7 +263,8 @@ let analytics = {
                 r: 10,
                 b: 20,
                 t: 30
-            }
+            },
+            paper_bgcolor: "rgba(0, 0, 0, 0)"
         }
 
         Plotly.newPlot("recipeSalesGraph", [trace], layout);

+ 6 - 4
views/dashboardPage/js/strands/home.js

@@ -75,10 +75,11 @@ let home = {
             },
             yaxis: {
                 title: "$"
-            }
+            },
+            paper_bgcolor: "rgba(0, 0, 0, 0)"
         }
 
-        if(screen.width < 1400){
+        if(screen.width < 1200){
             layout.margin = {
                 l: 35,
                 r: 0
@@ -196,10 +197,11 @@ let home = {
                 },
                 yaxis: {
                     showticklabels: false
-                }
+                },
+                paper_bgcolor: "rgba(0, 0, 0, 0)"
             }
 
-            if(screen.width < 1400){
+            if(screen.width < 1200){
                 layout.margin = {
                     l: 10,
                     r: 10,