Skip to content

Commit

Permalink
Document ReactModal__Body--open so people dare to use it
Browse files Browse the repository at this point in the history
  • Loading branch information
ksa authored and claydiffrient committed Oct 30, 2016
1 parent 3d8e5a0 commit e9fd43d
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,17 @@ This doesn't affect styling as no styles are applied to this element by default.
The default styles above are available on `Modal.defaultStyles`. Changes to this
object will apply to all instances of the modal.

### Body class
When the modal is opened a `ReactModal__Body--open` class is added to the `body` tag.
You can use this to remove scrolling on the the body while the modal is open.

```CSS
/* Remove scroll on the body when react-modal is open */
.ReactModal__Body--open {
overflow: hidden;
}
```

## Examples
Inside an app:

Expand Down

0 comments on commit e9fd43d

Please sign in to comment.