Skip to content

Commit

Permalink
expose responsiveWrapper to customStyles (#988)
Browse files Browse the repository at this point in the history
  • Loading branch information
jbetancur authored Dec 19, 2021
1 parent b792924 commit a881779
Show file tree
Hide file tree
Showing 5 changed files with 14 additions and 6 deletions.
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "react-data-table-component",
"version": "7.4.6",
"version": "7.4.7",
"description": "A simple to use declarative react based data table",
"main": "dist/index.cjs.js",
"module": "dist/index.es.js",
Expand Down Expand Up @@ -81,7 +81,7 @@
"jest-styled-components": "^7.0.8",
"jest-watch-typeahead": "^1.0.0",
"lodash-es": "^4.17.21",
"memoize-one": "^5.2.1",
"memoize-one": "^6.0.0",
"moment": "^2.29.1",
"prettier": "^2.5.1",
"react": "^17.0.2",
Expand Down
2 changes: 2 additions & 0 deletions src/DataTable/ResponsiveWrapper.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,8 @@ const ResponsiveWrapper = styled.div<{
max-height: ${fixedHeaderScrollHeight};
-webkit-overflow-scrolling: touch;
`};
${({ theme }) => theme.responsiveWrapper.style};
`;

export default ResponsiveWrapper;
3 changes: 3 additions & 0 deletions src/DataTable/styles.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@ export const defaultStyles = (theme: Theme): TableStyles => ({
display: 'table',
},
},
responsiveWrapper: {
style: {},
},
header: {
style: {
fontSize: '22px',
Expand Down
3 changes: 3 additions & 0 deletions src/DataTable/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,9 @@ export interface TableStyles {
tableWrapper?: {
style: CSSObject;
};
responsiveWrapper?: {
style: CSSObject;
};
header?: {
style: CSSObject;
};
Expand Down
8 changes: 4 additions & 4 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -8736,10 +8736,10 @@ memfs@^3.1.2:
dependencies:
fs-monkey "1.0.3"

memoize-one@^5.2.1:
version "5.2.1"
resolved "https://registry.yarnpkg.com/memoize-one/-/memoize-one-5.2.1.tgz#8337aa3c4335581839ec01c3d594090cebe8f00e"
integrity sha512-zYiwtZUcYyXKo/np96AGZAckk+FWWsUdJ3cHGGmld7+AhvcWmQyGCYUh1hc4Q/pkOhb65dQR/pqCyK0cOaHz4Q==
memoize-one@^6.0.0:
version "6.0.0"
resolved "https://registry.yarnpkg.com/memoize-one/-/memoize-one-6.0.0.tgz#b2591b871ed82948aee4727dc6abceeeac8c1045"
integrity sha512-rkpe71W0N0c0Xz6QD0eJETuWAJGnJ9afsl1srmwPrI+yBCkge5EycXXbYRyvL29zZVUWQCY7InPRCv3GDXuZNw==

memoizerific@^1.11.3:
version "1.11.3"
Expand Down

0 comments on commit a881779

Please sign in to comment.