-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
MudAutocomplete: Allow changing LockScroll value
#11414
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
MudAutocomplete: Allow changing LockScroll value
#11414
Conversation
LockScroll value (#11409)LockScroll value (#11409)
LockScroll value (#11409)LockScroll value
|
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## dev #11414 +/- ##
=======================================
Coverage 91.10% 91.11%
=======================================
Files 465 465
Lines 14407 14407
Branches 2788 2788
=======================================
+ Hits 13126 13127 +1
Misses 642 642
+ Partials 639 638 -1 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
Adds a LockScroll parameter to MudAutocomplete allowing consumers to enable or disable body scroll lock when the dropdown is open.
- Introduced
LockScrollparameter inMudAutocomplete.razor.cs - Passed
LockScrollthrough to the underlyingMudOverlayinMudAutocomplete.razor
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| src/MudBlazor/Components/Autocomplete/MudAutocomplete.razor.cs | Added LockScroll parameter with XML documentation |
| src/MudBlazor/Components/Autocomplete/MudAutocomplete.razor | Wired LockScroll value into the MudOverlay component |
Comments suppressed due to low confidence (2)
src/MudBlazor/Components/Autocomplete/MudAutocomplete.razor.cs:502
- Consider adding a unit or integration test to verify that setting
LockScrollonMudAutocompletecorrectly propagates to the underlyingMudOverlaycomponent.
public bool LockScroll { get; set; }
| /// </remarks> | ||
| [Parameter] | ||
| [Category(CategoryTypes.FormComponent.ListBehavior)] | ||
| public bool LockScroll { get; set; } |
Copilot
AI
May 27, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[nitpick] Explicitly initialize LockScroll to false in the property declaration (e.g., public bool LockScroll { get; set; } = false;) to make the default behavior clearer when skimming code.
| public bool LockScroll { get; set; } | |
| public bool LockScroll { get; set; } = false; |



Description
Resolves #11409
How Has This Been Tested?
Visually:
autocomplete-lockscroll.mp4
Type of Changes
Checklist
dev).