diff --git a/.eslintrc b/.eslintrc
index c29b8e9..ca70c65 100644
--- a/.eslintrc
+++ b/.eslintrc
@@ -11,7 +11,7 @@
],
"rules": {
"comma-dangle": ["error", "never"],
- "react/jsx-curly-spacing": 0,
+ "react/jsx-curly-spacing": [2, "always"],
"react/forbid-prop-types": 0,
"react/jsx-filename-extension": 0,
"react/jsx-space-before-closing": 0,
diff --git a/packages/react-bootstrap-table2-example/examples/basic/caption-table.js b/packages/react-bootstrap-table2-example/examples/basic/caption-table.js
index 2315f90..7f84142 100644
--- a/packages/react-bootstrap-table2-example/examples/basic/caption-table.js
+++ b/packages/react-bootstrap-table2-example/examples/basic/caption-table.js
@@ -36,12 +36,12 @@ const CaptionElement = () =>
} columns={ columns } />
`;
-const Caption = () => Component as Header
;
+const Caption = () => Component as Header
;
export default () => (
- } columns={ columns } />
+ } columns={ columns } />
{ sourceCode }
);
diff --git a/packages/react-bootstrap-table2-example/examples/cell-edit/cell-edit-with-redux-table.js b/packages/react-bootstrap-table2-example/examples/cell-edit/cell-edit-with-redux-table.js
index ebd0e3c..760c6d9 100644
--- a/packages/react-bootstrap-table2-example/examples/cell-edit/cell-edit-with-redux-table.js
+++ b/packages/react-bootstrap-table2-example/examples/cell-edit/cell-edit-with-redux-table.js
@@ -203,7 +203,7 @@ const reducers = (state, action) => {
const store = createStore(reducers, initialState, applyMiddleware(thunk));
const Index = () => (
-
+
);
diff --git a/packages/react-bootstrap-table2-example/examples/welcome.js b/packages/react-bootstrap-table2-example/examples/welcome.js
index 7438298..41f3547 100644
--- a/packages/react-bootstrap-table2-example/examples/welcome.js
+++ b/packages/react-bootstrap-table2-example/examples/welcome.js
@@ -24,13 +24,13 @@ export default class Welcome extends React.Component {
react-bootstrap-table2
{ this.el = el; }}
+ ref={ (el) => { this.el = el; } }
/>
-
diff --git a/packages/react-bootstrap-table2/src/bootstrap-table.js b/packages/react-bootstrap-table2/src/bootstrap-table.js
index 834362c..f466618 100644
--- a/packages/react-bootstrap-table2/src/bootstrap-table.js
+++ b/packages/react-bootstrap-table2/src/bootstrap-table.js
@@ -81,8 +81,8 @@ class BootstrapTable extends PropsBaseResolver(Component) {
visibleColumnSize={ this.visibleColumnSize() }
noDataIndication={ noDataIndication }
cellEdit={ cellEditInfo }
- selectRow={cellSelectionInfo}
- selectedRowKeys={store.getSelectedRowKeys()}
+ selectRow={ cellSelectionInfo }
+ selectedRowKeys={ store.getSelectedRowKeys() }
/>
diff --git a/packages/react-bootstrap-table2/src/header.js b/packages/react-bootstrap-table2/src/header.js
index 8953c63..4730c34 100644
--- a/packages/react-bootstrap-table2/src/header.js
+++ b/packages/react-bootstrap-table2/src/header.js
@@ -21,7 +21,7 @@ const Header = (props) => {
{
- selectRow.mode === ROW_SELECT_DISABLED ? null :
+ selectRow.mode === ROW_SELECT_DISABLED ? null :
}
{
columns.map((column, i) => {
diff --git a/packages/react-bootstrap-table2/src/row-selection/selection-cell.js b/packages/react-bootstrap-table2/src/row-selection/selection-cell.js
index 73b3e4a..604188b 100644
--- a/packages/react-bootstrap-table2/src/row-selection/selection-cell.js
+++ b/packages/react-bootstrap-table2/src/row-selection/selection-cell.js
@@ -48,10 +48,10 @@ export default class SelectionCell extends Component {
} = this.props;
return (
- |
+ |
|
);
diff --git a/packages/react-bootstrap-table2/src/row-selection/selection-header-cell.js b/packages/react-bootstrap-table2/src/row-selection/selection-header-cell.js
index b23e52c..a2c6956 100644
--- a/packages/react-bootstrap-table2/src/row-selection/selection-header-cell.js
+++ b/packages/react-bootstrap-table2/src/row-selection/selection-header-cell.js
@@ -6,10 +6,10 @@ import Const from '../const';
export const CheckBox = ({ checked, indeterminate }) => (
{
+ checked={ checked }
+ ref={ (input) => {
if (input) input.indeterminate = indeterminate; // eslint-disable-line no-param-reassign
- }}
+ } }
/>
);
@@ -64,11 +64,11 @@ export default class SelectionHeaderCell extends Component {
return mode === ROW_SELECT_SINGLE
? |
: (
-
+ |
|
);
diff --git a/packages/react-bootstrap-table2/src/row.js b/packages/react-bootstrap-table2/src/row.js
index fe894fc..b0b99a9 100644
--- a/packages/react-bootstrap-table2/src/row.js
+++ b/packages/react-bootstrap-table2/src/row.js
@@ -38,8 +38,8 @@ const Row = (props) => {
: (
)
}
diff --git a/packages/react-bootstrap-table2/test/body.test.js b/packages/react-bootstrap-table2/test/body.test.js
index d4dc9b4..c89c35d 100644
--- a/packages/react-bootstrap-table2/test/body.test.js
+++ b/packages/react-bootstrap-table2/test/body.test.js
@@ -28,7 +28,7 @@ describe('Body', () => {
describe('simplest body', () => {
beforeEach(() => {
- wrapper = shallow(
);
+ wrapper = shallow();
});
it('should render successfully', () => {
@@ -42,7 +42,7 @@ describe('Body', () => {
beforeEach(() => {
wrapper = shallow(
{
emptyIndication = 'Table is empty';
wrapper = shallow(
{
emptyIndicationCallBack = sinon.stub().returns(content);
wrapper = shallow(
{
beforeEach(() => {
wrapper = shallow(
{
it('props selected should be true if all rows were selected', () => {
wrapper = shallow(
);
@@ -171,12 +171,12 @@ describe('Body', () => {
it('props selected should be false if all rows were not selected', () => {
wrapper = shallow(
);
@@ -189,11 +189,11 @@ describe('Body', () => {
const keyField = 'id';
wrapper = shallow(