I'm trying to save the dimensions when the dialog gets closed. However, modal.GetDimension() returns null.
Here's the code: https://pastebin.com/BXGDa7jn
Relevant code:
private async void SaveSettings()
{
var dimensions = await modal.GetDimension();
Dictionary<string, string> windowData = new()
{
{"Width", $"{dimensions.Width}px"},
{"Height", $"{dimensions.Height}px"}
};
await sessionStorage.SetItemAsync($"window-{UID}", windowData);
}