Skip to content

Commit

Permalink
Remove Page separator prop as pages never have a separator
Browse files Browse the repository at this point in the history
  • Loading branch information
BPScott committed Jan 26, 2021
1 parent 640a1ef commit d6cdb87
Show file tree
Hide file tree
Showing 4 changed files with 1 addition and 27 deletions.
1 change: 1 addition & 0 deletions UNRELEASED.md
Expand Up @@ -17,6 +17,7 @@ Use [the changelog guidelines](https://git.io/polaris-changelog-guidelines) to f
- Removed `button-filled-disabled` and `plain-button-background` SASS mixins ([#3817](https://github.com/Shopify/polaris-react/pull/3817))
- Removed `text-emphasis-placeholder` SASS mixin ([#3889](https://github.com/Shopify/polaris-react/pull/3889))
- Removed `plain` property in `Pagination` as it no longer has any effect. ([#3833](https://github.com/Shopify/polaris-react/pull/3833))
- Removed `separator` property in `Page` as it no longer has any effect.

### Enhancements

Expand Down
18 changes: 0 additions & 18 deletions src/components/Page/README.md
Expand Up @@ -19,7 +19,6 @@ keywords:
- full-width page
- narrow-width page
- page with action groups
- page with separator
- outer wrapper
- page actions
- page layouts
Expand Down Expand Up @@ -174,7 +173,6 @@ Use for detail pages, which should have pagination and breadcrumbs, and also oft
hasNext: true,
}}
additionalNavigation={<Avatar size="small" initials="CD" customer={false} />}
separator
>
<p>Page content</p>
</Page>
Expand Down Expand Up @@ -430,22 +428,6 @@ Use action groups for sets of actions that relate to one another, particularly w
</Page>
```

### Page with separator

<!-- example-for: web -->

Use a separator for pages that have an [empty state](https://polaris.shopify.com/components/structure/empty-state) as their only content, or that have an [annotated section](https://polaris.shopify.com/components/structure/layout) as the first component on the page.

```jsx
<Page title="Settings" separator>
<Layout>
<Layout.AnnotatedSection title="Store details">
<p>Annotated section content</p>
</Layout.AnnotatedSection>
</Layout>
</Page>
```

### Page with content after title (title metadata)

<!-- example-for: web -->
Expand Down
5 changes: 0 additions & 5 deletions src/components/Page/components/Header/Header.scss
Expand Up @@ -12,11 +12,6 @@ $action-menu-rollup-computed-width: rem(40px);
position: relative;
}

.separator {
padding-bottom: spacing();
border-bottom: var(--p-override-none);
}

.titleHidden {
@include visually-hidden;
}
Expand Down
4 changes: 0 additions & 4 deletions src/components/Page/components/Header/Header.tsx
Expand Up @@ -37,8 +37,6 @@ interface PrimaryAction
export interface HeaderProps extends TitleProps {
/** Visually hide the title */
titleHidden?: boolean;
/** Adds a border to the bottom of the page header */
separator?: boolean;
/** Primary page-level action */
primaryAction?: PrimaryAction | React.ReactNode;
/** Page-level pagination */
Expand Down Expand Up @@ -72,7 +70,6 @@ export function Header({
additionalMetaData,
thumbnail,
titleHidden = false,
separator,
primaryAction,
pagination,
additionalNavigation,
Expand Down Expand Up @@ -148,7 +145,6 @@ export function Header({

const headerClassNames = classNames(
styles.Header,
separator && styles.separator,
isSingleRow && styles.isSingleRow,
titleHidden && styles.titleHidden,
navigationMarkup && styles.hasNavigation,
Expand Down

0 comments on commit d6cdb87

Please sign in to comment.