Best way to have responsive waiting indicator

I have an action that takes a while and need to indicate to the user that something is happening after clicking a button. This is what I’ve come up with:

Is there a better way to approach this?

1 Like

Hi @sdc50

I also need a button with a “waiting” or “active” indicator.

There might be various of your code to achieve this. But there is currently no builtin method in Panel to easily do this.

Feel free to post a feature request on Github or make a contribution via a PR.

There is also a discussion on how to improve the “loading” experience in Panel in general Feel free to join.

Just for the record. The awesome-panel-extensions package contains an alternative Material Design Button based on the MWC web components.

I can see that there is an extension of the MWC button that supports a loading spinner.

I might implement that one day.