victos / angular-opensource

angular opensource modules
MIT License
20 stars 21 forks source link

Directive isn't accepting options #24

Closed buddyackerman closed 2 years ago

buddyackerman commented 4 years ago

Tried to implement a delay in this way

<div class="container" [ngBusy]="busy" delay="500">

Are the options not implemented as @Input properties?

Betalos commented 4 years ago

@buddyackerman could be more specific in your issue. What is the problem exactly that you're facing.

buddyackerman commented 3 years ago

I was hoping that the this directive would allow you to set the options on the element itself, e.g.:

<div [ngBusy]="busy" delay="500">some content</div>

That way the behavior could be modified for each context in which it is used.

Betalos commented 3 years ago

Ah I see for that you need to pass the config to the directive as an object like this:

<div [ngBusy]="{busy: busy: delay: 500}">some content</div>