import streamlit as st
from config import ENV
from utils.translations import _
from utils.persistance import get_session_id


def afficher_entete():
    header = f"""
    <header role="banner" aria-labelledby="entete-header">
        <div class='wide-header'>
            <p id='entete-header' class='titre-header'>{_("header.title")}</p>
    """

    if ENV == "dev":
        header += f"<p>🔧 {_("app.dev_mode")} Session : {get_session_id()}</p>"
    else:
        header += f"<p>{_("header.subtitle")}</p>"

    header += """
        </div>
    </header>
    """

    st.markdown(header, unsafe_allow_html=True)
