diff --git a/.github/ISSUE_TEMPLATE.md b/.github/ISSUE_TEMPLATE.md index a74199b451542bcc350d6ba708406c78c5e80eaf..d3510fbc4abf7c7889b0b39f93232d04682fda88 100644 --- a/.github/ISSUE_TEMPLATE.md +++ b/.github/ISSUE_TEMPLATE.md @@ -19,11 +19,12 @@ To check the option, add x in [ ], e.g.: [x] I am ... - + - [ ] Required: I have read the document and examples and tried to solve it by myself. (必填)我读过了文档和教程,并且曾试图自己解决问题。 - [ ] Required: I have searched for similar issues and that didn't help. (必填)我搜索过 issue 但是没有帮助。 @@ -57,33 +58,35 @@ In this issue, I have provided information with: 在这个 issue 中我提供了 -{DESCRIBE_HERE} + ### Expected Behavior -{DESCRIBE_HERE} + ### Current Behavior -{DESCRIBE_HERE} + ### Online Example + -{ADD_LINK_OF_DEMO_HERE} + -{PASTE_RELATED_CODE_HERE} + ## Topics @@ -103,7 +106,7 @@ THIS IS REQUIRED FOR ALL BUG REPORTS AND QUESTIONS!!! 如果是提问或报 bug -{DESCRIBE_HERE} + ## Environment diff --git a/src/coord/cartesian/Grid.js b/src/coord/cartesian/Grid.js index 458a16602e22ec7a5b6ffce5b1230821877fc38a..ac45e9c0f5916d1bca4c26b7a260fb1220480372 100644 --- a/src/coord/cartesian/Grid.js +++ b/src/coord/cartesian/Grid.js @@ -62,7 +62,7 @@ function Grid(gridModel, ecModel, api) { this._coordsList = []; /** - * @type {Object.} + * @type {Object.>} * @private */ this._axesMap = {}; @@ -423,9 +423,7 @@ gridProto._initCartesian = function (gridModel, ecModel, api) { if (axisPosition !== 'top' && axisPosition !== 'bottom') { // Default bottom of X axisPosition = 'bottom'; - if (axisPositionUsed[axisPosition]) { - axisPosition = axisPosition === 'top' ? 'bottom' : 'top'; - } + axisPosition = axisPositionUsed[axisPosition] ? 'top' : 'bottom'; } } else { @@ -433,9 +431,7 @@ gridProto._initCartesian = function (gridModel, ecModel, api) { if (axisPosition !== 'left' && axisPosition !== 'right') { // Default left of Y axisPosition = 'left'; - if (axisPositionUsed[axisPosition]) { - axisPosition = axisPosition === 'left' ? 'right' : 'left'; - } + axisPosition = axisPositionUsed[axisPosition] ? 'right' : 'left'; } } axisPositionUsed[axisPosition] = true; diff --git a/src/echarts.js b/src/echarts.js index c5058267f69a673240f28b8860d0fb9508c950f3..c3146c5344e6013d589754575a19d7f1e9bd8419 100644 --- a/src/echarts.js +++ b/src/echarts.js @@ -1936,7 +1936,7 @@ function enableConnect(chart) { * @param {Object} [theme] * @param {Object} opts * @param {number} [opts.devicePixelRatio] Use window.devicePixelRatio by default - * @param {string} [opts.renderer] Currently only 'canvas' is supported. + * @param {string} [opts.renderer] Can choose 'canvas' or 'svg' to render the chart. * @param {number} [opts.width] Use clientWidth of the input `dom` by default. * Can be 'auto' (the same as null/undefined) * @param {number} [opts.height] Use clientHeight of the input `dom` by default.