Skip to content

Commit

Permalink
feat(community-pagination): design changes
Browse files Browse the repository at this point in the history
BREAKING CHANGE: Default visual designs have changed
  • Loading branch information
nicmak authored and agorovyi committed Oct 10, 2019
1 parent c648bc3 commit 4d0d662
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 10 deletions.
4 changes: 1 addition & 3 deletions packages/Pagination/Pagination.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -254,11 +254,9 @@ Pagination.propTypes = {
/**
* The default copy to be used.
*/
copy: PropTypes.oneOf(['en', 'fr']),
copy: PropTypes.oneOf(['en', 'fr']).isRequired,
}

Pagination.defaultProps = { copy: 'en' }

Pagination.Panel = Panel

export default Pagination
Original file line number Diff line number Diff line change
Expand Up @@ -33,14 +33,13 @@ exports[`Pagination renders 1`] = `
color: #4b286d;
font-size: 1rem;
line-height: 42px;
visibility: hidden;
display: none;
}
.c12 {
color: #4b286d;
font-size: 1rem;
line-height: 42px;
visibility: visible;
}
.c3 {
Expand Down Expand Up @@ -257,9 +256,7 @@ exports[`Pagination renders 1`] = `
}
}
<Pagination
copy="en"
>
<Pagination>
<styles__PaginationContainer>
<StyledComponent
forwardedComponent={
Expand Down
4 changes: 2 additions & 2 deletions packages/Pagination/styles.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,11 @@ const BasePaginationContainer = styled.p({
})

export const PrevPaginationContainer = styled(BasePaginationContainer)(props => ({
visibility: props.showPrevious ? 'visible' : 'hidden',
display: !props.showPrevious && 'none',
}))

export const NextPaginationContainer = styled(BasePaginationContainer)(props => ({
visibility: props.showNext ? 'visible' : 'hidden',
display: !props.showNext && 'none',
}))

export const PaginationButtonStyle = styled.button({
Expand Down

0 comments on commit 4d0d662

Please sign in to comment.