
    Be                        d Z ddlmZ ddlmZmZmZmZmZm	Z	m
Z
mZmZmZmZmZ ddlmZ ddlmZ ddlmZmZmZmZmZmZmZ ddl m!Z!  G d	 d
e          Z" G d de          Z# G d de!          Z$ G d de!          Z% G d de!          Z& G d de!          Z' G d de          Z( G d de          Z) G d de          Z* G d de          Z G d de          Z G d d e          Z G d! d"e          Zd#S )$z
Custom bokeh Widget models.
    )
ButtonType)AnyBoolEitherEnumFloatInstanceIntListNullableOverrideStringTuple)Tooltip)Icon)ButtonCheckboxButtonGroupInputWidgetRadioButtonGroupSelectTextAreaInputWidget   )HTMLBoxc                   0   e Zd ZdZ edd          Z edd          Z edd          Z edd          Z ed	d
          Z	 edd          Z
 edd          Z edddd          Z edd          Z ed          Z ed          ZdS )PlayerzQ
    The Player widget provides controls to play through a number of frames.
    r   z Lower bound of the Player sliderhelp
   z Upper bound of the Player sliderzCurrent value of the player appz)Current throttled value of the player appr   z)Number of steps to advance the player by.i  zInterval between updatesze
        Current play direction of the Player (-1: playing in reverse,
        0: paused, 1: playing)oncereflectloopdefaultTz9Whether the loop controls
        radio buttons are showni     N)__name__
__module____qualname____doc__r
   startendvaluevalue_throttledstepinterval	directionr   loop_policyr   show_loop_controlsr   widthheight     4lib/python3.11/site-packages/panel/models/widgets.pyr   r      s         C:;;;E
#b9
:
:
:CC9:::Ec!"MNNNO3qBCCCDs37888HA " # # #I $vy&&AAAKd *# $ $ $ HS!!!EXc"""FFFr6   r   c            	           e Zd ZdZ eeg d          Z e ee e	ee                    d          Z
 edd          Z eed          Zd	S )
SingleSelectz Single-select widget.

    %
    List of options to disable.
    r$   r   a  
    Available selection options. Options may be provided either as a list of
    possible string values, or as a list of tuples, each of the form
    ``(value, label)``. In the latter case, the visible widget text for each
    value will be corresponding given label.
    r      z
    The number of visible options in the dropdown list. (This uses the
    ``select`` HTML element's ``size`` attribute. Some browsers might not
    show less than 3 options.)
    zInitial or selected value.N)r&   r'   r(   r)   r   r   disabled_optionsr   r   r   optionsr
   sizer   r,   r5   r6   r7   r9   r9   3   s          tC 3 	 	 	 d66&%%"7"788 @ 	 	 	G 3q   	 	 	D HV">???EEEr6   r9   c                       e Zd Z edd          Z edd          Z edd          Z edd          Z edd          Z	 e
d	d
          Z ed          Z eed          ZdS )AudioFzWhether the audio should loopr   zWhether the audio is pausedzWhether the audio is mutedz*Whether the audio is playing automaticallyr   z5
        The current time stamp of the audio playbackr%   J
        The frequency at which the time value is updated in milliseconds.Encoded file datazThe volume of the audio player.N)r&   r'   r(   r   r"   pausedmutedautoplayr   timer
   throttler   r,   r   volumer5   r6   r7   rA   rA   L   s        4?@@@DT%?@@@FD=>>>EtE PQQQH5 8 9 9 9D s3 M N N NH C()))EXe"GHHHFFFr6   rA   c                       e Zd Z edd          Z edd          Z edd          Z edd          Z edd          Z	 e
d	d
          Z ed          Z e
d          ZdS )VideoFzWhether the video should loopr   Whether the video is pausedzWhether the video is mutedz*Whether the video is playing automaticallyr   z5
        The current time stamp of the video playbackr%   rB   rC   zThe volume of the video player.N)r&   r'   r(   r   r"   rD   rE   rF   r   rG   r
   rH   r   r,   rI   r5   r6   r7   rK   rK   a   s        4?@@@DT%?@@@FD=>>>EtE PQQQH5 8 9 9 9D s3 M N N NH C()))ES;<<<FFFr6   rK   c                       e Zd Z eddd          Z edd          Z edd          Z ee	d          Z
 ed	          Z ed
          Z ed          ZdS )VideoStreampngjpegr#   FrL   r   z8On change generate a snapshot of the current video framezq
        The timeout between snapshots (if None snapshot only generated
        when snapshot property is changedzSnapshot Data   i@  N)r&   r'   r(   r   formatr   rD   snapshotr   r
   timeoutr   r,   r   r4   r3   r5   r6   r7   rN   rN   v   s        T%///FT%?@@@FtE ^___Hhs "- . . .G C()))EXc"""FHS!!!EEEr6   rN   c                       e Zd Z edd          Z edddddd	d
dd	  	        Z edd          Z e	ed          Z
 ee          ZdS )ProgressTzWhether to animate the barr   primary	secondarysuccessinfodangerwarninglightdarkr#   d   zMaximum valuezCurrent valueN)r&   r'   r(   r   activer   	bar_colorr
   maxr   r,   r   r   cssr5   r6   r7   rV   rV      s        T$=>>>FYYy'69N N NI #c+
,
,
,CHS2333E
$v,,CCCr6   rV   c                      e Zd Z edd          Z eed          Z edd          Z	 e
d          Z edd          Z e ee          d	          Z e
d
d          Z e
d          Z edd          Z ed
          ZdS )FileDownloadFzWhether to download on clickr   z7
    A style for the button, signifying it's role.
    r   zM
    A private property that used to trigger ``on_click`` event handler.
    zEncoded URI data.z!Whether the data is pre-embedded.z
    An optional image appearing to the left of button's text. An instance of
    :class:`~bokeh.models.Icon` (such as :class:`~bokeh.models.BuiltinIcon`,
    :class:`~bokeh.models.SVGIcon`, or :class:`~bokeh.models.TablerIcon`).`
     z)The text label for the button to display.zFilename to use on downloadz:
    A private property to create and click the link.
    r#   N)r&   r'   r(   r   autor   r   button_typer
   clicksr   dataembedr   r	   r   iconlabelfilename
_transfersr   titler5   r6   r7   re   re      s	       4>???D$z ) 	 	 	K S  	 	 	F 6.///DDDEEEE8HHTNN * 	 	 	D F2KLLLEv<===HQ  	 	 	J HR   EEEr6   re   c                   F    e Zd ZdZ eeg d          Z ed          ZdS )CustomSelectzq Custom widget that extends the base Bokeh Select
    by adding a parameter to disable one or more options.

    r:   r;   r   r#   N)	r&   r'   r(   r)   r   r   r=   r
   r?   r5   r6   r7   rr   rr      sK          tC 3 	 	 	 3q>>>DDDr6   rr   c                   @    e Zd Z ee edd          d          ZdS )TooltipIconz	Help textright)contentpositionzThe tooltip held by the iconr;   N)r&   r'   r(   r	   r   descriptionr5   r6   r7   rt   rt      s<        (g>>>/  KKKr6   rt   c                   R    e Zd Z edd          Z e e            d          ZdS )r   Fzl
        Whether the text area should automatically grow vertically to
        accommodate the current text.r;   z[
        Maximum number of rows the input area can grow to if auto_grow
        is enabled.r   N)r&   r'   r(   r   	auto_growr   r
   max_rowsr5   r6   r7   r   r      sQ        )  I x %   HHHr6   r   c                   :    e Zd Z e ee          d          ZdS )r   
    A tooltip with plain text or rich HTML contents, providing general help or
    description of a widget's or component's function.
    r   Nr&   r'   r(   r   r	   r   tooltipr5   r6   r7   r   r      5        hxx(( 0 	 	 	GGGr6   r   c                   :    e Zd Z e ee          d          ZdS )r   r}   r   Nr~   r5   r6   r7   r   r      r   r6   r   c                   :    e Zd Z e ee          d          ZdS )r   r}   r   Nr~   r5   r6   r7   r   r      r   r6   r   N)+r)   bokeh.core.enumsr   bokeh.core.propertiesr   r   r   r   r   r	   r
   r   r   r   r   r   bokeh.models.uir   bokeh.models.ui.iconsr   bokeh.models.widgetsr   bkButtonr   bkCheckboxButtonGroupr   r   bkRadioButtonGroupr   r   BkTextAreaInputr   layoutr   r   r9   rA   rK   rN   rV   re   rr   rt   r5   r6   r7   <module>r      s    ( ' ' ' ' '                            $ # # # # # & & & & & &                       # # # # #V # # #>@ @ @ @ @; @ @ @2I I I I IG I I I*= = = = =G = = =*" " " " "' " " "&    w   ! ! ! ! !; ! ! !B	 	 	 	 	6 	 	 	    &       O   	 	 	 	 	X 	 	 		 	 	 	 	/ 	 	 		 	 	 	 	) 	 	 	 	 	r6   