1
1
mirror of https://github.com/go-gitea/gitea synced 2025-07-27 12:48:37 +00:00

Refactor LabelEdit (#32752)

And fix a regression:
https://github.com/go-gitea/gitea/pull/30053#discussion_r1874405470

Major changes:

* rewrite without jquery
* remove the "delete modal", using "link-action" is good enough
* merge "new modal" and "edit modal"
This commit is contained in:
wxiaoguang
2024-12-08 10:35:28 +08:00
committed by GitHub
parent a78a466383
commit 96d3a03a08
9 changed files with 110 additions and 193 deletions

View File

@@ -8,15 +8,11 @@
<button class="ui small primary new-label button">{{ctx.Locale.Tr "repo.issues.new_label"}}</button>
{{end}}
</div>
{{if and (or .CanWriteIssues .CanWritePulls) (not .Repository.IsArchived)}}
{{template "repo/issue/labels/label_new" .}}
{{end}}
{{template "base/alert" .}}
{{template "repo/issue/labels/label_list" .}}
</div>
{{if and (or .CanWriteIssues .CanWritePulls) (not .Repository.IsArchived)}}
{{template "repo/issue/labels/label_edit_modal" .}}
{{end}}
</div>
{{if and (or .CanWriteIssues .CanWritePulls) (not .Repository.IsArchived)}}
{{template "repo/issue/labels/edit_delete_label" .}}
{{end}}
{{template "base/footer" .}}