Skip to content

revert: limitInPlot #1891

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

Merged
merged 3 commits into from
Nov 10, 2020
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions __tests__/bugs/issue-1882-spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,10 @@ describe('#1882', () => {

area.render();

expect(area.chart.limitInPlot).toBe(true);
expect(area.chart.middleGroup.get('clipShape')).toBeDefined();
expect(area.chart.limitInPlot).toBe(false);
expect(area.chart.middleGroup.get('clipShape')).not.toBeDefined();
// 大于一个 xAxis 的高度
expect(area.chart.middleGroup.get('clipShape').getBBox().minY > 5).toBe(true);
expect(area.chart.middleGroup.get('clipShape').getBBox().minY > 5).not.toBe(true);

area.destroy();
});
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@antv/g2plot",
"version": "2.0.8",
"version": "2.0.9",
"description": "An interactive and responsive charting library",
"keywords": [
"chart",
Expand Down
2 changes: 1 addition & 1 deletion src/core/plot.ts
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ export abstract class Plot<O extends PickOptions> extends EE {
syncViewPadding,
supportCSSTransform,
/** 图形不超出画布 */
limitInPlot: true,
limitInPlot: false,
});
}

Expand Down
2 changes: 1 addition & 1 deletion src/index.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
export const version = '2.0.8';
export const version = '2.0.9';

// G2 自定义能力透出
import * as G2 from '@antv/g2';
Expand Down