How to: change the text of a button while a SC state is 'executing'

Hey all,

One of our API’s might take a while to process - so I’d like to change the button text to ‘verifying’ or similar.

I already have a spinner within the button that shows it’s working, i’d just like to add a litle more UX to it.

I’ve looked at the inner text dynamic value - but I don’t seem to be able to apply a condition to show it, like you can do with a spinner. Any ideas?

Matt

Hi Matt,
You should be able to use dmx-text for this with a ternary expression:

dmx-text="{{api_id.state.executing ? 'Verifying' : 'Submit'}}"
1 Like

You can use:

{{serveraction1.state.executing ? 'Please wait' : 'Submit'}}
1 Like

Thank you both! Perfect!