diff --git a/src/popover/test/popover.spec.js b/src/popover/test/popover.spec.js
index 7a23c75c87..d888d470dd 100644
--- a/src/popover/test/popover.spec.js
+++ b/src/popover/test/popover.spec.js
@@ -68,6 +68,30 @@ describe('popover', function() {
elm.click();
expect(scope.clicked).toBeTruthy();
}));
+
+ it('should popup with animate class by default', inject(function() {
+ elm.trigger( 'click' );
+ expect( tooltipScope.isOpen ).toBe( true );
+
+ expect(elmBody.children().eq(1)).toHaveClass('fade');
+ }));
+
+ it('should popup without animate class when animation disabled', inject(function($compile) {
+ elmBody = angular.element(
+ '
Selector Text
'
+ );
+
+ $compile(elmBody)(scope);
+ scope.$digest();
+ elm = elmBody.find('span');
+ elmScope = elm.scope();
+ tooltipScope = elmScope.$$childTail;
+
+ elm.trigger( 'click' );
+ expect( tooltipScope.isOpen ).toBe( true );
+ expect(elmBody.children().eq(1)).not.toHaveClass('fade');
+ }));
+
});
diff --git a/src/tooltip/tooltip.js b/src/tooltip/tooltip.js
index 68bf8b196b..c3c5a3818c 100644
--- a/src/tooltip/tooltip.js
+++ b/src/tooltip/tooltip.js
@@ -101,7 +101,7 @@ angular.module( 'ui.bootstrap.tooltip', [ 'ui.bootstrap.position', 'ui.bootstrap
'content="'+startSym+'content'+endSym+'" '+
'content-exp="contentExp()" '+
'placement="'+startSym+'placement'+endSym+'" '+
- 'class="'+startSym+'class'+endSym+'" '+
+ 'popup-class="'+startSym+'popupClass'+endSym+'" '+
'animation="animation" '+
'is-open="isOpen"'+
'origin-scope="origScope" '+
@@ -292,7 +292,7 @@ angular.module( 'ui.bootstrap.tooltip', [ 'ui.bootstrap.position', 'ui.bootstrap
});
attrs.$observe( prefix+'Class', function ( val ) {
- ttScope.class = val;
+ ttScope.popupClass = val;
});
function prepPlacement() {
@@ -451,7 +451,7 @@ function ($animate , $sce , $compile , $templateRequest) {
return {
restrict: 'EA',
replace: true,
- scope: { content: '@', placement: '@', class: '@', animation: '&', isOpen: '&' },
+ scope: { content: '@', placement: '@', popupClass: '@', animation: '&', isOpen: '&' },
templateUrl: 'template/tooltip/tooltip-popup.html'
};
})
@@ -478,7 +478,7 @@ function ($animate , $sce , $compile , $templateRequest) {
return {
restrict: 'EA',
replace: true,
- scope: { contentExp: '&', placement: '@', class: '@', animation: '&', isOpen: '&' },
+ scope: { contentExp: '&', placement: '@', popupClass: '@', animation: '&', isOpen: '&' },
templateUrl: 'template/tooltip/tooltip-html-popup.html'
};
})
@@ -494,7 +494,7 @@ Deprecated
return {
restrict: 'EA',
replace: true,
- scope: { content: '@', placement: '@', class: '@', animation: '&', isOpen: '&' },
+ scope: { content: '@', placement: '@', popupClass: '@', animation: '&', isOpen: '&' },
templateUrl: 'template/tooltip/tooltip-html-unsafe-popup.html'
};
})
diff --git a/template/tooltip/tooltip-html-popup.html b/template/tooltip/tooltip-html-popup.html
index 8b34cee9c6..b236a240e7 100644
--- a/template/tooltip/tooltip-html-popup.html
+++ b/template/tooltip/tooltip-html-popup.html
@@ -1,4 +1,4 @@
-