Skip to content

Commit d5deb66

Browse files
committed
Redesign RegisterPage
1 parent 7392458 commit d5deb66

File tree

2 files changed

+31
-12
lines changed

2 files changed

+31
-12
lines changed

Signal-Windows/Views/RegisterPage.xaml

Lines changed: 30 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -24,19 +24,38 @@
2424
</Page.Resources>
2525

2626
<Grid Background="{ThemeResource ApplicationPageBackgroundThemeBrush}">
27+
<VisualStateManager.VisualStateGroups>
28+
<VisualStateGroup>
29+
<VisualState>
30+
<VisualState.StateTriggers>
31+
<AdaptiveTrigger MinWindowWidth="640"/>
32+
</VisualState.StateTriggers>
33+
<VisualState.Setters>
34+
<Setter Target="TitleTextBlock.FontSize" Value="46"/>
35+
</VisualState.Setters>
36+
</VisualState>
37+
</VisualStateGroup>
38+
</VisualStateManager.VisualStateGroups>
2739
<Grid.RowDefinitions>
28-
<RowDefinition Height="Auto" />
29-
<RowDefinition Height="Auto" />
30-
<RowDefinition Height="Auto" />
31-
<RowDefinition Height="Auto" />
32-
<RowDefinition Height="Auto" />
40+
<RowDefinition Height="*" />
41+
<RowDefinition Height="*" />
3342
</Grid.RowDefinitions>
34-
<TextBlock Grid.Row="0" Foreground="White" FontSize="35" HorizontalAlignment="Center" Margin="20 20 20 20">Connect with Signal</TextBlock>
35-
<ComboBox Grid.Row="1" Background="White" HorizontalAlignment="Center" Width="250" ItemsSource="{x:Bind Vm.CountriesList}" SelectionChanged="ComboBox_SelectionChanged" Name="CountriesList"/>
36-
<StackPanel Grid.Row="2" Orientation="Horizontal" HorizontalAlignment="Center">
37-
<TextBox Text="{x:Bind Vm.PhonePrefix, Mode=TwoWay}" Background="White" />
38-
<TextBox Text="{x:Bind Vm.PhoneSuffix, Mode=TwoWay}" Background="White" Width="186"/>
43+
<TextBlock x:Name="TitleTextBlock" Grid.Row="0" Foreground="White" FontSize="34" HorizontalAlignment="Center" Text="Connect with Signal" FontWeight="Light" VerticalAlignment="Center"/>
44+
<StackPanel Grid.Row="1">
45+
<ComboBox HorizontalAlignment="Center" Width="300" ItemsSource="{x:Bind Vm.CountriesList}" SelectionChanged="ComboBox_SelectionChanged" x:Name="CountriesList" VerticalAlignment="Stretch" d:LayoutOverrides="TopPosition, BottomPosition" PlaceholderText="Select your country"/>
46+
<Grid Width="300" Margin="0,18,0,0">
47+
<Grid.ColumnDefinitions>
48+
<ColumnDefinition Width="Auto"/>
49+
<ColumnDefinition Width="48"/>
50+
<ColumnDefinition Width="10"/>
51+
<ColumnDefinition Width="*"/>
52+
</Grid.ColumnDefinitions>
53+
<TextBlock Grid.Column="0" Text="+" Foreground="White" FontSize="20"/>
54+
<TextBox Grid.Column="1" Text="{x:Bind Vm.PhonePrefix, Mode=TwoWay}" MinWidth="32"/>
55+
<TextBox Grid.Column="3" Text="{x:Bind Vm.PhoneSuffix, Mode=TwoWay}" PlaceholderText="Phone number"/>
56+
</Grid>
57+
<TextBlock x:Name="VerifyTextBlock" Text="Verify your phone number to connect with Signal." FontSize="20" Foreground="White" HorizontalAlignment="Center" Margin="0,16,0,0" TextAlignment="Center" TextWrapping="Wrap"/>
58+
<Button x:Name="RegisterButton" Background="White" Foreground="#2190EA" HorizontalAlignment="Center" Width="300" Content="Register" Click="RegisterButton_Click" Margin="0,16,0,0"/>
3959
</StackPanel>
40-
<Button Grid.Row="3" Background="White" Foreground="#2190EA" HorizontalAlignment="Center" Width="200" Margin="20 20 20 20" Click="Button_Click">Register</Button>
4160
</Grid>
4261
</Page>

Signal-Windows/Views/RegisterPage.xaml.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ internal void SetCountry(int i)
5555
CountriesList.SelectedIndex = i;
5656
}
5757

58-
private void Button_Click(object sender, RoutedEventArgs e)
58+
private void RegisterButton_Click(object sender, RoutedEventArgs e)
5959
{
6060
Vm.RegisterButton_Click();
6161
}

0 commit comments

Comments
 (0)