shlomiassaf / ngx-modialog

Modal / Dialog for Angular
http://shlomiassaf.github.io/ngx-modialog
MIT License
686 stars 241 forks source link

Modal align #29

Closed joseSerapicos closed 8 years ago

joseSerapicos commented 8 years ago

Hi, it's possible to aligner the modal at the center of the screen? When we have a scroll down and open the modal we can't see the modal so we have to scroll up every time we open the modal. Thanks

shlomiassaf commented 8 years ago

Modal alignment is handled by bootstrap CSS, do you mean it's not aligned like the original bootstrap lib?

shlomiassaf commented 8 years ago

This was fixed when #31 was fixed

If you need alignment see #39 and use dialogClass to change the class and set alignment's in CSS.

joseSerapicos commented 8 years ago

Hi, thanks for your effort, it is a very useful component and I appreciate the latest changes. I need that modal always aligned to the center of the screen and to allow scroll whenever the modal is larger than the screen (modal need to create the scrool), so I made this simple change, if someone has a better idea post here please:

shlomiassaf commented 8 years ago

I suggest to change the modal-dialog to a custom class and provide a custom modal-content implementation (replace MessageModal) with your own angular 2 component.

Make the size adjustment and set the container to fixed so no scrolling is allowed.

The current customisation options should allow to do that.

joseSerapicos commented 8 years ago

Yes, I can do this, thanks for the suggestion :)