Skip to content

Commit a0f3e68

Browse files
committed
Upgrade to stylelint 15.2
We no longer need to turn off style rules that prettier will check, and we also allow prettier to enforce CSS property order, although it's a bit different than our current sort order.
1 parent fcde6dc commit a0f3e68

21 files changed

+170
-118
lines changed

ui/frontend/.stylelintrc.json

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
11
{
22
"extends": [
33
"stylelint-config-standard",
4-
"stylelint-config-css-modules",
5-
"stylelint-config-idiomatic-order",
6-
"stylelint-config-prettier"
4+
"stylelint-config-css-modules"
75
],
86
"rules": {
97
"selector-class-pattern": [

ui/frontend/BuildMenu.module.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
.code {
2-
padding: 0 0.25em;
32
background: #eee;
3+
padding: 0 0.25em;
44
}

ui/frontend/ConfigElement.module.css

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -29,22 +29,22 @@
2929
$border: 1px solid #bbb;
3030

3131
flex: 1;
32-
padding: 0 1em;
32+
cursor: pointer;
3333
border: $border;
3434
border-right-width: 0;
35-
border-bottom-left-radius: var(--header-border-radius);
3635
border-top-left-radius: var(--header-border-radius);
36+
border-bottom-left-radius: var(--header-border-radius);
37+
padding: 0 1em;
3738
color: #777;
38-
cursor: pointer;
39-
font-size: 11px;
4039
font-weight: 600;
40+
font-size: 11px;
4141
text-align: center;
4242
text-transform: uppercase;
4343

4444
& ~ label {
45-
border-radius: 0 var(--header-border-radius) var(--header-border-radius) 0;
46-
border-right-width: 1px;
4745
border-left: $border;
46+
border-right-width: 1px;
47+
border-radius: 0 var(--header-border-radius) var(--header-border-radius) 0;
4848
}
4949

5050
&:hover {

ui/frontend/HeaderButton.module.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
.container {
22
display: flex;
3-
height: 3em;
43
align-items: center;
54
padding: 0 1.25em;
5+
height: 3em;
66
font-weight: 600;
77
text-decoration: none;
88
text-transform: uppercase;

ui/frontend/Help.module.css

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
.container {
2-
max-width: 800px;
3-
padding: 1em;
42
margin: 1em auto;
53
background-color: #fff;
4+
padding: 1em;
5+
max-width: 800px;
66
line-height: 1.5;
77
}
88

99
.code {
10-
padding: 0 0.25em;
1110
background: #eee;
11+
padding: 0 0.25em;
1212
}
1313

1414
.logo {

ui/frontend/HelpExample.module.css

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,16 +6,16 @@
66
position: absolute;
77
top: 0;
88
right: 0;
9-
border: none;
10-
background: rgb(255 255 255 / 80%);
11-
border-bottom-left-radius: 0.5em;
12-
cursor: pointer;
9+
visibility: hidden;
1310
opacity: 0;
1411
transition: all 0.5s;
15-
visibility: hidden;
12+
cursor: pointer;
13+
border: none;
14+
border-bottom-left-radius: 0.5em;
15+
background: rgb(255 255 255 / 80%);
1616
}
1717

1818
.container:hover .loadExample {
19-
opacity: 1;
2019
visibility: visible;
20+
opacity: 1;
2121
}

ui/frontend/Icon.module.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
.icon {
2-
display: block;
32
fill: currentcolor;
3+
display: block;
44
}

ui/frontend/Loader.module.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,9 @@
99
}
1010

1111
.dot {
12+
opacity: 0;
1213
animation: loader-fade 1s;
1314
animation-iteration-count: infinite;
14-
opacity: 0;
1515

1616
&:nth-child(2) {
1717
animation-delay: 0.2s;

ui/frontend/MenuGroup.module.css

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
.container {
2-
width: 27em;
32
padding: 0.75em 1em 0;
3+
width: 27em;
44
line-height: normal;
55

66
&:last-child {
@@ -9,11 +9,11 @@
99
}
1010

1111
.title {
12-
padding-bottom: 10px;
13-
border-bottom: 1px solid var(--header-main-border);
1412
margin: 0;
15-
font-size: 11px;
13+
border-bottom: 1px solid var(--header-main-border);
14+
padding-bottom: 10px;
1615
font-weight: 700;
16+
font-size: 11px;
1717
text-transform: uppercase;
1818
}
1919

ui/frontend/Notifications.module.css

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,15 +3,15 @@ $space: 0.25em;
33

44
.container {
55
position: absolute;
6-
z-index: 10;
76
right: $buffer;
87
bottom: $buffer;
98
left: $buffer;
10-
max-width: 50em;
11-
border: 2px solid #428bca;
9+
z-index: 10;
1210
margin-right: auto;
1311
margin-left: auto;
12+
border: 2px solid #428bca;
1413
background: white;
14+
max-width: 50em;
1515
}
1616

1717
.notification {
@@ -24,7 +24,7 @@ $space: 0.25em;
2424

2525
.close {
2626
composes: -buttonReset from './shared.module.css';
27-
padding: $space;
28-
background: #e1e1db;
2927
cursor: pointer;
28+
background: #e1e1db;
29+
padding: $space;
3030
}

ui/frontend/Output.module.css

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,9 @@ $background-tab: #fcfcfc; /* desaturate($current-tab, 100%); */
33

44
.container {
55
display: flex;
6+
flex-direction: column;
67
width: 100%;
78
height: 100%;
8-
flex-direction: column;
99
}
1010

1111
.tabs {
@@ -14,10 +14,10 @@ $background-tab: #fcfcfc; /* desaturate($current-tab, 100%); */
1414

1515
.tab {
1616
flex: 1 1 auto;
17+
cursor: pointer;
1718
border: var(--border);
1819
border-right: none;
1920
background-color: $background-tab;
20-
cursor: pointer;
2121
line-height: 1.5em;
2222

2323
&:last-of-type {
@@ -27,9 +27,9 @@ $background-tab: #fcfcfc; /* desaturate($current-tab, 100%); */
2727

2828
.tabSelected {
2929
composes: tab;
30+
cursor: default;
3031
border-bottom: none;
3132
background-color: $current-tab;
32-
cursor: default;
3333

3434
&:focus {
3535
outline: none;
@@ -42,10 +42,10 @@ $background-tab: #fcfcfc; /* desaturate($current-tab, 100%); */
4242
}
4343

4444
.body {
45-
overflow: scroll;
46-
height: 100%;
47-
padding: 0.5em;
4845
border: var(--border);
4946
border-top: none;
5047
background-color: $current-tab;
48+
padding: 0.5em;
49+
height: 100%;
50+
overflow: scroll;
5151
}

ui/frontend/Output/Gist.module.css

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,29 +6,29 @@ $copied-duration: 1s ease-in-out;
66

77
.button {
88
composes: -buttonReset from '../shared.module.css';
9-
margin: 0 0.25em 0 0.5em;
10-
cursor: pointer;
119
transition: color $copied-duration;
10+
cursor: pointer;
11+
margin: 0 0.25em 0 0.5em;
1212
}
1313

1414
.text {
15+
visibility: hidden;
1516
opacity: 0;
1617
transition: visibility $copied-duration, opacity $copied-duration, color $copied-duration;
17-
visibility: hidden;
1818
}
1919

2020
.active {
2121
composes: container;
2222

2323
& .button {
24-
color: green;
2524
transition: color 0s;
25+
color: green;
2626
}
2727

2828
& .text {
29-
color: green;
29+
visibility: visible;
3030
opacity: 1;
3131
transition: visibility 0s, opacity 0s, color 0s;
32-
visibility: visible;
32+
color: green;
3333
}
3434
}

ui/frontend/Output/Header.module.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@
66
&::before,
77
&::after {
88
flex: 1 1 auto;
9-
border-top: var(--border);
109
margin: auto;
10+
border-top: var(--border);
1111
content: '';
1212
}
1313

ui/frontend/Playground.module.css

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
.container {
22
display: flex;
3-
height: 100vh;
43
flex-direction: column;
54
padding-bottom: 1em;
5+
height: 100vh;
66
}
77

88
.-resizeableArea {
@@ -32,8 +32,8 @@
3232

3333
.-gutter {
3434
display: flex;
35-
align-items: center;
3635
justify-content: center;
36+
align-items: center;
3737
}
3838

3939
.splitRowsGutter {
@@ -42,8 +42,8 @@
4242
}
4343

4444
.splitRowsGutterHandle {
45-
pointer-events: none;
4645
transform: rotate(90deg);
46+
pointer-events: none;
4747
}
4848

4949
.splitColumnsGutter {

ui/frontend/PopButton.module.css

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,12 @@ $arrow-size: 10px;
44
$vertical-border-color: #cacaca;
55

66
.container {
7-
z-index: 10;
8-
97
/* Prevents the popper from shifting when adding it to the DOM
108
* triggers showing the scrollbars.
119
* https://github.com/FezVrasta/popper.js/issues/457#issuecomment-367692177
1210
*/
1311
top: 0;
12+
z-index: 10;
1413
font-size: 12px;
1514

1615
& button:enabled {
@@ -23,18 +22,18 @@ $vertical-border-color: #cacaca;
2322
}
2423

2524
.container[data-popper-placement^='bottom'] .arrow {
25+
margin-top: 0;
2626
border-top-width: 0;
2727
border-bottom-color: $bg-color;
28-
margin-top: 0;
2928
}
3029

3130
.content {
32-
border-radius: var(--header-border-radius);
31+
margin: $arrow-size;
32+
box-shadow: 0 1px 4px -2px rgb(0 0 0 / 60%), inset 0 1px 0 white;
3333
border-right: 1px solid $vertical-border-color;
3434
border-bottom: 1px solid var(--header-accent-border);
3535
border-left: 1px solid $vertical-border-color;
36-
margin: $arrow-size;
36+
border-radius: var(--header-border-radius);
3737
background: $bg-color;
38-
box-shadow: 0 1px 4px -2px rgb(0 0 0 / 60%), inset 0 1px 0 white;
3938
color: $fg-color;
4039
}

ui/frontend/SegmentedButton.module.css

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@ $bg-dark: #f9f9f9;
44
.container {
55
display: flex;
66
align-items: center;
7-
border-radius: var(--header-border-radius);
87
box-shadow: 0 2px 4px -2px rgb(0 0 0 / 40%), inset 0 1px 0 white;
8+
border-radius: var(--header-border-radius);
99
}
1010

1111
.button {
@@ -16,13 +16,13 @@ $bg-dark: #f9f9f9;
1616
color: #444;
1717

1818
&:first-child {
19-
border-bottom-left-radius: var(--header-border-radius);
2019
border-top-left-radius: var(--header-border-radius);
20+
border-bottom-left-radius: var(--header-border-radius);
2121
}
2222

2323
&:last-child {
24-
border-bottom-right-radius: var(--header-border-radius);
2524
border-top-right-radius: var(--header-border-radius);
25+
border-bottom-right-radius: var(--header-border-radius);
2626
}
2727

2828
&:not(:first-child) {
@@ -39,10 +39,10 @@ $bg-dark: #f9f9f9;
3939
}
4040

4141
&:active {
42+
box-shadow: inset 0 1px 1px rgb(0 0 0 / 20%);
4243
border-top-color: #bababa;
4344
border-bottom-color: #d6d6d6;
4445
background: linear-gradient($bg-dark, #ededed);
45-
box-shadow: inset 0 1px 1px rgb(0 0 0 / 20%);
4646
}
4747
}
4848

ui/frontend/SelectableMenuItem.module.css

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,9 +26,9 @@
2626
}
2727

2828
.checkmark {
29-
margin-right: 0.5em;
3029
opacity: 0;
3130
transition: opacity 0.15s ease-in-out;
31+
margin-right: 0.5em;
3232
}
3333

3434
.selected .checkmark,
@@ -37,6 +37,6 @@
3737
}
3838

3939
.container:hover .checkmark {
40-
color: var(--header-tint);
4140
opacity: 0.5;
41+
color: var(--header-tint);
4242
}

ui/frontend/index.module.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,8 @@ html {
3232
}
3333

3434
body {
35-
padding: 0 1em;
3635
background-color: #e1e1db;
36+
padding: 0 1em;
3737
font-family: var(--primary-font);
3838
}
3939

0 commit comments

Comments
 (0)