- Using SystemJS as Module Loader - Auth and Permissions moved to Credentials.service from $rootScope - Toasts moved to Messages.service - Massive Changes - Sprint 1 done to move to Angular.io from AngularJS - Should be fully working!! :)
21 lines
540 B
TypeScript
21 lines
540 B
TypeScript
import * as $ from 'jquery';
|
|
|
|
export function Fadey() {
|
|
return {
|
|
restrict: 'A',
|
|
link: function (scope, element, attrs) {
|
|
const duration = 500;
|
|
element = $(element);
|
|
element.hide();
|
|
element.fadeIn(duration);
|
|
|
|
scope.destroy = function (complete) {
|
|
element.fadeOut(duration, function () {
|
|
if (complete) {
|
|
complete.apply(scope);
|
|
}
|
|
});
|
|
};
|
|
}
|
|
};
|
|
} |