import { Meta, Story, ArgsTable, Canvas } from '@storybook/addon-docs/blocks';
import { Text } from './text.component';
import { FlowPropsTable, ExternalReferenceLink } from '../../../utils';

<Meta title="2 - System/Typography/Text" component={Text} />

# Text

This component provides block typography wrapped in a P tag.

Our brand font is FuturaPT.

## Variations

### Scale

The font scale contains 5 options:

| Size | Pixel Value |
| ---- | ----------- |
| f1   | 16px        |
| f2   | 18px        |
| f3   | 20px        |
| f4   | 27px        |
| f5   | 34px        |

The default value is **f2**

<Canvas withToolbar>
  <Story id="2-system-typography-text--scale" />
</Canvas>

### Color

Change the text colour by providing a theme color to the `colorName` prop

<Canvas withToolbar>
  <Story id="2-system-typography-text--color" />
</Canvas>

### Formatting

<Canvas withToolbar>
  <Story id="2-system-typography-text--formatting" />
</Canvas>

### Numerical

<Canvas withToolbar>
  <Story id="2-system-typography-text--numerical" />
</Canvas>

### Tabular

<Canvas withToolbar>
  <Story id="2-system-typography-text--tabular" />
</Canvas>

## Supported Layout Props

### Spacing

<Preview withToolbar>
  <Story id="2-system-typography-text--mixins-spacing" />
</Preview>

### Stackee

<Preview withToolbar>
  <Story id="2-system-typography-text--mixins-stackee" />
</Preview>

## Props

<FlowPropsTable ofComponent={Text} />

## External Reference

<ExternalReferenceLink src="" type="figma" />
<ExternalReferenceLink
  src="https://github.com/wealthsimple/patchwork/tree/master/core/typography/text"
  type="github"
/>
