Skip to content

Commit

Permalink
docs: move dual axes demos up
Browse files Browse the repository at this point in the history
  • Loading branch information
hustcc committed Jan 5, 2021
1 parent a42971e commit eb14f5b
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 10 deletions.
7 changes: 5 additions & 2 deletions __tests__/bugs/bug-dual-axes-same-y-spec.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { DualAxes } from '../../src';
import { findViewById } from '../../src/utils';
import { createDiv } from '../utils/dom';

const uv = [
Expand Down Expand Up @@ -65,8 +66,10 @@ describe('dual-axes same y fields', () => {

dualAxes.render();

expect(dualAxes.chart.views[0].getController('axis').getComponents()[0].component.get('title').text).toBe('y1');
expect(dualAxes.chart.views[1].getController('axis').getComponents()[0].component.get('title').text).toBe('y2');
const left = findViewById(dualAxes.chart, 'left-axes-view');
const right = findViewById(dualAxes.chart, 'right-axes-view');
expect(left.getController('axis').getComponents()[1].component.get('title').text).toBe('y1');
expect(right.getController('axis').getComponents()[0].component.get('title').text).toBe('y2');

dualAxes.destroy();
});
Expand Down
16 changes: 8 additions & 8 deletions gatsby-config.js
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,14 @@ module.exports = {
en: 'Pie',
},
},
{
slug: 'dual-axes',
icon: 'line',
title: {
zh: '双轴图',
en: 'Dual Axes',
},
},
{
slug: 'progress-plots',
icon: 'gauge',
Expand All @@ -148,14 +156,6 @@ module.exports = {
en: 'Scatter and Bubble',
},
},
{
slug: 'dual-axes',
icon: 'line',
title: {
zh: '双轴图',
en: 'Dual Axes',
},
},
{
slug: 'rose',
icon: 'rose',
Expand Down

0 comments on commit eb14f5b

Please sign in to comment.