aboutsummaryrefslogtreecommitdiff
path: root/src/client/views/nodes/DataVizBox/components/PieChart.tsx
diff options
context:
space:
mode:
Diffstat (limited to 'src/client/views/nodes/DataVizBox/components/PieChart.tsx')
-rw-r--r--src/client/views/nodes/DataVizBox/components/PieChart.tsx5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/client/views/nodes/DataVizBox/components/PieChart.tsx b/src/client/views/nodes/DataVizBox/components/PieChart.tsx
index 121e6db3d..3ca49a46c 100644
--- a/src/client/views/nodes/DataVizBox/components/PieChart.tsx
+++ b/src/client/views/nodes/DataVizBox/components/PieChart.tsx
@@ -14,7 +14,6 @@ import { PinProps, PresBox } from "../../trails";
import { Docs } from "../../../../documents/Documents";
import { List } from "../../../../../fields/List";
import './Chart.scss';
-import { ChatCompletionResponseMessageRoleEnum } from "openai";
export interface PieChartProps {
rootDoc: Doc;
@@ -281,11 +280,11 @@ export class PieChart extends React.Component<PieChartProps> {
render() {
return (
- this.props.axes.length >= 1 ? (
+ this.props.axes.length >= 1 && (this.incomingSelected? this.incomingSelected.length>0 : true) ? (
<div ref={this._piechartRef} className="chart-container">
<span> {`Selected: ${Object.keys(this._piechartData[0])[0]}`}</span>
</div>
- ) : <span className="chart-container"> {'first use table view to select an axis to plot'}</span>
+ ) : <span className="chart-container"> {'first use table view to select a column to graph'}</span>
);
}