Collapse

Simple wrapper that lets you collapse/expand some content

Simple Usage


This content is collapsible
<MudPaper Class="pa-4">
    <MudStack Spacing="2">
        <MudButton OnClick="OnExpandCollapseClick">@(_expanded ? "Collapse" : "Expand")</MudButton>
        <MudDivider />
        <MudCollapse Expanded="_expanded">
                This content is collapsible
        </MudCollapse>
    </MudStack>
</MudPaper>
@code {
    bool _expanded = true;

    private void OnExpandCollapseClick() {
        _expanded = !_expanded;
    }
}

Copyright © 2020-2024 MudBlazor.

Powered by .NET 8.0.5

An unhandled error has occurred. Reload 🗙