Skip to content

feat(android): edge to edge #10774

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 8 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion apps/toolbox/src/main-page.xml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<Page xmlns="http://schemas.nativescript.org/tns.xsd" navigatingTo="navigatingTo" class="page">
<Page xmlns="http://schemas.nativescript.org/tns.xsd" navigatingTo="navigatingTo" class="page" androidOverflowEdge="bottom" >
<Page.actionBar>
<ActionBar title="Dev Toolbox" icon="" class="action-bar" iosLargeTitle="true" iosShadow="false">
</ActionBar>
Expand Down Expand Up @@ -31,3 +31,4 @@
</ScrollView>
</StackLayout>
</Page>

14 changes: 13 additions & 1 deletion apps/toolbox/src/main-view-model.ts
Original file line number Diff line number Diff line change
@@ -1,9 +1,21 @@
import { Observable, Frame, StackLayout } from '@nativescript/core';
import { Observable, Frame, StackLayout, AndroidOverflowInsetData } from '@nativescript/core';

export class HelloWorldModel extends Observable {
viewDemo(args) {
Frame.topmost().navigate({
moduleName: `pages/${args.object.text}`,
});
}

onInset(args: AndroidOverflowInsetData) {
args.inset.top += 10; // add 10px to the top inset
args.inset.bottom += 10; // add 10px to the bottom inset
args.inset.left += 10; // add 10px to the left inset
args.inset.right += 10; // add 10px to the right inset

args.inset.topConsumed = true; // consume the top inset
args.inset.bottomConsumed = true; // consume the bottom inset
args.inset.leftConsumed = true; // consume the left inset
args.inset.rightConsumed = true; // consume the right inset
}
}
2 changes: 1 addition & 1 deletion apps/toolbox/src/pages/list-page.xml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<Page xmlns="http://schemas.nativescript.org/tns.xsd" navigatingTo="navigatingTo" actionBarHidden="false">
<Page xmlns="http://schemas.nativescript.org/tns.xsd" navigatingTo="navigatingTo" actionBarHidden="false" androidOverflowEdge="bottom">
<Page.actionBar>
<ActionBar>
<Label text="Components" class="header"/>
Expand Down
Binary file modified packages/core/platforms/android/widgets-release.aar
Binary file not shown.
Loading