19 lines
745 B
JavaScript
19 lines
745 B
JavaScript
import React from 'react'
|
|
|
|
const statusConfig = {
|
|
published: { label: 'Published', className: 'bg-emerald-500/20 text-emerald-400 border-emerald-500/30' },
|
|
draft: { label: 'Draft', className: 'bg-amber-500/20 text-amber-400 border-amber-500/30' },
|
|
archived: { label: 'Archived', className: 'bg-slate-500/20 text-slate-400 border-slate-500/30' },
|
|
scheduled: { label: 'Scheduled', className: 'bg-blue-500/20 text-blue-400 border-blue-500/30' },
|
|
}
|
|
|
|
export default function StatusBadge({ status }) {
|
|
const config = statusConfig[status] || statusConfig.draft
|
|
|
|
return (
|
|
<span className={`inline-flex items-center px-2 py-0.5 rounded-md text-xs font-medium border ${config.className}`}>
|
|
{config.label}
|
|
</span>
|
|
)
|
|
}
|