pcdoido2 commited on
Commit
8b00905
·
verified ·
1 Parent(s): a1f1c77

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -18
app.py CHANGED
@@ -51,24 +51,7 @@ st.header("📤 Upload de Arquivos")
51
 
52
  st.subheader("Selecione uma categoria:")
53
 
54
- # Checkboxes exclusivos
55
- selection = {cat: False for cat in CATEGORIES}
56
-
57
- cols = st.columns(len(CATEGORIES))
58
-
59
- for i, cat in enumerate(CATEGORIES):
60
- selection[cat] = cols[i].checkbox(cat)
61
-
62
- # Garante que só um esteja selecionado
63
- selected_cats = [cat for cat, checked in selection.items() if checked]
64
-
65
- if len(selected_cats) > 1:
66
- st.error("Selecione apenas uma categoria!")
67
- categoria = None
68
- elif len(selected_cats) == 0:
69
- categoria = None
70
- else:
71
- categoria = selected_cats[0]
72
 
73
  if categoria:
74
  uploaded_files = st.file_uploader(
 
51
 
52
  st.subheader("Selecione uma categoria:")
53
 
54
+ categoria = st.radio("Categoria:", CATEGORIES, index=None)
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
55
 
56
  if categoria:
57
  uploaded_files = st.file_uploader(