From e1607900c4666fd0f0e898f7a268c7ac6abd911f Mon Sep 17 00:00:00 2001 From: Caio Alexandre Troti Caetano Date: Fri, 17 Jan 2025 14:03:01 -0300 Subject: [PATCH] :boom: fix: Fixed organization metadata padding --- locales/extracted/pt.json | 2 +- .../organizations/organizations-form.tsx | 91 +++++++------------ 2 files changed, 34 insertions(+), 59 deletions(-) diff --git a/locales/extracted/pt.json b/locales/extracted/pt.json index 16adacf1..4c297d6b 100644 --- a/locales/extracted/pt.json +++ b/locales/extracted/pt.json @@ -331,4 +331,4 @@ "settings.tabs.system": "Sistema", "notAuthorized.backToHome": "Voltar para Home", "notAuthorized.title": "Você não tem autorização para acessar esta página." -} +} \ No newline at end of file diff --git a/src/app/(routes)/settings/organizations/organizations-form.tsx b/src/app/(routes)/settings/organizations/organizations-form.tsx index a6f3b621..fe5c6018 100644 --- a/src/app/(routes)/settings/organizations/organizations-form.tsx +++ b/src/app/(routes)/settings/organizations/organizations-form.tsx @@ -10,12 +10,6 @@ import { useForm } from 'react-hook-form' import { z } from 'zod' import { zodResolver } from '@hookform/resolvers/zod' import { Button } from '@/components/ui/button' -import { - Collapsible, - CollapsibleContent, - CollapsibleTrigger -} from '@/components/ui/collapsible' -import { ChevronDown, ChevronUp } from 'lucide-react' import { useRouter } from 'next/navigation' import { useIntl } from 'react-intl' import { MetadataField } from '@/components/form/metadata-field' @@ -30,6 +24,11 @@ import { import { LoadingButton } from '@/components/ui/loading-button' import { omit } from 'lodash' import { OrganizationsFormParentIdField } from './organizations-form-parent-id-field' +import { + PaperCollapsible, + PaperCollapsibleBanner, + PaperCollapsibleContent +} from '@/components/transactions/primitives/paper-collapsible' type OrganizationsViewProps = { data?: OrganizationsType @@ -313,58 +312,34 @@ export const OrganizationsForm = ({ - - - -
-
- - -

- {intl.formatMessage( - { - id: 'organizations.organizationForm.metadataRegisterCountText', - defaultMessage: - '{count} added {count, plural, =0 {records} one {record} other {records}}' - }, - { - count: Object.entries(metadataValue || 0).length - } - )} -

-
- - - - -
-
- - - - - - - - - - -
-
+ + +

+ {intl.formatMessage({ + id: 'common.metadata', + defaultMessage: 'Metadata' + })} +

+

+ {intl.formatMessage( + { + id: 'organizations.organizationForm.metadataRegisterCountText', + defaultMessage: + '{count} added {count, plural, =0 {records} one {record} other {records}}' + }, + { + count: Object.entries(metadataValue || 0).length + } + )} +

+
+ + +
+ +
+
+