mirror of
https://github.com/mountain-loop/yaak.git
synced 2026-01-17 06:26:58 +01:00
22 lines
419 B
TypeScript
22 lines
419 B
TypeScript
import classNames from 'classnames';
|
|
|
|
interface Props {
|
|
count: number;
|
|
className?: string;
|
|
}
|
|
|
|
export function CountBadge({ count, className }: Props) {
|
|
if (count === 0) return null;
|
|
return (
|
|
<div
|
|
aria-hidden
|
|
className={classNames(
|
|
className,
|
|
'opacity-70 border border-border-subtle text-4xs rounded mb-0.5 px-1 ml-1 h-4 font-mono',
|
|
)}
|
|
>
|
|
{count}
|
|
</div>
|
|
);
|
|
}
|