From dbe64f2fad2e50d34009077573c5d199b0d009ad Mon Sep 17 00:00:00 2001 From: Kelvin Jackson Date: Wed, 27 Nov 2024 14:18:13 +0200 Subject: [PATCH 1/2] =?UTF-8?q?Tulotietojen=20sivun=20ulkon=C3=A4=C3=B6n?= =?UTF-8?q?=20bugikorjaus?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../child-information/fee-alteration/FeeAlterationList.tsx | 7 +++++++ .../components/person-profile/income/IncomeItemHeader.tsx | 7 +++++++ 2 files changed, 14 insertions(+) diff --git a/frontend/src/employee-frontend/components/child-information/fee-alteration/FeeAlterationList.tsx b/frontend/src/employee-frontend/components/child-information/fee-alteration/FeeAlterationList.tsx index 26d8360506f..d651de4f5b1 100755 --- a/frontend/src/employee-frontend/components/child-information/fee-alteration/FeeAlterationList.tsx +++ b/frontend/src/employee-frontend/components/child-information/fee-alteration/FeeAlterationList.tsx @@ -88,6 +88,7 @@ export default React.memo(function FeeAlterationList({ }`} {feeAlteration.notes} + {feeAlteration.modifiedAt && ( )} + {feeAlteration.attachments.length > 0 && ( p.theme.colors.main.m2}; margin-right: ${defaultMargins.s}; ` + +const RightHandSide = styled(FixedSpaceRow)` + min-width: 50%; + justify-content: space-between; +` diff --git a/frontend/src/employee-frontend/components/person-profile/income/IncomeItemHeader.tsx b/frontend/src/employee-frontend/components/person-profile/income/IncomeItemHeader.tsx index f2bd50633c6..bcb731c062e 100755 --- a/frontend/src/employee-frontend/components/person-profile/income/IncomeItemHeader.tsx +++ b/frontend/src/employee-frontend/components/person-profile/income/IncomeItemHeader.tsx @@ -41,6 +41,11 @@ const Row = styled(FixedSpaceRow)` align-items: center; ` +const RightHandSide = styled(Row)` + min-width: 50%; + justify-content: space-between; +` + interface Props { title: string isOpen: boolean @@ -83,6 +88,7 @@ const IncomeItemHeader = React.memo(function IncomeItemHeader({ {period} + {modifiedAt && ( + ) }) From 71ea5be77a086f9cf0ae28755609af07188fde75 Mon Sep 17 00:00:00 2001 From: Kelvin Jackson Date: Wed, 27 Nov 2024 14:25:05 +0200 Subject: [PATCH 2/2] Ap;ease linter --- .../fee-alteration/FeeAlterationList.tsx | 68 +++++++-------- .../income/IncomeItemHeader.tsx | 84 +++++++++---------- 2 files changed, 76 insertions(+), 76 deletions(-) diff --git a/frontend/src/employee-frontend/components/child-information/fee-alteration/FeeAlterationList.tsx b/frontend/src/employee-frontend/components/child-information/fee-alteration/FeeAlterationList.tsx index d651de4f5b1..189b5b7597f 100755 --- a/frontend/src/employee-frontend/components/child-information/fee-alteration/FeeAlterationList.tsx +++ b/frontend/src/employee-frontend/components/child-information/fee-alteration/FeeAlterationList.tsx @@ -89,42 +89,42 @@ export default React.memo(function FeeAlterationList({ {feeAlteration.notes} - {feeAlteration.modifiedAt && ( - - - {i18n.childInformation.feeAlteration.lastModifiedAt( - feeAlteration.modifiedAt.format() - )} - - - )} - - {permittedActions.includes('UPDATE') && ( - { - if (feeAlteration.id !== null) { - toggleEditing(feeAlteration.id) + {feeAlteration.modifiedAt && ( + + - )} - {permittedActions.includes('DELETE') && ( - toggleDeleteModal(feeAlteration)} - aria-label={i18n.common.remove} - /> + > + {i18n.childInformation.feeAlteration.lastModifiedAt( + feeAlteration.modifiedAt.format() + )} + + )} - + + {permittedActions.includes('UPDATE') && ( + { + if (feeAlteration.id !== null) { + toggleEditing(feeAlteration.id) + } + }} + aria-label={i18n.common.edit} + /> + )} + {permittedActions.includes('DELETE') && ( + toggleDeleteModal(feeAlteration)} + aria-label={i18n.common.remove} + /> + )} + {feeAlteration.attachments.length > 0 && ( diff --git a/frontend/src/employee-frontend/components/person-profile/income/IncomeItemHeader.tsx b/frontend/src/employee-frontend/components/person-profile/income/IncomeItemHeader.tsx index bcb731c062e..77783c9a5f2 100755 --- a/frontend/src/employee-frontend/components/person-profile/income/IncomeItemHeader.tsx +++ b/frontend/src/employee-frontend/components/person-profile/income/IncomeItemHeader.tsx @@ -89,50 +89,50 @@ const IncomeItemHeader = React.memo(function IncomeItemHeader({ - {modifiedAt && ( - - - {i18n.personProfile.income.lastModifiedAt(modifiedAt.format())} - - - )} - - {permittedActions.includes('UPDATE') && ( -