Skip to content

Commit ee0801c

Browse files
committed
Enforce stylelint in CI and fix all existing violations
Adds stylelint and Prettier format checks to CI. Fixes 74 pre-existing stylelint violations: CSS property ordering, named colors to hex values, hex shorthand, and redundant shorthand values. Aligns ESLint comma-dangle rule with Prettier. Runs lint as part of local yarn build. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent 69a9aaf commit ee0801c

25 files changed

Lines changed: 75 additions & 78 deletions

File tree

.github/workflows/ci.yml

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -58,14 +58,6 @@ jobs:
5858
- name: Build
5959
run: yarn build
6060

61-
- name: Verify generated CSS type declarations are up to date
62-
run: |
63-
if [ -n "$(git diff --name-only -- '*.css.d.ts')" ]; then
64-
echo "::error::Generated .css.d.ts files are out of date. Run 'yarn build' and commit the changes."
65-
git diff --stat -- '*.css.d.ts'
66-
exit 1
67-
fi
68-
6961
- name: Upload frontend build
7062
uses: actions/upload-artifact@v7
7163
with:
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
.blocklist {
22
display: flex;
3-
flex-direction: column;
43
flex: 1 0 1px;
4+
flex-direction: column;
55
}
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
.history {
22
display: flex;
3-
flex-direction: column;
43
flex: 1 0 1px;
4+
flex-direction: column;
55
}
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
.queue {
22
display: flex;
3-
flex-direction: column;
43
flex: 1 0 1px;
4+
flex-direction: column;
55
}

frontend/src/AddGame/AddNewGame/AddNewGameModalContent.css

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,10 @@
99

1010
.poster {
1111
flex: 0 0 170px;
12-
width: 170px;
12+
overflow: hidden;
1313
margin-right: 20px;
14+
width: 170px;
1415
height: 250px;
15-
overflow: hidden;
1616
}
1717

1818
.poster img {

frontend/src/AddGame/ImportGame/Import/SelectGame/ImportGameSelectGame.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,6 @@
7171
}
7272

7373
.results {
74-
max-height: 200px;
7574
overflow-y: auto;
75+
max-height: 200px;
7676
}

frontend/src/Components/Label.css

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -23,10 +23,10 @@
2323
&:global(.colorImpaired) {
2424
background: repeating-linear-gradient(
2525
90deg,
26-
color-mix(in srgb, var(--dangerColor) 95%, black),
27-
color-mix(in srgb, var(--dangerColor) 95%, black) 5px,
28-
color-mix(in srgb, var(--dangerColor) 85%, black) 5px,
29-
color-mix(in srgb, var(--dangerColor) 85%, black) 10px
26+
color-mix(in srgb, var(--dangerColor) 95%, #000),
27+
color-mix(in srgb, var(--dangerColor) 95%, #000) 5px,
28+
color-mix(in srgb, var(--dangerColor) 85%, #000) 5px,
29+
color-mix(in srgb, var(--dangerColor) 85%, #000) 10px
3030
);
3131
}
3232
}
@@ -102,8 +102,8 @@
102102
45deg,
103103
var(--warningColor),
104104
var(--warningColor) 5px,
105-
color-mix(in srgb, var(--warningColor) 85%, white) 5px,
106-
color-mix(in srgb, var(--warningColor) 85%, white) 10px
105+
color-mix(in srgb, var(--warningColor) 85%, #fff) 5px,
106+
color-mix(in srgb, var(--warningColor) 85%, #fff) 10px
107107
);
108108
}
109109
}

frontend/src/Components/ProgressBar.css

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,8 +37,8 @@
3737
90deg,
3838
#e44c4c,
3939
#e44c4c 5px,
40-
#cc4444 5px,
41-
#cc4444 10px
40+
#c44 5px,
41+
#c44 10px
4242
);
4343
}
4444
}

frontend/src/Components/Tooltip/Popover.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,8 @@
88
.body {
99
overflow-x: hidden;
1010
overflow-y: auto;
11-
max-width: 400px;
1211
padding: 10px;
12+
max-width: 400px;
1313
background-color: var(--popoverBodyBackgroundColor);
1414
word-wrap: break-word;
1515
}

frontend/src/Game/Details/Dlc/DlcList.css

Lines changed: 26 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -12,13 +12,15 @@
1212
display: flex;
1313
align-items: center;
1414
gap: 4px;
15+
1516
padding: 8px 15px 0;
1617
}
1718

1819
.dlcGrid {
1920
display: grid;
2021
grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
2122
gap: 15px;
23+
2224
padding: 15px;
2325
}
2426

@@ -29,9 +31,9 @@
2931
border: 1px solid var(--borderColor);
3032
border-radius: 4px;
3133
background-color: var(--inputBackgroundColor);
32-
transition: background-color 0.2s ease;
3334
color: var(--textColor);
3435
text-decoration: none;
36+
transition: background-color 0.2s ease;
3537

3638
&:hover {
3739
background-color: var(--gameBackgroundColor);
@@ -45,26 +47,26 @@
4547

4648
.dlcPoster {
4749
flex-shrink: 0;
50+
overflow: hidden;
51+
margin-right: 12px;
4852
width: 60px;
4953
height: 80px;
50-
margin-right: 12px;
5154
border-radius: 3px;
52-
overflow: hidden;
5355
}
5456

5557
.dlcInfo {
5658
flex: 1;
57-
min-width: 0;
5859
overflow: hidden;
60+
min-width: 0;
5961
}
6062

6163
.dlcTitle {
62-
margin: 0 0 4px 0;
63-
font-size: 14px;
64-
font-weight: 500;
65-
white-space: nowrap;
6664
overflow: hidden;
65+
margin: 0 0 4px;
6766
text-overflow: ellipsis;
67+
white-space: nowrap;
68+
font-weight: 500;
69+
font-size: 14px;
6870
}
6971

7072
.dlcTitleLink {
@@ -77,14 +79,15 @@
7779
}
7880

7981
.dlcType {
80-
font-size: 12px;
8182
color: var(--textColorMuted);
83+
font-size: 12px;
8284
}
8385

8486
.dlcStatus {
8587
display: flex;
8688
align-items: center;
8789
gap: 8px;
90+
8891
margin-top: 6px;
8992
}
9093

@@ -107,17 +110,17 @@
107110
.parentGameInfo {
108111
display: flex;
109112
align-items: center;
110-
padding: 12px 15px;
111113
margin-bottom: 10px;
112-
background-color: var(--gameBackgroundColor);
114+
padding: 12px 15px;
113115
border: 1px solid var(--borderColor);
114116
border-radius: 4px;
117+
background-color: var(--gameBackgroundColor);
115118
}
116119

117120
.parentLabel {
118-
font-weight: 500;
119121
margin-right: 8px;
120122
color: var(--textColorMuted);
123+
font-weight: 500;
121124
}
122125

123126
.parentLink {
@@ -132,23 +135,23 @@
132135

133136
.dlcBadge {
134137
display: inline-block;
135-
padding: 2px 8px;
136138
margin-left: 10px;
137-
font-size: 11px;
138-
font-weight: 600;
139-
text-transform: uppercase;
140-
background-color: var(--purple);
141-
color: white;
139+
padding: 2px 8px;
142140
border-radius: 3px;
141+
background-color: var(--purple);
142+
color: #fff;
143+
text-transform: uppercase;
144+
font-weight: 600;
145+
font-size: 11px;
143146
}
144147

145148
.gameTypeBadge {
146149
display: inline-block;
147150
padding: 2px 8px;
148-
font-size: 11px;
149-
font-weight: 600;
150-
text-transform: uppercase;
151-
background-color: var(--purple);
152-
color: white;
153151
border-radius: 3px;
152+
background-color: var(--purple);
153+
color: #fff;
154+
text-transform: uppercase;
155+
font-weight: 600;
156+
font-size: 11px;
154157
}

0 commit comments

Comments
 (0)