From dde408682758e1f199445091c5abe984c8316b7f Mon Sep 17 00:00:00 2001 From: Matthias Kretschmann Date: Mon, 15 Apr 2019 22:46:49 +0200 Subject: [PATCH] cleanup --- client/src/components/atoms/CategoryImage.tsx | 2 +- .../molecules/Pagination.module.scss | 19 ++++++++----------- .../components/molecules/Pagination.test.tsx | 3 ++- 3 files changed, 11 insertions(+), 13 deletions(-) diff --git a/client/src/components/atoms/CategoryImage.tsx b/client/src/components/atoms/CategoryImage.tsx index fbe4e13..a02df06 100644 --- a/client/src/components/atoms/CategoryImage.tsx +++ b/client/src/components/atoms/CategoryImage.tsx @@ -127,7 +127,7 @@ const categoryImageFile = (category: string) => { case 'Transportation': case 'transport': return transport - case 'Urban Plannin': + case 'Urban Planning': case 'urbanplanning': return urbanplanning case 'Visual Arts & Design': diff --git a/client/src/components/molecules/Pagination.module.scss b/client/src/components/molecules/Pagination.module.scss index 90ccd5b..e3fc0ea 100644 --- a/client/src/components/molecules/Pagination.module.scss +++ b/client/src/components/molecules/Pagination.module.scss @@ -3,9 +3,9 @@ .pagination { display: flex; flex-wrap: wrap; + justify-content: center; margin-top: $spacer * 2; margin-bottom: $spacer; - justify-content: center; padding-left: 0; li { @@ -42,8 +42,14 @@ } } -.current { +.current, +.prev, +.next, +.break { composes: number; +} + +.current { cursor: default; pointer-events: none; @@ -56,19 +62,10 @@ } } -.prev { - composes: number; -} - .next { - composes: number; text-align: right; } .prevNextDisabled { opacity: 0; } - -.break { - composes: number; -} diff --git a/client/src/components/molecules/Pagination.test.tsx b/client/src/components/molecules/Pagination.test.tsx index 0271ec5..c93ec93 100644 --- a/client/src/components/molecules/Pagination.test.tsx +++ b/client/src/components/molecules/Pagination.test.tsx @@ -4,7 +4,7 @@ import Pagination from './Pagination' describe('Button', () => { it('renders without crashing', () => { - const { container, getByRole } = render( + const { container } = render( { /> ) expect(container.firstChild).toBeInTheDocument() + container.firstChild && expect(container.firstChild.nodeName).toBe('UL') }) })