Take number of entry into top menu to defined the trigger to change size

of top menu thumbs
This commit is contained in:
Laurent Destailleur 2015-11-17 19:16:40 +01:00
parent b1c5768de9
commit 683ad24ece
2 changed files with 28 additions and 17 deletions

View File

@ -215,7 +215,7 @@ print '*/'."\n";
if (! empty($conf->dol_optimize_smallscreen)) $fontsize=11;
//$nb=$menumanager->showmenu('topnb');
$nbtopmenuentries=$menumanager->showmenu('topnb');
//print $nb;
?>
@ -3871,6 +3871,17 @@ border-top-right-radius: 6px;
padding: 0 4px 0 4px;
}
@media only screen and (max-width: 767px)
{
.imgopensurveywizard { width:95%; height: auto; }
#tooltip {
position: absolute;
width: <?php print dol_size(350,'width'); ?>px;
}
}
@media only screen and (max-width: <?php echo $nbtopmenuentries * 85; ?>px)
{
.mainmenuaspan {
display: none;
@ -3888,13 +3899,6 @@ border-top-right-radius: 6px;
div.tmenuleft {
display: none;
}
.imgopensurveywizard { width:95%; height: auto; }
#tooltip {
position: absolute;
width: <?php print dol_size(350,'width'); ?>px;
}
}
@media only screen and (max-width: 570px)
{
@ -3910,7 +3914,8 @@ border-top-right-radius: 6px;
<?php } ?>
}
div.login_block {
top: 9px;
top: 4px;
max-width: 82px;
}
div.mainmenu {

View File

@ -32,7 +32,7 @@ if (! defined('NOREQUIRESOC')) define('NOREQUIRESOC','1');
if (! defined('NOCSRFCHECK')) define('NOCSRFCHECK',1);
if (! defined('NOTOKENRENEWAL')) define('NOTOKENRENEWAL',1);
if (! defined('NOLOGIN')) define('NOLOGIN',1); // File must be accessed by logon page so without login
if (! defined('NOREQUIREMENU')) define('NOREQUIREMENU',1);
//if (! defined('NOREQUIREMENU')) define('NOREQUIREMENU',1);
if (! defined('NOREQUIREHTML')) define('NOREQUIREHTML',1);
if (! defined('NOREQUIREAJAX')) define('NOREQUIREAJAX','1');
@ -209,6 +209,9 @@ print 'dol_screenheight='.$_SESSION['dol_screenheight']."\n";
print '*/'."\n";
if (! empty($conf->dol_optimize_smallscreen)) $fontsize=11;
$nbtopmenuentries=$menumanager->showmenu('topnb');
?>
/* ============================================================================== */
@ -3711,6 +3714,16 @@ border-top-right-radius: 6px;
padding: 0 4px 0 4px;
}
@media only screen and (max-width: 767px)
{
.imgopensurveywizard { width:95%; height: auto; }
#tooltip {
position: absolute;
width: <?php print dol_size(350,'width'); ?>px;
}
}
@media only screen and (max-width: <?php echo ($nbtopmenuentries * 85) + 200; ?>px)
{
.mainmenuaspan {
display: none;
@ -3728,13 +3741,6 @@ border-top-right-radius: 6px;
div.tmenuleft {
display: none;
}
.imgopensurveywizard { width:95%; height: auto; }
#tooltip {
position: absolute;
width: <?php print dol_size(350,'width'); ?>px;
}
}
@media only screen and (max-width: 570px)
{