1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798 |
- <UserControl x:Class="PDF_Master.Views.HomePanel.ChatGPTAI.ChatGPTAIRewritingContent"
- xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
- xmlns:convert="clr-namespace:PDF_Master.DataConvert"
- xmlns:cus="clr-namespace:PDF_Master.CustomControl"
- xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
- xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
- xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
- xmlns:i="http://schemas.microsoft.com/xaml/behaviors"
- xmlns:converter="clr-namespace:PDF_Master.DataConvert"
- xmlns:prism ="http://prismlibrary.com/"
- prism:ViewModelLocator.AutoWireViewModel="True"
- Background="White" MinWidth="540" MinHeight="460"
- mc:Ignorable="d"
- d:DesignHeight="760" d:DesignWidth="1032"
- >
- <UserControl.Resources>
- <ResourceDictionary>
- <convert:SizeBrushConvert x:Key="SizeBrushConvert" />
- <convert:SizeToBoolConvert x:Key="SizeToBoolConvert"/>
- </ResourceDictionary>
- </UserControl.Resources>
- <StackPanel Margin="0,0,0,0">
- <StackPanel>
- <Grid >
- <StackPanel HorizontalAlignment="Left">
- <TextBlock Text="{Binding T_Title}" FontFamily="Segoe UI" Margin="0,16,0,0"
- FontSize="20"
- FontWeight="Bold"
- Foreground="{StaticResource color.sys.text.neutral.lv1}" Height="28" HorizontalAlignment="Left"></TextBlock>
- <TextBlock
- HorizontalAlignment="Center"
- FontFamily="Segoe UI"
- FontSize="14"
- Foreground="#94989C"
- Text="{Binding T_LimitTip}"
- TextAlignment="Center"
- TextWrapping="Wrap"
- />
- </StackPanel>
- <Button HorizontalAlignment="Right" Width="104" Height="32" Content="{Binding T_RewritingBtn}" VerticalAlignment="Bottom" Style="{StaticResource Btn.cta}" Command="{Binding RewriteCommand}" IsEnabled="{Binding ElementName=textBoxEnterCharacters,Path=Text.Length, Converter={StaticResource SizeToBoolConvert}}"></Button>
- </Grid>
- <Grid Height="260" Margin="0,12,0,0" >
- <cus:TextBoxEx x:Name="textBoxEnterCharacters" Height="260" Text="{Binding InputText}" FontFamily="Segoe UI" ShowClose="False" PlaceholderText="{Binding T_TextBoxWatermark}" VerticalContentAlignment="Top" HorizontalContentAlignment="Left" TextWrapping="Wrap" Padding="8">
- <i:Interaction.Triggers>
- <i:EventTrigger EventName="TextChanged">
- <i:InvokeCommandAction Command="{Binding textBoxEnterCharactersTextChangedCommad}" CommandParameter="{Binding ElementName=textBoxEnterCharacters}" />
- </i:EventTrigger>
- </i:Interaction.Triggers>
- </cus:TextBoxEx>
- <TextBlock Text="{Binding ElementName=textBoxEnterCharacters,Path=Text.Length,StringFormat={}{0}/150}" Foreground="{Binding ElementName=textBoxEnterCharacters,Path=Text.Length, Converter={StaticResource SizeBrushConvert}}" Panel.ZIndex="1" Height="22" FontSize="14" HorizontalAlignment="Right" VerticalAlignment="Bottom" Margin="0,0,12,8"/>
- </Grid>
- </StackPanel>
- <StackPanel>
- <Grid Height="84" >
- <TextBlock Text="{Binding T_Result}" FontFamily="Segoe UI"
- FontSize="20"
- FontWeight="Bold"
- VerticalAlignment="Bottom" Margin="0,0,0,12"
- Foreground="{StaticResource color.sys.text.neutral.lv1}" Height="28" HorizontalAlignment="Left"></TextBlock>
- <Grid HorizontalAlignment="Right">
- <cus:ToastControl
- HorizontalAlignment="Center"
- VerticalAlignment="Top"
- Width="72"
- Height="32"
- Margin="0,0,0,4"
- Padding="0,4,0,0"
- Background="{StaticResource color.sys.layout.dark.bg}"
- BeginTime="0:0:0:3"
- CornerRadius="4"
- FontSize="14"
- Foreground="White"
- StringContent="{Binding T_Copied}"
- Visibility="{Binding ShowTip, Mode=TwoWay}"
- Duration="0:0:0:3" />
- <Button HorizontalAlignment="Right" VerticalAlignment="Bottom" Margin="0,0,0,12" Width="104" Height="32" Content="{Binding T_Copy}" Background="White" Command="{Binding CopyCommand}" Style="{StaticResource btn.sec}" IsEnabled="{Binding ElementName=RewriteTextBoxEx,Path=Text.Length, Converter={StaticResource SizeToBoolConvert}}"></Button>
- </Grid>
- </Grid>
- <Grid>
- <Border Height="260" Panel.ZIndex="1" BorderBrush="{StaticResource color.field.border.error}" Visibility="{Binding ErrorVisible}" BorderThickness="1" CornerRadius="4" >
- <StackPanel Orientation="Horizontal" VerticalAlignment="Top" Margin="16">
- <Grid Width="16" Height="16" Margin="4,0,8,0">
- <Ellipse Width="14" Height="14" Fill="#F3465B"></Ellipse>
- <Path Data="M7.25 4V9H8.75V4H7.25ZM7.25 10.5V12H8.75L8.75 10.5H7.25Z" Fill="white"/>
- </Grid>
- <TextBlock Text="{Binding ErrorTipText}" FontSize="14" FontFamily="SF Pro Text" Foreground="#F3465B" VerticalAlignment="Center"></TextBlock>
- </StackPanel>
- </Border>
- <cus:TextBoxEx x:Name="RewriteTextBoxEx" Height="260" Text="{Binding RewriteText}" FontFamily="Segoe UI" ShowClose="False" VerticalContentAlignment="Top" HorizontalContentAlignment="Left" TextWrapping="Wrap" Padding="8" IsReadOnly="True">
- </cus:TextBoxEx>
- <Path Visibility="{Binding NullStateVisible}" Data="M34.999 32.1992H76.999C88.597 32.1992 97.999 41.6012 97.999 53.1992V75.5992C97.999 87.1972 88.597 96.5992 76.999 96.5992H34.999C23.401 96.5992 13.999 87.1972 13.999 75.5992V53.1992C13.999 41.6012 23.4011 32.1992 34.999 32.1992ZM34.999 41.9992C28.8134 41.9992 23.799 47.0136 23.799 53.1992V75.5992C23.799 81.7848 29.8144 85.999 36 85.999V90.1792C36 91.0407 36.8809 91.6215 37.6727 91.2822L50 85.999H76.999C83.1846 85.999 88.199 81.7848 88.199 75.5992V53.1992C88.199 47.0136 83.1846 41.9992 76.999 41.9992H34.999ZM103.6 58.7988C103.6 63.2253 103.6 68.1665 103.6 72.7988M8.39941 58.7988C8.39941 63.2253 8.39941 68.1665 8.39941 72.7988M70.2856 18.0194L63.2854 30.1441L56.6426 30.9277L53.9999 24.7831L61.0001 12.6584L70.2856 18.0194ZM72.2856 14.5553L72.604 14.0037C74.0844 11.4396 73.2059 8.16089 70.6418 6.68049C68.0777 5.2001 64.7989 6.07863 63.3185 8.64275L63.0001 9.1943L72.2856 14.5553ZM44 56.1992C44 58.4084 42.2091 60.1992 40 60.1992C37.7909 60.1992 36 58.4084 36 56.1992C36 53.9901 37.7909 52.1992 40 52.1992C42.2091 52.1992 44 53.9901 44 56.1992ZM48 56.1992C48 53.9901 49.7909 52.1992 52 52.1992H72C74.2091 52.1992 76 53.9901 76 56.1992C76 58.4084 74.2091 60.1992 72 60.1992H52C49.7909 60.1992 48 58.4084 48 56.1992ZM44 72.1992C44 74.4084 42.2091 76.1992 40 76.1992C37.7909 76.1992 36 74.4084 36 72.1992C36 69.9901 37.7909 68.1992 40 68.1992C42.2091 68.1992 44 69.9901 44 72.1992ZM48 72.1992C48 69.9901 49.7909 68.1992 52 68.1992H72C74.2091 68.1992 76 69.9901 76 72.1992C76 74.4084 74.2091 76.1992 72 76.1992H52C49.7909 76.1992 48 74.4084 48 72.1992Z" Fill="#F7F8FA" HorizontalAlignment="Center" VerticalAlignment="Center" Panel.ZIndex="1"/>
- </Grid>
- </StackPanel>
- </StackPanel>
- </UserControl>
|