mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
Use media query to reduce font and img size when width is < 960px
Avoid having horizontal scrollbars.
This commit is contained in:
@@ -24,7 +24,7 @@ $image = getImage($device);
|
||||
|
||||
echo '
|
||||
<tr bgcolor="'.$device_colour.'" class="alert '.$class.'">
|
||||
<td width="40" align=center valign=middle style="padding: 21px;">'.$image.'</td>
|
||||
<td width="40" align=center valign=middle style="padding: 21px;"><span class="device_icon">'.$image.'</span></td>
|
||||
<td valign=middle style="padding: 0 15px;"><span style="font-size: 20px;">'.generate_device_link($device).'</span>
|
||||
<br />'.$device['location'].'</td>
|
||||
<td>';
|
||||
|
@@ -38,8 +38,8 @@ else {
|
||||
}//end if
|
||||
|
||||
if($_SESSION['screen_width']) {
|
||||
if($_SESSION['screen_width'] >= 800) {
|
||||
$graph_array['width'] = ($_SESSION['screen_width'] - 420 )/count($periods)+1;
|
||||
if($_SESSION['screen_width'] > 800) {
|
||||
$graph_array['width'] = ($_SESSION['screen_width'] - 400 )/count($periods)+1;
|
||||
}
|
||||
else {
|
||||
$graph_array['width'] = $_SESSION['screen_width'] - 155;
|
||||
@@ -47,7 +47,12 @@ if($_SESSION['screen_width']) {
|
||||
}
|
||||
|
||||
if($_SESSION['screen_height']) {
|
||||
$graph_array['height'] = ($_SESSION['screen_height'] - 250)/4;
|
||||
if($_SESSION['screen_width'] > 960) {
|
||||
$graph_array['height'] = ($_SESSION['screen_height'] - 250)/4;
|
||||
}
|
||||
else {
|
||||
$graph_array['height'] = ($_SESSION['screen_height'] - 250)/2;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user