
    ȯei                        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 d dlmZ erd dlmZ d dlmZmZ d d	lmZ  G d
 d      Zy)    )annotations)TYPE_CHECKINGcast)LayoutConfigvalidate_width)Text)gather_metrics)
clean_text)DeltaGenerator)TextAlignmentWidth)SupportsStrc                  X    e Zd Z ed      dddd	 	 	 	 	 	 	 	 	 dd       Zed	d       Zy)
	TextMixintextNcontentleft)helpwidthtext_alignmentc                   t               }t        |      |_        |r||_        t	        |d       t        ||      }| j                  j                  d||      S )a=	  Write text without Markdown or HTML parsing.

        For monospace text, use |st.code|_.

        .. |st.code| replace:: ``st.code``
        .. _st.code: https://docs.streamlit.io/develop/api-reference/text/st.code

        Parameters
        ----------
        body : str
            The string to display.

        help : str or None
            A tooltip that gets displayed next to the text. If this is ``None``
            (default), no tooltip is displayed.

            The tooltip can optionally contain GitHub-flavored Markdown,
            including the Markdown directives described in the ``body``
            parameter of ``st.markdown``.

        width : "content", "stretch", or int
            The width of the text element. This can be one of the following:

            - ``"content"`` (default): The width of the element matches the
              width of its content, but doesn't exceed the width of the parent
              container.
            - ``"stretch"``: The width of the element matches the width of the
              parent container.
            - An integer specifying the width in pixels: The element has a
              fixed width. If the specified width is greater than the width of
              the parent container, the width of the element matches the width
              of the parent container.

        text_alignment : "left", "center", "right", or "justify"
            The horizontal alignment of the text within the element. This can
            be one of the following:

            - ``"left"`` (default): Text is aligned to the left edge.
            - ``"center"``: Text is centered.
            - ``"right"``: Text is aligned to the right edge.
            - ``"justify"``: Text is justified (stretched to fill the available
              width with the last line left-aligned).

            .. note::
                For text alignment to have a visible effect, the element's
                width must be wider than its content. If you use
                ``width="content"`` with short text, the alignment may not be
                noticeable.

        Example
        -------
        >>> import streamlit as st
        >>>
        >>> st.text("This is text\n[and more text](that's not a Markdown link).")

        .. output::
            https://doc-text.streamlit.app/
            height: 220px

        T)allow_content)r   r   r   )layout_config)	TextProtor
   bodyr   r   r   dg_enqueue)selfr   r   r   r   
text_protor   s          Y/var/www/html/glpi_dashboard/venv/lib/python3.12/site-packages/streamlit/elements/text.pyr   zTextMixin.text   sT    J [
$T*
"JOuD1$5Pww
-PP    c                    t        d|       S )zGet our DeltaGenerator.r   )r   )r   s    r    r   zTextMixin.dgn   s     $d++r!   )
r   r   r   z
str | Noner   r   r   r   returnr   )r#   r   )__name__
__module____qualname__r	   r   propertyr    r!   r    r   r      sw    F
   (.LQLQ 	LQ
 LQ &LQ 
LQ LQ\ , ,r!   r   N)
__future__r   typingr   r   #streamlit.elements.lib.layout_utilsr   r   streamlit.proto.Text_pb2r   r   streamlit.runtime.metrics_utilr	   streamlit.string_utilr
   streamlit.delta_generatorr   r   r   streamlit.type_utilr   r   r(   r!   r    <module>r1      s1    # & L 6 9 ,8H/S, S,r!   