nativescript-nbmaterial-bottomsheet
A nativescript implementation of material bottom sheet (with animation). For iOS and Android.
npm i --save nativescript-nbmaterial-bottomsheet
- Version: 1.0.0
- GitHub:
- NPM: https://www.npmjs.com/package/nativescript-nbmaterial-bottomsheet
- Downloads:
- Last Day: 0
- Last Week: 0
- Last Month: 0
Nativescript implementation of the Material Bottom Sheet
The module implement Bottom Sheet Layout on both iOS and Android.
There is an animation effect on open and on close.
bottomSheet = page.getViewById("bottomsheet");
export function showBS() {
bottomSheet.show();
}
export function hideBS() {
bottomSheet.hide();
}
<Page xmlns="http://schemas.nativescript.org/tns.xsd"
xmlns:bnav="nativescript-nbmaterial-bottomnav">
<bs:BottomSheetModal id="bottomsheet">
<bs:BottomSheetModal.template>
<GridLayout rows="auto" columns="auto">
<StackLayout>
<Label text="Ready?" textWrap="true" />
<Label text="Steady?" textWrap="true" />
<Label text="Go!" textWrap="true" />
<Label text="Cool" textWrap="true" />
<Button text="HIDE BS" tap="hideBS" class="btn btn-primary btn-active"/>
</StackLayout>
</GridLayout>
</bs:BottomSheetModal.template>
</bs:BottomSheetModal>
</Page>
}