mirror of
https://gitlab.com/famedly/fluffychat.git
synced 2024-11-27 23:09:35 +01:00
fix: Typing indicator too large
This commit is contained in:
parent
db742fad6c
commit
c64c988910
@ -14,7 +14,7 @@ class TypingIndicators extends StatelessWidget {
|
|||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
final typingUsers = controller.room.typingUsers
|
final typingUsers = controller.room.typingUsers
|
||||||
..removeWhere((u) => u.stateKey == Matrix.of(context).client.userID);
|
..removeWhere((u) => u.stateKey == Matrix.of(context).client.userID);
|
||||||
const topPadding = 24.0;
|
const topPadding = 20.0;
|
||||||
const bottomPadding = 4.0;
|
const bottomPadding = 4.0;
|
||||||
|
|
||||||
return Container(
|
return Container(
|
||||||
@ -23,9 +23,7 @@ class TypingIndicators extends StatelessWidget {
|
|||||||
child: AnimatedContainer(
|
child: AnimatedContainer(
|
||||||
constraints:
|
constraints:
|
||||||
const BoxConstraints(maxWidth: FluffyThemes.columnWidth * 2.5),
|
const BoxConstraints(maxWidth: FluffyThemes.columnWidth * 2.5),
|
||||||
height: typingUsers.isEmpty
|
height: typingUsers.isEmpty ? 0 : Avatar.defaultSize + bottomPadding,
|
||||||
? 0
|
|
||||||
: Avatar.defaultSize + bottomPadding + topPadding,
|
|
||||||
duration: const Duration(milliseconds: 300),
|
duration: const Duration(milliseconds: 300),
|
||||||
curve: Curves.bounceInOut,
|
curve: Curves.bounceInOut,
|
||||||
alignment: controller.filteredEvents.isNotEmpty &&
|
alignment: controller.filteredEvents.isNotEmpty &&
|
||||||
@ -83,7 +81,7 @@ class TypingIndicators extends StatelessWidget {
|
|||||||
bottomRight: Radius.circular(AppConfig.borderRadius),
|
bottomRight: Radius.circular(AppConfig.borderRadius),
|
||||||
),
|
),
|
||||||
child: Padding(
|
child: Padding(
|
||||||
padding: const EdgeInsets.all(16),
|
padding: const EdgeInsets.all(8),
|
||||||
child: typingUsers.isEmpty
|
child: typingUsers.isEmpty
|
||||||
? null
|
? null
|
||||||
: Image.asset('assets/typing.gif', height: 12),
|
: Image.asset('assets/typing.gif', height: 12),
|
||||||
|
Loading…
Reference in New Issue
Block a user