m

    Mjahangiry75

    1 year ago
    how to collapse
    bottomsheet
    in compose when
    backpressed
    d

    dewildte

    1 year ago
    You can try the
    BackHandler
    Composable
    m

    Mjahangiry75

    1 year ago
    Could you please show me an example?
    Ch8n

    Ch8n

    1 year ago
    Hi @Mjahangiry75 see this
    BackHandler(enabled = bottomSheetScaffoldState.bottomSheetState.isExpanded) {
    
    scope.launch{
    bottomSheetScaffoldState.bottomSheetState.collapse()
    }
    
    }