Simplify privacy tile control
MODIFY
WalletWasabi.Fluent/Icons/Icons.axaml
WalletWasabi.Fluent/Icons/Icons.axaml
<DrawingImage x:Key="privacy_indicator_good">
<DrawingImage.Drawing>
<DrawingGroup>
- <GeometryDrawing Brush="{DynamicResource PrivacyIndicatorShieldGradientBrush0}"
- Geometry="m 0 13.3333 c 0 -1.4727 1.19391 -2.6666 2.66667 -2.6666 9.46993 0 18.69503 -3.35461 27.73333 -10.133367 0.9481 -0.711111 2.2519 -0.711111 3.2 0 C 42.6383 7.31209 51.8634 10.6667 61.3333 10.6667 62.8061 10.6667 64 11.8606 64 13.3333 V 32 c 0 17.782 -10.5158 30.8471 -31.0226 38.9255 -0.6281 0.2475 -1.3267 0.2475 -1.9548 0 C 10.5158 62.8471 0 49.782 0 32 Z"/>
- <GeometryDrawing Brush="White"
- Geometry="M45.7476 25.4471C46.4073 26.1615 46.3747 27.2865 45.6747 27.9598L27.2617 45.6735C26.4809 46.4246 25.2551 46.4015 24.5021 45.6214L18.2783 39.174C17.6033 38.4747 17.6115 37.3492 18.2966 36.6602C18.9817 35.9712 20.0843 35.9795 20.7594 36.6788L25.947 42.0529L43.2858 25.3727C43.9858 24.6993 45.0879 24.7326 45.7476 25.4471Z" />
+ <GeometryDrawing Brush="Transparent" Geometry="M 24 0 C 37.296 0 48 10.704 48 24 48 37.296 37.296 48 24 48 10.704 48 0 37.296 0 24 0 10.704 10.704 0 24 0 Z"/>
+ <GeometryDrawing Brush="{StaticResource SystemAccentColor}"
+ Geometry="M32.6129 19.1542C33.1122 18.6775 33.1306 17.8863 32.6539 17.3869C32.1773 16.8875 31.386 16.8691 30.8867 17.3458L20.7701 27.0026L17.1336 23.3661C16.6455 22.878 15.854 22.878 15.3659 23.3661C14.8777 23.8543 14.8777 24.6457 15.3659 25.1339L19.8659 29.6339C20.346 30.114 21.1217 30.1231 21.6129 29.6542L32.6129 19.1542ZM24.8646 4.34751C24.3811 3.88416 23.6184 3.88416 23.1349 4.34751C20.3762 6.99127 16.4502 8.42541 13.0979 9.18734C11.4389 9.56438 9.95899 9.76829 8.89553 9.87765C8.36453 9.93226 7.93932 9.9631 7.64987 9.98021C7.50519 9.98876 7.39459 9.99387 7.32181 9.9968C7.28543 9.99827 7.25851 9.99919 7.24154 9.99973L7.2236 10.0003L7.2202 10.0004C6.54169 10.0165 5.99999 10.5713 6 11.2501V20.75C6 25.587 7.24269 30.4082 10.0977 34.5249C12.9592 38.6508 17.3886 41.9936 23.6269 43.9431C23.8697 44.019 24.1298 44.019 24.3726 43.9431C36.9406 40.0156 42 30.4968 42 21V11.25C42 10.5711 41.4577 10.0164 40.7791 10.0003L40.7764 10.0003L40.7585 9.99973C40.7415 9.99919 40.7146 9.99827 40.6782 9.9968C40.6054 9.99387 40.4948 9.98876 40.3501 9.98021C40.0606 9.9631 39.6354 9.93226 39.1044 9.87765C38.0409 9.76829 36.5609 9.56438 34.9019 9.18733C31.5494 8.42541 27.6233 6.99126 24.8646 4.34751ZM8.5 20.75L8.50002 12.4253C8.6969 12.4089 8.91472 12.3889 9.15128 12.3645C10.2909 12.2473 11.8734 12.0294 13.6519 11.6252C16.8704 10.8937 20.8623 9.52333 23.9998 6.92285C27.1373 9.52333 31.1293 10.8937 34.3479 11.6252C36.1264 12.0294 37.709 12.2473 38.8487 12.3645C39.0853 12.3889 39.3031 12.4089 39.5 12.4253V21C39.5 29.4102 35.1556 37.7988 23.9998 41.4378C18.4402 39.6244 14.6108 36.6454 12.152 33.1001C9.6322 29.4668 8.50001 25.1629 8.5 20.75Z" />
</DrawingGroup>
</DrawingImage.Drawing>
</DrawingImage>

MODIFY
WalletWasabi.Fluent/Styles/Themes/BaseLight.axaml
WalletWasabi.Fluent/Styles/Themes/BaseLight.axaml
<Color x:Key="SystemChromeAltHighColor">#FFE3E8F0</Color>
<Color x:Key="SystemRevealListLowColor">#FFEEF3FC</Color>
<Color x:Key="SystemRevealListMediumColor">#FFE3E8F0</Color>
+
<Color x:Key="SystemAccentColorLight1">#FF88B340</Color>
<Color x:Key="SystemAccentColorLight2">#FF99BF59</Color>
<Color x:Key="SystemAccentColorLight3">#FFA9CA73</Color>
<Color x:Key="SystemAccentColorDark1">#FF65951F</Color>
<Color x:Key="SystemAccentColorDark2">#FF528217</Color>
<Color x:Key="SystemAccentColorDark3">#FF3F6F10</Color>
+
<Color x:Key="RegionColor">#FCFDFF</Color>
<Color x:Key="TileRegionColor">#FFFFFF</Color>
</ResourceDictionary>

MODIFY
WalletWasabi.Fluent/ViewModels/Wallets/Home/Tiles/PrivacyControlTileViewModel.cs
WalletWasabi.Fluent/ViewModels/Wallets/Home/Tiles/PrivacyControlTileViewModel.cs
@@ -131,7 +131,7 @@ public partial class PrivacyControlTileViewModel : TileViewModel
var pcPrivate = totalDecimalAmount == 0M ? 1d : (double)(privateDecimalAmount / totalDecimalAmount);
var pcNormal = 1 - pcPrivate;
- PercentText = $"{pcPrivate:P}";
+ PercentText = $"\u205F{pcPrivate*100:N1}\u205F/\u205F{100}";
FullyMixed = pcPrivate >= 1d;

MODIFY
WalletWasabi.Fluent/Views/Wallets/Home/Tiles/PrivacyControlTileView.axaml
WalletWasabi.Fluent/Views/Wallets/Home/Tiles/PrivacyControlTileView.axaml
x:CompileBindings="True" x:DataType="tiles:PrivacyControlTileViewModel"
x:Class="WalletWasabi.Fluent.Views.Wallets.Home.Tiles.PrivacyControlTileView">
<controls:TileControl TileSize="{Binding CurrentTileSize}">
- <controls:TileControl.LargeSizeContent>
<DockPanel>
<DockPanel.Styles>
<Style Selector="Button">
<Setter Property="HorizontalAlignment" Value="Center" />
<Setter Property="VerticalAlignment" Value="Center" />
</Style>
-
- <Style Selector="controls|ProgressRing.visible, controls|RingChartControl.visible">
- <Setter Property="Opacity" Value="1" />
- </Style>
- <Style Selector="controls|ProgressRing, controls|RingChartControl">
- <Setter Property="Opacity" Value="0" />
- <Setter Property="Transitions">
- <Transitions>
- <DoubleTransition Property="Opacity" Duration="0:0:0.5" />
- </Transitions>
- </Setter>
- </Style>
- </DockPanel.Styles>
-
- <TextBlock Text="PRIVACY LEVEL" DockPanel.Dock="Top" Classes="h8 bold" />
-
- <StackPanel Spacing="10" DockPanel.Dock="Bottom" Orientation="Horizontal" HorizontalAlignment="Center">
- <Button Classes="plain" Cursor="Hand" Command="{Binding BoostPrivacyCommand}"
- IsVisible="{Binding BoostButtonVisible}"
- ToolTip.Tip="Boost Privacy">
- <StackPanel Orientation="Horizontal" Spacing="10">
- <PathIcon Data="{StaticResource rocket_regular}" />
- <TextBlock Text="Boost Privacy" />
- </StackPanel>
- </Button>
- <TextBlock Text="Your Privacy is protected"
- IsVisible="{Binding FullyMixed}" />
- <Button Classes="plain" Cursor="Hand" Command="{Binding BoostPrivacyCommand}"
- IsVisible="{Binding IsBoosting}"
- ToolTip.Tip="Stop Privacy Boost">
- <PathIcon Data="{StaticResource stop_regular}" />
- </Button>
- <!--<Button Classes="plain" Cursor="Hand" IsVisible="{Binding IsAutoCoinJoinEnabled}"
- ToolTip.Tip="Pause Automatic CoinJoins">
- <PathIcon Data="{StaticResource pause_regular}" />
- </Button>-->
- </StackPanel>
-
- <Separator DockPanel.Dock="Bottom" Margin="0 10" IsVisible="{Binding !IsAutoCoinJoinEnabled}" />
-
- <Panel>
- <Panel IsVisible="{Binding !FullyMixed}">
- <controls:RingChartControl DataPoints="{Binding TestDataPoints}" Classes.visible="{Binding !ShowBoostingAnimation}"
- HorizontalAlignment="Center" VerticalAlignment="Center" />
- <controls:ProgressRing IsIndeterminate="{Binding ShowBoostingAnimation}"
- Classes.visible="{Binding ShowBoostingAnimation}" />
- </Panel>
-
- <TextBlock IsVisible="{Binding !FullyMixed}" HorizontalAlignment="Center" VerticalAlignment="Center" Text="{Binding PercentText}" FontSize="36" />
- <Image Height="160" Width="160" IsVisible="{Binding FullyMixed}" Source="{StaticResource privacy_indicator_good}" />
- </Panel>
- </DockPanel>
- </controls:TileControl.LargeSizeContent>
- <DockPanel>
- <DockPanel.Styles>
- <Style Selector="Button">
- <Setter Property="HorizontalAlignment" Value="Center" />
- <Setter Property="VerticalAlignment" Value="Center" />
- </Style>
-
- <Style Selector="controls|ProgressRing.visible, controls|RingChartControl.visible">
- <Setter Property="Opacity" Value="1" />
- </Style>
- <Style Selector="controls|ProgressRing, controls|RingChartControl">
- <Setter Property="Opacity" Value="0" />
- <Setter Property="Transitions">
- <Transitions>
- <DoubleTransition Property="Opacity" Duration="0:0:0.5" />
- </Transitions>
- </Setter>
- </Style>
</DockPanel.Styles>
<TextBlock Text="PRIVACY LEVEL" DockPanel.Dock="Top" Classes="h8 bold" />
- <StackPanel Spacing="10" DockPanel.Dock="Right" Orientation="Horizontal"
- HorizontalAlignment="Center" VerticalAlignment="Center">
- <Button Classes="plain" Cursor="Hand" Command="{Binding BoostPrivacyCommand}"
- IsVisible="{Binding BoostButtonVisible}"
- ToolTip.Tip="Boost Privacy">
- <PathIcon Data="{StaticResource rocket_regular}" />
- </Button>
- <TextBlock Text="Your Privacy is protected"
- IsVisible="{Binding FullyMixed}" />
- <Button Classes="plain" Cursor="Hand" Command="{Binding BoostPrivacyCommand}"
- IsVisible="{Binding IsBoosting}"
- ToolTip.Tip="Stop Privacy Boost">
- <PathIcon Data="{StaticResource stop_regular}" />
- </Button>
- <!--<Button Classes="plain" Cursor="Hand" IsVisible="{Binding IsAutoCoinJoinEnabled}"
- ToolTip.Tip="Pause Automatic CoinJoins">
- <PathIcon Data="{StaticResource pause_regular}" />
- </Button>-->
+ <StackPanel VerticalAlignment="Center" Orientation="Horizontal" HorizontalAlignment="Center" Margin="0 8 0 0">
+ <Image Height="48" Width="48" VerticalAlignment="Center" HorizontalAlignment="Center"
+ Source="{StaticResource privacy_indicator_good}" />
+ <TextBlock
+ VerticalAlignment="Center" HorizontalAlignment="Center"
+ TextAlignment="Center"
+ Text="{Binding PercentText}" Classes="h1" Foreground="{StaticResource SystemAccentColorLight1}" />
</StackPanel>
- <Separator DockPanel.Dock="Right"
- Classes="vertical"
- Margin="10 0"
- IsVisible="{Binding !IsAutoCoinJoinEnabled}" />
- <DockPanel>
- <Panel IsVisible="{Binding !FullyMixed}" DockPanel.Dock="Left" Margin="5 8 0 -8">
- <controls:RingChartControl DataPoints="{Binding TestDataPoints}"
- Classes.visible="{Binding !ShowBoostingAnimation}"
- HorizontalAlignment="Center" VerticalAlignment="Center" />
- <controls:ProgressRing IsIndeterminate="{Binding ShowBoostingAnimation}"
- Classes.visible="{Binding ShowBoostingAnimation}" />
- </Panel>
- <Panel>
- <TextBlock IsVisible="{Binding !FullyMixed}"
- TextAlignment="Center"
- VerticalAlignment="Center"
- Text="{Binding PercentText}" FontSize="24" Opacity="0.8" />
- <Image Height="75" Width="75" IsVisible="{Binding FullyMixed}" Source="{StaticResource privacy_indicator_good}" />
- </Panel>
- </DockPanel>
</DockPanel>
</controls:TileControl>
</UserControl>
\ No newline at end of file

Simplify privacy tile control