Skip to content

Commit

Permalink
Update sample application with a ViewsGalleryPage and child TabViewPa…
Browse files Browse the repository at this point in the history
  • Loading branch information
ChaplinMarchais committed Jan 30, 2022
1 parent 7ee6be5 commit cae39aa
Show file tree
Hide file tree
Showing 3 changed files with 47 additions and 0 deletions.
16 changes: 16 additions & 0 deletions samples/CommunityToolkit.Maui.Sample/Pages/Views/TabViewPage.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
using CommunityToolkit.Maui.Sample.Pages;
using CommunityToolkit.Maui.Views.TabView;

namespace CommunityToolkit.Maui.Sample.ViewModels.Views;

class TabViewPage : BasePage
{
public TabViewPage()
{
Title = nameof(TabView);
Content = new ScrollView()
{
Content = new TabView()
};
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
using CommunityToolkit.Maui.Sample.Pages;
using CommunityToolkit.Maui.Sample.ViewModels.Views;

namespace CommunityToolkit.Maui.Sample;

public partial class ViewsGalleryPage : BaseGalleryPage<ViewsGalleryViewModel>
{
public ViewsGalleryPage() : base("Views")
{
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

using CommunityToolkit.Maui.Sample.Models;
using CommunityToolkit.Maui.Views.TabView;

namespace CommunityToolkit.Maui.Sample.ViewModels.Views;

public class ViewsGalleryViewModel : BaseGalleryViewModel
{
protected override IEnumerable<SectionModel> CreateItems() => new[] {
new SectionModel(
typeof(TabViewPage),
nameof(TabView),
"Use the TabView control when you need to provide heirarchical navigation")
};
}

0 comments on commit cae39aa

Please sign in to comment.