@@ -734,6 +734,7 @@ return /******/ (function(modules) { // webpackBootstrap
734
734
if (this.store.filterObj) this.handleFilterData(this.store.filterObj);
735
735
newState.currPage = _util2.default.getFirstPage(nextProps.options.pageStartIndex);
736
736
} else {
737
+ data = this.store.sort().get();
737
738
newState.data = data;
738
739
}
739
740
this.setState(function () {
@@ -8207,14 +8208,16 @@ return /******/ (function(modules) { // webpackBootstrap
8207
8208
}, {
8208
8209
key: '__handleCellEdit__REACT_HOT_LOADER__',
8209
8210
value: function __handleCellEdit__REACT_HOT_LOADER__(e) {
8210
- if (this.props.cellEdit.mode === _Const2.default.CELL_EDIT_DBCLICK) {
8211
- if (document.selection && document.selection.empty) {
8212
- document.selection.empty();
8213
- } else if (window.getSelection) {
8214
- var sel = window.getSelection();
8215
- sel.removeAllRanges();
8211
+ try {
8212
+ if (this.props.cellEdit.mode === _Const2.default.CELL_EDIT_DBCLICK) {
8213
+ if (document.selection && document.selection.empty) {
8214
+ document.selection.empty();
8215
+ } else if (window.getSelection) {
8216
+ var sel = window.getSelection();
8217
+ sel.removeAllRanges();
8218
+ }
8216
8219
}
8217
- }
8220
+ } catch (err) {} /* eslint no-empty: 0 */
8218
8221
this.props.onEdit(this.props.rIndex + 1, e.currentTarget.cellIndex, e);
8219
8222
if (this.props.cellEdit.mode !== _Const2.default.CELL_EDIT_DBCLICK) {
8220
8223
this.props.onClick(this.props.rIndex + 1, e.currentTarget.cellIndex, e);
@@ -9149,13 +9152,22 @@ return /******/ (function(modules) { // webpackBootstrap
9149
9152
return _this.__toggleDropDown__REACT_HOT_LOADER__.apply(_this, arguments);
9150
9153
};
9151
9154
9155
+ _this.closeDropDown = function () {
9156
+ return _this.__closeDropDown__REACT_HOT_LOADER__.apply(_this, arguments);
9157
+ };
9158
+
9152
9159
_this.state = {
9153
9160
open: _this.props.open
9154
9161
};
9155
9162
return _this;
9156
9163
}
9157
9164
9158
9165
_createClass(PaginationList, [{
9166
+ key: '__closeDropDown__REACT_HOT_LOADER__',
9167
+ value: function __closeDropDown__REACT_HOT_LOADER__() {
9168
+ return this.__closeDropDown__REACT_HOT_LOADER__.apply(this, arguments);
9169
+ }
9170
+ }, {
9159
9171
key: '__toggleDropDown__REACT_HOT_LOADER__',
9160
9172
value: function __toggleDropDown__REACT_HOT_LOADER__() {
9161
9173
return this.__toggleDropDown__REACT_HOT_LOADER__.apply(this, arguments);
@@ -9176,9 +9188,7 @@ return /******/ (function(modules) { // webpackBootstrap
9176
9188
var keepSizePerPageState = this.props.keepSizePerPageState;
9177
9189
9178
9190
if (!keepSizePerPageState) {
9179
- this.setState(function () {
9180
- return { open: false };
9181
- });
9191
+ this.closeDropDown();
9182
9192
}
9183
9193
}
9184
9194
}, {
@@ -9208,9 +9218,7 @@ return /******/ (function(modules) { // webpackBootstrap
9208
9218
}
9209
9219
9210
9220
if (keepSizePerPageState) {
9211
- this.setState(function () {
9212
- return { open: false };
9213
- });
9221
+ this.closeDropDown();
9214
9222
}
9215
9223
9216
9224
if (page !== currPage) {
@@ -9233,9 +9241,7 @@ return /******/ (function(modules) { // webpackBootstrap
9233
9241
}
9234
9242
}
9235
9243
9236
- this.setState(function () {
9237
- return { open: false };
9238
- });
9244
+ this.closeDropDown();
9239
9245
}
9240
9246
}, {
9241
9247
key: '__toggleDropDown__REACT_HOT_LOADER__',
@@ -9248,6 +9254,15 @@ return /******/ (function(modules) { // webpackBootstrap
9248
9254
};
9249
9255
});
9250
9256
}
9257
+ }, {
9258
+ key: '__closeDropDown__REACT_HOT_LOADER__',
9259
+ value: function __closeDropDown__REACT_HOT_LOADER__() {
9260
+ this.setState(function () {
9261
+ return {
9262
+ open: false
9263
+ };
9264
+ });
9265
+ }
9251
9266
}, {
9252
9267
key: 'render',
9253
9268
value: function render() {
@@ -9340,7 +9355,8 @@ return /******/ (function(modules) { // webpackBootstrap
9340
9355
currSizePerPage: String(sizePerPage),
9341
9356
sizePerPageList: sizePerPageList,
9342
9357
toggleDropDown: this.toggleDropDown,
9343
- changeSizePerPage: this.changeSizePerPage
9358
+ changeSizePerPage: this.changeSizePerPage,
9359
+ onBlur: this.closeDropDown
9344
9360
});
9345
9361
if (dropdown.type.name === _SizePerPageDropDown2.default.name) {
9346
9362
dropdownProps = dropdown.props;
@@ -9362,7 +9378,7 @@ return /******/ (function(modules) { // webpackBootstrap
9362
9378
{ role: 'menuitem',
9363
9379
tabIndex: '-1', href: '#',
9364
9380
'data-page': pageNum,
9365
- onClick : function onClick (e) {
9381
+ onMouseDown : function onMouseDown (e) {
9366
9382
e.preventDefault();
9367
9383
_this3.changeSizePerPage(pageNum);
9368
9384
} },
@@ -9375,7 +9391,8 @@ return /******/ (function(modules) { // webpackBootstrap
9375
9391
hidden: hideSizePerPage,
9376
9392
currSizePerPage: String(sizePerPageText),
9377
9393
options: sizePerPageOptions,
9378
- onClick: this.toggleDropDown
9394
+ onClick: this.toggleDropDown,
9395
+ onBlur: this.closeDropDown
9379
9396
}, dropdownProps));
9380
9397
}
9381
9398
return dropdown;
@@ -9681,6 +9698,7 @@ return /******/ (function(modules) { // webpackBootstrap
9681
9698
open = _props.open,
9682
9699
hidden = _props.hidden,
9683
9700
onClick = _props.onClick,
9701
+ onBlur = _props.onBlur,
9684
9702
options = _props.options,
9685
9703
className = _props.className,
9686
9704
variation = _props.variation,
@@ -9700,7 +9718,8 @@ return /******/ (function(modules) { // webpackBootstrap
9700
9718
{ className: 'btn ' + btnContextual + ' dropdown-toggle',
9701
9719
id: 'pageDropDown', 'data-toggle': 'dropdown',
9702
9720
'aria-expanded': open,
9703
- onClick: onClick },
9721
+ onClick: onClick,
9722
+ onBlur: onBlur },
9704
9723
currSizePerPage,
9705
9724
_react2.default.createElement(
9706
9725
'span',
@@ -9729,7 +9748,8 @@ return /******/ (function(modules) { // webpackBootstrap
9729
9748
options: _propTypes2.default.array,
9730
9749
variation: _propTypes2.default.oneOf(['dropdown', 'dropup']),
9731
9750
className: _propTypes2.default.string,
9732
- onClick: _propTypes2.default.func
9751
+ onClick: _propTypes2.default.func,
9752
+ onBlur: _propTypes2.default.func
9733
9753
};
9734
9754
SizePerPageDropDown.defaultProps = {
9735
9755
open: false,
0 commit comments