Description
Changing Content property of ShellContent does not change visual content. You need to reroute to the page in another tab and when you come back it changes, but only on windows and android. On Mac and iOS it doesn't change anyway.
Steps to Reproduce
- Create Page inside ShellContent
- try change Content property
- it doesn't change visual content
public partial class MainPage : ContentPage
{
public MainPage()
{
InitializeComponent();
}
private void OnCounterClicked(object sender, EventArgs e)
{
if (this.Parent is ShellContent shellContent)
{
var contentPage = new ContentPage();
var label = new Label();
label.Text = "Page changed";
label.FontSize = 30;
label.HorizontalOptions = LayoutOptions.Center;
label.VerticalOptions = LayoutOptions.Center;
contentPage.Content = label;
shellContent.ContentTemplate = null;
shellContent.Content = contentPage;
// there is no way to reload shell content
}
}
}
Link to public reproduction project repository
https://github.com/idexus/issue_maui_Content
Version with bug
7.0 (current)
Last version that worked well
Unknown/Other
Affected platforms
iOS, Android, Windows, macOS, I was not able test on other platforms
Affected platform versions
iOS 16.2, Android API 33, macOS 13.1, Windows 10
Did you find any workaround?
No response
Relevant log output
No response
Description
Changing Content property of ShellContent does not change visual content. You need to reroute to the page in another tab and when you come back it changes, but only on windows and android. On Mac and iOS it doesn't change anyway.
Steps to Reproduce
Link to public reproduction project repository
https://github.com/idexus/issue_maui_Content
Version with bug
7.0 (current)
Last version that worked well
Unknown/Other
Affected platforms
iOS, Android, Windows, macOS, I was not able test on other platforms
Affected platform versions
iOS 16.2, Android API 33, macOS 13.1, Windows 10
Did you find any workaround?
No response
Relevant log output
No response