2
0
forked from Wavyzz/dolibarr

Fix css for MD theme

This commit is contained in:
Laurent Destailleur
2019-04-03 14:36:27 +02:00
parent d7510016da
commit c5f5abc67d
3 changed files with 18 additions and 7 deletions

View File

@@ -7180,7 +7180,7 @@ function printCommonFooter($zone = 'private')
print "\n"; print "\n";
print '/* JS CODE TO ENABLE to manage handler to switch left menu page (menuhider) */'."\n"; print '/* JS CODE TO ENABLE to manage handler to switch left menu page (menuhider) */'."\n";
print 'jQuery(".menuhider").click(function(event) {'; print 'jQuery(".menuhider").click(function(event) {';
print ' if(!$( "body" ).hasClass( "sidebar-collapse" )){ event.preventDefault(); }'."\n"; print ' if (!$( "body" ).hasClass( "sidebar-collapse" )){ event.preventDefault(); }'."\n";
print ' console.log("We click on .menuhider");'."\n"; print ' console.log("We click on .menuhider");'."\n";
print ' $("body").toggleClass("sidebar-collapse")'."\n"; print ' $("body").toggleClass("sidebar-collapse")'."\n";
print '});'."\n"; print '});'."\n";

View File

@@ -1091,12 +1091,14 @@ if (! function_exists("llxHeader"))
// html header // html header
top_htmlhead($head, $title, $disablejs, $disablehead, $arrayofjs, $arrayofcss); top_htmlhead($head, $title, $disablejs, $disablehead, $arrayofjs, $arrayofcss);
//if ($conf->browser->layout == 'phone') $tmpcsstouse='sidebar-collapse'.($morecssonbody?' '.$morecssonbody:'');
//{ // If theme MD and classic layer, we open the menulayer by default.
$morecssonbody.= ' sidebar-collapse'; if ($conf->theme == 'md' && ! in_array($conf->browser->layout, array('phone','tablet')) && empty($conf->global->MAIN_OPTIMIZEFORTEXTBROWSER))
//} {
$tmpcsstouse=$morecssonbody;
}
print '<body id="mainbody"'.($morecssonbody?' class="'.$morecssonbody.'"':'').'>' . "\n"; print '<body id="mainbody" class="'.$tmpcsstouse.'">' . "\n";
// top menu and left menu area // top menu and left menu area
if (empty($conf->dol_hide_topmenu) || GETPOST('dol_invisible_topmenu', 'int')) if (empty($conf->dol_hide_topmenu) || GETPOST('dol_invisible_topmenu', 'int'))

View File

@@ -1771,6 +1771,7 @@ div.mainmenu.members {
div.mainmenu.menu { div.mainmenu.menu {
background-image: url(<?php echo dol_buildpath($path.'/theme/'.$theme.'/img/menus/menu.png', 1) ?>); background-image: url(<?php echo dol_buildpath($path.'/theme/'.$theme.'/img/menus/menu.png', 1) ?>);
top: 7px; top: 7px;
left: 5px;
} }
div.mainmenu.products { div.mainmenu.products {
@@ -1884,6 +1885,10 @@ foreach($mainmenuusedarray as $val)
a.tmenuimage { a.tmenuimage {
display: block; display: block;
} }
a.tmenuimage:focus {
outline: none;
}
/* Login */ /* Login */
@@ -5668,6 +5673,10 @@ border-top-right-radius: 6px;
} }
} }
.menuhider {
width: 40px;
}
/* nboftopmenuentries = <?php echo $nbtopmenuentries ?>, fontsize=<?php echo $fontsize ?> */ /* nboftopmenuentries = <?php echo $nbtopmenuentries ?>, fontsize=<?php echo $fontsize ?> */
/* disableimages = <?php echo $disableimages; ?> */ /* disableimages = <?php echo $disableimages; ?> */
/* rule to reduce top menu - 1st reduction */ /* rule to reduce top menu - 1st reduction */
@@ -5688,7 +5697,7 @@ border-top-right-radius: 6px;
margin-top: 0px; margin-top: 0px;
} }
li.tmenu, li.tmenusel { li.tmenu, li.tmenusel {
min-width: 32px; min-width: 34px;
} }
div.mainmenu { div.mainmenu {
min-width: auto; min-width: auto;