mirror of
https://github.com/supabase/supabase.git
synced 2026-10-06 09:55:06 +03:00
Align borders to match header heights. <img width="2904" height="1734" alt="shot_2026-02-04_at_08 42 21z_2x" src="https://github.com/user-attachments/assets/0538f8eb-64a5-4329-94fb-3ea4feed847d" />
36 lines
871 B
TypeScript
36 lines
871 B
TypeScript
import { ReactNode } from 'react'
|
|
import { cn } from 'ui'
|
|
|
|
import { DocsButton } from '../DocsButton'
|
|
|
|
export const FormHeader = ({
|
|
title,
|
|
description,
|
|
docsUrl,
|
|
actions,
|
|
className,
|
|
}: {
|
|
title: string
|
|
description?: string
|
|
docsUrl?: string
|
|
actions?: ReactNode
|
|
className?: string
|
|
}) => {
|
|
return (
|
|
<div
|
|
className={cn(
|
|
`w-full mb-6 flex flex-col sm:flex-row md:items-center justify-between gap-4 md:h-[var(--header-height)] ${className}`
|
|
)}
|
|
>
|
|
<div className="space-y-1">
|
|
<h3 className="text-foreground text-xl prose">{title}</h3>
|
|
{description && <p className="prose text-sm max-w-2xl">{description}</p>}
|
|
</div>
|
|
<div className="flex flex-col sm:flex-row md:items-center gap-x-2">
|
|
{docsUrl !== undefined && <DocsButton href={docsUrl} />}
|
|
{actions}
|
|
</div>
|
|
</div>
|
|
)
|
|
}
|