-
Notifications
You must be signed in to change notification settings - Fork 52
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
docs(typography): Edits and cleanup to Text, Paragraph, Strong, Small…
…, and Text.Sup docs
- Loading branch information
1 parent
c450d22
commit 4830b2b
Showing
12 changed files
with
55 additions
and
59 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -23,7 +23,7 @@ exports[`<Notification /> renders 1`] = ` | |
medium | ||
mediumFont | ||
leftAlign | ||
" | ||
" | ||
> | ||
Some content | ||
</p> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,23 @@ | ||
### Usage | ||
|
||
``` | ||
<div> | ||
<Paragraph>Our commitment to service is demonstrated in everything we do.</Paragraph> | ||
<Paragraph>Enjoy your choice of <Link href="#">5 channels</Link>, and up to <Link href="#">23 local and regional channels</Link>. Plus, add Premium channel packs like HBO, TMN & Crave TV for just $20/mo. All delivered via TELUS Internet through the Pik TV media box and Pik TV app.<Text.Sup>2</Text.Sup> | ||
<Paragraph> | ||
Our commitment to service is demonstrated in everything we do. | ||
</Paragraph> | ||
<Paragraph> | ||
Enjoy your choice of <Link href="#">5 channels</Link>, and up to <Link href="#">23 local and regional channels</Link>. Plus, add Premium channel packs like HBO, TMN & Crave TV for just $20/mo. All delivered via TELUS Internet through the Pik TV media box and Pik TV app.<Text.Sup>2</Text.Sup> | ||
</Paragraph> | ||
</div> | ||
``` | ||
|
||
### Placing text on dark colours | ||
|
||
Use the `invert` prop. | ||
|
||
``` | ||
const PurpleBlock = require('../../__docs__/PurpleBlock').default; | ||
<PurpleBlock> | ||
<Paragraph invert>Order online and save an extra $150.</Paragraph> | ||
</PurpleBlock> | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -8,7 +8,7 @@ exports[`Paragraph renders 1`] = ` | |
medium | ||
mediumFont | ||
leftAlign | ||
" | ||
" | ||
> | ||
Some content | ||
</p> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
### Usage | ||
|
||
``` | ||
<Small>Taxes and pay-per-use charges (including long distance, roaming and additional airtime or data) are extra.</Small> | ||
<Small> | ||
Taxes and pay-per-use charges (including long distance, roaming and additional airtime or data) are extra. | ||
</Small> | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
### Usage | ||
|
||
``` | ||
<Strong>This text is bold</Strong> | ||
<Text> | ||
<Strong>Your password is not valid.</Strong> It must not be one of your previously used passwords. | ||
</Text> | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,17 @@ | ||
### Usage | ||
|
||
The Text component can be used within other typography components such as [Paragraph](#paragraph). It is useful for modifying text appearance such as **bold**, or changing text size. | ||
|
||
``` | ||
<Text size="small" bold>Tell us what you think</Text> | ||
<Text>Tell us what you think</Text> | ||
``` | ||
|
||
### Inherits props from Paragraph | ||
By default, the Text component will inherit font properties from its parent. Use the props to override this behaviour. | ||
|
||
``` | ||
<Paragraph size="small"><Text>Tell us what you think</Text> It's in our nature to listen.</Paragraph> | ||
``` | ||
|
||
### Invert on dark colours | ||
|
||
``` | ||
const PurpleBlock = require('../../__docs__/PurpleBlock').default; | ||
<PurpleBlock> | ||
<Text invert>Personal</Text> | ||
</PurpleBlock> | ||
<Paragraph> | ||
<Text bold> | ||
Get Optik TV<Text.Sup>®</Text.Sup> and Internet for $85 per month for 12 months. | ||
</Text> | ||
<br /> | ||
<Text size="small"> | ||
Sign up for 2 years and save BIG on your first 12 months. | ||
</Text> | ||
</Paragraph> | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,20 +1,7 @@ | ||
### Usage | ||
|
||
The Text Sup component wraps text in a `<sup>` tag. It assures proper font sizes are rendered depending on the parent font size. | ||
|
||
**Note: do not use Text Sup within a Heading component. Use [Heading.Sup](#headingsup) instead.** | ||
Only use `Text.Sup` as a child of `Paragraph` or `Text`. Use [`Heading.Sup`](#headingsup) for superscript within headings. | ||
|
||
``` | ||
<div> | ||
<div> | ||
<Text size="large">Enjoy your choice of <Link href="#">5 channels</Link>, and up to <Link href="#">23 local and regional channels</Link>. Plus, add Premium channel packs like HBO, TMN & Crave TV for just $20/mo. All delivered via TELUS Internet through the Pik TV media box and Pik TV app.<Text.Sup>2</Text.Sup> | ||
</Text> | ||
</div> | ||
<div> | ||
<Text size="medium">Enjoy buffer-free streaming any time of day<Text.Sup>2</Text.Sup></Text> | ||
</div> | ||
<div> | ||
<Text size="small">Starting at $75 per month on a 2-year plan<Text.Sup>15</Text.Sup></Text> | ||
</div> | ||
</div> | ||
<Text> | ||
Enjoy buffer-free streaming any time of day<Text.Sup>2</Text.Sup>. | ||
</Text> | ||
``` |