How do you apply style when state is executing?

I know how to make the button disabled when a form state is executing.

How about changing the button text or changing the style. Is that possible with Wappler?

Ideally, I want to change the button style to cursor:not-allowed when the form is executing. But I can’t find a way to hook it with the form state.

The easiest way to do this would be to create a CSS class like:

.not-allowed {
    cursor:not-allowed;
}

and use the dynamic attributes > class toggle and toggle this class when state.executing

If you want to do this using the style attribute, it will be:

Name

cursor

Value:

state.executing ? 'not-allowed' : 'pointer'
2 Likes

Very nice. Thank you @Teodor