diff options
Diffstat (limited to 'src/client/views/collections/CollectionNoteTakingView.tsx')
-rw-r--r-- | src/client/views/collections/CollectionNoteTakingView.tsx | 18 |
1 files changed, 4 insertions, 14 deletions
diff --git a/src/client/views/collections/CollectionNoteTakingView.tsx b/src/client/views/collections/CollectionNoteTakingView.tsx index 4bb16b01e..79e3c5f4b 100644 --- a/src/client/views/collections/CollectionNoteTakingView.tsx +++ b/src/client/views/collections/CollectionNoteTakingView.tsx @@ -303,12 +303,13 @@ export class CollectionNoteTakingView extends CollectionSubView<Partial<collecti const heading = d[this.pivotField] as object const castedSectionValue = heading.toString() const existingHeader = this.columnHeaders.find(sh => sh.heading === (castedSectionValue)); + const colStartXCoords = this.columnStartXCoords if (existingHeader) { const index = this.columnHeaders.indexOf(existingHeader) if (this.columnHeaders.length == 1) { - return this.props.PanelWidth() - this.columnStartXCoords[index] - 4 * this.gridGap - 100 + return this.props.PanelWidth() - colStartXCoords[index] - 4 * this.gridGap - 100 } - return this.columnStartXCoords[index + 1] - this.columnStartXCoords[index] - 2 * this.gridGap - 100 + return colStartXCoords[index + 1] - colStartXCoords[index] - 2 * this.gridGap - 100 } return 1000; } @@ -668,21 +669,10 @@ export class CollectionNoteTakingView extends CollectionSubView<Partial<collecti //TODO make this look pretty if (i < sections.length - 1) { eles.push( - // <div style={{display: "flex", alignItems: "center", cursor: "col-resize"}}> - // <div className="columnDivider" onPointerOver={e => this.onDividerPointerOver(e, i)} key={i} - // style={{ - // height: "95%", - // width: 12, - // borderRight: "4px solid #282828", - // borderLeft: "4px solid #282828", - // margin: "0px 10px" - // }} - // /> - // </div> <CollectionNoteTakingViewDivider index={i} columnStartXCoords={this.columnStartXCoords} - setColumnStartXCoords={this.setColumnStartXCoords} + setColumnStartXCoords={this.setColumnStartXCoords.bind(this)} xMargin={this.xMargin} /> ) |