Skip to content
This repository has been archived by the owner on Dec 6, 2022. It is now read-only.

Commit

Permalink
add support component
Browse files Browse the repository at this point in the history
  • Loading branch information
SiAdcock committed May 20, 2022
1 parent 0c2fb3e commit 6d1a2c6
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 3 deletions.
19 changes: 16 additions & 3 deletions docs/rfcs/header-component-api.md
Original file line number Diff line number Diff line change
Expand Up @@ -354,8 +354,9 @@ A special header layout for editorial pages. The logo and supporter messages are
#### Example

```jsx
<EditorialHeader isSignedIn showMessage>
<EditorialHeader>
<Masthead>
<EditorialHeader.Support />
<Masthead.Links>
<Masthead.Link href icon={<Icon />} label until from />
<Masthead.Menu icon label until from>
Expand All @@ -377,11 +378,23 @@ A special header layout for editorial pages. The logo and supporter messages are

#### Props

- `isSignedIn` _boolean_
- `edition` _string_ `'uk'` | `'au'` | `'us'` | `'international'`

#### `<EditorialHeader.Support />`

Presents either the Support buttons, or the Thank You message depending on whether the user is a supporter

![Support buttons](images/header-component-api/support-buttons.png)
![Support thank you message](images/header-component-api/support-thank-you.png)

#### Props

- `showSupportButtons` _boolean_
- whether to show the support buttons
- `showSubscriberMessage` _boolean_
- whether to show the Thank You message
- `edition` _string_ `'uk'` | `'au'` | `'us'` | `'international'`
- `readerRevenueLinks` _{ subscribe: string; support: string; contribute: string }_
- urls to assign to the support buttons

#### `<EditorialHeader.EditionSwitch />`

Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 6d1a2c6

Please sign in to comment.