add Platform property to SiteState and populate on both Web and .NET MAUI

This commit is contained in:
sbwalker
2024-02-26 14:12:52 -05:00
parent c20138c9fc
commit 553bbda769
5 changed files with 12 additions and 4 deletions

View File

@ -47,6 +47,9 @@
[Parameter]
public string AuthorizationToken { get; set; } = "";
[Parameter]
public string Platform { get; set; } = "";
[CascadingParameter]
HttpContext HttpContext { get; set; }
@ -71,6 +74,7 @@
SiteState.AntiForgeryToken = AntiForgeryToken;
SiteState.AuthorizationToken = AuthorizationToken;
SiteState.RemoteIPAddress = (_pageState != null) ? _pageState.RemoteIPAddress : "";
SiteState.Platform = Platform;
SiteState.IsPrerendering = (HttpContext != null) ? true : false;
_installation = await InstallationService.IsInstalled();