|
43 | 43 | <Setter Property="Template"> |
44 | 44 | <Setter.Value> |
45 | 45 | <ControlTemplate TargetType="RadioButton"> |
46 | | - <Grid x:Name="RootGrid" Margin="0"> |
47 | | - <Grid.RowDefinitions> |
48 | | - <RowDefinition Height="Auto" /> |
49 | | - <RowDefinition Height="4" /> |
50 | | - </Grid.RowDefinitions> |
51 | | - <ContentPresenter |
52 | | - x:Name="ContentPresenter" |
53 | | - Grid.Row="0" |
54 | | - Padding="12,4,12,4" |
55 | | - HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" |
56 | | - VerticalAlignment="{TemplateBinding VerticalContentAlignment}" |
57 | | - AutomationProperties.AccessibilityView="Raw" |
58 | | - Content="{TemplateBinding Content}" |
59 | | - ContentTemplate="{TemplateBinding ContentTemplate}" |
60 | | - ContentTransitions="{TemplateBinding ContentTransitions}" |
61 | | - Foreground="{TemplateBinding Foreground}" |
62 | | - TextWrapping="Wrap" /> |
63 | | - <Border |
64 | | - x:Name="SelectionPill" |
65 | | - Grid.Row="1" |
66 | | - Height="2" |
67 | | - Margin="16,0,16,0" |
| 46 | + <Grid x:Name="RootGrid"> |
| 47 | + <Grid |
| 48 | + x:Name="ContainerGrid" |
| 49 | + Height="32" |
68 | 50 | Background="Transparent" |
69 | | - CornerRadius="2" /> |
| 51 | + BorderThickness="1" |
| 52 | + CornerRadius="4"> |
| 53 | + <ContentPresenter |
| 54 | + x:Name="ContentPresenter" |
| 55 | + Padding="16,0,16,0" |
| 56 | + HorizontalAlignment="Stretch" |
| 57 | + VerticalAlignment="Center" |
| 58 | + AutomationProperties.AccessibilityView="Raw" |
| 59 | + Content="{TemplateBinding Content}" |
| 60 | + ContentTemplate="{TemplateBinding ContentTemplate}" |
| 61 | + ContentTransitions="{TemplateBinding ContentTransitions}" |
| 62 | + TextWrapping="Wrap" /> |
| 63 | + <Border |
| 64 | + x:Name="SelectionPill" |
| 65 | + Width="16" |
| 66 | + Height="3" |
| 67 | + HorizontalAlignment="Center" |
| 68 | + VerticalAlignment="Bottom" |
| 69 | + Background="Transparent" |
| 70 | + CornerRadius="1" /> |
| 71 | + </Grid> |
70 | 72 | <VisualStateManager.VisualStateGroups> |
71 | 73 | <VisualStateGroup x:Name="CommonStates"> |
72 | 74 | <VisualState x:Name="Normal" /> |
|
77 | 79 | </ObjectAnimationUsingKeyFrames> |
78 | 80 | </Storyboard> |
79 | 81 | </VisualState> |
80 | | - <VisualState x:Name="Pressed"> |
81 | | - <Storyboard> |
82 | | - <ObjectAnimationUsingKeyFrames Storyboard.TargetName="ContentPresenter" Storyboard.TargetProperty="Foreground"> |
83 | | - <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource TextFillColorPrimaryBrush}" /> |
84 | | - </ObjectAnimationUsingKeyFrames> |
85 | | - </Storyboard> |
86 | | - </VisualState> |
87 | 82 | <VisualState x:Name="Disabled"> |
88 | 83 | <Storyboard> |
89 | 84 | <ObjectAnimationUsingKeyFrames Storyboard.TargetName="ContentPresenter" Storyboard.TargetProperty="Foreground"> |
|
95 | 90 | <VisualStateGroup x:Name="CheckStates"> |
96 | 91 | <VisualState x:Name="Checked"> |
97 | 92 | <Storyboard> |
| 93 | + <ObjectAnimationUsingKeyFrames Storyboard.TargetName="ContainerGrid" Storyboard.TargetProperty="Background"> |
| 94 | + <DiscreteObjectKeyFrame KeyTime="0:0:00.3" Value="{ThemeResource ControlFillColorDefaultBrush}" /> |
| 95 | + </ObjectAnimationUsingKeyFrames> |
| 96 | + <ObjectAnimationUsingKeyFrames Storyboard.TargetName="ContainerGrid" Storyboard.TargetProperty="BorderBrush"> |
| 97 | + <DiscreteObjectKeyFrame KeyTime="0:0:00.3" Value="{ThemeResource ControlElevationBorderBrush}" /> |
| 98 | + </ObjectAnimationUsingKeyFrames> |
98 | 99 | <ObjectAnimationUsingKeyFrames Storyboard.TargetName="SelectionPill" Storyboard.TargetProperty="Background"> |
99 | | - <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource SystemAccentColor}" /> |
| 100 | + <DiscreteObjectKeyFrame KeyTime="0:0:00.3" Value="{ThemeResource SystemAccentColor}" /> |
100 | 101 | </ObjectAnimationUsingKeyFrames> |
101 | 102 | <ObjectAnimationUsingKeyFrames Storyboard.TargetName="ContentPresenter" Storyboard.TargetProperty="Foreground"> |
102 | 103 | <DiscreteObjectKeyFrame KeyTime="0" Value="{ThemeResource TextFillColorPrimaryBrush}" /> |
|
142 | 143 | Grid.Row="0" |
143 | 144 | Grid.Column="0" |
144 | 145 | Grid.ColumnSpan="2" |
145 | | - Padding="12" |
146 | | - HorizontalAlignment="Left" |
| 146 | + Margin="12" |
| 147 | + Padding="-1" |
| 148 | + HorizontalAlignment="Center" |
147 | 149 | VerticalAlignment="Center" |
| 150 | + Background="{ThemeResource SubtleFillColorTertiaryBrush}" |
| 151 | + BorderBrush="{ThemeResource ControlStrokeColorDefaultBrush}" |
| 152 | + BorderThickness="1" |
| 153 | + CornerRadius="4" |
148 | 154 | Orientation="Horizontal"> |
149 | 155 | <!-- Details --> |
150 | 156 | <RadioButton |
|
0 commit comments