-
-
Notifications
You must be signed in to change notification settings - Fork 2k
Expand file tree
/
Copy pathast.pyi
More file actions
160 lines (138 loc) · 4.61 KB
/
ast.pyi
File metadata and controls
160 lines (138 loc) · 4.61 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
from typing import Literal
class Node:
source_line: int
source_column: int
type: str
def __init__(self, source_line: int, source_column: int) -> None: ...
def serialize(self) -> str: ...
class ParseError(Node):
type: Literal["error"]
kind: str
message: str
repr_format: str
def __init__(self, line: int, column: int, kind: str, message: str) -> None: ...
class Comment(Node):
type: Literal["comment"]
value: str
repr_format: str
def __init__(self, line: int, column: int, value: str) -> None: ...
class WhitespaceToken(Node):
type: Literal["whitespace"]
value: str
repr_format: str
def __init__(self, line: int, column: int, value: str) -> None: ...
class LiteralToken(Node):
type: Literal["literal"]
value: str
repr_format: str
def __init__(self, line: int, column: int, value: str) -> None: ...
def __eq__(self, other: object) -> bool: ...
def __ne__(self, other: object) -> bool: ...
class IdentToken(Node):
type: Literal["ident"]
value: str
lower_value: str
repr_format: str
def __init__(self, line: int, column: int, value: str) -> None: ...
class AtKeywordToken(Node):
type: Literal["at-keyword"]
value: str
lower_value: str
repr_format: str
def __init__(self, line: int, column: int, value: str) -> None: ...
class HashToken(Node):
type: Literal["hash"]
value: str
is_identifier: bool
repr_format: str
def __init__(self, line: int, column: int, value: str, is_identifier: bool) -> None: ...
class StringToken(Node):
type: Literal["string"]
value: str
representation: str
repr_format: str
def __init__(self, line: int, column: int, value: str, representation: str) -> None: ...
class URLToken(Node):
type: Literal["url"]
value: str
representation: str
repr_format: str
def __init__(self, line: int, column: int, value: str, representation: str) -> None: ...
class UnicodeRangeToken(Node):
type: Literal["unicode-range"]
start: int
end: int
repr_format: str
def __init__(self, line: int, column: int, start: int, end: int) -> None: ...
class NumberToken(Node):
type: Literal["number"]
value: float
int_value: int | None
is_integer: bool
representation: str
repr_format: str
def __init__(self, line: int, column: int, value: float, int_value: int | None, representation: str) -> None: ...
class PercentageToken(Node):
type: Literal["percentage"]
value: float
int_value: int | None
is_integer: bool
representation: str
repr_format: str
def __init__(self, line: int, column: int, value: float, int_value: int | None, representation: str) -> None: ...
class DimensionToken(Node):
type: Literal["dimension"]
value: float
int_value: int | None
is_integer: bool
representation: str
unit: str
lower_unit: str
repr_format: str
def __init__(self, line: int, column: int, value: float, int_value: int | None, representation: str, unit: str) -> None: ...
class ParenthesesBlock(Node):
type: Literal["() block"]
content: list[Node]
repr_format: str
def __init__(self, line: int, column: int, content: list[Node]) -> None: ...
class SquareBracketsBlock(Node):
type: Literal["[] block"]
content: list[Node]
repr_format: str
def __init__(self, line: int, column: int, content: list[Node]) -> None: ...
class CurlyBracketsBlock(Node):
type: Literal["{} block"]
content: list[Node]
repr_format: str
def __init__(self, line: int, column: int, content: list[Node]) -> None: ...
class FunctionBlock(Node):
type: Literal["function"]
name: str
lower_name: str
arguments: list[Node]
repr_format: str
def __init__(self, line: int, column: int, name: str, arguments: list[Node]) -> None: ...
class Declaration(Node):
type: Literal["declaration"]
name: str
lower_name: str
value: list[Node]
important: bool
repr_format: str
def __init__(self, line: int, column: int, name: str, lower_name: str, value: list[Node], important: bool) -> None: ...
class QualifiedRule(Node):
type: Literal["qualified-rule"]
prelude: list[Node]
content: list[Node]
repr_format: str
def __init__(self, line: int, column: int, prelude: list[Node], content: list[Node]) -> None: ...
class AtRule(Node):
type: Literal["at-rule"]
at_keyword: str
lower_at_keyword: str
prelude: list[Node]
content: list[Node] | None
repr_format: str
def __init__(
self, line: int, column: int, at_keyword: str, lower_at_keyword: str, prelude: list[Node], content: list[Node] | None
) -> None: ...