Преглед изворни кода

Update look of home strand on mobile.

Lee Morgan пре 5 година
родитељ
комит
14c1e881aa

+ 9 - 0
views/dashboardPage/bundle.js

@@ -3480,6 +3480,15 @@ let home = {
                     showticklabels: false
                 }
             }
+
+            if(screen.width < 1000){
+                layout.margin = {
+                    l: 10,
+                    r: 10,
+                    t: 100,
+                    b: 100
+                };
+            }
             
             Plotly.newPlot("popularIngredientsCard", [trace], layout);
         }else{

+ 4 - 0
views/dashboardPage/dashboard.css

@@ -645,6 +645,10 @@ Modal
             color: black;
         }
 
+        #homeStrand .flexRow:nth-child(3){
+            flex-grow: 2;
+        }
+
         #inventoryCheckCard{
             display: none;
         }

+ 1 - 1
views/dashboardPage/dashboard.ejs

@@ -151,7 +151,7 @@
                         </div>
                     </div>
 
-                    <div id="graphCard" class="card"></div>
+                    <div id="graphCard" class="card mobileHide"></div>
                 </div>
 
                 <div class="flexRow">

+ 9 - 0
views/dashboardPage/js/strands/home.js

@@ -189,6 +189,15 @@ let home = {
                     showticklabels: false
                 }
             }
+
+            if(screen.width < 1000){
+                layout.margin = {
+                    l: 10,
+                    r: 10,
+                    t: 100,
+                    b: 100
+                };
+            }
             
             Plotly.newPlot("popularIngredientsCard", [trace], layout);
         }else{