GeneralSettings.tsx58 lines · main
| 1 | import { |
| 2 | PageSection, |
| 3 | PageSectionContent, |
| 4 | PageSectionMeta, |
| 5 | PageSectionSummary, |
| 6 | PageSectionTitle, |
| 7 | } from 'ui-patterns/PageSection' |
| 8 | |
| 9 | import { DataPrivacyForm } from './DataPrivacyForm' |
| 10 | import { OrganizationDeletePanel } from './OrganizationDeletePanel' |
| 11 | import { OrganizationDetailsForm } from './OrganizationDetailsForm' |
| 12 | import { NoProjectsOnPaidOrgInfo } from '@/components/interfaces/Billing/NoProjectsOnPaidOrgInfo' |
| 13 | import { useIsFeatureEnabled } from '@/hooks/misc/useIsFeatureEnabled' |
| 14 | |
| 15 | export const GeneralSettings = () => { |
| 16 | const organizationDeletionEnabled = useIsFeatureEnabled('organizations:delete') |
| 17 | |
| 18 | return ( |
| 19 | <> |
| 20 | <NoProjectsOnPaidOrgInfo /> |
| 21 | |
| 22 | <PageSection> |
| 23 | <PageSectionMeta> |
| 24 | <PageSectionSummary> |
| 25 | <PageSectionTitle>Organization details</PageSectionTitle> |
| 26 | </PageSectionSummary> |
| 27 | </PageSectionMeta> |
| 28 | <PageSectionContent> |
| 29 | <OrganizationDetailsForm /> |
| 30 | </PageSectionContent> |
| 31 | </PageSection> |
| 32 | |
| 33 | <PageSection> |
| 34 | <PageSectionMeta> |
| 35 | <PageSectionSummary> |
| 36 | <PageSectionTitle>Data privacy</PageSectionTitle> |
| 37 | </PageSectionSummary> |
| 38 | </PageSectionMeta> |
| 39 | <PageSectionContent> |
| 40 | <DataPrivacyForm /> |
| 41 | </PageSectionContent> |
| 42 | </PageSection> |
| 43 | |
| 44 | {organizationDeletionEnabled && ( |
| 45 | <PageSection> |
| 46 | <PageSectionMeta> |
| 47 | <PageSectionSummary> |
| 48 | <PageSectionTitle>Danger zone</PageSectionTitle> |
| 49 | </PageSectionSummary> |
| 50 | </PageSectionMeta> |
| 51 | <PageSectionContent> |
| 52 | <OrganizationDeletePanel /> |
| 53 | </PageSectionContent> |
| 54 | </PageSection> |
| 55 | )} |
| 56 | </> |
| 57 | ) |
| 58 | } |