From eee6a38c5fb3121c29b9b6b8a92aca1f119de0e2 Mon Sep 17 00:00:00 2001 From: Joseph Schorr Date: Tue, 5 Aug 2014 18:16:30 -0400 Subject: [PATCH] Auto-focus the tag name field in the add tag dialog --- static/js/controllers.js | 3 +++ static/partials/view-repo.html | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/static/js/controllers.js b/static/js/controllers.js index d430850ef..1a9dad045 100644 --- a/static/js/controllers.js +++ b/static/js/controllers.js @@ -471,6 +471,9 @@ function RepoCtrl($scope, $sanitize, Restangular, ImageMetadataService, ApiServi $scope.showAddTag = function(image) { $scope.toTagImage = image; $('#addTagModal').modal('show'); + setTimeout(function() { + $('#tagName').focus(); + }, 500); }; $scope.isOwnedTag = function(image, tagName) { diff --git a/static/partials/view-repo.html b/static/partials/view-repo.html index 7d683cd2b..2c66046fc 100644 --- a/static/partials/view-repo.html +++ b/static/partials/view-repo.html @@ -350,7 +350,7 @@