diff --git a/examples/custom-components/index.js b/examples/custom-components/index.js index d527163..1ada390 100644 --- a/examples/custom-components/index.js +++ b/examples/custom-components/index.js @@ -9,21 +9,20 @@ import TableViewCol from './TableViewCol'; const CustomChip = (props) => { const { label, onDelete, columnNames, className, index } = props; return (); }; const CustomTooltip = (props) => { return ( - {props.children} ); }; @@ -72,31 +71,31 @@ class Example extends React.Component { return false; }, display: (filterList, onChange, index, column) => ( - + ) }, }, }, { name: 'City', label: 'City Label', options: { filterList: ['Dallas'] } }, { name: 'State' }, - { - name: 'Empty', - options: { - empty: true, - filterType: 'checkbox', + { + name: 'Empty', + options: { + empty: true, + filterType: 'checkbox', filterOptions: { renderValue: (val) => (val ? val : '(Empty)') } - } + } }, ]; const data = [ @@ -116,16 +115,16 @@ class Example extends React.Component { return ( ); diff --git a/examples/customize-footer/CustomFooter.js b/examples/customize-footer/CustomFooter.js index e3e77a8..76b739a 100644 --- a/examples/customize-footer/CustomFooter.js +++ b/examples/customize-footer/CustomFooter.js @@ -37,15 +37,19 @@ class CustomFooter extends React.Component { page={page} labelRowsPerPage={textLabels.rowsPerPage} labelDisplayedRows={({ from, to, count }) => `${from}-${to} ${textLabels.displayRows} ${count}`} - backIconButtonProps={{ - 'aria-label': textLabels.previous, - }} - nextIconButtonProps={{ - 'aria-label': textLabels.next, + slotProps={{ + actions: { + previousButton: { + 'aria-label': textLabels.previous, + }, + nextButton: { + 'aria-label': textLabels.next, + } + } }} rowsPerPageOptions={[10,20,100]} - onChangePage={this.handlePageChange} - onChangeRowsPerPage={this.handleRowChange} + onPageChange={this.handlePageChange} + onRowsPerPageChange={this.handleRowChange} /> diff --git a/examples/customize-styling/index.js b/examples/customize-styling/index.js index 80fad3e..b6c0e7b 100644 --- a/examples/customize-styling/index.js +++ b/examples/customize-styling/index.js @@ -192,7 +192,7 @@ class Example extends React.Component { }, setTableProps: () => { return { - padding: this.state.denseTable ? 'none' : 'default', + padding: this.state.denseTable ? 'none' : 'normal', // material ui v4 only size: this.state.denseTable ? 'small' : 'medium', diff --git a/src/components/Popover.js b/src/components/Popover.js index a947544..1dd2918 100644 --- a/src/components/Popover.js +++ b/src/components/Popover.js @@ -45,7 +45,6 @@ const Popover = ({ className, trigger, refExit, hide, content, ...providedProps }; const triggerProps = { - key: 'content', onClick: (event) => { if (trigger.props.onClick) trigger.props.onClick(); handleClick(event); @@ -54,7 +53,9 @@ const Popover = ({ className, trigger, refExit, hide, content, ...providedProps return ( <> - {trigger} + + {trigger} +