first test-flight version

This commit is contained in:
2022-03-03 15:10:36 +08:00
parent 9929eee056
commit 25191127f3
116 changed files with 1124 additions and 173 deletions

View File

@ -62,10 +62,26 @@ namespace Billing.Themes
{
Setters =
{
new Setter { Property = Editor.FontSizeProperty, Value = Device.GetNamedSize(NamedSize.Small, typeof(Entry)) },
new Setter { Property = Editor.FontSizeProperty, Value = Device.GetNamedSize(NamedSize.Small, typeof(Editor)) },
new Setter { Property = Editor.FontFamilyProperty, Value = robotoRegularFontFamily }
}
});
Add(new Style(typeof(OptionDatePicker))
{
Setters =
{
new Setter { Property = DatePicker.FontSizeProperty, Value = Device.GetNamedSize(NamedSize.Small, typeof(DatePicker)) },
new Setter { Property = DatePicker.FontFamilyProperty, Value = robotoRegularFontFamily }
}
});
Add(new Style(typeof(OptionTimePicker))
{
Setters =
{
new Setter { Property = TimePicker.FontSizeProperty, Value = Device.GetNamedSize(NamedSize.Small, typeof(TimePicker)) },
new Setter { Property = TimePicker.FontFamilyProperty, Value = robotoRegularFontFamily }
}
});
Add(new Style(typeof(Button))
{
Setters =

View File

@ -1,4 +1,6 @@
using Xamarin.Forms;
using Billing.UI;
using Xamarin.Essentials;
using Xamarin.Forms;
namespace Billing.Themes
{
@ -8,11 +10,25 @@ namespace Billing.Themes
public static Light Instance => _instance ??= new Light();
protected override Color PrimaryMauiColor => Color.FromRgb(0x18, 0x31, 0x53);
private Color primaryColor;
protected override Color PrimaryMauiColor => primaryColor;
protected override Color SecondaryMauiColor => Color.White;
public Light()
{
var color = Preferences.Get(Definition.PrimaryColorKey, "#183153");
primaryColor = Color.FromHex(color);
InitColors();
InitResources();
}
public void RefreshColor(Color primary)
{
primaryColor = primary;
Clear();
InitColors();
InitResources();
}
@ -35,7 +51,7 @@ namespace Billing.Themes
Setters =
{
new Setter { Property = Shell.TabBarBackgroundColorProperty, Value = Color.White },
new Setter { Property = Shell.TabBarTitleColorProperty, Value = PrimaryMauiColor },
new Setter { Property = Shell.TabBarTitleColorProperty, Value = primaryColor },
new Setter { Property = Shell.TabBarUnselectedColorProperty, Value = Color.FromRgb(0x82, 0x82, 0x82) }
}
});