Ë
    `§1hM  ã                   ó4   — d dl mZmZ d dlmZ  G d„ d«      Zy)é    )ÚDictÚUnion)Úcommand_builderc                   ó>   — e Zd ZdZd„ Zddefd„Zdeeef   ddfd„Z	y)	ÚWebExtensionz9
    BiDi implementation of the webExtension module.
    c                 ó   — || _         y ©N)Úconn)Úselfr
   s     úi/var/www/skyplay_api_hub/venv/lib/python3.12/site-packages/selenium/webdriver/common/bidi/webextension.pyÚ__init__zWebExtension.__init__   s	   € Øˆ�	ó    NÚreturnc                 óÌ   — t        d„ |||fD «       «      dk7  rt        d«      ‚|�d|dœ}n|�d|dœ}n|�d|dœ}d	i}| j                  j                  t	        d
|«      «      }|S )aª  Installs a web extension in the remote end.

        You must provide exactly one of the parameters.

        Parameters:
        -----------
            path: Path to an extension directory
            archive_path: Path to an extension archive file
            base64_value: Base64 encoded string of the extension archive

        Returns:
        -------
            Dict: A dictionary containing the extension ID.
        c              3   ó$   K  — | ]  }|d u–— Œ
 y ­wr	   © )Ú.0Úxs     r   ú	<genexpr>z'WebExtension.install.<locals>.<genexpr>.   s   è ø€ ÒI ˆq˜Œ}ÑIùs   ‚é   zCExactly one of path, archive_path, or base64_value must be providedÚpath)Útyper   ÚarchivePathÚbase64)r   ÚvalueÚextensionDatazwebExtension.install)ÚsumÚ
ValueErrorr
   Úexecuter   )r   r   Úarchive_pathÚbase64_valueÚextension_dataÚparamsÚresults          r   ÚinstallzWebExtension.install   s…   € ô ÑI t¨\¸<Ð&HÔIÓIÈQÒNÜÐbÓcÐcàÐØ&,°dÑ;‰NØÐ%Ø&3¸\ÑJ‰NØÐ%Ø&.¸ÑFˆNà! >Ð2ˆØ—‘×"Ñ"¤?Ð3IÈ6Ó#RÓSˆØˆr   Úextension_id_or_resultc                 óž   — t        |t        «      r|j                  d«      }n|}d|i}| j                  j	                  t        d|«      «       y)a!  Uninstalls a web extension from the remote end.

        Parameters:
        -----------
            extension_id_or_result: Either the extension ID as a string or the result dictionary
                                   from a previous install() call containing the extension ID.
        Ú	extensionzwebExtension.uninstallN)Ú
isinstanceÚdictÚgetr
   r   r   )r   r&   Úextension_idr#   s       r   Ú	uninstallzWebExtension.uninstall<   sH   € ô Ð,¬dÔ3Ø1×5Ñ5°kÓB‰Là1ˆLà˜|Ð,ˆØ�	‰	×Ñœ/Ð*BÀFÓKÕLr   )NNN)
Ú__name__Ú
__module__Ú__qualname__Ú__doc__r   r   r%   r   Ústrr-   r   r   r   r   r      s7   „ ñòñÈ$ó ð:M°°c¸4°iÑ0@ð MÀTô Mr   r   N)Útypingr   r   Ú%selenium.webdriver.common.bidi.commonr   r   r   r   r   ú<module>r5      s   ð÷$ å A÷3Mò 3Mr   