From a2e90014ec20a1085449a66061389cfe0d12260f Mon Sep 17 00:00:00 2001 From: silverwind Date: Mon, 4 Mar 2024 04:33:20 +0100 Subject: [PATCH] Replace some `gt-` classes with `tw-` (#29570) Replace 18 `gt-` prefixes with `tw-` with perl replacement. I manually checked them all with `rg` afterwards. --- templates/admin/notice.tmpl | 2 +- templates/org/header.tmpl | 2 +- templates/package/view.tmpl | 2 +- templates/projects/list.tmpl | 2 +- templates/projects/new.tmpl | 2 +- templates/projects/view.tmpl | 4 ++-- templates/repo/branch/list.tmpl | 2 +- templates/repo/commit_page.tmpl | 2 +- templates/repo/commits_list_small.tmpl | 2 +- templates/repo/commits_table.tmpl | 2 +- templates/repo/diff/box.tmpl | 4 ++-- templates/repo/diff/comment_form.tmpl | 2 +- templates/repo/diff/compare.tmpl | 2 +- templates/repo/empty.tmpl | 2 +- templates/repo/header.tmpl | 2 +- templates/repo/home.tmpl | 4 ++-- templates/repo/issue/list.tmpl | 2 +- templates/repo/issue/milestone_new.tmpl | 2 +- templates/repo/issue/view_content.tmpl | 4 ++-- .../repo/issue/view_content/comments.tmpl | 2 +- .../view_content/comments_delete_time.tmpl | 2 +- templates/repo/migrate/migrate.tmpl | 4 ++-- templates/repo/release/new.tmpl | 2 +- templates/repo/settings/branches.tmpl | 2 +- templates/repo/settings/githooks.tmpl | 2 +- templates/repo/settings/lfs_pointers.tmpl | 2 +- templates/repo/settings/options.tmpl | 2 +- templates/repo/settings/tags.tmpl | 2 +- templates/repo/unicode_escape_prompt.tmpl | 4 ++-- templates/repo/view_file.tmpl | 4 ++-- templates/repo/wiki/view.tmpl | 6 +++--- templates/status/500.tmpl | 2 +- templates/user/auth/captcha.tmpl | 2 +- templates/user/dashboard/issues.tmpl | 2 +- .../user/notification/notification_div.tmpl | 2 +- templates/user/settings/applications.tmpl | 4 ++-- templates/user/settings/repos.tmpl | 2 +- web_src/css/helpers.css | 20 ------------------- .../js/components/RepoBranchTagSelector.vue | 2 +- web_src/js/features/common-global.js | 2 +- web_src/js/modules/fomantic.js | 2 +- 41 files changed, 50 insertions(+), 70 deletions(-) diff --git a/templates/admin/notice.tmpl b/templates/admin/notice.tmpl index ed410425b5..e0abe4f8c0 100644 --- a/templates/admin/notice.tmpl +++ b/templates/admin/notice.tmpl @@ -31,7 +31,7 @@ -
+ {{.CsrfTokenHtml}}
diff --git a/templates/org/header.tmpl b/templates/org/header.tmpl index efbbc43b1d..943557b1ca 100644 --- a/templates/org/header.tmpl +++ b/templates/org/header.tmpl @@ -7,7 +7,7 @@ {{if .Org.Visibility.IsLimited}}{{ctx.Locale.Tr "org.settings.visibility.limited_shortname"}}{{end}} {{if .Org.Visibility.IsPrivate}}{{ctx.Locale.Tr "org.settings.visibility.private_shortname"}}{{end}} - + {{if .EnableFeed}} {{svg "octicon-rss" 24}} diff --git a/templates/package/view.tmpl b/templates/package/view.tmpl index 0fa23d67fd..54af71126f 100644 --- a/templates/package/view.tmpl +++ b/templates/package/view.tmpl @@ -87,7 +87,7 @@ {{end}}
{{ctx.Locale.Tr "packages.versions"}} ({{.TotalVersionCount}}) -
{{ctx.Locale.Tr "packages.versions.view_all"}} + {{ctx.Locale.Tr "packages.versions.view_all"}}
{{range .LatestVersions}}
diff --git a/templates/projects/list.tmpl b/templates/projects/list.tmpl index 30fbd498a4..54a41221bf 100644 --- a/templates/projects/list.tmpl +++ b/templates/projects/list.tmpl @@ -10,7 +10,7 @@ {{ctx.Locale.PrettyNumber .ClosedCount}} {{ctx.Locale.Tr "repo.issues.closed_title"}}
- diff --git a/templates/projects/new.tmpl b/templates/projects/new.tmpl index 711dbe842a..92ee36c1c4 100644 --- a/templates/projects/new.tmpl +++ b/templates/projects/new.tmpl @@ -55,7 +55,7 @@
-
+
{{ctx.Locale.Tr "repo.milestones.cancel"}} diff --git a/templates/projects/view.tmpl b/templates/projects/view.tmpl index 3792ccca0e..1d03477a9f 100644 --- a/templates/projects/view.tmpl +++ b/templates/projects/view.tmpl @@ -165,9 +165,9 @@
-
+
{{range (index $.IssuesMap .ID)}} -
+
{{template "repo/issue/card" (dict "Issue" . "Page" $)}}
{{end}} diff --git a/templates/repo/branch/list.tmpl b/templates/repo/branch/list.tmpl index 46503cb5df..916111faca 100644 --- a/templates/repo/branch/list.tmpl +++ b/templates/repo/branch/list.tmpl @@ -72,7 +72,7 @@
{{ctx.Locale.Tr "repo.branches"}}
-
+
{{if .Commit.Signature}} -
+
{{if .Verification.Verified}} {{if ne .Verification.SigningUser.ID 0}} diff --git a/templates/repo/commits_list_small.tmpl b/templates/repo/commits_list_small.tmpl index 79e1bd6309..86e6b7225e 100644 --- a/templates/repo/commits_list_small.tmpl +++ b/templates/repo/commits_list_small.tmpl @@ -13,7 +13,7 @@ {{$commitLink:= printf "%s/commit/%s" $.comment.Issue.PullRequest.BaseRepo.Link (PathEscape .ID.String)}} - + {{template "repo/commit_statuses" dict "Status" .Status "Statuses" .Statuses}} {{$class := "ui sha label"}} {{if .Signature}} diff --git a/templates/repo/commits_table.tmpl b/templates/repo/commits_table.tmpl index 054a3f6bec..70f673e27e 100644 --- a/templates/repo/commits_table.tmpl +++ b/templates/repo/commits_table.tmpl @@ -8,7 +8,7 @@ {{ctx.Locale.Tr "repo.commits.no_commits" $.BaseBranch $.HeadBranch}} {{end}}
-
+
{{if .PageIsCommits}}
{{if and .PageIsPullFiles $.SignedUserID (not .IsArchived) (not .DiffNotAvailable)}} -
+
@@ -202,7 +202,7 @@
{{if $showFileViewToggle}} {{/* for image or CSV, it can have a horizontal scroll bar, there won't be review comment context menu (position absolute) which would be clipped by "overflow" */}} -
+
{{if $isImage}} {{template "repo/diff/image_diff" dict "file" . "root" $ "blobBase" $blobBase "blobHead" $blobHead "sniffedTypeBase" $sniffedTypeBase "sniffedTypeHead" $sniffedTypeHead}} diff --git a/templates/repo/diff/comment_form.tmpl b/templates/repo/diff/comment_form.tmpl index 54817d4740..6005ea28ef 100644 --- a/templates/repo/diff/comment_form.tmpl +++ b/templates/repo/diff/comment_form.tmpl @@ -27,7 +27,7 @@ - diff --git a/templates/repo/settings/options.tmpl b/templates/repo/settings/options.tmpl index 5a85192a43..376cfe7607 100644 --- a/templates/repo/settings/options.tmpl +++ b/templates/repo/settings/options.tmpl @@ -80,7 +80,7 @@
{{if .Repository.IsArchived}} -
+
{{ctx.Locale.Tr "repo.settings.archive.mirrors_unavailable"}}
{{else}} diff --git a/templates/repo/settings/tags.tmpl b/templates/repo/settings/tags.tmpl index e4fcf2ee6b..31fb59e5e3 100644 --- a/templates/repo/settings/tags.tmpl +++ b/templates/repo/settings/tags.tmpl @@ -1,7 +1,7 @@ {{template "repo/settings/layout_head" (dict "ctxData" . "pageClass" "repository settings edit")}}
{{if .Repository.IsArchived}} -
+
{{ctx.Locale.Tr "repo.settings.archive.tagsettings_unavailable"}}
{{else}} diff --git a/templates/repo/unicode_escape_prompt.tmpl b/templates/repo/unicode_escape_prompt.tmpl index c9f8cd38c1..8bceafa8bb 100644 --- a/templates/repo/unicode_escape_prompt.tmpl +++ b/templates/repo/unicode_escape_prompt.tmpl @@ -1,6 +1,6 @@ {{if .EscapeStatus}} {{if .EscapeStatus.HasInvisible}} -
+
{{ctx.Locale.Tr "repo.invisible_runes_header"}} @@ -11,7 +11,7 @@ {{end}}
{{else if .EscapeStatus.HasAmbiguous}} -
+
{{ctx.Locale.Tr "repo.ambiguous_runes_header"}} diff --git a/templates/repo/view_file.tmpl b/templates/repo/view_file.tmpl index 1f9e0b5028..75f45b293f 100644 --- a/templates/repo/view_file.tmpl +++ b/templates/repo/view_file.tmpl @@ -1,12 +1,12 @@
{{- if .FileError}}
-
{{.FileError}}
+
{{.FileError}}
{{end}} {{- if .FileWarning}}
-
{{.FileWarning}}
+
{{.FileWarning}}
{{end}} diff --git a/templates/repo/wiki/view.tmpl b/templates/repo/wiki/view.tmpl index 9fa05b5b5c..541b1e9b42 100644 --- a/templates/repo/wiki/view.tmpl +++ b/templates/repo/wiki/view.tmpl @@ -79,19 +79,19 @@ {{if .sidebarPresent}} {{end}} -
+
{{if .footerPresent}}
{{if .InRepo}}{{svg "octicon-check"}}{{else}}{{svg "octicon-x"}}{{end}} {{if .Exists}}{{svg "octicon-check"}}{{else}}{{svg "octicon-x"}}{{end}} {{if .Accessible}}{{svg "octicon-check"}}{{else}}{{svg "octicon-x"}}{{end}} + {{ctx.Locale.Tr "repo.settings.lfs_findcommits"}}