types: added segment props

This commit is contained in:
원더 2021-01-29 20:24:48 +09:00
parent 1d3fdefa17
commit 2f008e60e7

View File

@ -1,4 +1,4 @@
const Segment = ({ children }): JSX.Element => { const Segment = ({ children }:SegmentProps): JSX.Element => {
return ( return (
<div className='p-5 text-black dark:text-white dark:bg-discord-black bg-little-white rounded-sm'> <div className='p-5 text-black dark:text-white dark:bg-discord-black bg-little-white rounded-sm'>
{children} {children}
@ -6,4 +6,8 @@ const Segment = ({ children }): JSX.Element => {
) )
} }
interface SegmentProps {
children: JSX.Element | JSX.Element[]
}
export default Segment export default Segment