mirror of
https://github.com/bitwarden/web
synced 2025-12-12 06:13:28 +00:00
icons for vault listing
This commit is contained in:
11
src/app/directives/fallbackSrcDirective.js
Normal file
11
src/app/directives/fallbackSrcDirective.js
Normal file
@@ -0,0 +1,11 @@
|
||||
angular
|
||||
.module('bit.directives')
|
||||
|
||||
.directive('fallbackSrc', function () {
|
||||
return function (scope, element, attrs) {
|
||||
var el = $(element);
|
||||
el.bind('error', function (event) {
|
||||
el.attr('src', attrs.fallbackSrc);
|
||||
});
|
||||
};
|
||||
});
|
||||
Reference in New Issue
Block a user