Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file added Bookmarkly.App/Assets/SignInBackground.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions Bookmarkly.App/Bookmarkly.App.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
<Content Include="Assets\Square44x44Logo.targetsize-24_altform-unplated.png" />
<Content Include="Assets\StoreLogo.png" />
<Content Include="Assets\Wide310x150Logo.scale-200.png" />
<Content Include="Assets\SignInBackground.png" />
</ItemGroup>

<ItemGroup>
Expand Down
2 changes: 1 addition & 1 deletion Bookmarkly.App/MainWindow.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,6 @@
</Window.SystemBackdrop>

<Grid Loaded="OnWindowLoaded">
<ListView ItemsSource="{x:Bind _datas, Mode=OneWay}"/>
<Frame x:Name="RootFrame" />
</Grid>
</Window>
15 changes: 3 additions & 12 deletions Bookmarkly.App/MainWindow.xaml.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
using System.Collections.ObjectModel;
using Cyclotron.Extensions.DependencyInjection;
using Cyclotron.Telemetry.Logging;
using Microsoft.Extensions.DependencyInjection;
Expand All @@ -8,22 +7,12 @@
namespace Bookmarkly.App;

/// <summary>
/// An empty window that can be used on its own or navigated to within a Frame.
/// Main application window that hosts page navigation.
/// </summary>
public sealed partial class MainWindow : Window
{
private readonly ObservableCollection<int> _datas = [];
public MainWindow()
{
_datas.Add(1);
_datas.Add(1);
_datas.Add(1);
_datas.Add(1);
_datas.Add(1);
_datas.Add(1);
_datas.Add(1);
_datas.Add(1);
_datas.Add(1);
InitializeComponent();
}

Expand All @@ -47,5 +36,7 @@ private void OnWindowLoaded(object sender, RoutedEventArgs e)
var logger = provider.GetRequiredService<ICyclotronLogger>().ForModule("Instapaper");

logger.LogInformation("Starting operation"); // Caller info auto-captured!

RootFrame.Navigate(typeof(SignInPage));
}
}
65 changes: 65 additions & 0 deletions Bookmarkly.App/SignInPage.xaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
<?xml version="1.0" encoding="utf-8"?>
<Page
x:Class="Bookmarkly.App.SignInPage"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
mc:Ignorable="d"
Background="Transparent">

<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="65*" />
<ColumnDefinition Width="35*" />
</Grid.ColumnDefinitions>

<!-- Left panel: Abstract image -->
<Grid Grid.Column="0">
<Image
Source="Assets/SignInBackground.png"
Stretch="UniformToFill"
HorizontalAlignment="Center"
VerticalAlignment="Center" />
</Grid>

<!-- Right panel: Sign-in buttons -->
<Grid Grid.Column="1" Padding="40">
<StackPanel
VerticalAlignment="Center"
HorizontalAlignment="Stretch"
Spacing="16">

<TextBlock
x:Uid="SignIn_Title"
Style="{StaticResource TitleTextBlockStyle}"
TextWrapping="Wrap"
HorizontalAlignment="Center" />

<TextBlock
x:Uid="SignIn_Subtitle"
Style="{StaticResource BodyTextBlockStyle}"
Foreground="{ThemeResource TextFillColorSecondaryBrush}"
TextWrapping="Wrap"
HorizontalAlignment="Center"
Margin="0,0,0,24" />

<Button
x:Uid="SignIn_FreshRSS"
HorizontalAlignment="Stretch"
HorizontalContentAlignment="Center"
Style="{StaticResource AccentButtonStyle}"
Padding="12"
Click="OnFreshRssSignInClick" />

<Button
x:Uid="SignIn_Instapaper"
HorizontalAlignment="Stretch"
HorizontalContentAlignment="Center"
Padding="12"
Click="OnInstapaperSignInClick" />

</StackPanel>
</Grid>
</Grid>
</Page>
25 changes: 25 additions & 0 deletions Bookmarkly.App/SignInPage.xaml.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
using Microsoft.UI.Xaml;
using Microsoft.UI.Xaml.Controls;

namespace Bookmarkly.App;

/// <summary>
/// Sign-in page that allows users to authenticate with FreshRSS or Instapaper.
/// </summary>
public sealed partial class SignInPage : Page
{
public SignInPage()
{
InitializeComponent();
}

private void OnFreshRssSignInClick(object sender, RoutedEventArgs e)
{
// TODO: Implement FreshRSS sign-in flow
}

private void OnInstapaperSignInClick(object sender, RoutedEventArgs e)
{
// TODO: Implement Instapaper sign-in flow
}
}
58 changes: 58 additions & 0 deletions Bookmarkly.App/Strings/en-us/Resources.resw
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" msdata:Ordinal="0" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>1.3</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<data name="SignIn_Title.Text" xml:space="preserve">
<value>Welcome to Bookmarkly</value>
<comment>Title shown on the sign-in page</comment>
</data>
<data name="SignIn_Subtitle.Text" xml:space="preserve">
<value>Sign in to sync your bookmarks</value>
<comment>Subtitle shown on the sign-in page</comment>
</data>
<data name="SignIn_FreshRSS.Content" xml:space="preserve">
<value>Sign in with FreshRSS</value>
<comment>Button text for FreshRSS sign-in</comment>
</data>
<data name="SignIn_Instapaper.Content" xml:space="preserve">
<value>Sign in with Instapaper</value>
<comment>Button text for Instapaper sign-in</comment>
</data>
</root>
Binary file added docs/signin-page-mockup.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading