MySpaceFloating
This template allows you to put an overlay that will be present on main page.
Then to create your regular template:
- Boilerplate
- Full Example
class MyCustomMySpaceFloating: MySpaceFloating {
@Composable
override fun Content(params: MySpaceFloatingParameters) {
// Your custom design here
}
}
class MyCustomMySpaceFloating : MySpaceFloating {
private val myMealButtonVM: MyMealButtonViewModel = MyMealButtonViewModel()
@Composable
override fun Content(params: MySpaceFloatingParameters) {
MyMealButton.View(myMealButtonVM = myMealButtonVM) {
params.onClickAction()
}
}
}
info
In our Sample we are showing the number or meals currently in the basket at the bottom of screen
Params
data class MySpaceFloatingParameters(
val onClickAction: () -> Unit // to call on click on default implementation redirect to my mealz
)