Skip to content

Commit dbc40d3

Browse files
committed
fix #892
1 parent 9183e71 commit dbc40d3

File tree

4 files changed

+9
-4
lines changed

4 files changed

+9
-4
lines changed

src/BootstrapTable.js

+1
Original file line numberDiff line numberDiff line change
@@ -140,6 +140,7 @@ class BootstrapTable extends Component {
140140
hiddenOnInsert: column.props.hiddenOnInsert,
141141
searchable: column.props.searchable,
142142
className: column.props.columnClassName,
143+
editClassName: column.props.editColumnClassName,
143144
columnTitle: column.props.columnTitle,
144145
width: column.props.width,
145146
text: column.props.headerText || column.props.children,

src/TableBody.js

+2-1
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,8 @@ class TableBody extends Component {
6969
rowIndex={ r }
7070
colIndex={ i }
7171
row={ data }
72-
fieldValue={ fieldValue } />
72+
fieldValue={ fieldValue }
73+
className={ column.editClassName } />
7374
);
7475
} else {
7576
// add by bluespring for className customize

src/TableEditColumn.js

+4-3
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ class TableEditColumn extends Component {
100100
}
101101

102102
render() {
103-
const { editable, format, customEditor } = this.props;
103+
const { editable, format, customEditor, className } = this.props;
104104
const { shakeEditor } = this.state;
105105
const attr = {
106106
ref: 'inputRef',
@@ -127,7 +127,7 @@ class TableEditColumn extends Component {
127127
}
128128

129129
return (
130-
<td ref='td' style={ { position: 'relative' } }>
130+
<td ref='td' style={ { position: 'relative' } } className={ className }>
131131
{ cellEditor }
132132
<Notifier ref='notifier'/>
133133
</td>
@@ -156,7 +156,8 @@ TableEditColumn.propTypes = {
156156
PropTypes.number,
157157
PropTypes.array,
158158
PropTypes.object
159-
])
159+
]),
160+
className: PropTypes.any
160161
};
161162

162163

src/TableHeaderColumn.js

+2
Original file line numberDiff line numberDiff line change
@@ -219,6 +219,7 @@ TableHeaderColumn.propTypes = {
219219
sortFunc: PropTypes.func,
220220
sortFuncExtraData: PropTypes.any,
221221
columnClassName: PropTypes.any,
222+
editColumnClassName: PropTypes.any,
222223
columnTitle: PropTypes.bool,
223224
filterFormatted: PropTypes.bool,
224225
filterValue: PropTypes.func,
@@ -261,6 +262,7 @@ TableHeaderColumn.defaultProps = {
261262
width: null,
262263
sortFunc: undefined,
263264
columnClassName: '',
265+
editColumnClassName: '',
264266
filterFormatted: false,
265267
filterValue: undefined,
266268
sort: undefined,

0 commit comments

Comments
 (0)