renderFurther function
dynamic
renderFurther( - dynamic context,
- dynamic ref,
- String spaceId,
- int? maxItems,
)
Implementation
Widget renderFurther(
BuildContext context,
WidgetRef ref,
String spaceId,
int? maxItems,
) {
final relatedChatsLoader = ref.watch(remoteChatRelationsProvider(spaceId));
return relatedChatsLoader.when(
data: (chats) => renderRemoteChats(context, ref, spaceId, chats, maxItems),
error: (e, s) {
_log.severe('Failed to load the related chats', e, s);
return Card(
child: Text(L10n.of(context).errorLoadingRelatedChats(e)),
);
},
loading: () => Skeletonizer(
child: Card(
child: Text(L10n.of(context).loadingOtherChats),
),
),
);
}