test: add expand examples

This commit is contained in:
Vasil Chimev
2018-08-22 15:00:44 +03:00
committed by Martin Yankov
parent 429ac8712f
commit 9549f6b6a2
6 changed files with 57 additions and 0 deletions

View File

@@ -0,0 +1,10 @@
<Page class="page"
xmlns="http://schemas.nativescript.org/tns.xsd"
xmlns:fragments="expand/fragments">
<ActionBar>
<Label text="Action Bar"></Label>
</ActionBar>
<fragments:grid-3x3-fragment></fragments:grid-3x3-fragment>
</Page>

View File

@@ -0,0 +1,8 @@
import { View, EventData } from "tns-core-modules/ui/core/view";
export function onNavigate(args: EventData) {
const view = args.object as View;
const route = view["route"];
view.page.frame.navigate(route);
}

View File

@@ -0,0 +1,20 @@
<Page class="page"
xmlns="http://schemas.nativescript.org/tns.xsd"
xmlns:fragments="listview/fragments"
navigatingTo="onNavigatingTo">
<ActionBar>
<Label text="Expand Examples"></Label>
</ActionBar>
<StackLayout horizontalAlignment="center">
<StackLayout>
<Label text="Pages w/ ActionBar"></Label>
<Button text="Expand Grid" tap="onNavigate" route="expand/action-bar/expand-gridlayout-3x3-page" />
</StackLayout>
<StackLayout>
<Label text="Pages w/o ActionBar"></Label>
<Button text="Expand Grid" tap="onNavigate" route="expand/no-action-bar/expand-gridlayout-3x3-page" />
</StackLayout>
</StackLayout>
</Page>

View File

@@ -0,0 +1,11 @@
<GridLayout rows="*, *, *" columns="*, *, *" class="grid" iosExpandSafeArea="false">
<Label row="0" col="0" text="overflowing text, overflowing text"></Label>
<Label row="0" col="1" text="overflowing text, overflowing text"></Label>
<Label row="0" col="2" text="overflowing text, overflowing text"></Label>
<Label row="1" col="0" text="overflowing text, overflowing text"></Label>
<Label row="1" col="1" text="overflowing text, overflowing text"></Label>
<Label row="1" col="2" text="overflowing text, overflowing text"></Label>
<Label row="2" col="0" text="overflowing text, overflowing text"></Label>
<Label row="2" col="1" text="overflowing text, overflowing text"></Label>
<Label row="2" col="2" text="overflowing text, overflowing text"></Label>
</GridLayout>

View File

@@ -0,0 +1,7 @@
<Page class="page"
xmlns="http://schemas.nativescript.org/tns.xsd"
xmlns:fragments="expand/fragments"
actionBarHidden="true">
<fragments:grid-3x3-fragment></fragments:grid-3x3-fragment>
</Page>

View File

@@ -16,6 +16,7 @@
<Button text="RadListView Examples" tap="onNavigate" route="radlistview/radlistview-page"></Button>
<Button text="RadCalendar Examples" tap="onNavigate" route="radcalendar/radcalendar-page"></Button>
<Button text="RadChart Examples" tap="onNavigate" route="radchart/radchart-page"></Button>
<Button text="Expand Examples" tap="onNavigate" route="expand/expand-page"></Button>
</StackLayout>
</ScrollView>