Browse Source

More UI fixes

Julio Montoya 12 years ago
parent
commit
4541c43cff

+ 4 - 7
main/document/create_document.php

@@ -29,15 +29,12 @@ var hide_bar = function() {
 }
 
 $(document).ready(function() {
-    if ($(window).width() <= 800 ) {
-        $("#template_col").hide();
+    if ($(window).width() <= 785 ) {
+        hide_bar();      
     }
     $("#hide_bar_template").toggle(
         function() { 
-            $("#template_col").hide(); 
-            $("#doc_form").removeClass("span9"); 
-            $("#doc_form").addClass("span11");             
-            $(this).css({"background-image" : \'url("../img/hide2.png")\'})
+          hide_bar();
         },
         function() { 
             $("#template_col").show(); 
@@ -597,7 +594,7 @@ if ($form->validate()) {
 	}    
     // HTML-editor
     echo '<div class="row-fluid" style="overflow:hidden">
-            <div id="template_col" class="span2" style="width:180px">
+            <div id="template_col" class="span2" style="width:162px">
                 <div id="frmModel" style="overflow: visible;"></div>
             </div>
             <div id="hide_bar_template"></div>

+ 4 - 7
main/document/edit_document.php

@@ -46,16 +46,13 @@ var hide_bar = function() {
 }
 
 $(document).ready(function() {   
-    if ($(window).width() <= 800 ) {
-        $("#template_col").hide();
+    if ($(window).width() <= 785 ) {
+        hide_bar();
     }
     
     $("#hide_bar_template").toggle(
         function() { 
-            $("#template_col").hide(); 
-            $("#doc_form").removeClass("span9"); 
-            $("#doc_form").addClass("span11");             
-            $(this).css({"background-image" : \'url("../img/hide2.png")\'})
+            hide_bar();
         },
         function() { 
             $("#template_col").show(); 
@@ -464,7 +461,7 @@ if ($owner_id == api_get_user_id() || api_is_platform_admin() || $is_allowed_to_
 		Display::display_warning_message(get_lang('BrowserDontSupportsSVG'));
 	}
 	echo '<div class="row-fluid" style="overflow:hidden">
-            <div id="template_col" class="span2" style="width:180px">
+            <div id="template_col" class="span2" style="width:162px">
                 <div id="frmModel" style="overflow: visible;"></div>
             </div>
             <div id="hide_bar_template"></div>

+ 8 - 5
main/newscorm/lp_add_item.php

@@ -200,6 +200,11 @@ $suredel = trim(get_lang('AreYouSureToDelete'));
     #resExercise .ui-selected { background: #F39814; color: white; }
     #resExercise { list-style-type: none; margin: 0; padding: 0; width: 60%; }
     #resExercise li { margin: 3px; padding: 0.4em; font-size: 1.4em; height: 18px; }
+    
+    /* Fixes LP toolbar */
+    #resource_tab li a {
+        padding: 5px 4px;
+    }
 </style>
     
 <script>
@@ -258,11 +263,9 @@ echo '</div>';
 if ($action == 'add_item' && $type == 'document' && !isset($_GET['file'])) {    
     echo '<div id="hide_bar_template" ></div>';    
 }
-if ($action == 'add_item' && $type == 'document' && !isset($_GET['file'])) {    
-    echo '<div id="doc_form" class="span7">';
-} else {
-    echo '<div id="doc_form" class="span8">';
-}
+
+echo '<div id="doc_form" class="span8">';
+
 if (isset($new_item_id) && is_numeric($new_item_id)) {        
     switch ($type) {
         case 'chapter':