Skip to content

Commit 4f48038

Browse files
authored
fix(ui): fixed the leave button in app bar UI (#603)
* fixed the leave button in app bar UI * tweak
1 parent 1ffe69f commit 4f48038

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

packages/stream_video_flutter/lib/src/call_screen/call_content/call_app_bar.dart

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ class CallAppBar extends StatelessWidget implements PreferredSizeWidget {
1010
super.key,
1111
required this.call,
1212
this.showBackButton = true,
13+
this.showLeaveCallAction = true,
1314
this.elevation = 1,
1415
this.backgroundColor,
1516
this.onBackPressed,
@@ -25,6 +26,9 @@ class CallAppBar extends StatelessWidget implements PreferredSizeWidget {
2526
/// Whether to show the leading back button.
2627
final bool showBackButton;
2728

29+
/// Whether to show the leave call action button.
30+
final bool showLeaveCallAction;
31+
2832
/// The elevation for this [CallAppBar].
2933
final double elevation;
3034

@@ -78,7 +82,11 @@ class CallAppBar extends StatelessWidget implements PreferredSizeWidget {
7882
centerTitle: true,
7983
actions: actions ??
8084
<Widget>[
81-
LeaveCallOption(call: call),
85+
if (showLeaveCallAction)
86+
Transform.scale(
87+
scale: 0.8,
88+
child: LeaveCallOption(call: call),
89+
),
8290
],
8391
title: title ??
8492
Text(

0 commit comments

Comments
 (0)