rotorgames / Rg.Plugins.Popup

Xamarin Forms popup plugin
MIT License
1.15k stars 336 forks source link

Popup popped after clicking anywhere on the screen, only on iOS #732

Closed Eden-Mor closed 2 years ago

Eden-Mor commented 2 years ago

🐛 Bug Report

I have a popup that works perfectly in android, and bugs out on iOS So the popup loads all the information correctly, but when I try to click any part of the popup (not the outside of the popup of course) the popup gets popped, I also have buttons on this popup, and they do not execute, they just pop the popup. https://gyazo.com/c9a239878b2dded27dfb25db07811892

Expected behavior

Popup should not be popping when clicking inside the popup.

Reproduction steps

I removed all the unncessary StaticResource color styles and label gesture buttons so you could test it out without changing the code. This bug still occurs with the popup below.

Heres my code for pushing the popup await Rg.Plugins.Popup.Services.PopupNavigation.Instance.PushAsync(new DashboardPopup(), true);


<pages:PopupPage
    x:Class="trainingGrid.Views.Popups.DashboardPopup"
    xmlns="http://xamarin.com/schemas/2014/forms"
    xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
    xmlns:animations="clr-namespace:Rg.Plugins.Popup.Animations;assembly=Rg.Plugins.Popup"
    xmlns:pages="clr-namespace:Rg.Plugins.Popup.Pages;assembly=Rg.Plugins.Popup">
    <pages:PopupPage.Animation>
        <animations:ScaleAnimation
            DurationIn="400"
            DurationOut="300"
            EasingIn="SinOut"
            EasingOut="SinIn"
            HasBackgroundAnimation="True"
            PositionIn="Center"
            PositionOut="Center"
            ScaleIn="1.2"
            ScaleOut="0.8" />
    </pages:PopupPage.Animation>
    <StackLayout
        Padding="0,40,20,0"
        HorizontalOptions="EndAndExpand"
        InputTransparent="True"
        VerticalOptions="Start">
        <Frame Padding="1" WidthRequest="150">
            <FlexLayout
                AlignItems="Center"
                Direction="Column"
                IsClippedToBounds="True"
                JustifyContent="SpaceBetween">
                <Grid FlexLayout.AlignSelf="Stretch" RowDefinitions="5,*,*,5">
                    <Label
                        Grid.Row="1"
                        Padding="0"
                        FontFamily="BoldT"
                        HorizontalOptions="Center"
                        HorizontalTextAlignment="Center"
                        Text="test2" />
                    <Label
                        Grid.Row="2"
                        Padding="0"
                        HorizontalOptions="Center"
                        HorizontalTextAlignment="Center"
                        Text="test"
                        VerticalOptions="Start" />
                    <BoxView
                        Grid.Row="3"
                        HeightRequest="1"
                        HorizontalOptions="FillAndExpand"
                        VerticalOptions="End" />
                </Grid>
                <StackLayout>
                    <FlexLayout
                        AlignItems="Center"
                        Direction="Column"
                        IsClippedToBounds="True"
                        JustifyContent="SpaceBetween">
                        <Label HorizontalTextAlignment="Center" Text="test" />
                        <Label Text="My Account">
                        </Label>
                        <Label Text="Support">
                        </Label>
                        <Label Text="Disclaimer">
                        </Label>
                        <Label
                            Margin="0,0,0,10"
                            FontFamily="BoldT"
                            Text="Logout">
                        </Label>
                    </FlexLayout>
                </StackLayout>
            </FlexLayout>
        </Frame>
    </StackLayout>
</pages:PopupPage>```

### Configuration
Xamarin Forms is on version 5.0.0.2401
Rg Popup is on 2.1.0

**Platform:** 
- [X ] :iphone: iOS
Eden-Mor commented 2 years ago

Im closing this ticket because I didnt notice I added "InputTransparent=true" to the background which made the children also input transparent....