polaris
polaris copied to clipboard
Tabs not collapsing when inside a AnnotatedSection element
Issue summary
When using Tabs within an <Layout.AnnotatedSection> element they don't collapse as they should when you reach mobile screen size.
Expected behavior
I'd expect the tabs to collapse like shown in the documentation.

Actual behavior
When I shrink my browser the tabs don't collapse causing the content to breakout as shown in the attached screenshot.

Steps to Reproduce the Problem
Place a Tabs element instead a Layout.AnnotatedSection element as shown below and resize your browser.
<Layout>
<Layout.AnnotatedSection
title="Store details"
description="Shopify and your customers will use this information to contact you."
>
<Card sectioned>
<Tabs
fitted
selected={0}
tabs={[
{
id: 'all-customers',
title: 'All',
panelID: 'all-customers-content',
},
{
id: 'accepts-marketing',
title: 'Accepts marketing',
panelID: 'accepts-marketing-content',
},
{
id: 'not-accept-marketing',
title: 'Not accept marketing',
panelID: 'not-accept-marketing-content',
}
]}
/>
</Card>
</Layout.AnnotatedSection>
</Layout>
Specifications
- Polaris version: 1.0.3
- React version: 15.4.2
- Browser: Chrome, Safari, Firefox (latest stable)
- Device: Macbook Pro
- Operating System: Mac OS
Confirmed that this is happening, we should have a fix out by the end of the week. I'll close this issue once we cut the new release.
Should be fixed by v1.1.0