o
    äe¼  ã                   @  sp   d Z ddlmZ ddlmZmZ ddlmZmZ ddl	m
Z
 ddlmZmZ edƒ eƒ G dd	„ d	ee
ƒƒZd
S )zgr.Interpretation() componenté    )Úannotations)ÚAnyÚLiteral)ÚdocumentÚset_documentation_group)ÚSimpleSerializable)Ú	ComponentÚ	_KeywordsÚ	componentc                   @  sB   e Zd ZdZddddœddd„Zdd„ Zeejdfddd„ƒZ	dS )ÚInterpretationzý
    Used to create an interpretation widget for a component.
    Preprocessing: this component does *not* accept input.
    Postprocessing: expects a {dict} with keys "original" and "interpretation".

    Guides: custom-interpretations-with-blocks
    TN©ÚvisibleÚelem_idÚelem_classesr
   r   r   Úboolr   ú
str | Noner   úlist[str] | str | Nonec                K  s$   t j| f|||dœ|¤Ž || _dS )aÙ  
        Parameters:
            component: Which component to show in the interpretation widget.
            visible: Whether or not the interpretation is visible.
            elem_id: An optional string that is assigned as the id of this component in the HTML DOM. Can be used for targeting CSS styles.
            elem_classes: An optional list of strings that are assigned as the classes of this component in the HTML DOM. Can be used for targeting CSS styles.
        r   N)r   Ú__init__r
   )Úselfr
   r   r   r   Úkwargs© r   úPD:\Projects\ConvertPro\env\Lib\site-packages\gradio/components/interpretation.pyr      s   ÿÿÿ
zInterpretation.__init__c                 C  s   | j  ¡ | j  ¡ dœS )N)r
   Zcomponent_props)r
   Zget_block_nameÚ
get_config)r   r   r   r   r   .   s   þzInterpretation.get_configÚvalueú(Any | Literal[_Keywords.NO_VALUE] | Noneúbool | Nonec                 C  s   || ddœS )NÚupdate)r   r   Z__type__r   )r   r   r   r   r   r   4   s   ýzInterpretation.update)r
   r   r   r   r   r   r   r   )r   r   r   r   )
Ú__name__Ú
__module__Ú__qualname__Ú__doc__r   r   Ústaticmethodr	   ZNO_VALUEr   r   r   r   r   r      s    úþr   N)r    Ú
__future__r   Útypingr   r   Zgradio_client.documentationr   r   Zgradio_client.serializingr   Zgradio.components.baser   r	   r   r   r   r   r   Ú<module>   s    