fix: make the loadingWidgetBuilder not nullable

This commit is contained in:
Freek van de Ven 2025-02-14 10:36:50 +01:00 committed by Bart Ribbers
parent 63575ac8fe
commit f4c02829f5
2 changed files with 4 additions and 4 deletions

View file

@ -75,7 +75,7 @@ class ChatBuilders {
final ImagePickerContainerBuilder? imagePickerContainerBuilder;
/// The loading widget builder
final Widget? Function(BuildContext context) loadingWidgetBuilder;
final Widget Function(BuildContext context) loadingWidgetBuilder;
}
/// The button builder

View file

@ -323,9 +323,9 @@ class _ChatBody extends HookWidget {
),
],
),
if (showIndicator.value && options.enableLoadingIndicator)
options.builders.loadingWidgetBuilder(context) ??
const SizedBox.shrink(),
if (showIndicator.value && options.enableLoadingIndicator) ...[
options.builders.loadingWidgetBuilder(context),
],
],
);
}