WIn_RustTools/RustTools/WindowUI/ModuleInfoWin.xaml

133 lines
5.0 KiB
Plaintext
Raw Normal View History

<?xml version="1.0" encoding="utf-8" ?>
<windowex:WindowEx
x:Class="RustTools.WindowUI.ModuleInfoWin"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:windowex="using:WinUIEx"
Title="信息"
MinWidth="650"
MinHeight="500"
Closed="WindowEx_Closed"
SizeChanged="WindowEx_SizeChanged"
mc:Ignorable="d">
2024-08-08 04:29:27 +00:00
<Grid x:Name="grid"
Padding="16,36,16,10">
<Grid.RowDefinitions>
2024-08-08 04:29:27 +00:00
<RowDefinition Height="Auto"/>
<RowDefinition Height="*"/>
<RowDefinition Height="Auto"/>
</Grid.RowDefinitions>
2024-08-08 04:29:27 +00:00
<Grid.ColumnDefinitions/>
<StackPanel Grid.Row="0"
Orientation="Horizontal">
<Border
Width="106"
Height="106"
CornerRadius="9">
<Border.Background>
2024-08-08 04:29:27 +00:00
<ImageBrush ImageSource="{Binding Mod.IconUrl}"
Stretch="UniformToFill"/>
</Border.Background>
</Border>
2024-08-08 04:29:27 +00:00
<StackPanel Margin="16,3,9,3"
Orientation="Vertical">
<TextBlock Style="{StaticResource TitleLargeTextBlockStyle}"
Text="{Binding Mod.Name}"/>
<TextBlock
x:Name="title_b"
Margin="0,3,0,0"
Style="{StaticResource BodyTextBlockStyle}"
2024-08-08 04:29:27 +00:00
Text="加载中"/>
<TextBlock
x:Name="title_c"
Margin="0,9,0,0"
Style="{StaticResource BodyTextBlockStyle}"
2024-08-08 04:29:27 +00:00
Text="加载中"/>
</StackPanel>
</StackPanel>
<ScrollView Grid.Row="1">
2024-08-08 04:29:27 +00:00
<StackPanel Margin="0,26,0,0"
Orientation="Vertical">
<TextBlock Style="{StaticResource SubtitleTextBlockStyle}"
Text="介绍"/>
<TextBlock
x:Name="DescriptionText"
Padding="6,6,6,6"
Style="{StaticResource BodyTextBlockStyle}"
Text="{Binding Mod.Description}"
2024-08-08 04:29:27 +00:00
TextWrapping="Wrap"/>
<TextBlock
x:Name="fliptext"
Style="{StaticResource SubtitleTextBlockStyle}"
Text="截图"
2024-08-08 04:29:27 +00:00
Visibility="Collapsed"/>
<FlipView
x:Name="flipview"
MaxWidth="600"
MaxHeight="360"
Margin="6,6,6,6"
HorizontalAlignment="Left"
ItemsSource="{x:Bind ScreenshotsList}"
Visibility="Collapsed">
<FlipView.ItemTemplate>
<DataTemplate x:DataType="x:String">
2024-08-08 04:29:27 +00:00
<Image Source="{x:Bind Mode=OneTime}"
Stretch="Uniform"/>
</DataTemplate>
</FlipView.ItemTemplate>
</FlipView>
</StackPanel>
</ScrollView>
<CommandBar
Grid.Row="3"
VerticalAlignment="Bottom"
Background="Transparent"
DefaultLabelPosition="Right"
IsOpen="False">
<CommandBar.PrimaryCommands>
2024-07-31 03:24:52 +00:00
<AppBarButton
Name="ReportButton"
Click="AppBarButton_Click"
Icon="ReportHacked"
2024-08-08 04:29:27 +00:00
Label="举报"/>
<AppBarSeparator/>
2024-07-31 03:24:52 +00:00
<AppBarButton
Name="LikeButton"
Click="AppBarButton_Click"
Icon="Like"
2024-08-08 04:29:27 +00:00
Label="支持"/>
<AppBarSeparator/>
2024-07-31 03:24:52 +00:00
<AppBarButton
Name="DownLoadButton"
Click="AppBarButton_Click"
Icon="Download"
2024-08-08 04:29:27 +00:00
Label="下载"/>
</CommandBar.PrimaryCommands>
</CommandBar>
2024-07-31 03:24:52 +00:00
<TeachingTip
x:Name="Toast"
Title="底部提示"
ActionButtonClick="Toast_ActionButtonClick"
ActionButtonContent="确定"
CloseButtonContent="取消"
IsLightDismissEnabled="True"
PlacementMargin="20"
PreferredPlacement="Auto"
2024-08-08 04:29:27 +00:00
Subtitle="消息"/>
<ContentDialog
x:Name="DownloadDialog"
Title="下载中"
SecondaryButtonText="取消">
<StackPanel>
2024-08-08 04:29:27 +00:00
<TextBlock Name="DownloadDialogText"
Text="下载完成后会自动导入到你配置的模组路径,请勿取消"/>
<ProgressBar Margin="0,6,0,0"
IsIndeterminate="True"/>
</StackPanel>
</ContentDialog>
</Grid>
</windowex:WindowEx>