-
Notifications
You must be signed in to change notification settings - Fork 49
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #2338 from unoplatform/dev/nr/improvedrouting
fix: Closure of flyout when no route set on the flyoutnavigator
- Loading branch information
Showing
81 changed files
with
1,437 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
13 changes: 13 additions & 0 deletions
13
testing/TestHarness/TestHarness.Shared/Ext/Navigation/Apps/Chefs/ChefsCompletedDialog.xaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
<ContentDialog x:Class="TestHarness.Ext.Navigation.Apps.Chefs.ChefsCompletedDialog" | ||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" | ||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" | ||
xmlns:local="using:TestHarness.Ext.Navigation.Apps.Chefs" | ||
xmlns:d="http://schemas.microsoft.com/expression/blend/2008" | ||
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" | ||
mc:Ignorable="d" | ||
Background="{ThemeResource ApplicationPageBackgroundThemeBrush}"> | ||
|
||
<Grid> | ||
<TextBlock Text="Completed" /> | ||
</Grid> | ||
</ContentDialog> |
10 changes: 10 additions & 0 deletions
10
...ing/TestHarness/TestHarness.Shared/Ext/Navigation/Apps/Chefs/ChefsCompletedDialog.xaml.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
| ||
namespace TestHarness.Ext.Navigation.Apps.Chefs; | ||
|
||
public sealed partial class ChefsCompletedDialog : ContentDialog | ||
{ | ||
public ChefsCompletedDialog() | ||
{ | ||
this.InitializeComponent(); | ||
} | ||
} |
5 changes: 5 additions & 0 deletions
5
testing/TestHarness/TestHarness.Shared/Ext/Navigation/Apps/Chefs/ChefsCookbookDetailModel.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
namespace TestHarness.Ext.Navigation.Apps.Chefs; | ||
|
||
public partial class ChefsCookbookDetailModel | ||
{ | ||
} |
13 changes: 13 additions & 0 deletions
13
...ing/TestHarness/TestHarness.Shared/Ext/Navigation/Apps/Chefs/ChefsCookbookDetailPage.xaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
<Page x:Class="TestHarness.Ext.Navigation.Apps.Chefs.ChefsCookbookDetailPage" | ||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" | ||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" | ||
xmlns:local="using:TestHarness.Ext.Navigation.Apps.Chefs" | ||
xmlns:d="http://schemas.microsoft.com/expression/blend/2008" | ||
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" | ||
mc:Ignorable="d" | ||
Background="{ThemeResource ApplicationPageBackgroundThemeBrush}"> | ||
|
||
<Grid> | ||
<TextBlock Text="ChefsCookbookDetail" /> | ||
</Grid> | ||
</Page> |
10 changes: 10 additions & 0 deletions
10
.../TestHarness/TestHarness.Shared/Ext/Navigation/Apps/Chefs/ChefsCookbookDetailPage.xaml.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
| ||
namespace TestHarness.Ext.Navigation.Apps.Chefs; | ||
|
||
public sealed partial class ChefsCookbookDetailPage : Page | ||
{ | ||
public ChefsCookbookDetailPage() | ||
{ | ||
this.InitializeComponent(); | ||
} | ||
} |
5 changes: 5 additions & 0 deletions
5
...estHarness/TestHarness.Shared/Ext/Navigation/Apps/Chefs/ChefsCreateUpdateCookbookModel.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
namespace TestHarness.Ext.Navigation.Apps.Chefs; | ||
|
||
public partial class ChefsCreateUpdateCookbookModel | ||
{ | ||
} |
13 changes: 13 additions & 0 deletions
13
...stHarness/TestHarness.Shared/Ext/Navigation/Apps/Chefs/ChefsCreateUpdateCookbookPage.xaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
<Page x:Class="TestHarness.Ext.Navigation.Apps.Chefs.ChefsCreateUpdateCookbookPage" | ||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" | ||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" | ||
xmlns:local="using:TestHarness.Ext.Navigation.Apps.Chefs" | ||
xmlns:d="http://schemas.microsoft.com/expression/blend/2008" | ||
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" | ||
mc:Ignorable="d" | ||
Background="{ThemeResource ApplicationPageBackgroundThemeBrush}"> | ||
|
||
<Grid> | ||
<TextBlock Text="ChefsCreateUpdateCookbook" /> | ||
</Grid> | ||
</Page> |
10 changes: 10 additions & 0 deletions
10
...arness/TestHarness.Shared/Ext/Navigation/Apps/Chefs/ChefsCreateUpdateCookbookPage.xaml.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
| ||
namespace TestHarness.Ext.Navigation.Apps.Chefs; | ||
|
||
public sealed partial class ChefsCreateUpdateCookbookPage : Page | ||
{ | ||
public ChefsCreateUpdateCookbookPage() | ||
{ | ||
this.InitializeComponent(); | ||
} | ||
} |
5 changes: 5 additions & 0 deletions
5
...ing/TestHarness/TestHarness.Shared/Ext/Navigation/Apps/Chefs/ChefsFavoriteRecipesModel.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
namespace TestHarness.Ext.Navigation.Apps.Chefs; | ||
|
||
public partial class ChefsFavoriteRecipesModel | ||
{ | ||
} |
13 changes: 13 additions & 0 deletions
13
...ng/TestHarness/TestHarness.Shared/Ext/Navigation/Apps/Chefs/ChefsFavoriteRecipesPage.xaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
<Page x:Class="TestHarness.Ext.Navigation.Apps.Chefs.ChefsFavoriteRecipesPage" | ||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" | ||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" | ||
xmlns:local="using:TestHarness.Ext.Navigation.Apps.Chefs" | ||
xmlns:d="http://schemas.microsoft.com/expression/blend/2008" | ||
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" | ||
mc:Ignorable="d" | ||
Background="{ThemeResource ApplicationPageBackgroundThemeBrush}"> | ||
|
||
<Grid> | ||
<TextBlock Text="ChefsFavoriteRecipes" /> | ||
</Grid> | ||
</Page> |
10 changes: 10 additions & 0 deletions
10
...TestHarness/TestHarness.Shared/Ext/Navigation/Apps/Chefs/ChefsFavoriteRecipesPage.xaml.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
| ||
namespace TestHarness.Ext.Navigation.Apps.Chefs; | ||
|
||
public sealed partial class ChefsFavoriteRecipesPage : Page | ||
{ | ||
public ChefsFavoriteRecipesPage() | ||
{ | ||
this.InitializeComponent(); | ||
} | ||
} |
5 changes: 5 additions & 0 deletions
5
testing/TestHarness/TestHarness.Shared/Ext/Navigation/Apps/Chefs/ChefsFilterModel.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
namespace TestHarness.Ext.Navigation.Apps.Chefs; | ||
|
||
public partial class ChefsFilterModel | ||
{ | ||
} |
13 changes: 13 additions & 0 deletions
13
testing/TestHarness/TestHarness.Shared/Ext/Navigation/Apps/Chefs/ChefsFilterPage.xaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
<Page x:Class="TestHarness.Ext.Navigation.Apps.Chefs.ChefsFilterPage" | ||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" | ||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" | ||
xmlns:local="using:TestHarness.Ext.Navigation.Apps.Chefs" | ||
xmlns:d="http://schemas.microsoft.com/expression/blend/2008" | ||
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" | ||
mc:Ignorable="d" | ||
Background="{ThemeResource ApplicationPageBackgroundThemeBrush}"> | ||
|
||
<Grid> | ||
<TextBlock Text="ChefsFilter" /> | ||
</Grid> | ||
</Page> |
10 changes: 10 additions & 0 deletions
10
testing/TestHarness/TestHarness.Shared/Ext/Navigation/Apps/Chefs/ChefsFilterPage.xaml.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
| ||
namespace TestHarness.Ext.Navigation.Apps.Chefs; | ||
|
||
public sealed partial class ChefsFilterPage : Page | ||
{ | ||
public ChefsFilterPage() | ||
{ | ||
this.InitializeComponent(); | ||
} | ||
} |
13 changes: 13 additions & 0 deletions
13
testing/TestHarness/TestHarness.Shared/Ext/Navigation/Apps/Chefs/ChefsGenericDialog.xaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
<ContentDialog x:Class="TestHarness.Ext.Navigation.Apps.Chefs.ChefsGenericDialog" | ||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" | ||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" | ||
xmlns:local="using:TestHarness.Ext.Navigation.Apps.Chefs" | ||
xmlns:d="http://schemas.microsoft.com/expression/blend/2008" | ||
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" | ||
mc:Ignorable="d" | ||
Background="{ThemeResource ApplicationPageBackgroundThemeBrush}"> | ||
|
||
<Grid> | ||
<TextBlock Text="Generic" /> | ||
</Grid> | ||
</ContentDialog> |
10 changes: 10 additions & 0 deletions
10
testing/TestHarness/TestHarness.Shared/Ext/Navigation/Apps/Chefs/ChefsGenericDialog.xaml.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
| ||
namespace TestHarness.Ext.Navigation.Apps.Chefs; | ||
|
||
public sealed partial class ChefsGenericDialog : ContentDialog | ||
{ | ||
public ChefsGenericDialog() | ||
{ | ||
this.InitializeComponent(); | ||
} | ||
} |
5 changes: 5 additions & 0 deletions
5
testing/TestHarness/TestHarness.Shared/Ext/Navigation/Apps/Chefs/ChefsGenericDialogModel.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
namespace TestHarness.Ext.Navigation.Apps.Chefs; | ||
|
||
public partial class ChefsGenericDialogModel | ||
{ | ||
} |
35 changes: 35 additions & 0 deletions
35
testing/TestHarness/TestHarness.Shared/Ext/Navigation/Apps/Chefs/ChefsHomeModel.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
using TestHarness.Ext.Navigation.Apps.Chefs.Models; | ||
|
||
namespace TestHarness.Ext.Navigation.Apps.Chefs; | ||
|
||
public partial class ChefsHomeModel(INavigator navigator) | ||
{ | ||
|
||
public async ValueTask ShowCurrentProfile() | ||
{ | ||
await navigator.NavigateToProfile(this, new ChefsUser { FullName = "Tester User" }); | ||
} | ||
|
||
public async ValueTask ShowCurrentProfileNew() | ||
{ | ||
await navigator.NavigateRouteAsync(this, "ChefsProfile", qualifier: Qualifiers.Dialog, data: new ChefsUser { FullName = "Tester User (new)" }); | ||
} | ||
|
||
|
||
} | ||
|
||
public static class ChefsNavigationExtensions | ||
{ | ||
public static async ValueTask NavigateToProfile(this INavigator navigator, object sender, ChefsUser? profile = null) | ||
{ | ||
var response = await navigator.NavigateRouteForResultAsync<ChefsRecipe?>(sender, "ChefsProfile", qualifier: Qualifiers.Dialog, data: profile); | ||
var result = await response!.Result; | ||
|
||
//If a Recipe was selected, navigate to the RecipeDetails. Otherwise, do nothing | ||
await (result.SomeOrDefault() switch | ||
{ | ||
ChefsRecipe recipe => navigator.NavigateDataAsync(sender, recipe), | ||
_ => Task.CompletedTask, | ||
}); | ||
} | ||
} |
17 changes: 17 additions & 0 deletions
17
testing/TestHarness/TestHarness.Shared/Ext/Navigation/Apps/Chefs/ChefsHomePage.xaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
<Page x:Class="TestHarness.Ext.Navigation.Apps.Chefs.ChefsHomePage" | ||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" | ||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" | ||
xmlns:local="using:TestHarness.Ext.Navigation.Apps.Chefs" | ||
xmlns:d="http://schemas.microsoft.com/expression/blend/2008" | ||
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" | ||
mc:Ignorable="d" | ||
Background="{ThemeResource ApplicationPageBackgroundThemeBrush}"> | ||
|
||
<StackPanel> | ||
<TextBlock Text="ChefsHome" /> | ||
<Button Content="Profile" | ||
Command="{Binding ShowCurrentProfile}" /> | ||
<Button Content="Profile (New)" | ||
Command="{Binding ShowCurrentProfileNew}" /> | ||
</StackPanel> | ||
</Page> |
10 changes: 10 additions & 0 deletions
10
testing/TestHarness/TestHarness.Shared/Ext/Navigation/Apps/Chefs/ChefsHomePage.xaml.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
| ||
namespace TestHarness.Ext.Navigation.Apps.Chefs; | ||
|
||
public sealed partial class ChefsHomePage : Page | ||
{ | ||
public ChefsHomePage() | ||
{ | ||
this.InitializeComponent(); | ||
} | ||
} |
Oops, something went wrong.