Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve modal component by adding toggleOverflow and transition options #255

Merged
merged 6 commits into from
Jul 17, 2020

Conversation

sebnitu
Copy link
Owner

@sebnitu sebnitu commented Jul 17, 2020

Problem

There are a few missing core features on the modal component such as the ability to toggle the overflow:hidden on elements and the ability to disable transitions.

Solution

This PR adds two new feature options:

  • toggleOverflow (default: 'body') - Toggle overflow:hidden on all matching elements provided by the CSS selector. Set to falsy to disable.
  • transition (default: true) - Toggle the transition animation for the modal. Set to false to disable which will only ever apply the stateOpened and stateClosed states and ignore stateOpening and stateClosing.

@sebnitu sebnitu marked this pull request as ready for review July 17, 2020 04:58
@sebnitu sebnitu merged commit 04bbe99 into master Jul 17, 2020
@sebnitu sebnitu deleted the sn-improve-modal branch July 17, 2020 04:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant