Show loader when tags are loading instead of empty msg

This commit is contained in:
Kenny Lee Sin Cheong 2018-10-24 17:35:02 -04:00
parent 1cda2e1a62
commit e61551d6b9
3 changed files with 8 additions and 3 deletions

View file

@ -341,7 +341,8 @@
<div class="empty-secondary-msg">Try expanding your filtering terms.</div>
</div>
<div class="empty" ng-if="!allTags.length">
<div class="cor-loader" ng-show="tagsLoading"></div>
<div class="empty" ng-if="!allTags.length && !tagsLoading">
<div class="empty-primary-msg">This repository is empty.</div>
<div class="empty-secondary-msg">Push a tag or initiate a build to populate this repository.</div>
</div>

View file

@ -31,7 +31,8 @@
'imageLoader': imageLoader,
'builds': null,
'historyFilter': '',
'repositoryTags': null
'repositoryTags': null,
'tagsLoading': true
};
$scope.repositoryTags = {};
@ -77,6 +78,8 @@
if (resp.has_additional) {
loadPaginatedRepositoryTags(page + 1);
} else {
$scope.viewScope.tagsLoading = false;
}
});
};

View file

@ -77,6 +77,7 @@
<div class="repo-panel-tags"
repository="viewScope.repository"
repository-tags="viewScope.repositoryTags"
tags-loading="viewscope.tagsLoading"
image-loader="viewScope.imageLoader"
selected-tags="viewScope.selectedTags"
history-filter="viewScope.historyFilter"