
    +g:                       S SK Jr  SSKJrJr  S SKJr  S SKrS SKrSSK	J
r
  SSK	Jr   " S S	\5      r " S
 S\R                  5      r " S S\R                  5      r " S S\R                  5      r\ " S S5      5       r\ " S S5      5       r\ " S S5      5       r\ " S S5      5       r " S S\R                  5      r\ " S S5      5       rS S jrS S jr    S!         S"S jjrS#S jrg)$    )annotations   )event_classT_JSON_DICT)	dataclassN)dom)runtimec                  J   ^  \ rS rSrSrSS jr\SS j5       rU 4S jrSr	U =r
$ )	AXNodeId   z'
Unique accessibility node identifier.
c                    U $ N selfs    |/Users/Alptekin/Desktop/izin_takip/venv/lib/python3.13/site-packages/selenium/webdriver/common/devtools/v85/accessibility.pyto_jsonAXNodeId.to_json   s        c                    U " U5      $ r   r   clsjsons     r   	from_jsonAXNodeId.from_json       4yr   c                >   > SR                  [        TU ]	  5       5      $ )NzAXNodeId({}))formatsuper__repr__)r   	__class__s    r   r    AXNodeId.__repr__   s    $$UW%5%788r   r   )returnstr)r   r$   r#   r   )__name__
__module____qualname____firstlineno____doc__r   classmethodr   r    __static_attributes____classcell__)r!   s   @r   r   r      s+      9 9r   r   c                  r    \ rS rSrSrSrSrSrSrSr	Sr
S	rS
rSrSrSrSrSrSrSrSrSrS r\S 5       rSrg)AXValueType   z"
Enum of possible property types.
booleantristatebooleanOrUndefinedidref	idrefListintegernodenodeListnumberstringcomputedStringtoken	tokenListdomRelationroleinternalRolevalueUndefinedc                    U R                   $ r   valuer   s    r   r   AXValueType.to_json5       zzr   c                    U " U5      $ r   r   r   s     r   r   AXValueType.from_json8   r   r   r   N)r%   r&   r'   r(   r)   BOOLEANTRISTATEBOOLEAN_OR_UNDEFINEDIDREF
IDREF_LISTINTEGERNODE	NODE_LISTNUMBERSTRINGCOMPUTED_STRINGTOKEN
TOKEN_LISTDOM_RELATIONROLEINTERNAL_ROLEVALUE_UNDEFINEDr   r*   r   r+   r   r   r   r.   r.      sx     GH/EJGDIFF&OEJ LD"M&O  r   r.   c                  F    \ rS rSrSrSrSrSrSrSr	Sr
S	 r\S
 5       rSrg)AXValueSourceType=   z$
Enum of possible property sources.
	attributeimplicitstylecontentsplaceholderrelatedElementc                    U R                   $ r   rB   r   s    r   r   AXValueSourceType.to_jsonH   rE   r   c                    U " U5      $ r   r   r   s     r   r   AXValueSourceType.from_jsonK   r   r   r   N)r%   r&   r'   r(   r)   	ATTRIBUTEIMPLICITSTYLECONTENTSPLACEHOLDERRELATED_ELEMENTr   r*   r   r+   r   r   r   rZ   rZ   =   s@     IHEHK&O  r   rZ   c                  N    \ rS rSrSrSrSrSrSrSr	Sr
S	rS
rS r\S 5       rSrg)AXValueNativeSourceTypeP   z\
Enum of possible native property sources (as a subtype of a particular AXValueSourceType).

figcaptionlabellabelforlabelwrappedlegendtablecaptiontitleotherc                    U R                   $ r   rB   r   s    r   r   AXValueNativeSourceType.to_json]   rE   r   c                    U " U5      $ r   r   r   s     r   r   !AXValueNativeSourceType.from_json`   r   r   r   N)r%   r&   r'   r(   r)   
FIGCAPTIONLABELLABELFORLABELWRAPPEDLEGENDTABLECAPTIONTITLEOTHERr   r*   r   r+   r   r   r   rm   rm   P   sJ     JEH!LF!LEE  r   rm   c                      \ rS rSr% SrS\S'   SrS\S'   SrS\S	'   SrS\S
'   Sr	S\S'   Sr
S\S'   SrS\S'   SrS\S'   SrS\S'   S r\S 5       rSrg)AXValueSourcee   z-
A single source for a computed AX property.
rZ   type_Ntyping.Optional[AXValue]rC   typing.Optional[str]r\   attribute_valuetyping.Optional[bool]
supersededz(typing.Optional[AXValueNativeSourceType]native_sourcenative_source_valueinvalidinvalid_reasonc                   [        5       nU R                  R                  5       US'   U R                  b  U R                  R                  5       US'   U R                  b  U R                  US'   U R
                  b  U R
                  R                  5       US'   U R                  b  U R                  US'   U R                  b  U R                  R                  5       US'   U R                  b  U R                  R                  5       US'   U R                  b  U R                  US'   U R                  b  U R                  US	'   U$ )
NtyperC   r\   attributeValuer   nativeSourcenativeSourceValuer   invalidReason)dictr   r   rC   r\   r   r   r   r   r   r   r   r   s     r   r   AXValueSource.to_json   s   vzz))+V::! JJ..0DM>>% $D+%)%9%9%A%A%CD!"??&!%D)#'#5#5#=#=#?D ##/(,(@(@(H(H(JD$%<<#"llDO*$($7$7D!r   c                   U " [         R                  US   5      SU;   a  [        R                  US   5      OS SU;   a  [        US   5      OS SU;   a  [        R                  US   5      OS SU;   a  [	        US   5      OS SU;   a  [
        R                  US   5      OS SU;   a  [        R                  US   5      OS SU;   a  [	        US   5      OS S	U;   a  [        US	   5      S
9	$ S S
9	$ )Nr   rC   r\   r   r   r   r   r   r   )	r   rC   r\   r   r   r   r   r   r   )rZ   r   AXValuer$   boolrm   r   s     r   r   AXValueSource.from_json   s    #--d6l;6=o'##DM240;t0Cc${+,IY]aIaG--d3C.DEgk3?43GtD./TUcgkUk1;;D<PQquPcgkPk 1 1$7J2K Lqu-6$->Di)D9HD9P3tO45

 
	
 W[

 
	
r   r   )r%   r&   r'   r(   r)   __annotations__rC   r\   r   r   r   r   r   r   r   r*   r   r+   r   r   r   r   r   e   s      '+E#* '+I#* 15O-4 )-J%, ?CM;B 5918 &*G") ,0N(/* 
 
r   r   c                  R    \ rS rSr% S\S'   SrS\S'   SrS\S'   S r\S	 5       r	S
r
g)AXRelatedNode   zdom.BackendNodeIdbackend_dom_node_idNr   r3   textc                    [        5       nU R                  R                  5       US'   U R                  b  U R                  US'   U R                  b  U R                  US'   U$ )NbackendDOMNodeIdr3   r   )r   r   r   r3   r   r   s     r   r   AXRelatedNode.to_json   sV    v#'#;#;#C#C#E ::! JJDM99 99DLr   c                    U " [         R                  R                  US   5      SU;   a  [        US   5      OS SU;   a  [        US   5      S9$ S S9$ )Nr   r3   r   )r   r3   r   )r   BackendNodeIdr   r$   r   s     r   r   AXRelatedNode.from_json   s^     # 1 1 ; ;DAS<T U(/4#d7m$T&,nT&\"
 	
 ;?
 	
r   r   )r%   r&   r'   r(   r   r3   r   r   r*   r   r+   r   r   r   r   r      s=     +* #'E& "&D
% 
 
r   r   c                  @    \ rS rSr% S\S'   S\S'   S r\S 5       rSrg	)

AXProperty   AXPropertyNamenamer   rC   c                    [        5       nU R                  R                  5       US'   U R                  R                  5       US'   U$ )Nr   rC   )r   r   r   rC   r   s     r   r   AXProperty.to_json   s:    vyy((*V

**,Wr   c                h    U " [         R                  US   5      [        R                  US   5      S9$ )Nr   rC   )r   rC   )r   r   r   r   s     r   r   AXProperty.from_json   s3    ))$v,7##DM2
 	
r   r   N)	r%   r&   r'   r(   r   r   r*   r   r+   r   r   r   r   r      s*      N 
 
r   r   c                  d    \ rS rSr% SrS\S'   SrS\S'   SrS\S	'   SrS
\S'   S r	\
S 5       rSrg)r      z 
A single computed AX property.
r.   r   Nztyping.Optional[typing.Any]rC   z+typing.Optional[typing.List[AXRelatedNode]]related_nodesz+typing.Optional[typing.List[AXValueSource]]sourcesc                   [        5       nU R                  R                  5       US'   U R                  b  U R                  US'   U R                  b-  U R                   Vs/ s H  o"R                  5       PM     snUS'   U R
                  b-  U R
                   Vs/ s H  o"R                  5       PM     snUS'   U$ s  snf s  snf )Nr   rC   relatedNodesr   )r   r   r   rC   r   r   r   r   is      r   r   AXValue.to_json   s    vzz))+V::! JJDM)9=9K9K#L9KAIIK9K#LD <<#48LLALqyy{LADO $MAs   B:B?c                *   U " [         R                  US   5      SU;   a  US   OS SU;   a)  US    Vs/ s H  n[        R                  U5      PM     snOS SU;   a+  US    Vs/ s H  n[        R                  U5      PM     snS9$ S S9$ s  snf s  snf )Nr   rC   r   r   )r   rC   r   r   )r.   r   r   r   r   r   r   s      r   r   AXValue.from_json   s    ''V5#*d?$w-XfjnXntN?ST?S!=2215?STtxMVZ^M^iIA],,Q/I	
 	
 ei	
 	
 UIs   B#Br   )r%   r&   r'   r(   r)   r   rC   r   r   r   r*   r   r+   r   r   r   r   r      sR      *.E&- BFM>E <@G8?	 
 
r   r   c                      \ rS rSrSrSrSrSrSrSr	Sr
S	rS
rSrSrSrSrSrSrSrSrSrSrSrSrSrSrSrSrSrSrSrSr Sr!S r"S!r#S"r$S#r%S$r&S%r'S&r(S'r)S(r*S)r+S* r,\-S+ 5       r.S,r/g-).r   i  a  
Values of AXProperty name:
- from 'busy' to 'roledescription': states which apply to every AX node
- from 'live' to 'root': attributes which apply to nodes in live regions
- from 'autocomplete' to 'valuetext': attributes which apply to widgets
- from 'checked' to 'selected': states which apply to widgets
- from 'activedescendant' to 'owns' - relationships between elements other than parent/child/sibling.
busydisablededitable	focusablefocusedhidden
hiddenRootr   keyshortcutssettableroledescriptionliveatomicrelevantrootautocompletehasPopuplevelmultiselectableorientation	multilinereadonlyrequiredvalueminvaluemax	valuetextcheckedexpandedmodalpressedselectedactivedescendantcontrolsdescribedbydetailserrormessageflowto
labelledbyownsc                    U R                   $ r   rB   r   s    r   r   AXPropertyName.to_json3  rE   r   c                    U " U5      $ r   r   r   s     r   r   AXPropertyName.from_json6  r   r   r   N)0r%   r&   r'   r(   r)   BUSYDISABLEDEDITABLE	FOCUSABLEFOCUSEDHIDDENHIDDEN_ROOTINVALIDKEYSHORTCUTSSETTABLEROLEDESCRIPTIONLIVEATOMICRELEVANTROOTAUTOCOMPLETE	HAS_POPUPLEVELMULTISELECTABLEORIENTATION	MULTILINEREADONLYREQUIREDVALUEMINVALUEMAX	VALUETEXTCHECKEDEXPANDEDMODALPRESSEDSELECTEDACTIVEDESCENDANTCONTROLSDESCRIBEDBYDETAILSERRORMESSAGEFLOWTO
LABELLEDBYOWNSr   r*   r   r+   r   r   r   r   r     s     DHHIGFKG!LH'ODFHD!LIE'OKIHHHHIGHEGH)HKG!LFJD  r   r   c                      \ rS rSr% SrS\S'   S\S'   SrS\S	'   SrS
\S'   SrS
\S'   Sr	S
\S'   Sr
S
\S'   SrS\S'   SrS\S'   SrS\S'   S r\S 5       rSrg)AXNodei;  z#
A node in the accessibility tree.
r   node_idr   ignoredNz(typing.Optional[typing.List[AXProperty]]ignored_reasonsr   r>   r   descriptionrC   
propertiesz&typing.Optional[typing.List[AXNodeId]]	child_ids"typing.Optional[dom.BackendNodeId]r   c                   [        5       nU R                  R                  5       US'   U R                  US'   U R                  b-  U R                   Vs/ s H  o"R                  5       PM     snUS'   U R
                  b  U R
                  R                  5       US'   U R                  b  U R                  R                  5       US'   U R                  b  U R                  R                  5       US'   U R                  b  U R                  R                  5       US'   U R                  b-  U R                   Vs/ s H  o"R                  5       PM     snUS'   U R                  b-  U R                   Vs/ s H  o"R                  5       PM     snUS	'   U R                  b  U R                  R                  5       US
'   U$ s  snf s  snf s  snf )NnodeIdr  ignoredReasonsr>   r   r  rC   r  childIdsr   )r   r  r   r  r  r>   r   r  rC   r  r  r   r   s      r   r   AXNode.to_json^  ss   v--/X,,Y+;?;O;O%P;Oaiik;O%PD!"99 99,,.DL99 99,,.DL'"&"2"2":":"<D::! JJ..0DM??&7;!G!))+!GD>>%59^^D^		^DD##/'+'?'?'G'G'ID#$ &Q "HDs   F94F>.Gc                   U " [         R                  US   5      [        US   5      SU;   a)  US    Vs/ s H  n[        R                  U5      PM     snOS SU;   a  [        R                  US   5      OS SU;   a  [        R                  US   5      OS SU;   a  [        R                  US   5      OS SU;   a  [        R                  US   5      OS SU;   a)  US    Vs/ s H  n[        R                  U5      PM     snOS S	U;   a)  US	    Vs/ s H  n[         R                  U5      PM     snOS S
U;   a$  [
        R                  R                  US
   5      S9
$ S S9
$ s  snf s  snf s  snf )Nr  r  r  r>   r   r  rC   r  r  r   )
r  r  r  r>   r   r  rC   r  r  r   )r   r   r   r   r   r   r   r   s      r   r   AXNode.from_jsont  si   &&tH~6i)YimqYqdCS>TU>TZ11!4>TUw{4:dN""4<04:dN""4<0BOSWBW))$}*=>]a6=o'##DM24P\`dPdl9KL9KA
,,Q/9KLjnKUY]K]d:6FG6Fx))!,6FGcgYkosYs 1 1 ; ;DAS<T U
 	
 z~
 	
 V
 MGs   E! E&E+r   )r%   r&   r'   r(   r)   r   r  r>   r   r  rC   r  r  r   r   r*   r   r+   r   r   r   r  r  ;  s      M AEO=D &*D
") &*D
") -1K)0 '+E#* <@J8? 9=I5< ?C;B, 
 
r   r  c               #     #    SS0n U v ng7f)z$
Disables the accessibility domain.
methodzAccessibility.disableNr   cmd_dictr   s     r   disabler$    s     
 	)H >D   
c               #     #    SS0n U v ng7f)z
Enables the accessibility domain which causes ``AXNodeId``'s to remain consistent between method calls.
This turns on accessibility for the page, which can impact performance until accessibility is disabled.
r!  zAccessibility.enableNr   r"  s     r   enabler'    s      	(H >Dr%  c              #    #    [        5       nU b  U R                  5       US'   Ub  UR                  5       US'   Ub  UR                  5       US'   Ub  X4S'   SUS.nUv nUS    Vs/ s H  n[        R                  U5      PM     sn$ s  snf 7f)a  
Fetches the accessibility node and partial accessibility tree for this DOM node, if it exists.

**EXPERIMENTAL**

:param node_id: *(Optional)* Identifier of the node to get the partial accessibility tree for.
:param backend_node_id: *(Optional)* Identifier of the backend node to get the partial accessibility tree for.
:param object_id: *(Optional)* JavaScript object id of the node wrapper to get the partial accessibility tree for.
:param fetch_relatives: *(Optional)* Whether to fetch this nodes ancestors, siblings and children. Defaults to true.
:returns: The ``Accessibility.AXNode`` for this DOM node, if it exists, plus its ancestors, siblings and children, if requested.
r  backendNodeIdobjectIdfetchRelativeszAccessibility.getPartialAXTree)r!  paramsnodes)r   r   r  r   )r  backend_node_id	object_idfetch_relativesr,  r#  r   r   s           r   get_partial_ax_treer1    s     " &F"??,x""1"9"9";&..0z"#2 2H >D)-g7AFQ777s   A$B&BBc               #  v   #    SS0n U v nUS    Vs/ s H  n[         R                  U5      PM     sn$ s  snf 7f)zE
Fetches the entire accessibility tree

**EXPERIMENTAL**

:returns: 
r!  zAccessibility.getFullAXTreer-  )r  r   )r#  r   r   s      r   get_full_ax_treer3    sD      	/H >D)-g7AFQ777s   949)r#   z0typing.Generator[T_JSON_DICT, T_JSON_DICT, None])NNNN)
r  ztyping.Optional[dom.NodeId]r.  r  r/  z'typing.Optional[runtime.RemoteObjectId]r0  r   r#   ?typing.Generator[T_JSON_DICT, T_JSON_DICT, typing.List[AXNode]])r#   r4  )
__future__r   utilr   r   dataclassesr   enumtyping r   r	   r$   r   Enumr.   rZ   rm   r   r   r   r   r   r  r$  r'  r1  r3  r   r   r   <module>r<     sA   # * !    9s 9$)) <		 &dii * @
 @
 @
F 
 
 
8 
 
 
* "
 "
 "
J6TYY 6r E
 E
 E
P 04>B=A15	8,8;8 ;8 /	8
 
G8D8r   