Fix progress bar display on admin homepage.

This commit is contained in:
Buster "Silver Eagle" Neece 2021-10-11 21:22:51 -05:00
parent 5abfb3de32
commit 57d3ecc819
No known key found for this signature in database
GPG Key ID: 6D9E12FF03411F4E
2 changed files with 25 additions and 38 deletions

View File

@ -1,33 +1,17 @@
.progress-bar {
.progress {
&.h-5 {
border-bottom-width: 5px !important;
&::after {
height: 5px !important;
}
height: 5px;
}
&.h-10 {
border-bottom-width: 10px !important;
&::after {
height: 10px !important;
}
height: 10px;
}
&.h-15 {
border-bottom-width: 15px !important;
&::after {
height: 15px !important;
}
height: 15px;
}
&.h-20 {
border-bottom-width: 20px !important;
&::after {
height: 20px !important;
}
height: 20px;
}
}

View File

@ -50,8 +50,8 @@ $assets
</li>
<li class="list-group-item">
<p class="card-text mb-0">
<strong><?=round($load[2], 2)?></strong>
<small><?=__('15-Minute Average')?></small>
<strong><?= round($load[2], 2) ?></strong>
<small><?= __('15-Minute Average') ?></small>
</p>
</li>
</ul>
@ -59,44 +59,47 @@ $assets
<div class="card" role="region">
<div class="card-header bg-primary-dark">
<h2 class="card-title"><?=__('Memory')?></h2>
<h2 class="card-title"><?= __('Memory') ?></h2>
</div>
<div class="card-body">
<div class="progress mb-1">
<div class="progress-bar h-20" role="progressbar" aria-valuenow="<?=$memory_percent?>" aria-valuemin="0" aria-valuemax="100" style="width: <?=$memory_percent?>%;">
<span class="sr-only"><?=$memory_percent?>%</span>
<div class="progress h-20 mb-1">
<div class="progress-bar" role="progressbar" aria-valuenow="<?= $memory_percent ?>" aria-valuemin="0"
aria-valuemax="100" style="width: <?= $memory_percent ?>%;">
<?= $memory_percent ?>%
</div>
</div>
<h3><small><?=__('%s of %s Used', $memory_used, $memory_total)?></small></h3>
<h3><small><?= __('%s of %s Used', $memory_used, $memory_total) ?></small></h3>
</div>
</div>
<div class="card" role="region">
<div class="card-header bg-primary-dark">
<h2 class="card-title"><?=__('Disk Space')?></h2>
<h2 class="card-title"><?= __('Disk Space') ?></h2>
</div>
<div class="card-body">
<div class="progress mb-1">
<div class="progress-bar h-20" role="progressbar" aria-valuenow="<?=$space_percent?>" aria-valuemin="0" aria-valuemax="100" style="width: <?=$space_percent?>%;">
<span class="sr-only"><?=$space_percent?>%</span>
<div class="progress h-20 mb-1">
<div class="progress-bar" role="progressbar" aria-valuenow="<?= $space_percent ?>" aria-valuemin="0"
aria-valuemax="100" style="width: <?= $space_percent ?>%;">
<?= $space_percent ?>%
</div>
</div>
<h3><small><?=__('%s of %s Used', $space_used, $space_total)?></small></h3>
<h3><small><?= __('%s of %s Used', $space_used, $space_total) ?></small></h3>
</div>
</div>
</div>
<h2 class="outside-card-header mb-1"><?=__('Synchronization Tasks')?></h2>
<h2 class="outside-card-header mb-1"><?= __('Synchronization Tasks') ?></h2>
<div class="card-deck">
<?php foreach ($sync_times as $sync_key => $sync_info): ?>
<?php
foreach ($sync_times as $sync_key => $sync_info): ?>
<section class="card" role="region">
<div class="card-header bg-primary-dark">
<h2 class="card-title"><?=$sync_info['name']?></h2>
<h3 class="card-subtitle"><?=implode(', ', $sync_info['contents'])?></h3>
<h2 class="card-title"><?= $sync_info['name'] ?></h2>
<h3 class="card-subtitle"><?= implode(', ', $sync_info['contents']) ?></h3>
</div>
<div class="card-body">
<p class="card-text"><?=__(
<p class="card-text"><?= __(
'Last run: %s',
'<time data-duration="' . $sync_info['latest'] . '"></time>'
)?></p>