mirror of
https://github.com/nasa/openmct.git
synced 2025-06-17 14:48:13 +00:00
Fixed failing tests, and added stopPropagation to prevent maximizing of notifications on action click or dismiss
This commit is contained in:
@ -16,9 +16,9 @@
|
||||
</span>
|
||||
<a ng-hide="active.notification.primaryAction === undefined"
|
||||
class="banner-elem l-action s-action"
|
||||
ng-click="active.notification.primaryAction.action()">
|
||||
ng-click="action(active.notification.primaryAction.action, $event)">
|
||||
{{active.notification.primaryAction.label}}
|
||||
</a>
|
||||
<a class="banner-elem ui-symbol close" ng-click="dismiss(active.notification)">
|
||||
<a class="banner-elem ui-symbol close" ng-click="dismiss(active.notification, $event)">
|
||||
x</a>
|
||||
</div>
|
@ -28,7 +28,12 @@ define(
|
||||
function BannerController($scope, notificationService, dialogService) {
|
||||
$scope.active = notificationService.active;
|
||||
$scope.MessageSeverity = MessageSeverity;
|
||||
$scope.dismiss = function(notification) {
|
||||
$scope.action = function (action, $event){
|
||||
$event.stopPropagation();
|
||||
return action();
|
||||
}
|
||||
$scope.dismiss = function(notification, $event) {
|
||||
$event.stopPropagation();
|
||||
notificationService.dismissOrMinimize(notification);
|
||||
};
|
||||
$scope.maximize = function(notification) {
|
||||
|
Reference in New Issue
Block a user