-
Notifications
You must be signed in to change notification settings - Fork 29.7k
Closed
Labels
a: text inputEntering text in a text field or keyboard related problemsEntering text in a text field or keyboard related problemsf: material designflutter/packages/flutter/material repository.flutter/packages/flutter/material repository.found in release: 3.35Found to occur in 3.35Found to occur in 3.35found in release: 3.38Found to occur in 3.38Found to occur in 3.38frameworkflutter/packages/flutter repository. See also f: labels.flutter/packages/flutter repository. See also f: labels.has reproducible stepsThe issue has been confirmed reproducible and is ready to work onThe issue has been confirmed reproducible and is ready to work onr: fixedIssue is closed as already fixed in a newer versionIssue is closed as already fixed in a newer versionteam-text-inputOwned by Text Input teamOwned by Text Input team
Description
Steps to reproduce
- Run the code sample
- Observe the TextField width
Expected results
The label is fully visible
Actual results
The label is not fully visible because the width is not wide enough.
Code sample
Code sample
import 'package:flutter/material.dart';
void main() {
runApp(const ReproApp());
}
class ReproApp extends StatelessWidget {
const ReproApp({super.key});
@override
Widget build(BuildContext context) {
return MaterialApp(
theme: ThemeData.dark(),
title: 'InputDecorator with label intrinsic width',
home: const HomePage(),
);
}
}
class HomePage extends StatelessWidget {
const HomePage({super.key});
@override
Widget build(BuildContext context) {
return const Material(
child: Center(
child: IntrinsicWidth(
child: TextField(
decoration: InputDecoration(
labelText: 'labelText',
hintText: 'hint',
floatingLabelBehavior: FloatingLabelBehavior.never,
border: OutlineInputBorder(),
),
),
),
),
);
}
}
Screenshots or Video
No response
Logs
Flutter Doctor output
Doctor output
Flutter (Channel [user-branch], 3.38.0-1.0.pre-429, on macOS 15.6.1 24G90 darwin-arm64, locale en-FR)Metadata
Metadata
Assignees
Labels
a: text inputEntering text in a text field or keyboard related problemsEntering text in a text field or keyboard related problemsf: material designflutter/packages/flutter/material repository.flutter/packages/flutter/material repository.found in release: 3.35Found to occur in 3.35Found to occur in 3.35found in release: 3.38Found to occur in 3.38Found to occur in 3.38frameworkflutter/packages/flutter repository. See also f: labels.flutter/packages/flutter repository. See also f: labels.has reproducible stepsThe issue has been confirmed reproducible and is ready to work onThe issue has been confirmed reproducible and is ready to work onr: fixedIssue is closed as already fixed in a newer versionIssue is closed as already fixed in a newer versionteam-text-inputOwned by Text Input teamOwned by Text Input team
Type
Projects
Status
Done (PR merged)