Class DeviceDetector
Detects whether the current client platform should use its own native input UI (e.g. the iOS/Android date, time, and color pickers) instead of a TwBlazor picker's custom popover.
public static class DeviceDetector
- Inheritance
-
DeviceDetector
- Inherited Members
Methods
PrefersNativePickerAsync(IJSRuntime, CancellationToken)
Asks the browser, via JS interop, whether the current device is a mobile platform (iOS or Android) that provides its own native picker UI.
public static Task<bool> PrefersNativePickerAsync(IJSRuntime jsRuntime, CancellationToken cancellationToken = default)
Parameters
jsRuntimeIJSRuntimeThe JS runtime used to query the client platform.
cancellationTokenCancellationTokenA token used to cancel the interop call.