maxs15 / react-native-modalbox

A <Modal/> component for react-native
MIT License
2.89k stars 505 forks source link

Is it possible to remove the overlay? #254

Closed xstable closed 5 years ago

xstable commented 5 years ago

I use the modalBox as kind of Media-Toolbar.

I let it open at the bottom of the screen. Is it possible to remove the dark layer with opacity which is outside of my modal (the red framed area) image

If not, it would be a great feature to make this overlay optional!

xstable commented 5 years ago

Ok, didn't know, that this was meant by backdrop. I only know it as overlay. So for each one who struggle with this too.. set backdrop={false} to your Modal.

But there is still an issue. Even if I set backdrop to false, i can't move the Scrollview that lay behind. Any Idea, how to fix this?

petarivanovv9 commented 5 years ago

Hi @xstable, Did you find a way to fix it? I'm also trying to accomplish similar behavior.

xstable commented 5 years ago

Yer, I solved it by using isDisabled to prevent each action on it:

<Modal
          style={[styles.audioToolbarModal, styles.audioToolbarBottomModal]}
          position="bottom"
          backdrop
          swipeToClose={false}
          coverScreen
          onOpened={() => this.startRecording()}
          isDisabled={modalIsDisabled}
          ref={(ref) => { this.audioToolbar = ref; }}
        >