Changing text of button

I’m just wondering if there is a way to programmatically set the label of a streamlit button e.g.

import streamlit as st
btn = st.button("Click Me!")
if btn:
    btn.text = "Clicked"

I am doing it this way.

        if (btn):
                    '<style> .streamlit-button.primary-button{visibility: hidden;} .streamlit-button.primary-button:after{content: "Clicked"; visibility: visible; position:relative;-webkit-tap-highlight-color: rgba(38,39,48,0);box-sizing: border-box;font-family: inherit;font-size: inherit;overflow: visible;text-transform: none;display: inline-flex;align-items: center;justify-content: center;font-weight: 400;border-radius: .25rem;margin: 0;line-height: 1.6;color: #262730;cursor: pointer;padding: .25rem .75rem;background-color: #fff;border: 1px solid #e6eaf1; left: 0;}</style>', unsafe_allow_html=True)

I know it is not how it should be done, but it’s just my small personal project and I didn’t find a quick solution so I’m doing it this hacky way. I’m sure the quality can be improved with some more CSS fiddling.