import { BarChart2 } from 'lucide-react' import Link from 'next/link' import { Button, Card, CardContent } from 'ui' import { PageSection, PageSectionContent, PageSectionDescription, PageSectionMeta, PageSectionSummary, PageSectionTitle, } from 'ui-patterns/PageSection' import PauseProjectButton from './Infrastructure/PauseProjectButton' import RestartServerButton from './Infrastructure/RestartServerButton' import { useIsFeatureEnabled } from '@/hooks/misc/useIsFeatureEnabled' import { useSelectedOrganizationQuery } from '@/hooks/misc/useSelectedOrganization' import { useSelectedProjectQuery } from '@/hooks/misc/useSelectedProject' export const Project = () => { const { data: project } = useSelectedProjectQuery() const { data: organization } = useSelectedOrganizationQuery() const isBranch = Boolean(project?.parent_project_ref) const { projectSettingsRestartProject } = useIsFeatureEnabled([ 'project_settings:restart_project', ]) return ( <> Project availability Restart or pause your project when performing maintenance

{projectSettingsRestartProject ? 'Restart project' : 'Restart database'}

Your project will not be available for a few minutes.

Pause project

Your project will not be accessible while it is paused.

{!isBranch && ( Project usage

Project usage statistics have been moved

You may view your project's usage under your organization's settings

{!!organization && !!project && ( )}
)} ) }