feat: implementacao inicial do sistema LeadRadar
This commit is contained in:
@@ -0,0 +1,40 @@
|
||||
import streamlit as st
|
||||
from api_client import APIClient
|
||||
|
||||
def render_login_view(api_client: APIClient):
|
||||
st.markdown("<br><br>", unsafe_allow_html=True)
|
||||
c1, c2, c3 = st.columns([1, 2, 1])
|
||||
|
||||
with c2:
|
||||
with st.container(border=True):
|
||||
st.markdown(
|
||||
"""
|
||||
<div style="text-align: center; margin-bottom: 24px;">
|
||||
<h1 style="color: #58A6FF; margin-bottom: 4px;">📡 LeadRadar</h1>
|
||||
<p style="color: #8B949E; font-size: 0.95rem;">Prospecção Inteligente & Gestão Comercial B2B</p>
|
||||
</div>
|
||||
""", unsafe_allow_html=True
|
||||
)
|
||||
|
||||
email = st.text_input("E-mail de Acesso", placeholder="seu.email@empresa.com", key="login_email")
|
||||
password = st.text_input("Senha", type="password", placeholder="••••••••", key="login_password")
|
||||
|
||||
if st.button("🚀 Entrar no Sistema", use_container_width=True, type="primary"):
|
||||
if not email or not password:
|
||||
st.error("Por favor, preencha o e-mail e a senha.")
|
||||
else:
|
||||
with st.spinner("Autenticando credenciais..."):
|
||||
success, message = api_client.login(email, password)
|
||||
if success:
|
||||
st.success(message)
|
||||
st.rerun()
|
||||
else:
|
||||
st.error(message)
|
||||
|
||||
st.markdown(
|
||||
"""
|
||||
<div style="text-align: center; margin-top: 16px; font-size: 0.8rem; color: #8B949E;">
|
||||
LeadRadar Core v1.0 • Desenvolvido com Flask & Streamlit
|
||||
</div>
|
||||
""", unsafe_allow_html=True
|
||||
)
|
||||
Reference in New Issue
Block a user