Skip to content

Commit

Permalink
1.3.0 release
Browse files Browse the repository at this point in the history
  • Loading branch information
kener committed Nov 5, 2013
1 parent 9d20a64 commit f152249
Show file tree
Hide file tree
Showing 27 changed files with 5,646 additions and 888 deletions.
1 change: 1 addition & 0 deletions build/build-map.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
'echarts/chart/scatter',
'echarts/chart/k',
'echarts/chart/radar',
'echarts/chart/chord',
'echarts/chart/force',
'echarts/chart/map',
'echarts/util/mapData/china/0', // 全国
Expand Down
1 change: 1 addition & 0 deletions build/build-original-map.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
'echarts/chart/scatter',
'echarts/chart/k',
'echarts/chart/radar',
'echarts/chart/chord',
'echarts/chart/force',
'echarts/chart/map',
'echarts/util/mapData/china/0', // 全国
Expand Down
1 change: 1 addition & 0 deletions build/build-original.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
'echarts/chart/scatter',
'echarts/chart/k',
'echarts/chart/radar',
'echarts/chart/chord',
'echarts/chart/force',
/*
'echarts/chart/map',
Expand Down
1 change: 1 addition & 0 deletions build/build.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
'echarts/chart/scatter',
'echarts/chart/k',
'echarts/chart/radar',
'echarts/chart/chord',
'echarts/chart/force',
/*
'echarts/chart/map',
Expand Down
2 changes: 1 addition & 1 deletion build/echarts-map.js

Large diffs are not rendered by default.

1,562 changes: 1,376 additions & 186 deletions build/echarts-original-map.js

Large diffs are not rendered by default.

1,662 changes: 1,426 additions & 236 deletions build/echarts-original.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion build/echarts.js

Large diffs are not rendered by default.

Binary file modified doc/asset/img/architecture.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified doc/asset/img/doc/charts.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified doc/asset/img/mix.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions doc/asset/js/bootstrap-transition.js
Original file line number Diff line number Diff line change
Expand Up @@ -63,5 +63,5 @@ var _bdhmProtocol = (("https:" == document.location.protocol) ? " https://" : "
document.write(unescape("%3Cscript src='" + _bdhmProtocol + "hm.baidu.com/h.js%3Fb78830c9a5dad062d08b90b2bc0cf5da' type='text/javascript'%3E%3C/script%3E"));

var lrl = document.getElementById('last-release-link');
lrl.href = 'https://github.com/ecomfe/echarts/archive/1.2.1.zip';
lrl.innerHTML = 'ZIP (1.2.1)'
lrl.href = 'https://github.com/ecomfe/echarts/archive/1.3.0.zip';
lrl.innerHTML = 'ZIP (1.3.0)'
2 changes: 1 addition & 1 deletion doc/changelog.html
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ <h2>修改记录</h2>
<span>[+]新增 [-]删除 [^]升级 [#]修复 【】重要</span>
<div class="row-fluid">
<div>
<h3>Latest<small>After 2013-09-29</small></h3>
<h3>1.3.0<small>(2013-11-05</small></h3>
<ul>
<li>【+】 [chord]新增和弦图,支持多维选择</li>
<li>【^】 [pie]升级支持南丁格尔玫瑰图(半径/面积)模式</li>
Expand Down
2 changes: 1 addition & 1 deletion doc/example/www/js/echarts-map.js

Large diffs are not rendered by default.

1,562 changes: 1,376 additions & 186 deletions doc/example/www/js/echarts-original-map.js

Large diffs are not rendered by default.

1,662 changes: 1,426 additions & 236 deletions doc/example/www/js/echarts-original.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion doc/example/www/js/echarts.js

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@
<div class="container">
<div class="carousel-caption">
<h1>ECharts</h1>
<h6>(1.2.1 <a href="doc/changelog.html" target="_blank" class="link">Changelog</a></h6>
<h6>(1.3.0 <a href="doc/changelog.html" target="_blank" class="link">Changelog</a></h6>
<p>基于Canvas,纯Javascript图表库,提供直观,生动,可交互,可个性化定制的数据可视化图表。创新的拖拽重计算、数据视图、值域漫游等特性大大增强了用户体验,赋予了用户对数据进行挖掘、整合的能力。</p>
<p style="text-align: right;"><strong>———— 大数据时代,重新定义数据图表的时候到了</strong></p>
</div>
Expand Down Expand Up @@ -224,7 +224,7 @@ <h2 class="featurette-heading">多维度堆积</h2>
<img src="doc/asset/img/custom.png"/>
</div>
<h2 class="featurette-heading">个性化定制</h2>
<p>近300个可配置选项结合多级控制设计满足高度定制的个性化需求</p>
<p>超过500个可配置选项结合多级控制设计满足高度定制的个性化需求</p>
<a href="doc/doc.html" target="_blank">详细文档 &raquo;</a>
</div>
<hr class="featurette-divider">
Expand Down
1 change: 0 additions & 1 deletion src/chart/bar.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ define(function(require) {
var ecConfig = require('../config');
var ecData = require('../util/ecData');

var zrUtil = require('zrender/tool/util');
var zrColor = require('zrender/tool/color');

var self = this;
Expand Down
3 changes: 0 additions & 3 deletions src/chart/chord.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,6 @@ define(function(require) {
var ecConfig = require('../config');
var ecData = require('../util/ecData');

var zrConfig = require('zrender/config');
var zrEvent = require('zrender/tool/event');

var zrUtil = require('zrender/tool/util');
var vec2 = require('zrender/tool/vector');
var NDArray = require('../util/ndarray');
Expand Down
8 changes: 5 additions & 3 deletions src/chart/line.js
Original file line number Diff line number Diff line change
Expand Up @@ -630,7 +630,9 @@ define(function(require) {
/**
* 生成空数据所需的可计算提示图形
*/
function _getCalculableItem(seriesIndex, dataIndex, name, x, y, orient) {
function _getCalculableItem(
seriesIndex, dataIndex, name, x, y, orient
) {
var color = series[seriesIndex].calculableHolderColor
|| ecConfig.calculableHolderColor;

Expand Down Expand Up @@ -719,11 +721,11 @@ define(function(require) {
);
if (symbol.match('empty')) {
if (typeof itemShape.style.textColor == 'undefined') {
itemShape.style.textColor = itemShape.style.strokeColor
itemShape.style.textColor = itemShape.style.strokeColor;
}
if (typeof itemShape.highlightStyle.textColor == 'undefined') {
itemShape.highlightStyle.textColor =
itemShape.highlightStyle.strokeColor
itemShape.highlightStyle.strokeColor;
}
}

Expand Down
11 changes: 4 additions & 7 deletions src/chart/pie.js
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ define(function(require) {
if (self.selectedMap[itemName]) {
totalSelected++;
totalValue += +data[i].value;
maxValue = Math.max(maxValue, +data[i].value)
maxValue = Math.max(maxValue, +data[i].value);
}
}

Expand Down Expand Up @@ -412,8 +412,8 @@ define(function(require) {
if (labelControl.position == 'outer') {
// 外部显示,默认
radius = serie.radius[1]
- -itemStyle[status].labelLine.length
- -textStyle.fontSize;
- (-itemStyle[status].labelLine.length)
- (-textStyle.fontSize);
textAlign = (midAngle >= 150 && midAngle <= 210)
? 'right'
: ((midAngle <= 30 || midAngle >= 330)
Expand Down Expand Up @@ -554,7 +554,7 @@ define(function(require) {
// 视觉引导线起点半径
var midRadius = r1;
// 视觉引导线终点半径
var maxRadius = serie.radius[1] - -labelLineControl.length;
var maxRadius = serie.radius[1] - (-labelLineControl.length);
var midAngle = ((endAngle + startAngle) / 2) % 360; // 角度中值
var cosValue = zrMath.cos(midAngle, true);
var sinValue = zrMath.sin(midAngle, true);
Expand Down Expand Up @@ -1119,9 +1119,6 @@ define(function(require) {
var endAngle = shape.style.endAngle;
var defaultColor = shape.highlightStyle.color;

var r0 = +series[seriesIndex].radius[0]; // 扇形内半径
var r1 = +series[seriesIndex].radius[1]; // 扇形外半径

// 文本标签,需要显示则会有返回
var label = _getLabel(
seriesIndex, dataIndex, percent,
Expand Down
12 changes: 6 additions & 6 deletions src/component/legend.js
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ define(function (require) {

for (var i = 0; i < dataLength; i++) {
itemName = data[i];
if (itemName == '') {
if (itemName === '') {
if (legendOption.orient == 'horizontal') {
lastX = _itemGroupLocation.x;
lastY += itemHeight + itemGap;
Expand All @@ -107,7 +107,7 @@ define(function (require) {
&& (itemWidth + 5
+ zrArea.getTextWidth(itemName, font)
// 分行的最后一个不用算itemGap
+ (i == dataLength - 1 || data[i+1] == ''
+ (i == dataLength - 1 || data[i+1] === ''
? 0 : itemGap))
>= zrWidth - lastX
) {
Expand All @@ -119,7 +119,7 @@ define(function (require) {
if (zrHeight - lastY < 200 // 最后200px做分行预判
&& (itemHeight
// 分行的最后一个不用算itemGap
+ (i == dataLength - 1 || data[i+1] == ''
+ (i == dataLength - 1 || data[i+1] === ''
? 0 : itemGap))
>= zrHeight - lastY
) {
Expand Down Expand Up @@ -231,7 +231,7 @@ define(function (require) {
// 水平布局,计算总宽度
totalHeight = itemHeight;
for (var i = 0; i < dataLength; i++) {
if (data[i] == '') {
if (data[i] === '') {
temp -= itemGap;
if (temp > zrWidth) {
totalWidth = zrWidth;
Expand Down Expand Up @@ -274,7 +274,7 @@ define(function (require) {
maxWidth += itemWidth;
totalWidth = maxWidth;
for (var i = 0; i < dataLength; i++) {
if (data[i] == '') {
if (data[i] === '') {
temp -= itemGap;
if (temp > zrHeight) {
totalHeight = zrHeight;
Expand Down Expand Up @@ -479,7 +479,7 @@ define(function (require) {
var color;
for (var i = 0, dataLength = data.length; i < dataLength; i++) {
itemName = data[i];
if (itemName == '') {
if (itemName === '') {
continue;
}
serie = _getSeriesByName(itemName);
Expand Down
4 changes: 2 additions & 2 deletions src/component/title.js
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ define(function (require) {
textShape.clickable = true;
textShape.onclick = function(){
window.open(link);
}
};
}

var subtextShape = {
Expand All @@ -93,7 +93,7 @@ define(function (require) {
subtextShape.clickable = true;
subtextShape.onclick = function(){
window.open(sublink);
}
};
}


Expand Down
14 changes: 7 additions & 7 deletions src/component/tooltip.js
Original file line number Diff line number Diff line change
Expand Up @@ -895,7 +895,7 @@ define(function (require) {
else if (serie.type == ecConfig.CHART_TYPE_CHORD) {
if (typeof special2 == 'undefined') {
// 外环上
_tDom.innerHTML = _encodeHTML(name) + ' (' + value + ')';
_tDom.innerHTML = _encodeHTML(name)+' (' + value + ')';
}
else {
var name1 = _encodeHTML(name);
Expand Down Expand Up @@ -1196,7 +1196,7 @@ define(function (require) {
tipShape[i].ondragend = null;
tipShape[i].ondragover = null;
tipShape[i].ondrop = null;
zr.addShape(tipShape[i])
zr.addShape(tipShape[i]);
}
_lastTipShape = {
dataIndex : param.dataIndex,
Expand Down Expand Up @@ -1303,11 +1303,11 @@ define(function (require) {
*/
_encodeHTML = function (source) {
return String(source)
.replace(/&/g,'&amp;')
.replace(/</g,'&lt;')
.replace(/>/g,'&gt;')
.replace(/"/g, "&quot;")
.replace(/'/g, "&#39;");
.replace(/&/g, '&amp;')
.replace(/</g, '&lt;')
.replace(/>/g, '&gt;')
.replace(/"/g, '&quot;')
.replace(/'/g, '&#39;');
};

zr.on(zrConfig.EVENT.MOUSEMOVE, _onmousemove);
Expand Down
5 changes: 2 additions & 3 deletions src/echarts.js
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,9 @@
define(function(require) {
var self = {};
var echarts = self; // 提供内部反向使用静态方法;
self.version = '1.2.1';
self.version = '1.3.0';
self.dependencies = {
zrender : '1.0.4'
zrender : '1.0.5'
};
/**
* 入口方法
Expand Down Expand Up @@ -405,7 +405,6 @@ define(function(require) {
&& _chartList[len].ontooltipHover
&& _chartList[len].ontooltipHover(param, tipShape);
}
//_zr.refreshHover();
}

/**
Expand Down
6 changes: 3 additions & 3 deletions src/util/shape/chord.js
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@
*/
define(function(require) {

var util = require('zrender/tool/util')
var util = require('zrender/tool/util');
function ChordShape() {
this.type = 'chord';
}
Expand Down Expand Up @@ -160,12 +160,12 @@ define(function(require) {
y = originPos[1];
}
_ctx.beginPath();
ChordShape.prototype.buildPath.call(null, _ctx, e.style)
ChordShape.prototype.buildPath.call(null, _ctx, e.style);
_ctx.closePath();

return _ctx.isPointInPath(x, y);
}
}
};

require('zrender/shape/base').derive(ChordShape);
require('zrender/shape').define('chord', new ChordShape());
Expand Down

0 comments on commit f152249

Please sign in to comment.