PopuBox and Background, CornerRadius #3200
-
Hello! |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 3 replies
-
@Frillaut This is not the default "look" of a |
Beta Was this translation helpful? Give feedback.
-
@Frillaut Yeah I can see that causes an issue with the <materialDesign:PopupBox TextBlock.FontSize="14" TextBlock.FontWeight="Medium"
VerticalContentAlignment="Center"
materialDesign:RippleAssist.IsCentered="False"
ClipToBounds="True">
<materialDesign:PopupBox.ToggleContent>
<materialDesign:ColorZone CornerRadius="8" Height="28" Mode="SecondaryLight">
<materialDesign:Ripple
Padding="16,0"
HorizontalContentAlignment="{Binding HorizontalContentAlignment, RelativeSource={RelativeSource FindAncestor, AncestorType={x:Type materialDesign:PopupBox}}}"
VerticalContentAlignment="{Binding VerticalContentAlignment, RelativeSource={RelativeSource FindAncestor, AncestorType={x:Type materialDesign:PopupBox}}}"
Focusable="False">
<StackPanel Orientation="Horizontal">
<materialDesign:PackIcon Kind="DockWindow" VerticalAlignment="Center" Foreground="{DynamicResource PrimaryHueDarkBrush}"/>
<TextBlock Text="PopupBox" Margin="4,0,0,0" VerticalAlignment="Center"/>
</StackPanel>
</materialDesign:Ripple>
</materialDesign:ColorZone>
</materialDesign:PopupBox.ToggleContent>
<StackPanel Margin="0,-8,0,-8"
MinWidth="{Binding ActualWidth,RelativeSource={RelativeSource FindAncestor, AncestorType={x:Type materialDesign:PopupBox}}}">
<Button Content="item 1" Height="32" VerticalContentAlignment="Center"/>
<Button Content="item 2" Height="32" VerticalContentAlignment="Center"/>
<Button Content="item 3" Height="32" VerticalContentAlignment="Center"/>
</StackPanel>
</materialDesign:PopupBox> Note that I have moved the With regards to |
Beta Was this translation helpful? Give feedback.
@Frillaut Yeah I can see that causes an issue with the
Ripple
being below theColorZone
. One way you could "solve" this is by adding your ownRipple
to thepopupBox.ToggleContent
that you add: