mirror of
https://github.com/balena-io/etcher.git
synced 2025-07-19 17:26:34 +00:00
feat(GUI): replace ng-show and ng-hide with ng-if
We replace `ng-show/hide` with `ng-if` on the main page in order to remove unnecessary calls and become more efficient. Changelog-Entry: Replace ng-show/hide with ng-if on main page. Change-Type: patch
This commit is contained in:
parent
41a694e4a4
commit
e769ef7d0b
@ -7,7 +7,7 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="space-vertical-large">
|
<div class="space-vertical-large">
|
||||||
<div ng-hide="main.selection.hasImage()">
|
<div ng-if="!main.selection.hasImage()">
|
||||||
<button
|
<button
|
||||||
class="button button-primary button-brick"
|
class="button button-primary button-brick"
|
||||||
tabindex="{{ main.selection.hasImage() ? -1 : 1 }}"
|
tabindex="{{ main.selection.hasImage() ? -1 : 1 }}"
|
||||||
@ -49,7 +49,7 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="space-vertical-large">
|
<div class="space-vertical-large">
|
||||||
<div ng-hide="main.selection.hasDrive()">
|
<div ng-if="!main.selection.hasDrive()">
|
||||||
|
|
||||||
<div>
|
<div>
|
||||||
<button class="button button-primary button-brick"
|
<button class="button button-primary button-brick"
|
||||||
@ -59,7 +59,7 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
<div ng-show="main.selection.hasDrive()">
|
<div ng-if="main.selection.hasDrive()">
|
||||||
|
|
||||||
<div class="step-selection-text"
|
<div class="step-selection-text"
|
||||||
ng-class="{
|
ng-class="{
|
||||||
@ -99,7 +99,7 @@
|
|||||||
<span ng-bind="flash.getProgressButtonLabel()"></span>
|
<span ng-bind="flash.getProgressButtonLabel()"></span>
|
||||||
</progress-button>
|
</progress-button>
|
||||||
|
|
||||||
<p class="step-footer step-footer-split" ng-show="main.state.getFlashState().speed && main.state.getFlashState().percentage != 100">
|
<p class="step-footer step-footer-split" ng-if="main.state.getFlashState().speed && main.state.getFlashState().percentage != 100">
|
||||||
<span ng-bind="main.state.getFlashState().speed.toFixed(2) + ' MB/s'"></span>
|
<span ng-bind="main.state.getFlashState().speed.toFixed(2) + ' MB/s'"></span>
|
||||||
<span>ETA: {{ main.state.getFlashState().eta | secondsToDate | amDateFormat:'m[m]ss[s]' }}</span>
|
<span>ETA: {{ main.state.getFlashState().eta | secondsToDate | amDateFormat:'m[m]ss[s]' }}</span>
|
||||||
</p>
|
</p>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user