Skip to content

Conversation

@shihaohong
Copy link
Contributor

Adds assets to display different ways that toggle buttons can be implemented.

Fixes flutter/flutter#36862

Copy link
Contributor

@Piinks Piinks left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! The splash looks a little slow-mo in the animation. WDYT?

@shihaohong
Copy link
Contributor Author

Did you mean to reduce the tap duration? That crossed my mind and I experimented with 500ms, 750ms and 1 second (I ended up going with 750ms). I was thinking that it would help emphasize the tap behavior when developers look at it in the docs, but I don't have a preference either way.

@Piinks
Copy link
Contributor

Piinks commented Aug 15, 2019

Did you mean to reduce the tap duration? That crossed my mind and I experimented with 500ms, 750ms and 1 second (I ended up going with 750ms). I was thinking that it would help emphasize the tap behavior when developers look at it in the docs, but I don't have a preference either way.

That SGTM!

@shihaohong
Copy link
Contributor Author

Actually, I tried it again and 500ms did seem a little better :) I also took the opportunity to add UniqueKeys to each iteration since I noticed some that the state of the buttons between each example was being retained when it shouldn't be.

@shihaohong shihaohong merged commit 95b4eef into flutter:master Aug 15, 2019
@shihaohong shihaohong deleted the toggle-buttons branch August 15, 2019 19:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

ToggleButton API doc images

2 participants