zmc
2023-08-08 e792e9a60d958b93aef96050644f369feb25d61b
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
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
U
[±d…ã@s²ddlmZddlmZmZddlmZddlZddlZddl    m
Z
ddl    m Z ddl    m Z eGd    d
„d
ƒƒZ eGd d „d ƒƒZeGd d„dƒƒZeGdd„dƒƒZeGdd„dƒƒZGdd„deƒZGdd„deƒZeGdd„dƒƒZeGdd„dƒƒZeGdd„dƒƒZGdd„deƒZeGdd „d ƒƒZeGd!d"„d"ƒƒZeGd#d$„d$ƒƒZeGd%d&„d&ƒƒZd'd(œd)d*„Zd'd(œd+d,„Zd7d-d.d.d.d/d0œd1d2„Z d8d-d.d.d3d4œd5d6„Z!dS)9é)Ú annotationsé)Ú event_classÚ T_JSON_DICT)Ú    dataclassN)Údom)Ú dom_debugger)Úpagec@sfeZdZUdZded<ded<ded<ded<d    Zd
ed <d    Zd
ed <d    Zd ed<d    Zd ed<d    Z    ded<d    Z
ded<d    Z ded<d    Z ded<d    Z d
ed<d    Zd
ed<d    Zd
ed<d    Zd
ed<d    Zd
ed<d    Zd
ed<d    Zded<d    Zded<d    Zd ed!<d    Zd"ed#<d    Zd ed$<d    Zd%ed&<d    Zd
ed'<d    Zd
ed(<d    Zd)ed*<d    Zd)ed+<d,d-„Zed.d/„ƒZd    S)0ÚDOMNodez!
    A Node in the DOM tree.
    ÚintÚ    node_typeÚstrÚ    node_nameÚ
node_valuezdom.BackendNodeIdÚbackend_node_idNútyping.Optional[str]Ú
text_valueÚ input_valueútyping.Optional[bool]Ú input_checkedÚoption_selectedú!typing.Optional[typing.List[int]]Úchild_node_indexesz'typing.Optional[typing.List[NameValue]]Ú
attributesÚpseudo_element_indexesútyping.Optional[int]Úlayout_node_indexÚ document_urlÚbase_urlÚcontent_languageÚdocument_encodingÚ    public_idÚ    system_idztyping.Optional[page.FrameId]Úframe_idÚcontent_document_indexztyping.Optional[dom.PseudoType]Ú pseudo_typez#typing.Optional[dom.ShadowRootType]Úshadow_root_typeÚ is_clickablez8typing.Optional[typing.List[dom_debugger.EventListener]]Úevent_listenersÚcurrent_source_urlÚ
origin_urlútyping.Optional[float]Úscroll_offset_xÚscroll_offset_ycCsjtƒ}|j|d<|j|d<|j|d<|j ¡|d<|jdk    rF|j|d<|jdk    rZ|j|d<|jdk    rn|j|d<|j    dk    r‚|j    |d<|j
dk    r d    d
„|j
Dƒ|d <|j dk    r¾d d
„|j Dƒ|d <|j dk    rÜdd
„|j Dƒ|d<|j dk    rð|j |d<|jdk    r|j|d<|jdk    r|j|d<|jdk    r2|j|d<|jdk    rH|j|d<|jdk    r^|j|d<|jdk    rt|j|d<|jdk    rŽ|j ¡|d<|jdk    r¤|j|d<|jdk    r¾|j ¡|d<|jdk    rØ|j ¡|d<|jdk    rî|j|d<|jdk    rdd
„|jDƒ|d<|jdk    r$|j|d<|jdk    r:|j|d<|jdk    rP|j|d <|jdk    rf|j|d!<|S)"NÚnodeTypeÚnodeNameÚ    nodeValueÚ backendNodeIdÚ    textValueÚ
inputValueÚ inputCheckedÚoptionSelectedcSsg|]}|‘qS©r6©Ú.0Úir6r6újd:\z\workplace\vscode\pyvenv\venv\Lib\site-packages\selenium/webdriver/common/devtools/v85/dom_snapshot.pyÚ
<listcomp>~sz#DOMNode.to_json.<locals>.<listcomp>ÚchildNodeIndexescSsg|] }| ¡‘qSr6©Úto_jsonr7r6r6r:r;€srcSsg|]}|‘qSr6r6r7r6r6r:r;‚sÚpseudoElementIndexesÚlayoutNodeIndexÚ documentURLÚbaseURLÚcontentLanguageÚdocumentEncodingÚpublicIdÚsystemIdÚframeIdÚcontentDocumentIndexÚ
pseudoTypeÚshadowRootTypeÚ isClickablecSsg|] }| ¡‘qSr6r=r7r6r6r:r;œsÚeventListenersÚcurrentSourceURLÚ    originURLÚ scrollOffsetXÚ scrollOffsetY)Údictr rrrr>rrrrrrrrrrrr r!r"r#r$r%r&r'r(r)r*r,r-©ÚselfÚjsonr6r6r:r>osl
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
zDOMNode.to_jsoncCsˆ|t|dƒt|dƒt|dƒtj |d¡d|krBt|dƒndd|krXt|dƒndd|krnt|dƒndd|kr„t|dƒndd    |kr d
d „|d    Dƒndd |kr¼d d „|d Dƒndd|krØdd „|dDƒndd|krît|dƒndd|krt|dƒndd|krt|dƒndd|kr6t|dƒndd|krNt|dƒndd|krft|dƒndd|kr~t|dƒndd|krštj |d¡ndd|kr²t|dƒndd|krÎtj |d¡ndd|krêtj     |d¡ndd|krt|dƒndd|kr dd „|dDƒndd|kr8t|dƒndd|krPt|dƒndd |krht
|d ƒndd!|kr€t
|d!ƒndd"S)#Nr.r/r0r1r2r3r4r5r<cSsg|] }t|ƒ‘qSr6©r r7r6r6r:r;²sz%DOMNode.from_json.<locals>.<listcomp>rcSsg|]}t |¡‘qSr6©Ú    NameValueÚ    from_jsonr7r6r6r:r;³sr?cSsg|] }t|ƒ‘qSr6rUr7r6r6r:r;´sr@rArBrCrDrErFrGrHrIrJrKrLcSsg|]}tj |¡‘qSr6)rZ EventListenerrXr7r6r6r:r;ÁsrMrNrOrP)r rrrrrrrrrrrrrrr r!r"r#r$r%r&r'r(r)r*r,r-) r r rÚ BackendNodeIdrXÚboolr    ZFrameIdZ
PseudoTypeZShadowRootTypeÚfloat©ÚclsrTr6r6r:rX§s<
 
 
äzDOMNode.from_json) Ú__name__Ú
__module__Ú __qualname__Ú__doc__Ú__annotations__rrrrrrrrrrrr r!r"r#r$r%r&r'r(r)r*r,r-r>Ú classmethodrXr6r6r6r:r
s@
                        8r
c@s>eZdZUdZded<ded<ded<dd„Zed    d
„ƒZd S) Ú InlineTextBoxz
    Details of post layout rendered text positions. The exact layout should not be regarded as
    stable and may change between versions.
    údom.RectÚ bounding_boxr Ústart_character_indexÚnum_characterscCs,tƒ}|j ¡|d<|j|d<|j|d<|S)NÚ boundingBoxÚstartCharacterIndexÚ numCharacters)rQrfr>rgrhrRr6r6r:r>Ús
 
 
zInlineTextBox.to_jsoncCs*|tj |d¡t|dƒt|dƒdS)Nrirjrk)rfrgrh)rÚRectrXr r\r6r6r:rXás
 
 
ýzInlineTextBox.from_jsonN©r^r_r`rarbr>rcrXr6r6r6r:rdÉs
rdc@sreZdZUdZded<ded<dZded<dZd    ed
<dZd ed <dZd ed <dZ    ded<dd„Z
e dd„ƒZ dS)ÚLayoutTreeNodezD
    Details of an element in the DOM tree with a LayoutObject.
    r Údom_node_indexrerfNrÚ layout_textz+typing.Optional[typing.List[InlineTextBox]]Úinline_text_nodesrÚ style_indexÚ paint_orderrÚis_stacking_contextcCstƒ}|j|d<|j ¡|d<|jdk    r2|j|d<|jdk    rPdd„|jDƒ|d<|jdk    rd|j|d<|jdk    rx|j|d<|jdk    rŒ|j|d    <|S)
NÚ domNodeIndexriÚ
layoutTextcSsg|] }| ¡‘qSr6r=r7r6r6r:r; sz*LayoutTreeNode.to_json.<locals>.<listcomp>ÚinlineTextNodesÚ
styleIndexÚ
paintOrderÚisStackingContext)    rQrorfr>rprqrrrsrtrRr6r6r:r>s
 
 
 
 
 
 
 
 
 
zLayoutTreeNode.to_jsonc
Cs”|t|dƒtj |d¡d|kr.t|dƒndd|krJdd„|dDƒndd|kr`t|dƒndd|krvt|dƒndd    |krŒt|d    ƒndd
S) NrurirvrwcSsg|]}t |¡‘qSr6)rdrXr7r6r6r:r;sz,LayoutTreeNode.from_json.<locals>.<listcomp>rxryrz)rorfrprqrrrsrt)r rrlrXr rZr\r6r6r:rXs
ùzLayoutTreeNode.from_json) r^r_r`rarbrprqrrrsrtr>rcrXr6r6r6r:rnês
     rnc@s.eZdZUdZded<dd„Zedd„ƒZdS)    Ú ComputedStylezQ
    A subset of the full ComputedStyle as defined by the request whitelist.
    ztyping.List[NameValue]Ú
propertiescCstƒ}dd„|jDƒ|d<|S)NcSsg|] }| ¡‘qSr6r=r7r6r6r:r;-sz)ComputedStyle.to_json.<locals>.<listcomp>r|)rQr|rRr6r6r:r>+szComputedStyle.to_jsoncCs|dd„|dDƒdS)NcSsg|]}t |¡‘qSr6rVr7r6r6r:r;3sz+ComputedStyle.from_json.<locals>.<listcomp>r|)r|r6r\r6r6r:rX0sÿzComputedStyle.from_jsonNrmr6r6r6r:r{#s
 
r{c@s6eZdZUdZded<ded<dd„Zedd„ƒZd    S)
rWz
    A name/value pair.
    r ÚnameÚvaluecCstƒ}|j|d<|j|d<|S)Nr}r~)rQr}r~rRr6r6r:r>Bs
 
zNameValue.to_jsoncCs|t|dƒt|dƒdS)Nr}r~)r}r~©r r\r6r6r:rXHs
 
þzNameValue.from_jsonNrmr6r6r6r:rW7s
rWcsBeZdZdZddœdd„Zedddœdd„ƒZ‡fd    d
„Z‡ZS) Ú StringIndexú3
    Index of the string in the strings table.
    r ©ÚreturncCs|S©Nr6©rSr6r6r:r>TszStringIndex.to_json©rTrƒcCs||ƒSr„r6r\r6r6r:rXWszStringIndex.from_jsoncsd tƒ ¡¡S)NzStringIndex({})©ÚformatÚsuperÚ__repr__r…©Ú    __class__r6r:rŠ[szStringIndex.__repr__©    r^r_r`rar>rcrXrŠÚ __classcell__r6r6r‹r:r€Ps
r€csBeZdZdZddœdd„Zedddœdd„ƒZ‡fd    d
„Z‡ZS) ÚArrayOfStringsrútyping.List[StringIndex]r‚cCs|Sr„r6r…r6r6r:r>cszArrayOfStrings.to_jsonr†cCs||ƒSr„r6r\r6r6r:rXfszArrayOfStrings.from_jsoncsd tƒ ¡¡S)NzArrayOfStrings({})r‡r…r‹r6r:rŠjszArrayOfStrings.__repr__rr6r6r‹r:r_s
rc@s6eZdZUdZded<ded<dd„Zedd    „ƒZd
S) ÚRareStringDataz2
    Data that is only present on rare nodes.
    útyping.List[int]Úindexrr~cCs2tƒ}dd„|jDƒ|d<dd„|jDƒ|d<|S)NcSsg|]}|‘qSr6r6r7r6r6r:r;ysz*RareStringData.to_json.<locals>.<listcomp>r“cSsg|] }| ¡‘qSr6r=r7r6r6r:r;zsr~©rQr“r~rRr6r6r:r>wszRareStringData.to_jsoncCs(|dd„|dDƒdd„|dDƒdS)NcSsg|] }t|ƒ‘qSr6rUr7r6r6r:r;€sz,RareStringData.from_json.<locals>.<listcomp>r“cSsg|]}t |¡‘qSr6©r€rXr7r6r6r:r;sr~©r“r~r6r\r6r6r:rX}sþzRareStringData.from_jsonNrmr6r6r6r:r‘ns
r‘c@s*eZdZUded<dd„Zedd„ƒZdS)ÚRareBooleanDatar’r“cCstƒ}dd„|jDƒ|d<|S)NcSsg|]}|‘qSr6r6r7r6r6r:r;‹sz+RareBooleanData.to_json.<locals>.<listcomp>r“)rQr“rRr6r6r:r>‰szRareBooleanData.to_jsoncCs|dd„|dDƒdS)NcSsg|] }t|ƒ‘qSr6rUr7r6r6r:r;‘sz-RareBooleanData.from_json.<locals>.<listcomp>r“)r“r6r\r6r6r:rXŽsÿzRareBooleanData.from_jsonN©r^r_r`rbr>rcrXr6r6r6r:r—…s
r—c@s2eZdZUded<ded<dd„Zedd„ƒZdS)    ÚRareIntegerDatar’r“r~cCs2tƒ}dd„|jDƒ|d<dd„|jDƒ|d<|S)NcSsg|]}|‘qSr6r6r7r6r6r:r;sz+RareIntegerData.to_json.<locals>.<listcomp>r“cSsg|]}|‘qSr6r6r7r6r6r:r;žsr~r”rRr6r6r:r>›szRareIntegerData.to_jsoncCs(|dd„|dDƒdd„|dDƒdS)NcSsg|] }t|ƒ‘qSr6rUr7r6r6r:r;¤sz-RareIntegerData.from_json.<locals>.<listcomp>r“cSsg|] }t|ƒ‘qSr6rUr7r6r6r:r;¥sr~r–r6r\r6r6r:rX¡sþzRareIntegerData.from_jsonNr˜r6r6r6r:r™•s
 
r™cs>eZdZddœdd„Zedddœdd„ƒZ‡fdd    „Z‡ZS)
Ú    Rectangleztyping.List[float]r‚cCs|Sr„r6r…r6r6r:r>ªszRectangle.to_jsonr†cCs||ƒSr„r6r\r6r6r:rX­szRectangle.from_jsoncsd tƒ ¡¡S)Nz Rectangle({})r‡r…r‹r6r:rбszRectangle.__repr__)r^r_r`r>rcrXrŠrŽr6r6r‹r:rš©sršc@s®eZdZUdZded<ded<ded<ded<ded<ded<ded    <ded
<d ed <d ed<ded<dZded<dZded<dZded<dZded<dd„Z    e
dd„ƒZ dS)ÚDocumentSnapshotz
    Document snapshot.
    r€rÚtitlerrÚ encoding_namer!r"r#ÚNodeTreeSnapshotÚnodesÚLayoutTreeSnapshotÚlayoutÚTextBoxSnapshotÚ
text_boxesNr+r,r-Ú content_widthÚcontent_heightcCsôtƒ}|j ¡|d<|j ¡|d<|j ¡|d<|j ¡|d<|j ¡|d<|j ¡|d<|j ¡|d<|j     ¡|d<|j
 ¡|d    <|j  ¡|d
<|j  ¡|d <|j dk    r´|j |d <|jdk    rÈ|j|d <|jdk    rÜ|j|d<|jdk    rð|j|d<|S)NrArœrBrCÚ encodingNamerErFrGrŸr¡Ú    textBoxesrOrPÚ contentWidthÚ contentHeight)rQrr>rœrrrr!r"r#rŸr¡r£r,r-r¤r¥rRr6r6r:r>çs*
 
 
 
 
 
 
 
zDocumentSnapshot.to_jsoncCsä|t |d¡t |d¡t |d¡t |d¡t |d¡t |d¡t |d¡t |d¡t |d    ¡t |d
¡t |d ¡d |kršt|d ƒndd |kr°t|d ƒndd|krÆt|dƒndd|krÜt|dƒnddS)NrArœrBrCr¦rErFrGrŸr¡r§rOrPr¨r©)rrœrrrr!r"r#rŸr¡r£r,r-r¤r¥)r€rXržr r¢r[r\r6r6r:rXþs"           ñzDocumentSnapshot.from_json) r^r_r`rarbr,r-r¤r¥r>rcrXr6r6r6r:r›µs&
    r›c@sÚeZdZUdZdZded<dZded<dZded<dZded<dZ    d    ed
<dZ
d ed <dZ d ed<dZ d ed<dZ ded<dZded<dZded<dZd ed<dZded<dZd ed<dZd ed<dd„Zedd„ƒZdS)ržz!
    Table containing nodes.
    NrÚ parent_indexr z)typing.Optional[typing.List[StringIndex]]rrz/typing.Optional[typing.List[dom.BackendNodeId]]rz,typing.Optional[typing.List[ArrayOfStrings]]rztyping.Optional[RareStringData]rrz typing.Optional[RareBooleanData]rrz typing.Optional[RareIntegerData]r$r%r'r)r*cCs¤tƒ}|jdk    r$dd„|jDƒ|d<|jdk    rBdd„|jDƒ|d<|jdk    r`dd„|jDƒ|d<|jdk    r~dd„|jDƒ|d    <|jdk    rœd
d„|jDƒ|d <|jdk    rºd d„|jDƒ|d <|jdk    rÒ|j ¡|d<|j    dk    rê|j     ¡|d<|j
dk    r|j
 ¡|d<|j dk    r|j  ¡|d<|j dk    r8|j  ¡|d<|j dk    rR|j  ¡|d<|jdk    rl|j ¡|d<|jdk    r†|j ¡|d<|jdk    r |j ¡|d<|S)NcSsg|]}|‘qSr6r6r7r6r6r:r;Jsz,NodeTreeSnapshot.to_json.<locals>.<listcomp>Ú parentIndexcSsg|]}|‘qSr6r6r7r6r6r:r;Lsr.cSsg|] }| ¡‘qSr6r=r7r6r6r:r;Nsr/cSsg|] }| ¡‘qSr6r=r7r6r6r:r;Psr0cSsg|] }| ¡‘qSr6r=r7r6r6r:r;Rsr1cSsg|] }| ¡‘qSr6r=r7r6r6r:r;Tsrr2r3r4r5rHrIrKrMrN)rQrªr rrrrrr>rrrr$r%r'r)r*rRr6r6r:r>Gs@
 
 
 
 
 
 
 
       zNodeTreeSnapshot.to_jsoncCs”|d|krdd„|dDƒndd|kr8dd„|dDƒndd|krTdd„|dDƒndd|krpd    d„|dDƒndd
|krŒd d„|d
Dƒndd |kr¨d d„|d Dƒndd|krÀt |d¡ndd|krØt |d¡ndd|krðt |d¡ndd|kr
t |d¡ndd|kr$t |d¡ndd|kr>t |d¡ndd|krXt |d¡ndd|krrt |d¡ndd|krŒt |d¡nddS)Nr«cSsg|] }t|ƒ‘qSr6rUr7r6r6r:r;lsz.NodeTreeSnapshot.from_json.<locals>.<listcomp>r.cSsg|] }t|ƒ‘qSr6rUr7r6r6r:r;msr/cSsg|]}t |¡‘qSr6r•r7r6r6r:r;nsr0cSsg|]}t |¡‘qSr6r•r7r6r6r:r;osr1cSsg|]}tj |¡‘qSr6)rrYrXr7r6r6r:r;psrcSsg|]}t |¡‘qSr6©rrXr7r6r6r:r;qsr2r3r4r5rHrIrKrMrN)rªr rrrrrrrrr$r%r'r)r*)r‘rXr—r™r\r6r6r:rXis"ñzNodeTreeSnapshot.from_json)r^r_r`rarªrbr rrrrrrrrr$r%r'r)r*r>rcrXr6r6r6r:ržs&
               "ržc@s~eZdZUdZded<ded<ded<ded    <d
ed <d Zd ed<d Zded<d Zded<d Zded<dd„Z    e
dd„ƒZ d S)r zM
    Table of details of an element in the DOM tree with a LayoutObject.
    r’Ú
node_indexztyping.List[ArrayOfStrings]Ústylesútyping.List[Rectangle]ÚboundsrÚtextr—Ústacking_contextsNrÚ paint_ordersz'typing.Optional[typing.List[Rectangle]]Ú offset_rectsÚ scroll_rectsÚ client_rectscCsàtƒ}dd„|jDƒ|d<dd„|jDƒ|d<dd„|jDƒ|d<dd„|jDƒ|d    <|j ¡|d
<|jdk    r‚d d„|jDƒ|d <|jdk    r d d„|jDƒ|d<|j    dk    r¾dd„|j    Dƒ|d<|j
dk    rÜdd„|j
Dƒ|d<|S)NcSsg|]}|‘qSr6r6r7r6r6r:r;¢sz.LayoutTreeSnapshot.to_json.<locals>.<listcomp>Ú    nodeIndexcSsg|] }| ¡‘qSr6r=r7r6r6r:r;£sr®cSsg|] }| ¡‘qSr6r=r7r6r6r:r;¤sr°cSsg|] }| ¡‘qSr6r=r7r6r6r:r;¥sr±ÚstackingContextscSsg|]}|‘qSr6r6r7r6r6r:r;¨sÚ paintOrderscSsg|] }| ¡‘qSr6r=r7r6r6r:r;ªsÚ offsetRectscSsg|] }| ¡‘qSr6r=r7r6r6r:r;¬sÚ scrollRectscSsg|] }| ¡‘qSr6r=r7r6r6r:r;®sÚ clientRects) rQr­r®r°r±r²r>r³r´rµr¶rRr6r6r:r> s
 
 
 
zLayoutTreeSnapshot.to_jsonc CsÄ|dd„|dDƒdd„|dDƒdd„|dDƒdd„|d    Dƒt |d
¡d |krhd d„|d Dƒndd |kr„dd„|d Dƒndd|kr dd„|dDƒndd|kr¼dd„|dDƒndd    S)NcSsg|] }t|ƒ‘qSr6rUr7r6r6r:r;´sz0LayoutTreeSnapshot.from_json.<locals>.<listcomp>r·cSsg|]}t |¡‘qSr6r¬r7r6r6r:r;µsr®cSsg|]}t |¡‘qSr6©ršrXr7r6r6r:r;¶sr°cSsg|]}t |¡‘qSr6r•r7r6r6r:r;·sr±r¸r¹cSsg|] }t|ƒ‘qSr6rUr7r6r6r:r;¹srºcSsg|]}t |¡‘qSr6r½r7r6r6r:r;ºsr»cSsg|]}t |¡‘qSr6r½r7r6r6r:r;»sr¼cSsg|]}t |¡‘qSr6r½r7r6r6r:r;¼s)    r­r®r°r±r²r³r´rµr¶)r—rXr\r6r6r:rX±s ÷zLayoutTreeSnapshot.from_json) r^r_r`rarbr³r´rµr¶r>rcrXr6r6r6r:r ~s
    r c@sFeZdZUdZded<ded<ded<ded<dd    „Zed
d „ƒZd S) r¢z
    Table of details of the post layout rendered text positions. The exact layout should not be regarded as
    stable and may change between versions.
    r’Ú layout_indexr¯r°ÚstartÚlengthcCsZtƒ}dd„|jDƒ|d<dd„|jDƒ|d<dd„|jDƒ|d<dd„|jDƒ|d    <|S)
NcSsg|]}|‘qSr6r6r7r6r6r:r;Ösz+TextBoxSnapshot.to_json.<locals>.<listcomp>Ú layoutIndexcSsg|] }| ¡‘qSr6r=r7r6r6r:r;×sr°cSsg|]}|‘qSr6r6r7r6r6r:r;Øsr¿cSsg|]}|‘qSr6r6r7r6r6r:r;ÙsrÀ)rQr¾r°r¿rÀrRr6r6r:r>Ôs zTextBoxSnapshot.to_jsoncCsH|dd„|dDƒdd„|dDƒdd„|dDƒdd„|d    Dƒd
S) NcSsg|] }t|ƒ‘qSr6rUr7r6r6r:r;ßsz-TextBoxSnapshot.from_json.<locals>.<listcomp>rÁcSsg|]}t |¡‘qSr6r½r7r6r6r:r;àsr°cSsg|] }t|ƒ‘qSr6rUr7r6r6r:r;ásr¿cSsg|] }t|ƒ‘qSr6rUr7r6r6r:r;âsrÀ)r¾r°r¿rÀr6r\r6r6r:rXÜs üzTextBoxSnapshot.from_jsonNrmr6r6r6r:r¢Às
r¢z0typing.Generator[T_JSON_DICT, T_JSON_DICT, None]r‚ccsddi}|V}dS)z9
    Disables DOM snapshot agent for the given page.
    ÚmethodzDOMSnapshot.disableNr6©Úcmd_dictrTr6r6r:ÚdisableæsÿrÅccsddi}|V}dS)z8
    Enables DOM snapshot agent for the given page.
    rÂzDOMSnapshot.enableNr6rÃr6r6r:ÚenableðsÿrÆztyping.List[str]rz‡typing.Generator[T_JSON_DICT, T_JSON_DICT, typing.Tuple[typing.List[DOMNode], typing.List[LayoutTreeNode], typing.List[ComputedStyle]]])Úcomputed_style_whitelistÚinclude_event_listenersÚinclude_paint_orderÚinclude_user_agent_shadow_treerƒccsŒtƒ}dd„|Dƒ|d<|dk    r(||d<|dk    r8||d<|dk    rH||d<d|d    œ}|V}d
d„|d Dƒd d„|d Dƒdd„|dDƒfS)a?
    Returns a document snapshot, including the full DOM tree of the root node (including iframes,
    template contents, and imported documents) in a flattened array, as well as layout and
    white-listed computed style information for the nodes. Shadow DOM in the returned DOM tree is
    flattened.
 
    :param computed_style_whitelist: Whitelist of computed styles to return.
    :param include_event_listeners: *(Optional)* Whether or not to retrieve details of DOM listeners (default false).
    :param include_paint_order: *(Optional)* Whether to determine and include the paint order index of LayoutTreeNodes (default false).
    :param include_user_agent_shadow_tree: *(Optional)* Whether to include UA shadow tree in the snapshot (default false).
    :returns: A tuple with the following items:
 
        0. **domNodes** - The nodes in the DOM tree. The DOMNode at index 0 corresponds to the root document.
        1. **layoutTreeNodes** - The nodes in the layout tree.
        2. **computedStyles** - Whitelisted ComputedStyle properties for each node in the layout tree.
    cSsg|]}|‘qSr6r6r7r6r6r:r;sz get_snapshot.<locals>.<listcomp>ZcomputedStyleWhitelistNZincludeEventListenersÚincludePaintOrderZincludeUserAgentShadowTreezDOMSnapshot.getSnapshot©rÂÚparamscSsg|]}t |¡‘qSr6)r
rXr7r6r6r:r;sZdomNodescSsg|]}t |¡‘qSr6)rnrXr7r6r6r:r;sZlayoutTreeNodescSsg|]}t |¡‘qSr6)r{rXr7r6r6r:r; sÚcomputedStyles©rQ)rÇrÈrÉrÊrÍrÄrTr6r6r:Ú get_snapshotús þýrÐzityping.Generator[T_JSON_DICT, T_JSON_DICT, typing.Tuple[typing.List[DocumentSnapshot], typing.List[str]]])Úcomputed_stylesrÉÚinclude_dom_rectsrƒccsltƒ}dd„|Dƒ|d<|dk    r(||d<|dk    r8||d<d|dœ}|V}d    d„|d
Dƒd d„|d DƒfS) al
    Returns a document snapshot, including the full DOM tree of the root node (including iframes,
    template contents, and imported documents) in a flattened array, as well as layout and
    white-listed computed style information for the nodes. Shadow DOM in the returned DOM tree is
    flattened.
 
    :param computed_styles: Whitelist of computed styles to return.
    :param include_paint_order: *(Optional)* Whether to include layout object paint orders into the snapshot.
    :param include_dom_rects: *(Optional)* Whether to include DOM rectangles (offsetRects, clientRects, scrollRects) into the snapshot
    :returns: A tuple with the following items:
 
        0. **documents** - The nodes in the DOM tree. The DOMNode at index 0 corresponds to the root document.
        1. **strings** - Shared string table that all string properties refer to with indexes.
    cSsg|]}|‘qSr6r6r7r6r6r:r;8sz$capture_snapshot.<locals>.<listcomp>rÎNrËZincludeDOMRectszDOMSnapshot.captureSnapshotrÌcSsg|]}t |¡‘qSr6)r›rXr7r6r6r:r;CsZ    documentscSsg|] }t|ƒ‘qSr6rr7r6r6r:r;DsÚstringsrÏ)rÑrÉrÒrÍrÄrTr6r6r:Úcapture_snapshot$sþþrÔ)NNN)NN)"Ú
__future__rÚutilrrZ dataclassesrÚenumÚtypingÚrrr    r
rdrnr{rWr r€Úlistrr‘r—r™ršr›ržr r¢rÅrÆrÐrÔr6r6r6r:Ú<module>sX     8 8 ]jA%
 ü,ý