chore: Follow up inputbar design

pull/956/head
Krille 2 years ago
parent 49c1de8610
commit 93f0ace3cf
No known key found for this signature in database
GPG Key ID: E067ECD60F1A0652

@ -254,26 +254,26 @@ class ChatInputRow extends StatelessWidget {
), ),
), ),
), ),
if (PlatformInfos.platformCanRecord &&
controller.sendController.text.isEmpty)
Container( Container(
height: 56, height: 56,
alignment: Alignment.center, alignment: Alignment.center,
child: IconButton( child: AnimatedCrossFade(
crossFadeState: PlatformInfos.platformCanRecord &&
controller.sendController.text.isEmpty
? CrossFadeState.showFirst
: CrossFadeState.showSecond,
duration: FluffyThemes.animationDuration,
sizeCurve: FluffyThemes.animationCurve,
firstChild: IconButton(
tooltip: L10n.of(context)!.voiceMessage, tooltip: L10n.of(context)!.voiceMessage,
icon: const Icon(Icons.mic_none_outlined),
onPressed: controller.voiceMessageAction, onPressed: controller.voiceMessageAction,
icon: const Icon(Icons.mic_none_outlined),
), ),
), secondChild: IconButton(
if (!PlatformInfos.isMobile || tooltip: L10n.of(context)!.voiceMessage,
controller.sendController.text.isNotEmpty)
Container(
height: 56,
alignment: Alignment.center,
child: IconButton(
icon: const Icon(Icons.send_outlined),
onPressed: controller.send, onPressed: controller.send,
tooltip: L10n.of(context)!.send, icon: const Icon(Icons.send_outlined),
),
), ),
), ),
], ],

@ -283,6 +283,12 @@ class ChatView extends StatelessWidget {
), ),
alignment: Alignment.center, alignment: Alignment.center,
child: Material( child: Material(
clipBehavior: Clip.hardEdge,
color: Theme.of(context).brightness ==
Brightness.light
? Colors.white.withOpacity(0.95)
: Colors.black.withOpacity(0.87),
shape: RoundedRectangleBorder(
borderRadius: const BorderRadius.only( borderRadius: const BorderRadius.only(
bottomLeft: Radius.circular( bottomLeft: Radius.circular(
AppConfig.borderRadius, AppConfig.borderRadius,
@ -291,16 +297,10 @@ class ChatView extends StatelessWidget {
AppConfig.borderRadius, AppConfig.borderRadius,
), ),
), ),
clipBehavior: Clip.hardEdge, side: BorderSide(
color: Theme.of(context).brightness == color: Theme.of(context).dividerColor,
Brightness.light ),
? Colors.white ),
: Colors.black,
elevation: 4.0,
shadowColor: Theme.of(context)
.colorScheme
.onBackground
.withOpacity(0.33),
child: controller.room.isAbandonedDMRoom == true child: controller.room.isAbandonedDMRoom == true
? Row( ? Row(
mainAxisAlignment: mainAxisAlignment:

Loading…
Cancel
Save