xh / hoist-react

🏗️ ⚛️ The XH Hoist toolkit for React
https://xh.io
Apache License 2.0
24 stars 8 forks source link

Spinner component variations #2919

Open cnrudd opened 2 years ago

cnrudd commented 2 years ago

We are using this spinner component in a client app for two job states: PENDING and PROCESSING.

It would be nice to have a way to show a spinning gear for the PROCESSING state.

This could be accomplished in one of three ways:

  1. make a new component that uses the VM optimized gear
  2. modify component to take a prop option string for image name for images that are built in: 'default', 'gear', 'dotdotdot', etc
  3. modify component to take the actual image used as a prop

I'm in favor of #2, since it lets us make sure app developers do not load bonkers heavy animated gifs into the component, and we could always pretty easily add more image options once the pattern is in place.

diegoherrer4 commented 2 years ago

I can work on this