| 1 | <Page x:Class="UI.Views.ChartPage" |
| 2 | xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" |
| 3 | xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" |
| 4 | xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" |
| 5 | xmlns:d="http://schemas.microsoft.com/expression/blend/2008" |
| 6 | xmlns:local="clr-namespace:UI.Views" xmlns:charts="clr-namespace:UI.Controls.Charts" xmlns:Tabbar="clr-namespace:UI.Controls.Tabbar" xmlns:select="clr-namespace:UI.Controls.Select" xmlns:base="clr-namespace:UI.Controls.Base" xmlns:DatePickerBar="clr-namespace:UI.Controls.DatePickerBar" xmlns:converter="clr-namespace:UI.Controls.Converters" |
| 7 | mc:Ignorable="d" |
| 8 | d:DesignHeight="450" d:DesignWidth="800" |
| 9 | Title="ChartPage" Foreground="{DynamicResource StandardTextBrush}" Background="Transparent"> |
| 10 | <Page.ContextMenu> |
| 11 | <ContextMenu> |
| 12 | <MenuItem Header="刷新" Command="{Binding RefreshCommand}"/> |
| 13 | </ContextMenu> |
| 14 | </Page.ContextMenu> |
| 15 | <StackPanel Margin="20"> |
| 16 | <StackPanel Orientation="Horizontal" Margin="0,5,0,20" > |
| 17 | <TextBlock Text="统计" FontSize="18" VerticalAlignment="Center"/> |
| 18 | <select:Select Margin="10,0,0,0" VerticalAlignment="Top" Padding="10,5" IsShowIcon="False" SelectedItem="{Binding ShowType,Mode=TwoWay}" Options="{Binding ShowTypeOptions}"/> |
| 19 | </StackPanel> |
| 20 | <Tabbar:Tabbar Data="{Binding TabbarData}" SelectedIndex="{Binding TabbarSelectedIndex,Mode=TwoWay}" Width="180" HorizontalAlignment="Left"/> |
| 21 | <Border Margin="0,15,0,0"> |
| 22 | <Grid> |
| 23 | |
| 24 | <base:View Condition="0" Value="{Binding TabbarSelectedIndex}"> |
| 25 | <select:DateSelect Date="{Binding Date,Mode=TwoWay}"/> |
| 26 | </base:View> |
| 27 | |
| 28 | |
| 29 | <base:View Condition="1" Value="{Binding TabbarSelectedIndex}"> |
| 30 | <StackPanel Orientation="Horizontal" VerticalAlignment="Center"> |
| 31 | <select:Select IsShowIcon="False" SelectedItem="{Binding SelectedWeek,Mode=TwoWay}" Options="{Binding WeekOptions}"/> |
| 32 | <TextBlock Foreground="{DynamicResource DefaultTextBrush}" Margin="20,0,0,0" FontSize="14" Text="{Binding WeekDateStr}" VerticalAlignment="Center"/> |
| 33 | </StackPanel> |
| 34 | </base:View> |
| 35 | |
| 36 | <base:View Condition="2" Value="{Binding TabbarSelectedIndex}"> |
| 37 | <select:DateSelect Date="{Binding MonthDate,Mode=TwoWay}" SelectType="Month"/> |
| 38 | |
| 39 | </base:View> |
| 40 | |
| 41 | <base:View Condition="3" Value="{Binding TabbarSelectedIndex}"> |
| 42 | <select:DateSelect Date="{Binding YearDate,Mode=TwoWay}" SelectType="Year"/> |
| 43 | |
| 44 | </base:View> |
| 45 | </Grid> |
| 46 | </Border> |
| 47 | |
| 48 | <TabControl |
| 49 | SelectedIndex="{Binding ShowType.Id}" |
| 50 | BorderThickness="0" |
| 51 | Margin="0,10,0,0" |
| 52 | Padding="0" |
| 53 | Background="Transparent" |
| 54 | > |
| 55 | <TabControl.Resources> |
| 56 | <Style TargetType="TabItem"> |
| 57 | <Setter Property="Template"> |
| 58 | <Setter.Value> |
| 59 | <ControlTemplate TargetType="TabItem"> |
| 60 | </ControlTemplate> |
| 61 | </Setter.Value> |
| 62 | </Setter> |
| 63 | </Style> |
| 64 | |
| 65 | </TabControl.Resources> |
| 66 | <TabItem TextElement.Foreground="{DynamicResource DefaultTextBrush}"> |
| 67 | |
| 68 | <StackPanel> |
| 69 | <Grid Width="680" HorizontalAlignment="Left" Margin="0,5,0,0" > |
| 70 | <Grid.ColumnDefinitions> |
| 71 | <ColumnDefinition Width="*"/> |
| 72 | <ColumnDefinition Width="*"/> |
| 73 | <ColumnDefinition Width="*"/> |
| 74 | </Grid.ColumnDefinitions> |
| 75 | <Border Margin="0,5,0,0" Background="{DynamicResource SettingPanelBgBrush}" Padding="10" CornerRadius="10"> |
| 76 | <Grid> |
| 77 | <Grid.ColumnDefinitions> |
| 78 | <ColumnDefinition Width="auto"/> |
| 79 | <ColumnDefinition Width="*"/> |
| 80 | <ColumnDefinition Width="auto"/> |
| 81 | |
| 82 | </Grid.ColumnDefinitions> |
| 83 | <Border Width="40" Height="40" CornerRadius="14"> |
| 84 | <Border.Background> |
| 85 | <LinearGradientBrush> |
| 86 | <GradientStop Offset="0" Color="{DynamicResource ThemeColor}"/> |
| 87 | |
| 88 | </LinearGradientBrush> |
| 89 | </Border.Background> |
| 90 | <base:Icon IconType="ScreenTime" Foreground="White"/> |
| 91 | </Border> |
| 92 | <Grid Grid.Column="1" Margin="10,0,0,0" VerticalAlignment="Center"> |
| 93 | <Grid.RowDefinitions> |
| 94 | <RowDefinition Height="auto"/> |
| 95 | <RowDefinition Height="auto"/> |
| 96 | </Grid.RowDefinitions> |
| 97 | <TextBlock > |
| 98 | <Run Text="{Binding TotalHours}" FontSize="20" Foreground="{DynamicResource DefaultTextBrush}"/> |
| 99 | <Run Text="小时" FontSize="12" Foreground="{DynamicResource SubTextBrush}"/> |
| 100 | </TextBlock> |
| 101 | <TextBlock Grid.Row="1" Margin="0,3,0,0" Text="总计" Foreground="{DynamicResource SubTextBrush}"/> |
| 102 | |
| 103 | </Grid> |
| 104 | <Border Grid.Column="2" VerticalAlignment="Bottom"> |
| 105 | <StackPanel Orientation="Horizontal"> |
| 106 | <base:View Condition="=1" Value="{Binding DiffTotalTimeType}"> |
| 107 | <base:Icon VerticalAlignment="Center" IconType="ArrowUp8" FontSize="10" /> |
| 108 | </base:View> |
| 109 | <base:View Condition="=0" Value="{Binding DiffTotalTimeType}"> |
| 110 | <base:Icon VerticalAlignment="Center" IconType="SubtractBold" FontSize="10" /> |
| 111 | </base:View> |
| 112 | <base:View Condition="=-1" Value="{Binding DiffTotalTimeType}"> |
| 113 | <base:Icon VerticalAlignment="Center" IconType="ArrowDown8" FontSize="10" /> |
| 114 | </base:View> |
| 115 | <TextBlock Text="{Binding DiffTotalTimeValue}" VerticalAlignment="Center"/> |
| 116 | </StackPanel> |
| 117 | </Border> |
| 118 | </Grid> |
| 119 | </Border> |
| 120 | <Border Grid.Column="1" Margin="20,5,0,0" Background="{DynamicResource SettingPanelBgBrush}" Padding="10" CornerRadius="10"> |
| 121 | <Grid> |
| 122 | <Grid.ColumnDefinitions> |
| 123 | <ColumnDefinition Width="auto"/> |
| 124 | <ColumnDefinition Width="*"/> |
| 125 | <ColumnDefinition Width="auto"/> |
| 126 | </Grid.ColumnDefinitions> |
| 127 | <Border Width="40" Height="40" CornerRadius="14"> |
| 128 | <Border.Background> |
| 129 | <LinearGradientBrush> |
| 130 | <GradientStop Offset="0" Color="{DynamicResource ThemeColor}"/> |
| 131 | |
| 132 | </LinearGradientBrush> |
| 133 | </Border.Background> |
| 134 | <base:Icon IconType="Apps" Foreground="White"/> |
| 135 | </Border> |
| 136 | <Grid Grid.Column="1" Margin="10,0,0,0" VerticalAlignment="Center"> |
| 137 | <Grid.RowDefinitions> |
| 138 | <RowDefinition Height="auto"/> |
| 139 | <RowDefinition Height="auto"/> |
| 140 | </Grid.RowDefinitions> |
| 141 | <TextBlock > |
| 142 | <Run Text="{Binding AppCount}" FontSize="20" Foreground="{DynamicResource DefaultTextBrush}"/> |
| 143 | <Run Text="个" FontSize="12" Foreground="{DynamicResource SubTextBrush}"/> |
| 144 | </TextBlock> |
| 145 | <TextBlock Grid.Row="1" Margin="0,3,0,0" Text="应用量" Foreground="{DynamicResource SubTextBrush}"/> |
| 146 | |
| 147 | |
| 148 | </Grid> |
| 149 | <Border Grid.Column="2" VerticalAlignment="Bottom"> |
| 150 | <StackPanel Orientation="Horizontal"> |
| 151 | <base:View Condition="=1" Value="{Binding DiffAppCountType}"> |
| 152 | <base:Icon VerticalAlignment="Center" IconType="ArrowUp8" FontSize="10" /> |
| 153 | </base:View> |
| 154 | <base:View Condition="=0" Value="{Binding DiffAppCountType}"> |
| 155 | <base:Icon VerticalAlignment="Center" IconType="SubtractBold" FontSize="10" /> |
| 156 | </base:View> |
| 157 | <base:View Condition="=-1" Value="{Binding DiffAppCountType}"> |
| 158 | <base:Icon VerticalAlignment="Center" IconType="ArrowDown8" FontSize="10" /> |
| 159 | </base:View> |
| 160 | <TextBlock Text="{Binding DiffAppCountValue}" VerticalAlignment="Center"/> |
| 161 | |
| 162 | </StackPanel> |
| 163 | </Border> |
| 164 | </Grid> |
| 165 | </Border> |
| 166 | <Border Grid.Column="2" Margin="20,5,0,0" Background="{DynamicResource SettingPanelBgBrush}" Padding="10" CornerRadius="10" ToolTip="{Binding Top1App.Description}"> |
| 167 | <Grid> |
| 168 | <Grid.ColumnDefinitions> |
| 169 | <ColumnDefinition Width="auto"/> |
| 170 | <ColumnDefinition Width="*"/> |
| 171 | <ColumnDefinition Width="auto"/> |
| 172 | </Grid.ColumnDefinitions> |
| 173 | <Border Width="40" Height="40" CornerRadius="14"> |
| 174 | <Border.Background> |
| 175 | <LinearGradientBrush> |
| 176 | <GradientStop Offset="0" Color="{DynamicResource ThemeColor}"/> |
| 177 | |
| 178 | </LinearGradientBrush> |
| 179 | </Border.Background> |
| 180 | <base:Icon IconType="StockUp" Foreground="White"/> |
| 181 | </Border> |
| 182 | <Grid Grid.Column="1" Margin="10,0,0,0" VerticalAlignment="Center"> |
| 183 | <Grid.RowDefinitions> |
| 184 | <RowDefinition Height="auto"/> |
| 185 | <RowDefinition Height="auto"/> |
| 186 | </Grid.RowDefinitions> |
| 187 | |
| 188 | <TextBlock> |
| 189 | <Run Text="{Binding TopHours}" FontSize="20" Foreground="{DynamicResource DefaultTextBrush}"/> |
| 190 | <Run Text="小时" FontSize="12" Foreground="{DynamicResource SubTextBrush}"/> |
| 191 | </TextBlock> |
| 192 | <TextBlock Grid.Row="1" Margin="0,3,0,0" Text="最长使用" Foreground="{DynamicResource SubTextBrush}"/> |
| 193 | </Grid> |
| 194 | <Border Grid.Column="2"> |
| 195 | |
| 196 | |
| 197 | |
| 198 | |
| 199 | |
| 200 | <Border CornerRadius="6" VerticalAlignment="Bottom" > |
| 201 | <base:View Value="{Binding Top1App}" Condition="not null"> |
| 202 | <base:Img URL="{Binding Top1App.IconFile}" VerticalAlignment="Center" HorizontalAlignment="Center" Width="16" Height="16"/> |
| 203 | </base:View> |
| 204 | |
| 205 | </Border> |
| 206 | |
| 207 | </Border> |
| 208 | </Grid> |
| 209 | </Border> |
| 210 | </Grid> |
| 211 | |
| 212 | <WrapPanel Margin="-10"> |
| 213 | |
| 214 | |
| 215 | <Grid Margin="10,0,0,0"> |
| 216 | <Grid.RowDefinitions> |
| 217 | <RowDefinition Height="auto"/> |
| 218 | <RowDefinition Height="*"/> |
| 219 | </Grid.RowDefinitions> |
| 220 | |
| 221 | |
| 222 | <Border Grid.Row="1" Margin="0,20,0,0" Width="680" HorizontalAlignment="Left" Background="{DynamicResource SettingPanelBgBrush}" Padding="20" CornerRadius="10"> |
| 223 | <StackPanel > |
| 224 | <select:Select Padding="0" Height="30" IsShowIcon="False" SelectedItem="{Binding ChartDataMode,Mode=TwoWay}" Options="{Binding ChartDataModeOptions}"/> |
| 225 | <charts:Charts IsStack="{Binding IsChartStack}" Height="310" ColumnSelectedIndex="{Binding ColumnSelectedIndex,Mode=TwoWay}" IsShowTotal="False" DataMaximum="{Binding DataMaximum}" NameIndexStart="{Binding NameIndexStart}" ChartsType="Column" Data="{Binding Data}" IsCanColumnSelect="{Binding IsCanColumnSelect}"/> |
| 226 | <base:View Value="{Binding DayHoursSelectedTime}" Condition="not empty"> |
| 227 | <StackPanel> |
| 228 | <Border Margin="0,10,0,5" HorizontalAlignment="Left" Padding="10" CornerRadius="10"> |
| 229 | <Border.Background> |
| 230 | <SolidColorBrush Color="{DynamicResource ThemeColor}" Opacity=".05"/> |
| 231 | </Border.Background> |
| 232 | <StackPanel Orientation="Horizontal"> |
| 233 | <base:Icon Foreground="{DynamicResource SubTextBrush}" IconType="Calendar" VerticalAlignment="Center"/> |
| 234 | <TextBlock Foreground="{DynamicResource SubTextBrush}" VerticalAlignment="Center" Text="{Binding DayHoursSelectedTime}" FontSize="13" Margin="5,0,0,0"/> |
| 235 | |
| 236 | </StackPanel> |
| 237 | </Border> |
| 238 | <base:View Value="{Binding DayHoursData}" Condition="not empty"> |
| 239 | <charts:Charts IsSearch="True" Margin="0,0,0,0" Height="300" ItemMenu="{Binding AppContextMenu}" Data="{Binding DayHoursData}" ChartsType="List" ClickCommand="{Binding ToDetailCommand}" /> |
| 240 | </base:View> |
| 241 | <base:View Value="{Binding DayHoursData}" Condition="empty"> |
| 242 | <base:EmptyData/> |
| 243 | </base:View> |
| 244 | </StackPanel> |
| 245 | </base:View> |
| 246 | </StackPanel> |
| 247 | </Border> |
| 248 | |
| 249 | </Grid> |
| 250 | |
| 251 | |
| 252 | |
| 253 | <Grid Margin="10,0,0,10" Width="350" Height="400" VerticalAlignment="Top"> |
| 254 | <Grid.RowDefinitions> |
| 255 | <RowDefinition Height="auto"/> |
| 256 | <RowDefinition Height="*"/> |
| 257 | </Grid.RowDefinitions> |
| 258 | |
| 259 | <TextBlock Text="分类" Foreground="#5c5c5c" FontSize="15" Margin="0,20,0,5"/> |
| 260 | <Border Margin="0,5,0,0" Grid.Row="1" Background="{DynamicResource SettingPanelBgBrush}" Padding="20" CornerRadius="10"> |
| 261 | <charts:Charts Margin="10,20,10,10" Height="230" Width="230" ChartsType="Radar" Data="{Binding RadarData}"/> |
| 262 | |
| 263 | </Border> |
| 264 | </Grid> |
| 265 | |
| 266 | |
| 267 | <Grid Margin="10,0,0,10" Width="320" Height="400" VerticalAlignment="Top"> |
| 268 | <Grid.RowDefinitions> |
| 269 | <RowDefinition Height="auto"/> |
| 270 | <RowDefinition Height="*"/> |
| 271 | </Grid.RowDefinitions> |
| 272 | |
| 273 | <TextBlock Text="最为频繁" Foreground="#5c5c5c" FontSize="15" Margin="0,20,0,5"/> |
| 274 | <Border Grid.Row="1" Margin="0,5,0,0" Background="{DynamicResource SettingPanelBgBrush}" Padding="20" CornerRadius="10"> |
| 275 | <charts:Charts ItemMenu="{Binding AppContextMenu}" Data="{Binding TopData}" ChartsType="List" ClickCommand="{Binding ToDetailCommand}" IsCanScroll="False"/> |
| 276 | </Border> |
| 277 | </Grid> |
| 278 | |
| 279 | |
| 280 | |
| 281 | |
| 282 | |
| 283 | |
| 284 | |
| 285 | |
| 286 | |
| 287 | |
| 288 | |
| 289 | |
| 290 | |
| 291 | |
| 292 | |
| 293 | |
| 294 | |
| 295 | |
| 296 | |
| 297 | |
| 298 | |
| 299 | |
| 300 | |
| 301 | |
| 302 | |
| 303 | |
| 304 | |
| 305 | |
| 306 | |
| 307 | |
| 308 | </WrapPanel> |
| 309 | |
| 310 | </StackPanel> |
| 311 | </TabItem> |
| 312 | <TabItem TextElement.Foreground="{DynamicResource DefaultTextBrush}"> |
| 313 | |
| 314 | <StackPanel> |
| 315 | <Grid Width="680" HorizontalAlignment="Left" Margin="0,5,0,0"> |
| 316 | <Grid.ColumnDefinitions> |
| 317 | <ColumnDefinition Width="*"/> |
| 318 | <ColumnDefinition Width="*"/> |
| 319 | <ColumnDefinition Width="*"/> |
| 320 | </Grid.ColumnDefinitions> |
| 321 | <Border Margin="0,5,0,0" Padding="10" CornerRadius="10" Background="{DynamicResource SettingPanelBgBrush}"> |
| 322 | <Grid> |
| 323 | <Grid.ColumnDefinitions> |
| 324 | <ColumnDefinition Width="auto"/> |
| 325 | <ColumnDefinition Width="*"/> |
| 326 | <ColumnDefinition Width="auto"/> |
| 327 | |
| 328 | </Grid.ColumnDefinitions> |
| 329 | <Border Width="40" Height="40" CornerRadius="14"> |
| 330 | <Border.Background> |
| 331 | <LinearGradientBrush> |
| 332 | <GradientStop Offset="0" Color="{DynamicResource ThemeColor}"/> |
| 333 | |
| 334 | </LinearGradientBrush> |
| 335 | </Border.Background> |
| 336 | <base:Icon IconType="Stopwatch" Foreground="White"/> |
| 337 | </Border> |
| 338 | <Grid Grid.Column="1" Margin="10,0,0,0" VerticalAlignment="Center"> |
| 339 | <Grid.RowDefinitions> |
| 340 | <RowDefinition Height="auto"/> |
| 341 | <RowDefinition Height="auto"/> |
| 342 | </Grid.RowDefinitions> |
| 343 | <TextBlock > |
| 344 | <Run Text="{Binding WebTotalTimeText}" FontSize="20" Foreground="{DynamicResource DefaultTextBrush}"/> |
| 345 | <Run Text="小时" FontSize="12" Foreground="{DynamicResource SubTextBrush}"/> |
| 346 | </TextBlock> |
| 347 | <TextBlock Grid.Row="1" Margin="0,3,0,0" Text="浏览" Foreground="{DynamicResource SubTextBrush}"/> |
| 348 | |
| 349 | </Grid> |
| 350 | <Border Grid.Column="2" VerticalAlignment="Bottom"> |
| 351 | <base:DiffValue Value="{Binding WebTotalTime}" LastValue="{Binding LastWebTotalTime}" /> |
| 352 | </Border> |
| 353 | </Grid> |
| 354 | </Border> |
| 355 | <Border Grid.Column="1" Margin="20,5,0,0" Background="{DynamicResource SettingPanelBgBrush}" Padding="10" CornerRadius="10"> |
| 356 | <Grid> |
| 357 | <Grid.ColumnDefinitions> |
| 358 | <ColumnDefinition Width="auto"/> |
| 359 | <ColumnDefinition Width="*"/> |
| 360 | <ColumnDefinition Width="auto"/> |
| 361 | </Grid.ColumnDefinitions> |
| 362 | <Border Width="40" Height="40" CornerRadius="14"> |
| 363 | <Border.Background> |
| 364 | <LinearGradientBrush> |
| 365 | <GradientStop Offset="0" Color="{DynamicResource ThemeColor}"/> |
| 366 | |
| 367 | </LinearGradientBrush> |
| 368 | </Border.Background> |
| 369 | <base:Icon IconType="WebSearch" Foreground="White"/> |
| 370 | </Border> |
| 371 | <Grid Grid.Column="1" Margin="10,0,0,0" VerticalAlignment="Center"> |
| 372 | <Grid.RowDefinitions> |
| 373 | <RowDefinition Height="auto"/> |
| 374 | <RowDefinition Height="auto"/> |
| 375 | </Grid.RowDefinitions> |
| 376 | <TextBlock > |
| 377 | <Run Text="{Binding WebSiteCount}" FontSize="20" Foreground="{DynamicResource DefaultTextBrush}"/> |
| 378 | <Run Text="个" FontSize="12" Foreground="{DynamicResource SubTextBrush}"/> |
| 379 | </TextBlock> |
| 380 | <TextBlock Grid.Row="1" Margin="0,3,0,0" Text="站点" Foreground="{DynamicResource SubTextBrush}"/> |
| 381 | |
| 382 | |
| 383 | </Grid> |
| 384 | <Border Grid.Column="2" VerticalAlignment="Bottom"> |
| 385 | <base:DiffValue Type="Number" Value="{Binding WebSiteCount}" LastValue="{Binding LastWebSiteCount}" /> |
| 386 | </Border> |
| 387 | </Grid> |
| 388 | </Border> |
| 389 | <Border Grid.Column="2" Margin="20,5,0,0" Background="{DynamicResource SettingPanelBgBrush}" Padding="10" CornerRadius="10" > |
| 390 | <Grid> |
| 391 | <Grid.ColumnDefinitions> |
| 392 | <ColumnDefinition Width="auto"/> |
| 393 | <ColumnDefinition Width="*"/> |
| 394 | <ColumnDefinition Width="auto"/> |
| 395 | </Grid.ColumnDefinitions> |
| 396 | <Border Width="40" Height="40" CornerRadius="14"> |
| 397 | <Border.Background> |
| 398 | <LinearGradientBrush> |
| 399 | <GradientStop Offset="0" Color="{DynamicResource ThemeColor}"/> |
| 400 | |
| 401 | </LinearGradientBrush> |
| 402 | </Border.Background> |
| 403 | <base:Icon IconType="Website" Foreground="White"/> |
| 404 | </Border> |
| 405 | <Grid Grid.Column="1" Margin="10,0,0,0" VerticalAlignment="Center"> |
| 406 | <Grid.RowDefinitions> |
| 407 | <RowDefinition Height="auto"/> |
| 408 | <RowDefinition Height="auto"/> |
| 409 | </Grid.RowDefinitions> |
| 410 | |
| 411 | <TextBlock> |
| 412 | <Run Text="{Binding WebPageCount}" FontSize="20" Foreground="{DynamicResource DefaultTextBrush}"/> |
| 413 | <Run Text="个" FontSize="12" Foreground="{DynamicResource SubTextBrush}"/> |
| 414 | </TextBlock> |
| 415 | <TextBlock Grid.Row="1" Margin="0,3,0,0" Text="网页" Foreground="{DynamicResource SubTextBrush}"/> |
| 416 | </Grid> |
| 417 | <Border Grid.Column="2" VerticalAlignment="Bottom"> |
| 418 | <base:DiffValue Type="Number" Value="{Binding WebPageCount}" LastValue="{Binding LastWebPageCount}" /> |
| 419 | </Border> |
| 420 | </Grid> |
| 421 | </Border> |
| 422 | </Grid> |
| 423 | |
| 424 | <WrapPanel Margin="-10,0,-10,0"> |
| 425 | |
| 426 | <Border Margin="10,10,0,0" Background="{DynamicResource SettingPanelBgBrush}" CornerRadius="10" Width="680" Padding="20" > |
| 427 | <StackPanel> |
| 428 | <charts:Charts IsCanColumnSelect="True" ColumnSelectedIndex="{Binding WebColSelectedIndex,Mode=TwoWay}" IsShowTotal="False" NameIndexStart="{Binding NameIndexStart}" IsStack="True" Height="305" ChartsType="Column" Data="{Binding WebBrowseStatisticsData}"/> |
| 429 | |
| 430 | |
| 431 | |
| 432 | <base:View Condition="!=-1" Value="{Binding WebColSelectedIndex}"> |
| 433 | <StackPanel> |
| 434 | <Border Margin="0,10,0,10" HorizontalAlignment="Left" Padding="10" CornerRadius="10"> |
| 435 | <Border.Background> |
| 436 | <SolidColorBrush Color="{DynamicResource ThemeColor}" Opacity=".05"/> |
| 437 | </Border.Background> |
| 438 | <StackPanel Orientation="Horizontal"> |
| 439 | <base:Icon Foreground="{DynamicResource SubTextBrush}" IconType="Calendar" VerticalAlignment="Center"/> |
| 440 | <TextBlock Foreground="{DynamicResource SubTextBrush}" VerticalAlignment="Center" Text="{Binding WebSitesColSelectedTimeText}" FontSize="13" Margin="5,0,0,0"/> |
| 441 | |
| 442 | </StackPanel> |
| 443 | </Border> |
| 444 | <base:View Value="{Binding WebSitesColSelectedData}" Condition="not empty"> |
| 445 | <charts:Charts IconSize="18" IsSearch="True" Margin="0,0,0,0" Height="300" Data="{Binding WebSitesColSelectedData}" ChartsType="List" ClickCommand="{Binding ToDetailCommand}" ItemMenu="{Binding WebSiteContextMenu}"/> |
| 446 | </base:View> |
| 447 | <base:View Value="{Binding WebSitesColSelectedData}" Condition="empty"> |
| 448 | <base:EmptyData/> |
| 449 | </base:View> |
| 450 | </StackPanel> |
| 451 | </base:View> |
| 452 | </StackPanel> |
| 453 | |
| 454 | </Border> |
| 455 | |
| 456 | <Border Margin="10,10,0,0" Width="350" Height="300" Padding="20" Background="{DynamicResource SettingPanelBgBrush}" CornerRadius="10" VerticalAlignment="Top"> |
| 457 | <Grid> |
| 458 | <Grid.RowDefinitions> |
| 459 | <RowDefinition Height="auto"/> |
| 460 | <RowDefinition Height="*"/> |
| 461 | </Grid.RowDefinitions> |
| 462 | <TextBlock Text="分类占比" FontSize="14"/> |
| 463 | |
| 464 | <Grid Grid.Row="1" Margin="0,20,0,0"> |
| 465 | |
| 466 | |
| 467 | <Grid.ColumnDefinitions> |
| 468 | <ColumnDefinition Width="auto"/> |
| 469 | <ColumnDefinition Width="*"/> |
| 470 | </Grid.ColumnDefinitions> |
| 471 | <charts:Charts Width="100" Height="100" ChartsType="Pie" Data="{Binding WebCategoriesPieData}" VerticalAlignment="Center" HorizontalAlignment="Left"/> |
| 472 | <ListView MaxHeight="200" Margin="20,0,0,0" VerticalAlignment="Center" Grid.Column="1" ItemsSource="{Binding WebCategoriesPieData}" ScrollViewer.HorizontalScrollBarVisibility="Disabled" > |
| 473 | |
| 474 | <ListBox.Resources> |
| 475 | <converter:HextoColorConverter x:Key="HextoColorConverter"/> |
| 476 | |
| 477 | <Style TargetType="{x:Type ListView}"> |
| 478 | <Setter Property="OverridesDefaultStyle" Value="True"/> |
| 479 | |
| 480 | <Setter Property="Template"> |
| 481 | <Setter.Value> |
| 482 | <ControlTemplate TargetType="{x:Type ListView}"> |
| 483 | <Border> |
| 484 | <ScrollViewer> |
| 485 | <ItemsPresenter /> |
| 486 | </ScrollViewer> |
| 487 | </Border> |
| 488 | </ControlTemplate> |
| 489 | </Setter.Value> |
| 490 | </Setter> |
| 491 | </Style> |
| 492 | <Style TargetType="{x:Type ListViewItem}"> |
| 493 | <Setter Property="OverridesDefaultStyle" Value="True"/> |
| 494 | <Setter Property="Template"> |
| 495 | <Setter.Value> |
| 496 | <ControlTemplate TargetType="{x:Type ListViewItem}"> |
| 497 | <Grid> |
| 498 | |
| 499 | <Border BorderBrush="Transparent" BorderThickness="2" x:Name="Border" Margin="5" CornerRadius="20"> |
| 500 | <ContentPresenter/> |
| 501 | </Border> |
| 502 | </Grid> |
| 503 | |
| 504 | |
| 505 | </ControlTemplate> |
| 506 | </Setter.Value> |
| 507 | </Setter> |
| 508 | |
| 509 | </Style> |
| 510 | </ListBox.Resources> |
| 511 | <ListBox.ItemsPanel> |
| 512 | <ItemsPanelTemplate> |
| 513 | <StackPanel/> |
| 514 | </ItemsPanelTemplate> |
| 515 | </ListBox.ItemsPanel> |
| 516 | <ListView.ItemTemplate> |
| 517 | <DataTemplate> |
| 518 | <StackPanel Orientation="Horizontal" > |
| 519 | <Rectangle HorizontalAlignment="Left" VerticalAlignment="Center" RadiusX="2" RadiusY="2" Width="12" Height="12" Fill="{Binding Color,Converter={StaticResource HextoColorConverter}}"/> |
| 520 | |
| 521 | |
| 522 | <TextBlock Margin="5,0,0,0" Foreground="{DynamicResource SubTextBrush}" HorizontalAlignment="Center" VerticalAlignment="Center" Text="{Binding Name}" FontSize="12"/> |
| 523 | |
| 524 | </StackPanel> |
| 525 | </DataTemplate> |
| 526 | </ListView.ItemTemplate> |
| 527 | </ListView> |
| 528 | </Grid> |
| 529 | </Grid> |
| 530 | </Border> |
| 531 | |
| 532 | |
| 533 | <Border Margin="10,10,0,0" Background="{DynamicResource SettingPanelBgBrush}" Padding="20" CornerRadius="10" Width="320" Height="300" VerticalAlignment="Top"> |
| 534 | <Grid> |
| 535 | <Grid.RowDefinitions> |
| 536 | <RowDefinition Height="auto"/> |
| 537 | <RowDefinition Height="*"/> |
| 538 | </Grid.RowDefinitions> |
| 539 | |
| 540 | <TextBlock Text="最为频繁" FontSize="14" /> |
| 541 | |
| 542 | <charts:Charts IconSize="18" Grid.Row="1" Margin="0,10,0,0" Data="{Binding WebSitesTopData}" ChartsType="List" ClickCommand="{Binding ToDetailCommand}" ItemMenu="{Binding WebSiteContextMenu}"/> |
| 543 | |
| 544 | </Grid> |
| 545 | </Border> |
| 546 | </WrapPanel> |
| 547 | </StackPanel> |
| 548 | </TabItem> |
| 549 | </TabControl> |
| 550 | </StackPanel> |
| 551 | </Page> |