Skip to content

Commit

Permalink
add pi undervoltage (#1802)
Browse files Browse the repository at this point in the history
  • Loading branch information
mkz212 authored Nov 22, 2023
1 parent a8e36dd commit 3f8bb2c
Showing 1 changed file with 20 additions and 0 deletions.
20 changes: 20 additions & 0 deletions ui/src/app/shared/layout/layout.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,16 @@
<img class="menu-logo" src="/assets/homebridge-logo.svg" />
<strong>Homebridge</strong>
</a>
<div class="nav-item ml-auto mr-3" *ngIf="rPiWasUnderVoltage || rPiCurrentlyUnderVoltage">
<a href="javascript:void(0)" class="nav-link dropdown-toggle waves-effect waves-light"
[popoverTitle]="(rPiCurrentlyUnderVoltage ? 'rpi.throttled.currently_undervoltage_title' : 'rpi.throttled.previously_undervoltage_title') | translate"
[ngbPopover]="(rPiCurrentlyUnderVoltage ? 'rpi.throttled.currently_undervoltage_message' : 'rpi.throttled.previously_undervoltage_message') | translate"
[ngbTooltip]="(rPiCurrentlyUnderVoltage ? 'rpi.throttled.currently_undervoltage_title' : 'rpi.throttled.previously_undervoltage_title') | translate"
container="body" [placement]="['bottom', 'auto']">
<i class="fa-solid fa-bolt yellow-text " style="--fa-beat-scale: 2.0;"
[ngClass]="{ 'fa-beat': rPiCurrentlyUnderVoltage }"></i>
</a>
</div>
<button class="navbar-toggler collapsed" type="button" data-toggle="collapse" data-target="#navbarSupportedContent"
aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
<span class="toggler-icon top-bar"></span>
Expand Down Expand Up @@ -248,6 +258,16 @@
<li><a class="link_name" href="javascript:void(0)" (click)="$auth.logout()" [translate]="'menu.tooltip_logout'">{{ 'menu.tooltip_logout' | translate }} - {{ $auth.user.username }}</a></li>
</ul>
</li>
<li class="pl-3 mt-5" *ngIf="rPiWasUnderVoltage || rPiCurrentlyUnderVoltage">
<a href="javascript:void(0)" class="nav-link dropdown-toggle waves-effect waves-light"
[popoverTitle]="(rPiCurrentlyUnderVoltage ? 'rpi.throttled.currently_undervoltage_title' : 'rpi.throttled.previously_undervoltage_title') | translate"
[ngbPopover]="(rPiCurrentlyUnderVoltage ? 'rpi.throttled.currently_undervoltage_message' : 'rpi.throttled.previously_undervoltage_message') | translate"
[ngbTooltip]="(rPiCurrentlyUnderVoltage ? 'rpi.throttled.currently_undervoltage_title' : 'rpi.throttled.previously_undervoltage_title') | translate"
container="body" [placement]="['bottom', 'auto']">
<i class="fa-solid fa-bolt yellow-text " style="--fa-beat-scale: 2.0;"
[ngClass]="{ 'fa-beat': rPiCurrentlyUnderVoltage }"></i>
</a>
</li>
<li>
<div class="iocn-link" style="position: fixed; bottom:0;">
<a href="#" data-toggle="collapse" data-target=".sidebar,#chevron" aria-expanded="false" aria-controls=".sidebar">
Expand Down

0 comments on commit 3f8bb2c

Please sign in to comment.