Skip to content
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

"VirtualizedLists should never be nested inside plain ScrollViews with the same orientation - use another VirtualizedList-backed container instead." while tap item picker #3433

Open
6 tasks done
patricktan98 opened this issue Feb 4, 2021 · 11 comments
Labels

Comments

@patricktan98
Copy link

I have gone through these following points

Issue Description

node, npm, react-native, react and native-base version, expo version if used, xcode version

Expected behaviour

The Item picker should view without warnings.

Actual behaviour

When Item Picker is shown, the 'VirtualizedLists should never be nested inside plain ScrollViews with the same orientation - use another VirtualizedList-backed container instead.' warning shown.

Steps to reproduce

<Item picker>
                        <Picker
                            mode="dropdown"
                            iosIcon={<Icon name="arrow-down" />}
                            style={{ width: undefined }}
                            placeholder="All"
                            Header="Transaction Type"
                            iosHeader="Transaction Type"
                            placeholderStyle={{ color: "#bfc6ea" }}
                            placeholderIconColor="#007aff"
                            selectedValue={this.state.selected2}
                            onValueChange={this.onValueChange2.bind(this)}
                        >
                            <Picker.Item label="Payment" value="Payment" />
                            <Picker.Item label="Top up" value="Topup" />
                            <Picker.Item label="Refunded" value="Refunded" />
                        </Picker>
                    </Item>

Video Link: https://user-images.githubusercontent.com/50147719/106872277-14bbff00-670e-11eb-9497-4407ca5ac2cb.mov

Is the bug present in both iOS and Android or in any one of them?

The bugs occur in iOS and Android. I have tested in iOS 14.4 and Android 11.0

Any other additional info which would help us debug the issue quicker.

###Important

If you want your issue to be looked at quicker, attach a snack reproducible with your issue. Makes it easier for us!

@dlenskyi
Copy link

dlenskyi commented Feb 9, 2021

Same here
I will provide you more details from Element inspector
So basically thats because Picker component renders FlatList inside VirtualizedList (screenshot below)

Снимок экрана 2021-02-09 в 18 29 30

Снимок экрана 2021-02-09 в 18 29 49

@dlenskyi
Copy link

dlenskyi commented Feb 9, 2021

Same issue here #3334

@KasTasElis
Copy link

Same issue for me, still waiting for solutions?

@gregormelhorn
Copy link

Please fix this and accept the pull from dlferro!

@megacherry
Copy link

yes, please accept the pull to resolve this issue.

@hoekma
Copy link

hoekma commented Jan 2, 2022

@Ajamuar I am also still having this problem in NativeBase v2 with the sample code. I realize you all are focused on v3 right now, but I hope you will continue to support v2 for a while until we get a chance to rewrite our app.

 <Container>
      <Header />
      <Content>
        <Form>
          <Item>
            <Input value="test" onChangeText={() => true} />
          </Item>
          <Item picker>
            <Picker
              mode="dropdown"
              iosIcon={<Icon name="arrow-down" />}
              style={{ width: undefined }}
              placeholder="Select your SIM"
              placeholderStyle={{ color: '#bfc6ea' }}
              placeholderIconColor="#007aff"
              selectedValue={selected2}
              onValueChange={() => true}
            >
              <Picker.Item label="Wallet" value="key0" />
              <Picker.Item label="ATM Card" value="key1" />
              <Picker.Item label="Debit Card" value="key2" />
              <Picker.Item label="Credit Card" value="key3" />
              <Picker.Item label="Net Banking" value="key4" />
            </Picker>
          </Item>
        </Form>
      </Content>
    </Container>

@stale
Copy link

stale bot commented Mar 3, 2022

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale label Mar 3, 2022
@moseslucas
Copy link

I hope the team at native base continue support for nativebase v2 and fix this issue. There are still many apps out there that uses v2

@stale stale bot removed the stale label Apr 10, 2022
@stale
Copy link

stale bot commented Jun 10, 2022

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale label Jun 10, 2022
@kleydon
Copy link

kleydon commented Apr 10, 2023

It isn't stale, its still an issue.

@jmgarciasanti
Copy link

Yes, still an issue. It's thrown as error on iOS devices after migrating app to Expo SDK 48. The error is shown in every screen I have with a Form including a "Select" Native Base component. The error is not thrown on Android.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

9 participants