Dialog全屏弹窗扩展
jianzhichu opened this issue · comments
在DialogOption 中增加了一个 bool 类型的属性 FullScreen 默认 false
另外在DialogService中增加了一个扩展方法,如下:
public async Task<DialogResult> ShowFullScreenDialogAsync<TComponent>(string title, IDictionary<string, object> parameters)
where TComponent : ComponentBase
{
var taskCompletionSource = new TaskCompletionSource<DialogResult>();
var option = new DialogOption()
{
Content = typeof(TComponent),
IsDialog = true,
Title = title,
Width = 0,
FullScreen = true,
Parameters = parameters,
TaskCompletionSource = taskCompletionSource,
};
ShowDialog(option);
return await taskCompletionSource.Task;
}