diff --git a/components/common/sidebar/sidebar.css b/components/common/sidebar/sidebar.css index 76de1a7..30775e2 100644 --- a/components/common/sidebar/sidebar.css +++ b/components/common/sidebar/sidebar.css @@ -132,3 +132,15 @@ margin: 16px !important; } } + +/* A count at the right edge of an entry, with the label truncating before it. */ +.theme-sidebar nav a > .theme-counter { + margin-left: auto; +} + +.theme-sidebar nav a > span:not(.theme-counter) { + min-width: 0; + overflow: hidden; + text-overflow: ellipsis; + white-space: nowrap; +} diff --git a/styles/components/issues/issue_overview.ts b/styles/components/issues/issue_overview.ts index ac73aa5..35f814c 100644 --- a/styles/components/issues/issue_overview.ts +++ b/styles/components/issues/issue_overview.ts @@ -3,23 +3,9 @@ import { css, themeVars } from "@lutinglt/gitea-github-theme/core"; // The issue list and the pull request list share one layout. export default css` :is(.github-issues, .github-pull-list) { + /* The heading itself is the shared theme-list-heading component. */ & .list-header-issues { margin: 0 0 16px; - min-height: 32px; - display: flex; - align-items: center; - justify-content: space-between; - } - & .issue-list-title { - display: flex; - align-items: center; - gap: 8px; - } - & .issue-list-title h1 { - font-size: 20px; - line-height: 28px; - font-weight: 600; - margin: 0; } & .issue-list-new { min-height: 32px; diff --git a/styles/pages/dashboard-lists.css b/styles/pages/dashboard-lists.css index 4070501..60dfc13 100644 --- a/styles/pages/dashboard-lists.css +++ b/styles/pages/dashboard-lists.css @@ -20,18 +20,6 @@ padding: 6px 8px; } -/* Counts sit at the right edge of a sidebar entry, as in GitHub's sidebars. */ -:is(.dashboard-issue-list, .github-notifications) .theme-sidebar nav a > .theme-counter { - margin-left: auto; -} - -:is(.dashboard-issue-list, .github-notifications) .theme-sidebar nav a > span:not(.theme-counter) { - min-width: 0; - overflow: hidden; - text-overflow: ellipsis; - white-space: nowrap; -} - /* Milestones: the cards form one bordered list under the Open/Closed bar. */ .github-milestones .milestone-list { margin: 0; @@ -54,26 +42,8 @@ } /* Notifications */ -.github-notifications-header { - display: flex; - align-items: center; - justify-content: space-between; - gap: 8px; - min-height: 32px; - margin: 0 0 16px; -} - -.github-notifications-title { - display: flex; - align-items: center; - gap: 8px; -} - -.github-notifications-title h1 { - margin: 0; - font-size: 20px; - font-weight: 600; - line-height: 28px; +.github-notifications .theme-list-heading { + margin-bottom: 16px; } .github-notifications #notification_table { diff --git a/templates/repo/issue/list.tmpl b/templates/repo/issue/list.tmpl index 10fb2a9..5371394 100644 --- a/templates/repo/issue/list.tmpl +++ b/templates/repo/issue/list.tmpl @@ -14,8 +14,8 @@ {{end}} -
-

{{if eq .ViewType "assigned"}}Assigned to me{{else if eq .ViewType "created_by"}}Created by me{{else if eq .ViewType "mentioned"}}Mentioned{{else if eq .ViewType "review_requested"}}Review requested{{else if .PageIsIssueList}}All issues{{else}}All pull requests{{end}}

+
+

{{if eq .ViewType "assigned"}}Assigned to me{{else if eq .ViewType "created_by"}}Created by me{{else if eq .ViewType "mentioned"}}Mentioned{{else if eq .ViewType "review_requested"}}Review requested{{else if .PageIsIssueList}}All issues{{else}}All pull requests{{end}}

{{if not .Repository.IsArchived}} {{if .PageIsIssueList}} {{ctx.Locale.Tr "repo.issues.new"}} diff --git a/templates/user/dashboard/issues.tmpl b/templates/user/dashboard/issues.tmpl index f46cf03..80b6b20 100644 --- a/templates/user/dashboard/issues.tmpl +++ b/templates/user/dashboard/issues.tmpl @@ -23,8 +23,8 @@
{{template "base/alert" .}} -
-
+
+

{{if eq .ViewType "assigned"}}{{ctx.Locale.Tr "repo.issues.filter_type.assigned_to_you"}}{{else if eq .ViewType "created_by"}}{{ctx.Locale.Tr "repo.issues.filter_type.created_by_you"}}{{else if eq .ViewType "mentioned"}}{{ctx.Locale.Tr "repo.issues.filter_type.mentioning_you"}}{{else if eq .ViewType "review_requested"}}{{ctx.Locale.Tr "repo.issues.filter_type.review_requested"}}{{else if eq .ViewType "reviewed_by"}}{{ctx.Locale.Tr "repo.issues.filter_type.reviewed_by_you"}}{{else}}{{ctx.Locale.Tr "home.issues.in_your_repos"}}{{end}}

diff --git a/templates/user/dashboard/milestones.tmpl b/templates/user/dashboard/milestones.tmpl index 50759d2..24e6e8a 100644 --- a/templates/user/dashboard/milestones.tmpl +++ b/templates/user/dashboard/milestones.tmpl @@ -32,8 +32,8 @@
{{template "base/alert" .}} -
-
+
+

{{ctx.Locale.Tr "repo.milestones"}}

diff --git a/templates/user/notification/notification_div.tmpl b/templates/user/notification/notification_div.tmpl index 293911b..58cd00b 100644 --- a/templates/user/notification/notification_div.tmpl +++ b/templates/user/notification/notification_div.tmpl @@ -14,8 +14,8 @@ {{template "components/common/sidebar/toggle" .}}
-
-
+
+

{{if eq .Status 2}}{{ctx.Locale.Tr "notification.read"}}{{else}}{{ctx.Locale.Tr "notification.unread"}}{{end}}