
    Mhs                    \    d Z ddlmZ ddlZddlZddlmZ ddlmZ ddlm	Z	 dd
ZdddZ
dS )z*
Utilities imported from ipython_genutils
    )annotationsN)dedent)indent)Listvalstrreturnc                "    t          | d          S )Nz    )_indent)r   s    T/var/www/html/test/jupyter/venv/lib/python3.11/site-packages/traitlets/utils/text.pyr   r      s    3    P   textncolsint	List[str]c                   t          j        dt           j                  }t          |                                           } |                    |           ddd         }g }t          j        dt           j                  }|D ]A}|                    |          t          j        ||          }|	                    |           B|S )a  Wrap multiple paragraphs to fit a specified width.

    This is equivalent to textwrap.wrap, but with support for multiple
    paragraphs, as separated by empty lines.

    Returns
    -------

    list of complete paragraphs, wrapped to fill `ncols` columns.
    z
\n(\s*\n)+N   z\n\s+)
recompile	MULTILINEr   stripsplitsearchtextwrapfillappend)r   r   paragraph_re
paragraphsout_ps	indent_reps          r   wrap_paragraphsr#      s     :mR\::L$<<D##D))##A#.JF
8R\22I   A&a''AaMr   )r   r   r	   r   )r   )r   r   r   r   r	   r   )__doc__
__future__r   r   r   r   r   r   typingr   r#    r   r   <module>r(      s     # " " " " " 				        & & & & & &                   r   