Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.
Sign upscrolling behavior for large modals #11
Comments
This comment has been minimized.
Show comment
Hide comment
This comment has been minimized.
lukemelia
Apr 10, 2015
Contributor
This would be a useful feature.
The modal-overlays div should not be functional IMO, besides being the attachment point for the modal. There is nothing in this library to prevent rendering multiple modals into modal-overlays, so having it fire close would be strange since it wouldn't be clear what component it should be routed to. We could consider making the modal a child of the ember-modal-overlay element.
|
This would be a useful feature. The |
This comment has been minimized.
Show comment
Hide comment
This comment has been minimized.
varblob
Apr 13, 2015
@samselikoff I've been using this styling
.ember-modal-overlay {
height: 100vh;
left: 0;
opacity: 0;
position: fixed;
right: 0;
top: 0;
z-index: 50;
}
.ember-modal-dialog {
z-index: 50;
position: absolute;
left:50%;
}
.ember-modal-dialog > div{
position: relative;
right: 50%;
}
.ember-modal-overlay.translucent {
opacity: 0.77;
filter: alpha(opacity=15);
background-color: #808080;
}
along with alignment top to handle large models. I haven't put it through the any sort of rigorous testing yet so use with caution.
varblob
commented
Apr 13, 2015
|
@samselikoff I've been using this styling
along with alignment top to handle large models. I haven't put it through the any sort of rigorous testing yet so use with caution. |
This comment has been minimized.
Show comment
Hide comment
This comment has been minimized.
smartlaksh
Apr 30, 2015
yes @lukemelia you're right. Also the modal should retain the center position even after the content height & width changed in the run time.
smartlaksh
commented
Apr 30, 2015
|
yes @lukemelia you're right. Also the modal should retain the center position even after the content height & width changed in the run time. |
This comment has been minimized.
Show comment
Hide comment
This comment has been minimized.
samselikoff
Apr 30, 2015
Collaborator
agree. i think we should make the modal a child of ember-modal-overlay. havent had time to come back to this yet.
|
agree. i think we should make the modal a child of |
lukemelia
referenced this issue
Jun 20, 2015
Closed
Scrollbar for large modals (or small browser window) #45
This comment has been minimized.
Show comment
Hide comment
This comment has been minimized.
|
Addressed by #79 |
samselikoff commentedApr 8, 2015
I'm having a hard time getting the styling just the way I want it for large modals. Essentially I want want Trello has:
Scrollbar on right, modal scrolls up and down.
I used flexbox to style the modal and overlay, but the problem is on scroll. Since the overlay is a sibling of the modal, calculating its height is the problem. If it's just fullscreen (something like
100vh), when your mouse cursor is over the overlay, the modal won't scroll:This is because the overlay is 100% height so, there's no overflow to scroll. Without using JavaScript I don't see a way to get its height to adjust - and even when I set it manually, I saw some strange visual quirks.
I'm wondering if it'd be possible to opt-out of the
.ember-modal-overlayelement, and to have the click event fireclosefrom the#modal-overlayselement? Or possibly even drop the.ember-modal-overlayaltogether, and#modal-overlayswould essentially also act as the overlay. That way it would wrap the content, making styling with flexbox (and other strategies) easier. Thoughts?