Skip to content

Show InputDecoration.errorText when the field is disabled in M2 - #12589

Draft
kaluli123123 wants to merge 1 commit into
flutter:mainfrom
kaluli123123:port-191662-inputdecorator-errortext
Draft

kaluli123123 wants to merge 1 commit into
flutter:mainfrom
kaluli123123:port-191662-inputdecorator-errortext

Conversation

@kaluli123123

Copy link
Copy Markdown
Contributor

_InputDecoratorDefaultsM2.errorStyle resolved the error text color to
Colors.transparent for the disabled state. The subtext row is still laid
out for the error, so a disabled field with an errorText reserved space
below the input but painted nothing, leaving an unexplained gap.

The Material 3 defaults already paint the error text with the error
color in every state. This change removes the disabled special case from
the Material 2 defaults so both align, and the space that is reserved
for the error is used by the visible error text.

Ported from flutter/flutter#191662, which is blocked by the Material code freeze.

Fixes flutter/flutter#67409
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

p: material_ui triage-design Should be looked at in design triage

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Disabled TextField InputDecoration errorText allocates space but is not shown

1 participant