Files
Shogi/Shogi.UI/Pages/Play/PlayPage.razor
Lucas Morgan 51d234d871 Replace custom socket implementation with SignalR.
Replace MSAL and custom cookie auth with Microsoft.Identity.EntityFramework
Also some UI redesign to accommodate different login experience.
2024-08-25 03:46:44 +00:00

29 lines
433 B
Plaintext

@attribute [Authorize]
@page "/play/{sessionId}"
@inject GameHubNode node
@if (string.IsNullOrWhiteSpace(SessionId))
{
return;
}
<main class="PrimaryTheme">
<AuthorizeView>
<GameBoard SessionId="@SessionId" />
</AuthorizeView>
</main>
@code {
[Parameter]
public string? SessionId { get; set; }
protected override async Task OnParametersSetAsync()
{
if (!node.IsConnected)
{
await node.BeginListen();
}
}
}