Skip to content

Commit

Permalink
splash of colour
Browse files Browse the repository at this point in the history
  • Loading branch information
kfrancis committed May 17, 2023
1 parent 5fd6699 commit e13f2bd
Show file tree
Hide file tree
Showing 9 changed files with 37 additions and 20 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,4 +56,4 @@ Based on NNostr, but I couldn't quite understand how it was meant to be used so
### Images
- [BlurHash](https://blurha.sh/) is how we'll store compact representations of profile images so they load immediately and we can then load them dynamically as they are seen.

![Current progress](/pic.png "Current progress")
![Current progress](/nusocial.gif "Current progress")
Binary file added nusocial.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 2 additions & 1 deletion src/NuSocial/Localization/NuSocial/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
"AccountId": "Account ID",
"AccountKeyPlaceholder": "nsec1...",
"NuSocial": "NuSocial",
"TapToRegenerate": "Tap to regenerate"
"TapToRegenerate": "Tap to regenerate",
"WelcomeText": "#nostr NuSocial: Your Universe, Nu Connections"
}
}
3 changes: 2 additions & 1 deletion src/NuSocial/MauiProgram.cs
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,8 @@ public static MauiApp CreateMauiApp()
fonts.AddFont("FontAwesome6FreeSolid.otf", "FontAwesomeSolid");
fonts.AddFont("OpenSans-Regular.ttf", "OpenSansRegular");
fonts.AddFont("OpenSans-Semibold.ttf", "OpenSansSemibold");
})
fonts.AddFont("Urbanist-Medium.ttf", "Urbanist");
})
.ConfigureMopups()
.ConfigureContainer<ContainerBuilder>(new AbpAutofacServiceProviderFactory(GetAutofacContainerBuilder(builder.Services)));

Expand Down
1 change: 1 addition & 0 deletions src/NuSocial/NuSocial.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,7 @@
<ItemGroup>
<None Remove="Localization\NuSocial\en.json" />
<None Remove="Localization\NuSocial\fr.json" />
<None Remove="Resources\Fonts\Urbanist-Medium.ttf" />
<None Remove="Resources\Raw\144135-planet.json" />
</ItemGroup>

Expand Down
Binary file added src/NuSocial/Resources/Fonts/Urbanist-Medium.ttf
Binary file not shown.
5 changes: 5 additions & 0 deletions src/NuSocial/Resources/Styles/Colors.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -41,4 +41,9 @@
<Color x:Key="Blue200Accent">#FF72ACF1</Color>
<Color x:Key="Blue300Accent">#FFA7CBF6</Color>

<LinearGradientBrush x:Key="PrimaryGradient" StartPoint="0,0" EndPoint="0,1">
<GradientStop Offset="0.0" Color="#373063" />
<GradientStop Offset="1.0" Color="#C8CF9C" />
</LinearGradientBrush>

</ResourceDictionary>
22 changes: 12 additions & 10 deletions src/NuSocial/Resources/Styles/Styles.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@
<?xaml-comp compile="true" ?>
<ResourceDictionary xmlns="http://schemas.microsoft.com/dotnet/2021/maui" xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml">

<x:String x:Key="AppFontFamily">Urbanist</x:String>

<Style TargetType="ActivityIndicator">
<Setter Property="Color" Value="{AppThemeBinding Light={StaticResource Primary}, Dark={StaticResource White}}" />
</Style>
Expand All @@ -24,7 +26,7 @@
<Style TargetType="Button">
<Setter Property="TextColor" Value="{AppThemeBinding Light={StaticResource White}, Dark={StaticResource Primary}}" />
<Setter Property="BackgroundColor" Value="{AppThemeBinding Light={StaticResource Primary}, Dark={StaticResource White}}" />
<Setter Property="FontFamily" Value="OpenSansRegular" />
<Setter Property="FontFamily" Value="{StaticResource AppFontFamily}" />
<Setter Property="FontSize" Value="14" />
<Setter Property="CornerRadius" Value="8" />
<Setter Property="Padding" Value="14,10" />
Expand Down Expand Up @@ -62,7 +64,7 @@
<Style TargetType="DatePicker">
<Setter Property="TextColor" Value="{AppThemeBinding Light={StaticResource Gray900}, Dark={StaticResource White}}" />
<Setter Property="BackgroundColor" Value="Transparent" />
<Setter Property="FontFamily" Value="OpenSansRegular" />
<Setter Property="FontFamily" Value="{StaticResource AppFontFamily}" />
<Setter Property="FontSize" Value="14" />
<Setter Property="VisualStateManager.VisualStateGroups">
<VisualStateGroupList>
Expand All @@ -81,7 +83,7 @@
<Style TargetType="Editor">
<Setter Property="TextColor" Value="{AppThemeBinding Light={StaticResource Black}, Dark={StaticResource White}}" />
<Setter Property="BackgroundColor" Value="Transparent" />
<Setter Property="FontFamily" Value="OpenSansRegular" />
<Setter Property="FontFamily" Value="{StaticResource AppFontFamily}" />
<Setter Property="FontSize" Value="14" />
<Setter Property="PlaceholderColor" Value="{AppThemeBinding Light={StaticResource Gray200}, Dark={StaticResource Gray500}}" />
<Setter Property="VisualStateManager.VisualStateGroups">
Expand All @@ -101,7 +103,7 @@
<Style TargetType="Entry">
<Setter Property="TextColor" Value="{AppThemeBinding Light={StaticResource Black}, Dark={StaticResource White}}" />
<Setter Property="BackgroundColor" Value="Transparent" />
<Setter Property="FontFamily" Value="OpenSansRegular" />
<Setter Property="FontFamily" Value="{StaticResource AppFontFamily}" />
<Setter Property="FontSize" Value="14" />
<Setter Property="PlaceholderColor" Value="{AppThemeBinding Light={StaticResource Gray200}, Dark={StaticResource Gray500}}" />
<Setter Property="VisualStateManager.VisualStateGroups">
Expand Down Expand Up @@ -145,7 +147,7 @@

<Style TargetType="Label">
<Setter Property="TextColor" Value="{AppThemeBinding Light={StaticResource Gray900}, Dark={StaticResource White}}" />
<Setter Property="FontFamily" Value="OpenSansRegular" />
<Setter Property="FontFamily" Value="{StaticResource AppFontFamily}" />
<Setter Property="FontSize" Value="14" />
<Setter Property="VisualStateManager.VisualStateGroups">
<VisualStateGroupList>
Expand All @@ -170,7 +172,7 @@
<Setter Property="TextColor" Value="{AppThemeBinding Light={StaticResource Gray900}, Dark={StaticResource White}}" />
<Setter Property="TitleColor" Value="{AppThemeBinding Light={StaticResource Gray900}, Dark={StaticResource Gray200}}" />
<Setter Property="BackgroundColor" Value="Transparent" />
<Setter Property="FontFamily" Value="OpenSansRegular" />
<Setter Property="FontFamily" Value="{StaticResource AppFontFamily}" />
<Setter Property="FontSize" Value="14" />
<Setter Property="VisualStateManager.VisualStateGroups">
<VisualStateGroupList>
Expand Down Expand Up @@ -206,7 +208,7 @@
<Style TargetType="RadioButton">
<Setter Property="Background" Value="Transparent" />
<Setter Property="TextColor" Value="{AppThemeBinding Light={StaticResource Black}, Dark={StaticResource White}}" />
<Setter Property="FontFamily" Value="OpenSansRegular" />
<Setter Property="FontFamily" Value="{StaticResource AppFontFamily}" />
<Setter Property="FontSize" Value="14" />
<Setter Property="VisualStateManager.VisualStateGroups">
<VisualStateGroupList>
Expand All @@ -231,7 +233,7 @@
<Setter Property="PlaceholderColor" Value="{StaticResource Gray500}" />
<Setter Property="CancelButtonColor" Value="{StaticResource Gray500}" />
<Setter Property="BackgroundColor" Value="Transparent" />
<Setter Property="FontFamily" Value="OpenSansRegular" />
<Setter Property="FontFamily" Value="{StaticResource AppFontFamily}" />
<Setter Property="FontSize" Value="14" />
<Setter Property="VisualStateManager.VisualStateGroups">
<VisualStateGroupList>
Expand All @@ -252,7 +254,7 @@
<Setter Property="TextColor" Value="{AppThemeBinding Light={StaticResource Gray900}, Dark={StaticResource White}}" />
<Setter Property="PlaceholderColor" Value="{StaticResource Gray500}" />
<Setter Property="BackgroundColor" Value="Transparent" />
<Setter Property="FontFamily" Value="OpenSansRegular" />
<Setter Property="FontFamily" Value="{StaticResource AppFontFamily}" />
<Setter Property="FontSize" Value="14" />
<Setter Property="VisualStateManager.VisualStateGroups">
<VisualStateGroupList>
Expand Down Expand Up @@ -332,7 +334,7 @@
<Style TargetType="TimePicker">
<Setter Property="TextColor" Value="{AppThemeBinding Light={StaticResource Gray900}, Dark={StaticResource White}}" />
<Setter Property="Background" Value="Transparent" />
<Setter Property="FontFamily" Value="OpenSansRegular" />
<Setter Property="FontFamily" Value="{StaticResource AppFontFamily}" />
<Setter Property="FontSize" Value="14" />
<Setter Property="VisualStateManager.VisualStateGroups">
<VisualStateGroupList>
Expand Down
21 changes: 14 additions & 7 deletions src/NuSocial/Views/StartView.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,27 +11,34 @@
Padding="20"
x:DataType="viewModels:StartViewModel"
x:TypeArguments="viewModels:StartViewModel"
BackgroundColor="{StaticResource Background}"
Shell.FlyoutBehavior="Disabled">
<Grid RowDefinitions="Auto,Auto, Auto,*" RowSpacing="10">
Background="{StaticResource PrimaryGradient}"
Shell.FlyoutBehavior="Disabled"
Shell.NavBarIsVisible="False">
<Grid RowDefinitions="*, Auto,Auto, Auto,*" RowSpacing="10">
<Label
FontSize="55"
Text="NuSocial"
TextColor="{StaticResource White}" />
<skia:SKLottieView
Grid.Row="1"
HeightRequest="200"
HorizontalOptions="Center"
RepeatCount="-1"
Source="144135-planet.json"
WidthRequest="200" />
<Label
Grid.Row="1"
Grid.Row="2"
HorizontalTextAlignment="Center"
Text="{loc:Translate Welcome}" />
Text="{loc:Translate WelcomeText}"
TextColor="{StaticResource White}" />
<Button
Grid.Row="2"
Grid.Row="3"
Command="{Binding CreateAccountCommand}"
MaximumWidthRequest="200"
Text="{loc:Translate CreateAccount}"
VerticalOptions="End" />
<Button
Grid.Row="3"
Grid.Row="4"
Command="{Binding GoToLoginCommand}"
MaximumWidthRequest="200"
Text="{loc:Translate Login}"
Expand Down

0 comments on commit e13f2bd

Please sign in to comment.