initial import for Open Source 🎉
This commit is contained in:
parent
1898c361f3
commit
9c0dd3b722
2048 changed files with 218743 additions and 0 deletions
28
static/js/directives/ui/repo-list-grid.js
Normal file
28
static/js/directives/ui/repo-list-grid.js
Normal file
|
@ -0,0 +1,28 @@
|
|||
/**
|
||||
* An element that displays a list of repositories in a grid.
|
||||
*/
|
||||
angular.module('quay').directive('repoListGrid', function () {
|
||||
var directiveDefinitionObject = {
|
||||
priority: 0,
|
||||
templateUrl: '/static/directives/repo-list-grid.html',
|
||||
replace: false,
|
||||
transclude: true,
|
||||
restrict: 'C',
|
||||
scope: {
|
||||
repositoriesResource: '=repositoriesResource',
|
||||
starred: '=starred',
|
||||
namespace: '=namespace',
|
||||
starToggled: '&starToggled',
|
||||
hideTitle: '=hideTitle',
|
||||
hideNamespaces: '=hideNamespaces',
|
||||
repoKind: '@repoKind'
|
||||
},
|
||||
controller: function($scope, $element, UserService, StateService) {
|
||||
$scope.inReadOnlyMode = StateService.inReadOnlyMode();
|
||||
$scope.isOrganization = function(namespace) {
|
||||
return !!UserService.getOrganization(namespace);
|
||||
};
|
||||
}
|
||||
};
|
||||
return directiveDefinitionObject;
|
||||
});
|
Reference in a new issue