mirror of
https://github.com/NativeScript/NativeScript.git
synced 2025-08-16 11:42:04 +08:00
Update a test page.
This commit is contained in:
5
apps/ui-tests-app/segmented-bar/all.ts
Normal file
5
apps/ui-tests-app/segmented-bar/all.ts
Normal file
@ -0,0 +1,5 @@
|
||||
import frame = require("ui/frame");
|
||||
|
||||
export function navigate(args) {
|
||||
frame.topmost().navigate("segmented-bar/clean");
|
||||
}
|
@ -1,10 +1,12 @@
|
||||
<Page>
|
||||
<GridLayout rows="auto, *">
|
||||
<SegmentedBar style="color: green; background-color: yellow; font-weight: bold; font-size: 20; font-style: italic; font-family: monospace;">
|
||||
<StackLayout>
|
||||
<SegmentedBar selectedIndex="2" style="color: yellow; background-color: blue; font-weight: bold; font-size: 20; font-style: italic; font-family: monospace;" selectedBackgroundColor="red">
|
||||
<SegmentedBar.items>
|
||||
<SegmentedBarItem title="Item 1" />
|
||||
<SegmentedBarItem title="Item 2" />
|
||||
<SegmentedBarItem title="Item 3" />
|
||||
</SegmentedBar.items>
|
||||
</SegmentedBar>
|
||||
</GridLayout>
|
||||
<Button text="go to cleared page" tap="navigate"/>
|
||||
</StackLayout>
|
||||
</Page>
|
5
apps/ui-tests-app/segmented-bar/clean.ts
Normal file
5
apps/ui-tests-app/segmented-bar/clean.ts
Normal file
@ -0,0 +1,5 @@
|
||||
import frame = require("ui/frame");
|
||||
|
||||
export function navigate(args) {
|
||||
frame.topmost().goBack();
|
||||
}
|
12
apps/ui-tests-app/segmented-bar/clean.xml
Normal file
12
apps/ui-tests-app/segmented-bar/clean.xml
Normal file
@ -0,0 +1,12 @@
|
||||
<Page>
|
||||
<StackLayout>
|
||||
<SegmentedBar selectedIndex="1">
|
||||
<SegmentedBar.items>
|
||||
<SegmentedBarItem title="Item 1" />
|
||||
<SegmentedBarItem title="Item 2" />
|
||||
<SegmentedBarItem title="Item 3" />
|
||||
</SegmentedBar.items>
|
||||
</SegmentedBar>
|
||||
<Button text="go to previous page" tap="navigate"/>
|
||||
</StackLayout>
|
||||
</Page>
|
Reference in New Issue
Block a user