Skip to content

Commit afda815

Browse files
authored
Adjust Material 3 textfield padding to align with specs (#116225)
* Adjust textfield padding * lint * lint
1 parent fa063eb commit afda815

File tree

2 files changed

+216
-218
lines changed

2 files changed

+216
-218
lines changed

packages/flutter/lib/src/material/input_decorator.dart

+2-6
Original file line numberDiff line numberDiff line change
@@ -2345,18 +2345,14 @@ class _InputDecoratorState extends State<InputDecorator> with TickerProviderStat
23452345
if (decoration.filled ?? false) {
23462346
contentPadding = decorationContentPadding ?? (decorationIsDense
23472347
? const EdgeInsets.fromLTRB(12.0, 8.0, 12.0, 8.0)
2348-
: themeData.useMaterial3
2349-
? const EdgeInsets.fromLTRB(12.0, 12.75, 12.0, 12.75)
2350-
: const EdgeInsets.fromLTRB(12.0, 12.0, 12.0, 12.0));
2348+
: const EdgeInsets.fromLTRB(12.0, 12.0, 12.0, 12.0));
23512349
} else {
23522350
// Not left or right padding for underline borders that aren't filled
23532351
// is a small concession to backwards compatibility. This eliminates
23542352
// the most noticeable layout change introduced by #13734.
23552353
contentPadding = decorationContentPadding ?? (decorationIsDense
23562354
? const EdgeInsets.fromLTRB(0.0, 8.0, 0.0, 8.0)
2357-
: themeData.useMaterial3
2358-
? const EdgeInsets.fromLTRB(0.0, 12.75, 0.0, 12.75)
2359-
: const EdgeInsets.fromLTRB(0.0, 12.0, 0.0, 12.0));
2355+
: const EdgeInsets.fromLTRB(0.0, 12.0, 0.0, 12.0));
23602356
}
23612357
} else {
23622358
floatingLabelHeight = 0.0;

0 commit comments

Comments
 (0)