Repository navigation
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
There was a problem hiding this comment.
The behavior looks good! My main request is to let the list's own animated win instead of being overwritten by ion-fab.
One more thing outside the diff: the main button's animated now also controls the list reveal, but its JSDoc in fab-button.tsx only describes the button's own transition. Could it say something like "When used as the main button of an ion-fab, this also controls whether the buttons in its ion-fab-list show one at a time, unless the list sets its own animated.
brandyscarney
left a comment
There was a problem hiding this comment.
Thanks for the changes! Looks good.
thetaPC
left a comment
There was a problem hiding this comment.
LGTM, minor suggestions
"Setting it on the main button is enough" reads as if it turns off all motion in the list. The buttons in the list still scale and fade in, just all at once. Could that bullet say each button in the list still needs animated="false" to skip its own transition?
| * If `true`, the fab buttons in the list will show one at a time | ||
| * when the list opens. If not set, it follows the main fab button's | ||
| * `animated`. | ||
| */ |
There was a problem hiding this comment.
The docs table will show no default for this prop, since it has none. The JSDoc also doesn't say what an unset list does outside an ion-fab, so a reader can't tell that it still shows its buttons one at a time:
| * If `true`, the fab buttons in the list will show one at a time | |
| * when the list opens. If not set, it follows the main fab button's | |
| * `animated`. | |
| */ | |
| * If `true`, the fab buttons in the list will show one at a time | |
| * when the list opens. If not set, it follows the `animated` | |
| * property of the main fab button in its `ion-fab`, or `true` | |
| * when the list is not in an `ion-fab`. |
Issue number: internal
What is the current behavior?
Currently, a fab list shows its buttons one at a time when it opens, even when the main fab button has
animated="false", the globalanimatedconfig isfalse, or the user prefers reduced motion. Settinganimatedon the list buttons doesn't help because it only covers their own transitions.What is the new behavior?
animatedprop toion-fab-list. When it'sfalse, every button in the list shows at once.animatedconfig isfalseor the user prefers reduced motion.ion-fab, the list follows the main fab button'sanimatedunless the list sets its own, so setting it on the main button is enough.Does this introduce a breaking change?
But it is a new feature, which is why it's pointed at
feature-9.1Other information
This is the follow-up from Brandy's review on #31743.
The fab on the right of the fab button animation test page has
animated="false"on its main button, so its list should now open all at once:Fab button animation test page