Files
Joshen Lim 85194a05d8 Joshenlim/fe 5190 move off scaffold components in (#53849)
## Context

Housekeeping to deprecate more deprecated UI components, this one's
focusing on the `Scaffold` components.
The main visual differences are just the width within PageSections since
the new components where the right content takes up a bit more width
than the left content. (Ref org billing + usage)

Starting the refactor with the organization pages:
- Billing
- Team
- Usage
- Settings -> SSO
- Settings -> Security
- Settings -> Audit Logs
- Settings -> Documents
2026-11-24 10:39:33 +07:00

42 lines
1.3 KiB
TypeScript

import { ExternalLinkIcon } from 'lucide-react'
import { Button } from 'ui'
import { PageContainer } from 'ui-patterns/PageContainer'
import {
PageSection,
PageSectionContent,
PageSectionDescription,
PageSectionMeta,
PageSectionSummary,
PageSectionTitle,
} from 'ui-patterns/PageSection'
import { CustomContentTypes } from '@/hooks/custom-content/CustomContent.types'
interface CustomDocumentProps {
doc: CustomContentTypes['organizationLegalDocuments'][number]
}
export const CustomDocument = ({ doc }: CustomDocumentProps) => {
return (
<PageContainer id={doc.id}>
<PageSection orientation="horizontal">
<PageSectionMeta>
<PageSectionSummary>
<PageSectionTitle>{doc.name}</PageSectionTitle>
<PageSectionDescription>{doc.description}</PageSectionDescription>
</PageSectionSummary>
</PageSectionMeta>
<PageSectionContent>
<div className="@lg:flex items-center justify-center h-full">
<Button asChild iconRight={<ExternalLinkIcon />}>
<a download href={doc.action.url} target="_blank" rel="noreferrer noopener">
{doc.action.text}
</a>
</Button>
</div>
</PageSectionContent>
</PageSection>
</PageContainer>
)
}