fix(chat): Return breaks lines on phones and align the activity line

On Android and iOS the keyboard's Return now inserts a newline and the
Send button sends; desktop keeps Enter to send. The Material activity
line drops TextButton's inset so it starts at the answer's edge now that
replies have no bubble.
This commit is contained in:
2026-10-30 20:07:27 +00:00
parent 027c2f800e
commit 44b2cff347
9 changed files with 349 additions and 174 deletions
@@ -64,6 +64,21 @@ void main() {
);
});
testWidgets('the activity line starts at the answer\'s edge ($style)', (
tester,
) async {
await tester.pumpWidget(_host([_answer], cupertino: cupertino));
final activity = find.descendant(
of: find.byKey(const Key('chat-turn-activity')),
matching: find.byType(Text),
);
expect(
tester.getTopLeft(activity.first).dx,
tester.getTopLeft(find.text('First paragraph.')).dx,
);
});
testWidgets('a finished reply copies its answer text ($style)', (
tester,
) async {