table and filter reusable component
This commit is contained in:
@@ -0,0 +1,22 @@
|
||||
import { FC, ReactNode } from 'react'
|
||||
|
||||
interface Props {
|
||||
text: string,
|
||||
children?: ReactNode,
|
||||
dir?: string,
|
||||
}
|
||||
|
||||
const Td: FC<Props> = (props: Props) => {
|
||||
return (
|
||||
<td className='td' style={{ direction: props.dir === "ltr" ? "ltr" : "rtl" }}>
|
||||
{
|
||||
props.text ?
|
||||
props.text
|
||||
:
|
||||
props.children
|
||||
}
|
||||
</td>
|
||||
)
|
||||
}
|
||||
|
||||
export default Td
|
||||
Reference in New Issue
Block a user