mirror of
https://github.com/go-gitea/gitea
synced 2024-12-22 16:44:26 +00:00
Fix other create buttons
This commit is contained in:
parent
300dfae3e5
commit
dbc780b7f6
@ -15,7 +15,7 @@
|
||||
|
||||
{{if .ShowMemberAndTeamTab}}
|
||||
<div class="ui five wide column">
|
||||
{{if .CanCreateOrgRepo}}
|
||||
{{if and .CanCreateOrgRepo .SignedUser.CanCreateRepo}}
|
||||
<div class="center aligned tw-mb-4">
|
||||
<a class="ui primary button" href="{{AppSubUrl}}/repo/create?org={{.Org.ID}}">{{ctx.Locale.Tr "new_repo"}}</a>
|
||||
{{if not .DisableNewPullMirrors}}
|
||||
|
@ -13,6 +13,7 @@ const data = {
|
||||
textFilter: {{ctx.Locale.Tr "home.filter"}},
|
||||
textShowArchived: {{ctx.Locale.Tr "home.show_archived"}},
|
||||
textShowPrivate: {{ctx.Locale.Tr "home.show_private"}},
|
||||
textRepoReachLimitOfCreation: {{ctx.Locale.TrN .SignedUser.MaxCreationLimit "repo.form.reach_limit_of_creation_1" "repo.form.reach_limit_of_creation_n" .SignedUser.MaxCreationLimit}},
|
||||
|
||||
textShowBothArchivedUnarchived: {{ctx.Locale.Tr "home.show_both_archived_unarchived"}},
|
||||
textShowOnlyUnarchived: {{ctx.Locale.Tr "home.show_only_unarchived"}},
|
||||
@ -49,6 +50,7 @@ data.organizations = [{{range .Orgs}}{'name': {{.Name}}, 'num_repos': {{.NumRepo
|
||||
data.isOrganization = false;
|
||||
data.organizationsTotalCount = {{.UserOrgsCount}};
|
||||
data.canCreateOrganization = {{.SignedUser.CanCreateOrganization}};
|
||||
data.canCreateRepo = {{.SignedUser.CanCreateRepo}};
|
||||
{{else}}
|
||||
data.organizationId = {{.ContextUser.ID}};
|
||||
{{end}}
|
||||
|
@ -350,9 +350,12 @@ export default sfc; // activate the IDE's Vue plugin
|
||||
{{ textMyRepos }}
|
||||
<span class="ui grey label tw-ml-2">{{ reposTotalCount }}</span>
|
||||
</div>
|
||||
<a class="tw-flex tw-items-center muted" :href="subUrl + '/repo/create' + (isOrganization ? '?org=' + organizationId : '')" :data-tooltip-content="textNewRepo">
|
||||
<a v-if="canCreateRepo" class="tw-flex tw-items-center muted" :href="subUrl + '/repo/create' + (isOrganization ? '?org=' + organizationId : '')" :data-tooltip-content="textNewRepo">
|
||||
<svg-icon name="octicon-plus"/>
|
||||
</a>
|
||||
<span v-else class="tw-flex tw-items-center disabled" :data-tooltip-content="textRepoReachLimitOfCreation">
|
||||
<svg-icon name="octicon-plus"/>
|
||||
</span>
|
||||
</h4>
|
||||
<div class="ui attached segment repos-search">
|
||||
<div class="ui small fluid action left icon input">
|
||||
@ -546,4 +549,9 @@ ul li:not(:last-child) {
|
||||
.repo-owner-name-list li.active {
|
||||
background: var(--color-hover);
|
||||
}
|
||||
|
||||
span.disabled {
|
||||
opacity: var(--opacity-disabled);
|
||||
}
|
||||
|
||||
</style>
|
||||
|
Loading…
Reference in New Issue
Block a user