DEV Community


Discussion on: Should a button communicate the current state, the intended behavior, or both?

turnerj profile image
James Turner • Edited

I remember seeing something similar about toggle states on the UX Stack Exchange site. That question/answer talk about on/off options and indicating state etc.

While it is super convenient in one way to have the button be dual purposed, it is probably better to give more distinct actions and have them be more discoverable.

It might take up more space but maybe more:

Saved. Undo?

("Saved." would be text, "Undo" would be a link)

That way you give both the current state and the desired action.

With the following button, I do think you have more flexibility with it simply because of the ubiquity of that type of button across other systems (Twitter etc).

Forem Open with the Forem app