yalabot / angular-foundation

http://pineconellc.github.io/angular-foundation/
Other
1.05k stars 267 forks source link

alert always "closeable" due to angularjs change #242

Closed dbartholomae closed 8 years ago

dbartholomae commented 9 years ago

Hi there,

since AngularJS 1.4.x alerts will always be closeable (with an x in the upper right corner) as seen in this Plunker: http://plnkr.co/edit/X3xA0WOYpfBWAjtNqnKF

Here is the AngularJS commit that broke it: https://github.com/angular/angular.js/commit/6a38dbfd3c34c8f9efff503d17eb3cbeb666d422

And this change to the AlertController will fix it and should not break any existing code:

.controller('AlertController', ['$scope', '$attrs', function ($scope, $attrs) {
  $scope.closeable = 'close' in $attrs && typeof $attrs.close !== "undefined";
}])

Should I create a pull request? :)

jbrowning commented 9 years ago

Thanks for the report. As noted in #243, we haven't upgraded this library to 1.4 yet. A pull request to fix this issue would be greatly appreciated. :heart:

dbartholomae commented 9 years ago

Here you are :)

jbrowning commented 8 years ago

Fixed by #245.