Repository navigation
MRoessler.BlazorBottomSheet.BottomSheet
github-actions[bot] edited this page Jul 19, 2026
·
3 revisions
A BottomSheet that displays its contents in a BottomSheetOutlet
public class BottomSheet : Microsoft.AspNetCore.Components.ComponentBase, System.IAsyncDisposableInheritance System.Object → Microsoft.AspNetCore.Components.ComponentBase → BottomSheet
Implements System.IAsyncDisposable
| Properties | |
|---|---|
| AdditionalAttributes | Additional HTML attributes to render (see ASP.NET Core Blazor attribute splatting) |
| AllowClosedExpansion | Whether to allow the user to close the sheet by dragging it (Default: true) |
| AllowMaximizedExpansion | Whether to allow the user to maximize the sheet by dragging it (Default: false) |
| AllowMinimizedExpansion | Whether to allow the user to minimize the sheet by dragging it (Default: false) |
| AllowNormalExpansion | Whether to allow the user to expand the sheet by dragging it (Default: true) |
| BackgroundClass | style class to apply on the BottomSheet background (visible when IsModal is true) |
| ChildContent | The BottomSheet's content. Place MinimizedExpansionMarker and NormalExpansionMarker within this content for automatic height computation |
| Class | style class to apply on the BottomSheet element |
| CloseOnBackgroundClick | Whether to close the sheet when the background overlay is clicked (Default: false) |
| DefaultExpansion | Expansion to be applied when IsOpen is set to true (Default: Normal) |
| Expansion | the expansion state to apply (Default: Closed) |
| ExpansionChanged | |
| Handle | Use this to overwrite the default drag handle |
| IsModal | Whether to prevent interaction with the overlayed content (Default: false) |
| IsOpen | Alternative to Expansion for easier ViewModel bindings. When set to true DefaultExpansion will be applied. |
| IsOpenChanged | |
| IsVisible | Whether this sheet should generally be visible (Default: true). Note: this is separate from Expansion |
| JavaScriptObjRef | Reference to the JavaScript BottomSheet object. You may use this to add event listeners. |
| Methods | |
|---|---|
| BuildRenderTree(RenderTreeBuilder) | |
| DisposeAsync() | |
| DisposeAsyncCore() | Can be overriden in sub-classes to dispose resources. |
| OnAfterRenderAsync(bool) | |
| OnInitialized() | |
| OnParametersSetAsync() | |
| RefreshHeightAsync() | Recomputes the height for the current expansion. Can be invoked when the content height changed dynamically. |
| SetExpansionAsync(int) | INTERNAL API |
| WhenRenderedOnce() | Use this to wait for the sheet render at least once. Note: JavaScriptObjRef is initialized after the first render. |