NavigatorUAData Class
The identity of the user agent given by the User-Agent Client Hints (https://wicg.github.io/ua-client-hints/#navigatoruadata, navigator.userAgentData in the windows and the workers of the secure contexts): the values of BrowsingContextOptions.ClientHints, also sent in the Sec-CH-UA-* request headers.
public sealed class NavigatorUADataProperties
| Name | Description |
|---|---|
| Brands | Gets the brands of the user agent and their significant versions (https://wicg.github.io/ua-client-hints/#dom-navigatoruadata-brands). |
| Mobile | Gets whether the user agent prefers a mobile experience (https://wicg.github.io/ua-client-hints/#dom-navigatoruadata-mobile). |
| Platform | Gets the platform brand (https://wicg.github.io/ua-client-hints/#dom-navigatoruadata-platform). |
Brands
NavigatorUAData.csGets the brands of the user agent and their significant versions (https://wicg.github.io/ua-client-hints/#dom-navigatoruadata-brands).
public IReadOnlyList<NavigatorUABrandVersion> Brands { get; }Mobile
NavigatorUAData.csGets whether the user agent prefers a mobile experience (https://wicg.github.io/ua-client-hints/#dom-navigatoruadata-mobile).
public bool Mobile { get; }Platform
NavigatorUAData.csGets the platform brand (https://wicg.github.io/ua-client-hints/#dom-navigatoruadata-platform).
public string Platform { get; }Methods
| Name | Description |
|---|---|
| GetHighEntropyValues(IReadOnlyList<string>) | Returns the low-entropy values and the requested high-entropy values (https://wicg.github.io/ua-client-hints/#dom-navigatoruadata-gethighentropyvalues): architecture, bitness, formFactors, fullVersionList, model, platformVersion, uaFullVersion and wow64; the other names are ignored. The document of a window that is not allowed to use the ch-ua-high-entropy-values policy-controlled feature only gets the low-entropy values. The task completes in a task of the event loop of the global object. |
| ToJson() | Returns the low-entropy values (https://wicg.github.io/ua-client-hints/#dom-navigatoruadata-tojson). |
GetHighEntropyValues(IReadOnlyList<string>)
NavigatorUAData.csReturns the low-entropy values and the requested high-entropy values (https://wicg.github.io/ua-client-hints/#dom-navigatoruadata-gethighentropyvalues): architecture, bitness, formFactors, fullVersionList, model, platformVersion, uaFullVersion and wow64; the other names are ignored. The document of a window that is not allowed to use the ch-ua-high-entropy-values policy-controlled feature only gets the low-entropy values. The task completes in a task of the event loop of the global object.
public Task<UADataValues> GetHighEntropyValues(IReadOnlyList<string> hints)ToJson()
NavigatorUAData.csReturns the low-entropy values (https://wicg.github.io/ua-client-hints/#dom-navigatoruadata-tojson).
public UALowEntropyJson ToJson()