mirror of
https://github.com/NativeScript/NativeScript.git
synced 2025-11-05 13:26:48 +08:00
fix(ios-layouts): switch contentInsetAdjustmentBehavior on ScrollView (#5411)
* fix(layouts): switch contentInsetAdjustmentBehavior on ScrollView * chore(ui-tests-app): add test for ScrollView as a root Page element
This commit is contained in:
committed by
GitHub
parent
e1eea8efe7
commit
b8e0beccdd
@@ -12,5 +12,7 @@ export function pageLoaded(args: EventData) {
|
||||
export function loadExamples() {
|
||||
const examples = new Map<string, string>();
|
||||
examples.set("scrolling-and-sizing", "scroll-view/scrolling-and-sizing");
|
||||
examples.set("safe-area-root-element", "scroll-view/safe-area-root-element");
|
||||
examples.set("safe-area-sub-element", "scroll-view/safe-area-sub-element");
|
||||
return examples;
|
||||
}
|
||||
15
apps/app/ui-tests-app/scroll-view/safe-area-root-element.xml
Normal file
15
apps/app/ui-tests-app/scroll-view/safe-area-root-element.xml
Normal file
@@ -0,0 +1,15 @@
|
||||
<Page xmlns="http://schemas.nativescript.org/tns.xsd" navigatingTo="onNavigatingTo" class="page">
|
||||
|
||||
<Page.actionBar>
|
||||
<ActionBar title="My App" icon="" class="action-bar">
|
||||
</ActionBar>
|
||||
</Page.actionBar>
|
||||
|
||||
<ScrollView>
|
||||
<StackLayout>
|
||||
<GridLayout height="30" backgroundColor="red" />
|
||||
<GridLayout height="30" backgroundColor="yellow" />
|
||||
<GridLayout height="30" backgroundColor="green" />
|
||||
</StackLayout>
|
||||
</ScrollView>
|
||||
</Page>
|
||||
17
apps/app/ui-tests-app/scroll-view/safe-area-sub-element.xml
Normal file
17
apps/app/ui-tests-app/scroll-view/safe-area-sub-element.xml
Normal file
@@ -0,0 +1,17 @@
|
||||
<Page xmlns="http://schemas.nativescript.org/tns.xsd" navigatingTo="onNavigatingTo" class="page">
|
||||
|
||||
<Page.actionBar>
|
||||
<ActionBar title="My App" icon="" class="action-bar">
|
||||
</ActionBar>
|
||||
</Page.actionBar>
|
||||
|
||||
<GridLayout>
|
||||
<ScrollView height="50" verticalAlignment="top">
|
||||
<StackLayout>
|
||||
<GridLayout height="30" backgroundColor="red" />
|
||||
<GridLayout height="30" backgroundColor="yellow" />
|
||||
<GridLayout height="30" backgroundColor="green" />
|
||||
</StackLayout>
|
||||
</ScrollView>
|
||||
</GridLayout>
|
||||
</Page>
|
||||
Reference in New Issue
Block a user