Skip to content

Commit 1db5f7d

Browse files
committed
Fixed ESLintCompatiblePostCSSNode for Container subclasses
1 parent 5aa2f2b commit 1db5f7d

File tree

1 file changed

+13
-12
lines changed

1 file changed

+13
-12
lines changed

src/ast/style.ts

Lines changed: 13 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -4,16 +4,17 @@ import type { BaseNode } from "./base";
44
export type ESLintCompatiblePostCSSNode<PostCSSNode extends Node = Node> =
55
BaseNode &
66
(PostCSSNode extends Container<infer Child>
7-
? Omit<
8-
Container<ESLintCompatiblePostCSSNode<Child>>,
9-
"parent" | "walk"
10-
> & {
11-
parent: BaseNode;
12-
walk(
13-
callback: (
14-
node: ESLintCompatiblePostCSSNode<Child>,
15-
index: number
16-
) => false | void
17-
): false | undefined;
18-
}
7+
? Omit<PostCSSNode, "parent" | "type"> &
8+
Omit<
9+
Container<ESLintCompatiblePostCSSNode<Child>>,
10+
"parent" | "walk"
11+
> & {
12+
parent: BaseNode;
13+
walk(
14+
callback: (
15+
node: ESLintCompatiblePostCSSNode<Child>,
16+
index: number
17+
) => false | void
18+
): false | undefined;
19+
}
1920
: PostCSSNode);

0 commit comments

Comments
 (0)