Skip to content

Commit

Permalink
Fix dropdown menu header and mobile view (#33108)
Browse files Browse the repository at this point in the history
  • Loading branch information
wxiaoguang authored Jan 5, 2025
1 parent 4237736 commit cf60734
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 6 deletions.
4 changes: 2 additions & 2 deletions templates/base/head_navbar.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@
<span class="not-mobile">{{svg "octicon-triangle-down"}}</span>
</span>
<div class="menu user-menu">
<div class="ui header">
<div class="header">
{{ctx.Locale.Tr "signed_in_as"}} <strong>{{.SignedUser.Name}}</strong>
</div>

Expand Down Expand Up @@ -130,7 +130,7 @@
{{/* do not localize it, here it needs the fixed length (width) to make UI comfortable */}}
{{if .IsAdmin}}<span class="navbar-profile-admin">admin</span>{{end}}
<div class="menu user-menu">
<div class="ui header">
<div class="header">
{{ctx.Locale.Tr "signed_in_as"}} <strong>{{.SignedUser.Name}}</strong>
</div>

Expand Down
2 changes: 1 addition & 1 deletion templates/repo/commit_page.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
{{ctx.Locale.Tr "repo.commit.operations"}}
{{svg "octicon-triangle-down" 14 "dropdown icon"}}
<div class="menu">
<div class="ui header">{{ctx.Locale.Tr "repo.commit.operations"}}</div>
<div class="header">{{ctx.Locale.Tr "repo.commit.operations"}}</div>
<div class="divider"></div>
<div class="item show-create-branch-modal"
data-content="{{ctx.Locale.Tr "repo.branch.new_branch_from" (.CommitID)}}" {{/* used by the form */}}
Expand Down
4 changes: 2 additions & 2 deletions templates/user/dashboard/navbar.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
{{svg "octicon-triangle-down" 14 "dropdown icon tw-ml-1"}}
</span>
<div class="context user overflow menu">
<div class="ui header">
<div class="header">
{{ctx.Locale.Tr "home.switch_dashboard_context"}}
</div>
<div class="scrolling menu items">
Expand Down Expand Up @@ -56,7 +56,7 @@
</span>
{{svg "octicon-triangle-down" 14 "dropdown icon"}}
<div class="context user overflow menu">
<div class="ui header">
<div class="header">
{{ctx.Locale.Tr "home.filter_by_team_repositories"}}
</div>
<div class="scrolling menu items">
Expand Down
3 changes: 2 additions & 1 deletion web_src/css/modules/navbar.css
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,8 @@
align-items: stretch;
}
/* hide all items */
#navbar .item {
#navbar .navbar-left > .item,
#navbar .navbar-right > .item {
display: none;
}
#navbar #navbar-logo {
Expand Down

0 comments on commit cf60734

Please sign in to comment.