Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Edge bars display over axes #354

Closed
2 tasks done
nickofthyme opened this issue Aug 27, 2019 · 1 comment · Fixed by #355
Closed
2 tasks done

Edge bars display over axes #354

nickofthyme opened this issue Aug 27, 2019 · 1 comment · Fixed by #355
Assignees
Labels
bug Something isn't working :chart Chart element related issue released Issue released publicly

Comments

@nickofthyme
Copy link
Collaborator

Describe the bug
Edge bars cover the axes when outside of the domain.

To Reproduce
Steps to reproduce the behavior:

  1. Replace playground.tsx with 👇
import React from 'react';
import { Axis, Chart, getAxisId, getSpecId, Position, ScaleType, Settings, HistogramBarSeries } from '../src';
import { KIBANA_METRICS } from '../src/utils/data_samples/test_dataset_kibana';

export class Playground extends React.Component {
  render() {
    return (
      <div className="chart">
        <Chart>
          <Settings
            showLegend={true}
            xDomain={{
              min: KIBANA_METRICS.metrics.kibana_os_load[0].data[0][0] + 10000,
              max: KIBANA_METRICS.metrics.kibana_os_load[0].data[18][0] + 10000,
            }}
            rotation={0}
          />
          <Axis id={getAxisId('y')} position={Position.Left} />
          <Axis id={getAxisId('x')} position={Position.Bottom} />
          <HistogramBarSeries
            id={getSpecId('bar')}
            yScaleType={ScaleType.Linear}
            xScaleType={ScaleType.Time}
            xAccessor={0}
            yAccessors={[1]}
            data={KIBANA_METRICS.metrics.kibana_os_load[0].data.slice(0, 15)}
          />
        </Chart>
      </div>
    );
  }
}

Expected behavior
Bars add bands should be clipped from the edge or no shown.

Screenshots
Screen Recording 2019-08-27 at 08 26 AM

Kibana Cross Issues
Add any Kibana related issues here.

Checklist

  • every related Kibana issue is listed under Kibana Cross Issues list
  • kibana cross issue tag is associated to the issue if any kibana cross issue is present
@nickofthyme nickofthyme added the bug Something isn't working label Aug 27, 2019
@markov00 markov00 self-assigned this Aug 27, 2019
@markov00 markov00 added the :chart Chart element related issue label Aug 27, 2019
markov00 added a commit to markov00/elastic-charts that referenced this issue Aug 27, 2019
markov00 added a commit that referenced this issue Aug 27, 2019
This commit re-apply the clippings for all the geometries but the points to avoid issues with a smaller custom domain than the one computed

fix #354
markov00 pushed a commit that referenced this issue Aug 27, 2019
## [11.0.5](v11.0.4...v11.0.5) (2019-08-27)

### Bug Fixes

* clip overflowing rect/lines/areas ([#355](#355)) ([3ff7379](3ff7379)), closes [#354](#354)
@markov00
Copy link
Member

🎉 This issue has been resolved in version 11.0.5 🎉

The release is available on:

Your semantic-release bot 📦🚀

@markov00 markov00 added the released Issue released publicly label Aug 27, 2019
AMoo-Miki pushed a commit to AMoo-Miki/OpenSearch-Dashboards that referenced this issue Feb 10, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working :chart Chart element related issue released Issue released publicly
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants