mirror of
https://github.com/portainer/portainer.git
synced 2025-07-25 16:29:44 +02:00
14 lines
282 B
JavaScript
14 lines
282 B
JavaScript
angular
|
|
.module('portainer')
|
|
.directive('autoFocus', ['$timeout', function porAutoFocus($timeout) {
|
|
var directive = {
|
|
restrict: 'A',
|
|
link: function($scope, $element) {
|
|
$timeout(function() {
|
|
$element[0].focus();
|
|
});
|
|
}
|
|
};
|
|
|
|
return directive;
|
|
}]);
|