File tree Expand file tree Collapse file tree 8 files changed +69
-59
lines changed
apps/landing/src/components Expand file tree Collapse file tree 8 files changed +69
-59
lines changed Original file line number Diff line number Diff line change @@ -4,14 +4,12 @@ import Markdown from 'react-markdown'
44import { _components } from '@/mdx-components'
55
66import { CustomCodeBlock } from './mdx/components/CustomCodeBlock'
7- import {
8- TableBody ,
9- TableCell ,
10- TableHead ,
11- TableHeaderCell ,
12- TableRoot ,
13- TableRow ,
14- } from './Table'
7+ import { TableBody } from './TableBody'
8+ import { TableCell } from './TableCell'
9+ import { TableHead } from './TableHead'
10+ import { TableHeaderCell } from './TableHeaderCell'
11+ import { TableRoot } from './TableRoot'
12+ import { TableRow } from './TableRow'
1513
1614interface ComponentProp {
1715 property : string
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 1+ import { Box } from '@devup-ui/react'
2+ import { ComponentPropsWithoutRef } from 'react'
3+
4+ export const TableBody = ( { ...props } : ComponentPropsWithoutRef < 'tbody' > ) => {
5+ return < Box { ...props } as = "tbody" />
6+ }
Original file line number Diff line number Diff line change 1+ import { Box } from '@devup-ui/react'
2+ import { ComponentPropsWithoutRef } from 'react'
3+
4+ export const TableCell = ( { ...props } : ComponentPropsWithoutRef < 'th' > ) => {
5+ return < Box { ...props } as = "td" padding = "0.5rem 1rem" />
6+ }
Original file line number Diff line number Diff line change 1+ import { Box } from '@devup-ui/react'
2+ import { ComponentPropsWithoutRef } from 'react'
3+
4+ export const TableHead = ( { ...props } : ComponentPropsWithoutRef < 'thead' > ) => {
5+ return (
6+ < Box
7+ { ...props }
8+ as = "thead"
9+ selectors = { {
10+ '& tr' : {
11+ bg : '$cardBg' ,
12+ } ,
13+ } }
14+ />
15+ )
16+ }
Original file line number Diff line number Diff line change 1+ import { Box } from '@devup-ui/react'
2+ import { ComponentPropsWithoutRef } from 'react'
3+
4+ export const TableHeaderCell = ( {
5+ ...props
6+ } : ComponentPropsWithoutRef < 'th' > ) => {
7+ return < Box { ...props } as = "th" padding = "0.5rem 1rem" textAlign = "left" />
8+ }
Original file line number Diff line number Diff line change 1+ import { Box } from '@devup-ui/react'
2+ import { ComponentPropsWithoutRef } from 'react'
3+
4+ export const TableRoot = ( { ...props } : ComponentPropsWithoutRef < 'table' > ) => {
5+ return (
6+ < Box borderRadius = "0.5rem" overflow = "hidden" >
7+ < Box { ...props } as = "table" borderCollapse = "collapse" borderSpacing = { 0 } />
8+ </ Box >
9+ )
10+ }
Original file line number Diff line number Diff line change 1+ import { Box } from '@devup-ui/react'
2+ import { ComponentPropsWithoutRef } from 'react'
3+
4+ export const TableRow = ( { ...props } : ComponentPropsWithoutRef < 'tr' > ) => {
5+ return (
6+ < Box
7+ { ...props }
8+ as = "tr"
9+ borderBottom = "1px solid var(--border, #E4E4E4)"
10+ selectors = { {
11+ '& + &:last-of-type' : {
12+ borderBottom : 'none' ,
13+ } ,
14+ } }
15+ />
16+ )
17+ }
You can’t perform that action at this time.
0 commit comments