Show an animated assistant bubble before response tokens

This commit is contained in:
2026-10-25 17:38:56 +00:00
parent a58d820d43
commit 18d43cadc3
12 changed files with 676 additions and 3 deletions
@@ -9,6 +9,7 @@ import '../../domain/chat_tool_calls.dart';
import 'chat_tool_calls_view.dart';
import 'chat_reasoning_chip.dart';
import 'native_disclosure.dart';
import 'chat_response_pending.dart';
/// Builds an assistant text part; the default keeps the server's text exactly.
typedef ChatMessageTextBuilder = Widget Function(BuildContext, String);
@@ -265,6 +266,9 @@ class ChatMessageView extends StatelessWidget {
KeyedSubtree(key: _partKey(part, index, seen), child: widget),
);
}
if (widgets.isEmpty && row['streaming'] == true) {
widgets.add(const ChatResponsePending());
}
return widgets;
}