Skip to content

Commit f154ec8

Browse files
committed
chore: Fix new lint and type errors
1 parent 4bef1aa commit f154ec8

File tree

4 files changed

+5
-6
lines changed

4 files changed

+5
-6
lines changed

src/types.ts

+2-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,8 @@ import type { DEFAULT_SECTION_ORDER } from './utils';
33
declare global {
44
interface HTMLElement {
55
/** `stage1` synthetic click event handler. */
6-
__click?(event: MouseEvent): void;
6+
// eslint-disable-next-line @typescript-eslint/no-invalid-void-type
7+
__click?(event: MouseEvent): void | boolean | Promise<void>;
78
}
89
}
910

test/setup.ts

+1-3
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,7 @@ import { GlobalWindow, type Window } from 'happy-dom';
44
/* eslint-disable no-var, vars-on-top */
55
declare global {
66
/** Real bun console. `console` is mapped to happy-dom's virtual console. */
7-
// biome-ignore lint/style/noVar: define global
87
var console2: Console;
9-
// biome-ignore lint/style/noVar: define global
108
var happyDOM: Window['happyDOM'];
119
}
1210
/* eslint-enable */
@@ -74,7 +72,7 @@ function setupMocks(): void {
7472
},
7573
// @ts-expect-error - partial mock
7674
runtime: {
77-
openOptionsPage: noop,
75+
openOptionsPage: noopAsync,
7876
},
7977
// @ts-expect-error - partial mock
8078
sessions: {

test/unit/newtab.test.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ describe('CSS', () => {
7474
test('does not contain any comments', () => {
7575
expect(css).not.toInclude('/*');
7676
expect(css).not.toInclude('*/');
77-
expect(css).not.toInclude('//');
77+
expect(css).not.toInclude('//'); // inline comments or URL protocol
7878
expect(css).not.toInclude('<!');
7979
});
8080

test/unit/theme.test.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ for (const theme of themeNames) {
6161
test('does not contain any comments', () => {
6262
expect(css).not.toInclude('/*');
6363
expect(css).not.toInclude('*/');
64-
expect(css).not.toInclude('//');
64+
expect(css).not.toInclude('//'); // inline comments or URL protocol
6565
expect(css).not.toInclude('<!');
6666
});
6767

0 commit comments

Comments
 (0)