mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2024-12-29 01:32:16 +01:00
5a5ab8ef5a
Since 2015/2016, there is a global pollution: ".ui.left" / ".ui.right". Fomantic UI doesn't work this way, it just conflicts with many Fomantic definitions. This PR starts the cleaning work of such techinical debts. And, the "label list" page has been quite messy for long time, for example, why "li" appears in "div" ...... And fix #24296 <details> ![image](https://user-images.githubusercontent.com/2114189/235051281-54c5374c-b5fd-4b5f-9aa2-02d4bb2d9112.png) ![image](https://user-images.githubusercontent.com/2114189/235055703-2ba042e0-4db7-4e63-8646-02f390d496b5.png) ![image](https://user-images.githubusercontent.com/2114189/235056310-4f6ffdc2-5758-4927-8fb8-314d9fb72a6b.png) ![image](https://user-images.githubusercontent.com/2114189/235058400-dab1c9ec-3325-4671-8345-aee6b0b68042.png) ![image](https://user-images.githubusercontent.com/2114189/235058424-85509532-b9bc-43ad-b00f-a87184c60f22.png) </details>
89 lines
3.5 KiB
Handlebars
89 lines
3.5 KiB
Handlebars
{{template "base/head" .}}
|
|
<div role="main" aria-label="{{.Title}}" class="page-content organization teams">
|
|
{{template "org/header" .}}
|
|
<div class="ui container">
|
|
{{template "base/alert" .}}
|
|
<div class="ui stackable grid">
|
|
{{template "org/team/sidebar" .}}
|
|
<div class="ui ten wide column">
|
|
{{template "org/team/navbar" .}}
|
|
{{$canAddRemove := and $.IsOrganizationOwner (not $.Team.IncludesAllRepositories)}}
|
|
{{if $canAddRemove}}
|
|
<div class="ui attached segment" id="repo-top-segment">
|
|
<div class="inline ui field left">
|
|
<form class="ui form ignore-dirty" id="add-repo-form" action="{{$.OrgLink}}/teams/{{$.Team.LowerName | PathEscape}}/action/repo/add" method="post">
|
|
{{.CsrfTokenHtml}}
|
|
<div class="inline field ui left">
|
|
<div id="search-repo-box" data-uid="{{.Org.ID}}" class="ui search">
|
|
<div class="ui input">
|
|
<input class="prompt" name="repo_name" placeholder="{{.locale.Tr "org.teams.search_repo_placeholder"}}" autocomplete="off" required>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<button class="ui green button">{{.locale.Tr "add"}}</button>
|
|
</form>
|
|
</div>
|
|
<div class="inline ui field right">
|
|
<form class="ui form" id="repo-multiple-form" action="{{$.OrgLink}}/teams/{{$.Team.LowerName | PathEscape}}/repositories" method="post">
|
|
<button class="ui green button add-all-button" data-modal-id="org-team-add-all-repo" data-url="{{$.OrgLink}}/teams/{{$.Team.LowerName | PathEscape}}/action/repo/addall">{{.locale.Tr "add_all"}}</button>
|
|
<button class="ui red button delete-button" data-modal-id="org-team-remove-all-repo" data-url="{{$.OrgLink}}/teams/{{$.Team.LowerName | PathEscape}}/action/repo/removeall">{{.locale.Tr "remove_all"}}</button>
|
|
</form>
|
|
</div>
|
|
</div>
|
|
{{end}}
|
|
<div class="ui bottom attached table segment repositories">
|
|
{{range .Team.Repos}}
|
|
<div class="item gt-df gt-ac gt-fw">
|
|
{{if .IsPrivate}}
|
|
{{svg "octicon-lock" 16 "gt-mr-3"}}
|
|
{{else if .IsFork}}
|
|
{{svg "octicon-repo-forked" 16 "gt-mr-3"}}
|
|
{{else if .IsMirror}}
|
|
{{svg "octicon-mirror" 16 "gt-mr-3"}}
|
|
{{else}}
|
|
{{svg "octicon-repo" 16 "gt-mr-3"}}
|
|
{{end}}
|
|
<a class="member gt-f1" href="{{$.Org.HomeLink}}/{{.Name | PathEscape}}">
|
|
<strong>{{$.Org.Name}}/{{.Name}}</strong>
|
|
</a>
|
|
{{if $canAddRemove}}
|
|
<form method="post" action="{{$.OrgLink}}/teams/{{$.Team.LowerName | PathEscape}}/action/repo/remove">
|
|
{{$.CsrfTokenHtml}}
|
|
<button type="submit" class="ui red small button right" name="repoid" value="{{.ID}}">{{$.locale.Tr "remove"}}</button>
|
|
</form>
|
|
{{end}}
|
|
</div>
|
|
{{else}}
|
|
<div class="item">
|
|
<span class="text grey italic">{{$.locale.Tr "org.teams.repos.none"}}</span>
|
|
</div>
|
|
{{end}}
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="ui g-modal-confirm delete modal" id="org-team-remove-all-repo">
|
|
<div class="header">
|
|
{{svg "octicon-trash"}}
|
|
{{.locale.Tr "org.teams.remove_all_repos_title"}}
|
|
</div>
|
|
<div class="content">
|
|
<p>{{.locale.Tr "org.teams.remove_all_repos_desc"}}</p>
|
|
</div>
|
|
{{template "base/modal_actions_confirm" .}}
|
|
</div>
|
|
|
|
<div class="ui g-modal-confirm addall modal" id="org-team-add-all-repo">
|
|
<div class="header">
|
|
{{svg "octicon-globe"}}
|
|
{{.locale.Tr "org.teams.add_all_repos_title"}}
|
|
</div>
|
|
<div class="content">
|
|
<p>{{.locale.Tr "org.teams.add_all_repos_desc"}}</p>
|
|
</div>
|
|
{{template "base/modal_actions_confirm" .}}
|
|
</div>
|
|
|
|
{{template "base/footer" .}}
|