animate MemoryCoverWidget when it appears
This commit is contained in:
parent
a7e6c34b13
commit
3c3e55856f
1 changed files with 8 additions and 1 deletions
|
@ -1,6 +1,7 @@
|
|||
import "dart:async";
|
||||
|
||||
import 'package:flutter/material.dart';
|
||||
import "package:flutter_animate/flutter_animate.dart";
|
||||
import "package:photos/core/event_bus.dart";
|
||||
import "package:photos/events/memories_setting_changed.dart";
|
||||
import 'package:photos/models/memory.dart';
|
||||
|
@ -79,7 +80,13 @@ class _MemoriesWidgetState extends State<MemoriesWidget> {
|
|||
memories: collatedMemories[itemIndex],
|
||||
controller: _controller,
|
||||
offsetOfItem: offsetOfItem,
|
||||
);
|
||||
)
|
||||
.animate(delay: Duration(milliseconds: 75 * itemIndex))
|
||||
.fadeIn(
|
||||
duration: const Duration(milliseconds: 250),
|
||||
curve: Curves.easeInOutCubic,
|
||||
)
|
||||
.slideX(begin: 0.04, end: 0);
|
||||
},
|
||||
),
|
||||
);
|
||||
|
|
Loading…
Add table
Reference in a new issue