20 行
635 B
TypeScript
20 行
635 B
TypeScript
import PostImportStatusBadge from '@/components/posts/import/PostImportStatusBadge'
|
|
|
|
import type { FC } from 'react'
|
|
|
|
import type { PostImportBadgeValue } from '@/components/posts/import/postImportRowStatus'
|
|
|
|
type Props = {
|
|
label: string
|
|
value: number
|
|
badge?: PostImportBadgeValue }
|
|
|
|
const PostImportSummaryChip: FC<Props> = ({ label, value, badge }) => (
|
|
<div className="flex items-center gap-2 rounded-full border border-border
|
|
bg-background px-3 py-1 text-sm">
|
|
{badge != null && <PostImportStatusBadge value={badge}/>}
|
|
<span>{label} {value}</span>
|
|
</div>)
|
|
|
|
export default PostImportSummaryChip
|