sozsoft-platform/ui/src/components/shared/PageModeBadge.tsx

19 lines
678 B
TypeScript
Raw Normal View History

2026-10-20 10:53:21 +00:00
import { useConfig } from '@/components/ui/ConfigProvider'
// Sayfa başlığındaki görünüm/mod rozeti. Badge'in .badge sınıfı katmansız CSS'te sabit kırmızıdır
// (bildirim sayacı) ve utility sınıfları ezemez; renkler tema renginden gelir, sınıflar
// tailwind/index.css'teki @source inline listesinde üretilir.
const PageModeBadge = ({ content }: { content: string }) => {
const { themeColor } = useConfig()
return (
<span
className={`rounded-full px-2 py-0.5 text-xs bg-${themeColor}-100 text-${themeColor}-700 dark:bg-${themeColor}-500/20 dark:text-${themeColor}-300`}
>
{content}
</span>
)
}
export default PageModeBadge