import { Disclosure } from '@headlessui/react'
import { ChevronDownIcon } from '@heroicons/react/outline'
import { ReactNode } from 'hoist-non-react-statics/node_modules/@types/react'
export const Table = ({ children }) => (
)
export const TrHead = ({ children }) => (
{children}
)
export const Th = ({ children }) => (
{children}
|
)
export const TrBody = ({ children, index }) => (
{children}
)
export const Td = ({
children,
className,
}: {
children: ReactNode
className?: string
}) => (
{children}
|
)
type ExpandableRowProps = {
buttonTemplate: React.ReactNode
index: number
panelTemplate: React.ReactNode
rounded?: boolean
}
export const ExpandableRow = ({
buttonTemplate,
index,
panelTemplate,
rounded,
}: ExpandableRowProps) => {
return (
{({ open }) => (
<>
{buttonTemplate}
{panelTemplate}
>
)}
)
}
type RowProps = {
children: React.ReactNode
index: number
}
export const Row = ({ children, index }: RowProps) => {
return (
{children}
)
}