Skip to content

v6 can't scroll on iOS  #462

@pc035860

Description

@pc035860

Bug report

Describe the bug

I'm not able to scroll the modal content when the modal is opened in iOS Safari (or any webkit-based browsers on iOS).

To Reproduce

The "Modal with a lot of content" example on the doc site doesn't scroll for me.

https://react-responsive-modal.leopradel.com/#modal-with-a-lot-of-content

Expected behavior

It should scroll.

System information

  • Version of react-responsive-modal: 6.0.0
  • Version of react: 17.0.1
  • Browser version: Safari 13.1 on iOS 13.6

Additional context

As far as I know, the issue is caused by incorrectly setting disableBodyScroll element.
When using body-scroll-lock package on iOS, the ref element should be any ancestor of the scroll container.

I locally patch the refModal onto modal-container element and the issue is fixed.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions