From d9ac13fd73568c4ed4ec939a5d63dda455bc4e5f Mon Sep 17 00:00:00 2001 From: ljungster Date: Thu, 28 Apr 2022 12:35:34 -0400 Subject: pushing prior to sprint --- .../views/collections/CollectionNoteTakingView.tsx | 18 ++++-------------- .../collections/CollectionNoteTakingViewDivider.tsx | 10 +++++----- 2 files changed, 9 insertions(+), 19 deletions(-) (limited to 'src') 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 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 - //
this.onDividerPointerOver(e, i)} key={i} - // style={{ - // height: "95%", - // width: 12, - // borderRight: "4px solid #282828", - // borderLeft: "4px solid #282828", - // margin: "0px 10px" - // }} - // /> - //
) diff --git a/src/client/views/collections/CollectionNoteTakingViewDivider.tsx b/src/client/views/collections/CollectionNoteTakingViewDivider.tsx index 3655c3f38..731ac556e 100644 --- a/src/client/views/collections/CollectionNoteTakingViewDivider.tsx +++ b/src/client/views/collections/CollectionNoteTakingViewDivider.tsx @@ -40,11 +40,11 @@ export default class Divider extends React.Component{ // const xDividerPos = this.props.columnStartXCoords[this.props.index + 1] - 25 // const diff = xDividerPos - xPos // // make a copy of the array - const colXCoords : number[] = [] - this.props.columnStartXCoords.forEach(val => colXCoords.push(val)) - colXCoords[this.props.index + 1] += movementX - this.props.setColumnStartXCoords(colXCoords) - // console.log(this.props.columnStartXCoords) + // const colXCoords = [...this.props.columnStartXCoords] + // colXCoords[this.props.index + 1] += movementX + this.props.columnStartXCoords[this.props.index + 1] += movementX + // this.props.setColumnStartXCoords(colXCoords) + console.log(this.props.columnStartXCoords) // this.props.columnStartXCoords = colXCoords // } } -- cgit v1.2.3-70-g09d2