Skip to content

Commit a6101e3

Browse files
committed
fix(toastr): make animations optional
1 parent f35b658 commit a6101e3

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

src/toastr.js

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
angular.module('toastr', ['ngAnimate'])
1+
angular.module('toastr', [])
22

33
.directive('toast', ['$timeout', 'toastr', function($timeout, toastr) {
44
return {
@@ -52,7 +52,6 @@ angular.module('toastr', ['ngAnimate'])
5252
},
5353
messageClass: 'toast-message',
5454
positionClass: 'toast-top-right',
55-
target: 'body',
5655
timeOut: 5000,
5756
titleClass: 'toast-title',
5857
toastClass: 'toast'
@@ -131,7 +130,7 @@ angular.module('toastr', ['ngAnimate'])
131130
container = angular.element('<div></div>');
132131
container.attr('id', options.containerId);
133132
container.addClass(options.positionClass);
134-
var body = $document.find(options.target).eq(0);
133+
var body = $document.find('body').eq(0);
135134
$animate.enter(container, body, null, function() {
136135
containerDefer.resolve();
137136
});

0 commit comments

Comments
 (0)