-
Notifications
You must be signed in to change notification settings - Fork 10.5k
Closed
Labels
DoneThis issue has been fixedThis issue has been fixedaffected-fewThis issue impacts only small number of customersThis issue impacts only small number of customersarea-blazorIncludes: Blazor, Razor ComponentsIncludes: Blazor, Razor ComponentsenhancementThis issue represents an ask for new feature or an enhancement to an existing oneThis issue represents an ask for new feature or an enhancement to an existing onegood first issueGood for newcomers.Good for newcomers.help wantedUp for grabs. We would accept a PR to help resolve this issueUp for grabs. We would accept a PR to help resolve this issueseverity-majorThis label is used by an internal toolThis label is used by an internal tool
Milestone
Description
Add an overload to ElementReference.FocusAsync that accepts preventScroll as an option:
public static ValueTask FocusAsync(this ElementReference elementReference, bool preventScroll);I should probably add a new issue for this but I think FocusAsync() should also include preventScroll flag
https://developer.mozilla.org/en-US/docs/Web/API/HTMLOrForeignElement/focus
Describe the bug
On Blazor server side, when you apply autofocus on your inputs the attribute is not being respected:
- At the first time, you can see the
autofocusbeing applied but loses it after the page fully load - When you use the navigation bar the
autofocusis not applied at all
To Reproduce
Create a page with the followin code:
<input type="text" name="name" />
<input type="text" name="name1" autofocus />Expected: If you don't do anything while the page loads the autofocus must be aplied
Metadata
Metadata
Assignees
Labels
DoneThis issue has been fixedThis issue has been fixedaffected-fewThis issue impacts only small number of customersThis issue impacts only small number of customersarea-blazorIncludes: Blazor, Razor ComponentsIncludes: Blazor, Razor ComponentsenhancementThis issue represents an ask for new feature or an enhancement to an existing oneThis issue represents an ask for new feature or an enhancement to an existing onegood first issueGood for newcomers.Good for newcomers.help wantedUp for grabs. We would accept a PR to help resolve this issueUp for grabs. We would accept a PR to help resolve this issueseverity-majorThis label is used by an internal toolThis label is used by an internal tool