Files
supabase/apps/www/components/CodeTabs/CodeTabs.components.tsx
T
Steve Chavez cb66b6b635 feat: blog post postgrest 13 (#38840)
* add CodeTabs component to www
* add  to www mdx components
2025-09-30 14:37:07 -05:00

22 lines
517 B
TypeScript

import type { PropsWithChildren } from 'react'
import { cn } from 'ui'
export function NamedCodeBlock({ name, children }: PropsWithChildren<{ name: string }>) {
return (
<div className="shiki-wrapper w-full space-y-2">
<h6
className={cn(
'w-fit flex items-center text-center',
'shadow-sm rounded border border-stronger bg-selection',
'px-2.5 py-1',
'text-xs text-foreground'
)}
>
{name}
</h6>
{children}
</div>
)
}