Horizontally align text with two buttons 'st.write()' and 'st.button()'

I’m having trouble aligning the button with the text

create, list_users = st.tabs(["Criação de usuários", "Lista de usuários"])
with list_users:
        blobs = db.collection("users").where(filter=FieldFilter("company", "==", st.session_state["company"])).stream()

        with st.form("Usuários"):
            r, m, l = st.columns([1, 1, 1])
            for blob in blobs:
                with r:
                    st.caption(blob.to_dict()["email"])
                with m:
                    if blob.to_dict()["disabled"]:
                        if st.form_submit_button("🟢 Ativar", key=blob.id + "desab"):
                            desabilited(id=blob.to_dict()["uid"])
                    if not blob.to_dict()["disabled"]:
                        if st.form_submit_button("🔴 Desativar", key=blob.id + "desativar"):
                            desabilited(id=blob.to_dict()["uid"])
                with l:
                    if st.form_submit_button("🗑️ Deletar", key=blob.id + "del", type="primary"):
                        delet_user(id=blob.to_dict()["uid"], email=blob.to_dict()["email"])

Having a similar issue… 200+ views and no replies… not a good thing…

Check for “vertical_alignment” in st.columns.

… 200+ views and no replies…

You can make a PR, or just say ‘up’. Stop complaining :slight_smile:
(Carefull you got the dot-dot-dot syndrome)

@Faltawer thanks for the reply, I will check that out, someone else just suggested the same just now in a different post… oh, and I was not complaining, I was just thinking that if there were no replies after 200+ views, the likelyhood of this issue having a solution was probably low…

Btw, I am not sure what you mean by the dot syndrome, but that’s fine… cheers!

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.