AIdeaText commited on
Commit
b8da5e8
verified
1 Parent(s): 683e84d

Update modules/ui/ui.py

Browse files
Files changed (1) hide show
  1. modules/ui/ui.py +37 -5
modules/ui/ui.py CHANGED
@@ -77,6 +77,7 @@ eventos = [
77
  }
78
  ]
79
 
 
80
  def initialize_carousel_state():
81
  """Inicializa todas las variables de estado necesarias para el carrusel"""
82
  if not hasattr(st.session_state, 'current_event'):
@@ -216,9 +217,21 @@ def login_register_page(lang_code, t):
216
  div.row-widget.stHorizontalBlock {
217
  align-items: center;
218
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
219
  </style>
220
  """, unsafe_allow_html=True)
221
-
222
  ####################################################################################################################################
223
 
224
  # Pie de p谩gina legal (debe ir al final de la funci贸n)
@@ -285,13 +298,32 @@ def login_register_page(lang_code, t):
285
  left_column, right_column = st.columns([1, 3])
286
 
287
  with left_column:
288
- tab1, tab2 = st.tabs([landing_t['login'], landing_t['register']])
 
 
289
 
290
- with tab1:
291
- login_form(lang_code, landing_t)
 
 
 
 
 
 
 
 
 
 
 
 
292
 
293
- with tab2:
 
294
  register_form(lang_code, landing_t)
 
 
 
 
295
 
296
  with right_column:
297
  display_videos_and_info(lang_code, landing_t)
 
77
  }
78
  ]
79
 
80
+ #####################
81
  def initialize_carousel_state():
82
  """Inicializa todas las variables de estado necesarias para el carrusel"""
83
  if not hasattr(st.session_state, 'current_event'):
 
217
  div.row-widget.stHorizontalBlock {
218
  align-items: center;
219
  }
220
+ /* Resaltar el tab de registro */
221
+ .stTabs [data-baseweb="tab-list"] {
222
+ gap: 0px;
223
+ }
224
+ .stTabs [data-baseweb="tab"] {
225
+ padding: 10px 20px;
226
+ font-weight: 600;
227
+ }
228
+ .stTabs [aria-selected="true"] {
229
+ background-color: #1E3A8A;
230
+ color: white !important;
231
+ border-radius: 5px 5px 0 0;
232
+ }
233
  </style>
234
  """, unsafe_allow_html=True)
 
235
  ####################################################################################################################################
236
 
237
  # Pie de p谩gina legal (debe ir al final de la funci贸n)
 
298
  left_column, right_column = st.columns([1, 3])
299
 
300
  with left_column:
301
+ # ============================================
302
+ # FORMULARIO PRINCIPAL - REGISTRO PRIMERO
303
+ # ============================================
304
 
305
+ # Encabezado para resaltar la acci贸n principal
306
+ st.markdown("""
307
+ <div style='background: linear-gradient(135deg, #1E3A8A 0%, #3730A3 100%);
308
+ color: white; padding: 15px; border-radius: 10px 10px 0 0; text-align: center;'>
309
+ <h3 style='margin: 0;'>馃殌 Comienza Gratis</h3>
310
+ <p style='margin: 5px 0 0 0; opacity: 0.9; font-size: 0.9em;'>
311
+ Reg铆strate en 30 segundos
312
+ </p>
313
+ </div>
314
+ """, unsafe_allow_html=True)
315
+
316
+ # Crear tabs - REGISTRO siempre primero
317
+ tab_titles = [f"馃摑 {landing_t['register']}", f"馃攼 {landing_t['login']}"]
318
+ tabs = st.tabs(tab_titles)
319
 
320
+ # TAB 1: FORMULARIO DE REGISTRO (Siempre visible por defecto)
321
+ with tabs[0]:
322
  register_form(lang_code, landing_t)
323
+
324
+ # TAB 2: FORMULARIO DE LOGIN
325
+ with tabs[1]:
326
+ login_form(lang_code, landing_t)
327
 
328
  with right_column:
329
  display_videos_and_info(lang_code, landing_t)