Skip to content

Commit

Permalink
fix(legend): avoid expanding label on click (#209)
Browse files Browse the repository at this point in the history
  • Loading branch information
markov00 authored May 20, 2019
1 parent e38e8f6 commit 22cad8e
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions .playground/playgroud.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ export class Playground extends React.Component {
render() {
return (
<Chart>
<Settings showLegend={true} legendPosition={Position.Bottom} rotation={0} />
<Settings showLegend={true} legendPosition={Position.Right} rotation={0} />
<Axis
id={getAxisId('timestamp')}
title="timestamp"
Expand All @@ -39,15 +39,15 @@ export class Playground extends React.Component {
yAccessors={[1]}
/>
<LineSeries
id={getSpecId('dataset B')}
id={getSpecId('bar series 1')}
xScaleType={ScaleType.Time}
yScaleType={ScaleType.Linear}
data={KIBANA_METRICS.metrics.kibana_os_load[1].data.slice(0, 15)}
xAccessor={0}
yAccessors={[1]}
/>
<LineSeries
id={getSpecId('dataset C')}
id={getSpecId('bar series 2')}
xScaleType={ScaleType.Time}
yScaleType={ScaleType.Linear}
data={KIBANA_METRICS.metrics.kibana_os_load[2].data.slice(0, 15)}
Expand Down
2 changes: 1 addition & 1 deletion src/components/legend_element.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ class LegendElementComponent extends React.Component<LegendElementProps, LegendE
<EuiFlexItem grow={false}>
{this.renderVisibilityButton(legendItemKey, isSeriesVisible)}
</EuiFlexItem>
<EuiFlexItem onClick={onTitleClick} grow={false}>
<EuiFlexItem onClick={onTitleClick} grow={true}>
<EuiPopover
id="contentPanel"
button={
Expand Down

0 comments on commit 22cad8e

Please sign in to comment.