Skip to content

Commit 14c902b

Browse files
authored
Updated the latest changes. (#72)
1. Added dark theme support 2. Added new credit card payment XAML page 3. Added ripple effects for touch interaction 4. Improved the styles applied in XAML pages 5. Embedded fonts support 6. Thumbnail view for viewing/selecting the XAML pages.
1 parent 1eded92 commit 14c902b

File tree

968 files changed

+27475
-27113
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

968 files changed

+27475
-27113
lines changed

EssentialUIKit.Android/EssentialUIKit.Android.csproj

+47-34
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,11 @@
4141
<AndroidManagedSymbols>true</AndroidManagedSymbols>
4242
<AndroidUseSharedRuntime>false</AndroidUseSharedRuntime>
4343
</PropertyGroup>
44+
45+
<PropertyGroup>
46+
<CodeAnalysisRuleSet>..\EssentialUIKit\StyleCop.ruleset</CodeAnalysisRuleSet>
47+
</PropertyGroup>
48+
4449
<ItemGroup>
4550
<Reference Include="Mono.Android" />
4651
<Reference Include="Mono.Android.Export" />
@@ -59,66 +64,74 @@
5964
<PackageReference Include="SkiaSharp.Views.Forms">
6065
<Version>1.68.0</Version>
6166
</PackageReference>
62-
<PackageReference Include="Syncfusion.Xamarin.Buttons" Version="17.4.0.44" />
63-
<PackageReference Include="Syncfusion.Xamarin.Cards" Version="17.4.0.44" />
64-
<PackageReference Include="Syncfusion.Xamarin.Core" Version="17.4.0.44" />
67+
<PackageReference Include="Syncfusion.Xamarin.Buttons" Version="18.4.0.31" />
68+
<PackageReference Include="Syncfusion.Xamarin.Cards" Version="18.4.0.31" />
69+
<PackageReference Include="Syncfusion.Xamarin.Core" Version="18.4.0.31" />
6570
<PackageReference Include="Syncfusion.Xamarin.DataSource">
66-
<Version>17.4.0.44</Version>
71+
<Version>18.4.0.31</Version>
6772
</PackageReference>
6873
<PackageReference Include="Syncfusion.Xamarin.GridCommon">
69-
<Version>17.4.0.44</Version>
74+
<Version>18.4.0.31</Version>
7075
</PackageReference>
7176
<PackageReference Include="Syncfusion.Xamarin.SfCalendar">
72-
<Version>17.4.0.44</Version>
77+
<Version>18.4.0.31</Version>
7378
</PackageReference>
7479
<PackageReference Include="Syncfusion.Xamarin.SfChart">
75-
<Version>17.4.0.44</Version>
80+
<Version>18.4.0.31</Version>
7681
</PackageReference>
77-
<PackageReference Include="Syncfusion.Xamarin.SfComboBox" Version="17.4.0.44" />
82+
<PackageReference Include="Syncfusion.Xamarin.SfComboBox" Version="18.4.0.31" />
7883
<PackageReference Include="Syncfusion.Xamarin.SfGauge">
79-
<Version>17.4.0.44</Version>
84+
<Version>18.4.0.31</Version>
8085
</PackageReference>
81-
<PackageReference Include="Syncfusion.Xamarin.SfMaps" Version="17.4.0.44" />
86+
<PackageReference Include="Syncfusion.Xamarin.SfMaps" Version="18.4.0.31" />
8287
<PackageReference Include="Syncfusion.Xamarin.SfParallaxView">
83-
<Version>17.4.0.44</Version>
88+
<Version>18.4.0.31</Version>
89+
</PackageReference>
90+
<PackageReference Include="Syncfusion.Xamarin.SfPicker">
91+
<Version>18.4.0.31</Version>
8492
</PackageReference>
8593
<PackageReference Include="Syncfusion.Xamarin.SfProgressBar">
86-
<Version>17.4.0.44</Version>
94+
<Version>18.4.0.31</Version>
8795
</PackageReference>
88-
<PackageReference Include="Syncfusion.Xamarin.SfRating" Version="17.4.0.44" />
89-
<PackageReference Include="Syncfusion.Xamarin.SfRotator" Version="17.4.0.44" />
90-
<PackageReference Include="Syncfusion.Xamarin.SfPopupLayout" Version="17.4.0.44" />
91-
<PackageReference Include="Syncfusion.Xamarin.Expander" Version="17.4.0.44" />
92-
<PackageReference Include="Syncfusion.Xamarin.SfListView" Version="17.4.0.44" />
93-
<PackageReference Include="Syncfusion.Xamarin.SfBadgeView" Version="17.4.0.44" />
96+
<PackageReference Include="Syncfusion.Xamarin.SfRating" Version="18.4.0.31" />
97+
<PackageReference Include="Syncfusion.Xamarin.SfRotator" Version="18.4.0.31" />
98+
<PackageReference Include="Syncfusion.Xamarin.SfPopupLayout" Version="18.4.0.31" />
99+
<PackageReference Include="Syncfusion.Xamarin.Expander" Version="18.4.0.31" />
100+
<PackageReference Include="Syncfusion.Xamarin.SfListView" Version="18.4.0.31" />
101+
<PackageReference Include="Syncfusion.Xamarin.SfBadgeView" Version="18.4.0.31" />
94102
<PackageReference Include="Syncfusion.Xamarin.SfTabView">
95-
<Version>17.4.0.44</Version>
103+
<Version>18.4.0.31</Version>
104+
</PackageReference>
105+
<PackageReference Include="Xamarin.Essentials">
106+
<Version>1.6.0</Version>
107+
</PackageReference>
108+
<PackageReference Include="Xamarin.Forms" Version="4.8.0.1821" />
109+
<PackageReference Include="Xamarin.AndroidX.Legacy.Support.V4">
110+
<Version>1.0.0.6</Version>
111+
</PackageReference>
112+
<PackageReference Include="Xamarin.Google.Android.Material">
113+
<Version>1.2.1.1</Version>
114+
</PackageReference>
115+
<PackageReference Include="Xamarin.AndroidX.Lifecycle.LiveData">
116+
<Version>2.2.0.4</Version>
117+
</PackageReference>
118+
<PackageReference Include="Xamarin.AndroidX.Browser">
119+
<Version>1.3.0.4</Version>
96120
</PackageReference>
97-
<PackageReference Include="Xamarin.Forms" Version="4.3.0.991250" />
98-
<PackageReference Include="Xamarin.Android.Support.Design" Version="28.0.0.1" />
99-
<PackageReference Include="Xamarin.Android.Support.v7.AppCompat" Version="28.0.0.1" />
100-
<PackageReference Include="Xamarin.Android.Support.v4" Version="28.0.0.1" />
101-
<PackageReference Include="Xamarin.Android.Support.v7.CardView" Version="28.0.0.1" />
102-
<PackageReference Include="Xamarin.Android.Support.v7.MediaRouter" Version="28.0.0.1" />
103-
<PackageReference Include="Xamarin.Android.Support.CustomTabs" Version="28.0.0.1" />
104121
</ItemGroup>
105122
<ItemGroup>
106123
<Compile Include="MainActivity.cs" />
107124
<Compile Include="Renderers\CalenderDatePickerRenderer.cs" />
108125
<Compile Include="Renderers\ParallaxListViewRenderer.cs" />
109126
<Compile Include="Renderers\BorderlessEditorRenderer.cs" />
110127
<Compile Include="Renderers\BorderlessEntryRenderer.cs" />
128+
<Compile Include="Renderers\TransitionNavigationPageRenderer.cs" />
111129
<Compile Include="Renderers\TemplateHostViewRenderer.cs" />
112130
<Compile Include="Resources\Resource.Designer.cs" />
113131
<Compile Include="Properties\AssemblyInfo.cs" />
114132
<Compile Include="SplashScreenActivity.cs" />
115133
</ItemGroup>
116134
<ItemGroup>
117-
<AndroidAsset Include="Assets\Montserrat-Bold.ttf" />
118-
<AndroidAsset Include="Assets\Montserrat-Medium.ttf" />
119-
<AndroidAsset Include="Assets\Montserrat-Regular.ttf" />
120-
<AndroidAsset Include="Assets\Montserrat-SemiBold.ttf" />
121-
<AndroidAsset Include="Assets\UIFontIcons.ttf" />
122135
<None Include="Resources\AboutResources.txt" />
123136
<None Include="Assets\AboutAssets.txt" />
124137
<None Include="Properties\AndroidManifest.xml">
@@ -232,9 +245,6 @@
232245
<ItemGroup>
233246
<AndroidResource Include="Resources\drawable-xxxhdpi\SplashScreen.png" />
234247
</ItemGroup>
235-
<ItemGroup>
236-
<AndroidResource Include="Resources\drawable\ChatMessageBackground.png" />
237-
</ItemGroup>
238248
<ItemGroup>
239249
<AndroidResource Include="Resources\drawable-land\ChatMessageBackground.png" />
240250
</ItemGroup>
@@ -274,6 +284,9 @@
274284
<ItemGroup>
275285
<AndroidResource Include="Resources\drawable\Visa.png" />
276286
</ItemGroup>
287+
<ItemGroup>
288+
<AndroidResource Include="Resources\drawable\ChatMessageBackground.png" />
289+
</ItemGroup>
277290
<Import Project="$(MSBuildExtensionsPath)\Xamarin\Android\Xamarin.Android.CSharp.targets" />
278291
<Import Project="..\build\tools\Syncfusion.CodeAnalysis.StyleCop\tools\StyleCop.MsBuild.targets" Condition="Exists('..\build\tools\Syncfusion.CodeAnalysis.StyleCop\tools\StyleCop.MsBuild.targets')" />
279292
<Target Name="BeforeBuild" Condition=" $(SetVersion) == true ">

EssentialUIKit.Android/MainActivity.cs

+3-3
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@ namespace EssentialUIKit.Droid
1212
public class MainActivity : global::Xamarin.Forms.Platform.Android.FormsAppCompatActivity
1313
{
1414
protected override void OnCreate(Bundle savedInstanceState)
15-
{
16-
Window.AddFlags(WindowManagerFlags.DrawsSystemBarBackgrounds);
15+
{
16+
this.Window.AddFlags(WindowManagerFlags.DrawsSystemBarBackgrounds);
1717

1818
base.OnCreate(savedInstanceState);
1919

@@ -24,7 +24,7 @@ protected override void OnCreate(Bundle savedInstanceState)
2424
Syncfusion.XForms.Android.PopupLayout.SfPopupLayoutRenderer.Init();
2525

2626
Syncfusion.XForms.Android.Core.Core.Init(this);
27-
27+
2828
this.LoadApplication(new App());
2929

3030
// Change the status bar color
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<?xml version="1.0" encoding="utf-8"?>
2-
<manifest xmlns:android="http://schemas.android.com/apk/res/android" android:versionCode="8" android:versionName="6.1" package="com.syncfusion.xamarin.uikit" android:installLocation="internalOnly">
2+
<manifest xmlns:android="http://schemas.android.com/apk/res/android" android:versionCode="8" android:versionName="18.4" package="com.syncfusion.xamarin.uikit" android:installLocation="internalOnly">
33
<uses-sdk android:minSdkVersion="21" android:targetSdkVersion="28" />
44
<application android:label="Essential UI Kit"></application>
55
</manifest>

EssentialUIKit.Android/Renderers/BorderlessEditorRenderer.cs

+3-1
Original file line numberDiff line numberDiff line change
@@ -14,13 +14,15 @@ public class BorderlessEditorRenderer : EditorRenderer
1414
{
1515
#region Constructor
1616

17-
public BorderlessEditorRenderer() : base(Application.Context)
17+
public BorderlessEditorRenderer()
18+
: base(Application.Context)
1819
{
1920
}
2021

2122
#endregion
2223

2324
#region Methods
25+
2426
/// <summary>
2527
/// Used to set the transparent color for editor control background property.
2628
/// </summary>

EssentialUIKit.Android/Renderers/BorderlessEntryRenderer.cs

+4-3
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,8 @@ namespace EssentialUIKit.Droid
99
{
1010
public class BorderlessEntryRenderer : EntryRenderer
1111
{
12-
public BorderlessEntryRenderer() : base(Application.Context)
12+
public BorderlessEntryRenderer()
13+
: base(Application.Context)
1314
{
1415
}
1516

@@ -20,8 +21,8 @@ protected override void OnElementChanged(ElementChangedEventArgs<Entry> e)
2021
if (this.Control != null)
2122
{
2223
this.Control.SetBackground(null);
23-
Control.Gravity = GravityFlags.CenterVertical;
24-
Control.SetPadding(0, 0, 0, 0);
24+
this.Control.Gravity = GravityFlags.CenterVertical;
25+
this.Control.SetPadding(0, 0, 0, 0);
2526
}
2627
}
2728
}

EssentialUIKit.Android/Renderers/CalenderDatePickerRenderer.cs

+6-5
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,8 @@ namespace EssentialUIKit.Droid
1111
/// </summary>
1212
public class CalenderDatePickerRenderer : DatePickerRenderer
1313
{
14-
public CalenderDatePickerRenderer(Context context) : base(context)
14+
public CalenderDatePickerRenderer(Context context)
15+
: base(context)
1516
{
1617
}
1718

@@ -25,10 +26,10 @@ protected override void OnElementChanged(ElementChangedEventArgs<DatePicker> e)
2526
if (this.Control != null)
2627
{
2728
this.Control.SetBackground(null);
28-
Control.Text = (e.NewElement as Controls.CalenderDatePicker).PlaceHolderText;
29-
Control.SetTextColor(new Android.Graphics.Color(96, 106, 123));
30-
Control.Gravity = Android.Views.GravityFlags.CenterVertical;
31-
Control.SetPadding(0, 0, 0, 0);
29+
this.Control.Text = (e?.NewElement as Controls.CalenderDatePicker).PlaceHolderText;
30+
this.Control.SetTextColor(new Android.Graphics.Color(96, 106, 123));
31+
this.Control.Gravity = Android.Views.GravityFlags.CenterVertical;
32+
this.Control.SetPadding(0, 0, 0, 0);
3233
}
3334
}
3435
}

EssentialUIKit.Android/Renderers/ParallaxListViewRenderer.cs

+6-5
Original file line numberDiff line numberDiff line change
@@ -12,27 +12,28 @@ public class ParallaxListViewRenderer : ListViewRenderer
1212
{
1313
private int previousScrollPosition;
1414

15-
public ParallaxListViewRenderer(Context context) : base(context)
15+
public ParallaxListViewRenderer(Context context)
16+
: base(context)
1617
{
1718
}
1819

1920
protected override void OnElementChanged(ElementChangedEventArgs<ListView> e)
2021
{
2122
base.OnElementChanged(e);
22-
if (e.NewElement != null)
23+
if (e?.NewElement != null)
2324
{
24-
(e.NewElement as ParallaxListView).WidthInPixel = Context.Resources.DisplayMetrics.WidthPixels;
25+
(e.NewElement as ParallaxListView).WidthInPixel = this.Context.Resources.DisplayMetrics.WidthPixels;
2526
if (this.Control != null)
2627
{
2728
this.Control.Scroll += (sender, arg) =>
2829
{
2930
var topView = arg.View.GetChildAt(0);
3031
if (this.Control.FirstVisiblePosition == 0)
3132
{
32-
previousScrollPosition = topView.Top;
33+
this.previousScrollPosition = topView.Top;
3334
}
3435

35-
ParallaxListView.OnScrollChanged(Element, new ScrollChangedEventArgs(previousScrollPosition));
36+
ParallaxListView.OnScrollChanged(this.Element, new ScrollChangedEventArgs(this.previousScrollPosition));
3637
};
3738
}
3839
}

EssentialUIKit.Android/Renderers/TemplateHostViewRenderer.cs

+7-2
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,8 @@ namespace EssentialUIKit.Droid.Renderers
1111
{
1212
public class TemplateHostViewRenderer : ViewRenderer
1313
{
14-
public TemplateHostViewRenderer(Context context) : base(context)
14+
public TemplateHostViewRenderer(Context context)
15+
: base(context)
1516
{
1617
}
1718

@@ -55,17 +56,21 @@ protected override void OnElementChanged(ElementChangedEventArgs<Xamarin.Forms.V
5556
{
5657
base.OnElementChanged(e);
5758

58-
var pageView = e.NewElement as TemplateHostView;
59+
var pageView = e?.NewElement as TemplateHostView;
5960

61+
#pragma warning disable CA2000 // Dispose objects before losing scope
6062
var nativePage = this.GetNativeView(pageView?.Template, pageView);
63+
#pragma warning restore CA2000 // Dispose objects before losing scope
6164

6265
if (nativePage != null)
6366
{
6467
this.SetNativeControl(nativePage.View);
6568
}
6669
else
6770
{
71+
#pragma warning disable CA2000 // Dispose objects before losing scope
6872
this.SetNativeControl(new TextView(this.Context) { Text = "There is no loaded page" });
73+
#pragma warning restore CA2000 // Dispose objects before losing scope
6974
}
7075
}
7176

Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
using Android.Content;
2+
using Android.Support.V4.App;
3+
using EssentialUIKit.Droid.Renderers;
4+
using Xamarin.Forms;
5+
using Xamarin.Forms.Platform.Android.AppCompat;
6+
7+
[assembly: ExportRenderer(typeof(NavigationPage), typeof(TransitionNavigationPageRenderer))]
8+
9+
namespace EssentialUIKit.Droid.Renderers
10+
{
11+
public class TransitionNavigationPageRenderer : NavigationPageRenderer
12+
{
13+
public TransitionNavigationPageRenderer(Context context)
14+
: base(context)
15+
{
16+
}
17+
18+
protected override void SetupPageTransition(FragmentTransaction transaction, bool isPush)
19+
{
20+
if (transaction != null)
21+
{
22+
if (isPush)
23+
{
24+
transaction.SetCustomAnimations(Resource.Animation.abc_slide_in_bottom, 0, 0, 0);
25+
}
26+
else
27+
{
28+
transaction.SetCustomAnimations(0, Resource.Animation.abc_slide_out_bottom, 0, 0);
29+
}
30+
31+
base.SetupPageTransition(transaction, isPush);
32+
}
33+
}
34+
}
35+
}
Loading

EssentialUIKit.Android/SplashScreenActivity.cs

+4-6
Original file line numberDiff line numberDiff line change
@@ -4,16 +4,14 @@
44

55
namespace EssentialUIKit.Droid
66
{
7-
[Activity(Theme = "@style/Theme.Splash",
8-
MainLauncher = true,
9-
NoHistory = true, Icon = "@drawable/Icon")]
7+
[Activity(Theme = "@style/Theme.Splash", MainLauncher = true, NoHistory = true, Icon = "@drawable/Icon")]
108
public class SplashScreenActivity : Activity
119
{
1210
protected override void OnCreate(Bundle bundle)
1311
{
14-
Window.DecorView.SystemUiVisibility = (StatusBarVisibility)((int)Window.DecorView.SystemUiVisibility ^ (int)SystemUiFlags.LayoutStable ^ (int)SystemUiFlags.LayoutFullscreen);
15-
Window.AddFlags(WindowManagerFlags.DrawsSystemBarBackgrounds);
16-
Window.SetFlags(WindowManagerFlags.Fullscreen, WindowManagerFlags.Fullscreen);
12+
this.Window.DecorView.SystemUiVisibility = (StatusBarVisibility)((int)this.Window.DecorView.SystemUiVisibility ^ (int)SystemUiFlags.LayoutStable ^ (int)SystemUiFlags.LayoutFullscreen);
13+
this.Window.AddFlags(WindowManagerFlags.DrawsSystemBarBackgrounds);
14+
this.Window.SetFlags(WindowManagerFlags.Fullscreen, WindowManagerFlags.Fullscreen);
1715
base.OnCreate(bundle);
1816
this.StartActivity(typeof(MainActivity));
1917
}

EssentialUIKit.UWP/App.xaml.cs

+4-3
Original file line numberDiff line numberDiff line change
@@ -71,15 +71,16 @@ protected override void OnLaunched(LaunchActivatedEventArgs e)
7171
typeof(Syncfusion.XForms.UWP.PopupLayout.SfPopupLayoutRenderer).GetTypeInfo().Assembly,
7272
typeof(Syncfusion.XForms.UWP.Expander.SfExpanderRenderer).GetTypeInfo().Assembly,
7373
typeof(Syncfusion.XForms.UWP.Cards.SfCardViewRenderer).GetTypeInfo().Assembly,
74+
typeof(Syncfusion.XForms.Pickers.UWP.SfDatePickerRenderer).GetTypeInfo().Assembly,
7475
typeof(Syncfusion.XForms.UWP.BadgeView.SfBadgeViewRenderer).GetTypeInfo().Assembly,
7576
typeof(Syncfusion.XForms.UWP.Buttons.SfSegmentedControlRenderer).GetTypeInfo().Assembly,
7677
typeof(Syncfusion.SfMaps.XForms.UWP.SfMapsRenderer).GetTypeInfo().Assembly,
77-
typeof(Syncfusion.XForms.UWP.ProgressBar.SfLinearProgressRenderer).GetTypeInfo().Assembly
78+
typeof(Syncfusion.XForms.UWP.ProgressBar.SfLinearProgressRenderer).GetTypeInfo().Assembly,
7879
};
7980
Xamarin.Forms.Forms.SetFlags("CollectionView_Experimental");
8081
Xamarin.Forms.Forms.Init(e, assembliesToInclude);
8182

82-
if (e.PreviousExecutionState == ApplicationExecutionState.Terminated)
83+
if (e?.PreviousExecutionState == ApplicationExecutionState.Terminated)
8384
{
8485
// TODO: Load state from previously suspended application
8586
}
@@ -93,7 +94,7 @@ protected override void OnLaunched(LaunchActivatedEventArgs e)
9394
// When the navigation stack isn't restored navigate to the first page,
9495
// configuring the new page by passing required information as a navigation
9596
// parameter
96-
rootFrame.Navigate(typeof(MainPage), e.Arguments);
97+
rootFrame.Navigate(typeof(MainPage), e?.Arguments);
9798
}
9899

99100
//// Ensure the current window is active
-238 KB
Binary file not shown.
-237 KB
Binary file not shown.
-240 KB
Binary file not shown.
Binary file not shown.
-33.7 KB
Binary file not shown.

0 commit comments

Comments
 (0)