diff --git a/src/Snap.Hutao/Snap.Hutao/View/Control/StatisticsCard.xaml b/src/Snap.Hutao/Snap.Hutao/View/Control/StatisticsCard.xaml index ba262a12..5b3dfc4d 100644 --- a/src/Snap.Hutao/Snap.Hutao/View/Control/StatisticsCard.xaml +++ b/src/Snap.Hutao/Snap.Hutao/View/Control/StatisticsCard.xaml @@ -195,7 +195,24 @@ Value="{Binding LastPurplePull}"/> - + + + + + + + + + + + + - + + @@ -237,12 +259,14 @@ Style="{StaticResource BodyTextBlockStyle}" Text="{Binding MinOrangePullFormatted}"/> + @@ -255,6 +279,7 @@ @@ -267,6 +292,7 @@ diff --git a/src/Snap.Hutao/Snap.Hutao/ViewModel/GachaLog/Wish.cs b/src/Snap.Hutao/Snap.Hutao/ViewModel/GachaLog/Wish.cs index efaf1989..fc5278c0 100644 --- a/src/Snap.Hutao/Snap.Hutao/ViewModel/GachaLog/Wish.cs +++ b/src/Snap.Hutao/Snap.Hutao/ViewModel/GachaLog/Wish.cs @@ -19,20 +19,9 @@ internal abstract class Wish /// public int TotalCount { get; set; } - /// - /// 统计开始时间 - /// - public string FromFormatted + public string TimeSpanFormatted { - get => $"{From:yyyy.MM.dd}"; - } - - /// - /// 统计开始时间 - /// - public string ToFormatted - { - get => $"{To:yyyy.MM.dd}"; + get => $"{From:yyyy.MM.dd} - {To:yyyy.MM.dd}"; } /// diff --git a/src/Snap.Hutao/Snap.Hutao/Web/Bridge/MiHoYoJSInterface.cs b/src/Snap.Hutao/Snap.Hutao/Web/Bridge/MiHoYoJSInterface.cs index c9bc081e..75a127a8 100644 --- a/src/Snap.Hutao/Snap.Hutao/Web/Bridge/MiHoYoJSInterface.cs +++ b/src/Snap.Hutao/Snap.Hutao/Web/Bridge/MiHoYoJSInterface.cs @@ -53,11 +53,11 @@ internal class MiHoYoJSInterface private CoreWebView2 coreWebView2; - public MiHoYoJSInterface(CoreWebView2 webView, UserAndUid userAndUid) + public MiHoYoJSInterface(CoreWebView2 coreWebView2, UserAndUid userAndUid) { // 由于Webview2 的作用域特殊性,我们在此处直接使用根服务 serviceProvider = Ioc.Default; - this.coreWebView2 = webView; + this.coreWebView2 = coreWebView2; this.userAndUid = userAndUid; taskContext = serviceProvider.GetRequiredService(); @@ -67,9 +67,9 @@ internal class MiHoYoJSInterface domContentLoadedEventHandler = OnDOMContentLoaded; navigationStartingEventHandler = OnNavigationStarting; - webView.WebMessageReceived += webMessageReceivedEventHandler; - webView.DOMContentLoaded += domContentLoadedEventHandler; - webView.NavigationStarting += navigationStartingEventHandler; + coreWebView2.WebMessageReceived += webMessageReceivedEventHandler; + coreWebView2.DOMContentLoaded += domContentLoadedEventHandler; + coreWebView2.NavigationStarting += navigationStartingEventHandler; } public event Action? ClosePageRequested;