Skip to content

Tab containers are trying to acheve the same height after switching back and forth #577

@laukaichung

Description

@laukaichung

All of my tabs contain lists. I notice that the tab component in 2.0.10 would make all tab containers of equal height after you switch back and forth between the tabs.

For example, the first tab, which is shorter, is trying to adjust the height after switching to a longer tab:

Image of Yaktocat

render(){
   let list = []
   for(let i = 0;i < 20;i++){
        list.push(<ListItem><Text>{i}</Text></ListItem>)
   }
   return(
            <Container>
                <Content>
                    <Tabs>
                        <Tab heading={<TabHeading><Text>Tab1</Text></TabHeading>}>
                            <Grid>
                                <Row>
                                    <Text>Lorem Ipsum is simply</Text>
                                </Row>
                                <Row>
                                    <Text>Lorem Ipsum is simply</Text>
                                </Row>
                            </Grid>
                        </Tab>
                        <Tab heading={<TabHeading><Text>Tab2</Text></TabHeading>}>
                            <List initialListSize={3}>{list}</List>
                        </Tab>
                        <Tab heading={<TabHeading><Text>Tab3</Text></TabHeading>}>
                            <List initialListSize={3}>{list}</List>
                        </Tab>
                    </Tabs>
                </Content>
            </Container>
     )
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions