Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

material-table

Package Overview
Dependencies
Maintainers
1
Versions
194
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

material-table - npm Package Compare versions

Comparing version 0.8.1 to 0.8.2

3

dist/m-table-actions.js

@@ -50,2 +50,3 @@ 'use strict';

{
key: action.icon,
disabled: action.disabled,

@@ -66,3 +67,3 @@ onClick: function onClick(event) {

_core.Tooltip,
{ title: action.tooltip },
{ title: action.tooltip, key: action.tooltip },
button

@@ -69,0 +70,0 @@ );

@@ -54,9 +54,9 @@ 'use strict';

_core.TableRow,
{ selected: index % 2 === 0 },
{ selected: index % 2 === 0, key: index },
this.props.options.selection ? React.createElement(
_core.TableCell,
{ padding: 'checkbox' },
{ padding: 'checkbox', key: 'key-selection-column' },
React.createElement(_core.Checkbox, {
checked: data.tableData.checked === true,
value: data.tableData.id,
value: '' + data.tableData.id,
onChange: this.props.onRowSelected

@@ -68,3 +68,3 @@ })

_core.TableCell,
{ style: { paddingTop: 0, paddingBottom: 0 } },
{ style: { paddingTop: 0, paddingBottom: 0 }, key: 'key-actions-column' },
React.createElement(

@@ -82,3 +82,3 @@ 'div',

var value = _this2.props.getFieldValue(data, columnDef);
return React.createElement(_mTableCell2.default, { columnDef: columnDef, value: value });
return React.createElement(_mTableCell2.default, { columnDef: columnDef, value: value, key: columnDef.tableData.id });
})

@@ -115,4 +115,4 @@ );

}),
[].concat(_toConsumableArray(Array(emptyRowCount))).map(function () {
return React.createElement(_core.TableRow, { style: { height: 49 } });
[].concat(_toConsumableArray(Array(emptyRowCount))).map(function (r, index) {
return React.createElement(_core.TableRow, { style: { height: 49 }, key: 'empty-' + index });
}),

@@ -119,0 +119,0 @@ emptyRowCount > 0 && React.createElement('div', { style: { height: 1 } })

@@ -89,3 +89,3 @@ 'use strict';

style: columnDef.type === 'numeric' ? { float: 'right' } : {},
type: columnDef.type === 'numeric' && 'number',
type: columnDef.type === 'numeric' ? 'number' : 'text',
value: columnDef.tableData.filterValue,

@@ -122,3 +122,3 @@ onChange: function onChange(event) {

_core.TableCell,
null,
{ key: columnDef.tableData.id },
_this3.getComponentForColumn(columnDef)

@@ -125,0 +125,0 @@ );

@@ -48,3 +48,3 @@ 'use strict';

_core.TableCell,
{ padding: 'checkbox' },
{ padding: 'checkbox', key: 'key-selection-column' },
React.createElement(_core.Checkbox, {

@@ -59,3 +59,3 @@ indeterminate: this.props.selectedCount > 0 && this.props.selectedCount < this.props.dataCount,

_core.TableCell,
null,
{ key: 'key-actions-column' },
React.createElement(

@@ -73,4 +73,5 @@ _core.TableSortLabel,

{
key: columnDef.tableData.id,
numeric: ['numeric'].indexOf(columnDef.type) !== -1,
className: arr.length - 1 === index && _this2.props.classes.lastColumn },
className: arr.length - 1 === index ? _this2.props.classes.lastColumn : '' },
columnDef.sort !== false ? React.createElement(

@@ -80,3 +81,3 @@ _core.TableSortLabel,

active: _this2.props.orderBy === index,
direction: _this2.props.orderDirection,
direction: _this2.props.orderDirection || 'asc',
onClick: function onClick() {

@@ -83,0 +84,0 @@ var orderDirection = index !== _this2.props.orderBy ? 'asc' : _this2.props.orderDirection === 'asc' ? 'desc' : 'asc';

@@ -114,3 +114,3 @@ 'use strict';

_core.MenuItem,
null,
{ key: col.tableData.id },
React.createElement(_core.FormControlLabel, {

@@ -117,0 +117,0 @@ label: col.title,

@@ -216,30 +216,34 @@ 'use strict';

return React.createElement(
_core.TableFooter,
{ style: { display: 'grid' } },
_core.Table,
null,
React.createElement(
_core.TableRow,
null,
React.createElement(_core.TablePagination, {
style: { float: 'right' },
colSpan: 3,
count: this.state.renderData.length,
rowsPerPage: this.state.pageSize,
rowsPerPageOptions: props.options.pageSizeOptions,
page: this.state.currentPage,
onChangePage: function onChangePage(event, page) {
_this3.setState({ currentPage: page }, function () {
_this3.setData();
});
},
onChangeRowsPerPage: function onChangeRowsPerPage(event) {
_this3.setState(function (state) {
state.pageSize = event.target.value;
state.currentPage = 0;
return state;
}, function () {
_this3.setData();
});
},
ActionsComponent: _mTablePagination2.default
})
_core.TableFooter,
{ style: { display: 'grid' } },
React.createElement(
_core.TableRow,
null,
React.createElement(_core.TablePagination, {
style: { float: 'right' },
colSpan: 3,
count: this.state.renderData.length,
rowsPerPage: this.state.pageSize,
rowsPerPageOptions: props.options.pageSizeOptions,
page: this.state.currentPage,
onChangePage: function onChangePage(event, page) {
_this3.setState({ currentPage: page }, function () {
_this3.setData();
});
},
onChangeRowsPerPage: function onChangeRowsPerPage(event) {
_this3.setState(function (state) {
state.pageSize = event.target.value;
state.currentPage = 0;
return state;
}, function () {
_this3.setData();
});
},
ActionsComponent: _mTablePagination2.default
})
)
)

@@ -246,0 +250,0 @@ );

{
"name": "material-table",
"version": "0.8.1",
"version": "0.8.2",
"description": "Datatable for React based on https://material-ui.com/api/table/ with additional features",

@@ -5,0 +5,0 @@ "main": "index.js",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc