Skip to content

Commit

Permalink
fix: adjust form container styles
Browse files Browse the repository at this point in the history
  • Loading branch information
cooper-joe committed Dec 16, 2024
1 parent 6eab28e commit 6d60814
Show file tree
Hide file tree
Showing 8 changed files with 11 additions and 5 deletions.
1 change: 1 addition & 0 deletions src/components/form/DefaultFormContents.module.css
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
.form {
background: var(--colors-white);
border: 1px solid var(--colors-grey300);
padding: var(--spacers-dp16);
padding-bottom: var(--spacers-dp32);
}
Expand Down
9 changes: 4 additions & 5 deletions src/components/form/DefaultFormContents.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import i18n from '@dhis2/d2-i18n'
import { Card } from '@dhis2/ui'
import React from 'react'
import { useFormState } from 'react-final-form'
import { getSectionPath, useNavigateWithSearchState } from '../../lib'
Expand All @@ -24,13 +23,13 @@ export function DefaultEditFormContents({

return (
<>
<Card className={classes.form}>
<div className={classes.form}>
{children}

<StandardFormSection>
<DefaultFormErrorNotice />
</StandardFormSection>
</Card>
</div>
<div className={classes.formActions}>
<StandardFormActions
cancelLabel={i18n.t('Cancel')}
Expand Down Expand Up @@ -59,7 +58,7 @@ export function DefaultNewFormContents({
const listPath = `/${getSectionPath(section)}`

return (
<Card className={classes.form}>
<div className={classes.form}>
{children}
<StandardFormSection>
<DefaultFormErrorNotice />
Expand All @@ -72,6 +71,6 @@ export function DefaultNewFormContents({
submitting={submitting}
onCancelClick={() => navigate(listPath)}
/>
</Card>
</div>
)
}
1 change: 1 addition & 0 deletions src/pages/dataElementGroupSets/Edit.module.css
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
.form {
background: var(--colors-white);
border: 1px solid var(--colors-grey300);
padding: var(--spacers-dp16);
padding-bottom: var(--spacers-dp32);
}
Expand Down
1 change: 1 addition & 0 deletions src/pages/dataElementGroupSets/New.module.css
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
.form {
background: var(--colors-white);
border: 1px solid var(--colors-grey300);
padding: var(--spacers-dp16);
padding-bottom: var(--spacers-dp32);
}
1 change: 1 addition & 0 deletions src/pages/dataElementGroups/Edit.module.css
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
.form {
background: var(--colors-white);
border: 1px solid var(--colors-grey300);
padding: var(--spacers-dp16);
padding-bottom: var(--spacers-dp32);
}
Expand Down
1 change: 1 addition & 0 deletions src/pages/dataElementGroups/New.module.css
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
.form {
background: var(--colors-white);
border: 1px solid var(--colors-grey300);
padding: var(--spacers-dp16);
padding-bottom: var(--spacers-dp32);
}
1 change: 1 addition & 0 deletions src/pages/dataElements/Edit.module.css
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
.form {
background: var(--colors-white);
border: 1px solid var(--colors-grey300);
padding: var(--spacers-dp16);
padding-bottom: var(--spacers-dp32);
}
Expand Down
1 change: 1 addition & 0 deletions src/pages/dataElements/New.module.css
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
.form {
background: var(--colors-white);
border: 1px solid var(--colors-grey300);
padding: var(--spacers-dp16);
padding-bottom: var(--spacers-dp32);
}

0 comments on commit 6d60814

Please sign in to comment.