ui: WPF layout, accessibility, and performance improvements
This commit is contained in:
@@ -59,6 +59,14 @@
|
||||
</EventTrigger>
|
||||
</Style.Triggers>
|
||||
</Style>
|
||||
|
||||
<!-- Shared style for tab header icon -->
|
||||
<Style x:Key="TabHeaderIcon" TargetType="iconPacks:PackIconMaterial">
|
||||
<Setter Property="Width" Value="15"/>
|
||||
<Setter Property="Height" Value="15"/>
|
||||
<Setter Property="Margin" Value="0,0,7,0"/>
|
||||
<Setter Property="VerticalAlignment" Value="Center"/>
|
||||
</Style>
|
||||
</mah:MetroWindow.Resources>
|
||||
|
||||
<Grid>
|
||||
@@ -93,8 +101,8 @@
|
||||
<TabItem x:Name="NewListingTab" Style="{StaticResource AppTabItem}">
|
||||
<TabItem.Header>
|
||||
<StackPanel Orientation="Horizontal">
|
||||
<iconPacks:PackIconMaterial Kind="CameraPlus" Width="15" Height="15"
|
||||
Margin="0,0,7,0" VerticalAlignment="Center"/>
|
||||
<iconPacks:PackIconMaterial Kind="CameraPlus"
|
||||
Style="{StaticResource TabHeaderIcon}"/>
|
||||
<TextBlock Text="New Listing" VerticalAlignment="Center"/>
|
||||
</StackPanel>
|
||||
</TabItem.Header>
|
||||
@@ -106,6 +114,7 @@
|
||||
<StackPanel HorizontalAlignment="Center" VerticalAlignment="Center" MaxWidth="340">
|
||||
<Border Width="72" Height="72" CornerRadius="36"
|
||||
HorizontalAlignment="Center" Margin="0,0,0,18">
|
||||
|
||||
<Border.Background>
|
||||
<LinearGradientBrush StartPoint="0,0" EndPoint="1,1">
|
||||
<GradientStop Color="#7C3AED" Offset="0"/>
|
||||
@@ -115,7 +124,8 @@
|
||||
<iconPacks:PackIconMaterial Kind="CartOutline" Width="32" Height="32"
|
||||
Foreground="White"
|
||||
HorizontalAlignment="Center"
|
||||
VerticalAlignment="Center"/>
|
||||
VerticalAlignment="Center"
|
||||
/>
|
||||
</Border>
|
||||
<TextBlock Text="Connect to eBay" FontSize="20" FontWeight="Bold"
|
||||
HorizontalAlignment="Center"
|
||||
@@ -127,7 +137,8 @@
|
||||
Margin="0,0,0,24"/>
|
||||
<Button x:Name="ConnectBtn" Click="ConnectBtn_Click"
|
||||
Style="{StaticResource LockConnectButton}"
|
||||
HorizontalAlignment="Center">
|
||||
HorizontalAlignment="Center"
|
||||
AutomationProperties.Name="Connect to eBay account">
|
||||
<StackPanel Orientation="Horizontal">
|
||||
<iconPacks:PackIconMaterial Kind="Link" Width="14" Height="14"
|
||||
Margin="0,0,7,0" VerticalAlignment="Center"/>
|
||||
@@ -143,8 +154,8 @@
|
||||
<TabItem x:Name="DraftsTab" Style="{StaticResource AppTabItem}">
|
||||
<TabItem.Header>
|
||||
<StackPanel Orientation="Horizontal">
|
||||
<iconPacks:PackIconMaterial Kind="BookmarkMultiple" Width="15" Height="15"
|
||||
Margin="0,0,7,0" VerticalAlignment="Center"/>
|
||||
<iconPacks:PackIconMaterial Kind="BookmarkMultiple"
|
||||
Style="{StaticResource TabHeaderIcon}"/>
|
||||
<TextBlock Text="Drafts" VerticalAlignment="Center"/>
|
||||
</StackPanel>
|
||||
</TabItem.Header>
|
||||
@@ -166,7 +177,8 @@
|
||||
<iconPacks:PackIconMaterial Kind="AlertCircleOutline"
|
||||
Width="12" Height="12" Margin="0,0,5,0"
|
||||
VerticalAlignment="Center"
|
||||
Foreground="{DynamicResource MahApps.Brushes.Gray5}"/>
|
||||
Foreground="{DynamicResource MahApps.Brushes.Gray5}"
|
||||
/>
|
||||
<TextBlock x:Name="StatusBar" Text="Ready" FontSize="11"
|
||||
Foreground="{DynamicResource MahApps.Brushes.Gray5}"
|
||||
VerticalAlignment="Center"/>
|
||||
@@ -181,7 +193,8 @@
|
||||
<Button x:Name="DisconnectBtn" Click="DisconnectBtn_Click"
|
||||
Visibility="Collapsed"
|
||||
Style="{StaticResource MahApps.Styles.Button.Square}"
|
||||
Padding="6,2" Margin="8,0,0,0" FontSize="10">
|
||||
Padding="6,2" Margin="8,0,0,0" FontSize="10"
|
||||
AutomationProperties.Name="Disconnect from eBay">
|
||||
<TextBlock Text="Disconnect"/>
|
||||
</Button>
|
||||
</StackPanel>
|
||||
|
||||
@@ -1,17 +1,69 @@
|
||||
<UserControl x:Class="EbayListingTool.Views.NewListingView"
|
||||
<UserControl x:Class="EbayListingTool.Views.NewListingView"
|
||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||
xmlns:mah="http://metro.mahapps.com/winfx/xaml/controls"
|
||||
xmlns:iconPacks="http://metro.mahapps.com/winfx/xaml/iconpacks"
|
||||
Loaded="UserControl_Loaded">
|
||||
Loaded="UserControl_Loaded"
|
||||
KeyboardNavigation.TabNavigation="Cycle">
|
||||
|
||||
<UserControl.Resources>
|
||||
<!-- Shared style for AI action buttons (Title AI, Desc AI, Price Research) -->
|
||||
<Style x:Key="AiActionButton" TargetType="Button"
|
||||
BasedOn="{StaticResource MahApps.Styles.Button.Square}">
|
||||
<Setter Property="Padding" Value="6,2"/>
|
||||
</Style>
|
||||
|
||||
<!-- Shared style for field labels -->
|
||||
<Style x:Key="FieldLabel" TargetType="TextBlock">
|
||||
<Setter Property="FontSize" Value="13"/>
|
||||
<Setter Property="FontWeight" Value="SemiBold"/>
|
||||
<Setter Property="Foreground" Value="{DynamicResource MahApps.Brushes.Gray3}"/>
|
||||
</Style>
|
||||
|
||||
<!-- Shared style for section headers (PHOTOS, LISTING DETAILS) -->
|
||||
<Style x:Key="SectionHeader" TargetType="TextBlock">
|
||||
<Setter Property="FontSize" Value="12"/>
|
||||
<Setter Property="FontWeight" Value="SemiBold"/>
|
||||
<Setter Property="Foreground" Value="{DynamicResource MahApps.Brushes.Gray5}"/>
|
||||
</Style>
|
||||
|
||||
<!-- Shared style for subtitle/hint text -->
|
||||
<Style x:Key="HintText" TargetType="TextBlock">
|
||||
<Setter Property="FontSize" Value="13"/>
|
||||
<Setter Property="Foreground" Value="{DynamicResource MahApps.Brushes.Gray5}"/>
|
||||
</Style>
|
||||
|
||||
<!-- Shared style for character count labels -->
|
||||
<Style x:Key="CharCountLabel" TargetType="TextBlock">
|
||||
<Setter Property="FontSize" Value="12"/>
|
||||
<Setter Property="Margin" Value="6,0,0,0"/>
|
||||
<Setter Property="Foreground" Value="{DynamicResource MahApps.Brushes.Gray5}"/>
|
||||
</Style>
|
||||
|
||||
<!-- Shared style for progress track background -->
|
||||
<Style x:Key="ProgressTrack" TargetType="Border">
|
||||
<Setter Property="Height" Value="3"/>
|
||||
<Setter Property="CornerRadius" Value="1.5"/>
|
||||
<Setter Property="Background" Value="{DynamicResource MahApps.Brushes.Gray8}"/>
|
||||
</Style>
|
||||
|
||||
<!-- Shared style for progress track fill -->
|
||||
<Style x:Key="ProgressFill" TargetType="Border">
|
||||
<Setter Property="Height" Value="3"/>
|
||||
<Setter Property="CornerRadius" Value="1.5"/>
|
||||
<Setter Property="HorizontalAlignment" Value="Left"/>
|
||||
<Setter Property="Width" Value="0"/>
|
||||
</Style>
|
||||
</UserControl.Resources>
|
||||
|
||||
<!-- Root grid hosts all three states; Visibility toggled in code-behind -->
|
||||
<Grid>
|
||||
<!-- ══════════════════════════════════════ STATE A: Drop Zone -->
|
||||
<Grid x:Name="StateA" Visibility="Visible">
|
||||
<!-- STATE A: Drop Zone -->
|
||||
<Grid x:Name="StateA" Visibility="Visible"
|
||||
FocusManager.FocusedElement="{Binding ElementName=DropZoneBorder}">
|
||||
<DockPanel LastChildFill="True">
|
||||
|
||||
<!-- Loading panel — shown while AI runs -->
|
||||
<!-- Loading panel - shown while AI runs -->
|
||||
<Border x:Name="LoadingPanel" DockPanel.Dock="Top"
|
||||
Visibility="Collapsed"
|
||||
Margin="60,30,60,0" Padding="30,40"
|
||||
@@ -19,15 +71,16 @@
|
||||
CornerRadius="10">
|
||||
<StackPanel HorizontalAlignment="Center" VerticalAlignment="Center">
|
||||
<mah:ProgressRing Width="36" Height="36"
|
||||
IsTabStop="False"
|
||||
HorizontalAlignment="Center" Margin="0,0,0,16"/>
|
||||
<TextBlock x:Name="LoadingStepText"
|
||||
Text="Examining the photo…"
|
||||
Text="Examining the photo."
|
||||
FontSize="14" FontWeight="SemiBold"
|
||||
HorizontalAlignment="Center"
|
||||
Foreground="{DynamicResource MahApps.Brushes.Gray1}"/>
|
||||
<TextBlock Text="This usually takes 10–20 seconds"
|
||||
FontSize="13" HorizontalAlignment="Center"
|
||||
Foreground="{DynamicResource MahApps.Brushes.Gray5}"
|
||||
<TextBlock Text="This usually takes 10-20 seconds"
|
||||
Style="{StaticResource HintText}"
|
||||
HorizontalAlignment="Center"
|
||||
Margin="0,6,0,0"/>
|
||||
</StackPanel>
|
||||
</Border>
|
||||
@@ -36,34 +89,39 @@
|
||||
<Border x:Name="DropZoneBorder" DockPanel.Dock="Top"
|
||||
Margin="60,30,60,0"
|
||||
AllowDrop="True"
|
||||
Focusable="True"
|
||||
MouseLeftButtonUp="DropZone_Click"
|
||||
DragOver="DropZone_DragOver"
|
||||
DragEnter="DropZone_DragEnter"
|
||||
DragLeave="DropZone_DragLeave"
|
||||
Drop="DropZone_Drop"
|
||||
Cursor="Hand"
|
||||
MinHeight="180">
|
||||
MinHeight="180"
|
||||
AutomationProperties.Name="Photo drop zone - drop photos here or click to browse">
|
||||
<Grid>
|
||||
<!-- Dashed border via Rectangle -->
|
||||
<Rectangle x:Name="DropBorderRect"
|
||||
StrokeThickness="2"
|
||||
StrokeDashArray="6,4"
|
||||
RadiusX="10" RadiusY="10"
|
||||
Stroke="{DynamicResource MahApps.Brushes.Gray6}"/>
|
||||
Stroke="{DynamicResource MahApps.Brushes.Gray6}"
|
||||
IsHitTestVisible="False"/>
|
||||
<StackPanel HorizontalAlignment="Center" VerticalAlignment="Center"
|
||||
Margin="0,40">
|
||||
Margin="0,40"
|
||||
IsHitTestVisible="False">
|
||||
<iconPacks:PackIconMaterial Kind="CameraOutline"
|
||||
Width="52" Height="52"
|
||||
HorizontalAlignment="Center"
|
||||
Foreground="{DynamicResource MahApps.Brushes.Gray5}"
|
||||
Margin="0,0,0,16"/>
|
||||
Margin="0,0,0,16"
|
||||
IsTabStop="False"/>
|
||||
<TextBlock Text="Drop photos here"
|
||||
FontSize="18" FontWeight="SemiBold"
|
||||
HorizontalAlignment="Center"
|
||||
Foreground="{DynamicResource MahApps.Brushes.Gray2}"/>
|
||||
<TextBlock Text="or click to browse — up to 12 photos"
|
||||
FontSize="13" HorizontalAlignment="Center"
|
||||
Foreground="{DynamicResource MahApps.Brushes.Gray5}"
|
||||
<TextBlock Text="or click to browse - up to 12 photos"
|
||||
Style="{StaticResource HintText}"
|
||||
HorizontalAlignment="Center"
|
||||
Margin="0,6,0,0"/>
|
||||
</StackPanel>
|
||||
</Grid>
|
||||
@@ -73,6 +131,7 @@
|
||||
<ScrollViewer x:Name="ThumbScroller" DockPanel.Dock="Top"
|
||||
HorizontalScrollBarVisibility="Auto"
|
||||
VerticalScrollBarVisibility="Disabled"
|
||||
Focusable="False"
|
||||
Margin="60,12,60,0" Visibility="Collapsed">
|
||||
<StackPanel x:Name="ThumbStrip" Orientation="Horizontal"/>
|
||||
</ScrollViewer>
|
||||
@@ -83,14 +142,16 @@
|
||||
Click="Analyse_Click"
|
||||
IsEnabled="False"
|
||||
Style="{StaticResource MahApps.Styles.Button.Square.Accent}"
|
||||
Padding="28,12" FontSize="14" FontWeight="SemiBold">
|
||||
Padding="28,12" FontSize="14" FontWeight="SemiBold"
|
||||
AutomationProperties.Name="Identify and price item with AI">
|
||||
<StackPanel Orientation="Horizontal">
|
||||
<iconPacks:PackIconMaterial x:Name="AnalyseIcon"
|
||||
Kind="MagnifyScan" Width="18" Height="18"
|
||||
Margin="0,0,8,0" VerticalAlignment="Center"/>
|
||||
<mah:ProgressRing x:Name="AnalyseSpinner"
|
||||
Width="18" Height="18" Margin="0,0,8,0"
|
||||
Visibility="Collapsed"/>
|
||||
Visibility="Collapsed"
|
||||
IsTabStop="False"/>
|
||||
<TextBlock x:Name="AnalyseBtnText"
|
||||
Text="Identify & Price with AI"
|
||||
VerticalAlignment="Center"/>
|
||||
@@ -106,11 +167,11 @@
|
||||
</DockPanel>
|
||||
</Grid>
|
||||
|
||||
<!-- ══════════════════════════════════════ STATE B: Review & Edit -->
|
||||
<!-- STATE B: Review & Edit -->
|
||||
<Grid x:Name="StateB" Visibility="Collapsed">
|
||||
<DockPanel LastChildFill="True">
|
||||
|
||||
<!-- Footer bar — pinned to bottom via DockPanel.Dock -->
|
||||
<!-- Footer bar - pinned to bottom via DockPanel.Dock -->
|
||||
<Border DockPanel.Dock="Bottom"
|
||||
Background="{DynamicResource MahApps.Brushes.Gray9}"
|
||||
BorderThickness="0,1,0,0"
|
||||
@@ -125,7 +186,8 @@
|
||||
Click="StartOver_Click"
|
||||
Background="Transparent" BorderThickness="0"
|
||||
Foreground="{DynamicResource MahApps.Brushes.Gray5}"
|
||||
Cursor="Hand" VerticalAlignment="Center">
|
||||
Cursor="Hand" VerticalAlignment="Center"
|
||||
AutomationProperties.Name="Start over and discard edits">
|
||||
<TextBlock FontSize="13">
|
||||
<Run Text="← "/>
|
||||
<Run Text="Start Over" TextDecorations="Underline"/>
|
||||
@@ -135,7 +197,8 @@
|
||||
<Button x:Name="SaveDraftBtn"
|
||||
Click="SaveDraft_Click"
|
||||
Style="{StaticResource MahApps.Styles.Button.Square}"
|
||||
Padding="16,8" Margin="0,0,8,0">
|
||||
Padding="16,8" Margin="0,0,8,0"
|
||||
AutomationProperties.Name="Save listing as draft">
|
||||
<StackPanel Orientation="Horizontal">
|
||||
<iconPacks:PackIconMaterial Kind="ContentSaveOutline"
|
||||
Width="14" Height="14" Margin="0,0,6,0"
|
||||
@@ -146,14 +209,16 @@
|
||||
<Button x:Name="PostBtn"
|
||||
Click="Post_Click"
|
||||
Style="{StaticResource MahApps.Styles.Button.Square.Accent}"
|
||||
Padding="16,8">
|
||||
Padding="16,8"
|
||||
AutomationProperties.Name="Post listing to eBay">
|
||||
<StackPanel Orientation="Horizontal">
|
||||
<iconPacks:PackIconMaterial x:Name="PostIcon"
|
||||
Kind="CartArrowRight" Width="14" Height="14"
|
||||
Margin="0,0,6,0" VerticalAlignment="Center"/>
|
||||
<mah:ProgressRing x:Name="PostSpinner"
|
||||
Width="14" Height="14" Margin="0,0,6,0"
|
||||
Visibility="Collapsed"/>
|
||||
Visibility="Collapsed"
|
||||
IsTabStop="False"/>
|
||||
<TextBlock Text="Post to eBay" VerticalAlignment="Center"/>
|
||||
</StackPanel>
|
||||
</Button>
|
||||
@@ -162,9 +227,9 @@
|
||||
</Border>
|
||||
|
||||
<!-- Two-column content area -->
|
||||
<Grid DockPanel.Dock="Top" Margin="16,12,16,0">
|
||||
<Grid Margin="16,12,16,0">
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="220"/>
|
||||
<ColumnDefinition Width="220" MinWidth="160"/>
|
||||
<ColumnDefinition Width="12"/>
|
||||
<ColumnDefinition Width="*"/>
|
||||
</Grid.ColumnDefinitions>
|
||||
@@ -172,13 +237,13 @@
|
||||
<!-- LEFT: Photos panel -->
|
||||
<DockPanel Grid.Column="0">
|
||||
<TextBlock DockPanel.Dock="Top"
|
||||
Text="PHOTOS" FontSize="12" FontWeight="SemiBold"
|
||||
Foreground="{DynamicResource MahApps.Brushes.Gray5}"
|
||||
Text="PHOTOS" Style="{StaticResource SectionHeader}"
|
||||
Margin="0,0,0,8"/>
|
||||
<StackPanel DockPanel.Dock="Bottom" Orientation="Horizontal" Margin="0,8,0,0">
|
||||
<Button x:Name="AddMorePhotosBtn" Click="AddMorePhotos_Click"
|
||||
Style="{StaticResource MahApps.Styles.Button.Square}"
|
||||
Padding="8,4" FontSize="13">
|
||||
Padding="8,4" FontSize="13"
|
||||
AutomationProperties.Name="Add more photos to listing">
|
||||
<StackPanel Orientation="Horizontal">
|
||||
<iconPacks:PackIconMaterial Kind="Plus" Width="12" Height="12"
|
||||
Margin="0,0,4,0" VerticalAlignment="Center"/>
|
||||
@@ -190,17 +255,19 @@
|
||||
FontSize="13"
|
||||
Foreground="{DynamicResource MahApps.Brushes.Gray5}"/>
|
||||
</StackPanel>
|
||||
<ScrollViewer VerticalScrollBarVisibility="Auto">
|
||||
<ScrollViewer VerticalScrollBarVisibility="Auto"
|
||||
Focusable="False">
|
||||
<WrapPanel x:Name="BPhotosPanel"/>
|
||||
</ScrollViewer>
|
||||
</DockPanel>
|
||||
|
||||
<!-- RIGHT: Listing fields -->
|
||||
<ScrollViewer Grid.Column="2" VerticalScrollBarVisibility="Auto">
|
||||
<StackPanel Margin="0,0,8,16" MaxWidth="600">
|
||||
<ScrollViewer Grid.Column="2" VerticalScrollBarVisibility="Auto"
|
||||
Focusable="False">
|
||||
<StackPanel Margin="0,0,8,16" MaxWidth="600"
|
||||
KeyboardNavigation.TabNavigation="Local">
|
||||
<TextBlock Text="LISTING DETAILS"
|
||||
FontSize="12" FontWeight="SemiBold"
|
||||
Foreground="{DynamicResource MahApps.Brushes.Gray5}"
|
||||
Style="{StaticResource SectionHeader}"
|
||||
Margin="0,0,0,12"/>
|
||||
|
||||
<!-- Title -->
|
||||
@@ -209,38 +276,38 @@
|
||||
<ColumnDefinition Width="*"/>
|
||||
<ColumnDefinition Width="Auto"/>
|
||||
</Grid.ColumnDefinitions>
|
||||
<TextBlock Text="Title" FontSize="13" FontWeight="SemiBold"
|
||||
Foreground="{DynamicResource MahApps.Brushes.Gray3}"
|
||||
<TextBlock x:Name="TitleLabel" Text="Title"
|
||||
Style="{StaticResource FieldLabel}"
|
||||
VerticalAlignment="Center"/>
|
||||
<Button Grid.Column="1" x:Name="AiTitleBtn" Click="AiTitle_Click"
|
||||
Style="{StaticResource MahApps.Styles.Button.Square}"
|
||||
Padding="6,2" ToolTip="Improve title with AI">
|
||||
Style="{StaticResource AiActionButton}"
|
||||
ToolTip="Improve title with AI"
|
||||
AutomationProperties.Name="Improve title with AI">
|
||||
<StackPanel Orientation="Horizontal">
|
||||
<iconPacks:PackIconMaterial x:Name="TitleAiIcon"
|
||||
Kind="AutoFix" Width="12" Height="12"
|
||||
Margin="0,0,4,0" VerticalAlignment="Center"/>
|
||||
<mah:ProgressRing x:Name="TitleSpinner" Width="12" Height="12"
|
||||
Margin="0,0,4,0" Visibility="Collapsed"/>
|
||||
Margin="0,0,4,0" Visibility="Collapsed"
|
||||
IsTabStop="False"/>
|
||||
<TextBlock Text="AI" FontSize="12" VerticalAlignment="Center"/>
|
||||
</StackPanel>
|
||||
</Button>
|
||||
</Grid>
|
||||
<TextBox x:Name="BTitleBox" TextChanged="TitleBox_TextChanged"
|
||||
MaxLength="80" Margin="0,0,0,2"/>
|
||||
MaxLength="80" Margin="0,0,0,2"
|
||||
AutomationProperties.LabeledBy="{Binding ElementName=TitleLabel}"/>
|
||||
<Grid Margin="0,0,0,12">
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="*"/>
|
||||
<ColumnDefinition Width="Auto"/>
|
||||
</Grid.ColumnDefinitions>
|
||||
<Border Height="3" CornerRadius="1.5"
|
||||
Background="{DynamicResource MahApps.Brushes.Gray8}">
|
||||
<Border x:Name="BTitleBar" Height="3" CornerRadius="1.5"
|
||||
HorizontalAlignment="Left" Width="0"
|
||||
<Border Style="{StaticResource ProgressTrack}">
|
||||
<Border x:Name="BTitleBar" Style="{StaticResource ProgressFill}"
|
||||
Background="{DynamicResource MahApps.Brushes.Accent}"/>
|
||||
</Border>
|
||||
<TextBlock x:Name="BTitleCount" Grid.Column="1"
|
||||
Text="0 / 80" FontSize="12" Margin="6,0,0,0"
|
||||
Foreground="{DynamicResource MahApps.Brushes.Gray5}"/>
|
||||
Text="0 / 80" Style="{StaticResource CharCountLabel}"/>
|
||||
</Grid>
|
||||
|
||||
<!-- Description -->
|
||||
@@ -249,18 +316,20 @@
|
||||
<ColumnDefinition Width="*"/>
|
||||
<ColumnDefinition Width="Auto"/>
|
||||
</Grid.ColumnDefinitions>
|
||||
<TextBlock Text="Description" FontSize="13" FontWeight="SemiBold"
|
||||
Foreground="{DynamicResource MahApps.Brushes.Gray3}"
|
||||
<TextBlock x:Name="DescLabel" Text="Description"
|
||||
Style="{StaticResource FieldLabel}"
|
||||
VerticalAlignment="Center"/>
|
||||
<Button Grid.Column="1" x:Name="AiDescBtn" Click="AiDesc_Click"
|
||||
Style="{StaticResource MahApps.Styles.Button.Square}"
|
||||
Padding="6,2" ToolTip="Write description with AI">
|
||||
Style="{StaticResource AiActionButton}"
|
||||
ToolTip="Write description with AI"
|
||||
AutomationProperties.Name="Write description with AI">
|
||||
<StackPanel Orientation="Horizontal">
|
||||
<iconPacks:PackIconMaterial x:Name="DescAiIcon"
|
||||
Kind="AutoFix" Width="12" Height="12"
|
||||
Margin="0,0,4,0" VerticalAlignment="Center"/>
|
||||
<mah:ProgressRing x:Name="DescSpinner" Width="12" Height="12"
|
||||
Margin="0,0,4,0" Visibility="Collapsed"/>
|
||||
Margin="0,0,4,0" Visibility="Collapsed"
|
||||
IsTabStop="False"/>
|
||||
<TextBlock Text="AI" FontSize="12" VerticalAlignment="Center"/>
|
||||
</StackPanel>
|
||||
</Button>
|
||||
@@ -268,32 +337,31 @@
|
||||
<TextBox x:Name="BDescBox" TextChanged="DescBox_TextChanged"
|
||||
AcceptsReturn="True" TextWrapping="Wrap"
|
||||
Height="110" VerticalScrollBarVisibility="Auto"
|
||||
Margin="0,0,0,2"/>
|
||||
Margin="0,0,0,2"
|
||||
AutomationProperties.LabeledBy="{Binding ElementName=DescLabel}"/>
|
||||
<Grid Margin="0,0,0,12">
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="*"/>
|
||||
<ColumnDefinition Width="Auto"/>
|
||||
</Grid.ColumnDefinitions>
|
||||
<Border Height="3" CornerRadius="1.5"
|
||||
Background="{DynamicResource MahApps.Brushes.Gray8}">
|
||||
<Border x:Name="BDescBar" Height="3" CornerRadius="1.5"
|
||||
HorizontalAlignment="Left" Width="0"
|
||||
<Border Style="{StaticResource ProgressTrack}">
|
||||
<Border x:Name="BDescBar" Style="{StaticResource ProgressFill}"
|
||||
Background="{DynamicResource MahApps.Brushes.Accent}"/>
|
||||
</Border>
|
||||
<TextBlock x:Name="BDescCount" Grid.Column="1"
|
||||
Text="0 / 2000" FontSize="12" Margin="6,0,0,0"
|
||||
Foreground="{DynamicResource MahApps.Brushes.Gray5}"/>
|
||||
Text="0 / 2000" Style="{StaticResource CharCountLabel}"/>
|
||||
</Grid>
|
||||
|
||||
<!-- Category -->
|
||||
<TextBlock Text="Category" FontSize="13" FontWeight="SemiBold"
|
||||
Foreground="{DynamicResource MahApps.Brushes.Gray3}"
|
||||
<TextBlock x:Name="CategoryLabel" Text="Category"
|
||||
Style="{StaticResource FieldLabel}"
|
||||
Margin="0,0,0,4"/>
|
||||
<Grid Margin="0,0,0,2">
|
||||
<TextBox x:Name="BCategoryBox"
|
||||
TextChanged="CategoryBox_TextChanged"
|
||||
KeyDown="CategoryBox_KeyDown"
|
||||
mah:TextBoxHelper.Watermark="Type to search categories…"/>
|
||||
mah:TextBoxHelper.Watermark="Type to search categories."
|
||||
AutomationProperties.LabeledBy="{Binding ElementName=CategoryLabel}"/>
|
||||
<ListBox x:Name="BCategoryList"
|
||||
Visibility="Collapsed"
|
||||
SelectionChanged="CategoryList_SelectionChanged"
|
||||
@@ -302,7 +370,11 @@
|
||||
Margin="0,32,0,0"
|
||||
Panel.ZIndex="10"
|
||||
Background="{DynamicResource MahApps.Brushes.Gray8}"
|
||||
BorderBrush="{DynamicResource MahApps.Brushes.Gray6}"/>
|
||||
BorderBrush="{DynamicResource MahApps.Brushes.Gray6}"
|
||||
VirtualizingPanel.IsVirtualizing="True"
|
||||
VirtualizingPanel.VirtualizationMode="Recycling"
|
||||
ScrollViewer.CanContentScroll="True"
|
||||
AutomationProperties.Name="Category suggestions"/>
|
||||
</Grid>
|
||||
<TextBlock x:Name="BCategoryIdLabel"
|
||||
Text="(no category selected)"
|
||||
@@ -317,11 +389,12 @@
|
||||
<ColumnDefinition Width="*"/>
|
||||
</Grid.ColumnDefinitions>
|
||||
<StackPanel Grid.Column="0">
|
||||
<TextBlock Text="Condition" FontSize="13" FontWeight="SemiBold"
|
||||
Foreground="{DynamicResource MahApps.Brushes.Gray3}"
|
||||
<TextBlock x:Name="ConditionLabel" Text="Condition"
|
||||
Style="{StaticResource FieldLabel}"
|
||||
Margin="0,0,0,4"/>
|
||||
<ComboBox x:Name="BConditionBox"
|
||||
SelectionChanged="ConditionBox_SelectionChanged">
|
||||
SelectionChanged="ConditionBox_SelectionChanged"
|
||||
AutomationProperties.LabeledBy="{Binding ElementName=ConditionLabel}">
|
||||
<ComboBoxItem Content="New" Tag="New"/>
|
||||
<ComboBoxItem Content="Open Box" Tag="OpenBox"/>
|
||||
<ComboBoxItem Content="Refurbished" Tag="Refurbished"/>
|
||||
@@ -330,10 +403,11 @@
|
||||
</ComboBox>
|
||||
</StackPanel>
|
||||
<StackPanel Grid.Column="2">
|
||||
<TextBlock Text="Format" FontSize="13" FontWeight="SemiBold"
|
||||
Foreground="{DynamicResource MahApps.Brushes.Gray3}"
|
||||
<TextBlock x:Name="FormatLabel" Text="Format"
|
||||
Style="{StaticResource FieldLabel}"
|
||||
Margin="0,0,0,4"/>
|
||||
<ComboBox x:Name="BFormatBox">
|
||||
<ComboBox x:Name="BFormatBox"
|
||||
AutomationProperties.LabeledBy="{Binding ElementName=FormatLabel}">
|
||||
<ComboBoxItem Content="Fixed Price" IsSelected="True"/>
|
||||
<ComboBoxItem Content="Auction"/>
|
||||
</ComboBox>
|
||||
@@ -346,27 +420,30 @@
|
||||
<ColumnDefinition Width="*"/>
|
||||
<ColumnDefinition Width="Auto"/>
|
||||
</Grid.ColumnDefinitions>
|
||||
<TextBlock Text="Price" FontSize="13" FontWeight="SemiBold"
|
||||
Foreground="{DynamicResource MahApps.Brushes.Gray3}"
|
||||
<TextBlock x:Name="PriceLabel" Text="Price"
|
||||
Style="{StaticResource FieldLabel}"
|
||||
VerticalAlignment="Center"/>
|
||||
<Button Grid.Column="1" x:Name="AiPriceBtn" Click="AiPrice_Click"
|
||||
Style="{StaticResource MahApps.Styles.Button.Square}"
|
||||
Padding="6,2" ToolTip="Research live eBay price">
|
||||
Style="{StaticResource AiActionButton}"
|
||||
ToolTip="Research live eBay price"
|
||||
AutomationProperties.Name="Research live eBay price">
|
||||
<StackPanel Orientation="Horizontal">
|
||||
<iconPacks:PackIconMaterial x:Name="PriceAiIcon"
|
||||
Kind="Magnify" Width="12" Height="12"
|
||||
Margin="0,0,4,0" VerticalAlignment="Center"/>
|
||||
<mah:ProgressRing x:Name="PriceSpinner" Width="12" Height="12"
|
||||
Margin="0,0,4,0" Visibility="Collapsed"/>
|
||||
Margin="0,0,4,0" Visibility="Collapsed"
|
||||
IsTabStop="False"/>
|
||||
<TextBlock Text="Research" FontSize="12" VerticalAlignment="Center"/>
|
||||
</StackPanel>
|
||||
</Button>
|
||||
</Grid>
|
||||
<mah:NumericUpDown x:Name="BPriceBox"
|
||||
StringFormat="£{0:0.00}"
|
||||
StringFormat="£{0:0.00}"
|
||||
Minimum="0" Maximum="99999"
|
||||
Interval="0.50"
|
||||
Margin="0,0,0,4"/>
|
||||
Margin="0,0,0,4"
|
||||
AutomationProperties.LabeledBy="{Binding ElementName=PriceLabel}"/>
|
||||
<TextBlock x:Name="BPriceHint"
|
||||
FontSize="12" Margin="0,0,0,12"
|
||||
Visibility="Collapsed"
|
||||
@@ -380,10 +457,11 @@
|
||||
<ColumnDefinition Width="120"/>
|
||||
</Grid.ColumnDefinitions>
|
||||
<StackPanel Grid.Column="0">
|
||||
<TextBlock Text="Postage" FontSize="13" FontWeight="SemiBold"
|
||||
Foreground="{DynamicResource MahApps.Brushes.Gray3}"
|
||||
<TextBlock x:Name="PostageLabel" Text="Postage"
|
||||
Style="{StaticResource FieldLabel}"
|
||||
Margin="0,0,0,4"/>
|
||||
<ComboBox x:Name="BPostageBox">
|
||||
<ComboBox x:Name="BPostageBox"
|
||||
AutomationProperties.LabeledBy="{Binding ElementName=PostageLabel}">
|
||||
<ComboBoxItem Content="Royal Mail 1st Class" Tag="RoyalMailFirstClass"/>
|
||||
<ComboBoxItem Content="Royal Mail 2nd Class" Tag="RoyalMailSecondClass" IsSelected="True"/>
|
||||
<ComboBoxItem Content="Royal Mail Tracked 24" Tag="RoyalMailTracked24"/>
|
||||
@@ -393,10 +471,11 @@
|
||||
</ComboBox>
|
||||
</StackPanel>
|
||||
<StackPanel Grid.Column="2">
|
||||
<TextBlock Text="From postcode" FontSize="13" FontWeight="SemiBold"
|
||||
Foreground="{DynamicResource MahApps.Brushes.Gray3}"
|
||||
<TextBlock x:Name="PostcodeLabel" Text="From postcode"
|
||||
Style="{StaticResource FieldLabel}"
|
||||
Margin="0,0,0,4"/>
|
||||
<TextBox x:Name="BPostcodeBox"/>
|
||||
<TextBox x:Name="BPostcodeBox"
|
||||
AutomationProperties.LabeledBy="{Binding ElementName=PostcodeLabel}"/>
|
||||
</StackPanel>
|
||||
</Grid>
|
||||
</StackPanel>
|
||||
@@ -405,7 +484,7 @@
|
||||
</DockPanel>
|
||||
</Grid>
|
||||
|
||||
<!-- â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â•â• STATE C: Success -->
|
||||
<!-- STATE C: Success -->
|
||||
<Grid x:Name="StateC" Visibility="Collapsed">
|
||||
<StackPanel HorizontalAlignment="Center" VerticalAlignment="Center" MaxWidth="480">
|
||||
<!-- Success banner -->
|
||||
@@ -413,7 +492,8 @@
|
||||
CornerRadius="8" Padding="24,16" Margin="0,0,0,28">
|
||||
<StackPanel Orientation="Horizontal" HorizontalAlignment="Center">
|
||||
<iconPacks:PackIconMaterial Kind="CheckCircleOutline" Width="24" Height="24"
|
||||
Foreground="#4CAF50" VerticalAlignment="Center" Margin="0,0,12,0"/>
|
||||
Foreground="#4CAF50" VerticalAlignment="Center" Margin="0,0,12,0"
|
||||
IsTabStop="False"/>
|
||||
<TextBlock Text="Listed successfully!" FontSize="18" FontWeight="SemiBold"
|
||||
Foreground="#4CAF50" VerticalAlignment="Center"/>
|
||||
</StackPanel>
|
||||
@@ -427,10 +507,12 @@
|
||||
Foreground="{DynamicResource MahApps.Brushes.Accent}"
|
||||
HorizontalAlignment="Center" Cursor="Hand" TextWrapping="Wrap"
|
||||
TextAlignment="Center" Margin="0,0,0,16"
|
||||
MouseLeftButtonUp="SuccessUrl_Click"/>
|
||||
MouseLeftButtonUp="SuccessUrl_Click"
|
||||
AutomationProperties.Name="Listing URL - click to open"/>
|
||||
<Button x:Name="CopyUrlBtn" Click="CopyUrl_Click"
|
||||
Style="{StaticResource MahApps.Styles.Button.Square}"
|
||||
HorizontalAlignment="Center" Padding="16,8" Margin="0,0,0,36">
|
||||
HorizontalAlignment="Center" Padding="16,8" Margin="0,0,0,36"
|
||||
AutomationProperties.Name="Copy listing URL to clipboard">
|
||||
<StackPanel Orientation="Horizontal">
|
||||
<iconPacks:PackIconMaterial Kind="ContentCopy" Width="13" Height="13"
|
||||
Margin="0,0,6,0" VerticalAlignment="Center"/>
|
||||
@@ -440,7 +522,8 @@
|
||||
<!-- List Another -->
|
||||
<Button Click="ListAnother_Click"
|
||||
Style="{StaticResource MahApps.Styles.Button.Square.Accent}"
|
||||
HorizontalAlignment="Center" Padding="24,12" FontSize="14">
|
||||
HorizontalAlignment="Center" Padding="24,12" FontSize="14"
|
||||
AutomationProperties.Name="List another item">
|
||||
<StackPanel Orientation="Horizontal">
|
||||
<iconPacks:PackIconMaterial Kind="Plus" Width="16" Height="16"
|
||||
Margin="0,0,8,0" VerticalAlignment="Center"/>
|
||||
|
||||
@@ -2,7 +2,8 @@
|
||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||
xmlns:mah="http://metro.mahapps.com/winfx/xaml/controls"
|
||||
xmlns:iconPacks="http://metro.mahapps.com/winfx/xaml/iconpacks">
|
||||
xmlns:iconPacks="http://metro.mahapps.com/winfx/xaml/iconpacks"
|
||||
KeyboardNavigation.TabNavigation="Cycle">
|
||||
|
||||
<UserControl.Resources>
|
||||
|
||||
@@ -41,6 +42,22 @@
|
||||
<Setter Property="Height" Value="30"/>
|
||||
</Style>
|
||||
|
||||
<!-- Shared style for detail action buttons -->
|
||||
<Style x:Key="DetailActionButton" TargetType="Button"
|
||||
BasedOn="{StaticResource MahApps.Styles.Button.Square.Accent}">
|
||||
<Setter Property="Height" Value="34"/>
|
||||
<Setter Property="Padding" Value="14,0"/>
|
||||
<Setter Property="Margin" Value="0,0,8,6"/>
|
||||
</Style>
|
||||
|
||||
<!-- Shared style for secondary detail action buttons -->
|
||||
<Style x:Key="DetailSecondaryButton" TargetType="Button"
|
||||
BasedOn="{StaticResource MahApps.Styles.Button.Square}">
|
||||
<Setter Property="Height" Value="34"/>
|
||||
<Setter Property="Padding" Value="12,0"/>
|
||||
<Setter Property="Margin" Value="0,0,8,6"/>
|
||||
</Style>
|
||||
|
||||
</UserControl.Resources>
|
||||
|
||||
<Grid>
|
||||
@@ -51,7 +68,7 @@
|
||||
</Grid.ColumnDefinitions>
|
||||
|
||||
<!-- ================================================================
|
||||
LEFT — Listings list
|
||||
LEFT - Listings list
|
||||
================================================================ -->
|
||||
<Grid Grid.Column="0">
|
||||
<Grid.RowDefinitions>
|
||||
@@ -72,7 +89,8 @@
|
||||
<StackPanel Grid.Column="0" Orientation="Horizontal">
|
||||
<iconPacks:PackIconMaterial Kind="BookmarkMultiple" Width="14" Height="14"
|
||||
Margin="0,0,7,0" VerticalAlignment="Center"
|
||||
Foreground="{DynamicResource MahApps.Brushes.Accent}"/>
|
||||
Foreground="{DynamicResource MahApps.Brushes.Accent}"
|
||||
IsTabStop="False"/>
|
||||
<TextBlock x:Name="ListingCountText" Text="0 saved listings"
|
||||
FontSize="12" FontWeight="SemiBold"
|
||||
Foreground="{DynamicResource MahApps.Brushes.Gray2}"
|
||||
@@ -81,7 +99,8 @@
|
||||
<Button Grid.Column="1" x:Name="OpenExportsDirBtn"
|
||||
Click="OpenExportsDir_Click"
|
||||
Style="{StaticResource CardActionBtn}"
|
||||
ToolTip="Open exports folder in Explorer">
|
||||
ToolTip="Open exports folder in Explorer"
|
||||
AutomationProperties.Name="Open exports folder in Explorer">
|
||||
<StackPanel Orientation="Horizontal">
|
||||
<iconPacks:PackIconMaterial Kind="FolderOpen" Width="12" Height="12"
|
||||
Margin="0,0,4,0" VerticalAlignment="Center"/>
|
||||
@@ -104,18 +123,20 @@
|
||||
Width="13" Height="13"
|
||||
Margin="0,0,7,0"
|
||||
VerticalAlignment="Center"
|
||||
Foreground="{DynamicResource MahApps.Brushes.Gray5}"/>
|
||||
Foreground="{DynamicResource MahApps.Brushes.Gray5}"
|
||||
IsTabStop="False"/>
|
||||
<TextBox Grid.Column="1" x:Name="SearchBox"
|
||||
Style="{StaticResource SearchBox}"
|
||||
mah:TextBoxHelper.Watermark="Filter listings…"
|
||||
mah:TextBoxHelper.Watermark="Filter listings..."
|
||||
mah:TextBoxHelper.ClearTextButton="True"
|
||||
TextChanged="SearchBox_TextChanged"/>
|
||||
TextChanged="SearchBox_TextChanged"
|
||||
AutomationProperties.Name="Filter saved listings"/>
|
||||
</Grid>
|
||||
</Border>
|
||||
|
||||
<!-- Card list -->
|
||||
<ScrollViewer Grid.Row="2" VerticalScrollBarVisibility="Auto"
|
||||
Padding="10,8">
|
||||
Padding="10,8" Focusable="False">
|
||||
<Grid>
|
||||
<!-- Empty state for no saved listings -->
|
||||
<StackPanel x:Name="EmptyCardState"
|
||||
@@ -128,11 +149,13 @@
|
||||
HorizontalAlignment="Center"
|
||||
Margin="0,0,0,16"
|
||||
Background="{DynamicResource MahApps.Brushes.Gray9}">
|
||||
|
||||
<iconPacks:PackIconMaterial Kind="BookmarkPlusOutline"
|
||||
Width="32" Height="32"
|
||||
HorizontalAlignment="Center"
|
||||
VerticalAlignment="Center"
|
||||
Foreground="{DynamicResource MahApps.Brushes.Gray5}"/>
|
||||
Foreground="{DynamicResource MahApps.Brushes.Gray5}"
|
||||
IsTabStop="False"/>
|
||||
</Border>
|
||||
<TextBlock Text="No saved listings yet"
|
||||
FontSize="13" FontWeight="SemiBold"
|
||||
@@ -158,7 +181,8 @@
|
||||
Width="36" Height="36"
|
||||
HorizontalAlignment="Center"
|
||||
Foreground="{DynamicResource MahApps.Brushes.Gray6}"
|
||||
Margin="0,0,0,12"/>
|
||||
Margin="0,0,0,12"
|
||||
IsTabStop="False"/>
|
||||
<TextBlock Text="No listings match your search"
|
||||
FontSize="12"
|
||||
Foreground="{DynamicResource MahApps.Brushes.Gray5}"
|
||||
@@ -172,10 +196,11 @@
|
||||
|
||||
<!-- Splitter -->
|
||||
<GridSplitter Grid.Column="1" Width="4" HorizontalAlignment="Stretch"
|
||||
Background="{DynamicResource MahApps.Brushes.Gray8}"/>
|
||||
Background="{DynamicResource MahApps.Brushes.Gray8}"
|
||||
AutomationProperties.Name="Resize listings panel"/>
|
||||
|
||||
<!-- ================================================================
|
||||
RIGHT — Detail panel
|
||||
RIGHT - Detail panel
|
||||
================================================================ -->
|
||||
<Grid Grid.Column="2">
|
||||
|
||||
@@ -185,7 +210,8 @@
|
||||
<iconPacks:PackIconMaterial Kind="BookmarkOutline" Width="48" Height="48"
|
||||
HorizontalAlignment="Center"
|
||||
Foreground="{DynamicResource MahApps.Brushes.Gray7}"
|
||||
Margin="0,0,0,14"/>
|
||||
Margin="0,0,0,14"
|
||||
IsTabStop="False"/>
|
||||
<TextBlock Text="Select a saved listing" FontSize="14"
|
||||
Foreground="{DynamicResource MahApps.Brushes.Gray5}"
|
||||
HorizontalAlignment="Center"/>
|
||||
@@ -193,7 +219,8 @@
|
||||
|
||||
<!-- Detail content -->
|
||||
<ScrollViewer x:Name="DetailPanel" Visibility="Collapsed" Opacity="0"
|
||||
VerticalScrollBarVisibility="Auto" Padding="18,14">
|
||||
VerticalScrollBarVisibility="Auto" Padding="18,14"
|
||||
Focusable="False">
|
||||
<StackPanel>
|
||||
|
||||
<!-- Title + price row -->
|
||||
@@ -219,7 +246,8 @@
|
||||
<Button x:Name="RevalueBtn" Click="RevalueBtn_Click"
|
||||
Height="28" Padding="8,0" Margin="6,0,0,0"
|
||||
Style="{DynamicResource MahApps.Styles.Button.Square}"
|
||||
ToolTip="Quick-change the price">
|
||||
ToolTip="Quick-change the price"
|
||||
AutomationProperties.Name="Quick-change the price">
|
||||
<StackPanel Orientation="Horizontal">
|
||||
<iconPacks:PackIconMaterial Kind="CurrencyGbp" Width="11" Height="11"
|
||||
Margin="0,0,4,0" VerticalAlignment="Center"/>
|
||||
@@ -235,11 +263,13 @@
|
||||
<mah:NumericUpDown x:Name="RevaluePrice"
|
||||
Minimum="0" Maximum="99999"
|
||||
StringFormat="F2" Interval="0.5"
|
||||
Width="110" Height="30"/>
|
||||
Width="110" Height="30"
|
||||
AutomationProperties.Name="New price value"/>
|
||||
<Button x:Name="CheckEbayBtn" Click="CheckEbayBtn_Click"
|
||||
Height="30" Padding="8,0" Margin="6,0,4,0"
|
||||
Style="{DynamicResource MahApps.Styles.Button.Square}"
|
||||
ToolTip="Check eBay for a suggested price">
|
||||
ToolTip="Check eBay for a suggested price"
|
||||
AutomationProperties.Name="Check eBay for suggested price">
|
||||
<StackPanel Orientation="Horizontal">
|
||||
<iconPacks:PackIconMaterial x:Name="CheckEbayIcon"
|
||||
Kind="Magnify" Width="11" Height="11"
|
||||
@@ -251,13 +281,15 @@
|
||||
<Button Click="RevalueSave_Click"
|
||||
Style="{DynamicResource MahApps.Styles.Button.Square.Accent}"
|
||||
Height="30" Padding="10,0" Margin="0,0,4,0"
|
||||
ToolTip="Save new price">
|
||||
ToolTip="Save new price"
|
||||
AutomationProperties.Name="Save new price">
|
||||
<iconPacks:PackIconMaterial Kind="Check" Width="13" Height="13"/>
|
||||
</Button>
|
||||
<Button Click="RevalueCancel_Click"
|
||||
Style="{DynamicResource MahApps.Styles.Button.Square}"
|
||||
Height="30" Padding="8,0"
|
||||
ToolTip="Cancel">
|
||||
ToolTip="Cancel"
|
||||
AutomationProperties.Name="Cancel price change">
|
||||
<iconPacks:PackIconMaterial Kind="Close" Width="11" Height="11"/>
|
||||
</Button>
|
||||
</StackPanel>
|
||||
@@ -270,20 +302,22 @@
|
||||
</StackPanel>
|
||||
</Grid>
|
||||
|
||||
<!-- Meta row: category · date -->
|
||||
<!-- Meta row: category / date -->
|
||||
<StackPanel Orientation="Horizontal" Margin="0,0,0,14">
|
||||
<iconPacks:PackIconMaterial Kind="Tag" Width="11" Height="11"
|
||||
Margin="0,0,4,0" VerticalAlignment="Center"
|
||||
Foreground="{DynamicResource MahApps.Brushes.Gray5}"/>
|
||||
Foreground="{DynamicResource MahApps.Brushes.Gray5}"
|
||||
IsTabStop="False"/>
|
||||
<TextBlock x:Name="DetailCategory" FontSize="11"
|
||||
Foreground="{DynamicResource MahApps.Brushes.Gray4}"
|
||||
VerticalAlignment="Center"/>
|
||||
<TextBlock Text=" · " FontSize="11"
|
||||
<TextBlock Text=" | " FontSize="11"
|
||||
Foreground="{DynamicResource MahApps.Brushes.Gray6}"
|
||||
VerticalAlignment="Center"/>
|
||||
<iconPacks:PackIconMaterial Kind="ClockOutline" Width="11" Height="11"
|
||||
Margin="0,0,4,0" VerticalAlignment="Center"
|
||||
Foreground="{DynamicResource MahApps.Brushes.Gray5}"/>
|
||||
Foreground="{DynamicResource MahApps.Brushes.Gray5}"
|
||||
IsTabStop="False"/>
|
||||
<TextBlock x:Name="DetailDate" FontSize="11"
|
||||
Foreground="{DynamicResource MahApps.Brushes.Gray4}"
|
||||
VerticalAlignment="Center"/>
|
||||
@@ -293,6 +327,7 @@
|
||||
<TextBlock Text="PHOTOS" Style="{StaticResource DetailLabel}"/>
|
||||
<ScrollViewer HorizontalScrollBarVisibility="Auto"
|
||||
VerticalScrollBarVisibility="Disabled"
|
||||
Focusable="False"
|
||||
Margin="0,0,0,4">
|
||||
<WrapPanel x:Name="DetailPhotosPanel" Orientation="Horizontal"/>
|
||||
</ScrollViewer>
|
||||
@@ -320,22 +355,23 @@
|
||||
<WrapPanel Orientation="Horizontal">
|
||||
<Button x:Name="PostDraftBtn"
|
||||
Click="PostDraft_Click"
|
||||
Style="{StaticResource MahApps.Styles.Button.Square.Accent}"
|
||||
Height="34" Padding="14,0" Margin="0,0,8,6"
|
||||
ToolTip="Post this draft to eBay">
|
||||
Style="{StaticResource DetailActionButton}"
|
||||
ToolTip="Post this draft to eBay"
|
||||
AutomationProperties.Name="Post draft to eBay">
|
||||
<StackPanel Orientation="Horizontal">
|
||||
<iconPacks:PackIconMaterial x:Name="PostDraftIcon"
|
||||
Kind="CartArrowRight" Width="14" Height="14"
|
||||
Margin="0,0,6,0" VerticalAlignment="Center"/>
|
||||
<mah:ProgressRing x:Name="PostDraftSpinner"
|
||||
Width="14" Height="14" Margin="0,0,6,0"
|
||||
Visibility="Collapsed"/>
|
||||
Visibility="Collapsed"
|
||||
IsTabStop="False"/>
|
||||
<TextBlock Text="Post to eBay" VerticalAlignment="Center"/>
|
||||
</StackPanel>
|
||||
</Button>
|
||||
<Button Click="EditListing_Click"
|
||||
Style="{DynamicResource MahApps.Styles.Button.Square.Accent}"
|
||||
Height="34" Padding="14,0" Margin="0,0,8,6">
|
||||
Style="{StaticResource DetailActionButton}"
|
||||
AutomationProperties.Name="Edit this listing">
|
||||
<StackPanel Orientation="Horizontal">
|
||||
<iconPacks:PackIconMaterial Kind="Pencil" Width="13" Height="13"
|
||||
Margin="0,0,6,0" VerticalAlignment="Center"/>
|
||||
@@ -343,8 +379,8 @@
|
||||
</StackPanel>
|
||||
</Button>
|
||||
<Button Click="OpenFolderDetail_Click"
|
||||
Style="{DynamicResource MahApps.Styles.Button.Square.Accent}"
|
||||
Height="34" Padding="14,0" Margin="0,0,8,6">
|
||||
Style="{StaticResource DetailActionButton}"
|
||||
AutomationProperties.Name="Open export folder for this listing">
|
||||
<StackPanel Orientation="Horizontal">
|
||||
<iconPacks:PackIconMaterial Kind="FolderOpen" Width="13" Height="13"
|
||||
Margin="0,0,6,0" VerticalAlignment="Center"/>
|
||||
@@ -352,8 +388,8 @@
|
||||
</StackPanel>
|
||||
</Button>
|
||||
<Button Click="CopyTitle_Click"
|
||||
Style="{DynamicResource MahApps.Styles.Button.Square}"
|
||||
Height="34" Padding="12,0" Margin="0,0,8,6">
|
||||
Style="{StaticResource DetailSecondaryButton}"
|
||||
AutomationProperties.Name="Copy listing title to clipboard">
|
||||
<Button.Content>
|
||||
<StackPanel Orientation="Horizontal">
|
||||
<iconPacks:PackIconMaterial Kind="ContentCopy" Width="12" Height="12"
|
||||
@@ -363,8 +399,8 @@
|
||||
</Button.Content>
|
||||
</Button>
|
||||
<Button Click="CopyDescription_Click"
|
||||
Style="{DynamicResource MahApps.Styles.Button.Square}"
|
||||
Height="34" Padding="12,0" Margin="0,0,8,6">
|
||||
Style="{StaticResource DetailSecondaryButton}"
|
||||
AutomationProperties.Name="Copy listing description to clipboard">
|
||||
<Button.Content>
|
||||
<StackPanel Orientation="Horizontal">
|
||||
<iconPacks:PackIconMaterial Kind="ContentCopy" Width="12" Height="12"
|
||||
@@ -374,8 +410,9 @@
|
||||
</Button.Content>
|
||||
</Button>
|
||||
<Button Click="DeleteListing_Click"
|
||||
Style="{DynamicResource MahApps.Styles.Button.Square}"
|
||||
Height="34" Padding="12,0" Margin="0,0,0,6">
|
||||
Style="{StaticResource MahApps.Styles.Button.Square}"
|
||||
Height="34" Padding="12,0" Margin="0,0,0,6"
|
||||
AutomationProperties.Name="Delete this listing">
|
||||
<Button.Content>
|
||||
<StackPanel Orientation="Horizontal">
|
||||
<iconPacks:PackIconMaterial Kind="TrashCanOutline" Width="13" Height="13"
|
||||
@@ -391,15 +428,17 @@
|
||||
</StackPanel>
|
||||
</ScrollViewer>
|
||||
|
||||
<!-- Edit panel — shown in place of DetailPanel when editing -->
|
||||
<!-- Edit panel - shown in place of DetailPanel when editing -->
|
||||
<ScrollViewer x:Name="EditPanel" Visibility="Collapsed"
|
||||
VerticalScrollBarVisibility="Auto" Padding="18,14">
|
||||
<StackPanel>
|
||||
VerticalScrollBarVisibility="Auto" Padding="18,14"
|
||||
Focusable="False">
|
||||
<StackPanel KeyboardNavigation.TabNavigation="Local">
|
||||
|
||||
<!-- Title -->
|
||||
<TextBlock Text="TITLE" Style="{StaticResource DetailLabel}" Margin="0,0,0,3"/>
|
||||
<TextBlock x:Name="EditTitleLabel" Text="TITLE" Style="{StaticResource DetailLabel}" Margin="0,0,0,3"/>
|
||||
<TextBox x:Name="EditTitle" FontSize="13" Margin="0,0,0,4"
|
||||
mah:TextBoxHelper.Watermark="Listing title"/>
|
||||
mah:TextBoxHelper.Watermark="Listing title"
|
||||
AutomationProperties.LabeledBy="{Binding ElementName=EditTitleLabel}"/>
|
||||
|
||||
<!-- Price + Category -->
|
||||
<Grid Margin="0,0,0,4">
|
||||
@@ -409,35 +448,40 @@
|
||||
<ColumnDefinition Width="*"/>
|
||||
</Grid.ColumnDefinitions>
|
||||
<StackPanel Grid.Column="0">
|
||||
<TextBlock Text="PRICE (£)" Style="{StaticResource DetailLabel}" Margin="0,0,0,3"/>
|
||||
<TextBlock x:Name="EditPriceLabel" Text="PRICE" Style="{StaticResource DetailLabel}" Margin="0,0,0,3"/>
|
||||
<mah:NumericUpDown x:Name="EditPrice" Minimum="0" Maximum="99999"
|
||||
StringFormat="F2" Interval="0.5" Value="0"/>
|
||||
StringFormat="F2" Interval="0.5" Value="0"
|
||||
AutomationProperties.LabeledBy="{Binding ElementName=EditPriceLabel}"/>
|
||||
</StackPanel>
|
||||
<StackPanel Grid.Column="2">
|
||||
<TextBlock Text="CATEGORY" Style="{StaticResource DetailLabel}" Margin="0,0,0,3"/>
|
||||
<TextBlock x:Name="EditCategoryLabel" Text="CATEGORY" Style="{StaticResource DetailLabel}" Margin="0,0,0,3"/>
|
||||
<TextBox x:Name="EditCategory" FontSize="12"
|
||||
mah:TextBoxHelper.Watermark="e.g. Clothing, Shoes & Accessories"/>
|
||||
mah:TextBoxHelper.Watermark="e.g. Clothing, Shoes & Accessories"
|
||||
AutomationProperties.LabeledBy="{Binding ElementName=EditCategoryLabel}"/>
|
||||
</StackPanel>
|
||||
</Grid>
|
||||
|
||||
<!-- Condition notes -->
|
||||
<TextBlock Text="CONDITION NOTES" Style="{StaticResource DetailLabel}" Margin="0,0,0,3"/>
|
||||
<TextBlock x:Name="EditConditionLabel" Text="CONDITION NOTES" Style="{StaticResource DetailLabel}" Margin="0,0,0,3"/>
|
||||
<TextBox x:Name="EditCondition" FontSize="12" Margin="0,0,0,4"
|
||||
mah:TextBoxHelper.Watermark="Optional — e.g. minor scuff on base"/>
|
||||
mah:TextBoxHelper.Watermark="Optional - e.g. minor scuff on base"
|
||||
AutomationProperties.LabeledBy="{Binding ElementName=EditConditionLabel}"/>
|
||||
|
||||
<!-- Description -->
|
||||
<TextBlock Text="DESCRIPTION" Style="{StaticResource DetailLabel}" Margin="0,0,0,3"/>
|
||||
<TextBlock x:Name="EditDescriptionLabel" Text="DESCRIPTION" Style="{StaticResource DetailLabel}" Margin="0,0,0,3"/>
|
||||
<TextBox x:Name="EditDescription" FontSize="12" Margin="0,0,0,4"
|
||||
TextWrapping="Wrap" AcceptsReturn="True"
|
||||
Height="130" VerticalScrollBarVisibility="Auto"/>
|
||||
Height="130" VerticalScrollBarVisibility="Auto"
|
||||
AutomationProperties.LabeledBy="{Binding ElementName=EditDescriptionLabel}"/>
|
||||
|
||||
<!-- Photos -->
|
||||
<TextBlock Text="PHOTOS" Style="{StaticResource DetailLabel}" Margin="0,0,0,3"/>
|
||||
<TextBlock Text="First photo is the listing cover. Use ◀ ▶ to reorder."
|
||||
<TextBlock Text="First photo is the listing cover. Use arrows to reorder."
|
||||
FontSize="10" Foreground="{DynamicResource MahApps.Brushes.Gray5}"
|
||||
Margin="0,0,0,6"/>
|
||||
<ScrollViewer HorizontalScrollBarVisibility="Auto"
|
||||
VerticalScrollBarVisibility="Disabled"
|
||||
Focusable="False"
|
||||
Margin="0,0,0,10">
|
||||
<StackPanel x:Name="EditPhotosPanel" Orientation="Horizontal"/>
|
||||
</ScrollViewer>
|
||||
@@ -447,11 +491,13 @@
|
||||
<Button x:Name="SaveEditBtn" Click="SaveEdit_Click"
|
||||
Style="{DynamicResource MahApps.Styles.Button.Square.Accent}"
|
||||
Height="34" Padding="16,0" Margin="0,0,8,0"
|
||||
Content="Save Changes"/>
|
||||
Content="Save Changes"
|
||||
AutomationProperties.Name="Save listing changes"/>
|
||||
<Button x:Name="CancelEditBtn" Click="CancelEdit_Click"
|
||||
Style="{DynamicResource MahApps.Styles.Button.Square}"
|
||||
Height="34" Padding="14,0"
|
||||
Content="Cancel"/>
|
||||
Content="Cancel"
|
||||
AutomationProperties.Name="Cancel editing"/>
|
||||
</StackPanel>
|
||||
|
||||
</StackPanel>
|
||||
@@ -470,6 +516,7 @@
|
||||
BorderThickness="0,0,0,3"
|
||||
BorderBrush="{DynamicResource MahApps.Brushes.Accent}"
|
||||
Panel.ZIndex="10">
|
||||
|
||||
<Border.RenderTransform>
|
||||
<TranslateTransform x:Name="ToastTranslate" Y="60"/>
|
||||
</Border.RenderTransform>
|
||||
@@ -482,14 +529,16 @@
|
||||
<iconPacks:PackIconMaterial Kind="CheckCircleOutline"
|
||||
Width="16" Height="16" Margin="0,0,10,0"
|
||||
Foreground="{DynamicResource MahApps.Brushes.Accent}"
|
||||
VerticalAlignment="Center"/>
|
||||
VerticalAlignment="Center"
|
||||
IsTabStop="False"/>
|
||||
<TextBlock x:Name="ToastUrlText" Grid.Column="1"
|
||||
VerticalAlignment="Center" TextTrimming="CharacterEllipsis"
|
||||
Foreground="{DynamicResource MahApps.Brushes.Gray1}" FontSize="12"/>
|
||||
<Button Grid.Column="2" Content="✕" Width="20" Height="20"
|
||||
<Button Grid.Column="2" Content="x" Width="20" Height="20"
|
||||
BorderThickness="0" Background="Transparent"
|
||||
Foreground="{DynamicResource MahApps.Brushes.Gray5}"
|
||||
Click="DismissToast_Click" Margin="8,0,0,0"/>
|
||||
Click="DismissToast_Click" Margin="8,0,0,0"
|
||||
AutomationProperties.Name="Dismiss notification"/>
|
||||
</Grid>
|
||||
</Border>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user