
    iz                        U d dl mZ d dlmZ d dlmZmZ  ee      j                  j                  dz  Z	g dZ
dZ e ee	      dz         Zi Zeeef   ed<   e
D ]  Z eegd	ged
      ee<    efdededefdZefdededefdZy)    )Path)Optional)FluentLocalizationFluentResourceLoaderlocales)uzruenr   z	/{locale}_localizationszmessages.ftlF)r   resource_idsresource_loaderuse_isolatingkeylangreturnc                     |t         vrt        }t         |   }|j                  | |r|nd      }|*|t        k7  r!t         t           j                  | |r|nd      }|xs d|  dS )z}
    Lokalizatsiya kaliti bo'yicha tarjimani olish.

    Foydalanish:
        get_text("welcome", lang="uz", name="Ali")
    N[])r   DEFAULT_LANGformat_value)r   r   kwargslocresults        ?/home/empty/Documents/pet_projects/kinoBot/bot/services/i18n.pyget_textr      sq     >!

CcV6>F~<#L1>>vV4F qQZ    c                     t        | |fi |S )zget_text uchun qisqa alias)r   )r   r   r   s      r   __r   0   s    C(((r   N)pathlibr   typingr   fluent.runtimer   r   __file__parentLOCALES_DIRSUPPORTED_LANGSr   str_loaderr   dict__annotations__r   r   r    r   r   <module>r+      s      C 8n##**Y6$ s;/+=
>02S,,- 2 D-$%	N4 $0  #  S  c  . * )C )s ) )r   