Demos
For examples and details on the usage of this component, visit the component demo page:
Modal
Properties
| Parameter | Type | Description | Default |
|---|---|---|---|
| ChildContent | RenderFragment |
Gets or sets the content to be rendered inside the modal. | - |
| Size | ModalSize |
Gets or sets the size of the modal. | Medium |
| Radius | Radius |
Gets or sets the border radius of the modal. | Large |
| Shadow | Shadow |
Gets or sets the shadow of the modal. | Large |
| Backdrop | Backdrop |
Gets or sets the backdrop style of the modal. | Opaque |
| ScrollBehavior | ScrollBehavior |
Gets or sets the scroll behavior of the modal. | Normal |
| Placement | ModalPlacement |
Gets or sets the placement of the modal within the viewport. | Auto |
| Open | bool |
Gets or sets a value indicating whether the modal is currently open. | false |
| OpenChanged | EventCallback<bool> |
Gets or sets a callback that is invoked when the state changes. | - |
| OnClose | EventCallback |
Gets or sets a callback that is invoked when the modal is closed. | - |
| ShowCloseButton | bool |
Gets or sets a value indicating whether the close button is shown. | true |
| Classes | ModalSlots |
Gets or sets the CSS class names for the modal slots. | - |
| As | string |
Gets or sets an HTML tag of the component. | - |
| Class | string |
Gets or sets CSS class names that will be applied to the component. | - |
| Style | string |
Gets or sets styles that will be applied to the component. | - |
| AdditionalAttributes | IReadOnlyDictionary<string, object> |
Gets or sets a collection of additional attributes that will be applied to the component. | - |
| ElementReference | ElementReference? |
Gets or sets the associated . May be if accessed before the component is rendered. | - |
Methods
| Method | Type | Description |
|---|---|---|
| OpenAsync | Task |
|
| CloseAsync | Task |