Skip to content

Commit e7c0265

Browse files
zeripathSysoev, Vladimir
authored and
Sysoev, Vladimir
committed
Refix notification bell placement (go-gitea#20251)
The use of `m-4 text black` for the notification bell results in this icon being shifted upwards. Instead we should use the `item` class but adjust `not-mobile` and `mobile-only` to make their `display: none` settings `!important`. (As an aside: This is probably one of the only times we should use `!important` in our less files and the rest should be avoided or removed.) Ref go-gitea#20069 Revert go-gitea#20236 Signed-off-by: Andrew Thornton <art27@cantab.net>
1 parent 5b60856 commit e7c0265

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

Diff for: templates/base/head_navbar.tmpl

+1-1
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,7 @@
114114
</div>
115115
</div>
116116

117-
<a href="{{AppSubUrl}}/notifications" class="m-4 text black tooltip not-mobile" data-content='{{.locale.Tr "notifications"}}'>
117+
<a href="{{AppSubUrl}}/notifications" class="item tooltip not-mobile" data-content='{{.locale.Tr "notifications"}}'>
118118
<span class="text">
119119
<span class="fitted">{{svg "octicon-bell"}}</span>
120120
<span class="ui red label {{if not $notificationUnreadCount}}hidden{{end}} notification_count">

Diff for: web_src/less/_base.less

+2-2
Original file line numberDiff line numberDiff line change
@@ -1329,7 +1329,7 @@ footer {
13291329
@media @mediaMdAndUp {
13301330
.mobile-only,
13311331
.ui.button.mobile-only {
1332-
display: none;
1332+
display: none !important;
13331333
}
13341334

13351335
// has the same behaviour of sr-only, hiding the content for
@@ -1341,7 +1341,7 @@ footer {
13411341

13421342
@media @mediaSm {
13431343
.not-mobile {
1344-
display: none;
1344+
display: none !important;
13451345
}
13461346
}
13471347

0 commit comments

Comments
 (0)