forked from nodejs/nodejs.org
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added Table Styling Based on Figma Design for Node.js Website (nodejs…
…#6034) * Added table styling based on Figma design for both light and dark modes * added border radius to the table * indented styles, changed to text-sm, added th & td properties to common selectors * added HeadlessTable to table story * simplified nested tr, td
- Loading branch information
1 parent
2002ff8
commit 6ac88d7
Showing
2 changed files
with
96 additions
and
0 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 |
---|---|---|
@@ -0,0 +1,58 @@ | ||
import type { Meta as MetaObj, StoryObj } from '@storybook/react'; | ||
|
||
export const Table: StoryObj = { | ||
render: () => ( | ||
<table> | ||
<thead> | ||
<tr> | ||
<th>Column 1</th> | ||
<th>Column 2</th> | ||
<th>Column 3</th> | ||
</tr> | ||
</thead> | ||
<tbody> | ||
<tr> | ||
<td>Data 1</td> | ||
<td>Data 2</td> | ||
<td>Data 3</td> | ||
</tr> | ||
<tr> | ||
<td>Data 1</td> | ||
<td>Data 2</td> | ||
<td>Data 3</td> | ||
</tr> | ||
<tr> | ||
<td>Data 1</td> | ||
<td>Data 2</td> | ||
<td>Data 3</td> | ||
</tr> | ||
</tbody> | ||
</table> | ||
), | ||
}; | ||
|
||
export const HeadlessTable: StoryObj = { | ||
render: () => ( | ||
<table> | ||
<tbody> | ||
<tr> | ||
<td>Data 1</td> | ||
<td>Data 2</td> | ||
<td>Data 3</td> | ||
</tr> | ||
<tr> | ||
<td>Data 1</td> | ||
<td>Data 2</td> | ||
<td>Data 3</td> | ||
</tr> | ||
<tr> | ||
<td>Data 1</td> | ||
<td>Data 2</td> | ||
<td>Data 3</td> | ||
</tr> | ||
</tbody> | ||
</table> | ||
), | ||
}; | ||
|
||
export default { title: 'Design System' } as MetaObj; |
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