Keep the GIF picker above the system navigation bar

Open the GIF picker through showMeshSheet so it is padded by the
navigation bar or keyboard, and cap its height instead of fixing it so it
shrinks when the keyboard is up.
This commit is contained in:
zjs81 committed 2026-10-24 20:59:49 -07:00
1 parent 918ab7f5a0
commit 4c9705b3cb
2 files changed
+6 -4

No files matched your search

+3 -3
View File
@@ -9,6 +9,7 @@ import '../theme/mesh_theme.dart';
import 'byte_count_input.dart';
import 'gif_message.dart';
import 'gif_picker.dart';
import 'mesh_ui.dart';
import 'message_translation_button.dart';
/// One entry of the composer's "+" menu.
@@ -27,9 +28,8 @@ class ChatComposerAction {
/// Opens the GIF picker and puts the chosen GIF into [controller].
void showChatGifPicker(BuildContext context, TextEditingController controller) {
showModalBottomSheet(
context: context,
isScrollControlled: true,
showMeshSheet<void>(
context,
builder: (context) => GifPicker(
onGifSelected: (gifId) {
controller.text = GifHelper.encodeGif(gifId);
+3 -1
View File
@@ -117,7 +117,9 @@ class _GifPickerState extends State<GifPicker> {
@override
Widget build(BuildContext context) {
return Container(
height: MediaQuery.of(context).size.height * 0.7,
constraints: BoxConstraints(
maxHeight: MediaQuery.of(context).size.height * 0.7,
),
padding: const EdgeInsets.all(16),
child: Column(
children: [