Fix overlay: Directionality widget + startListening state guard

- Wrap overlay Stack with Directionality (required above MaterialApp)
- Guard startListening() for IncomingData/StaleData states to prevent
  overlay dismissal when status reloads on app resume

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-04-09 23:09:36 +08:00
parent 4c6130aa04
commit bb0346a843
2 changed files with 15 additions and 4 deletions

View File

@@ -79,9 +79,11 @@ class _ChatRequestOverlayState extends ConsumerState<ChatRequestOverlay>
}
});
return Stack(
children: [
widget.child,
return Directionality(
textDirection: TextDirection.ltr,
child: Stack(
children: [
widget.child,
if (_visible) ...[
// Semi-transparent dim
Positioned.fill(
@@ -108,6 +110,7 @@ class _ChatRequestOverlayState extends ConsumerState<ChatRequestOverlay>
),
],
],
),
);
}