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

Allow advanced version to accept a promise, or something that has a .promise or .$promise

Open mtpultz opened this issue 9 years ago • 2 comments

Of the two options to pass to cg-busy is it possible to have the advanced version to expect a promise (or something that has a .promise or .$promise similar to the simple version. That would allow the use of $q.defer() in the advanced version, and an easy invocation to either resolve or reject, for example:

// Controller
vm.busy = {
    promise: $q.defer(),
    templateUrl: 'something.html',
    message: '...',
    backdrop: false
}

// Template
<div cg-busy="vm.busy"></div>

mtpultz avatar Nov 02 '16 04:11 mtpultz

+1

plantsmiles avatar Nov 19 '16 06:11 plantsmiles

Hi @mtpultz implemented your desired modifications from this post https://github.com/cgross/angular-busy/issues/102 into my fork. https://github.com/tiberiuzuld/angular-busy

tiberiuzuld avatar Nov 30 '16 22:11 tiberiuzuld