BottomSheets

Like with Dialogs, the Router doesn't have a special method like router.routerBTS(...) to navigate to a BottomSheet, as this would break the project's philosophy. The caller shouldn't know what it is calling; it only navigates by Path. Therefore, your BottomSheet screen should implement the ViewBTS interface to inform the Router that this screen is a BottomSheet. This means that only the Screen knows that it is a BottomSheet and knows how to present itself.

In practice, you don't need to implement the ViewBTS interface yourself. You can use predefined classes available in the Fragment bootstrap package and Compose bootstrap package.

Implementation

You can read more about implementing BottomSheets in the Fragment and Compose sections.

Additionally, since BottomSheets usually send results, refer to the ResultApi section for more information.

Last updated