ricokahler / hacker-ui

A design system for the modern developer. (development on hiatus)
https://hacker-ui.com/
MIT License
241 stars 10 forks source link

Add table components #68

Closed pearlzhuzeng closed 4 years ago

pearlzhuzeng commented 4 years ago

What does this PR do?

This PR adds eight table components (listed below), four table examples, and a docs page with the examples.

Screenshots

Outlined table with caption outlined_table_with_caption

Contained table with a different row hover color contained_table_with_different_hover_color

Scrollable striped table with fixed first column scrollable_striped_table_with_fixed_first_column

Ghost table ghost table

Closes #26

pearlzhuzeng commented 4 years ago

Hey @ricokahler, thank you for the suggestions! I didn't know that we can define a component by just doing const TableBody = 'tbody', very nice and simple (and consistent).

I made updates according to your suggestions, except for the createData function, which I think is a pretty straightforward function.

github-actions[bot] commented 4 years ago

Size Change: +1.74 kB (7%) 🔍

Total Size: 24.1 kB

Filename Size Change
dist/bundle.esm.js 10.4 kB +750 B (7%) 🔍
dist/bundle.umd.js 13.7 kB +993 B (7%) 🔍

compressed-size-action