Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 15 additions & 15 deletions gallery/gallery/lib/codeviewer/code_segments.dart
Original file line number Diff line number Diff line change
Expand Up @@ -27869,7 +27869,7 @@ class CodeSegments {
text: '\u000a prefixText'),
TextSpan(style: codeStyle.punctuationStyle, text: ':'),
TextSpan(style: codeStyle.baseStyle, text: ' '),
TextSpan(style: codeStyle.stringStyle, text: '\u0027+1\u0027'),
TextSpan(style: codeStyle.stringStyle, text: '\u0027+1 \u0027'),
TextSpan(style: codeStyle.punctuationStyle, text: ','),
TextSpan(style: codeStyle.baseStyle, text: '\u000a '),
TextSpan(style: codeStyle.punctuationStyle, text: '),'),
Expand Down Expand Up @@ -27900,6 +27900,20 @@ class CodeSegments {
TextSpan(style: codeStyle.punctuationStyle, text: ';'),
TextSpan(style: codeStyle.baseStyle, text: '\u000a '),
TextSpan(style: codeStyle.punctuationStyle, text: '},'),
TextSpan(
style: codeStyle.baseStyle,
text: '\u000a maxLength'),
TextSpan(style: codeStyle.punctuationStyle, text: ':'),
TextSpan(style: codeStyle.baseStyle, text: ' '),
TextSpan(style: codeStyle.numberStyle, text: '14'),
TextSpan(style: codeStyle.punctuationStyle, text: ','),
TextSpan(
style: codeStyle.baseStyle,
text: '\u000a maxLengthEnforced'),
TextSpan(style: codeStyle.punctuationStyle, text: ':'),
TextSpan(style: codeStyle.baseStyle, text: ' '),
TextSpan(style: codeStyle.keywordStyle, text: 'false'),
TextSpan(style: codeStyle.punctuationStyle, text: ','),
TextSpan(
style: codeStyle.baseStyle,
text: '\u000a validator'),
Expand Down Expand Up @@ -28179,20 +28193,6 @@ class CodeSegments {
TextSpan(style: codeStyle.punctuationStyle, text: ').'),
TextSpan(style: codeStyle.baseStyle, text: 'demoTextFieldUSD'),
TextSpan(style: codeStyle.punctuationStyle, text: ','),
TextSpan(
style: codeStyle.baseStyle,
text: '\u000a suffixStyle'),
TextSpan(style: codeStyle.punctuationStyle, text: ':'),
TextSpan(style: codeStyle.baseStyle, text: ' '),
TextSpan(style: codeStyle.classStyle, text: 'TextStyle'),
TextSpan(style: codeStyle.punctuationStyle, text: '('),
TextSpan(style: codeStyle.baseStyle, text: 'color'),
TextSpan(style: codeStyle.punctuationStyle, text: ':'),
TextSpan(style: codeStyle.baseStyle, text: ' '),
TextSpan(style: codeStyle.classStyle, text: 'Colors'),
TextSpan(style: codeStyle.punctuationStyle, text: '.'),
TextSpan(style: codeStyle.baseStyle, text: 'green'),
TextSpan(style: codeStyle.punctuationStyle, text: '),'),
TextSpan(style: codeStyle.baseStyle, text: '\u000a '),
TextSpan(style: codeStyle.punctuationStyle, text: '),'),
TextSpan(
Expand Down
5 changes: 3 additions & 2 deletions gallery/gallery/lib/demos/material/text_field_demo.dart
Original file line number Diff line number Diff line change
Expand Up @@ -209,12 +209,14 @@ class TextFormFieldDemoState extends State<TextFormFieldDemo> {
.demoTextFieldWhereCanWeReachYou,
labelText: GalleryLocalizations.of(context)
.demoTextFieldPhoneNumber,
prefixText: '+1',
prefixText: '+1 ',
),
keyboardType: TextInputType.phone,
onSaved: (value) {
person.phoneNumber = value;
},
maxLength: 14,
maxLengthEnforced: false,
validator: _validatePhoneNumber,
// TextInputFormatters are applied in sequence.
inputFormatters: <TextInputFormatter>[
Expand Down Expand Up @@ -263,7 +265,6 @@ class TextFormFieldDemoState extends State<TextFormFieldDemo> {
GalleryLocalizations.of(context).demoTextFieldSalary,
suffixText:
GalleryLocalizations.of(context).demoTextFieldUSD,
suffixStyle: TextStyle(color: Colors.green),
),
maxLines: 1,
),
Expand Down