Skip to content

Commit 3ae9976

Browse files
authored
Enhance stylelint rule config, remove dead CSS (#24472)
Make this stylelint rule match on more properties. The dead CSS relates to the navbar, which currently has classes: ``` ui top secondary stackable main menu following bar light ``` Which means `.following.bar .top.menu` can never match, so remove this dead CSS as well as inactive `z-index` and `left` on it. Commits table striping becomes more visible on dark theme, but I don't think it's worth introducing a new color until #24423 is ready, which would have to remove it again: <img width="668" alt="Screenshot 2023-05-01 at 18 41 49" src="https://user-images.githubusercontent.com/115237/235489873-6b272899-1d78-443a-872c-ee7731c269f9.png"> <img width="680" alt="Screenshot 2023-05-01 at 18 41 41" src="https://user-images.githubusercontent.com/115237/235489878-1b9468af-c74f-48a6-a469-9eba57cfcb4d.png">
1 parent 3362620 commit 3ae9976

File tree

3 files changed

+2
-22
lines changed

3 files changed

+2
-22
lines changed

.stylelintrc.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ rules:
9696
property-no-vendor-prefix: null
9797
rule-empty-line-before: null
9898
rule-selector-property-disallowed-list: null
99-
scale-unlimited/declaration-strict-value: [color, {ignoreValues: /^(inherit|transparent|unset|initial|currentcolor)$/}]
99+
scale-unlimited/declaration-strict-value: [[color, background-color, border-color], {ignoreValues: /^(inherit|transparent|unset|initial|currentcolor|none)$/, ignoreFunctions: false}]
100100
selector-attribute-name-disallowed-list: null
101101
selector-attribute-operator-allowed-list: null
102102
selector-attribute-operator-disallowed-list: null

web_src/css/base.css

Lines changed: 0 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1228,8 +1228,6 @@ img.ui.avatar,
12281228
}
12291229

12301230
.following.bar {
1231-
z-index: 900;
1232-
left: 0;
12331231
margin: 0 !important;
12341232
}
12351233

@@ -1242,24 +1240,6 @@ img.ui.avatar,
12421240
margin-top: 0;
12431241
}
12441242

1245-
.following.bar .top.menu a.item.brand {
1246-
padding-left: 0;
1247-
}
1248-
1249-
.following.bar .top.menu a.item:hover,
1250-
.following.bar .top.menu .dropdown.item:hover,
1251-
.following.bar .top.menu .dropdown.item.active {
1252-
background-color: transparent;
1253-
}
1254-
1255-
.following.bar .top.menu a.item:hover {
1256-
color: rgba(0, 0, 0, 0.45);
1257-
}
1258-
1259-
.following.bar .top.menu .menu {
1260-
z-index: 900;
1261-
}
1262-
12631243
.following.bar .fitted .svg {
12641244
margin-right: 0;
12651245
vertical-align: middle;

web_src/css/repository.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1359,7 +1359,7 @@
13591359
}
13601360

13611361
.repository #commits-table.ui.basic.striped.table tbody tr:nth-child(2n) {
1362-
background-color: rgba(0, 0, 0, 0.02) !important;
1362+
background-color: var(--color-light) !important;
13631363
}
13641364

13651365
.repository #commits-table td.sha .sha.label,

0 commit comments

Comments
 (0)