Skip to content

Commit 236a6fd

Browse files
author
mkrause
committed
Fix all style linting errors + enforce in CI.
1 parent 22dbfe2 commit 236a6fd

File tree

8 files changed

+18
-21
lines changed

8 files changed

+18
-21
lines changed

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,9 +44,9 @@
4444
"storybook:build": "storybook build --docs",
4545
"check:types": "tsc --noEmit",
4646
"lint:style": "stylelint 'src/**/*.scss'",
47-
"lint:script": "biome",
47+
"lint:script": "biome lint",
4848
"lint": "npm run lint:style && npm run lint:script",
49-
"test": "npm run check:types",
49+
"test": "npm run check:types && npm run lint:style",
5050
"test-ui": "vitest --ui",
5151
"coverage": "vitest run --coverage",
5252
"start": "npm run storybook:serve",

package.json.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -63,13 +63,13 @@ const packageConfig = {
6363
// Static analysis
6464
'check:types': 'tsc --noEmit',
6565
'lint:style': `stylelint 'src/**/*.scss'`,
66-
'lint:script': 'biome',
66+
'lint:script': 'biome lint',
6767
'lint': 'npm run lint:style && npm run lint:script',
6868

6969
// Test
7070
// Note: use `vitest run --root=. src/...` to run a single test file
7171
//'test': 'vitest run --root=.', // Need to specify `--root=.` since the vite root is set to `./app`
72-
'test': 'npm run check:types',
72+
'test': 'npm run check:types && npm run lint:style',
7373
'test-ui': 'vitest --ui',
7474
'coverage': 'vitest run --coverage',
7575

src/components/navigations/Stepper/Stepper.module.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515

1616
&.bk-stepper--vertical {
1717
.bk-stepper__item {
18-
&:not(:first-child):not(:first-child) {
18+
&:not(:first-child) {
1919
margin-top: bk.$spacing-9;
2020

2121
.bk-stepper__item__circle {

src/components/overlays/Toast/Toast.module.scss

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,9 @@
66

77
@layer baklava.components {
88
.bk-toast {
9-
width: auto !important; // Override style for .Toastify__toast-container
109
padding: 0 !important; // Override style for .Toastify__toast-container
1110
width: 400px !important; // Override style for .Toastify__toast-container
12-
11+
1312
&:has(.bk-close--dark) {
1413
.bk-toast__body {
1514
margin-right: bk.$spacing-4 !important; // Override style for .Toastify__toast-body

src/components/overlays/Toast/ToastyOverride.scss

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
|* This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0. If a copy of
33
|* the MPL was not distributed with this file, You can obtain one at http://mozilla.org/MPL/2.0/. */
44

5+
/* stylelint-disable selector-class-pattern */
6+
57
@use '../../../styling/defs.scss' as bk;
68

79
// Define styling to override react-toastify's styles, as overriding directly from Toast.module.scss is not possible.

src/components/overlays/Tooltip/Tooltip.module.scss

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@
3939
background: var(--c1);
4040

4141
&::before {
42-
content: "";
42+
content: '';
4343
position: absolute;
4444
z-index: -1;
4545
inset: 0;
@@ -72,16 +72,16 @@
7272
100% min(100%,var(--p) + var(--h)*tan(var(--a)/2)),
7373
calc(100% + var(--h)) var(--p),
7474
100% max(0% ,var(--p) - var(--h)*tan(var(--a)/2)));
75-
border-image: conic-gradient(var(--c1) 0 0) fill 0/
76-
max(0%,var(--p) - var(--h)*tan(var(--a)/2)) 0 max(0%,100% - var(--p) - var(--h)*tan(var(--a)/2)) var(--r)/0 var(--h) 0 0;
75+
border-image: conic-gradient(var(--c1) 0 0) fill 0
76+
/ max(0%,var(--p) - var(--h)*tan(var(--a)/2)) 0 max(0%,100% - var(--p) - var(--h)*tan(var(--a)/2)) var(--r)/0 var(--h) 0 0;
7777

7878
&::before {
7979
clip-path: polygon(100% 0,0 0,0 100%,100% 100%,
8080
calc(100% - var(--b)) min(100% - var(--b),var(--p) + var(--h)*tan(var(--a)/2) - var(--b)*tan(45deg - var(--a)/4)),
8181
calc(100% + var(--h) - var(--b)/sin(var(--a)/2)) var(--p),
8282
calc(100% - var(--b)) max( var(--b),var(--p) - var(--h)*tan(var(--a)/2) + var(--b)*tan(45deg - var(--a)/4)));
83-
border-image: conic-gradient(var(--c2) 0 0) fill 0/
84-
max(var(--b),var(--p) - var(--h)*tan(var(--a)/2)) 0 max(var(--b),100% - var(--p) - var(--h)*tan(var(--a)/2)) var(--r)/0 var(--h) 0 0;
83+
border-image: conic-gradient(var(--c2) 0 0) fill 0
84+
/ max(var(--b),var(--p) - var(--h)*tan(var(--a)/2)) 0 max(var(--b),100% - var(--p) - var(--h)*tan(var(--a)/2)) var(--r)/0 var(--h) 0 0;
8585
}
8686
}
8787
@mixin bk-tooltip-arrow-bottom {
@@ -108,16 +108,16 @@
108108
0 min(100%,var(--p) + var(--h)*tan(var(--a)/2)),
109109
calc(-1*var(--h)) var(--p),
110110
0 max(0% ,var(--p) - var(--h)*tan(var(--a)/2)));
111-
border-image: conic-gradient(var(--c1) 0 0) fill 0/
112-
max(0%,var(--p) - var(--h)*tan(var(--a)/2)) var(--r) max(0%,100% - var(--p) - var(--h)*tan(var(--a)/2)) 0/0 0 0 var(--h);
111+
border-image: conic-gradient(var(--c1) 0 0) fill 0
112+
/ max(0%,var(--p) - var(--h)*tan(var(--a)/2)) var(--r) max(0%,100% - var(--p) - var(--h)*tan(var(--a)/2)) 0/0 0 0 var(--h);
113113

114114
&::before {
115115
clip-path: polygon(0 0,100% 0,100% 100%,0 100%,
116116
var(--b) min(100% - var(--b),var(--p) + var(--h)*tan(var(--a)/2) - var(--b)*tan(45deg - var(--a)/4)),
117117
calc(var(--b)/sin(var(--a)/2) - var(--h)) var(--p),
118118
var(--b) max( var(--b),var(--p) - var(--h)*tan(var(--a)/2) + var(--b)*tan(45deg - var(--a)/4)));
119-
border-image: conic-gradient(var(--c2) 0 0) fill 0/
120-
max(var(--b),var(--p) - var(--h)*tan(var(--a)/2)) var(--r) max(var(--b),100% - var(--p) - var(--h)*tan(var(--a)/2)) 0/0 0 0 var(--h);
119+
border-image: conic-gradient(var(--c2) 0 0) fill 0
120+
/ max(var(--b),var(--p) - var(--h)*tan(var(--a)/2)) var(--r) max(var(--b),100% - var(--p) - var(--h)*tan(var(--a)/2)) 0/0 0 0 var(--h);
121121
}
122122
}
123123

src/layouts/AppLayout/Sidebar/Sidebar.module.scss

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -20,10 +20,6 @@
2020
transition: all 300ms ease-in-out;
2121
transition-property: width, grid-template-columns;
2222

23-
&.-collapsed {
24-
width: var(--bk-sizing-5);
25-
}
26-
2723
.bk-app-layout-sidebar__action-collapse {
2824
margin: var(--bk-sizing-2);
2925
padding: var(--bk-sizing-1) var(--bk-sizing-2);

stylelint.config.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ export default {
1111
'rules': {
1212
// Override `stylelint-config-standard-scss` rules
1313
'scss/load-partial-extension': 'always',
14-
'scss/at-import-partial-extension': 'always',
14+
//'scss/at-import-partial-extension': 'always',
1515
'comment-empty-line-before': null,
1616
'comment-whitespace-inside': null,
1717
'scss/comment-no-empty': null,

0 commit comments

Comments
 (0)