angular-busy icon indicating copy to clipboard operation
angular-busy copied to clipboard

Gain access to $cgBusyIsActive()

Open davfive opened this issue 6 years ago • 0 comments

I'm using minDuration because the action is quick but I'm "Checking for updates ..." and I want to leave it up long enough for them to read.

<div cg-busy="$ctrl.updatesBusy">
  <div ng-show="$ctrl.updateResult.done">
    ...
   </div>
</div>

However, the content in the second div will show behind the cgBusy while it's finishing up because my promise completed but cg-busy is still displaying. I want my div to show after cgBusy goes away.

In looking at the code, there is a call which is used in the directive for it's ng-show, that would be perfect for me: $cgBusyIsActive(). Then I could do

<div ng-show="!$cgBusyIsActive() && $ctrl.updateResult.done">

It is created, however, in a child scope, so I don't have access to it. It would be great to be able to have this feature.

davfive avatar Feb 13 '19 02:02 davfive