33 lines
803 B
JavaScript
33 lines
803 B
JavaScript
import Component from '../component';
|
|
import './TableCellOverflow.css';
|
|
|
|
class TableCellOverflow extends Component {
|
|
constructor (parentNode, text) {
|
|
super(null, parentNode);
|
|
|
|
const cell = this.createElement({
|
|
tagName: 'td',
|
|
parentNode: this.mainNode,
|
|
});
|
|
|
|
const div = this.createElement({
|
|
tagName: 'div',
|
|
parentNode: cell,
|
|
options: {
|
|
className: 'TableCellOverflow__cellWrapper'
|
|
}
|
|
});
|
|
const span = this.createElement({
|
|
tagName: 'span',
|
|
parentNode: div,
|
|
options: {
|
|
className: 'TableCellOverflow__cell',
|
|
},
|
|
});
|
|
|
|
span.innerHTML = text || '-';
|
|
}
|
|
}
|
|
|
|
export default TableCellOverflow;
|