Skip to content

docs: clarify dropdown menu text clearing#179676

Merged
auto-submit[bot] merged 10 commits intoflutter:masterfrom
kazbeksultanov:dropdown_menu_text_clear_doc_enhancement
Dec 23, 2025
Merged

docs: clarify dropdown menu text clearing#179676
auto-submit[bot] merged 10 commits intoflutter:masterfrom
kazbeksultanov:dropdown_menu_text_clear_doc_enhancement

Conversation

@kazbeksultanov
Copy link
Contributor

@kazbeksultanov kazbeksultanov commented Dec 10, 2025

The documentation for DropdownMenu's controller and initialSelection properties has been updated. It now explicitly states that clearing the text field requires using a TextEditingController's clear() method, and that setting initialSelection to null will not clear the text. A code snippet demonstrating how to clear the text field has also been added.

Fix for: #177599

Pre-launch Checklist

If you need help, consider asking for advice on the #hackers-new channel on Discord.

Note: The Flutter team is currently trialing the use of Gemini Code Assist for GitHub. Comments from the gemini-code-assist bot should not be taken as authoritative feedback from the Flutter team. If you find its comments useful you can update your code accordingly, but if you are unsure or disagree with the feedback, please feel free to wait for a Flutter team member's review for guidance on which automated comments should be addressed.

talabat.com Talabat Flutter PRs

Loading
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

f: material design flutter/packages/flutter/material repository. framework flutter/packages/flutter repository. See also f: labels.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants