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
feat(view): added iOS parameter for modal presentation style #6409
Conversation
@tsonevn It turns out this is not so easy as just passing a parameter to I've already implemented some default logic for I will investigate further, but wanted to open the discussion here for further ideas. |
Hey there @surdu - thanks for you effort. Here are a couple of thoughts: DefinitionsFirst of all - all OptionsThe My suggestion is to define a You can also have a callback in the options - which will be called if they are using the an option, that needs to give the control back to the user for additional setup of a view-controller for example. PRSeems that this PR is not as easy as originally thought. What do you think of moving the discussion back to the issue (#6387). We might pick only the |
@vakrilov I've made the changes that you requested. Also wrote a test for my changes. I took another test for the modal and just changed the way the options are passed. The test is somewhat overkill, but I guess there was a good reason to implement the test I copied like this, so I went with it. There is one thing that I want to do but I didn't manage to figure out how (probably can't be done at this stage of execution): I want to get styling informations about the Page that is about to be presented at this point. It would be nice to get the Page width and height expressed by the user is css and resize the pop-up accordingly. Also need the background color few lines bellow. For the old version of |
test |
test |
|
||
(<ViewCommon>view)._showNativeModalView(this, context, closeCallback, fullscreen, animated, stretched, iosOpts); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Note to self: removed iosOpts
by mistake
test |
test |
test |
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
PR Checklist
What is the current behavior?
Other than fullscreen or not, there is no way to set the rest of modal presentation styles for a modal on iOS
What is the new behavior?
You can now pass an extra parameter called
iOSPresentationStyle
to.showModal()
Implements #6387