From c53f7298af20d60c2a9634a9c6753419fd6e74df Mon Sep 17 00:00:00 2001 From: Paul Robert Lloyd Date: Tue, 26 Apr 2022 16:52:35 +0100 Subject: [PATCH 1/2] Refactor document list component to have better semantics --- app/components/document_list_component.html.erb | 16 ++++++++-------- app/frontend/styles/_document-list.scss | 7 ------- 2 files changed, 8 insertions(+), 15 deletions(-) diff --git a/app/components/document_list_component.html.erb b/app/components/document_list_component.html.erb index 6242ab3dc..c5b7affc5 100644 --- a/app/components/document_list_component.html.erb +++ b/app/components/document_list_component.html.erb @@ -1,15 +1,15 @@ - + diff --git a/app/frontend/styles/_document-list.scss b/app/frontend/styles/_document-list.scss index c510e52b2..d3f632b27 100644 --- a/app/frontend/styles/_document-list.scss +++ b/app/frontend/styles/_document-list.scss @@ -1,15 +1,8 @@ -.app-document-list { - list-style: none; - padding: 0; -} - .app-document-list__item { margin-bottom: govuk-spacing(4); &:last-child { - border-bottom: 0; margin-bottom: 0; - padding-bottom: 0; } } From cb000b305be5b0fa2d6fb329178f82d609de8735 Mon Sep 17 00:00:00 2001 From: Paul Robert Lloyd Date: Tue, 26 Apr 2022 16:52:50 +0100 Subject: [PATCH 2/2] Ensure last item in card does not have a bottom margin --- app/frontend/styles/_card.scss | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/app/frontend/styles/_card.scss b/app/frontend/styles/_card.scss index d0a9e9ecf..076f2a2c1 100644 --- a/app/frontend/styles/_card.scss +++ b/app/frontend/styles/_card.scss @@ -4,4 +4,8 @@ background-color: govuk-colour("light-grey"); display: block; position: relative; + + > *:last-child { + margin-bottom: 0; + } }