Skip to content

Commit

Permalink
Fix file path width in repo non-homepage view (#30951) (#30952)
Browse files Browse the repository at this point in the history
Backport #30951 by @silverwind

Fixes: #30940

<img width="1310" alt="Screenshot 2024-05-11 at 20 48 41"
src="https://github.com/go-gitea/gitea/assets/115237/f163dfd4-1299-421f-a99e-cd0c793e0e3d">

Co-authored-by: silverwind <me@silverwind.io>
  • Loading branch information
GiteaBot and silverwind committed May 12, 2024
1 parent bc45588 commit ebe8e63
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
2 changes: 1 addition & 1 deletion templates/repo/home.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@
{{$n := len .TreeNames}}
{{$l := Eval $n "-" 1}}
{{$isHomepage := (eq $n 0)}}
<div class="repo-button-row">
<div class="repo-button-row" data-is-homepage="{{$isHomepage}}">
<div class="repo-button-row-left">
{{template "repo/branch_dropdown" dict "root" . "ContainerClasses" "tw-mr-1"}}
{{if and .CanCompareOrPull .IsViewBranch (not .Repository.IsArchived)}}
Expand Down
4 changes: 4 additions & 0 deletions web_src/css/repo.css
Original file line number Diff line number Diff line change
Expand Up @@ -2256,6 +2256,10 @@ td .commit-summary {
justify-content: flex-end;
}

.repo-button-row[data-is-homepage="false"] .repo-button-row-right {
flex-grow: 0;
}

@media (max-width: 991px) {
.repository:not(.wiki) .repo-button-row {
flex-direction: column;
Expand Down

0 comments on commit ebe8e63

Please sign in to comment.