mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-11-08 23:58:13 +08:00
A whole lotta shit
This commit is contained in:
24
js/ext/angular/src/directive/ionicLoading.js
vendored
Normal file
24
js/ext/angular/src/directive/ionicLoading.js
vendored
Normal file
@ -0,0 +1,24 @@
|
||||
(function() {
|
||||
'use strict';
|
||||
|
||||
angular.module('ionic.ui.loading', [])
|
||||
|
||||
.directive('loading', function() {
|
||||
return {
|
||||
restrict: 'E',
|
||||
replace: true,
|
||||
transclude: true,
|
||||
link: function($scope, $element){
|
||||
$scope.$on('$destroy', function() {
|
||||
$element.remove();
|
||||
});
|
||||
$element.addClass($scope.animation || '');
|
||||
},
|
||||
template: '<div class="loading-backdrop" ng-class="{enabled: showBackdrop}">' +
|
||||
'<div class="loading" ng-transclude>' +
|
||||
'</div>' +
|
||||
'</div>'
|
||||
};
|
||||
});
|
||||
|
||||
})();
|
||||
Reference in New Issue
Block a user