New to Telerik UI for Blazor? Download free 30-day trial

Modal Window

The Window for Blazor can be modal so that the user is unable to interact with the rest of the page until it closes.

To make a modal window, set its Modal property to true.

It is possible for users to close a modal Window by clicking on the modal background around it. To allow this behavior, set CloseOnOverlayClick to true.

Open and close a modal Window

<TelerikWindow Modal="true"
        Window Title
        I am modal, so the page content behind me is not accessible to the user.
        <WindowAction Name="Close" />

<TelerikButton OnClick="@( _ => isModalVisible = true )">Open the window</TelerikButton>

    bool isModalVisible { get; set; } = true;

See Also

In this article