DaisyExpandableCard is a versatile card component that can reveal a secondary content area when triggered. It is ideal for "Showcase" or "Detail" views where initial high-level information is presented, and additional details are revealed on demand (e.g., clicking a "Learn More" or "Play" button).
Key features:
ToggleCommand for easy binding from child buttons.ScrollViewer.| Property | Description |
|---|---|
| IsExpanded | Controls whether the card is currently showing its expanded content. |
| ExpandedContent | The UI content to display in the revealed area. |
| ToggleCommand | A command that toggles IsExpanded. Typically bound to a button inside the card. |
<controls:DaisyExpandableCard x:Name="MyCard">
<!-- Main Content (Default) -->
<Grid Width="150" Height="225">
<controls:DaisyButton Content="Expand"
Command="{Binding #MyCard.ToggleCommand}" />
</Grid>
<!-- Expanded Content -->
<controls:DaisyExpandableCard.ExpandedContent>
<Border Width="150" Background="#111827">
<TextBlock Text="Detailed Info revealed!" />
</Border>
</controls:DaisyExpandableCard.ExpandedContent>
</controls:DaisyExpandableCard>
Width and Height on both the main content and the ExpandedContent container (e.g., a Border).StackPanel inside a ScrollViewer with HorizontalScrollBarVisibility="Auto". This ensures neighbors are pushed correctly.IsGlass="True" mode as DaisyCard for a modern frosted look.