mirror of
https://github.com/NativeScript/NativeScript.git
synced 2025-11-05 13:26:48 +08:00
test: include test page for button highlight related to issue 4740 (#4952)
This commit is contained in:
@@ -0,0 +1,7 @@
|
||||
.btn {
|
||||
font-size: 18;
|
||||
}
|
||||
|
||||
.btn:highlighted {
|
||||
background-color: red
|
||||
}
|
||||
@@ -0,0 +1,5 @@
|
||||
import * as frame from "tns-core-modules/ui/frame";
|
||||
|
||||
export function onTap() {
|
||||
frame.topmost().navigate("ui-tests-app/button/highlight-4740/sub-page");
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
|
||||
<Page
|
||||
xmlns="http://schemas.nativescript.org/tns.xsd" class="page">
|
||||
<StackLayout class="p-20">
|
||||
<Button text="go to sub" tap="onTap" class="btn"/>
|
||||
</StackLayout>
|
||||
</Page>
|
||||
5
apps/app/ui-tests-app/button/highlight-4740/sub-page.ts
Normal file
5
apps/app/ui-tests-app/button/highlight-4740/sub-page.ts
Normal file
@@ -0,0 +1,5 @@
|
||||
import * as frame from "tns-core-modules/ui/frame";
|
||||
|
||||
export function goBack() {
|
||||
frame.goBack();
|
||||
}
|
||||
4
apps/app/ui-tests-app/button/highlight-4740/sub-page.xml
Normal file
4
apps/app/ui-tests-app/button/highlight-4740/sub-page.xml
Normal file
@@ -0,0 +1,4 @@
|
||||
<Page
|
||||
xmlns="http://www.nativescript.org/tns.xsd">
|
||||
<Button text="goBack" tap="goBack" />
|
||||
</Page>
|
||||
@@ -18,5 +18,6 @@ export function loadExamples() {
|
||||
examples.set("border-playground","button/border-playground");
|
||||
examples.set("issue-4287","button/issue-4287");
|
||||
examples.set("issue-4385","button/issue-4385");
|
||||
examples.set("highlight-4740","button/highlight-4740/highlight-4740");
|
||||
return examples;
|
||||
}
|
||||
Reference in New Issue
Block a user