Skip to content
Snippets Groups Projects
Commit b18d5867 authored by Sandra Borst's avatar Sandra Borst
Browse files

improved design of distractionlist screen

parent cefc46e0
No related branches found
No related tags found
1 merge request!47improved design of distractionlist screen
...@@ -116,7 +116,7 @@ HorizontalAlignment="Right" ...@@ -116,7 +116,7 @@ HorizontalAlignment="Right"
BorderThickness="0" BorderThickness="0"
TextChanged="UrlInputBox_TextChanged" /> TextChanged="UrlInputBox_TextChanged" />
<TextBlock x:Name="UrlPlaceholder" <TextBlock x:Name="UrlPlaceholder"
Text="Url" Text="Url: www.example.de"
VerticalAlignment="Center" VerticalAlignment="Center"
Foreground="Gray" Foreground="Gray"
FontSize="14" FontSize="14"
......
...@@ -5,94 +5,84 @@ ...@@ -5,94 +5,84 @@
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:local="clr-namespace:InnoLabProjektDektopApp" xmlns:local="clr-namespace:InnoLabProjektDektopApp"
xmlns:header="clr-namespace:InnoLabProjektDektopApp.Screens.Templates" xmlns:header="clr-namespace:InnoLabProjektDektopApp.Screens.Templates"
mc:Ignorable="d"> mc:Ignorable="d"
<Grid> Background="{StaticResource BACKGROUND_PRIMARY_BRUSH}">
<Grid VerticalAlignment="Center">
<StackPanel Margin="20,20,20,20"> <StackPanel Margin="20,20,20,20">
<Grid> <Grid>
<Grid.ColumnDefinitions> <Grid.ColumnDefinitions>
<ColumnDefinition Width="*" /> <ColumnDefinition Width="*" />
<!-- Überschrift -->
<ColumnDefinition Width="Auto" /> <ColumnDefinition Width="Auto" />
<!-- Suchfeld -->
</Grid.ColumnDefinitions> </Grid.ColumnDefinitions>
<Button Width="40"
Height="40"
Background="White"
BorderBrush="Black"
BorderThickness="1"
HorizontalAlignment="Left"
VerticalAlignment="Top"
Click="BackButton_Click">
<Button.Template>
<ControlTemplate TargetType="Button">
<Grid>
<Ellipse Fill="Gray" />
<TextBlock Text="←"
FontSize="16"
VerticalAlignment="Center"
HorizontalAlignment="Center" />
</Grid>
</ControlTemplate>
</Button.Template>
</Button>
<!-- Überschrift --> <!-- Überschrift -->
<TextBlock Grid.Column="0" <TextBlock Grid.Column="0"
Style="{StaticResource Header1}" Style="{StaticResource Header1}"
Text="Edit the list of websites and programs for this category" Text="Edit the list of websites for this category"
HorizontalAlignment="Left" Margin="0,46,0,-46" /> HorizontalAlignment="Left" />
<!-- Suchfeld --> <!-- Suchfeld -->
<DockPanel Grid.Column="1" HorizontalAlignment="Right" Margin="10,0,0,0">
<!-- TextBox für Suche --> <Border CornerRadius="10" Padding="10" Grid.Column="1" HorizontalAlignment="Right" Margin="10,0,0,0" Background="{StaticResource BACKGROUND_SECONDARY_BRUSH}">
<!-- Input Field with Placeholder -->
<Grid> <Grid>
<TextBox x:Name="SearchBox" <TextBox x:Name="SearchBox"
Width="150" Margin="10,0"
Height="30" Width="150"
FontSize="14" Height="30"
VerticalAlignment="Center" FontSize="14"
VerticalAlignment="Center"
Padding="5" Padding="5"
HorizontalAlignment="Left" HorizontalAlignment="Left"
Foreground="Black"
Background="Transparent" Background="Transparent"
BorderBrush="Gray" Foreground="{StaticResource TEXT_PRIMARY_BRUSH}"
BorderThickness="1" BorderBrush="{StaticResource TEXT_SECONDARY_BRUSH}"
BorderThickness="0"
TextChanged="SearchBox_TextChanged" /> TextChanged="SearchBox_TextChanged" />
<TextBlock x:Name="SearchPlaceholder" <TextBlock x:Name="SearchPlaceholder"
Text="Search..." Text="Search..."
VerticalAlignment="Center" VerticalAlignment="Center"
HorizontalAlignment="Left" HorizontalAlignment="Left"
Foreground="Gray" Foreground="{StaticResource TEXT_SECONDARY_BRUSH}"
FontSize="14" FontSize="14"
Padding="5" Padding="5"
IsHitTestVisible="False" IsHitTestVisible="False"
Margin="5,0,0,0" /> Margin="15,0,0,0" />
<!-- Untere Linie als Border -->
<Border Height="1"
Background="{StaticResource TEXT_PRIMARY_BRUSH}"
VerticalAlignment="Bottom"
HorizontalAlignment="Stretch"
Margin="10,0,40,0" />
<Border Width="30"
Height="30"
Margin="165,0,0,0"
VerticalAlignment="Center"
HorizontalAlignment="Right"
>
<TextBlock Text="🔍"
FontSize="14"
VerticalAlignment="Center"
HorizontalAlignment="Center"
/>
</Border>
</Grid> </Grid>
</Border>
<!-- Lupe-Symbol -->
<Button Width="30"
Height="30"
Margin="5,0,0,0"
VerticalAlignment="Center"
HorizontalAlignment="Right">
<TextBlock Text="🔍"
FontSize="14"
VerticalAlignment="Center"
HorizontalAlignment="Center" />
</Button>
</DockPanel>
</Grid>
<TextBlock Style="{StaticResource StandardText}" Margin="0,40,0,0"
Text="By clicking on a toggle, you can change the programs/websites that should be marked as distracting." />
<Border Background="#2C2C2C" CornerRadius="10" Padding="10" Margin="0,10,0,0"> </Grid>
<TextBlock Text="By clicking on a toggle, you can change the programs/websites that should be marked as distracting."/>
<Border Background="{StaticResource BACKGROUND_SECONDARY_BRUSH}" CornerRadius="10" Padding="10" Margin="0,10,0,0">
<Grid> <Grid>
<Grid.ColumnDefinitions> <Grid.ColumnDefinitions>
<ColumnDefinition Width="2*" /> <ColumnDefinition Width="2*" />
<ColumnDefinition Width="3*" /> <ColumnDefinition Width="5*" />
<ColumnDefinition Width="2*" /> <ColumnDefinition Width="1*" />
<ColumnDefinition Width="Auto" />
</Grid.ColumnDefinitions> </Grid.ColumnDefinitions>
<!-- Label --> <!-- Label -->
...@@ -107,41 +97,39 @@ ...@@ -107,41 +97,39 @@
<!-- Input Field with Placeholder --> <!-- Input Field with Placeholder -->
<Grid Grid.Column="1" VerticalAlignment="Center" Margin="0,0,10,0"> <Grid Grid.Column="1" VerticalAlignment="Center" Margin="0,0,10,0">
<TextBox x:Name="UrlInputBox" <TextBox x:Name="UrlInputBox"
VerticalAlignment="Center" VerticalAlignment="Center"
Padding="5" Padding="5"
FontSize="14" FontSize="14"
Background="Transparent" Background="Transparent"
Foreground="White" Foreground="White"
BorderBrush="Gray" BorderBrush="Gray"
BorderThickness="1" BorderThickness="0"
TextChanged="UrlInputBox_TextChanged" /> TextChanged="UrlInputBox_TextChanged" />
<TextBlock x:Name="UrlPlaceholder" <TextBlock x:Name="UrlPlaceholder"
Text="Url" Text="Url: www.example.de"
VerticalAlignment="Center" VerticalAlignment="Center"
Foreground="Gray" Foreground="Gray"
FontSize="14" FontSize="14"
Padding="5" Padding="5"
IsHitTestVisible="False" IsHitTestVisible="False"
Margin="5,0,0,0" /> Margin="5,0,0,0" />
<!-- Untere Linie als Border -->
<Border Height="1"
Background="{StaticResource TEXT_PRIMARY_BRUSH}"
VerticalAlignment="Bottom"
HorizontalAlignment="Stretch"
Margin="0,0,0,0" />
</Grid> </Grid>
<!-- Add Button --> <!-- Add Button -->
<Button Width="30" <Border Width="40" Height="40" CornerRadius="10" Background="{StaticResource TEXT_PRIMARY_BRUSH}" Cursor="Hand"
Height="30" Grid.Column="2"
VerticalAlignment="Center" VerticalAlignment="Center" HorizontalAlignment="Center" Margin="10,0,0,0"
HorizontalAlignment="Right" MouseDown="AddButton_Click">
Grid.Column="3" <TextBlock Text="+" FontSize="24" FontWeight="Bold" Foreground="Black"
Margin="0" VerticalAlignment="Center" HorizontalAlignment="Center"/>
BorderThickness="0" </Border>
ToolTip="Add"
Click="AddButton_Click">
<TextBlock Text="+"
FontSize="20"
Foreground="#333436"
VerticalAlignment="Center"
HorizontalAlignment="Center"
/>
</Button>
</Grid> </Grid>
</Border> </Border>
...@@ -153,7 +141,7 @@ Style="{StaticResource Header2}" ...@@ -153,7 +141,7 @@ Style="{StaticResource Header2}"
Text="CATEGORY" RenderTransformOrigin="0.548,1.689" Margin="10,0,0,0"/> Text="CATEGORY" RenderTransformOrigin="0.548,1.689" Margin="10,0,0,0"/>
</StackPanel> </StackPanel>
</StackPanel> </StackPanel>
<ScrollViewer VerticalScrollBarVisibility="Auto" Margin="20,215,20,8"> <ScrollViewer VerticalScrollBarVisibility="Auto" Margin="20,190,20,8" Height="310">
<StackPanel x:Name="ItemsPanel" /> <StackPanel x:Name="ItemsPanel" />
</ScrollViewer> </ScrollViewer>
......
...@@ -219,11 +219,12 @@ namespace InnoLabProjektDektopApp ...@@ -219,11 +219,12 @@ namespace InnoLabProjektDektopApp
MessageBox.Show($"Error saving data: {ex.Message}"); MessageBox.Show($"Error saving data: {ex.Message}");
} }
} }
/*
private void BackButton_Click(object sender, RoutedEventArgs e) private void BackButton_Click(object sender, RoutedEventArgs e)
{ {
this.NavigationService.Navigate(new Distractions()); this.NavigationService.Navigate(new Distractions());
} }
*/
public class WebsiteEntry public class WebsiteEntry
{ {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment