From 02262b2b5f08b423fce833aa78505c2fd1744005 Mon Sep 17 00:00:00 2001
From: xamgore <xamgore@ya.ru>
Date: Sat, 11 Jun 2016 15:40:33 +0300
Subject: [PATCH] Make discipline view more responsive for students

---
 media/less/student/subject.less               | 75 ++++++++++++++++++-
 .../application/views/student/subject.twig    |  1 +
 2 files changed, 75 insertions(+), 1 deletion(-)

diff --git a/media/less/student/subject.less b/media/less/student/subject.less
index c3087459b..afb65318d 100644
--- a/media/less/student/subject.less
+++ b/media/less/student/subject.less
@@ -104,4 +104,77 @@ h3.blockTitle
   background: @ColorBlue;
   color: @ColorBaseGrey;
   text-align: center;
-}
\ No newline at end of file
+}
+
+
+@media all and (max-width: 599px) {
+    body {
+        min-width: initial;
+    }
+
+    #errButton {
+        display: none;
+    }
+
+    .main_layer {
+        max-width: initial;
+        min-width: initial;
+    }
+
+    .main .main_top {
+        display: inherit;
+        position: inherit;
+    }
+
+    .helpLink {
+        display: none;
+    }
+
+    .sidePadding {
+        padding: 0 5px !important;
+    }
+
+    .main .main_content {
+        border-radius: 0;
+        overflow: scroll;
+        padding-top: 8px !important;
+
+        .submoduleBlock {
+            text-align: center;
+            
+            .submoduleTitle {
+                width: 100%;
+                margin-bottom: 5px;
+            }
+            
+            .submoduleRate, .submodulePercent, .submoduleDate {
+                width: 20%;
+            }
+        }
+        
+        .moduleResult {
+            margin-bottom: 20px;
+        }
+        
+        .label {
+            width: 40%;
+        }
+    }
+
+    .header_wrapper {
+        padding: 9pt 10px;
+
+        .logotype span, #username {
+            display: none;
+        }
+    }
+
+    div.window {
+        min-width: initial !important;
+
+        .window-block {
+            width: initial !important;
+            border-radius: 0;
+        }
+    }
+}
diff --git a/~dev_rating/application/views/student/subject.twig b/~dev_rating/application/views/student/subject.twig
index ca507f3fa..55b6815e0 100644
--- a/~dev_rating/application/views/student/subject.twig
+++ b/~dev_rating/application/views/student/subject.twig
@@ -1,6 +1,7 @@
 {% extends 'base' %} 
  
 {% block media %} {# head -> css, js #}
+    <meta name="viewport" content="width=device-width, initial-scale=1.0">
     {{ HTML.style('static/css/student/subject.css')|raw }}
 {% endblock %}
 
-- 
GitLab