Closed
Description
It seems that on iOS the magnifier of a TextField can get stuck in place after releasing the finger and it never disappears. This happens when you put it into a scrollable view. This only seems to happen when the TextField is empty.
Steps to reproduce:
Using an iOS device.
- flutter run
- Long press on the TextField with the text empty to trigger the magnifier
- Scroll up with that same finger over the magnifier
The magnifier seems to get stuck in the same place.
Expected results:
No magnifier
Actual results:
Stuck magnifier
import 'package:flutter/material.dart';
void main() {
runApp(const MyApp());
}
class MyApp extends StatelessWidget {
const MyApp({super.key});
// This widget is the root of your application.
@override
Widget build(BuildContext context) {
return MaterialApp(
title: 'Flutter Demo',
theme: ThemeData(
primarySwatch: Colors.blue,
),
home: const MyHomePage(title: 'Flutter Demo Home Page'),
);
}
}
class MyHomePage extends StatelessWidget {
const MyHomePage({super.key, required this.title});
final String title;
@override
Widget build(BuildContext context) {
return Scaffold(
appBar: AppBar(),
body: ListView(
children: [
const Text(
"Long press to trigger the magnifier without writing anything and drag upwards (like if you where to scroll at the same time) while doing it",
),
const TextField(
decoration: InputDecoration(hintText: "write something"),
),
...List.generate(
20,
(index) => ListTile(
title: Text("Tile $index"),
),
)
],
),
);
}
}
Logs
[✓] Flutter (Channel stable, 3.7.0, on macOS 13.1 22C65 darwin-x64, locale es-ES)
• Flutter version 3.7.0 on channel stable at /Users/jorge/fvm/versions/stable
• Upstream repository https://github.com/flutter/flutter.git
• Framework revision b06b8b2710 (hace 9 días), 2023-01-23 16:55:55 -0800
• Engine revision b24591ed32
• Dart version 2.19.0
• DevTools version 2.20.1
[✓] Android toolchain - develop for Android devices (Android SDK version 33.0.1)
• Android SDK at /Users/jorge/Library/Android/sdk
• Platform android-33, build-tools 33.0.1
• Java binary at: /Applications/Android Studio.app/Contents/jre/Contents/Home/bin/java
• Java version OpenJDK Runtime Environment (build 11.0.13+0-b1751.21-8125866)
• All Android licenses accepted.
[✓] Xcode - develop for iOS and macOS (Xcode 14.2)
• Xcode at /Applications/Xcode.app/Contents/Developer
• Build 14C18
• CocoaPods version 1.11.3
[✓] Chrome - develop for the web
• Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome
[✓] Android Studio (version 2021.3)
• Android Studio at /Applications/Android Studio.app/Contents
• Flutter plugin can be installed from:
🔨 https://plugins.jetbrains.com/plugin/9212-flutter
• Dart plugin can be installed from:
🔨 https://plugins.jetbrains.com/plugin/6351-dart
• Java version OpenJDK Runtime Environment (build 11.0.13+0-b1751.21-8125866)
[✓] VS Code (version 1.74.3)
• VS Code at /Applications/Visual Studio Code.app/Contents
• Flutter extension version 3.58.0
[✓] Connected device (5 available)
...
[✓] HTTP Host Availability
• All required HTTP hosts are available
• No issues found!