Skip to content

Commit 253a00a

Browse files
authored
Remove conflicting CSS rules on notifications, improve notifications table (#23565)
Dropdowns on `/notifications/subscriptions` before and after: <img width="157" alt="Screenshot 2023-03-18 at 20 37 12" src="https://user-images.githubusercontent.com/115237/226133906-e4ad6a0a-de24-4324-8e1d-94081d23fe85.png"> <img width="152" alt="Screenshot 2023-03-18 at 20 41 29" src="https://user-images.githubusercontent.com/115237/226134038-c3946c32-a424-4b92-ad15-890e1036cafe.png"> These selectors are meant to target the notification list which I improved: <img width="1145" alt="Screenshot 2023-03-19 at 01 52 11" src="https://user-images.githubusercontent.com/115237/226147907-1c35736a-4bc9-4698-9813-21a20a1d2106.png"> <img width="1148" alt="Screenshot 2023-03-19 at 01 54 17" src="https://user-images.githubusercontent.com/115237/226147920-626dbd84-11d3-48db-a177-6d808e3212c0.png">
1 parent ad6444f commit 253a00a

File tree

2 files changed

+17
-29
lines changed

2 files changed

+17
-29
lines changed

templates/user/notification/notification_div.tmpl

+8-8
Original file line numberDiff line numberDiff line change
@@ -35,26 +35,26 @@
3535
{{$issue := .Issue}}
3636
{{$repo := .Repository}}
3737
<tr id="notification_{{.ID}}">
38-
<td class="collapsing" data-href="{{.Link}}">
38+
<td class="collapsing gt-pl-4" data-href="{{.Link}}">
3939
{{if eq .Status 3}}
40-
<span class="blue">{{svg "octicon-pin"}}</span>
40+
{{svg "octicon-pin" 16 "text blue"}}
4141
{{else if not $issue}}
42-
<span class="gray">{{svg "octicon-repo"}}</span>
42+
{{svg "octicon-repo" 16 "text grey"}}
4343
{{else if $issue.IsPull}}
4444
{{if $issue.IsClosed}}
4545
{{if $issue.GetPullRequest.HasMerged}}
46-
<span class="purple">{{svg "octicon-git-merge"}}</span>
46+
{{svg "octicon-git-merge" 16 "text purple"}}
4747
{{else}}
48-
<span class="red">{{svg "octicon-git-pull-request"}}</span>
48+
{{svg "octicon-git-pull-request" 16 "text red"}}
4949
{{end}}
5050
{{else}}
51-
<span class="green">{{svg "octicon-git-pull-request"}}</span>
51+
{{svg "octicon-git-pull-request" 16 "text green"}}
5252
{{end}}
5353
{{else}}
5454
{{if $issue.IsClosed}}
55-
<span class="red">{{svg "octicon-issue-closed"}}</span>
55+
{{svg "octicon-issue-closed" 16 "text red"}}
5656
{{else}}
57-
<span class="green">{{svg "octicon-issue-opened"}}</span>
57+
{{svg "octicon-issue-opened" 16 "text green"}}
5858
{{end}}
5959
{{end}}
6060
</td>

web_src/css/user.css

+9-21
Original file line numberDiff line numberDiff line change
@@ -90,27 +90,6 @@
9090
padding: 8px 15px;
9191
}
9292

93-
.user.notification .svg {
94-
float: left;
95-
font-size: 2em;
96-
}
97-
98-
.user.notification .svg.green {
99-
color: var(--color-green);
100-
}
101-
102-
.user.notification .svg.red {
103-
color: var(--color-red);
104-
}
105-
106-
.user.notification .svg.purple {
107-
color: var(--color-purple);
108-
}
109-
110-
.user.notification .svg.blue {
111-
color: var(--color-blue);
112-
}
113-
11493
.user.notification .content {
11594
float: left;
11695
margin-left: 7px;
@@ -175,4 +154,13 @@
175154

176155
#notification_div .tab.segment {
177156
overflow-x: auto;
157+
padding: 0;
158+
}
159+
160+
#notification_div .menu .active.item {
161+
background: var(--color-box-body);
162+
}
163+
164+
#notification_table {
165+
border: none;
178166
}

0 commit comments

Comments
 (0)