Skip to content

Commit

Permalink
fix lint issues
Browse files Browse the repository at this point in the history
Signed-off-by: hriday-panchasara <hriday.panchasara@ericsson.com>
  • Loading branch information
hriday-panchasara committed Jul 8, 2022
1 parent b45c044 commit d67ffff
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -915,8 +915,18 @@ export class TimegraphOutputComponent extends AbstractTreeOutputComponent<Timegr
protected showOptions(): React.ReactNode {
return <React.Fragment>
<ul>
{this.props.pinned === undefined && <li className='drop-down-list-item' onClick={() => this.pinView({ output: this.props.outputDescriptor, collapsedNodes: this.state.collapsedNodes, collapsedMarkerNodes: this.state.collapsedMarkerNodes } as ChartPersistedState)}>Pin View</li>}
{this.props.pinned === true && <li className='drop-down-list-item' onClick={() => this.unPinView({ output: this.props.outputDescriptor, collapsedNodes: this.state.collapsedNodes, collapsedMarkerNodes: this.state.collapsedMarkerNodes } as ChartPersistedState)}>Unpin View</li>}
{this.props.pinned === undefined &&
<li className='drop-down-list-item'
onClick={() => this.pinView({ output: this.props.outputDescriptor, collapsedNodes: this.state.collapsedNodes,
collapsedMarkerNodes: this.state.collapsedMarkerNodes } as ChartPersistedState)}>
Pin View
</li>}
{this.props.pinned === true &&
<li className='drop-down-list-item'
onClick={() => this.unPinView({ output: this.props.outputDescriptor, collapsedNodes: this.state.collapsedNodes,
collapsedMarkerNodes: this.state.collapsedMarkerNodes } as ChartPersistedState)}>
Unpin View
</li>}
</ul>
{this.state.additionalOptions && this.showAdditionalOptions()}
</React.Fragment>;
Expand Down
16 changes: 11 additions & 5 deletions packages/react-components/src/components/xy-output-component.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ export class XYOutputComponent extends AbstractTreeOutputComponent<AbstractOutpu
private margin = { top: 15, right: 0, bottom: 5, left: this.getYAxisWidth() };
private isScatterPlot: boolean = this.props.outputDescriptor.id.includes('scatter');
private isBarPlot = false;

private plugin = {
afterDraw: (chartInstance: Chart, _easing: Chart.Easing, _options?: any) => { this.afterChartDraw(chartInstance.ctx, chartInstance.chartArea); }
};
Expand Down Expand Up @@ -1087,13 +1087,19 @@ export class XYOutputComponent extends AbstractTreeOutputComponent<AbstractOutpu
protected showOptions(): React.ReactNode {
return <React.Fragment>
<ul>
{this.props.pinned === undefined &&
<li className='drop-down-list-item'
onClick={() => this.pinView({ output: this.props.outputDescriptor, checkedSeries: this.state.checkedSeries, collapsedNodes: this.state.collapsedNodes } as ChartPersistedState)}
{this.props.pinned === undefined &&
<li className='drop-down-list-item'
onClick={() => this.pinView({ output: this.props.outputDescriptor, checkedSeries: this.state.checkedSeries,
collapsedNodes: this.state.collapsedNodes } as ChartPersistedState)}
>
Pin View
</li>}
{this.props.pinned === true && <li className='drop-down-list-item' onClick={() => this.unPinView({ output: this.props.outputDescriptor, checkedSeries: this.state.checkedSeries, collapsedNodes: this.state.collapsedNodes } as ChartPersistedState)}>Unpin View</li>}
{this.props.pinned === true &&
<li className='drop-down-list-item'
onClick={() => this.unPinView({ output: this.props.outputDescriptor, checkedSeries: this.state.checkedSeries,
collapsedNodes: this.state.collapsedNodes } as ChartPersistedState)}>
Unpin View
</li>}
</ul>
{this.state.additionalOptions && this.showAdditionalOptions()}
</React.Fragment>;
Expand Down

0 comments on commit d67ffff

Please sign in to comment.