Platform: Windows 10
Fuse: Fuse version 0.10.0 (build 6032)
Issue: Using bindings with NavigateTo
that targets a page that has ux:AutoBind
set to false
will not display the targeted page. This feels like it is expected behavior but wanted to confirm and also see if there is better way to solve my problem. Which is how to do link to pages that have their ux:AutoBind
set to false
while still supporting binding swith NavigateTo
?
For example:
<!-- Success: Sub Page will display -->
<NavigateTo Target="_subPage1" NavigationContext="{context}" />
<!-- Fails: Requires button above to bind the sub page first then button will be active -->
<NavigateTo Target="{link}" NavigationContext="{context}" />
A working example of what I mean is below:
MainView.ux
<App Theme="Basic" Background="#eeeeeeff">
<ClientPanel>
<JavaScript File="MainView.js" />
<Panel>
<HierarchicalNavigation ux:Name="_nav" Active="_mainPage" />
<Page ux:Class="MyPage">
<EnteringAnimation>
<Move X="1" RelativeTo="ParentSize" />
</EnteringAnimation>
<ExitingAnimation>
<Move X="-1" RelativeTo="ParentSize" />
</ExitingAnimation>
</Page>
<MyPage ux:Name="_mainPage">
<StackPanel>
<Button Text="Click first and nothing will happen">
<Clicked>
<NavigateTo Target="{link}" NavigationContext="{context}" />
</Clicked>
</Button>
<Button Text="Click firts and button above will work">
<Clicked>
<NavigateTo Target="_subPage1" NavigationContext="{context}" />
</Clicked>
</Button>
</StackPanel>
</MyPage>
<MyPage ux:Name="_subPage1" ux:AutoBind="false">
<StackPanel>
<Text>Welcome to subpage 1</Text>
<Button Text="Go Back">
<Clicked>
<GoBack />
</Clicked>
</Button>
</StackPanel>
</MyPage>
</Panel>
</ClientPanel>
</App>
MainView.js
module.exports = {
link: "_subPage1",
context: "_nav"
};