Working on "Join Game" feature.

This commit is contained in:
2023-01-23 17:25:41 -06:00
parent 26fd955aa4
commit 11b387b928
18 changed files with 509 additions and 344 deletions

View File

@@ -15,7 +15,7 @@ else if (isSpectating)
}
else
{
<SeatedGameBoard Perspective="perspective" Session="session" />
<SeatedGameBoard Perspective="perspective" Session="session" OnRefetchSession="RefetchSession" />
}
@@ -29,7 +29,12 @@ else
protected override async Task OnParametersSetAsync()
{
if (!string.IsNullOrWhiteSpace(SessionName))
await RefetchSession();
}
async Task RefetchSession()
{
if (!string.IsNullOrWhiteSpace(SessionName))
{
this.session = await ShogiApi.GetSession(SessionName);
if (this.session != null)
@@ -42,4 +47,6 @@ else
}
}
}
}