From f2028f558b7f9abe931a604277ee74826cf36f49 Mon Sep 17 00:00:00 2001 From: cloudwebrtc Date: Thu, 24 Oct 2024 11:23:16 +0800 Subject: [PATCH] rename files. --- lib/livekit_components.dart | 12 +-- .../context/{chat.dart => chat_context.dart} | 0 ..._device.dart => media_device_context.dart} | 4 +- ...ticipant.dart => participant_context.dart} | 0 .../context/{room.dart => room_context.dart} | 2 +- .../{track.dart => track_context.dart} | 0 lib/src/ui/{room => builder}/control_bar.dart | 9 +- lib/src/ui/builder/media_device.dart | 28 +++++++ lib/src/ui/{room => builder}/room.dart | 2 +- lib/src/ui/{room => builder}/toast.dart | 2 +- .../buttons/audio_output_select_button.dart | 4 +- lib/src/ui/buttons/camera_select_button.dart | 4 +- lib/src/ui/buttons/chat_toggle.dart | 2 +- lib/src/ui/buttons/disconnect_button.dart | 2 +- lib/src/ui/buttons/join_button.dart | 2 +- .../ui/buttons/microphone_select_button.dart | 4 +- lib/src/ui/buttons/screenshare_toggle.dart | 4 +- lib/src/ui/chat/chat_widget.dart | 4 +- lib/src/ui/debug/track_stats_widget.dart | 4 +- .../connection_quality_indicator.dart | 2 +- .../participant/e2e_encryption_indicator.dart | 2 +- lib/src/ui/participant/focus_toggle.dart | 4 +- .../ui/participant/is_speaking_indicator.dart | 4 +- lib/src/ui/participant/no_track_widget.dart | 2 +- lib/src/ui/participant/participant_loop.dart | 6 +- .../participant_muted_indicator.dart | 2 +- lib/src/ui/participant/participant_name.dart | 4 +- .../participant/participant_status_bar.dart | 4 +- .../participant/participant_tile_widget.dart | 2 +- .../ui/participant/video_track_widget.dart | 2 +- lib/src/ui/prejoin/camera_preview.dart | 2 +- lib/src/ui/prejoin/prejoin.dart | 84 +++++++++---------- 32 files changed, 117 insertions(+), 92 deletions(-) rename lib/src/context/{chat.dart => chat_context.dart} (100%) rename lib/src/context/{media_device.dart => media_device_context.dart} (99%) rename lib/src/context/{participant.dart => participant_context.dart} (100%) rename lib/src/context/{room.dart => room_context.dart} (99%) rename lib/src/context/{track.dart => track_context.dart} (100%) rename lib/src/ui/{room => builder}/control_bar.dart (89%) create mode 100644 lib/src/ui/builder/media_device.dart rename lib/src/ui/{room => builder}/room.dart (93%) rename lib/src/ui/{room => builder}/toast.dart (98%) diff --git a/lib/livekit_components.dart b/lib/livekit_components.dart index 8925506..bafc092 100644 --- a/lib/livekit_components.dart +++ b/lib/livekit_components.dart @@ -1,8 +1,8 @@ library livekit_components; -export 'src/context/room.dart'; -export 'src/context/participant.dart'; -export 'src/context/track.dart'; +export 'src/context/room_context.dart'; +export 'src/context/participant_context.dart'; +export 'src/context/track_context.dart'; export 'src/ui/debug/track_stats_widget.dart'; export 'src/types/theme.dart'; export 'src/types/types.dart'; @@ -13,9 +13,9 @@ export 'src/ui/buttons/chat_toggle.dart'; export 'src/ui/buttons/join_button.dart'; export 'src/ui/buttons/screenshare_toggle.dart'; export 'src/ui/chat/chat_widget.dart'; -export 'src/ui/room/room.dart'; -export 'src/ui/room/toast.dart'; -export 'src/ui/room/control_bar.dart'; +export 'src/ui/builder/room.dart'; +export 'src/ui/builder/toast.dart'; +export 'src/ui/builder/control_bar.dart'; export 'src/ui/participant/participant_tile_widget.dart'; export 'src/ui/participant/participant_loop.dart'; export 'src/ui/participant/is_speaking_indicator.dart'; diff --git a/lib/src/context/chat.dart b/lib/src/context/chat_context.dart similarity index 100% rename from lib/src/context/chat.dart rename to lib/src/context/chat_context.dart diff --git a/lib/src/context/media_device.dart b/lib/src/context/media_device_context.dart similarity index 99% rename from lib/src/context/media_device.dart rename to lib/src/context/media_device_context.dart index 3690381..2464569 100644 --- a/lib/src/context/media_device.dart +++ b/lib/src/context/media_device_context.dart @@ -8,7 +8,7 @@ import 'package:livekit_client/livekit_client.dart'; import 'package:provider/provider.dart'; import '../ui/debug/logger.dart'; -import 'room.dart'; +import 'room_context.dart'; class MediaDeviceContext extends ChangeNotifier { /// Get the [MediaDeviceContext] from the [context]. @@ -106,8 +106,8 @@ class MediaDeviceContext extends ChangeNotifier { deviceId: device.deviceId, ), ); - selectedVideoInputDeviceId = device.deviceId; } + selectedVideoInputDeviceId = device.deviceId; notifyListeners(); } diff --git a/lib/src/context/participant.dart b/lib/src/context/participant_context.dart similarity index 100% rename from lib/src/context/participant.dart rename to lib/src/context/participant_context.dart diff --git a/lib/src/context/room.dart b/lib/src/context/room_context.dart similarity index 99% rename from lib/src/context/room.dart rename to lib/src/context/room_context.dart index 7c67bd2..fd26072 100644 --- a/lib/src/context/room.dart +++ b/lib/src/context/room_context.dart @@ -6,7 +6,7 @@ import 'package:livekit_client/livekit_client.dart'; import 'package:provider/provider.dart'; import '../ui/debug/logger.dart'; -import 'chat.dart'; +import 'chat_context.dart'; class RoomContext extends ChangeNotifier with ChatContextMixin { /// Get the [RoomContext] from the [context]. diff --git a/lib/src/context/track.dart b/lib/src/context/track_context.dart similarity index 100% rename from lib/src/context/track.dart rename to lib/src/context/track_context.dart diff --git a/lib/src/ui/room/control_bar.dart b/lib/src/ui/builder/control_bar.dart similarity index 89% rename from lib/src/ui/room/control_bar.dart rename to lib/src/ui/builder/control_bar.dart index 9e3b87a..a50cbed 100644 --- a/lib/src/ui/room/control_bar.dart +++ b/lib/src/ui/builder/control_bar.dart @@ -3,14 +3,14 @@ import 'package:flutter/material.dart'; import 'package:livekit_client/livekit_client.dart'; import 'package:provider/provider.dart'; -import '../../context/media_device.dart'; -import '../../context/room.dart'; +import '../../context/room_context.dart'; import '../buttons/audio_output_select_button.dart'; import '../buttons/camera_select_button.dart'; import '../buttons/chat_toggle.dart'; import '../buttons/disconnect_button.dart'; import '../buttons/microphone_select_button.dart'; import '../buttons/screenshare_toggle.dart'; +import 'media_device.dart'; class ControlBar extends StatelessWidget { const ControlBar({ @@ -42,9 +42,8 @@ class ControlBar extends StatelessWidget { ), child: Consumer( builder: (context, roomCtx, child) { - return ChangeNotifierProvider( - create: (_) => MediaDeviceContext(roomCtx: roomCtx), - child: Wrap( + return MediaDevices( + builder: (context, mediaDeviceCtx) => Wrap( alignment: WrapAlignment.center, spacing: 6, runSpacing: 6, diff --git a/lib/src/ui/builder/media_device.dart b/lib/src/ui/builder/media_device.dart new file mode 100644 index 0000000..bdec0f6 --- /dev/null +++ b/lib/src/ui/builder/media_device.dart @@ -0,0 +1,28 @@ +import 'package:flutter/material.dart'; + +import 'package:provider/provider.dart'; + +import '../../context/media_device_context.dart'; +import '../../context/room_context.dart'; + +typedef MediaDevicesBuilder = Widget Function( + BuildContext context, MediaDeviceContext mediaDeviceContext); + +class MediaDevices extends StatelessWidget { + const MediaDevices({super.key, required this.builder}); + + final MediaDevicesBuilder builder; + + @override + Widget build(BuildContext context) { + return Consumer( + builder: (context, roomCtx, child) => ChangeNotifierProvider( + create: (_) => MediaDeviceContext(roomCtx: roomCtx), + child: Consumer( + builder: (context, mediaDeviceCtx, child) => + builder(context, mediaDeviceCtx), + ), + ), + ); + } +} diff --git a/lib/src/ui/room/room.dart b/lib/src/ui/builder/room.dart similarity index 93% rename from lib/src/ui/room/room.dart rename to lib/src/ui/builder/room.dart index afc7dc7..96d2c4d 100644 --- a/lib/src/ui/room/room.dart +++ b/lib/src/ui/builder/room.dart @@ -2,7 +2,7 @@ import 'package:flutter/material.dart'; import 'package:provider/provider.dart'; -import '../../context/room.dart'; +import '../../context/room_context.dart'; typedef RoomContextBuilder = Widget Function( BuildContext context, RoomContext roomCtx); diff --git a/lib/src/ui/room/toast.dart b/lib/src/ui/builder/toast.dart similarity index 98% rename from lib/src/ui/room/toast.dart rename to lib/src/ui/builder/toast.dart index 0f28245..c32fb81 100644 --- a/lib/src/ui/room/toast.dart +++ b/lib/src/ui/builder/toast.dart @@ -5,7 +5,7 @@ import 'package:flutter/material.dart' hide ConnectionState; import 'package:livekit_client/livekit_client.dart'; import 'package:provider/provider.dart'; -import '../../context/room.dart'; +import '../../context/room_context.dart'; class ToastWidget extends StatefulWidget { const ToastWidget({ diff --git a/lib/src/ui/buttons/audio_output_select_button.dart b/lib/src/ui/buttons/audio_output_select_button.dart index a9cecdf..b11d744 100644 --- a/lib/src/ui/buttons/audio_output_select_button.dart +++ b/lib/src/ui/buttons/audio_output_select_button.dart @@ -4,8 +4,8 @@ import 'package:livekit_client/livekit_client.dart'; import 'package:provider/provider.dart'; import 'package:responsive_builder/responsive_builder.dart'; -import '../../context/media_device.dart'; -import '../../context/room.dart'; +import '../../context/media_device_context.dart'; +import '../../context/room_context.dart'; import '../../types/theme.dart'; class AudioOutputSelectButton extends StatelessWidget { diff --git a/lib/src/ui/buttons/camera_select_button.dart b/lib/src/ui/buttons/camera_select_button.dart index 5f4d12d..64972a4 100644 --- a/lib/src/ui/buttons/camera_select_button.dart +++ b/lib/src/ui/buttons/camera_select_button.dart @@ -4,8 +4,8 @@ import 'package:livekit_client/livekit_client.dart'; import 'package:provider/provider.dart'; import 'package:responsive_builder/responsive_builder.dart'; -import '../../context/media_device.dart'; -import '../../context/room.dart'; +import '../../context/media_device_context.dart'; +import '../../context/room_context.dart'; import '../../types/theme.dart'; class CameraSelectButton extends StatelessWidget { diff --git a/lib/src/ui/buttons/chat_toggle.dart b/lib/src/ui/buttons/chat_toggle.dart index 134e490..236e0a4 100644 --- a/lib/src/ui/buttons/chat_toggle.dart +++ b/lib/src/ui/buttons/chat_toggle.dart @@ -4,7 +4,7 @@ import 'package:livekit_client/livekit_client.dart'; import 'package:provider/provider.dart'; import 'package:responsive_builder/responsive_builder.dart'; -import '../../context/room.dart'; +import '../../context/room_context.dart'; import '../../types/theme.dart'; class ChatToggle extends StatelessWidget { diff --git a/lib/src/ui/buttons/disconnect_button.dart b/lib/src/ui/buttons/disconnect_button.dart index f1d11f5..e4b28ae 100644 --- a/lib/src/ui/buttons/disconnect_button.dart +++ b/lib/src/ui/buttons/disconnect_button.dart @@ -4,7 +4,7 @@ import 'package:livekit_client/livekit_client.dart'; import 'package:provider/provider.dart'; import 'package:responsive_builder/responsive_builder.dart'; -import '../../context/room.dart'; +import '../../context/room_context.dart'; class DisconnectButton extends StatelessWidget { const DisconnectButton( diff --git a/lib/src/ui/buttons/join_button.dart b/lib/src/ui/buttons/join_button.dart index 17b2a92..c52617a 100644 --- a/lib/src/ui/buttons/join_button.dart +++ b/lib/src/ui/buttons/join_button.dart @@ -2,7 +2,7 @@ import 'package:flutter/material.dart'; import 'package:provider/provider.dart'; -import '../../context/room.dart'; +import '../../context/room_context.dart'; import '../../types/theme.dart'; class JoinButton extends StatelessWidget { diff --git a/lib/src/ui/buttons/microphone_select_button.dart b/lib/src/ui/buttons/microphone_select_button.dart index aa8df93..6362f5b 100644 --- a/lib/src/ui/buttons/microphone_select_button.dart +++ b/lib/src/ui/buttons/microphone_select_button.dart @@ -4,8 +4,8 @@ import 'package:livekit_client/livekit_client.dart'; import 'package:provider/provider.dart'; import 'package:responsive_builder/responsive_builder.dart'; -import '../../context/media_device.dart'; -import '../../context/room.dart'; +import '../../context/media_device_context.dart'; +import '../../context/room_context.dart'; import '../../types/theme.dart'; class MicrophoneSelectButton extends StatelessWidget { diff --git a/lib/src/ui/buttons/screenshare_toggle.dart b/lib/src/ui/buttons/screenshare_toggle.dart index 1853452..fe894af 100644 --- a/lib/src/ui/buttons/screenshare_toggle.dart +++ b/lib/src/ui/buttons/screenshare_toggle.dart @@ -4,8 +4,8 @@ import 'package:livekit_client/livekit_client.dart'; import 'package:provider/provider.dart'; import 'package:responsive_builder/responsive_builder.dart'; -import '../../context/media_device.dart'; -import '../../context/room.dart'; +import '../../context/media_device_context.dart'; +import '../../context/room_context.dart'; import '../../types/theme.dart'; class ScreenShareToggle extends StatelessWidget { diff --git a/lib/src/ui/chat/chat_widget.dart b/lib/src/ui/chat/chat_widget.dart index e5d6e17..1679d9b 100644 --- a/lib/src/ui/chat/chat_widget.dart +++ b/lib/src/ui/chat/chat_widget.dart @@ -3,8 +3,8 @@ import 'package:flutter/material.dart'; import 'package:chat_bubbles/chat_bubbles.dart'; import 'package:provider/provider.dart'; -import '../../context/chat.dart'; -import '../../context/room.dart'; +import '../../context/chat_context.dart'; +import '../../context/room_context.dart'; import '../../types/theme.dart'; import 'data_chip.dart'; diff --git a/lib/src/ui/debug/track_stats_widget.dart b/lib/src/ui/debug/track_stats_widget.dart index dc60063..b6bd334 100644 --- a/lib/src/ui/debug/track_stats_widget.dart +++ b/lib/src/ui/debug/track_stats_widget.dart @@ -2,8 +2,8 @@ import 'package:flutter/material.dart'; import 'package:provider/provider.dart'; -import '../../context/room.dart'; -import '../../context/track.dart'; +import '../../context/room_context.dart'; +import '../../context/track_context.dart'; class TrackStatsWidget extends StatelessWidget { const TrackStatsWidget({Key? key}) : super(key: key); diff --git a/lib/src/ui/participant/connection_quality_indicator.dart b/lib/src/ui/participant/connection_quality_indicator.dart index e31301b..b6a8e87 100644 --- a/lib/src/ui/participant/connection_quality_indicator.dart +++ b/lib/src/ui/participant/connection_quality_indicator.dart @@ -3,7 +3,7 @@ import 'package:flutter/material.dart'; import 'package:livekit_client/livekit_client.dart'; import 'package:provider/provider.dart'; -import '../../context/participant.dart'; +import '../../context/participant_context.dart'; import '../debug/logger.dart'; class ConnectionQualityIndicator extends StatelessWidget { diff --git a/lib/src/ui/participant/e2e_encryption_indicator.dart b/lib/src/ui/participant/e2e_encryption_indicator.dart index 970675a..99da998 100644 --- a/lib/src/ui/participant/e2e_encryption_indicator.dart +++ b/lib/src/ui/participant/e2e_encryption_indicator.dart @@ -2,7 +2,7 @@ import 'package:flutter/material.dart'; import 'package:provider/provider.dart'; -import '../../context/participant.dart'; +import '../../context/participant_context.dart'; import '../debug/logger.dart'; class E2EEncryptionIndicator extends StatelessWidget { diff --git a/lib/src/ui/participant/focus_toggle.dart b/lib/src/ui/participant/focus_toggle.dart index ed1aa37..55bb18d 100644 --- a/lib/src/ui/participant/focus_toggle.dart +++ b/lib/src/ui/participant/focus_toggle.dart @@ -2,8 +2,8 @@ import 'package:flutter/material.dart'; import 'package:provider/provider.dart'; -import '../../context/room.dart'; -import '../../context/track.dart'; +import '../../context/room_context.dart'; +import '../../context/track_context.dart'; import '../debug/logger.dart'; class FocusToggle extends StatelessWidget { diff --git a/lib/src/ui/participant/is_speaking_indicator.dart b/lib/src/ui/participant/is_speaking_indicator.dart index 4470ae1..121bcd4 100644 --- a/lib/src/ui/participant/is_speaking_indicator.dart +++ b/lib/src/ui/participant/is_speaking_indicator.dart @@ -2,8 +2,8 @@ import 'package:flutter/material.dart'; import 'package:provider/provider.dart'; -import '../../context/participant.dart'; -import '../../context/track.dart'; +import '../../context/participant_context.dart'; +import '../../context/track_context.dart'; import '../../types/theme.dart'; import '../debug/logger.dart'; diff --git a/lib/src/ui/participant/no_track_widget.dart b/lib/src/ui/participant/no_track_widget.dart index 676334b..db80947 100644 --- a/lib/src/ui/participant/no_track_widget.dart +++ b/lib/src/ui/participant/no_track_widget.dart @@ -4,7 +4,7 @@ import 'package:flutter/material.dart'; import 'package:provider/provider.dart'; -import '../../context/track.dart'; +import '../../context/track_context.dart'; import '../../types/theme.dart'; import '../debug/logger.dart'; diff --git a/lib/src/ui/participant/participant_loop.dart b/lib/src/ui/participant/participant_loop.dart index 2784e13..1df81f6 100644 --- a/lib/src/ui/participant/participant_loop.dart +++ b/lib/src/ui/participant/participant_loop.dart @@ -3,9 +3,9 @@ import 'package:flutter/material.dart'; import 'package:livekit_client/livekit_client.dart'; import 'package:provider/provider.dart'; -import '../../context/participant.dart'; -import '../../context/room.dart'; -import '../../context/track.dart'; +import '../../context/participant_context.dart'; +import '../../context/room_context.dart'; +import '../../context/track_context.dart'; import '../debug/logger.dart'; import '../layout/grid_layout.dart'; import '../layout/layouts.dart'; diff --git a/lib/src/ui/participant/participant_muted_indicator.dart b/lib/src/ui/participant/participant_muted_indicator.dart index e075552..9743634 100644 --- a/lib/src/ui/participant/participant_muted_indicator.dart +++ b/lib/src/ui/participant/participant_muted_indicator.dart @@ -2,7 +2,7 @@ import 'package:flutter/material.dart'; import 'package:provider/provider.dart'; -import '../../context/participant.dart'; +import '../../context/participant_context.dart'; import '../debug/logger.dart'; class ParticipantMutedIndicator extends StatelessWidget { diff --git a/lib/src/ui/participant/participant_name.dart b/lib/src/ui/participant/participant_name.dart index 180abe0..36f1256 100644 --- a/lib/src/ui/participant/participant_name.dart +++ b/lib/src/ui/participant/participant_name.dart @@ -2,8 +2,8 @@ import 'package:flutter/material.dart'; import 'package:provider/provider.dart'; -import '../../context/participant.dart'; -import '../../context/track.dart'; +import '../../context/participant_context.dart'; +import '../../context/track_context.dart'; import '../debug/logger.dart'; class ParticipantName extends StatelessWidget { diff --git a/lib/src/ui/participant/participant_status_bar.dart b/lib/src/ui/participant/participant_status_bar.dart index 61d5e49..b57cc01 100644 --- a/lib/src/ui/participant/participant_status_bar.dart +++ b/lib/src/ui/participant/participant_status_bar.dart @@ -2,8 +2,8 @@ import 'package:flutter/material.dart'; import 'package:provider/provider.dart'; -import '../../context/participant.dart'; -import '../../context/track.dart'; +import '../../context/participant_context.dart'; +import '../../context/track_context.dart'; import '../debug/logger.dart'; import 'connection_quality_indicator.dart'; import 'e2e_encryption_indicator.dart'; diff --git a/lib/src/ui/participant/participant_tile_widget.dart b/lib/src/ui/participant/participant_tile_widget.dart index b2faa6b..91b0dca 100644 --- a/lib/src/ui/participant/participant_tile_widget.dart +++ b/lib/src/ui/participant/participant_tile_widget.dart @@ -2,7 +2,7 @@ import 'package:flutter/material.dart'; import 'package:provider/provider.dart'; -import '../../context/track.dart'; +import '../../context/track_context.dart'; import '../debug/logger.dart'; import '../debug/track_stats_widget.dart'; import 'focus_toggle.dart'; diff --git a/lib/src/ui/participant/video_track_widget.dart b/lib/src/ui/participant/video_track_widget.dart index 0816905..e6e0f3e 100644 --- a/lib/src/ui/participant/video_track_widget.dart +++ b/lib/src/ui/participant/video_track_widget.dart @@ -3,7 +3,7 @@ import 'package:flutter/material.dart'; import 'package:livekit_client/livekit_client.dart'; import 'package:provider/provider.dart'; -import '../../context/track.dart'; +import '../../context/track_context.dart'; import '../debug/logger.dart'; import 'no_track_widget.dart'; diff --git a/lib/src/ui/prejoin/camera_preview.dart b/lib/src/ui/prejoin/camera_preview.dart index 30abe21..d1207f5 100644 --- a/lib/src/ui/prejoin/camera_preview.dart +++ b/lib/src/ui/prejoin/camera_preview.dart @@ -5,7 +5,7 @@ import 'package:flutter/material.dart'; import 'package:livekit_client/livekit_client.dart'; import 'package:provider/provider.dart'; -import '../../context/room.dart'; +import '../../context/room_context.dart'; import '../../types/theme.dart'; class CameraPreview extends StatelessWidget { diff --git a/lib/src/ui/prejoin/prejoin.dart b/lib/src/ui/prejoin/prejoin.dart index c8fe978..d27a45c 100644 --- a/lib/src/ui/prejoin/prejoin.dart +++ b/lib/src/ui/prejoin/prejoin.dart @@ -2,12 +2,13 @@ import 'package:flutter/material.dart'; import 'package:provider/provider.dart'; -import '../../context/media_device.dart'; -import '../../context/room.dart'; +import '../../context/media_device_context.dart'; +import '../../context/room_context.dart'; import '../buttons/camera_select_button.dart'; import '../buttons/join_button.dart'; import '../buttons/microphone_select_button.dart'; import '../debug/logger.dart'; +import '../builder/media_device.dart'; import 'camera_preview.dart'; import 'text_input.dart'; @@ -55,17 +56,16 @@ class Prejoin extends StatelessWidget { width: 480, child: Row( children: [ - ChangeNotifierProvider( - create: (_) => MediaDeviceContext(roomCtx: roomCtx), - child: Expanded( - child: Column( - mainAxisAlignment: MainAxisAlignment.center, - children: [ - Container( - padding: const EdgeInsets.all(8.0), - child: const CameraPreview(), - ), - SizedBox( + Expanded( + child: Column( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + Container( + padding: const EdgeInsets.all(8.0), + child: const CameraPreview(), + ), + MediaDevices( + builder: (_, mediaDeviceCtx) => SizedBox( width: 360, child: Container( padding: const EdgeInsets.all(8.0), @@ -83,42 +83,40 @@ class Prejoin extends StatelessWidget { ), ), ), - SizedBox( - width: 360, - child: Container( - padding: - const EdgeInsets.fromLTRB(12, 8, 12, 8), - child: TextInput( - onTextChanged: onTextUrlChanged, - hintText: 'Enter Livekit Server URL', - text: url, - ), + ), + SizedBox( + width: 360, + child: Container( + padding: const EdgeInsets.fromLTRB(12, 8, 12, 8), + child: TextInput( + onTextChanged: onTextUrlChanged, + hintText: 'Enter Livekit Server URL', + text: url, ), ), - SizedBox( - width: 360, - child: Container( - padding: - const EdgeInsets.fromLTRB(12, 8, 12, 8), - child: TextInput( - onTextChanged: onTextTokenChanged, - hintText: 'Enter Token', - text: token, - ), + ), + SizedBox( + width: 360, + child: Container( + padding: const EdgeInsets.fromLTRB(12, 8, 12, 8), + child: TextInput( + onTextChanged: onTextTokenChanged, + hintText: 'Enter Token', + text: token, ), ), - SizedBox( - width: 360, - height: 64, - child: Container( - padding: const EdgeInsets.all(8.0), - child: JoinButton( - onPressed: () => _handleJoinPressed(roomCtx), - ), + ), + SizedBox( + width: 360, + height: 64, + child: Container( + padding: const EdgeInsets.all(8.0), + child: JoinButton( + onPressed: () => _handleJoinPressed(roomCtx), ), ), - ], - ), + ), + ], ), ), ],