This repository has been archived on 2020-03-24. You can view files and clone it, but cannot push or open issues or pull requests.
quay/static/js/directives/ui/registry-name.js

21 lines
569 B
JavaScript
Raw Normal View History

2019-11-12 16:09:47 +00:00
/**
* An element which displays the name of the registry (optionally the short name).
*/
angular.module('quay').directive('registryName', function () {
var directiveDefinitionObject = {
priority: 0,
templateUrl: '/static/directives/registry-name.html',
replace: false,
transclude: true,
restrict: 'C',
scope: {
'isShort': '=isShort'
},
controller: function($scope, $element, Config) {
$scope.name = $scope.isShort ? Config.REGISTRY_TITLE_SHORT : Config.REGISTRY_TITLE;
}
};
return directiveDefinitionObject;
});