diff options
author | srichman333 <sarah_n_richman@brown.edu> | 2023-10-16 15:40:09 -0400 |
---|---|---|
committer | srichman333 <sarah_n_richman@brown.edu> | 2023-10-16 15:40:09 -0400 |
commit | 8acaa16a276600d8c5a201f49099e551aeb55416 (patch) | |
tree | 3d2a8b47034e6d10b525719dbfaeb0c092156a3f /src/client/views/nodes/DataVizBox/components/LineChart.tsx | |
parent | 20ddaa48fae25dbb8c09107955b91630e9a311f9 (diff) |
from last
Diffstat (limited to 'src/client/views/nodes/DataVizBox/components/LineChart.tsx')
-rw-r--r-- | src/client/views/nodes/DataVizBox/components/LineChart.tsx | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/src/client/views/nodes/DataVizBox/components/LineChart.tsx b/src/client/views/nodes/DataVizBox/components/LineChart.tsx index 11bdcc3d6..007d0259c 100644 --- a/src/client/views/nodes/DataVizBox/components/LineChart.tsx +++ b/src/client/views/nodes/DataVizBox/components/LineChart.tsx @@ -1,4 +1,4 @@ -import { EditableText, Size } from 'browndash-components'; +import { Button, EditableText, Size } from 'browndash-components'; import * as d3 from 'd3'; import { action, computed, IReactionDisposer, observable, reaction } from 'mobx'; import { observer } from 'mobx-react'; @@ -23,6 +23,7 @@ export interface SelectedDataPoint extends DataPoint { elem?: d3.Selection<d3.BaseType, unknown, SVGGElement, unknown>; } export interface LineChartProps { + vizBox: DataVizBox; rootDoc: Doc; layoutDoc: Doc; axes: string[]; @@ -366,7 +367,16 @@ export class LineChart extends React.Component<LineChartProps> { /> </div> <div ref={this._lineChartRef} /> - {selectedPt != 'none' ? <div className={'selected-data'}> {`Selected: ${selectedPt}`}</div> : null} + {selectedPt != 'none' ? + <div className={'selected-data'}> + {`Selected: ${selectedPt}`} + <Button onClick={e=>{ + console.log("test plzz") + this.props.vizBox.sidebarBtnDown; + this.props.vizBox.sidebarAddDocument;} + }></Button> + </div> + : null} </div> ) : ( <span className="chart-container"> {'first use table view to select two numerical axes to plot'}</span> |