ui-material-components
ui-material-components copied to clipboard
BottomSheet Error open from rootlayout angular 13
Make sure to check the demo app(s) for sample usage
Which platform(s) does your issue occur on?
- Android
- Android versions 8.2.2
- emulator
Please, provide the following version numbers that your issue occurs with:
- CLI: 8.2.0
- Cross-platform modules: 8.2.0
- Runtime(s): 8.2.2
- Plugin(s): 7.0.3
Please, tell us how to recreate the issue in as much detail as possible.
I try to open a bottomsheet from a rootlayout. But it shows an error: JS: ERROR Error: Uncaught (in promise): Error: java.lang.NullPointerException: Attempt to invoke virtual method 'androidx.fragment.app.FragmentTransaction androidx.fragment.app.FragmentTransaction.add(androidx.fragment.app.Fragment, java.lang.String)' on a null object reference JS: _showNativeBottomSheet(file: src/webpack:/rootLSheet/node_modules/@nativescript-community/ui-material-bottomsheet/bottomsheet.android.js:185:0) JS: at showBottomSheet(file: src/webpack:/rootLSheet/node_modules/@nativescript-community/ui-material-bottomsheet/bottomsheet-common.js:101:0) JS: at (file: src/webpack:/rootLSheet/node_modules/@nativescript-community/ui-material-bottomsheet/angular/fesm2015/nativescript-community-ui-material-bottomsheet-angular.mjs:31:0) JS: at invoke(file: src/webpack:/rootLSheet/node_modules/zone.js/fesm2015/zone.js:372:0) JS: at onInvoke(file: src/webpack:/rootLSheet/node_modules/@angular/core/fesm2015/core.mjs:25548:0) JS: at invoke(file: src/webpack:/rootLSheet/node_modules/zone.js/fesm2015/zone.js:371:0) JS: at run(file: src/webpack:/rootLSheet/node_modules/zone.js/fesm2015/zone.js:134:0) JS: at (file: src/webpack:/rootLSheet/node_modules/zone.js/fesm2015/zone.js:1275:0) JS: at invokeTask(file:///data/data/org.nativescri...
`const options: BottomSheetOptions = {
viewContainerRef: this.containerRef,
context: ['Facebook', 'Google', 'Twitter'],
animated:true,
peekHeight:200,
transparent:true,
};
this.bottomSheet.show(ItemDetailComponent, options)`