Skip to content

Commit

Permalink
merged develop and updated the font weight table
Browse files Browse the repository at this point in the history
  • Loading branch information
samithaf committed Oct 31, 2023
1 parent 784ceec commit 714999f
Showing 1 changed file with 36 additions and 0 deletions.
36 changes: 36 additions & 0 deletions packages/ui/src/stories/foundation/typography.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -149,3 +149,39 @@ export const LineHeight = () => {
</div>
);
};

/**
* Fonts weight
*/
export const FontWeight = () => {
const fontWeight = [
{ className: 'font-light', weight: '300' },
{ className: 'font-normal', weight: '400' },
{ className: 'font-medium', weight: '500' },
{ className: 'font-semibold', weight: '600' },
{ className: 'font-bold', weight: '700' },
];
return (
<Table>
<Table.Caption>Font Weight</Table.Caption>
<Table.Header>
<Table.HeaderRow>
<Table.HeaderCell>Token</Table.HeaderCell>
<Table.HeaderCell>Font weight</Table.HeaderCell>
<Table.HeaderCell>Tailwind class</Table.HeaderCell>
</Table.HeaderRow>
</Table.Header>
<Table.Body>
{fontWeight.map(i => (
<Table.Row key={i.className}>
<Table.Cell>
<span className={i.className}>{i.className.replace('font-', '')}</span>
</Table.Cell>
<Table.Cell className={i.className}>{i.weight}</Table.Cell>
<Table.Cell>{i.className}</Table.Cell>
</Table.Row>
))}
</Table.Body>
</Table>
);
};

0 comments on commit 714999f

Please sign in to comment.