vtex / shoreline

Design System for the VTEX Admin, previously called Admin UI
https://shoreline.vtex.com
15 stars 0 forks source link

Add mouse leave event to pressed state of Button and IconButton #1701

Open davicostalf opened 3 days ago

davicostalf commented 3 days ago

Problem

In Figma, when assembling prototypes, sometimes buttons stay stuck in the pressed state after an action has been triggered. This may be due to a bug in Figma.

Solution

The best solution I could find is adding a mouse leave event to the pressed state that links to the default state.

Usage examples

I've already applied this interaction to the normal-sized secondary and tertiary IconButton.

Dependencies

No response

References

https://forum.figma.com/t/while-pressing-state-doesnt-reset-after-overlay-is-closed/3226