We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 2fcb24f commit 4b1e11eCopy full SHA for 4b1e11e
src/BootstrapTable.js
@@ -1271,12 +1271,17 @@ class BootstrapTable extends Component {
1271
}
1272
1273
} else {
1274
- React.Children.forEach(this.props.children.filter(_ => !!_), (child, i) => {
1275
- if (child.props.width) {
1276
- header[i].style.width = `${child.props.width}px`;
1277
- header[i].style.minWidth = `${child.props.width}px`;
+ for (const i in bodyHeader) {
+ if (bodyHeader.hasOwnProperty(i)) {
+ const child = bodyHeader[i];
+ if (child.style.width) {
1278
+ header[i].style.width = child.style.width;
1279
+ }
1280
+ if (child.style.minWidth) {
1281
+ header[i].style.minWidth = child.style.minWidth;
1282
1283
- });
1284
1285
1286
this.isVerticalScroll = isScroll;
1287
0 commit comments