From 7299b2def4131ca62df2beac0b6cc39288877302 Mon Sep 17 00:00:00 2001 From: 0ko <0ko@noreply.codeberg.org> Date: Fri, 28 Jun 2024 13:11:16 +0500 Subject: [PATCH] chore: rename class issue-title-buttons to button-row --- templates/org/header.tmpl | 2 +- templates/repo/issue/milestone_issues.tmpl | 2 +- templates/repo/issue/milestones.tmpl | 2 +- templates/repo/issue/view_title.tmpl | 4 ++-- templates/user/notification/notification_div.tmpl | 2 +- tests/integration/pull_create_test.go | 2 +- web_src/css/base.css | 4 ++-- web_src/css/repo.css | 4 ++-- 8 files changed, 11 insertions(+), 11 deletions(-) diff --git a/templates/org/header.tmpl b/templates/org/header.tmpl index 1209b29401..494dedf67a 100644 --- a/templates/org/header.tmpl +++ b/templates/org/header.tmpl @@ -9,7 +9,7 @@ {{if .Org.Visibility.IsPrivate}}{{ctx.Locale.Tr "org.settings.visibility.private_shortname"}}{{end}} - + {{if .EnableFeed}} {{svg "octicon-rss" 24}} diff --git a/templates/repo/issue/milestone_issues.tmpl b/templates/repo/issue/milestone_issues.tmpl index ed2f1ae0cd..e5dc8cb605 100644 --- a/templates/repo/issue/milestone_issues.tmpl +++ b/templates/repo/issue/milestone_issues.tmpl @@ -6,7 +6,7 @@

{{.Milestone.Name}}

{{if not .Repository.IsArchived}} -
+
{{if or .CanWriteIssues .CanWritePulls}} {{if .Milestone.IsClosed}} {{ctx.Locale.Tr "repo.milestones.open"}} diff --git a/templates/repo/issue/milestones.tmpl b/templates/repo/issue/milestones.tmpl index 2a5cf84b35..63a6f6b26a 100644 --- a/templates/repo/issue/milestones.tmpl +++ b/templates/repo/issue/milestones.tmpl @@ -8,7 +8,7 @@ {{template "repo/issue/navbar" .}} {{template "repo/issue/search" .}} {{if and (or .CanWriteIssues .CanWritePulls) (not .Repository.IsArchived)}} -
+ {{end}} diff --git a/templates/repo/issue/view_title.tmpl b/templates/repo/issue/view_title.tmpl index d4a69be0aa..546c765d14 100644 --- a/templates/repo/issue/view_title.tmpl +++ b/templates/repo/issue/view_title.tmpl @@ -10,7 +10,7 @@ {{RenderIssueTitle $.Context .Issue.Title ($.Repository.ComposeMetas ctx) | RenderCodeBlock}} #{{.Issue.Index}} -
+
{{if $canEditIssueTitle}} {{end}} @@ -24,7 +24,7 @@
-
+
-
+
{{ctx.Locale.Tr "notification.subscriptions"}} diff --git a/tests/integration/pull_create_test.go b/tests/integration/pull_create_test.go index 2eb7cd7dcd..fd98a3f05c 100644 --- a/tests/integration/pull_create_test.go +++ b/tests/integration/pull_create_test.go @@ -213,7 +213,7 @@ func TestPullCreate_TitleEscape(t *testing.T) { req := NewRequest(t, "GET", url) resp = session.MakeRequest(t, req, http.StatusOK) htmlDoc := NewHTMLParser(t, resp.Body) - editTestTitleURL, exists := htmlDoc.doc.Find(".top-right-buttons button[data-update-url]").First().Attr("data-update-url") + editTestTitleURL, exists := htmlDoc.doc.Find(".button-row button[data-update-url]").First().Attr("data-update-url") assert.True(t, exists, "The template has changed") req = NewRequestWithValues(t, "POST", editTestTitleURL, map[string]string{ diff --git a/web_src/css/base.css b/web_src/css/base.css index fc23587119..0fddf97c63 100644 --- a/web_src/css/base.css +++ b/web_src/css/base.css @@ -246,11 +246,11 @@ h1.error-code { user-select: none; } -.top-right-buttons { +.button-row { gap: 0.5rem; } -.top-right-buttons .ui.button { +.button-row .ui.button { margin-right: 0; } diff --git a/web_src/css/repo.css b/web_src/css/repo.css index f52804ff23..e4f8cce8b4 100644 --- a/web_src/css/repo.css +++ b/web_src/css/repo.css @@ -601,7 +601,7 @@ td .commit-summary { align-items: center; } -.repository.view.issue .top-right-buttons { +.repository.view.issue .button-row { display: flex; } @@ -609,7 +609,7 @@ td .commit-summary { .repository.view.issue .issue-title { flex-direction: column; } - .repository.view.issue .top-right-buttons { + .repository.view.issue .button-row { width: 100%; margin-top: .5rem; justify-content: space-between;