ElementReferenceExtensions.FocusAsync Metoda

Definice

Přetížení

FocusAsync(ElementReference)

Dává fokus prvku vzhledem k jeho ElementReference.

FocusAsync(ElementReference, Boolean)

Dává fokus prvku vzhledem k jeho ElementReference.

FocusAsync(ElementReference)

Dává fokus prvku vzhledem k jeho ElementReference.

public:
[System::Runtime::CompilerServices::Extension]
 static System::Threading::Tasks::ValueTask FocusAsync(Microsoft::AspNetCore::Components::ElementReference elementReference);
public static System.Threading.Tasks.ValueTask FocusAsync (this Microsoft.AspNetCore.Components.ElementReference elementReference);
static member FocusAsync : Microsoft.AspNetCore.Components.ElementReference -> System.Threading.Tasks.ValueTask
<Extension()>
Public Function FocusAsync (elementReference As ElementReference) As ValueTask

Parametry

elementReference
ElementReference

Odkaz na prvek, na který se chcete zaměřit.

Návraty

ValueTask

Reprezentace ValueTask asynchronní operace fokusu.

Platí pro

FocusAsync(ElementReference, Boolean)

Dává fokus prvku vzhledem k jeho ElementReference.

public static System.Threading.Tasks.ValueTask FocusAsync (this Microsoft.AspNetCore.Components.ElementReference elementReference, bool preventScroll);
static member FocusAsync : Microsoft.AspNetCore.Components.ElementReference * bool -> System.Threading.Tasks.ValueTask
<Extension()>
Public Function FocusAsync (elementReference As ElementReference, preventScroll As Boolean) As ValueTask

Parametry

elementReference
ElementReference

Odkaz na prvek, na který se chcete zaměřit.

preventScroll
Boolean

Hodnota Boolean označující, jestli má prohlížeč posunout dokument, aby se nově zaměřený prvek zobrazil. Hodnota false pro preventScroll (výchozí) znamená, že prohlížeč po zaměření posune prvek do zobrazení. Pokud je funkce preventScroll nastavená na hodnotu true, nedojde k žádnému posouvání.

Návraty

ValueTask

Reprezentace ValueTask asynchronní operace fokusu.

Platí pro