Ë
    ÔAHj~  ã                  óJ   — d dl mZ d dlmZ d dlmZ d dlmZ  G d„ de«      Zy)é    )Úannotations)ÚFraction)Ú
NamedTuple)ÚSizec                  ób   — e Zd ZU dZdZded<   dZded<   dZded<   dZded<   dd„Z	dd	„Z
dd
„Zy)ÚExtremaz)Specifies minimum and maximum dimensions.NzFraction | NoneÚ	min_widthÚ	max_widthÚ
min_heightÚ
max_heightc                óN   — | dd \  }}|t        ||«      }|t        ||«      }|S )z—Apply width extrema.

        Args:
            width: Width value.

        Returns:
            Width, clamped between minimum and maximum.

        Né   ©ÚmaxÚmin)ÚselfÚwidthr	   r
   s       úH/root/tools/cai/cai_env/lib/python3.12/site-packages/textual/_extrema.pyÚapply_widthzExtrema.apply_width   s=   € ð  $ B Q˜xÑˆ	9ØÐ Ü˜˜yÓ)ˆEØÐ Ü˜˜yÓ)ˆEØˆó    c                óN   — | dd \  }}|t        ||«      }|t        ||«      }|S )z›Apply height extrema.

        Args:
            height: Height value.

        Returns:
            Height, clamped between minimum and maximum.

        r   Nr   )r   Úheightr   r   s       r   Úapply_heightzExtrema.apply_height"   s=   € ð "& a b Ñˆ
JØÐ!Ü˜ Ó,ˆFØÐ!Ü˜ Ó,ˆFØˆr   c           
     óž   — t        t        | j                  t        |«      «      «      t        | j	                  t        |«      «      «      «      S )z»Apply extrema to integer dimensions.

        Args:
            width: Integer width.
            height: Integer height.

        Returns:
            Size with extrema applied.
        )r   Úintr   r   r   )r   r   r   s      r   Úapply_dimensionszExtrema.apply_dimensions3   s@   € ô Ü× Ñ ¤¨%£Ó1Ó2Ü×!Ñ!¤(¨6Ó"2Ó3Ó4ó
ð 	
r   )r   r   Úreturnr   )r   r   r   r   )r   r   r   r   r   r   )Ú__name__Ú
__module__Ú__qualname__Ú__doc__r	   Ú__annotations__r
   r   r   r   r   r   © r   r   r   r   	   s<   … Ù3à!%€IˆÓ%Ø!%€IˆÓ%Ø"&€JÓ&Ø"&€JÓ&óó"ô"
r   r   N)	Ú
__future__r   Ú	fractionsr   Útypingr   Útextual.geometryr   r   r#   r   r   ú<module>r(      s   ðÝ "å Ý å !ô7
ˆjõ 7
r   