Animate fade emote menu show/hide (#90)

This commit is contained in:
Tommy Chow 2022-06-29 19:37:56 -04:00
parent 390b4cca1e
commit 77400bbe42
2 changed files with 8 additions and 2 deletions

View file

@ -123,7 +123,12 @@ class Chat extends StatelessWidget {
curve: Curves.ease,
duration: const Duration(milliseconds: 200),
height: chatStore.assetsStore.showEmoteMenu ? MediaQuery.of(context).size.height / 3 : 0,
child: chatStore.assetsStore.showEmoteMenu ? EmoteMenu(chatStore: chatStore) : null,
child: AnimatedOpacity(
curve: Curves.ease,
opacity: chatStore.assetsStore.showEmoteMenu ? 1 : 0,
duration: const Duration(milliseconds: 200),
child: EmoteMenu(chatStore: chatStore),
),
onEnd: () => chatStore.scrollController.jumpTo(chatStore.scrollController.position.maxScrollExtent),
),
],

View file

@ -58,7 +58,8 @@ class _RecentEmotesPanelState extends State<RecentEmotesPanel> {
padding: EdgeInsets.symmetric(vertical: 5.0, horizontal: 10.0),
),
const Spacer(),
SizedBox(
Container(
padding: const EdgeInsets.symmetric(horizontal: 5.0),
height: 25,
child: Button(
padding: const EdgeInsets.all(0.0),