SukiUI icon indicating copy to clipboard operation
SukiUI copied to clipboard

[Bug] Margin on RadioButton.GigaChips:checked Border#SelectedBorder is too large

Open nicki419 opened this issue 1 year ago • 1 comments

Check the following items

  • [x] I have looked up relevant Issue

Description of the issue

The Margin on RadioButton.GigaChips:checked Border#SelectedBorder of 4 leaves a small ring if one was to change the colour of the border: image

Package Version

6.0.0-beta7

Environment

Win11, other platforms untested

Expected Behavior

The above-mentioned small "extra-border" should not be visible.

Reproduction

<Style Selector="RadioButton.GigaChips:checked Border#SelectedBorder">
  <Setter Property="BorderBrush" Value="{DynamicResource SukiBorderBrush}" />
  <Setter Property="BorderThickness" Value="5" />
  <Setter Property="Margin" Value="4" />
</Style>

Note: This behaviour does not relate to the BorderThickness Value.

Additional Information

Original Code as seen in SukiUI/Theme/RadioButtonStyles.xaml:

<Border Name="SelectedBorder"
                            Margin="4"
                            BorderBrush="{DynamicResource SukiPrimaryColor}"
                            BorderThickness="2"
                            CornerRadius="{TemplateBinding CornerRadius}"
                            Opacity="0">

Changing the Margin to 3 fixes this issue: image

nicki419 avatar Jun 22 '24 16:06 nicki419