Skip to content

Instantly share code, notes, and snippets.

@fredgrott
Created October 20, 2025 18:37
Show Gist options
  • Save fredgrott/47617a17699251964b94494801d84181 to your computer and use it in GitHub Desktop.
Save fredgrott/47617a17699251964b94494801d84181 to your computer and use it in GitHub Desktop.
motor, individual phase per motion
import 'package:motor/motor.dart';
final complexSequence = MotionSequence<AppState, ButtonStyle>.statesWithMotions({
.loading: (loadingStyle, .smoothSpring()),
.error: (errorStyle, .bouncySpring()), // Extra bounce for attention
.success: (successStyle, .curved(Duration(seconds: 2), Curves.ease)),
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment