-
Notifications
You must be signed in to change notification settings - Fork 39
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
Popup is not aligned to the center of the screen #9
Comments
Hi @mailyokesh , sorry for the trouble. The popup currently should expand to fill the screen horizontally. Can you provide a screen capture for this issue? |
Your library is awesome for the purpose of throwing popup in ios when app is in foreground. Thanks a lot. How Notification Popup is configured in render This is from a iphone 8 simulator. I see the same in other version of iphone as well |
Thanks for the report! Definitely some style issues in the library. My bad. I will fix it and together add the support of tablet width in the next version. But I am too busy to do it this week. If you are in an urgent, you may:
You can try adding {left:8, right: 8} in the style of popupContainer. See if it fixes the problem. |
Adding |
Adding |
Fixed in release v1.2.0. Thanks for the contributions! |
Hi Awesome library for showing popups when app is in foreground. When I use the latest library its not centered, rather the whole ui is aligned to the left in ios simulator.
Can you add alignSelf: 'center' to the below code? am not familiar with how to do checkin to npm library, if you can suggest how to do I can do this as well.
const getAnimatedContainerStyle = ({containerSlideOffsetY, containerDragOffsetY, containerScale}) => {
// Map 0-1 value to translateY value
const slideInAnimationStyle = {
transform: [
{translateY: containerSlideOffsetY.interpolate(slideOffsetYToTranslatePixelMapping)},
{translateY: containerDragOffsetY},
{scale: containerScale},
],
alignSelf: 'center',
};
// Combine with original container style
const animatedContainerStyle = [
styles.popupContainer,
slideInAnimationStyle,
];
return animatedContainerStyle;
};
The text was updated successfully, but these errors were encountered: