Recently I upgraded Flutter (I can’t remeber which version I was running) to 3.16. After doing so, a lot of UI elements in an app that I had previously built changed. Some of which were fixed by updating the ThemeData, but the most annoying that remains is the fact that none of the TextFormField elements have borders anymore. They show when clicked, but have no visual indicator, other than the hint text, that a text input is there until it is clicked. The only way I can get something to show is if I wrap the text field in a contianer with a box decoration. But when the text field is clicked the border that show and the box decoration clash with each other. I have even tried using the disabled border style in InputDecoration to no avail. How do I get the border or default underline to show back up for a TextFormField? (This is an iOS app btw being run on an iPad)
Flutter Version:
[✓] Flutter (Channel stable, 3.16.0, on macOS 14.1.1 23B81 darwin-arm64, locale en-US)
• Flutter version 3.16.0 on channel stable at /Users/macspinks/source/repos/flutter
• Upstream repository https://github.com/flutter/flutter.git
• Framework revision db7ef5bf9f (9 weeks ago), 2023-11-15 11:25:44 -0800
• Engine revision 74d16627b9
• Dart version 3.2.0
• DevTools version 2.28.2
[✓] Android toolchain - develop for Android devices (Android SDK version 32.1.0-rc1)
• Android SDK at /Users/macspinks/Library/Android/sdk
• Platform android-32, build-tools 32.1.0-rc1
• Java binary at: /Applications/Android Studio.app/Contents/jbr/Contents/Home/bin/java
• Java version OpenJDK Runtime Environment (build 17.0.6+0-17.0.6b829.9-10027231)
• All Android licenses accepted.
[✓] Xcode - develop for iOS and macOS (Xcode 15.0.1)
• Xcode at /Applications/Xcode.app/Contents/Developer
• Build 15A507
• CocoaPods version 1.11.2
[✓] Chrome - develop for the web
• Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome
[✓] Android Studio (version 2022.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 17.0.6+0-17.0.6b829.9-10027231)
[✓] VS Code (version 1.85.1)
• VS Code at /Applications/Visual Studio Code.app/Contents
• Flutter extension can be installed from:
🔨 https://marketplace.visualstudio.com/items?itemName=Dart-Code.flutter
[✓] Connected device (3 available)
• Joseph’s iPad (mobile) • 00008027-0016709A14F8402E • ios • iOS 17.1.1 21B91
• macOS (desktop) • macos • darwin-arm64 • macOS 14.1.1 23B81 darwin-arm64
• Chrome (web) • chrome • web-javascript • Google Chrome 120.0.6099.216
[✓] Network resources
• All expected network resources are available.
• No issues found!
Code:
Text(
'Login',
style: Theme.of(context).textTheme.headline4,
),
Padding(
padding: const EdgeInsets.symmetric(
vertical: 16.0, horizontal: 44.0),
child: TextFormField(
controller: cubit.emailController,
onChanged: (input) {
context
.read<LoginCubit>()
.updateEmailField(input);
},
decoration: InputDecoration(
errorText: emailErr,
border: const OutlineInputBorder(),
labelText: 'Email'),
),
),
Padding(
padding: const EdgeInsets.symmetric(
vertical: 16.0, horizontal: 44.0),
child: TextFormField(
controller: cubit.passwordController,
//initialValue: password,
obscureText: true,
onChanged: (input) {
context
.read<LoginCubit>()
.updatePasswordField(input);
},
decoration: const InputDecoration(
border: OutlineInputBorder(),
labelText: 'Password'),
),
),
TextButton(
onPressed: () {
cubit.login();
},
child: const Text('Login'))







